// Show outputs
for( auto oIt = outputs.begin( ); oIt != outputs.end( ); ++oIt )
- std::cout << *oIt << std::endl;
-
- /* TODO
- std::vector< std::string > outputs;
- std::string err = this->m_Plugins->UpdateActiveFilter( outputs );
- if( err == "" )
- {
- for( auto oIt = outputs.begin( ); oIt != outputs.end( ); ++oIt )
- {
- TPlugins::TImage* image = this->m_Plugins->GetImage( *oIt );
- if( image != NULL )
- {
- vtkImageData* vimage = image->GetVTK< vtkImageData >( );
- if( vimage != NULL )
- {
- this->m_UI->MPR->AddImage(
- vimage, *oIt, this->m_Plugins->GetParent( *oIt )
- );
- this->m_UI->MPR->ShowData( *oIt );
-
- } // fi
- continue;
-
- } // fi
-
- TPlugins::TMesh* mesh = this->m_Plugins->GetMesh( *oIt );
- if( mesh != NULL )
- {
- this->m_Plugins->BlockWidget( );
- this->m_UI->MPR->AddMesh(
- mesh->GetVTK< vtkPolyData >( ),
- *oIt,
- this->m_Plugins->GetParent( *oIt )
- );
- this->m_UI->MPR->ShowData( *oIt );
- this->m_Plugins->UnblockWidget( );
-
- } // fi
-
- } // rof
- }
- else
- {
- QMessageBox::critical(
- this,
- tr( "Error executing filter" ),
- tr( ( std::string( "Error caught: " ) + err ).c_str( ) )
- );
- return;
-
- } // fi
- */
+ {
+ std::string parent = this->m_Plugins.GetParent( *oIt );
+ TDataObject* dobj = this->m_Plugins.GetData< TDataObject >( *oIt );
+ if( this->m_UI->MPR->AddData( dobj, *oIt, parent ) )
+ this->m_UI->MPR->ShowData( *oIt );
+
+ } // rof
}
// -------------------------------------------------------------------------
return; \
TImage* image = this->m_Plugins.GetData< TImage >( name ); \
this->m_UI->MPR->AddData( image, name, "" ); \
+ this->m_UI->MPR->SetMainImage( name ); \
this->m_UI->MPR->ShowData( name ); \
} \
catch( std::exception& err ) \