I've been trying to set up my program to use HDR. This is done by first pre-rendering to a texture using a FBO and then orthagraphically projecting the quad to the screen. My hierachy looks a bit like this:

osgProducer::Viewer
         |
         V
    osg::Group -> osg::CameraNode (ortho projection) -> osg::Geode (quad)
         |
         V
osg::CameraNode (pre render)
         |
         V
  osg::Group (scene)
                                      
(I hope my diagram shows up clearly, tried to use fixed width font!)
The system works and displays the scene as I expected. The only problem is that the camera cannot be moved. When dragging with the mouse, the light source seems to rotate around the scene, instead of the camera itself.
Is there any way to tie the viewer to the required camera node?
I can see that I could create a callback class for the viewer which modifies the camera node matrix, but is there a better solution?

Thanks,
James
_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Reply via email to