Hi, I have just started using the OverlayNode in osg::Sim (from the 2.0 release) and have come accorss an issue. If the items in the overlay subgraph are purely 2D objects then nothing is rendered to the overlay at all. My guess is that the near and far values are both being calculated as 0. There doesn't seem to be any way to get access to the CameraNode to fix this issue.
The problem can be easily reproduced by running the osgsimulation example with the attached files: osgsimulation --overlay FlatRect.osg (nothing appears on the 'earth') osgsimulation --overlay NonFlatRect.osg (works fine) The attached files define a simple rectangle, FlatRect has no y component (ie is 2D) while NonFlatRect does. At the momemnt I am simply working around the issue by adding a couple of dummy points to my overlay scene to give it some depth. I havent looked in to this but neither file works if ortho mode is used. I don't have this problem in my application however. As a side note, by default the Overlaynode also prints a notify to the screen stating which mode it uses (ie OverlayNode::init() - OBJECT_DEPENDENT_WITH_ORTHOGRAPHIC_OVERLAY). This should probbaly be swiched off by default if it hasn't already been in the latest svn version. Cheers, Brad DISCLAIMER:--------------------------------------------------------------------------- This Email may contain confidential and/or privileged information and is intended solely for the addressee(s) named. If you have received this information in error, or are advised that you have been posted this Email by accident, please notify the sender by return Email, do not redistribute it, delete the Email and keep no copies. --------------------------------------------------------------------------------------
NonFlatRect.osg
Description: NonFlatRect.osg
FlatRect.osg
Description: FlatRect.osg
_______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

