]> Creatis software - cpPlugins.git/commitdiff
...
authorLeonardo Florez-Valencia <florez-l@javeriana.edu.co>
Mon, 28 Mar 2016 18:01:16 +0000 (13:01 -0500)
committerLeonardo Florez-Valencia <florez-l@javeriana.edu.co>
Mon, 28 Mar 2016 18:01:16 +0000 (13:01 -0500)
lib/cpExtensions/QT/SimpleMPRWidget.cxx
lib/cpExtensions/Visualization/IndexesToPolyData.h [new file with mode: 0644]
lib/cpExtensions/Visualization/IndexesToPolyData.hxx [new file with mode: 0644]
lib/cpPlugins_ITKInstances/Base_explicit_description.txt
lib/cpPlugins_ITKInstances/ImageFilters_explicit_description.txt
lib/cpPlugins_ITKInstances/ImageIterators_explicit_description.txt
lib/cpPlugins_ITKInstances/Image_explicit_description.txt
lib/cpPlugins_ITKInstances/Mesh_explicit_description.txt
plugins/cpPluginsVisualization/IndexesToPolyData.cxx [new file with mode: 0644]
plugins/cpPluginsVisualization/IndexesToPolyData.h [new file with mode: 0644]

index 62b92961f849085c0d37804565a73641544f6d4b..98c8191b40fb0887795454bcfb29ba2aec1bfb21 100644 (file)
@@ -541,6 +541,7 @@ Configure( vtkPolyData* pd )
     range[ 0 ], ( ( range[ 1 ] - range[ 0 ] ) * 0.75 ) + range[ 0 ]
     );
   this->Actor->SetMapper( this->Mapper );
+  this->Actor->GetProperty( )->SetPointSize( 10 );
   this->Actor->DeferLODConstructionOff( );
 }
 
