boost::multi_array equivalent for runtime number of dimensions

Hello,
I only know at runtime the dimension and extends of a multidimensional
array, though the number of dimensions is always < 10 for e.g.
Is there a container that allows this?
Otherwise, I can write code for
multi_array

I only know at runtime the dimension and extends of a multidimensional array, though the number of dimensions is always < 10 for e.g.
Is there a container that allows this?
OvermindDL1 proposed to use boost.variant in thread called "question
about multi_array use" (see there for a more complete code).
for example:
typedef boost::variant

On Thu, Jan 7, 2010 at 11:48 AM, alfC
I only know at runtime the dimension and extends of a multidimensional array, though the number of dimensions is always < 10 for e.g.
Is there a container that allows this?
OvermindDL1 proposed to use boost.variant in thread called "question about multi_array use" (see there for a more complete code). for example: typedef boost::variant
,multi_array ,multi_array ,multi_array ,multi_array ,multi_array ,multi_array > multi_array_variant_t; and he says that using boost.fusion will be even better. I didn't try it, but I would like to know if the solution really works well.
I have been using Boost.Fusion, I cannot recommend it enough, I have completely decoupled the sizes of things from what operates on them.
participants (3)
-
alfC
-
Hicham Mouline
-
OvermindDL1