From 66397b3962d1ae75e602d6bac849752add2a1201 Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Thu, 5 Aug 2004 12:47:55 +0000 Subject: [PATCH] Changed the popProjectionMatrix so that it didn't allow modification on the near and far values when clamping the projection matrix. --- src/osgUtil/CullVisitor.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/osgUtil/CullVisitor.cpp b/src/osgUtil/CullVisitor.cpp index 68463878e..55196d1b0 100644 --- a/src/osgUtil/CullVisitor.cpp +++ b/src/osgUtil/CullVisitor.cpp @@ -211,7 +211,10 @@ void CullVisitor::popProjectionMatrix() // so it doesn't cull them out. osg::Matrix& projection = *_projectionStack.back(); - clampProjectionMatrix(projection, _computed_znear, _computed_zfar); + double tmp_znear = _computed_znear; + double tmp_zfar = _computed_zfar; + + clampProjectionMatrix(projection, tmp_znear, tmp_zfar); } else {