Medical Imaging Interaction Toolkit
2016.11.0
Medical Imaging Interaction Toolkit
|
A data structure describing a label. More...
#include <mitkLabel.h>
Public Types | |
typedef unsigned short | PixelType |
Public Types inherited from mitk::PropertyList | |
typedef PropertyList | Self |
typedef itk::Object | Superclass |
typedef itk::SmartPointer< Self > | Pointer |
typedef itk::SmartPointer< const Self > | ConstPointer |
typedef std::map< std::string, BaseProperty::Pointer > | PropertyMap |
typedef std::pair< std::string, BaseProperty::Pointer > | PropertyMapElementType |
Public Member Functions | |
mitkClassMacro (Label, mitk::PropertyList) | |
void | SetLocked (bool locked) |
bool | GetLocked () const |
void | SetVisible (bool visible) |
bool | GetVisible () const |
void | SetOpacity (float opacity) |
float | GetOpacity () const |
void | SetName (const std::string &name) |
std::string | GetName () const |
void | SetCenterOfMassIndex (const mitk::Point3D ¢er) |
mitk::Point3D | GetCenterOfMassIndex () const |
void | SetCenterOfMassCoordinates (const mitk::Point3D ¢er) |
mitk::Point3D | GetCenterOfMassCoordinates () const |
void | SetColor (const mitk::Color &) |
const mitk::Color & | GetColor () const |
void | SetValue (PixelType pixelValue) |
PixelType | GetValue () const |
void | SetLayer (unsigned int layer) |
unsigned int | GetLayer () const |
void | SetProperty (const std::string &propertyKey, BaseProperty *property) |
void | Modified () |
Label () | |
virtual | ~Label () |
Public Member Functions inherited from mitk::PropertyList | |
virtual std::vector< std::string > | GetClassHierarchy () const |
virtual const char * | GetClassName () const |
Pointer | Clone () const |
mitk::BaseProperty * | GetProperty (const std::string &propertyKey) const |
Get a property by its name. More... | |
void | SetProperty (const std::string &propertyKey, BaseProperty *property) |
Set a property in the list/map by value. More... | |
void | ReplaceProperty (const std::string &propertyKey, BaseProperty *property) |
Set a property object in the list/map by reference. More... | |
void | ConcatenatePropertyList (PropertyList *pList, bool replace=false) |
Set a property object in the list/map by reference. More... | |
template<typename T > | |
bool | GetPropertyValue (const char *propertyKey, T &value) const |
Convenience access method for GenericProperty<T> properties (T being the type of the second parameter) More... | |
bool | GetBoolProperty (const char *propertyKey, bool &boolValue) const |
Convenience method to access the value of a BoolProperty. More... | |
bool | Get (const char *propertyKey, bool &boolValue) const |
ShortCut for the above method. More... | |
void | SetBoolProperty (const char *propertyKey, bool boolValue) |
Convenience method to set the value of a BoolProperty. More... | |
void | Set (const char *propertyKey, bool boolValue) |
ShortCut for the above method. More... | |
bool | GetIntProperty (const char *propertyKey, int &intValue) const |
Convenience method to access the value of an IntProperty. More... | |
bool | Get (const char *propertyKey, int &intValue) const |
ShortCut for the above method. More... | |
void | SetIntProperty (const char *propertyKey, int intValue) |
Convenience method to set the value of an IntProperty. More... | |
void | Set (const char *propertyKey, int intValue) |
ShortCut for the above method. More... | |
bool | GetFloatProperty (const char *propertyKey, float &floatValue) const |
Convenience method to access the value of a FloatProperty. More... | |
bool | Get (const char *propertyKey, float &floatValue) const |
ShortCut for the above method. More... | |
void | SetFloatProperty (const char *propertyKey, float floatValue) |
Convenience method to set the value of a FloatProperty. More... | |
void | Set (const char *propertyKey, float floatValue) |
ShortCut for the above method. More... | |
bool | GetDoubleProperty (const char *propertyKey, double &doubleValue) const |
Convenience method to access the value of a DoubleProperty. More... | |
bool | Get (const char *propertyKey, double &doubleValue) const |
ShortCut for the above method. More... | |
void | SetDoubleProperty (const char *propertyKey, double doubleValue) |
Convenience method to set the value of a DoubleProperty. More... | |
void | Set (const char *propertyKey, double doubleValue) |
ShortCut for the above method. More... | |
bool | GetStringProperty (const char *propertyKey, std::string &stringValue) const |
Convenience method to access the value of a StringProperty. More... | |
bool | Get (const char *propertyKey, std::string &stringValue) const |
ShortCut for the above method. More... | |
void | SetStringProperty (const char *propertyKey, const char *stringValue) |
Convenience method to set the value of a StringProperty. More... | |
void | Set (const char *propertyKey, const char *stringValue) |
ShortCut for the above method. More... | |
void | Set (const char *propertyKey, const std::string &stringValue) |
ShortCut for the above method. More... | |
virtual unsigned long | GetMTime () const override |
Get the timestamp of the last change of the map or the last change of one of the properties store in the list (whichever is later). More... | |
bool | DeleteProperty (const std::string &propertyKey) |
Remove a property from the list/map. More... | |
const PropertyMap * | GetMap () const |
bool | IsEmpty () const |
virtual void | Clear () |
Static Public Member Functions | |
static Pointer | New () |
Static Public Member Functions inherited from mitk::PropertyList | |
static const char * | GetStaticNameOfClass () |
static Pointer | New () |
Static Public Attributes | |
static const PixelType | MAX_LABEL_VALUE |
The maximum value a label can get: Since the value is of type unsigned short MAX_LABEL_VALUE = 65535. More... | |
Protected Member Functions | |
void | PrintSelf (std::ostream &os, itk::Indent indent) const override |
Label (const Label &other) | |
Protected Member Functions inherited from mitk::PropertyList | |
PropertyList () | |
PropertyList (const PropertyList &other) | |
virtual | ~PropertyList () |
Additional Inherited Members | |
Protected Attributes inherited from mitk::PropertyList | |
PropertyMap | m_Properties |
Map of properties. More... | |
A data structure describing a label.
Definition at line 35 of file mitkLabel.h.
typedef unsigned short mitk::Label::PixelType |
Definition at line 40 of file mitkLabel.h.
mitk::Label::Label | ( | ) |
Definition at line 28 of file mitkLabel.cpp.
References mitk::PropertyList::GetProperty(), SetCenterOfMassCoordinates(), SetCenterOfMassIndex(), SetColor(), SetLayer(), SetLocked(), SetName(), SetOpacity(), SetValue(), and SetVisible().
|
virtual |
Definition at line 81 of file mitkLabel.cpp.
|
protected |
Definition at line 66 of file mitkLabel.cpp.
References mitk::PropertyList::GetMap(), Modified(), and mitk::New().
mitk::Point3D mitk::Label::GetCenterOfMassCoordinates | ( | ) | const |
Definition at line 244 of file mitkLabel.cpp.
References mitk::GenericProperty< T >::GetValue().
mitk::Point3D mitk::Label::GetCenterOfMassIndex | ( | ) | const |
Definition at line 227 of file mitkLabel.cpp.
References mitk::GenericProperty< T >::GetValue().
const mitk::Color & mitk::Label::GetColor | ( | ) | const |
Definition at line 199 of file mitkLabel.cpp.
References mitk::ColorProperty::GetColor().
Referenced by mitk::LabelSetImageVtkMapper2D::GenerateDataForRenderer().
unsigned int mitk::Label::GetLayer | ( | ) | const |
Definition at line 191 of file mitkLabel.cpp.
References mitk::GenericProperty< T >::GetValue().
bool mitk::Label::GetLocked | ( | ) | const |
Definition at line 105 of file mitkLabel.cpp.
Referenced by InternalWritePreviewOnWorkingImage().
std::string mitk::Label::GetName | ( | ) | const |
Definition at line 153 of file mitkLabel.cpp.
float mitk::Label::GetOpacity | ( | ) | const |
Definition at line 141 of file mitkLabel.cpp.
mitk::Label::PixelType mitk::Label::GetValue | ( | ) | const |
Definition at line 171 of file mitkLabel.cpp.
Referenced by mitk::ContourModelUtils::FillSliceInSlice(), mitk::LabelSetImageVtkMapper2D::GenerateDataForRenderer(), InternalWritePreviewOnWorkingImage(), mitk::SetRegionTool::OnMousePressed(), mitk::SetRegionTool::OnMouseReleased(), and mitk::ContourTool::OnMouseReleased().
bool mitk::Label::GetVisible | ( | ) | const |
Definition at line 123 of file mitkLabel.cpp.
Referenced by mitk::LabelSetImageVtkMapper2D::GenerateDataForRenderer().
mitk::Label::mitkClassMacro | ( | Label | , |
mitk::PropertyList | |||
) |
|
inline |
Definition at line 77 of file mitkLabel.h.
Referenced by Label(), and SetProperty().
|
static |
|
overrideprotected |
Definition at line 257 of file mitkLabel.cpp.
void mitk::Label::SetCenterOfMassCoordinates | ( | const mitk::Point3D & | center | ) |
Definition at line 233 of file mitkLabel.cpp.
References mitk::Point3dProperty::New(), and mitk::GenericProperty< T >::SetValue().
Referenced by Label().
void mitk::Label::SetCenterOfMassIndex | ( | const mitk::Point3D & | center | ) |
Definition at line 216 of file mitkLabel.cpp.
References mitk::Point3dProperty::New(), and mitk::GenericProperty< T >::SetValue().
Referenced by Label().
void mitk::Label::SetColor | ( | const mitk::Color & | _color | ) |
Definition at line 205 of file mitkLabel.cpp.
References mitk::ColorProperty::New(), and mitk::ColorProperty::SetColor().
Referenced by Label(), and mitk::LabelSet::RenameLabel().
void mitk::Label::SetLayer | ( | unsigned int | layer | ) |
Definition at line 180 of file mitkLabel.cpp.
References mitk::UIntProperty::New(), and mitk::GenericProperty< T >::SetValue().
Referenced by Label().
void mitk::Label::SetLocked | ( | bool | locked | ) |
Definition at line 94 of file mitkLabel.cpp.
References mitk::GenericProperty< T >::SetValue().
Referenced by Label().
void mitk::Label::SetName | ( | const std::string & | name | ) |
Definition at line 148 of file mitkLabel.cpp.
Referenced by Label(), and mitk::LabelSet::RenameLabel().
void mitk::Label::SetOpacity | ( | float | opacity | ) |
Definition at line 130 of file mitkLabel.cpp.
References mitk::GenericProperty< T >::SetValue().
Referenced by Label().
void mitk::Label::SetProperty | ( | const std::string & | propertyKey, |
BaseProperty * | property | ||
) |
Definition at line 85 of file mitkLabel.cpp.
References Modified(), and mitk::New().
void mitk::Label::SetValue | ( | PixelType | pixelValue | ) |
Definition at line 160 of file mitkLabel.cpp.
References mitk::UShortProperty::New(), and mitk::GenericProperty< T >::SetValue().
Referenced by Label().
void mitk::Label::SetVisible | ( | bool | visible | ) |
Definition at line 112 of file mitkLabel.cpp.
References mitk::GenericProperty< T >::SetValue().
Referenced by Label().
|
static |
The maximum value a label can get: Since the value is of type unsigned short MAX_LABEL_VALUE = 65535.
Definition at line 45 of file mitkLabel.h.
Referenced by mitk::LabelSet::AddLabel(), and mitk::LabelSetImage::InitializeByLabeledImageProcessing().