diff --git a/lib/cpExtensions/Visualization/IndexesToPolyData.h b/lib/cpExtensions/Visualization/IndexesToPolyData.h
new file mode 100644 (file)
index 0000000..0dde70c
--- /dev/null
@@ -0,0 +1,71 @@
+#ifndef __CPEXTENSIONS__VISUALIZATION__INDEXESTOPOLYDATA__H__
+#define __CPEXTENSIONS__VISUALIZATION__INDEXESTOPOLYDATA__H__
+
+#include <vtkPolyDataAlgorithm.h>
+#include <itkImageBase.h>
+
+namespace cpExtensions
+{
+  namespace Visualization
+  {
+    /**
+     */
+    template< class _TIndexes >
+    class IndexesToPolyData
+      : public vtkPolyDataAlgorithm
+    {
+    public:
+      typedef IndexesToPolyData Self;
+
+      typedef _TIndexes TIndexes;
+      typedef typename TIndexes::ComponentType TContainer;
+      typedef typename TContainer::value_type  TIndex;
+      typedef itk::ImageBase< TIndex::Dimension > TImage;
+
+    public:
+      vtkTypeMacro( IndexesToPolyData, vtkPolyDataAlgorithm );
+
+    public:
+      static Self* New( );
+
+      const TIndexes* GetInput( ) const;
+      const TImage* GetReferenceImage( ) const;
+      void SetInput( const TIndexes* indexes );
+      void SetReferenceImage( const TImage* i );
+
+    protected:
+      IndexesToPolyData( );
+      virtual ~IndexesToPolyData( );
+
+      int RequestData(
+        vtkInformation* information,
+        vtkInformationVector** input,
+        vtkInformationVector* output
+        );
+      int RequestInformation(
+        vtkInformation* information,
+        vtkInformationVector** input,
+        vtkInformationVector* output
+        );
+
+    private:
+      // Purposely not implemented
+      IndexesToPolyData( const Self& );
+      void operator=( const Self& );
+
+    protected:
+      const TIndexes* m_Indexes;
+      const TImage*   m_ReferenceImage;
+    };
+
+  } // ecapseman
+
+} // ecapseman
+
+#ifndef ITK_MANUAL_INSTANTIATION
+#include <cpExtensions/Visualization/IndexesToPolyData.hxx>
+#endif // ITK_MANUAL_INSTANTIATION
+
+#endif //  __CPEXTENSIONS__VISUALIZATION__INDEXESTOPOLYDATA__H__
+
+// eof - $RCSfile$
diff --git a/lib/cpExtensions/Visualization/IndexesToPolyData.hxx b/lib/cpExtensions/Visualization/IndexesToPolyData.hxx
new file mode 100644 (file)
index 0000000..3e6f00d
--- /dev/null
@@ -0,0 +1,188 @@
+#ifndef __CPEXTENSIONS__VISUALIZATION__INDEXESTOPOLYDATA__HXX__
+#define __CPEXTENSIONS__VISUALIZATION__INDEXESTOPOLYDATA__HXX__
+
+#include <vtkInformation.h>
+#include <vtkInformationVector.h>
+
+// -------------------------------------------------------------------------
+template< class _TIndexes >
+typename cpExtensions::Visualization::IndexesToPolyData< _TIndexes >::
+Self* cpExtensions::Visualization::IndexesToPolyData< _TIndexes >::
+New( )
+{
+  return( new Self( ) );
+}
+
+// -------------------------------------------------------------------------
+template< class _TIndexes >
+const typename cpExtensions::Visualization::IndexesToPolyData< _TIndexes >::
+TIndexes* cpExtensions::Visualization::IndexesToPolyData< _TIndexes >::
+GetInput( ) const
+{
+  return( this->m_Indexes );
+}
+
+// -------------------------------------------------------------------------
+template< class _TIndexes >
+const typename cpExtensions::Visualization::IndexesToPolyData< _TIndexes >::
+TImage* cpExtensions::Visualization::IndexesToPolyData< _TIndexes >::
+GetReferenceImage( ) const
+{
+  return( this->m_ReferenceImage );
+}
+
+// -------------------------------------------------------------------------
+template< class _TIndexes >
+void cpExtensions::Visualization::IndexesToPolyData< _TIndexes >::
+SetInput( const TIndexes* indexes )
+{
+  if( this->m_Indexes != indexes )
+  {
+    this->m_Indexes = indexes;
+    this->Modified( );
+
+  } // fi
+}
+
+// -------------------------------------------------------------------------
+template< class _TIndexes >
+void cpExtensions::Visualization::IndexesToPolyData< _TIndexes >::
+SetReferenceImage( const TImage* i )
+{
+  if( this->m_ReferenceImage != i )
+  {
+    this->m_ReferenceImage = i;
+    this->Modified( );
+
+  } // fi
+}
+
+// -------------------------------------------------------------------------
+template< class _TIndexes >
+cpExtensions::Visualization::IndexesToPolyData< _TIndexes >::
+IndexesToPolyData( )
+  : vtkPolyDataAlgorithm( ),
+    m_Indexes( NULL ),
+    m_ReferenceImage( NULL )
+{
+  this->SetNumberOfInputPorts( 0 );
+}
+
+// -------------------------------------------------------------------------
+template< class _TIndexes >
+cpExtensions::Visualization::IndexesToPolyData< _TIndexes >::
+~IndexesToPolyData( )
+{
+}
+
+// -------------------------------------------------------------------------
+template< class _TIndexes >
+int cpExtensions::Visualization::IndexesToPolyData< _TIndexes >::
+RequestData(
+  vtkInformation* information,
+  vtkInformationVector** input,
+  vtkInformationVector* output
+  )
+{
+  static const unsigned int dim = TIndex::Dimension;
+
+  if( this->m_Indexes == NULL )
+    return( 0 );
+
+  // Get output
+  vtkInformation* info = output->GetInformationObject( 0 );
+  vtkPolyData* out = vtkPolyData::SafeDownCast(
+    info->Get( vtkDataObject::DATA_OBJECT( ) )
+    );
+
+  // Get input data
+  auto& lst = this->m_Indexes->Get( );
+
+  // Prepare points
+  vtkPoints* points = out->GetPoints( );
+  if( points == NULL )
+  {
+    points = vtkPoints::New( );
+    out->SetPoints( points );
+    points->Delete( );
+
+  } // fi
+  points->SetNumberOfPoints( lst.size( ) );
+
+  // Prepare cells
+  vtkSmartPointer< vtkCellArray > verts =
+    vtkSmartPointer< vtkCellArray >::New( );
+
+  for( unsigned int i = 0; i < lst.size( ); ++i )
+  {
+    auto idx = lst[ i ];
+    if( this->m_ReferenceImage != NULL )
+    {
+      typename TImage::PointType pnt;
+      this->m_ReferenceImage->TransformIndexToPhysicalPoint( idx, pnt );
+      if( dim == 1 )
+        points->SetPoint( i, pnt[ 0 ], 0, 0 );
+      else if( dim == 2 )
+        points->SetPoint( i, pnt[ 0 ], pnt[ 1 ], 0 );
+      else
+        points->SetPoint( i, pnt[ 0 ], pnt[ 1 ], pnt[ 2 ] );
+    }
+    else
+    {
+      if( dim == 1 )
+        points->SetPoint( i, idx[ 0 ], 0, 0 );
+      else if( dim == 2 )
+        points->SetPoint( i, idx[ 0 ], idx[ 1 ], 0 );
+      else
+        points->SetPoint( i, idx[ 0 ], idx[ 1 ], idx[ 2 ] );
+
+    } // fi
+    verts->InsertNextCell( 1 );
+    verts->InsertCellPoint( i );
+
+  } // rof
+  out->SetPoints( points );
+  out->SetVerts( verts );
+  return( 1 );
+}
+
+// -------------------------------------------------------------------------
+template< class _TIndexes >
+int
+cpExtensions::Visualization::IndexesToPolyData< _TIndexes >::
+RequestInformation(
+  vtkInformation* information,
+  vtkInformationVector** input,
+  vtkInformationVector* output
+  )
+{
+  vtkInformation* info = output->GetInformationObject( 0 );
+  /* TODO
+     info->Set(
+     vtkStreamingDemandDrivenPipeline::MAXIMUM_NUMBER_OF_PIECES( ), -1
+     );
+  */
+
+  if( this->m_Indexes != NULL && this->m_ReferenceImage != NULL )
+  {
+    /* TODO
+       typename C::TScalar len = this->m_RGC->GetTotalLength( );
+       typename C::TScalar s0 = this->m_RGC->Gets0( );
+       typename C::TPoint p0 = this->m_RGC->Axis( s0 );
+       typename C::TPoint p1 = this->m_RGC->Axis( s0 + len );
+
+       info->Set(
+       vtkStreamingDemandDrivenPipeline::WHOLE_BOUNDING_BOX( ),
+       double( p0[ 0 ] ), double( p1[ 0 ] ),
+       double( p0[ 1 ] ), double( p1[ 1 ] ),
+       double( p0[ 2 ] ), double( p1[ 2 ] )
+       );
+    */
+
+  } // fi
+  return( 1 );
+}
+
+#endif //  __CPEXTENSIONS__VISUALIZATION__INDEXESTOPOLYDATA__HXX__
+
+// eof - $RCSfile$
index f4874e7351f14c38940cc1de743e3fe4f241f88d..6bb63dd36af7a76b38e8c444296d18bd6255f0a6 100644 (file)
@@ -20,8 +20,7 @@ c itk::FixedArray< #1 , #2 >
 c itk::Point< #5 , #2 >
 c itk::Vector< #5 , #2 >
 c itk::Matrix< #5 , #2 , #2 >
