[info-performer] blending with fog

New Message Reply Date view Thread view Subject view Author view

From: Stephen Jeffrey (Stephen.Jeffrey++at++maths.uq.edu.au)
Date: 06/20/2002 23:27:45


Hi,

I wish to have a multitextured object shaded with fog.
The geoset is drawn once, with the first texture, and
then a copy of the geoset is drawn with another
texture. The two are blended using:

pfTransparency(PFTR_BLEND_ALPHA);
pfOverride(PFSTATE_TRANSPARENCY, PF_ON);
glBlendFunc(GL_ZERO, GL_SRC_COLOR);

(ie. the second texture modulates the first)

I have fog globally enabled, but there are problems
with the blending. Specifically, the fog will not
fully obscure the object. This may result in the fog being
blended with each geoset, and then the two fogged
geosets blended - I'm not sure, but suspect the problem
is somehow related to this.

The 2nd geoset has a draw callback function, and the
transparency/blending is implemented in that function.
I have tried switching off global fog and only applying
it in the draw callback, hoping that the two geosets
would be blended, and then the fog added. The results
are essentially unchanged.

cheers
steve


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2b29 : Thu Jun 20 2002 - 23:28:18 PDT

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.