Hi John, If you are using GLSL then osg::Fog/glFog will only provide the inbult fog uniform values will be available to the shader, but no fog will be applied unless you do something with them nothing will happen.
If Fog is being applied when you are expect to that a subgraph is using GLSL then it suggests that GLSL is not being used for some reason. In you case you suggest the RTT Pbuffer you are seeing Fog, so perhaps the Pbuffer context doesn't support GLSL, or perhaps the contexts aren't being extension/manged correctly on the OSG side so that shaders aren't being applied correctly. It may also be easily a driver bug, trying your setup on different machines/drivers would help test this. Having never tried your particular usage combination I can't really provide any insight to way it's not working. As in my previously reply, I can't really do anything without a bit of code to test that reproduces the problem. Robert. On Thu, Jun 19, 2008 at 4:59 PM, Argentieri, John-P63223 <[EMAIL PROTECTED]> wrote: > All, > > Why is it that osg::Fog, and maybe glFog(), work as expected in RTT setups > if FRAME_BUFFER_OBJECT is chosen as the RenderTargetImplementation on your > Camera, but if PIXEL_BUFFER/_RTT are chosen, you must re-load the scene? > > I think that people are under the impression that when GLSL shaders are > used, glFog is broken, but that's not true. > > I think that if the osg::Fog is applied ( with Fog options ) to the Scene > before setSceneData() is called, you will get fog, even in PIXEL_BUFFER type > setups. > > BTW I have a GeForce 6 series on my box. > > John > > _______________________________________________ > osg-users mailing list > [email protected] > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org > > _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