-c itk::RGBPixel< #1 >
-c itk::RGBAPixel< #1 >
+c #7 < #1 >
 c itk::SimpleDataObjectDecorator< #1 >
 c itk::SimpleDataObjectDecorator< #3 >
 c itk::SimpleDataObjectDecorator< std::vector< itk::Index< #6 > > >
@@ -29,16 +28,14 @@ c itk::SimpleDataObjectDecorator< std::vector< itk::Point< #5 , #6 > > >
 c itk::SimpleDataObjectDecorator< itk::Array< #1 > >
 c itk::ConvertPixelBuffer< #1 , #4 , itk::DefaultConvertPixelTraits< #4 > >
 c itk::ConvertPixelBuffer< #1 , std::complex< #5 > , itk::DefaultConvertPixelTraits< std::complex< #5 > > >
-c itk::ConvertPixelBuffer< #1 , itk::RGBPixel< #4 > , itk::DefaultConvertPixelTraits< itk::RGBPixel< #4 > > >
-c itk::ConvertPixelBuffer< #1 , itk::RGBAPixel< #4 > , itk::DefaultConvertPixelTraits< itk::RGBAPixel< #4 > > >
+c itk::ConvertPixelBuffer< #1 , #7 < #4 > , itk::DefaultConvertPixelTraits< #7 < #4 > > >
 c itk::ImportImageContainer< unsigned long , #1 >
 c itk::ImportImageContainer< unsigned long , std::complex< #5 > >
