[AD] Precalculating 1/h in the polygon rasterizers

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


Hi,

Last week, I was toying with the rasterizer again, and I have a map which
uses a lot of polys. fixdiv happens to show up (along with the rasterizer
itself, fill_edge_structure, and other friends) in the top 10 of my profile.
Looking at the code, it seems there are quite a few divisions by h, and
these could be precalculated. However, since I use the fixed point versions,
I'm wondering if this would introduce too large an imprecision.
My polys are medium sized, and roughly facing the camera, so that's not a
really good testcase. Maybe this was tried before, and it looked bad, so
that's why there are so many divs here ? Or merely nobody's thought doing
it worthwhile ?

Cheers

-- 
Vincent Penquerc'h



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