Show
Ignore:
Timestamp:
12/09/03 15:07:44 (11 years ago)
Author:
robert
Message:

Removed osg::Transform::ComputeTransformCallback? from osg::Transform.

Updated various dependant files to reimplemt callbacks as Transform subclasses.

Files:
1 modified

Legend:

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

    r2233 r2517  
    197197 
    198198 
    199 struct MoveEarthySkyWithEyePointCallback : public osg::Transform::ComputeTransformCallback 
    200 { 
     199class MoveEarthySkyWithEyePointTransform : public osg::Transform 
     200{ 
     201public: 
    201202    /** Get the transformation matrix which moves from local coords to world coords.*/ 
    202     virtual bool computeLocalToWorldMatrix(osg::Matrix& matrix,const osg::Transform*, osg::NodeVisitor* nv) const  
     203    virtual bool computeLocalToWorldMatrix(osg::Matrix& matrix,osg::NodeVisitor* nv) const  
    203204    { 
    204205        osgUtil::CullVisitor* cv = dynamic_cast<osgUtil::CullVisitor*>(nv); 
     
    212213 
    213214    /** Get the transformation matrix which moves from world coords to local coords.*/ 
    214     virtual bool computeWorldToLocalMatrix(osg::Matrix& matrix,const osg::Transform*, osg::NodeVisitor* nv) const 
     215    virtual bool computeWorldToLocalMatrix(osg::Matrix& matrix,osg::NodeVisitor* nv) const 
    215216    { 
    216217        osgUtil::CullVisitor* cv = dynamic_cast<osgUtil::CullVisitor*>(nv); 
     
    263264 
    264265 
    265     osg::Transform* transform = new osg::Transform; 
     266    osg::Transform* transform = new MoveEarthySkyWithEyePointTransform; 
    266267    transform->setCullingActive(false); 
    267     transform->setComputeTransformCallback(new MoveEarthySkyWithEyePointCallback); 
    268268    transform->addChild(geode); 
    269269