diff --git a/src/osg/Camera.cpp b/src/osg/Camera.cpp index 6a1306628..de5eab0a8 100644 --- a/src/osg/Camera.cpp +++ b/src/osg/Camera.cpp @@ -92,13 +92,13 @@ void Camera::copy(const Camera& camera) _useFarClippingPlane = camera._useFarClippingPlane; // cached matrix and clipping volume derived from above settings. - _dirty = camera._dirty; - _projectionMatrix = camera._projectionMatrix; - _modelViewMatrix = camera._modelViewMatrix; - _clippingVolume = camera._clippingVolume; + _dirty = false;// camera._dirty; + _projectionMatrix = NULL; //camera._projectionMatrix; + _modelViewMatrix = NULL; camera._modelViewMatrix; +// _clippingVolume = camera._clippingVolume; - _mp = camera._mp; - _inversemp = camera._inversemp; + _mp = NULL; + _inversemp = NULL; _useEyeOffset = camera._useEyeOffset; _eyeOffset = camera._eyeOffset; diff --git a/src/osgGLUT/Viewer.cpp b/src/osgGLUT/Viewer.cpp index 229a34d64..a761b3331 100644 --- a/src/osgGLUT/Viewer.cpp +++ b/src/osgGLUT/Viewer.cpp @@ -1031,12 +1031,12 @@ void Viewer::keyboard(unsigned char key, int x, int y) return; } - osg::ref_ptr LineSegment = new osg::LineSegment; - LineSegment->set(near_point,far_point); - osg::notify(osg::NOTICE) << "start("<start()<<") end("<end()<<")"<< std::endl; + osg::ref_ptr lineSegment = new osg::LineSegment; + lineSegment->set(near_point,far_point); + osg::notify(osg::NOTICE) << "start("<start()<<") end("<end()<<")"<< std::endl; osgUtil::IntersectVisitor iv; - iv.addLineSegment(LineSegment.get()); + iv.addLineSegment(lineSegment.get()); float startTime = clockSeconds(); @@ -1048,7 +1048,7 @@ void Viewer::keyboard(unsigned char key, int x, int y) if (iv.hits()) { - osgUtil::IntersectVisitor::HitList& hitList = iv.getHitList(LineSegment.get()); + osgUtil::IntersectVisitor::HitList& hitList = iv.getHitList(lineSegment.get()); for(osgUtil::IntersectVisitor::HitList::iterator hitr=hitList.begin(); hitr!=hitList.end(); ++hitr) diff --git a/src/osgUtil/SceneView.cpp b/src/osgUtil/SceneView.cpp index 04b9256d6..0a5b4e39e 100644 --- a/src/osgUtil/SceneView.cpp +++ b/src/osgUtil/SceneView.cpp @@ -279,6 +279,7 @@ void SceneView::cull() } camera->setNearFar(_near_plane,_far_plane); + _camera->setNearFar(_near_plane,_far_plane); } }