Hi,

I've got a project were I want to render a floating point texture. 
Currently im using a texture rectangle with GL_RGB as a render target which is 
attached to a prerender camera. This works fine but now I need to render to a 
floating point texture and I have tried GL_FLOAT_R32_NV(which is the one I 
want), and some of the ARB-variants but I guess im missing something because it 
does not work. The shader im using is simply trying to output pixels as red 
gl_FragColor.r = 1; but nothing seems to get rendered, the texture just stays 
black .
For the first frame that is rendered i get the following detected OpenGL error: 
"invalid enumeration after RenderBin::Draw" and subsequent rendering calls 
gives the message: "invalid operation after RenderBin::Draw"

I set the following texture 'attributes'
texture->setWrap(osg::Texture::WRAP_S, osg::Texture::CLAMP); 
texture->setWrap(osg::Texture::WRAP_T, osg::Texture::CLAMP); 
texture->setFilter(osg::Texture::MIN_FILTER, osg::Texture::NEAREST);
texture->setFilter(osg::Texture::MAG_FILTER, osg::Texture::NEAREST);
texture->setInternalFormat(GL_FLOAT_R32_NV);
texture->setShadowComparison(false);

The texture is attached to the camera as osg::Camera::COLOR_BUFFER
RenderTargetImplementation is set to FRAME_BUFFER_OBJECT

Im using a Quadro fx 700 with support for the GL_NV_float_buffer.

Any tips or pointers are highly appreciated!

/Andreas Lindmark

=
Sale on Peak Flow Meters
Prevent Asthma Attacks in Kids or Adults Electronic Peak Flow Meter.
http://a8-asy.a8ww.net/a8-ads/adftrclick?redirectid=580c56d9ac68512a3a942e278be98293


-- 
Powered by Outblaze
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to