]> Creatis software - cpPlugins.git/blobdiff - lib/cpPlugins/Interface/ProcessObject.h
Widget integration (step 3/6). WARNING: IT DOES NOT COMPILE YET
[cpPlugins.git] / lib / cpPlugins / Interface / ProcessObject.h
index 51cf06742c0ccb72ce01c3d9d9c2cf97e4266055..2a9fc916e17045d4be9fffc5e177332056ade156 100644 (file)
@@ -15,7 +15,8 @@ typedef char QWidget
 
 #include <itkProcessObject.h>
 
-class vtkAlgorithm;
+#include <vtkSmartPointer.h>
+#include <vtkAlgorithm.h>
 
 namespace cpPlugins
 {
@@ -36,11 +37,6 @@ namespace cpPlugins
       itkTypeMacro( ProcessObject, Object );
 
     public:
-      virtual vtkAlgorithm* GetVTKAlgorithm( )
-      { return( NULL ); }
-      virtual const vtkAlgorithm* GetVTKAlgorithm( ) const
-      { return( NULL ); }
-
       virtual const Parameters& GetDefaultParameters( ) const;
       virtual void SetParameters( const Parameters& params );
 
@@ -57,6 +53,18 @@ namespace cpPlugins
 
       virtual bool ExecConfigurationDialog( QWidget* parent );
 
+      template< class T >
+        inline T* GetITK( );
+
+      template< class T >
+        inline const T* GetITK( ) const;
+
+      template< class T >
+        inline T* GetVTK( );
+
+      template< class T >
+        inline const T* GetVTK( ) const;
+
       template< class T >
         inline T* GetInput( unsigned int idx );
 
@@ -73,6 +81,12 @@ namespace cpPlugins
       ProcessObject( );
       virtual ~ProcessObject( );
 
+      template< class F >
+        inline F* _CreateITK( );
+
+      template< class F >
+        inline F* _CreateVTK( );
+
       template< class O >
         inline void _MakeOutput( unsigned int idx );
 
@@ -84,7 +98,9 @@ namespace cpPlugins
       Self& operator=( const Self& );
 
     protected:
-      itk::ProcessObject::Pointer m_RealProcessObject;
+      itk::ProcessObject::Pointer     m_ITKObject;
+      vtkSmartPointer< vtkAlgorithm > m_VTKObject;
+
       Parameters m_DefaultParameters;
       Parameters m_Parameters;