>> "Niels" == Niels van Vliet
<van-vl_n(a)lrde.epita.fr> writes:
> Akim Demaille wrote:
>>
>> "Niels"
== Niels van Vliet <van-vl_n(a)lrde.epita.fr> writes:
>> >
+FROM_X_TO_RGB(hsi);
>> > +FROM_RGB_TO_X(hsi);
>> > +FROM_X_TO_RGB(hsl);
>> > +FROM_RGB_TO_X(hsl);
>> > +FROM_X_TO_RGB(hsv);
>> > +FROM_RGB_TO_X(hsv);
>> > +FROM_X_TO_RGB(nrgb);
>> > +FROM_RGB_TO_X(nrgb);
>> > +FROM_X_TO_RGB(xyz);
>> > +FROM_RGB_TO_X(xyz);
>> > +FROM_X_TO_RGB(yiq);
>> > +FROM_RGB_TO_X(yiq);
>> > +FROM_X_TO_RGB(yuv);
>> > +FROM_RGB_TO_X(yuv);
>> These pairs of guys should merged.
Next checkin.
> Can't you find a means to store their names in
a map and use that map
> instead of the series of if? That would be more extensible.
The type of the image (oln::image2d<ntg::T##_8>)
could be
generic using templates, but not the name of the function
which is a concatenation:
oln::convert::f_##T##_to_rgb<8, 8>()
I'm not sure we understand each other: can't you extend FROM_X_TO_X to
add the pair in a map which the test would latter use? You'd use this
map instead of the open coded list of ifs.