quote:
Here you go, perfect refllections, no stencil needed, works on every card that supports a zbuffer.
Well, you mean :
glClearDepth(0);
glClear(GL_DEPTH_BUFFER_BIT); // writes 0s in all depth buffer
glDepthRange(1,1);
glDepthFunc(GL_ALWAYS);
drawMyPolygon(); // create the mask with 1s in depth buffer
glDepthRange(0,1);
glDepthFunc(GL_LESS);
drawMyObjects(); // draw objects in the masked region
That's purely awesome !!!
Thanx for the tip

Also, it has one limitation : you can't render that at any moment. You have to find the time to do it at the beginning or the end of the rendering. right ?
quote:
Disons, que tu as 2 faces en X, l'une d'entre elles bouge lentement en X ou Y. Regardes l'intersection de plus proche, tu verras qu'il y a une sorte de scintillement dans les pixel qui font l'intersection.
Oui oui, Je vois très bien l'effet que c'est. Mais je ne vois pas en quoi le découpage des polygones peut arranger cet effet. Effectivement, l'approximation des Z est meilleure, mais toujours pas parfaite (et ne le sera jamais car les flottants auront toujours une précision limitée).
Mais ceci dit, je ce que vois encore moins, c'est pourquoi on se prend la tête avec ce cas particulier.

quote:
I would say, it practically does eleminate the problem. Keep in mind, that the range of a 64bit buffer is around 1,100,000,000,000 times higher than the range of a 24bit buffer...
LOL !!!
For the X junction, I agree it would be sufficient (unless your viewport is around 1e+15 pixels wide and high

But it would still not get rid of flickering for decal. Polygon Offset remains necessary.
Edited by - vincoof on January 18, 2002 5:49:30 PM