[osg-users] Rendering a scene to texture

Jochen Maier franke.jochen at gmx.de
Sun Mar 18 11:08:56 PDT 2018

Thank you very much Robert :)

Okay, I'll take a look at the examples you had talked about.

I know that the way is to realize this is using different cameras and render to texture. But I don't know how to initiate the rendering-process; I only know this by calling Viewer::frame(). I thought there is another way.

I was thinking a little bit of this and my idea was:
There are different scene-roots (osg::group). Add all my scene childs to each osg::group.
Now I set for the RTT the sceneData which I want to render to texture (osgViewer::setSceneData(sceneToRenderToTexture)) and the camera which renders to texture and call osgViewer::frame().
Done!! I have a texture wich shows my scene (sceneToRenderToTexture).

Is this an option to solve my problem?


Read this topic online here:

More information about the osg-users mailing list