]> Creatis software - cpPlugins.git/blobdiff - lib/cpPlugins/DataObject.h
Windows compilation is broken.
[cpPlugins.git] / lib / cpPlugins / DataObject.h
index 279fe761858eb9f30a4de49c830c8594cc7ea3cf..9ff55d8a0cee67db4090c5694e67ea88de329ad4 100644 (file)
@@ -2,11 +2,15 @@
 #define __CPPLUGINS__DATAOBJECT__H__
 
 #include <cpPlugins/Object.h>
+#include <set>
+#include <vtkProp.h>
+#include <vtkRenderer.h>
 
 namespace cpPlugins
 {
   // Some forward declarations
   class ProcessObject;
+  class DataObjectVisualizationQtDialog;
 
   /**
    */
@@ -24,6 +28,15 @@ namespace cpPlugins
     itkTypeMacro( DataObject, Object );
     cpPlugins_Id_Macro( DataObject, Object );
 
+    struct TDataView
+    {
+      vtkSmartPointer< vtkProp >     Actor;
+      vtkSmartPointer< vtkRenderer > Renderer;
+      bool operator<( const TDataView& b ) const
+        { return( this->Actor.GetPointer( ) < b.Actor.GetPointer( ) ); }
+    };
+    typedef std::set< TDataView > TDataViews;
+
   public:
     ProcessObject* GetSource( );
     const ProcessObject* GetSource( ) const;
@@ -31,6 +44,18 @@ namespace cpPlugins
 
     void DisconnectFromPipeline( );
 
+    // Qt dialog creation
+    virtual DataObjectVisualizationQtDialog* CreateQtDialog( );
+
+    // VTK actors
+    virtual void AddVTKActor( vtkProp* actor, vtkRenderer* renderer );
+    virtual void ClearVTKActors( );
+    virtual void RenderVTKActors( );
+    TDataViews::iterator BeginVTKActors( );
+    TDataViews::iterator EndVTKActors( );
+    TDataViews::const_iterator BeginVTKActors( ) const;
+    TDataViews::const_iterator EndVTKActors( ) const;
+
   protected:
     DataObject( );
     virtual ~DataObject( );
@@ -42,6 +67,7 @@ namespace cpPlugins
 
   protected:
     ProcessObject* m_Source;
+    TDataViews     m_Actors;
   };
 
 } // ecapseman