Show
Ignore:
Timestamp:
02/28/06 20:36:18 (8 years ago)
Author:
robert
Message:

Further clean up of RefNodePath? references.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • OpenSceneGraph/trunk/examples/osgprerendercubemap/osgprerendercubemap.cpp

    r4713 r5020  
    1717#include <osg/CullFace> 
    1818#include <osg/Material> 
    19 #include <osg/RefNodePath> 
    2019#include <osg/PositionAttitudeTransform> 
    2120 
     
    8685} 
    8786 
    88 osg::RefNodePath createReflector() 
    89 { 
    90   ref_ptr<osg::PositionAttitudeTransform> pat = new osg::PositionAttitudeTransform; 
     87osg::NodePath createReflector() 
     88{ 
     89  osg::PositionAttitudeTransform* pat = new osg::PositionAttitudeTransform; 
    9190  pat->setPosition(osg::Vec3(0.0f,0.0f,0.0f)); 
    9291  pat->setAttitude(osg::Quat(osg::inDegrees(0.0f),osg::Vec3(0.0f,0.0f,1.0f))); 
    9392   
    94   ref_ptr<Geode> geode_1 = new Geode; 
    95   pat->addChild(geode_1.get()); 
     93  Geode* geode_1 = new Geode; 
     94  pat->addChild(geode_1); 
    9695 
    9796  const float radius = 0.8f; 
    9897  ref_ptr<TessellationHints> hints = new TessellationHints; 
    9998  hints->setDetailRatio(2.0f); 
    100   ref_ptr<ShapeDrawable> shape = new ShapeDrawable(new Sphere(Vec3(0.0f, 0.0f, 0.0f), radius * 1.5f), hints.get()); 
     99  ShapeDrawable* shape = new ShapeDrawable(new Sphere(Vec3(0.0f, 0.0f, 0.0f), radius * 1.5f), hints.get()); 
    101100  shape->setColor(Vec4(0.8f, 0.8f, 0.8f, 1.0f)); 
    102   geode_1->addDrawable(shape.get()); 
     101  geode_1->addDrawable(shape); 
    103102   
    104   osg::RefNodePath refNodeList; 
    105   refNodeList.push_back(pat.get()); 
    106   refNodeList.push_back(geode_1.get()); 
     103  osg::NodePath nodeList; 
     104  nodeList.push_back(pat); 
     105  nodeList.push_back(geode_1); 
    107106   
    108   return refNodeList; 
     107  return nodeList; 
    109108} 
    110109 
     
    115114        typedef std::vector< osg::ref_ptr<osg::CameraNode> >  CameraList; 
    116115 
    117         UpdateCameraAndTexGenCallback(osg::RefNodePath& reflectorNodePath, CameraList& cameraNodes): 
     116        UpdateCameraAndTexGenCallback(osg::NodePath& reflectorNodePath, CameraList& cameraNodes): 
    118117            _reflectorNodePath(reflectorNodePath), 
    119118            _cameraNodes(cameraNodes) 
     
    161160        virtual ~UpdateCameraAndTexGenCallback() {} 
    162161         
    163         osg::RefNodePath            _reflectorNodePath;         
     162        osg::NodePath               _reflectorNodePath;         
    164163        CameraList                  _cameraNodes; 
    165164}; 
     
    194193 
    195194 
    196 osg::Group* createShadowedScene(osg::Node* reflectedSubgraph, osg::RefNodePath reflectorNodePath, unsigned int unit, const osg::Vec4& clearColor, unsigned tex_width, unsigned tex_height, osg::CameraNode::RenderTargetImplementation renderImplementation) 
     195osg::Group* createShadowedScene(osg::Node* reflectedSubgraph, osg::NodePath reflectorNodePath, unsigned int unit, const osg::Vec4& clearColor, unsigned tex_width, unsigned tex_height, osg::CameraNode::RenderTargetImplementation renderImplementation) 
    197196{ 
    198197