-c itk::ImportImageContainer< unsigned long , itk::RGBPixel< #1 > >
-c itk::ImportImageContainer< unsigned long , itk::RGBAPixel< #1 > >
-c itk::SimpleDataObjectDecorator< std::map< itk::Index< #6 >, std::pair< itk::Index< #6 >, short >, itk::Functor::IndexLexicographicCompare< #6 > > >
+c itk::ImportImageContainer< unsigned long , #7 < #1 > >
 a #1 = #integers;#floats
 a #2 = #all_dims
 a #3 = bool;std::string
 a #4 = #integers;#floats
 a #5 = #floats
 a #6 = #all_visual_dims
+a #7 = itk::RGBPixel;itk::RGBAPixel
index dae6d97f864e32977f8972184b25ed1ed4b92da1..73d0c8ea6bd8e0e42782c775918146ba992a2a21 100644 (file)
@@ -5,8 +5,7 @@ i itkInPlaceImageFilter.h
 i itkImageTransformer.h
 c itk::ImageSource< itk::Image< #1 , #2 > >
 c itk::ImageSource< itk::Image< std::complex< #3 > , #2 > >
-c itk::ImageSource< itk::Image< itk::RGBPixel< #1 > , #2 > >
-c itk::ImageSource< itk::Image< itk::RGBAPixel< #1 > , #2 > >
+c itk::ImageSource< itk::Image< #5 < #1 > , #2 > >
 c itk::ImageToImageFilter< itk::Image< #1 , #2 > , itk::Image< #4 , #2 > >
 c itk::InPlaceImageFilter< itk::Image< #1 , #2 > , itk::Image< #4 , #2 > >
 c itk::ImageTransformer< itk::Image< #1 , #2 > >
@@ -14,3 +13,4 @@ a #1 = #integers;#floats
 a #2 = #all_dims
 a #3 = #floats
 a #4 = #integers;#floats
+a #5 = itk::RGBPixel;itk::RGBAPixel
index 7221e6760985e0a0dd0451cc6f7fb791e579eefb..90d5cdc653fcd97292f1e2bb4b9ffda5ecc5e796 100644 (file)
@@ -5,44 +5,18 @@ i itkImageLinearConstIteratorWithIndex.h
 i itkImageLinearIteratorWithIndex.h
 i itkImageRegionConstIterator.h
 i itkImageRegionIterator.h
+i itkImageRegionConstIteratorWithIndex.h
+i itkImageRegionIteratorWithIndex.h
 i itkImageScanlineConstIterator.h
 i itkImageScanlineIterator.h
 i itkConstNeighborhoodIterator.h
 i itkNeighborhoodIterator.h
 i itkConstShapedNeighborhoodIterator.h
 i itkShapedNeighborhoodIterator.h
