On Thu, 29 Apr 1999, C.J. Beyer wrote:

> Btw. Is there anyone working on adding polygon_offset support for FX Mesa.
> It's used in Quake3. It doesn't seem to hard to implement at all.
> 
> Any toughs where/how should it implemented?

I can expect some hidden 'gotcha's.

The *obvious* thing is just to move the polygon in Z as a function
of slope. However, if you do that, the offset polygon will (I think)
fog differently.  At extreme slopes, this will become quite noticable
I suspect. Imagine a decal on a bad guy's jacket. Every time he
turns so the decal is nearly edge on, glPolygonOffset will apply
increasing amounts of Z, bringing the decal closer to the eye 
with the effect that although the bad guy is hiding in the fog,
every time he turns around, his decal shines like a beacon through
the fog.

glPolygonOffset really sucks.

I could imagine other things that might break too (like texture
perspective correction) - but those are harder to think about.

The trick that I have been using in the absence of a working glPolygonOffset
(which is to move the near clip plane a touch) avoids that problem
but is costly because it causes the fog tables to be recomputed.

Steve Baker                (817)619-2657 (Vox/Vox-Mail)
Raytheon Systems Inc.      (817)619-2466 (Fax)
Work: [EMAIL PROTECTED]      http://www.hti.com
Home: [EMAIL PROTECTED] http://web2.airmail.net/sjbaker1



_______________________________________________
Mesa-dev maillist  -  [EMAIL PROTECTED]
http://lists.mesa3d.org/mailman/listinfo/mesa-dev

Reply via email to