On 2002.04.04 09:08 Keith Whitwell wrote:
> On Thu, 4 Apr 2002 01:56:22 +0100
> José Fonseca <[EMAIL PROTECTED]> wrote:
> 
> > ...
> 
> > the further away is the vertex more its color is nearer to the fog
> > background color. Since the colors are interpolated in the triangle
> this
> > gave the impression of fog.
> >
> > But the OpenGL spec says that the fog color is calculated on a _pixel_
> > basis and not on a _vertex_ basis. Indeed the result is different,
> > especially in long polygons that span from the front way to the back.
> 
> 
> Actually I think it gives you scope to do either.

Well the Opengl 1.3, sec 3.10 says: "Further, f need not be computed at 
each fragment, but may be computed at each vertex and interpolated as 
other data are.", but it also says "If enabled, fog blends a fog color 
with a rasterized fragment s post-texturing color using a blending factor 
f." Since it's applied after on the pipeline I'm not sure that the results 
will be the same, even without texturing..

> The issue with adding
> fog into the vertex colors is what happens when texturing is turned on -
> the vertex color may not even contribute to the color of the generated
> fragments.

I see, it depends of the texture environment... so unless there is a way 
around it we will have to fallback to software on these no matter what.

> 
> Keith
> 

José Fonseca

_______________________________________________
Dri-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/dri-devel

Reply via email to