Medical Imaging Interaction Toolkit
2024.06.99-60d9b802
Medical Imaging Interaction Toolkit
|
The TransferFunction class A wrapper class for VTK scalar opacity, gradient opacity, and color transfer functions. More...
#include <mitkTransferFunction.h>
Public Types | |
typedef std::vector< std::pair< double, double > > | ControlPoints |
typedef std::vector< std::pair< double, itk::RGBPixel< double > > > | RGBControlPoints |
typedef TransferFunction | Self |
typedef itk::DataObject | Superclass |
typedef itk::SmartPointer< Self > | Pointer |
typedef itk::SmartPointer< const Self > | ConstPointer |
Public Member Functions | |
virtual std::vector< std::string > | GetClassHierarchy () const |
virtual const char * | GetClassName () const |
Pointer | Clone () const |
virtual void | SetMin (int _arg) |
Get/Set min/max of transfer function range for initialization. More... | |
virtual void | SetMax (int _arg) |
Get/Set min/max of transfer function range for initialization. More... | |
virtual int | GetMin () |
Get/Set min/max of transfer function range for initialization. More... | |
virtual int | GetMax () |
Get/Set min/max of transfer function range for initialization. More... | |
virtual vtkPiecewiseFunction * | GetScalarOpacityFunction () |
Get/Set wrapped vtk transfer function. More... | |
virtual vtkPiecewiseFunction * | GetGradientOpacityFunction () |
Get/Set wrapped vtk transfer function. More... | |
virtual vtkColorTransferFunction * | GetColorTransferFunction () |
Get/Set wrapped vtk transfer function. More... | |
virtual void | SetColorTransferFunction (vtkSmartPointer< vtkColorTransferFunction > _arg) |
virtual const HistogramGenerator::HistogramType * | GetHistogram () |
Get histogram used for transfer function initialization. More... | |
void | InitializeByMitkImage (const mitk::Image *image) |
Initialize transfer function based on the histogram of an mitk::Image. More... | |
void | InitializeByItkHistogram (const itk::Statistics::Histogram< double > *histogram) |
Initialize transfer function based on the specified histogram. More... | |
void | InitializeHistogram (const mitk::Image *image) |
Initialize the internal histogram and min/max range based on the specified mitk::Image. More... | |
void | SetScalarOpacityPoints (TransferFunction::ControlPoints points) |
Insert control points and values into the scalar opacity transfer function. More... | |
void | SetGradientOpacityPoints (TransferFunction::ControlPoints points) |
Insert control points and values into the gradient opacity transfer function. More... | |
void | SetRGBPoints (TransferFunction::RGBControlPoints rgbpoints) |
Insert control points and RGB values into the color transfer function. More... | |
void | AddScalarOpacityPoint (double x, double value) |
Add a single control point to the scalar opacity transfer function. More... | |
void | AddGradientOpacityPoint (double x, double value) |
Add a single control point to the gradient opacity transfer function. More... | |
void | AddRGBPoint (double x, double r, double g, double b) |
Add a single control point to the color opacity transfer function. More... | |
TransferFunction::ControlPoints & | GetScalarOpacityPoints () |
Get a copy of the scalar opacity transfer function control-points. More... | |
TransferFunction::ControlPoints & | GetGradientOpacityPoints () |
Get a copy of the gradient opacity transfer function control-points. More... | |
TransferFunction::RGBControlPoints & | GetRGBPoints () |
Get a copy of the color transfer function control-points. More... | |
int | RemoveScalarOpacityPoint (double x) |
Remove the specified control point from the scalar opacity transfer function. More... | |
int | RemoveGradientOpacityPoint (double x) |
Remove the specified control point from the gradient opacity transfer function. More... | |
int | RemoveRGBPoint (double x) |
Remove the specified control point from the color transfer function. More... | |
void | ClearScalarOpacityPoints () |
Removes all control points from the scalar opacity transfer function. More... | |
void | ClearGradientOpacityPoints () |
Removes all control points from the gradient opacity transfer function. More... | |
void | ClearRGBPoints () |
Removes all control points from the color transfer function. More... | |
bool | operator== (Self &other) |
Static Public Member Functions | |
static const char * | GetStaticNameOfClass () |
static Pointer | New () |
Protected Member Functions | |
TransferFunction () | |
~TransferFunction () override | |
TransferFunction (const TransferFunction &other) | |
itk::LightObject::Pointer | InternalClone () const override |
void | PrintSelf (std::ostream &os, itk::Indent indent) const override |
Protected Attributes | |
vtkSmartPointer< vtkPiecewiseFunction > | m_ScalarOpacityFunction |
vtkSmartPointer< vtkPiecewiseFunction > | m_GradientOpacityFunction |
vtkSmartPointer< vtkColorTransferFunction > | m_ColorTransferFunction |
int | m_Min |
int | m_Max |
mitk::HistogramGenerator::HistogramType::ConstPointer | m_Histogram |
The TransferFunction class A wrapper class for VTK scalar opacity, gradient opacity, and color transfer functions.
Holds a copy of each of the three standard VTK transfer functions (scalar opacity, gradient opacity, color) and provides an interface for manipulating their control points. Each original function can be retrieved by a Get() method.
Definition at line 55 of file mitkTransferFunction.h.
typedef itk::SmartPointer<const Self> mitk::TransferFunction::ConstPointer |
Definition at line 61 of file mitkTransferFunction.h.
typedef std::vector<std::pair<double, double> > mitk::TransferFunction::ControlPoints |
Definition at line 58 of file mitkTransferFunction.h.
Definition at line 61 of file mitkTransferFunction.h.
typedef std::vector<std::pair<double, itk::RGBPixel<double> > > mitk::TransferFunction::RGBControlPoints |
Definition at line 59 of file mitkTransferFunction.h.
Definition at line 61 of file mitkTransferFunction.h.
typedef itk::DataObject mitk::TransferFunction::Superclass |
Definition at line 61 of file mitkTransferFunction.h.
|
protected |
|
overrideprotected |
|
protected |
void mitk::TransferFunction::AddGradientOpacityPoint | ( | double | x, |
double | value | ||
) |
Add a single control point to the gradient opacity transfer function.
void mitk::TransferFunction::AddRGBPoint | ( | double | x, |
double | r, | ||
double | g, | ||
double | b | ||
) |
Add a single control point to the color opacity transfer function.
void mitk::TransferFunction::AddScalarOpacityPoint | ( | double | x, |
double | value | ||
) |
Add a single control point to the scalar opacity transfer function.
void mitk::TransferFunction::ClearGradientOpacityPoints | ( | ) |
Removes all control points from the gradient opacity transfer function.
void mitk::TransferFunction::ClearRGBPoints | ( | ) |
Removes all control points from the color transfer function.
void mitk::TransferFunction::ClearScalarOpacityPoints | ( | ) |
Removes all control points from the scalar opacity transfer function.
Pointer mitk::TransferFunction::Clone | ( | ) | const |
|
inlinevirtual |
Definition at line 61 of file mitkTransferFunction.h.
|
virtual |
|
virtual |
Get/Set wrapped vtk transfer function.
|
virtual |
Get/Set wrapped vtk transfer function.
TransferFunction::ControlPoints& mitk::TransferFunction::GetGradientOpacityPoints | ( | ) |
Get a copy of the gradient opacity transfer function control-points.
|
virtual |
Get histogram used for transfer function initialization.
|
virtual |
Get/Set min/max of transfer function range for initialization.
|
virtual |
Get/Set min/max of transfer function range for initialization.
TransferFunction::RGBControlPoints& mitk::TransferFunction::GetRGBPoints | ( | ) |
Get a copy of the color transfer function control-points.
|
virtual |
Get/Set wrapped vtk transfer function.
TransferFunction::ControlPoints& mitk::TransferFunction::GetScalarOpacityPoints | ( | ) |
Get a copy of the scalar opacity transfer function control-points.
|
inlinestatic |
Definition at line 61 of file mitkTransferFunction.h.
void mitk::TransferFunction::InitializeByItkHistogram | ( | const itk::Statistics::Histogram< double > * | histogram | ) |
Initialize transfer function based on the specified histogram.
void mitk::TransferFunction::InitializeByMitkImage | ( | const mitk::Image * | image | ) |
Initialize transfer function based on the histogram of an mitk::Image.
void mitk::TransferFunction::InitializeHistogram | ( | const mitk::Image * | image | ) |
Initialize the internal histogram and min/max range based on the specified mitk::Image.
|
overrideprotected |
|
static |
bool mitk::TransferFunction::operator== | ( | Self & | other | ) |
|
overrideprotected |
int mitk::TransferFunction::RemoveGradientOpacityPoint | ( | double | x | ) |
Remove the specified control point from the gradient opacity transfer function.
int mitk::TransferFunction::RemoveRGBPoint | ( | double | x | ) |
Remove the specified control point from the color transfer function.
int mitk::TransferFunction::RemoveScalarOpacityPoint | ( | double | x | ) |
Remove the specified control point from the scalar opacity transfer function.
|
virtual |
void mitk::TransferFunction::SetGradientOpacityPoints | ( | TransferFunction::ControlPoints | points | ) |
Insert control points and values into the gradient opacity transfer function.
|
virtual |
Get/Set min/max of transfer function range for initialization.
|
virtual |
Get/Set min/max of transfer function range for initialization.
void mitk::TransferFunction::SetRGBPoints | ( | TransferFunction::RGBControlPoints | rgbpoints | ) |
Insert control points and RGB values into the color transfer function.
void mitk::TransferFunction::SetScalarOpacityPoints | ( | TransferFunction::ControlPoints | points | ) |
Insert control points and values into the scalar opacity transfer function.
|
protected |
Wrapped VTK color transfer function
Definition at line 172 of file mitkTransferFunction.h.
|
protected |
Wrapped VTK gradient opacity transfer function
Definition at line 169 of file mitkTransferFunction.h.
|
protected |
Specified or calculated histogram (used for initialization)
Definition at line 181 of file mitkTransferFunction.h.
|
protected |
Current range of transfer function (used for initialization)
Definition at line 178 of file mitkTransferFunction.h.
|
protected |
Current range of transfer function (used for initialization)
Definition at line 175 of file mitkTransferFunction.h.
|
protected |
Wrapped VTK scalar opacity transfer function
Definition at line 166 of file mitkTransferFunction.h.