Updating now. I'll let you know how it goes.
-Paul
> Hi Paul,
>
> I have reviewed you changes, and rather than integrate this
> have added a getCurrentRenderStage() and getCurrentCamera()
> to CullVisitor, and converted your apply(OcclusionQueueNode&)
> code to use getCurrentCamera(). The implementation is a
> little different than you code, so it'd be worth you double
> checking. I believe it's more correct than your own old code
> though as it should handle nested RenderBins, I don't have
> code that unconvered the bug your seeing though so can't
> confirm first hand whether it works or not.
>
> The new methods look like:
>
> inline RenderStage* getCurrentRenderStage()
> {
> return _currentRenderBin->getStage();
> }
>
> inline osg::Camera* getCurrentCamera()
> {
> return getCurrentRenderStage()->getCamera();
> }
>
> An svn update will get these changes.
>
> Robert.
>
> On Wed, Jul 23, 2008 at 11:58 PM, Paul Martz
> <[EMAIL PROTECTED]> wrote:
> > Hi Robert -- Thanks for your help below.
> >
> > Attached is a fix for CullVisitor handling of
> OcclusionQueryNode, so
> > that OQN works with RTT Camera nodes.
> >
> > This CullVisitor.cpp has the same typo fixes from the "Fix
> a few typos"
> > submission, so you can use this file instead.
> >
> >> Hi Paul,
> >>
> >> The current RenderStage will have the RTT Camera attached to it.
> >> Beyond this I don't recall any CullVisitor mechinism for keeping
> >> track of the current Camera.
> >>
> >> Robert.
> >>
> >> On Wed, Jul 23, 2008 at 8:39 PM, Paul Martz
> <[EMAIL PROTECTED]>
> >> wrote:
> >> > Hi Robert -- I'm getting bounces from dreamhost, so sending
> >> this directly.
> >> > Hope you can help.
> >> > -Paul
> >> >
> >> >
> >> > Hi Robert -- I have a scene configured much like
> >> osgprerender, with a
> >> > top-level Camera and a nested RTT Camera.
> >> >
> >> > The rendered scene uses OcclusionQueryNode, and
> currently renders
> >> > incorrectly. I've tracked this down to a bug in the
> CullVisitor's
> >> > handling of OcclusionQueryNode, which I coded earlier this
> >> year when I
> >> > integrated OcclusionQueryNode into core OSG. I now need to
> >> fix my bug.
> >> >
> >> > At CullVisitor.cpp line 1464, I have:
> >> > osg::Camera* camera = getRenderStage()->getCamera();
> >> >
> >> > When I wrote this code, I was expecting I'd get the RTT
> Camera, but
> >> > this code actually obtains the top-level Camera rather than
> >> the RTT Camera.
> >> >
> >> > How can I obtain the current RTT Camera within
> >> > CullVisitor::apply(OcclusionQueryNode&) ?
> >> >
> >> > Thanks,
> >> >
> >> > Paul Martz
> >> > Skew Matrix Software LLC
> >> > http://www.skew-matrix.com
> >> > +1 303 859 9466
> >> >
> >
> > _______________________________________________
> > osg-submissions mailing list
> > [email protected]
> >
> http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscene
> > graph.org
> >
> >
> _______________________________________________
> osg-submissions mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-o
penscenegraph.org
_______________________________________________
osg-submissions mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org