RE: [Algorithms] Bullets on walls
Brought to you by:
vexxed72
From: Stephen J B. <sj...@li...> - 2000-07-21 17:49:49
|
On Fri, 21 Jul 2000, Mark Atkinson wrote: > We do it this way: > > If the decal does not cross a polygon boundary with a high enough crease > angle, draw it as a quad. Use ZBIAS if supported and/or move it along the > normal to lift it off the surface. > > Otherwise draw it as decal, as per Jaimi's method. Remember to enable > ALPHATEST so there's no overdraw or fill-rate hit even if the base triangle > is large and has several decals. Eh? Alpha Test (presuming it's the same mechanism as glAlphaFunc in OpenGL) won't eliminate (all of) the overdraw/fillrate issues. The renderer still has to scan-convert all those pixels, do the texture calculation on each one and compare the alpha value against the threshold. * On some hardware, that'll be no cheaper than drawing the entire polygon. * On other hardware, you'll only pay *some* per pixel cost (maybe half). * It'll never be zero though - that's impossible - it has to consume some texture bandwidth per-pixel of the entire polygon. Steve Baker (817)619-2657 (Vox/Vox-Mail) L3Com/Link Simulation & Training (817)619-2466 (Fax) Work: sj...@li... http://www.link.com Home: sjb...@ai... http://web2.airmail.net/sjbaker1 |