RE: [AD] Faster hsv_to_rgb()

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


Title: RE: [AD] Faster hsv_to_rgb()

> One nice thing about 0.8 fixed-point numbers is that I can make a 64K
> multiply lookup table for all values from 00-FF (they're one
> byte each).
> This eliminates any multiplies from the code, but reduces the
> accuracy of

Have you timed your changes by calling hsv_to_rgb lots of times in
a row ? Trading multiplies for memory fetches is unlikely to be
faster for uncached fetches on current (and even not so current)
hardware. Or have you timed these along with cache invalidation
between calls ?
That said, if you don't call it many times in a row, it's unlikely
to make a dent in one's profile anyway...

--
Vincent Penquerc'h



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