]> Creatis software - cpPlugins.git/blob - lib/cpPlugins/Plugins/BasicFilters/InputDataReproducer.cxx
...
[cpPlugins.git] / lib / cpPlugins / Plugins / BasicFilters / InputDataReproducer.cxx
1 #include "InputDataReproducer.h"
2
3 #include <cpPlugins/Interface/Image.h>
4 #include <cpPlugins/Interface/PointList.h>
5
6 // -------------------------------------------------------------------------
7 cpPlugins::BasicFilters::InputDataReproducer::
8 InputDataReproducer( )
9   : Superclass( )
10 {
11   this->_AddInput( "Input" );
12   this->_AddOutput< cpPlugins::Interface::DataObject >( "Output" );
13   this->m_Parameters->Clear( );
14 }
15
16 // -------------------------------------------------------------------------
17 cpPlugins::BasicFilters::InputDataReproducer::
18 ~InputDataReproducer( )
19 {
20 }
21
22 // -------------------------------------------------------------------------
23 std::string cpPlugins::BasicFilters::InputDataReproducer::
24 _GenerateData( )
25 {
26   auto i = this->m_Inputs.find( "Input" );
27   auto o = this->m_Outputs.find( "Output" );
28   if( i == this->m_Inputs.end( ) || o == this->m_Outputs.end( ) )
29     return( "InputDataReproducer: No input/output ports." );
30   o->second->SetITK( i->second->GetITK< itk::LightObject >( ) );
31   o->second->SetVTK( i->second->GetVTK< vtkObjectBase >( ) );
32   return( "" );
33 }
34
35 // eof - $RCSfile$