
Ullrich Koethe wrote:
Joel de Guzman wrote:
VIGRA doesn't have an explicit RGBA type (TinyVector<T, 4> can be used instead), because so far no-one came up with a convincing proposal for these operations. But without them, RGBA is pretty useless.
Hmmm... TinyVector<T, 4>... I think VIGRA should use Fusion for that instead ;-)
I had a look at Fusion, but I'm not sure whether it would be helpful in this context. TinyVector is based on three design goals: it should support the std::vector interface (except for resize etc.),
Like boost::array? it should be fast (you
have millions of these beasts in a single image),
Definitely. and it should behave
like a built-in arithmetic type (except for division which is problematic because the zero vector is not the only one that may cause a division-by-zero error).
No problem. But have you seen Andy's work on matrices using fusion? Fusion may be more helpful in heterogeneous pixel
types, but they often have very specific requirements that are perhaps better handled explicitly.
Like what, for example? Cheers, -- Joel de Guzman http://www.boost-consulting.com http://spirit.sf.net