Hi Janna, >From my understanding there is no built-in and "simple" way of accomplishing this, but it is possible. I have a similar feature working in my application that does the following:
- I attach a custom cull callback to the drawable I am interested in. This cull callback simply records the frame number from the cull visitor. - I then attach another cull callback to the RTT camera node. This cull callback compares the current frame number to the last recorded frame number in the drawable cull callback. If the frame numbers don't match, then the drawable has been culled and the cull callback will disable the RTT node. - An important note about this technique is that it depends on the traversal order of the drawable and RTT node. For this to work, the RTT node must be traversed AFTER the drawable node. So make sure the drawable appears before the RTT node in the scene graph. Hope this is helpful. Cheers, Farshid On Tue, Sep 11, 2012 at 11:36 AM, Janna Terde <[email protected]> wrote: > Hi Jeremy, > > I can cull the RTT camera using its cull mask or node mask however I need > to know when should I do it. I would like to cull the camera when the node > representing the mirror (Geode) is culled so when it is outside of the > viewing frustum. This is what I am trying to do, I've tried to use > CullVisitor and isCulled function and also tried to construct the Polytope > from main camera but still did not get the correct behavior. :( > > So I am wondering if there is something I don't know since it seems to be > very common thing to do and should be simple to do. > > Cheers, > Janna > > ------------------ > Read this topic online here: > http://forum.openscenegraph.org/viewtopic.php?p=49946#49946 > > > > > > _______________________________________________ > 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

