]> Creatis software - cpPlugins.git/blobdiff - lib/cpExtensions/Visualization/MPRObjects.h
sphere widget done, finally
[cpPlugins.git] / lib / cpExtensions / Visualization / MPRObjects.h
index 1920bb71a952352efee6717cc3782e5e1e051aee..c21fca66f55e2fc36614e1442e502ad0c6af86a7 100644 (file)
@@ -19,12 +19,19 @@ namespace cpExtensions
     {
     public:
       typedef MPRObjects Self;
-      typedef cpExtensions::Visualization::MPRActors TMPRActors;
 
-      typedef TMPRActors::TCursorCommand     TCursorCommand;
-      typedef TMPRActors::TMouseCommand      TMouseCommand;
-      typedef TMPRActors::TMouseWheelCommand TMouseWheelCommand;
-      typedef TMPRActors::TKeyCommand        TKeyCommand;
+      typedef MPRActors::TStyle                   TStyle;
+      typedef MPRActors::TMouseCommand            TMouseCommand;
+      typedef MPRActors::TMouseWheelCommand       TMouseWheelCommand;
+      typedef MPRActors::TKeyCommand              TKeyCommand;
+      typedef MPRActors::TVoidCommand             TVoidCommand;
+      typedef MPRActors::TMouseMoveCommand        TMouseMoveCommand;
+      typedef MPRActors::TMouseClickCommand       TMouseClickCommand;
+      typedef MPRActors::TMouseDoubleClickCommand TMouseDoubleClickCommand;
+      typedef MPRActors::TExposeCommand           TExposeCommand;
+      typedef MPRActors::TConfigureCommand        TConfigureCommand;
+      typedef MPRActors::TEnterCommand            TEnterCommand;
+      typedef MPRActors::TLeaveCommand            TLeaveCommand;
 
     public:
       vtkTypeMacro( MPRObjects, vtkObject );
@@ -33,22 +40,18 @@ namespace cpExtensions
       // Creation
       static MPRObjects* New( );
 
-      void AddCursorCommand( TCursorCommand command, void* data )
-      {
-        this->m_MPRActors->AddCursorCommand( command, data );
-      }
-
       void SetRenderWindows(
         vtkRenderWindow* wx, vtkRenderWindow* wy,
         vtkRenderWindow* wz, vtkRenderWindow* w3D
         );
       void AddImage( vtkImageData* image );
+      unsigned int GetNumberOfImages( ) const;
       void ClearAll( );
 
       void ResetCamera( const int& id );
       void ResetCameras( );
-      void Render( const int& id );
-      void RenderAll( );
+      void Render( const int& id, const double& t );
+      void RenderAll( const double& t );
       vtkRenderer* GetXRenderer( );
       vtkRenderer* GetYRenderer( );
       vtkRenderer* GetZRenderer( );
@@ -58,17 +61,11 @@ namespace cpExtensions
       const vtkRenderer* GetZRenderer( ) const;
       const vtkRenderer* Get3DRenderer( ) const;
 
-      TMPRActors* GetMPRActors( );
-      const TMPRActors* GetMPRActors( ) const;
+      MPRActors* GetMPRActors( );
+      const MPRActors* GetMPRActors( ) const;
 
-      double GetWindow( ) const
-      {
-        return( this->m_MPRActors->GetWindow( ) );
-      }
-      double GetLevel( ) const
-      {
-        return( this->m_MPRActors->GetLevel( ) );
-      }
+      double GetWindow( ) const;
+      double GetLevel( ) const;
 
     protected:
       MPRObjects( );
@@ -84,15 +81,8 @@ namespace cpExtensions
       vtkSmartPointer< vtkRenderWindow > m_Windows[ 4 ];
 
       // Internal pipelines
-      vtkSmartPointer< TMPRActors >  m_MPRActors;
+      vtkSmartPointer< MPRActors >   m_MPRActors;
       vtkSmartPointer< vtkRenderer > m_Renderers[ 4 ];
-
-      std::vector< TCursorCommand >     CursorCommands;
-      std::vector< TMouseCommand >      MouseCommands;
-      std::vector< TMouseCommand >      MouseClickCommands;
-      std::vector< TMouseCommand >      MouseDoubleClickCommands;
-      std::vector< TMouseWheelCommand > MouseWheelCommands;
-      std::vector< TKeyCommand >        KeyCommands;
     };
 
   } // ecapseman