Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
mitkTransferFunctionProperty.cpp
Go to the documentation of this file.
1 /*===================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center,
6 Division of Medical and Biological Informatics.
7 All rights reserved.
8 
9 This software is distributed WITHOUT ANY WARRANTY; without
10 even the implied warranty of MERCHANTABILITY or FITNESS FOR
11 A PARTICULAR PURPOSE.
12 
13 See LICENSE.txt or http://www.mitk.org for details.
14 
15 ===================================================================*/
16 
18 
19 namespace mitk
20 {
21  bool TransferFunctionProperty::IsEqual(const BaseProperty &property) const
22  {
23  return *(this->m_Value) == *(static_cast<const Self &>(property).m_Value);
24  }
25 
26  bool TransferFunctionProperty::Assign(const BaseProperty &property)
27  {
28  this->m_Value = static_cast<const Self &>(property).m_Value;
29  return true;
30  }
31 
33  {
34  std::stringstream myStr;
35  myStr << GetValue();
36  return myStr.str();
37  }
38 
41  : BaseProperty(other), m_Value(other.m_Value->Clone())
42  {
43  }
44 
46  : BaseProperty(), m_Value(value)
47  {
48  }
49 
50  itk::LightObject::Pointer TransferFunctionProperty::InternalClone() const
51  {
52  itk::LightObject::Pointer result(new Self(*this));
53  result->UnRegister();
54  return result;
55  }
56 
57 } // namespace mitk
The TransferFunctionProperty class Property class for the mitk::TransferFunction. ...
itk::SmartPointer< Self > Pointer
Pointer Clone() const
virtual mitk::TransferFunction::Pointer GetValue() const
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.
DataCollection - Class to facilitate loading/accessing structured data.
mitk::TransferFunction::Pointer m_Value
Abstract base class for properties.
std::string GetValueAsString() const override
static itkEventMacro(BoundingShapeInteractionEvent, itk::AnyEvent) class MITKBOUNDINGSHAPE_EXPORT BoundingShapeInteractor Pointer New()
Basic interaction methods for mitk::GeometryData.