-// -------------------------------------------------------------------------
-void cpExtensions::Visualization::ImageBlender::
-PrintSelf( std::ostream& os, vtkIndent indent )
-{
- this->Superclass::PrintSelf( os, indent );
-
- // Objects
- os << indent << "Colors: " << std::endl;
- auto i = this->m_Colors.begin( );
- for( ; i != this->m_Colors.end( ); ++i )
- os
- << indent << indent << i->first << " : ["
- << i->second.R << ", "
- << i->second.G << ", "
- << i->second.B << "]"
- << std::endl;
-}
-
-// -------------------------------------------------------------------------
-const double& cpExtensions::Visualization::ImageBlender::
-GetMaxWindow( ) const
-{
- return( this->m_MaxWindow );
-}
-
-// -------------------------------------------------------------------------
-const double& cpExtensions::Visualization::ImageBlender::
-GetMaxLevel( ) const
-{
- return( this->m_MaxLevel );
-}
-
-// -------------------------------------------------------------------------
-const double& cpExtensions::Visualization::ImageBlender::
-GetMinWindow( ) const
-{
- return( this->m_MinWindow );
-}
-
-// -------------------------------------------------------------------------
-const double& cpExtensions::Visualization::ImageBlender::
-GetMinLevel( ) const
-{
- return( this->m_MinLevel );
-}
-
-// -------------------------------------------------------------------------
-const double& cpExtensions::Visualization::ImageBlender::
-GetWindow( ) const
-{
- return( this->m_Window );
-}
-
-// -------------------------------------------------------------------------
-const double& cpExtensions::Visualization::ImageBlender::
-GetLevel( ) const
-{
- return( this->m_Level );
-}
-
-// -------------------------------------------------------------------------
-void cpExtensions::Visualization::ImageBlender::
-SetWindow( const double& w )
-{
- if( this->m_Window != w )
- {
- this->m_Window = w;
- this->Modified( );
-
- } // fi
-}
-
-// -------------------------------------------------------------------------
-void cpExtensions::Visualization::ImageBlender::
-SetLevel( const double& l )
-{
- if( this->m_Level != l )
- {
- this->m_Level = l;
- this->Modified( );
-
- } // fi
-}
-
-// -------------------------------------------------------------------------
-void cpExtensions::Visualization::ImageBlender::
-SetWindowLevel( const double& w, const double& l )
-{
- this->SetWindow( w );
- this->SetLevel( l );
-}
-
-// -------------------------------------------------------------------------
-void cpExtensions::Visualization::ImageBlender::
-GetColor(
- const unsigned int& i,
- double& r,
- double& g,
- double& b
- ) const
-{
- auto c = this->m_Colors.find( i );
- if( c != this->m_Colors.end( ) )
- {
- r = c->second.R;
- g = c->second.G;
- b = c->second.B;
- }
- else
- r = g = b = double( 1 );
-}
-
-// -------------------------------------------------------------------------
-void cpExtensions::Visualization::ImageBlender::
-SetColor(
- const unsigned int& i,
- const double& r,
- const double& g,
- const double& b
- )
-{
- this->m_Colors[ i ] = TColor( r, g, b );
- this->Modified( );
-}