Re: [Mesa-dev] Implement NV_fog_distance for Gallium hardware

2011-10-27 Thread Jose Fonseca
- Original Message - > From what I can see, the fog distance is computed per-vertex and > stored in the FogCoord vertex shader output. There is no fragment > shader change required. The fixed-function vertex program hasn't been > converted to the GLSL IR yet, only the fragment program, whic

Re: [Mesa-dev] Implement NV_fog_distance for Gallium hardware

2011-10-27 Thread Marek Olšák
From what I can see, the fog distance is computed per-vertex and stored in the FogCoord vertex shader output. There is no fragment shader change required. The fixed-function vertex program hasn't been converted to the GLSL IR yet, only the fragment program, which is irrelevant here. Gallium only u

Re: [Mesa-dev] Implement NV_fog_distance for Gallium hardware

2011-10-27 Thread Jose Fonseca
I only see implementation for ffvertex_prog.c Wasn't (or will soon be) the FF->Mesa IR replaced with FF->GLSL IR? If so, can you truly enable unconditionally on gallium/st? Jose - Original Message - > If there are no other concerns, I'll push this on Saturday, including > the nv20 fix

Re: [Mesa-dev] Implement NV_fog_distance for Gallium hardware

2011-10-27 Thread Marek Olšák
If there are no other concerns, I'll push this on Saturday, including the nv20 fix from Francisco Jerez. http://cgit.freedesktop.org/~mareko/mesa/log/?h=nv-fog-distance Marek On Tue, Sep 20, 2011 at 7:50 AM, Nicholas Miell wrote: > On 09/19/2011 10:23 AM, Ian Romanick wrote: >> >> I guess the b

Re: [Mesa-dev] Implement NV_fog_distance for Gallium hardware

2011-09-19 Thread Nicholas Miell
On 09/19/2011 10:23 AM, Ian Romanick wrote: > > I guess the big question is... why? With vertex shaders, this > functionality is not terribly useful. Over the past few weeks we've > been *removing* code like this, so it seems kind of odd to add some of > it. If I'm not mistaken, the only hardwa

Re: [Mesa-dev] Implement NV_fog_distance for Gallium hardware

2011-09-19 Thread Henri Verbeet
On 19 September 2011 19:23, Ian Romanick wrote: >> Direct3D 9 calls the eye radial fog distance mode "range-based fog" >> and Wine's D3D9 implementation will use NV_fog_distance to >> implement it. Several other open source game engines in Google Code >> Search use the eye radial fog mode if it is

Re: [Mesa-dev] Implement NV_fog_distance for Gallium hardware

2011-09-19 Thread Ian Romanick
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 09/19/2011 02:48 AM, Nicholas Miell wrote: > The NV_fog_distance extension allows you to specify how the fog > distance of a fragment is calculated. The usual method approximates > the distance of the fragment from the eye as the absolute value of >

Re: [Mesa-dev] Implement NV_fog_distance for Gallium hardware

2011-09-19 Thread Brian Paul
On 09/19/2011 03:48 AM, Nicholas Miell wrote: The NV_fog_distance extension allows you to specify how the fog distance of a fragment is calculated. The usual method approximates the distance of the fragment from the eye as the absolute value of the distance of the fragment from the eye's Z plane.

Re: [Mesa-dev] Implement NV_fog_distance for Gallium hardware

2011-09-19 Thread Corbin Simpson
On Mon, Sep 19, 2011 at 5:48 PM, Nicholas Miell wrote: > The NV_fog_distance extension allows you to specify how the fog distance > of a fragment is calculated. The usual method approximates the distance > of the fragment from the eye as the absolute value of the distance of > the fragment from th

[Mesa-dev] Implement NV_fog_distance for Gallium hardware

2011-09-19 Thread Nicholas Miell
The NV_fog_distance extension allows you to specify how the fog distance of a fragment is calculated. The usual method approximates the distance of the fragment from the eye as the absolute value of the distance of the fragment from the eye's Z plane. (Or, rather, the distance of each vertex and th