Am Mittwoch, 28. April 2004 06:23 schrieb Ian Romanick:
Here's my first attempt at EXT_fog_coord for R200. For tcl_mode=0 it works fine. In fact, the code currently in CVS has all the support needed for tcl_mode=0. tcl_mode=1 is totally broken. I think I missed setting R200_VTX_DISCRETE_FOG somewhere for that path.
tcl_mode=2 and tcl_mode=3 (which are the same because there's no x86-specific codegen yet) *almost* work. It looks like the fog coordinate is being interpreted incorrectly, but I'm not sure why. I tried sending 1.0-f, but that wasn't right either. Anyone (esp. anyone with docs!) have any ideas?
I haven't done anything yet to support arrays of fog coordinates.
My intention is to get this done, then add support for point sizes != 1.0, then add support for cube map texture coordinates, then add support for 3D texture coordinates. I wanted to get my feet wet with what should have been the easiest of the four. :)
I get some sigfaults with fog (only) and some results with various fogcord.
progs/redbook> ./fog Mesa: software DXTn compression/decompression available Speicherschutzverletzung
That's odd. I'll have to look into that. The interesting thing here is that this program does NOT use EXT_fog_coord. Does it segfault without my EXT_fog_coord patch?
progs/redbook> ./fogindex GLUT: Fatal Error in fogindex: visual with necessary capabilities not found.
That's normal. This program uses a color index visual, and none of the open-source drivers support that.
progs/redbook> cd ../samples/ progs/samples> ./fog Mesa: software DXTn compression/decompression available Speicherschutzverletzung
Hmm...this program is very similar to the Red Book fog program...
Mesa/progs> cd demos/ progs/demos> ./fogcoord Mesa: software DXTn compression/decompression available fog(GL_FOG_COORDINATE_EXT) fog(GL_EXP, 0.75)
The screen shot of this you sent is exactly what I get too. That's why I said it "almost works." :) The fog coordinate is getting to the vertex unit correctly, but apparently the vertex unit is programmed to interpret it correctly. I've tried everything I can think of, so I think someone that has access to hardware docs will have to finish this patch. :(
progs/demos> cd ../tests/ progs/tests> ./fogcoord Mesa: software DXTn compression/decompression available GL_RENDERER = Mesa DRI R200 20030328 AGP 4x x86/MMX+/3DNow!+/SSE TCL GL_VERSION = 1.3 Mesa 6.1 Squares should be colored from white -> gray -> black. glFogCoord( 5.0) glFogCoord(10.0) glFogCoord(15.0) glFogCoord(20.0) glFogCoord(25.0)
------------------------------------------------------- This SF.Net email is sponsored by: Oracle 10g Get certified on the hottest thing ever to hit the market... Oracle 10g. Take an Oracle 10g class now, and we'll give you the exam FREE. http://ads.osdn.com/?ad_id149&alloc_id�66&op=click -- _______________________________________________ Dri-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/dri-devel
