Hi J-S -- I have a similar issue in one of my apps. I have a large scene (VPB database) with some geometry right in front of the eye (which I draw in eye coordinate space). So the near plane must be very close to the eye and the far plane extremely distant.
I currently disable autocompute and set a large far plane value and a small near plane value, but this results in z fighting. To solve this in OpenGL, I'd use two projection matrices, one for the planet and one for the very close eye space geometry. The equivalent to this in OpenGL would be to use two Camera nodes. I haven't had time to code this up yet, but I'm certain it will address the issue. The first camera will auto compute near and far based on the planet, then the second camera will clear the depth buffer, will auto compute based on the eye space geometry, and will render that geometry. Seems like you could do something similar with your skydome. Use a camera to render the skydome, then a second camera to render everything else in your scene. (By the way, to "set" the near and far plane values, you set the projection matrix. OSG abstracts this away to make them look like two separate concepts, which is why we have a FAQ on "why does OSG seem to ignore my near and far values?" The answer is that OSG, by default, autocomputes the near and far planes and overrides those values as set by an application that explicitly sets the projection matrix.) Paul Martz Skew Matrix Software LLC http://www.skew-matrix.com +1 303 859 9466 -----Original Message----- From: osg-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Jean-Sébastien Guay Sent: Tuesday, April 21, 2009 10:13 AM To: OpenSceneGraph Users Subject: [osg-users] Geometry considered in near+far plane auto computation Hi all, I need some nodes to be ignored by the near+far plane auto computation. I was wondering, is there some other way than setReferenceFrame(ABSOLUTE_RF) to do this? My specific use case is a skydome. It needs to be very large, but still be "in the world" - if I use the same trick as for a skybox (moving the cube with the camera) it will look like the horizon moves up relative to the terrain if I move the camera higher in altitude... Not a desirable effect. J-S -- ______________________________________________________ Jean-Sebastien Guay jean-sebastien.g...@cm-labs.com http://www.cm-labs.com/ http://whitestar02.webhop.org/ _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org