From 1c4de0e1d2c30eb9a9cdced47182c97cf8d8874b Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Mon, 15 Apr 2002 08:09:02 +0000 Subject: [PATCH] Fixed display problem with the HUD in osgtext which was caused by the new mods to SceneView not honouring the z near/far calculation flag. --- src/Demos/osgtext/main.cpp | 2 +- src/osgUtil/SceneView.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Demos/osgtext/main.cpp b/src/Demos/osgtext/main.cpp index 591a11612..4a9c26d4e 100644 --- a/src/Demos/osgtext/main.cpp +++ b/src/Demos/osgtext/main.cpp @@ -60,7 +60,7 @@ void set2dScene(osg::Group* rootNode) osg::Geode* geode; osg::Material* textMaterial; osg::StateSet* textState; - double xOffset=250; + double xOffset=150; double yOffset=gFontSize+10; /////////////////////////////////////////////////////////////////////////// diff --git a/src/osgUtil/SceneView.cpp b/src/osgUtil/SceneView.cpp index c5c0e467b..e8a98ca20 100644 --- a/src/osgUtil/SceneView.cpp +++ b/src/osgUtil/SceneView.cpp @@ -242,7 +242,7 @@ void SceneView::cull() cullStage(projection.get(),modelview.get(),_cullVisitor.get(),_rendergraph.get(),_renderStage.get()); } - if (_camera.valid()) + if (_camera.valid() && _calc_nearfar) { _camera->setNearFar(_near_plane,_far_plane); }