On 10/6/2011 4:54 AM, Emmanuel Roche wrote:
Hi everyone,

I have a simple question regarding pre/post render cameras:

- suppose I have a scene graph under a viewer camera
- the scene data for this camera starts with a root group.
- somewhere in that root group, I add a pre_render camera, to render a texture on an FBO, and as a child of that pre render camera... I use the root group itself !...

OSG scene graphs must be acyclic, so don't do that.


What would be the behavior in that case ?
- Would OSG notice that the pre_render camera is to be rendered before but render it only once - Or would OSG fail to notice this and prepare "pre-pre-pre... pre-render" stages forever ? (and actually freeze completely) ?

I'm guessing it would infinite loop, but there's no need to speculate: try it and see for yourself. :-)

Or is there a way to achieve what I want to do here properly if this option is known to block ?

Multiparent your scene, once to the pre-render camera, and once again to the root camera (which would also have the pre-render camera as a child).
   -Paul


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

Reply via email to