Show
Ignore:
Timestamp:
10/04/07 19:11:34 (1 year ago)
Author:
cneumann
Message:

Work in progress commit.

NOTE: it does NOT compile at this point.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/Carsten_PtrWork/Source/Contrib/Manipulators/OSGManipulatorBase.h

    r864 r965  
    104104 
    105105    /*==========================  PUBLIC  =================================*/ 
    106  
    107106  public: 
    108107 
     
    164163 
    165164    /*---------------------------------------------------------------------*/ 
    166     /*! \name                    Class Get                                 */ 
     165    /*! \name Class Get                                                    */ 
    167166    /*! \{                                                                 */ 
    168167 
     
    173172    /*! \}                                                                 */ 
    174173    /*---------------------------------------------------------------------*/ 
    175     /*! \name                FieldContainer Get                            */ 
     174    /*! \name FieldContainer Get                                           */ 
    176175    /*! \{                                                                 */ 
    177176 
     
    183182    /*! \}                                                                 */ 
    184183    /*---------------------------------------------------------------------*/ 
    185     /*! \name                    Field Get                                 */ 
    186     /*! \{                                                                 */ 
    187  
    188             const SFNodePtr           *getSFTarget          (void) const; 
    189             const SFNodePtr           *getSFActiveSubHandle (void) const; 
    190             const SFViewportPtr       *getSFViewport        (void) const; 
    191  
     184    /*! \name Field SFTarget                                               */ 
     185    /*! \{                                                                 */ 
     186     
     187            SFNodePtr const *getSFTarget(void) const; 
     188            NodePtrConst getTarget(void) const; 
     189     
     190            void setTarget(NodePtrConstArg value); 
     191     
     192    /*! \}                                                                 */ 
     193    /*---------------------------------------------------------------------*/ 
     194    /*! \name Field SFActiveSubHandle                                      */ 
     195    /*! \{                                                                 */ 
     196     
     197            SFNodePtr const *getSFActiveSubHandle(void) const; 
     198            NodePtrConst getActiveSubHandle(void) const; 
     199     
     200            void setActiveSubHandle(NodePtrConstArg value); 
     201     
     202    /*! \}                                                                 */ 
     203    /*---------------------------------------------------------------------*/ 
     204    /*! \name Field SFViewport                                             */ 
     205    /*! \{                                                                 */ 
     206     
     207            SFViewportPtr const *getSFViewport(void) const; 
     208            ViewportPtrConst getViewport(void) const; 
     209     
     210            void setViewport(ViewportPtrConstArg value); 
     211     
     212    /*! \}                                                                 */ 
     213    /*---------------------------------------------------------------------*/ 
     214    /*! \name Field SFActive                                               */ 
     215    /*! \{                                                                 */ 
     216     
     217            SFBool       *editSFActive(void); 
     218            SFBool const *getSFActive (void) const; 
    192219#ifdef OSG_1_GET_COMPAT 
    193                   SFBool              *getSFActive          (void); 
    194 #endif 
    195                   SFBool              *editSFActive         (void); 
    196             const SFBool              *getSFActive          (void) const; 
    197  
     220            SFBool       *getSFActive (void); 
     221#endif 
     222            bool       &editActive(void); 
     223            bool const &getActive (void) const; 
    198224#ifdef OSG_1_GET_COMPAT 
    199                   SFVec3f             *getSFLength          (void); 
    200 #endif 
    201                   SFVec3f             *editSFLength         (void); 
    202             const SFVec3f             *getSFLength          (void) const; 
    203             const SFNodePtr           *getSFHandleXNode     (void) const; 
    204             const SFNodePtr           *getSFHandleYNode     (void) const; 
    205             const SFNodePtr           *getSFHandleZNode     (void) const; 
    206             const SFNodePtr           *getSFTransXNode      (void) const; 
    207             const SFNodePtr           *getSFTransYNode      (void) const; 
    208             const SFNodePtr           *getSFTransZNode      (void) const; 
    209             const SFMaterialPtr       *getSFMaterialX       (void) const; 
    210             const SFMaterialPtr       *getSFMaterialY       (void) const; 
    211             const SFMaterialPtr       *getSFMaterialZ       (void) const; 
    212             const SFNodePtr           *getSFAxisLinesN      (void) const; 
    213  
    214  
    215                   NodePtrConst getTarget         (void) const; 
    216  
    217                   NodePtrConst getActiveSubHandle(void) const; 
    218  
    219                   ViewportPtrConst getViewport       (void) const; 
    220  
     225            bool       &getActive (void); 
     226#endif 
     227            void setActive(bool const &value); 
     228     
     229    /*! \}                                                                 */ 
     230    /*---------------------------------------------------------------------*/ 
     231    /*! \name Field SFLength                                               */ 
     232    /*! \{                                                                 */ 
     233     
     234            SFVec3f       *editSFLength(void); 
     235            SFVec3f const *getSFLength (void) const; 
    221236#ifdef OSG_1_GET_COMPAT 
    222                   bool                &getActive          (void); 
    223 #endif 
    224                   bool                &editActive         (void); 
    225             const bool                &getActive          (void) const; 
    226  
     237            SFVec3f       *getSFLength (void); 
     238#endif 
     239            Vec3f       &editLength(void); 
     240            Vec3f const &getLength (void) const; 
    227241#ifdef OSG_1_GET_COMPAT 
    228                   Vec3f               &getLength          (void); 
    229 #endif 
    230                   Vec3f               &editLength         (void); 
    231             const Vec3f               &getLength          (void) const; 
    232  
    233                   NodePtrConst getHandleXNode    (void) const; 
    234  
    235                   NodePtrConst getHandleYNode    (void) const; 
    236  
    237                   NodePtrConst getHandleZNode    (void) const; 
    238  
    239                   NodePtrConst getTransXNode     (void) const; 
    240  
    241                   NodePtrConst getTransYNode     (void) const; 
    242  
    243                   NodePtrConst getTransZNode     (void) const; 
    244  
    245                   MaterialPtrConst getMaterialX      (void) const; 
    246  
    247                   MaterialPtrConst getMaterialY      (void) const; 
    248  
    249                   MaterialPtrConst getMaterialZ      (void) const; 
    250  
    251                   NodePtrConst getAxisLinesN     (void) const; 
    252  
    253     /*! \}                                                                 */ 
    254     /*---------------------------------------------------------------------*/ 
    255     /*! \name                    Field Set                                 */ 
    256     /*! \{                                                                 */ 
    257  
    258             void setTarget         (NodePtrConstArg value); 
    259             void setActiveSubHandle(NodePtrConstArg value); 
    260             void setViewport       (ViewportPtrConstArg value); 
    261             void setActive         (const bool &value); 
    262             void setLength         (const Vec3f &value); 
    263             void setHandleXNode    (NodePtrConstArg value); 
    264             void setHandleYNode    (NodePtrConstArg value); 
    265             void setHandleZNode    (NodePtrConstArg value); 
    266             void setTransXNode     (NodePtrConstArg value); 
    267             void setTransYNode     (NodePtrConstArg value); 
    268             void setTransZNode     (NodePtrConstArg value); 
    269             void setMaterialX      (MaterialPtrConstArg value); 
    270             void setMaterialY      (MaterialPtrConstArg value); 
    271             void setMaterialZ      (MaterialPtrConstArg value); 
    272             void setAxisLinesN     (NodePtrConstArg value); 
    273  
    274     /*! \}                                                                 */ 
    275     /*---------------------------------------------------------------------*/ 
    276     /*! \name                Ptr Field Set                                 */ 
    277     /*! \{                                                                 */ 
    278  
    279     /*! \}                                                                 */ 
    280     /*---------------------------------------------------------------------*/ 
    281     /*! \name                Ptr MField Set                                */ 
    282     /*! \{                                                                 */ 
    283  
    284     /*! \}                                                                 */ 
    285     /*---------------------------------------------------------------------*/ 
    286     /*! \name                   Binary Access                              */ 
     242            Vec3f       &getLength (void); 
     243#endif 
     244            void setLength(Vec3f const &value); 
     245     
     246    /*! \}                                                                 */ 
     247    /*---------------------------------------------------------------------*/ 
     248    /*! \name Field SFHandleXNode                                          */ 
     249    /*! \{                                                                 */ 
     250     
     251            SFNodePtr const *getSFHandleXNode(void) const; 
     252            NodePtrConst getHandleXNode(void) const; 
     253     
     254            void setHandleXNode(NodePtrConstArg value); 
     255     
     256    /*! \}                                                                 */ 
     257    /*---------------------------------------------------------------------*/ 
     258    /*! \name Field SFHandleYNode                                          */ 
     259    /*! \{                                                                 */ 
     260     
     261            SFNodePtr const *getSFHandleYNode(void) const; 
     262            NodePtrConst getHandleYNode(void) const; 
     263     
     264            void setHandleYNode(NodePtrConstArg value); 
     265     
     266    /*! \}                                                                 */ 
     267    /*---------------------------------------------------------------------*/ 
     268    /*! \name Field SFHandleZNode                                          */ 
     269    /*! \{                                                                 */ 
     270     
     271            SFNodePtr const *getSFHandleZNode(void) const; 
     272            NodePtrConst getHandleZNode(void) const; 
     273     
     274            void setHandleZNode(NodePtrConstArg value); 
     275     
     276    /*! \}                                                                 */ 
     277    /*---------------------------------------------------------------------*/ 
     278    /*! \name Field SFTransXNode                                           */ 
     279    /*! \{                                                                 */ 
     280     
     281            SFNodePtr const *getSFTransXNode(void) const; 
     282            NodePtrConst getTransXNode(void) const; 
     283     
     284            void setTransXNode(NodePtrConstArg value); 
     285     
     286    /*! \}                                                                 */ 
     287    /*---------------------------------------------------------------------*/ 
     288    /*! \name Field SFTransYNode                                           */ 
     289    /*! \{                                                                 */ 
     290     
     291            SFNodePtr const *getSFTransYNode(void) const; 
     292            NodePtrConst getTransYNode(void) const; 
     293     
     294            void setTransYNode(NodePtrConstArg value); 
     295     
     296    /*! \}                                                                 */ 
     297    /*---------------------------------------------------------------------*/ 
     298    /*! \name Field SFTransZNode                                           */ 
     299    /*! \{                                                                 */ 
     300     
     301            SFNodePtr const *getSFTransZNode(void) const; 
     302            NodePtrConst getTransZNode(void) const; 
     303     
     304            void setTransZNode(NodePtrConstArg value); 
     305     
     306    /*! \}                                                                 */ 
     307    /*---------------------------------------------------------------------*/ 
     308    /*! \name Field SFMaterialX                                            */ 
     309    /*! \{                                                                 */ 
     310     
     311            SFMaterialPtr const *getSFMaterialX(void) const; 
     312            MaterialPtrConst getMaterialX(void) const; 
     313     
     314            void setMaterialX(MaterialPtrConstArg value); 
     315     
     316    /*! \}                                                                 */ 
     317    /*---------------------------------------------------------------------*/ 
     318    /*! \name Field SFMaterialY                                            */ 
     319    /*! \{                                                                 */ 
     320     
     321            SFMaterialPtr const *getSFMaterialY(void) const; 
     322            MaterialPtrConst getMaterialY(void) const; 
     323     
     324            void setMaterialY(MaterialPtrConstArg value); 
     325     
     326    /*! \}                                                                 */ 
     327    /*---------------------------------------------------------------------*/ 
     328    /*! \name Field SFMaterialZ                                            */ 
     329    /*! \{                                                                 */ 
     330     
     331            SFMaterialPtr const *getSFMaterialZ(void) const; 
     332            MaterialPtrConst getMaterialZ(void) const; 
     333     
     334            void setMaterialZ(MaterialPtrConstArg value); 
     335     
     336    /*! \}                                                                 */ 
     337    /*---------------------------------------------------------------------*/ 
     338    /*! \name Field SFAxisLinesN                                           */ 
     339    /*! \{                                                                 */ 
     340     
     341            SFNodePtr const *getSFAxisLinesN(void) const; 
     342            NodePtrConst getAxisLinesN(void) const; 
     343     
     344            void setAxisLinesN(NodePtrConstArg value); 
     345     
     346    /*! \}                                                                 */ 
     347     
     348    /*---------------------------------------------------------------------*/ 
     349    /*! \name Binary Access                                                */ 
    287350    /*! \{                                                                 */ 
    288351 
     
    293356                               ConstFieldMaskArg  whichField); 
    294357 
    295  
    296358    /*! \}                                                                 */ 
    297359    /*=========================  PROTECTED  ===============================*/ 
    298  
    299360  protected: 
    300361 
     
    305366 
    306367    /*---------------------------------------------------------------------*/ 
    307     /*! \name                      Fields                                  */ 
     368    /*! \name Fields                                                       */ 
    308369    /*! \{                                                                 */ 
    309370 
     
    327388    /*! \}                                                                 */ 
    328389    /*---------------------------------------------------------------------*/ 
    329     /*! \name                   Constructors                               */ 
     390    /*! \name Constructors                                                 */ 
    330391    /*! \{                                                                 */ 
    331392 
     
    335396    /*! \}                                                                 */ 
    336397    /*---------------------------------------------------------------------*/ 
    337     /*! \name                   Destructors                                */ 
     398    /*! \name Destructors                                                  */ 
    338399    /*! \{                                                                 */ 
    339400 
     
    342403    /*! \}                                                                 */ 
    343404    /*---------------------------------------------------------------------*/ 
    344     /*! \name                     onCreate                                */ 
     405    /*! \name onCreate                                                     */ 
    345406    /*! \{                                                                 */ 
    346407 
     
    349410    /*! \}                                                                 */ 
    350411    /*---------------------------------------------------------------------*/ 
    351     /*! \name                    Generic Field Access                      */ 
     412    /*! \name Generic Field Access                                         */ 
    352413    /*! \{                                                                 */ 
    353414 
     
    387448    /*! \}                                                                 */ 
    388449    /*---------------------------------------------------------------------*/ 
    389     /*! \name                    Field Get                                 */ 
    390     /*! \{                                                                 */ 
    391  
    392  
     450    /*! \name Field SFLastMousePos                                         */ 
     451    /*! \{                                                                 */ 
     452     
     453            SFPnt2f       *editSFLastMousePos(void); 
     454            SFPnt2f const *getSFLastMousePos (void) const; 
    393455#ifdef OSG_1_GET_COMPAT 
    394                   SFPnt2f             *getSFLastMousePos    (void); 
    395 #endif 
    396                   SFPnt2f             *editSFLastMousePos   (void); 
    397             const SFPnt2f             *getSFLastMousePos    (void) const; 
    398  
    399  
     456            SFPnt2f       *getSFLastMousePos (void); 
     457#endif 
     458            Pnt2f       &editLastMousePos(void); 
     459            Pnt2f const &getLastMousePos (void) const; 
    400460#ifdef OSG_1_GET_COMPAT 
    401                   Pnt2f               &getLastMousePos    (void); 
    402 #endif 
    403                   Pnt2f               &editLastMousePos   (void); 
    404             const Pnt2f               &getLastMousePos    (void) const; 
    405  
    406     /*! \}                                                                 */ 
    407     /*---------------------------------------------------------------------*/ 
    408     /*! \name                    Field Set                                 */ 
    409     /*! \{                                                                 */ 
    410  
    411             void setLastMousePos   (const Pnt2f &value); 
    412  
    413     /*! \}                                                                 */ 
    414     /*---------------------------------------------------------------------*/ 
    415     /*! \name                Ptr MField Set                                */ 
    416     /*! \{                                                                 */ 
    417  
    418  
    419     /*! \}                                                                 */ 
    420     /*---------------------------------------------------------------------*/ 
    421     /*! \name                       Sync                                   */ 
     461            Pnt2f       &getLastMousePos (void); 
     462#endif 
     463            void setLastMousePos(Pnt2f const &value); 
     464     
     465    /*! \}                                                                 */ 
     466     
     467    /*! \}                                                                 */ 
     468    /*---------------------------------------------------------------------*/ 
     469    /*! \name Sync                                                         */ 
    422470    /*! \{                                                                 */ 
    423471 
     
    438486    /*! \}                                                                 */ 
    439487    /*---------------------------------------------------------------------*/ 
    440     /*! \name                       Edit                                   */ 
    441     /*! \{                                                                 */ 
    442  
    443     /*! \}                                                                 */ 
    444     /*---------------------------------------------------------------------*/ 
    445     /*! \name                     Aspect Create                            */ 
    446     /*! \{                                                                 */ 
    447  
    448     /*! \}                                                                 */ 
    449     /*---------------------------------------------------------------------*/ 
    450     /*! \name                       Edit                                   */ 
    451     /*! \{                                                                 */ 
    452     /*! \}                                                                 */ 
    453     /*---------------------------------------------------------------------*/ 
    454     /*! \name                       Sync                                   */ 
     488    /*! \name Aspect Create                                                */ 
     489    /*! \{                                                                 */ 
     490     
     491    /*! \}                                                                 */ 
     492    /*---------------------------------------------------------------------*/ 
     493    /*! \name Sync                                                         */ 
    455494    /*! \{                                                                 */ 
    456495 
     
    459498    /*! \}                                                                 */ 
    460499    /*==========================  PRIVATE  ================================*/ 
    461  
    462500  private: 
    463501 
     
    469507 
    470508/** Type specific RefPtr type for Manipulator. */ 
    471 typedef RefPtr<ManipulatorPtr> ManipulatorRefPtr; 
     509typedef RefPtr<Manipulator>   ManipulatorRefPtr; 
     510typedef MTRefPtr<Manipulator> ManipulatorMTRefPtr; 
     511 
     512typedef InternalRefPtr<Manipulator>       ManipulatorInternalRefPtr; 
     513typedef InternalRefPtr<Manipulator> const ManipulatorInternalRefPtrConst; 
     514typedef InternalRefPtr<Manipulator> const ManipulatorInternalRefPtrConstArg; 
    472515 
    473516typedef boost::mpl::if_<