-c itk::ImageRegionConstIterator< itk::Image< #1 , #2 > >
-c itk::ImageRegionConstIterator< itk::Image< std::complex< #3 >, #2 > >
-c itk::ImageRegionConstIterator< itk::Image< itk::RGBPixel< #1 > , #2 > >
-c itk::ImageRegionConstIterator< itk::Image< itk::RGBAPixel< #1 > , #2 > >
-c itk::ImageRegionIterator< itk::Image< #1 , #2 > >
-c itk::ImageRegionIterator< itk::Image< std::complex< #3 > , #2 > >
-c itk::ImageRegionIterator< itk::Image< itk::RGBPixel< #1 > , #2 > >
-c itk::ImageRegionIterator< itk::Image< itk::RGBAPixel< #1 > , #2 > >
-c itk::ImageConstIteratorWithIndex< itk::Image< #1 , #2 > >
-c itk::ImageConstIteratorWithIndex< itk::Image< std::complex< #3 > , #2 > >
-c itk::ImageConstIteratorWithIndex< itk::Image< itk::RGBPixel< #1 > , #2 > >
-c itk::ImageConstIteratorWithIndex< itk::Image< itk::RGBAPixel< #1 > , #2 > >
-c itk::ImageIteratorWithIndex< itk::Image< #1 , #2 > >
-c itk::ImageIteratorWithIndex< itk::Image< std::complex< #3 > , #2 > >
-c itk::ImageIteratorWithIndex< itk::Image< itk::RGBPixel< #1 > , #2 > >
-c itk::ImageIteratorWithIndex< itk::Image< itk::RGBAPixel< #1 > , #2 > >
-c itk::ImageLinearConstIteratorWithIndex< itk::Image< #1 , #2 > >
-c itk::ImageLinearConstIteratorWithIndex< itk::Image< std::complex< #3 > , #2 > >
-c itk::ImageLinearConstIteratorWithIndex< itk::Image< itk::RGBPixel< #1 > , #2 > >
-c itk::ImageLinearConstIteratorWithIndex< itk::Image< itk::RGBAPixel< #1 > , #2 > >
-c itk::ImageLinearIteratorWithIndex< itk::Image< #1 , #2 > >
-c itk::ImageLinearIteratorWithIndex< itk::Image< std::complex< #3 > , #2 > >
-c itk::ImageLinearIteratorWithIndex< itk::Image< itk::RGBPixel< #1 > , #2 > >
-c itk::ImageLinearIteratorWithIndex< itk::Image< itk::RGBAPixel< #1 > , #2 > >
-c itk::ImageScanlineConstIterator< itk::Image< #1 , #2 > >
-c itk::ImageScanlineConstIterator< itk::Image< std::complex< #3 > , #2 > >
-c itk::ImageScanlineConstIterator< itk::Image< itk::RGBPixel< #1 > , #2 > >
-c itk::ImageScanlineConstIterator< itk::Image< itk::RGBAPixel< #1 > , #2 > >
-c itk::ImageScanlineIterator< itk::Image< #1 , #2 > >
-c itk::ImageScanlineIterator< itk::Image< std::complex< #3 > , #2 > >
-c itk::ImageScanlineIterator< itk::Image< itk::RGBPixel< #1 > , #2 > >
-c itk::ImageScanlineIterator< itk::Image< itk::RGBAPixel< #1 > , #2 > >
+c #5 < itk::Image< #1 , #2 > >
+c #5 < itk::Image< std::complex< #3 >, #2 > >
+c #5 < itk::Image< itk::RGBPixel< #1 > , #2 > >
+c #5 < itk::Image< itk::RGBAPixel< #1 > , #2 > >
 c #4 < itk::Image< #1 , #2 >, itk::Image< #1 , #2 > >
 c itk::ConstNeighborhoodIterator< itk::Image< #1 , #2 >, #4 < itk::Image< #1 , #2 >, itk::Image< #1 , #2 > > >
 c itk::NeighborhoodIterator< itk::Image< #1 , #2 >, #4 < itk::Image< #1 , #2 >, itk::Image< #1 , #2 > > >
