emanuel stiebler wrote:
>
>>
> > All the definitions of the INNER_LOOP
> > seem to start with something like ...
>
> Nope. That's why i thought about this. I was looking at osmesa.c
>
> > #define INNER_LOOP( LEFT, RIGHT, Y ) \
> > { \
> > GLint i, n = RIGHT-LEFT; \
>
> n = RIGHT - LEFT;
>
> NO cpu time ? (this are no constants, are variables !)
>
Well, not significantly more than the comparison you were suggesting,
and the value of n is needed in the "typical case".
>
> But even if it would be true, every time you write one of this triangle
> routines, you have to think about this case.
>
Looking at the osmesa.c code which does some unecessary calculations,
even if RIGHT<=LEFT (the PIXELADDR4) I agree at least partially to
you.
But if the test is added, then the current comparisons
should be removed if we want to avoid redundance. (But
for example in osmesa the test is part of the
span rendering operation so it cannot just be removed
without changing the whole loop structure).
So I still suspect if this is worth the trouble.
(In any case I don't actually use any of these code
paths I think so who am I to speak here...)
Eero
_______________________________________________
Mesa-dev maillist - [EMAIL PROTECTED]
http://lists.mesa3d.org/mailman/listinfo/mesa-dev