);
// Connect actions to slots
+ this->connect(
+ this->m_UI->ActionBackgroundMPR, SIGNAL( triggered( ) ),
+ this, SLOT( _ActionBackgroundMPR( ) )
+ );
+ this->connect(
+ this->m_UI->ActionBackground3D, SIGNAL( triggered( ) ),
+ this, SLOT( _ActionBackground3D( ) )
+ );
this->connect(
this->m_UI->ButtonLoadPluginsFile, SIGNAL( clicked( ) ),
this, SLOT( _InteractiveLoadPlugins( ) )
delete this->m_UI;
}
+// -------------------------------------------------------------------------
+void PipelineEditor::
+_ActionBackgroundMPR( )
+{
+ this->_BackgroundProperties( 4 );
+}
+
+// -------------------------------------------------------------------------
+void PipelineEditor::
+_ActionBackground3D( )
+{
+ this->_BackgroundProperties( 3 );
+}
+
// -------------------------------------------------------------------------
void PipelineEditor::
_ShowFilterOutput(
const std::string& filter_name, const std::string& output_name
)
{
- // Update filter, if needed
this->_ExecFilter( filter_name );
-
- // Get output
- auto output = this->m_Workspace.GetOutput( filter_name, output_name );
- if( output == NULL )
- {
- QMessageBox::critical(
- this,
- QMessageBox::tr( "Error showing data" ),
- QMessageBox::tr( "Unknown port name." )
- );
- return;
-
- } // fi
-
- // Create and associate actor
- this->_Block( );
- this->m_UI->Viewer->AddActor( output->GetVTKActor( ) );
- this->_UnBlock( );
+ this->_ShowData( filter_name, output_name );
}
// -------------------------------------------------------------------------
const std::string& filter_name, const std::string& output_name
)
{
- // Get output
- /* TODO
- auto filter = this->m_Workspace.GetFilter( filter_name );
- if( filter != NULL )
- {
- auto output = filter->GetOutputData( output_name );
- if( output != NULL )
- {
- std::string data_name = output_name + "@" + filter_name;
- this->m_UI->Viewer->HideData( data_name );
-
- } // fi
-
- } // fi
- */
+ this->_HideData( filter_name, output_name );
}
// -------------------------------------------------------------------------
const std::string& filter_name, const std::string& output_name
)
{
- /* TODO
- auto filter = this->m_Workspace.GetFilter( filter_name );
- if( filter != NULL )
- {
- auto output = filter->GetOutputData< vtkPolyData >( output_name );
- if( output != NULL )
- {
- auto actor = this->m_UI->Viewer->GetActor( output );
- if( actor != NULL )
- {
- cpExtensions::QT::PropertyWidget* wdg =
- new cpExtensions::QT::PropertyWidget( NULL );
- wdg->SetProp( actor );
- wdg->SetRenderWindow(
- this->m_UI->Viewer->GetInteractor( 3 )->GetRenderWindow( )
- );
- wdg->show( );
-
- } // fi
- }
- else
- QMessageBox::critical(
- this,
- QMessageBox::tr( "Error showing data" ),
- QMessageBox::tr( "No known VTK conversion!" )
- );
-
- } // fi
- */
+ this->_DataProperties( filter_name, output_name );
}
// eof - $RCSfile$