@@ -52,3 +26,4 @@ a #1 = #integers;#floats
 a #2 = #all_dims
 a #3 = #floats
 a #4 = itk::ZeroFluxNeumannBoundaryCondition
+a #5 = itk::ImageRegionConstIterator;itk::ImageRegionIterator;itk::ImageRegionConstIteratorWithIndex;itk::ImageRegionIteratorWithIndex;itk::ImageConstIteratorWithIndex;itk::ImageIteratorWithIndex;itk::ImageLinearConstIteratorWithIndex;itk::ImageLinearIteratorWithIndex;itk::ImageScanlineConstIterator;itk::ImageScanlineIterator
index 210e7bbe545b490bb46ce4e7553822b31d083597..7b1708d6971052aaf365e1217f46ae0f0fab1bde 100644 (file)
@@ -12,13 +12,12 @@ c itk::HistogramAlgorithmBase< itk::Statistics::Histogram< #1 > >
 c itk::ImageRegion< #2 >
 c itk::Image< #1 , #2 >
 c itk::Image< std::complex< #4 > , #2 >
-c itk::Image< itk::RGBPixel< #1 > , #2 >
-c itk::Image< itk::RGBAPixel< #1 > , #2 >
+c itk::Image< #6 < #1 > , #2 >
 c itk::ImageToVTKImageFilter< itk::Image< #1 , #3 > >
-c itk::ImageToVTKImageFilter< itk::Image< itk::RGBPixel< #1 > , #3 > >
-c itk::ImageToVTKImageFilter< itk::Image< itk::RGBAPixel< #1 > , #3 > >
+c itk::ImageToVTKImageFilter< itk::Image< #6 < #1 > , #3 > >
 a #1 = #integers;#floats
 a #2 = #all_dims
 a #3 = #all_visual_dims
 a #4 = #floats
 a #5 = #integers_ptr;#floats_ptr
+a #6 = itk::RGBPixel;itk::RGBAPixel
index 9acff0a3d0a76f055749b1ec541ad24beb33169b..d43489ea5363f4bb3c6b27fa7d14bbfb0b748275 100644 (file)
@@ -8,9 +8,9 @@ i itkTriangleCell.h
 c itk::VectorContainer< unsigned long, itk::Point< #1 , #2 > >
 c itk::MapContainer< unsigned long , itk::QuadEdgeMeshPoint< #1 , #2 , itk::GeometricalQuadEdge< unsigned long, unsigned long, bool, bool, true > > >
 c itk::PointSet< #1 , #2 >
-c itk::Mesh< #1 , #2 >
-c itk::QuadEdgeMesh< #1 , #2 >
+c #4 < #1 , #2 >
 c #3 < itk::CellInterface< #1 , itk::CellTraitsInfo< #2 , float , float , unsigned long , unsigned long , unsigned long , itk::Point< float , #2 > , itk::VectorContainer< unsigned long , itk::Point< float , #2 > > , std::set< unsigned long , std::less< unsigned long > , std::allocator< unsigned long > > > > >
 a #1 = #floats
 a #2 = #all_visual_dims
 a #3 = itk::LineCell;itk::PolygonCell;itk::TriangleCell
