Hi Yefei,

The OSG supports multiple render to texture Cameras seamlessly, it
should simply be a case of creating the Camera's and adding the
textures and appropriate subgraphs to them and then using these
textures.  The only twist would be that if you are using Viewer slave
Camera then you'll need to make sure that these slaves don't inherit
the main scene graph as is the default behavior of slave Camera.  A
render to texture Camera in the scene graph doesn't inherit any
subgraph so it'll just use what subgraph you assign to it.

Robert.

On Wed, Sep 14, 2011 at 1:01 AM, He, Yefei <[email protected]> wrote:
> Hello, Folks,
>
>
>
> I’m working on an OSG application that requires two cameras rendering two
> different subscenes into textures, and apply the two textures to different
> geometries in the main scene.  I started out with the osgprerender example
> by creating two cameras and attaching them to two different textures. But
> the result was the two textures were identical, and the content was that
> from the first camera. I saw that Anthousis Andreadis reported a similar
> problem in April and later submitted a fix. My version of OSG does contain
> that fix. I looked into osgstereomatch and osgmultiplerendertargets, but I
> figured they are a bit different from my application. In those applications,
> a single camera is attached to multiple textures; in my case, two cameras
> are attached to two different textures. What do I need to do to make my
> application work? Are there any examples that I can look at?
>
>
>
> Thanks,
>
>
>
> Yefei
>
> _______________________________________________
> 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

Reply via email to