Show
Ignore:
Timestamp:
05/05/08 07:12:19 (3 months ago)
Author:
vossg
Message:

changed: interface cleanup, removed ptr typedefs, nullfc

these will be needed for the 1.x compat stuff

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/Source/System/Action/Base/OSGAction.h

    r1177 r1198  
    7171class Action; 
    7272 
    73 ActionBase::ResultE MultiCoreRenderEnter(const NodeCorePtr &pCore, 
    74                                                Action      *action); 
    75 ActionBase::ResultE MultiCoreRenderLeave(const NodeCorePtr &pCore, 
    76                                                Action      *action); 
     73ActionBase::ResultE MultiCoreRenderEnter(NodeCore * const &pCore, 
     74                                         Action           *action); 
     75ActionBase::ResultE MultiCoreRenderLeave(NodeCore * const &pCore, 
     76                                         Action           *action); 
    7777 
    7878//--------------------------------------------------------------------------- 
     
    9191    //----------------------------------------------------------------------- 
    9292 
    93     typedef boost::function<ResultE(const NodeCorePtr,  
    94                                           Action     *)> Functor; 
    95     typedef boost::function<ResultE(const NodePtr,    
    96                                           Action     *)> NodeFunctor;  
     93    typedef boost::function<ResultE(NodeCore * const,  
     94                                    Action   *      )> Functor; 
     95    typedef boost::function<ResultE(Node     * const,    
     96                                    Action   *      )> NodeFunctor;  
    9797 
    9898    typedef ActionBase::ResultE (NodeCore::*Callback)(Action *); 
     
    144144    // application 
    145145 
    146     virtual ResultE apply(      std::vector<NodePtr>::iterator begin,  
    147                                 std::vector<NodePtr>::iterator end  ); 
    148  
    149     virtual ResultE apply(const NodePtr                        node ); 
     146    virtual ResultE apply(std::vector<Node *>::iterator begin,  
     147                          std::vector<Node *>::iterator end  ); 
     148 
     149    virtual ResultE apply(Node * const                   node); 
    150150 
    151151    /*------------------------- your_category -------------------------------*/ 
     
    153153    // the node being traversed. Might be needed by the traversed core 
    154154     
    155     inline NodePtr getActNode( void ); 
     155    inline Node *getActNode( void ); 
    156156 
    157157    // the node being traversed. Might be needed by the traversed core 
     
    159159    // after the graph traversal 
    160160     
    161     void setActNode(const NodePtr node); 
     161    void setActNode(Node * const node); 
    162162 
    163163    /*------------------------- your_category -------------------------------*/ 
     
    170170    // you can access a single node by getNode 
    171171     
    172     NodePtr      getNode    (int             index); 
     172    Node        *getNode    (int             index); 
    173173     
    174174    // per default all child nodes are traversed. If addNode is called,  
    175175    // only the added nodes will be traversed. 
    176176     
    177     void         addNode    (const NodePtr node); 
     177    void         addNode    (Node * const node); 
    178178 
    179179    // Common case: going through the children list and picking up some of  
     
    192192 
    193193    // recurse through the node 
    194     ResultE recurse(const NodePtr node); 
     194    ResultE recurse(Node * const node); 
    195195 
    196196    /*------------------------- comparison ----------------------------------*/ 
     
    233233    // call the single node. used for cascading actions 
    234234     
    235     inline ResultE callEnter(const NodeCorePtr core);    
    236     inline ResultE callLeave(const NodeCorePtr core); 
     235    inline ResultE callEnter(NodeCore * const core);    
     236    inline ResultE callLeave(NodeCore * const core); 
    237237 
    238238    // start/stop functions for the action. 
     
    256256    // default function 
    257257     
    258     static ResultE _defaultEnterFunction(const NodeCorePtr node,  
    259                                                Action      *action); 
    260     static ResultE _defaultLeaveFunction(const NodeCorePtr node,  
    261                                                Action      *action); 
     258    static ResultE _defaultEnterFunction(NodeCore * const node,  
     259                                         Action   *       action); 
     260    static ResultE _defaultLeaveFunction(NodeCore * const node,  
     261                                         Action   *       action); 
    262262 
    263263    // functors 
     
    272272    //----------------------------------------------------------------------- 
    273273 
    274     NodePtr               _actNode;   // the node being traversed right now 
    275      
    276     std::vector<NodePtr> *_actList;  // list of active objects for this level 
     274    Node                 *_actNode;   // the node being traversed right now 
     275     
     276    std::vector<Node  *> *_actList;  // list of active objects for this level 
    277277                                     // if empty, use the actNode's children 
    278278 
    279279    bool                  _useNewList;// set by clearNodeList 
    280     std::vector<NodePtr>  _newList;   // list of active object for this level 
     280    std::vector<Node  *>  _newList;   // list of active object for this level 
    281281 
    282282    UInt32                _travMask; 
     
    346346 
    347347typedef boost::function< 
    348           Action::ResultE (const NodePtr        )> TraverseEnterFunctor; 
     348          Action::ResultE (Node * const   )> TraverseEnterFunctor; 
    349349typedef boost::function< 
    350           Action::ResultE (const NodePtr,  
    351                                  Action::ResultE)> TraverseLeaveFunctor; 
     350          Action::ResultE (Node * const,  
     351                           Action::ResultE)> TraverseLeaveFunctor; 
    352352 
    353353 
     
    363363 
    364364OSG_SYSTEM_DLLMAPPING 
    365 ActionBase::ResultE traverse(const NodePtr               root,  
     365ActionBase::ResultE traverse(      Node * const          root,  
    366366                                   TraverseEnterFunctor  func); 
    367367OSG_SYSTEM_DLLMAPPING 
    368 ActionBase::ResultE traverse(const std::vector<NodePtr> &nodeList,  
     368ActionBase::ResultE traverse(const std::vector<Node *> &nodeList,  
    369369                                   TraverseEnterFunctor  func); 
    370370 
     
    374374                             
    375375OSG_SYSTEM_DLLMAPPING 
    376 ActionBase::ResultE traverse(const NodePtr               root,  
     376ActionBase::ResultE traverse(      Node * const          root,  
    377377                                   TraverseEnterFunctor  enter,  
    378378                                   TraverseLeaveFunctor  leave); 
    379379OSG_SYSTEM_DLLMAPPING 
    380 ActionBase::ResultE traverse(const std::vector<NodePtr> &nodeList,  
     380ActionBase::ResultE traverse(const std::vector<Node *> &nodeList,  
    381381                                   TraverseEnterFunctor  enter,  
    382382                                   TraverseLeaveFunctor  leave);