Maciej Cencora wrote:
> Hi,
> 
> here are patches for EXT_fog_coords support for r300-r500 hw. I tested it 
> only 
> on rs690 hw (no tcl), so probably I've missed some code for hw tcl path. 
> Progs 
> I have tested the fog with:
> tests/fog
> tests/fogcoord
> demos/fogcoord
> demos/tunnel
> 
> 
> Here's how it works:
> 1. dedicated fog unit is disabled
> 2. stuff fog coords (along with mesa other params) as tex coord and pass it 
> down to the fp (can't stuff it into color vector because GA/GB unit is 
> clamping all colors to [0..1] range - the clamping can be disabled on r500 hw 
> only)
> 3. calculate result color in fragment shader (fragment program is 
> automagically added by mesa code).
> 
> I've rewritten RS setup a little, I think it's little bit more clean now. W 
> pos support in fp is probably screwed up with those patches.
> 
> The fog probably could be done with dedicated fog unit but there's the 
> clamping problem for r300 hw (possible solution is to scale the fog coords in 
> vertex shader so they fit in [0..1] range).
> 
> I'd appreciate all comments and test reports.

On the surface of it, the patches look pretty decent. Of course, I've
been down that path before. I'll test it on an r4xx later with HW TCL,
and see if any changes need to be made.

~ C.

------------------------------------------------------------------------------
Create and Deploy Rich Internet Apps outside the browser with Adobe(R)AIR(TM)
software. With Adobe AIR, Ajax developers can use existing skills and code to
build responsive, highly engaging applications that combine the power of local
resources and data with the reach of the web. Download the Adobe AIR SDK and
Ajax docs to start building applications today-http://p.sf.net/sfu/adobe-com
_______________________________________________
Mesa3d-dev mailing list
Mesa3d-dev@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mesa3d-dev

Reply via email to