ExtractSliceImageFilter( )
: Superclass( )
{
- this->_AddInput( "Input" );
- this->_MakeOutput< cpPlugins::Interface::Image >( "Output" );
+ this->_AddInput( "Input", true );
+ this->_AddOutput< cpPlugins::Interface::Image >( "Output" );
this->m_Parameters->ConfigureAsUint( "Axis" );
this->m_Parameters->ConfigureAsInt( "Slice" );
std::string cpPlugins::BasicFilters::ExtractSliceImageFilter::
_GenerateData( )
{
- cpPlugins::Interface::Image* image =
- this->GetInput< cpPlugins::Interface::Image >( "Input" );
+ auto image = this->GetInputData< cpPlugins::Interface::Image >( "Input" );
if( image == NULL )
return( "ExtractSliceImageFilter: No input image." );
filter->Update( );
// Connect output
- cpPlugins::Interface::Image* out =
- this->GetOutput< cpPlugins::Interface::Image >( "Output" );
+ auto out = this->GetOutputData< cpPlugins::Interface::Image >( "Output" );
if( out != NULL )
{
out->SetITK< O >( filter->GetOutput( ) );