+a #4 = itk::Mesh;itk::QuadEdgeMesh
diff --git a/plugins/cpPluginsVisualization/IndexesToPolyData.cxx b/plugins/cpPluginsVisualization/IndexesToPolyData.cxx
new file mode 100644 (file)
index 0000000..9e4b65c
--- /dev/null
@@ -0,0 +1,65 @@
+#include <cpPluginsVisualization/IndexesToPolyData.h>
+#include <cpPlugins/Image.h>
+#include <cpPlugins/Mesh.h>
+
+#include <cpExtensions/Visualization/IndexesToPolyData.h>
+#include <cpExtensions/Visualization/IndexesToPolyData.hxx>
+
+// -------------------------------------------------------------------------
+cpPluginsVisualization::IndexesToPolyData::
+IndexesToPolyData( )
+  : Superclass( )
+{
+  this->_AddInput( "Input" );
+  this->_AddInput( "ReferenceImage", false );
+  this->_AddOutput< cpPlugins::Mesh >( "Output" );
+}
+
+// -------------------------------------------------------------------------
+cpPluginsVisualization::IndexesToPolyData::
+~IndexesToPolyData( )
+{
+}
+
+// -------------------------------------------------------------------------
+std::string cpPluginsVisualization::IndexesToPolyData::
+_GenerateData( )
+{
+  typedef itk::SimpleDataObjectDecorator< std::vector< itk::Index< 2 > > > _2D;
+  typedef itk::SimpleDataObjectDecorator< std::vector< itk::Index< 3 > > > _3D;
+
+  auto indexes = this->GetInputData( "Input" )->GetITK< itk::DataObject >( );
+  auto indexes2D = dynamic_cast< _2D* >( indexes );
+  auto indexes3D = dynamic_cast< _3D* >( indexes );
+  if( indexes2D != NULL )
+    return( this->_GD0( indexes2D ) );
+  else if( indexes3D != NULL )
+    return( this->_GD0( indexes3D ) );
+  else
+    return( "cpPluginsVisualization::IndexesToPolyData: no valid input." );
+}
+
+// -------------------------------------------------------------------------
+template< class _TIndexes >
+std::string cpPluginsVisualization::IndexesToPolyData::
+_GD0( _TIndexes* indexes )
+{
+  typedef
+    cpExtensions::Visualization::IndexesToPolyData< _TIndexes >
+    _TFilter;
+  typedef typename _TFilter::TImage _TImage;
+
+  // Configure filter
+  _TFilter* filter = this->_CreateVTK< _TFilter >( );
+  filter->SetInput( indexes );
+  filter->SetReferenceImage(
+    this->GetInputData( "Input" )->GetITK< _TImage >( )
+    );
+  filter->Update( );
+
+  // Connect output
+  this->GetOutputData( "Output" )->SetVTK( filter->GetOutput( ) );
+  return( "" );
+}
+
+// eof - $RCSfile$
diff --git a/plugins/cpPluginsVisualization/IndexesToPolyData.h b/plugins/cpPluginsVisualization/IndexesToPolyData.h
new file mode 100644 (file)
index 0000000..ac296b7
--- /dev/null
@@ -0,0 +1,44 @@
+#ifndef __CPPLUGINSVISUALIZATION__INDEXESTOPOLYDATA__H__
+#define __CPPLUGINSVISUALIZATION__INDEXESTOPOLYDATA__H__
+
+#include <plugins/cpPluginsVisualization/cpPluginsVisualization_Export.h>
+#include <cpPlugins/ProcessObject.h>
+
+namespace cpPluginsVisualization
+{
+  /**
+   */
+  class cpPluginsVisualization_EXPORT IndexesToPolyData
+    : public cpPlugins::ProcessObject
+  {
+  public:
+    typedef IndexesToPolyData               Self;
+    typedef cpPlugins::ProcessObject        Superclass;
+    typedef itk::SmartPointer< Self >       Pointer;
+    typedef itk::SmartPointer< const Self > ConstPointer;
+
+  public:
+    itkNewMacro( Self );
+    itkTypeMacro( IndexesToPolyData, cpPlugins::ProcessObject );
+    cpPlugins_Id_Macro( IndexesToPolyData, Visualization );
+
+  protected:
+    IndexesToPolyData( );
+    virtual ~IndexesToPolyData( );
+
+    virtual std::string _GenerateData( );
+
+    template< class _TIndexes >
+      inline std::string _GD0( _TIndexes* path );
+
+  private:
+    // Purposely not implemented
+    IndexesToPolyData( const Self& );
+    Self& operator=( const Self& );
+  };
+
+} // ecapseman
+
+#endif // __CPPLUGINSVISUALIZATION__INDEXESTOPOLYDATA__H__
+
+// eof - $RCSfile$