Re: [AD] Color convertors

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


> > I think adding $040204 is most correct,

this is because 0xFFFF would be (8 * 31.5 , 4* 63.5 , 8 * 31.5)

> So here's bright pink in 15bpp: 111110000011111.  In 24bpp, it's 0xf0f.
That
> means r24 = (r15 << 3) + 7.  What's so hard about that?  It means that
> 15bpp's 0 turns to 24bpp's 7, but that's close.  Hopefully nobody uses
both
> this code and code that triggers on exactly (0,0,0).

adding 0x070007 would fix bright pink but tint everything else slightly too,
and as you say it
would break black=0x000000 which might cause other bother, but less so IMO.

Why not make this a user defined value? it could be used to apply a range of
effects.

Matt
"If you document your bugs, they become features"





Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/