Medical Imaging Interaction Toolkit
2016.11.0
Medical Imaging Interaction Toolkit
|
#include <mitkLabeledImageLookupTable.h>
Public Types | |
typedef unsigned char | LabelType |
Public Types inherited from mitk::LookupTable | |
enum | LookupTableType { GRAYSCALE, INVERSE_GRAYSCALE, HOT_IRON, JET, JET_TRANSPARENT, LEGACY_BINARY, LEGACY_RAINBOW_COLOR, MULTILABEL, PET_COLOR, PET_20 } |
The LookupTableType enum for different predefined lookup tables. More... | |
typedef unsigned char | RawLookupTableType |
RawLookupTableType raw lookuptable typedef for convenience. More... | |
typedef LookupTable | Self |
typedef itk::DataObject | Superclass |
typedef itk::SmartPointer< Self > | Pointer |
typedef itk::SmartPointer< const Self > | ConstPointer |
Public Member Functions | |
mitkClassMacro (LabeledImageLookupTable, LookupTable) | |
Pointer | Clone () const |
LabeledImageLookupTable & | operator= (const LookupTable &other) override |
implementation necessary because operator made private in itk::Object More... | |
virtual void | SetColorForLabel (const LabelType &label, const double &r, const double &g, const double &b, const double a=1.0) |
virtual double * | GetColorForLabel (const LabelType &label) |
mitk::LevelWindow | GetLevelWindow () |
Public Member Functions inherited from mitk::LookupTable | |
virtual std::vector< std::string > | GetClassHierarchy () const |
virtual const char * | GetClassName () const |
Pointer | Clone () const |
virtual vtkSmartPointer< vtkLookupTable > | GetVtkLookupTable () const |
GetVtkLookupTable Getter for the internally wrapped vtkLookupTable. More... | |
virtual RawLookupTableType * | GetRawLookupTable () const |
GetRawLookupTable Getter for the raw lookuptable array. More... | |
virtual void | SetVtkLookupTable (vtkSmartPointer< vtkLookupTable > lut) |
SetVtkLookupTable Setter for the internal lookuptable. More... | |
virtual void | ChangeOpacityForAll (float opacity) |
ChangeOpacityForAll Set the opacity for all table values. More... | |
virtual void | ChangeOpacity (int index, float opacity) |
ChangeOpacity Set the opacity for a specific table index. More... | |
virtual void | GetColor (double value, double rgb[3]) |
GetColor convenience method wrapping the vtkLookupTable::GetColor() method. More... | |
virtual void | GetTableValue (int index, double rgba[4]) |
GetTableValue convenience method wrapping the vtkLookupTable::GetTableValue() method. More... | |
virtual void | SetTableValue (int index, double rgba[4]) |
SetTableValue convenience method wrapping the vtkLookupTable::SetTableValue() method. More... | |
virtual void | SetWindow (float _arg) |
virtual void | SetLevel (float _arg) |
virtual void | SetOpacity (float _arg) |
virtual bool | operator== (const mitk::LookupTable &LookupTable) const |
equality operator implementation More... | |
virtual bool | operator!= (const LookupTable &LookupTable) const |
non equality operator implementation More... | |
virtual void | UpdateOutputInformation () override |
virtual void | SetRequestedRegionToLargestPossibleRegion () override |
virtual bool | RequestedRegionIsOutsideOfTheBufferedRegion () override |
virtual bool | VerifyRequestedRegion () override |
virtual void | SetRequestedRegion (const itk::DataObject *data) override |
LookupTable () | |
virtual | ~LookupTable () |
void | CreateColorTransferFunction (vtkColorTransferFunction *&colorFunction) |
void | CreateOpacityTransferFunction (vtkPiecewiseFunction *&opacityFunction) |
void | CreateGradientTransferFunction (vtkPiecewiseFunction *&gradientFunction) |
vtkSmartPointer< vtkColorTransferFunction > | CreateColorTransferFunction () |
vtkSmartPointer< vtkPiecewiseFunction > | CreateOpacityTransferFunction () |
vtkSmartPointer< vtkPiecewiseFunction > | CreateGradientTransferFunction () |
virtual void | SetType (const LookupTableType type) |
Set the look-up table type by enum (or integer). More... | |
virtual void | SetType (const std::string &typeName) |
Set the look-up table type by string. More... | |
virtual const std::string | GetActiveTypeAsString () |
Return the current look-up table type as a string. More... | |
Static Public Member Functions | |
static Pointer | New () |
Static Public Member Functions inherited from mitk::LookupTable | |
static const char * | GetStaticNameOfClass () |
static Pointer | New () |
Protected Member Functions | |
LabeledImageLookupTable () | |
LabeledImageLookupTable (const LabeledImageLookupTable &other) | |
virtual | ~LabeledImageLookupTable () |
virtual void | GenerateRandomColor (double &r, double &g, double &b) |
virtual double | GenerateRandomNumber () |
Protected Member Functions inherited from mitk::LookupTable | |
void | PrintSelf (std::ostream &os, itk::Indent indent) const override |
LookupTable (const LookupTable &other) | |
virtual void | BuildGrayScaleLookupTable () |
virtual void | BuildLegacyBinaryLookupTable () |
virtual void | BuildLegacyRainbowColorLookupTable () |
virtual void | BuildInverseGrayScaleLookupTable () |
virtual void | BuildHotIronLookupTable () |
virtual void | BuildJetLookupTable (bool transparent=false) |
virtual void | BuildPETColorLookupTable () |
virtual void | BuildPET20LookupTable () |
virtual void | BuildMultiLabelLookupTable () |
Protected Attributes | |
mitk::LevelWindow | m_LevelWindow |
Protected Attributes inherited from mitk::LookupTable | |
vtkSmartPointer< vtkLookupTable > | m_LookupTable |
float | m_Window |
float | m_Level |
float | m_Opacity |
LookupTableType | m_type |
Additional Inherited Members | |
Static Public Attributes inherited from mitk::LookupTable | |
static const char *const | typenameList [] |
A lookup table for 2D mapping of labeled images. The lookup table supports images with up to 256 unsigned labels. Negative labels are not supported. Please use the level/window settings as given by the GetLevelWindow() method to make sure, that the colors are rendered correctly. The colors are initialized with random colors as default. As background the label 0 is assumed. The color for the background is set to fully transparent as default.
Definition at line 37 of file mitkLabeledImageLookupTable.h.
typedef unsigned char mitk::LabeledImageLookupTable::LabelType |
The data type for a label. Currently only images with labels in the range [0,255] are supported.
Definition at line 54 of file mitkLabeledImageLookupTable.h.
|
protected |
Default constructor. Protected to prevent "normal" creation
Definition at line 24 of file mitkLabeledImageLookupTable.cpp.
References GenerateRandomColor(), m_LevelWindow, mitk::LookupTable::m_LookupTable, mitk::New(), mitk::LevelWindow::SetFixed(), mitk::LevelWindow::SetRangeMinMax(), and mitk::LevelWindow::SetWindowBounds().
|
protected |
Definition at line 58 of file mitkLabeledImageLookupTable.cpp.
|
protectedvirtual |
Virtual destructor
Definition at line 66 of file mitkLabeledImageLookupTable.cpp.
Pointer mitk::LabeledImageLookupTable::Clone | ( | ) | const |
|
protectedvirtual |
Generates a random rgb color value. Values for rgb are in the range [0,1]
Definition at line 122 of file mitkLabeledImageLookupTable.cpp.
Referenced by LabeledImageLookupTable().
|
protectedvirtual |
Generates a radnom number drawn from a uniform distribution in the range [0,1].
Definition at line 133 of file mitkLabeledImageLookupTable.cpp.
|
virtual |
Determines the color which will be used for coloring a given label.
label | the label for which the color should be returned |
Determines the color which will be used for coloring a given label.
label | the label for which the color should be returned |
Definition at line 108 of file mitkLabeledImageLookupTable.cpp.
|
inline |
Provides access to level window settings, which should be used in combination with the LUTs generated by this filter (at lease for 2D visualization. If you use other level/window settings, it is not guaranteed, that scalar values are mapped to the correct colors.
Definition at line 83 of file mitkLabeledImageLookupTable.h.
mitk::LabeledImageLookupTable::mitkClassMacro | ( | LabeledImageLookupTable | , |
LookupTable | |||
) |
Standard mitk typedefs are generated by the mitkClassMacro
|
static |
Make this object constructable by the New() Method.
|
overridevirtual |
implementation necessary because operator made private in itk::Object
assignment operator implementation
Reimplemented from mitk::LookupTable.
Definition at line 70 of file mitkLabeledImageLookupTable.cpp.
References mitk::LookupTable::operator=().
|
virtual |
Sets the color for a given label
label | The pixel value used as a label in the image |
r | The red component of the rgba color value. Values sould be given in the range [0,1] |
g | The green component of the rgba color value. Values sould be given in the range [0,1] |
b | The blue component of the rgba color value. Values sould be given in the range [0,1] |
a | The alpha component of the rgba color value. Values sould be given in the range [0,1]. Default is 1. |
Definition at line 88 of file mitkLabeledImageLookupTable.cpp.
|
protected |
Definition at line 108 of file mitkLabeledImageLookupTable.h.
Referenced by LabeledImageLookupTable().