Medical Imaging Interaction Toolkit  2024.12.99-0da743f6
Medical Imaging Interaction Toolkit
mitkTransferFunctionProperty.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 #ifndef mitkTransferFunctionProperty_h
13 #define mitkTransferFunctionProperty_h
14 
15 #include "mitkBaseProperty.h"
16 #include "mitkTransferFunction.h"
17 
18 namespace mitk
19 {
20 #ifdef _MSC_VER
21 #pragma warning(push)
22 #pragma warning(disable : 4522)
23 #endif
24 
37  {
38  public:
40 
42 
43  itkFactorylessNewMacro(Self);
44 
45  itkCloneMacro(Self)
47 
48  itkSetMacro(Value, mitk::TransferFunction::Pointer);
49  itkGetConstMacro(Value, mitk::TransferFunction::Pointer);
50 
51  std::string GetValueAsString() const override;
52 
53  bool ToJSON(nlohmann::json& j) const override;
54  bool FromJSON(const nlohmann::json& j) override;
55 
56  using BaseProperty::operator=;
57 
58  protected:
60 
63 
65 
66  private:
67  // purposely not implemented
69 
70  itk::LightObject::Pointer InternalClone() const override;
71 
72  bool IsEqual(const BaseProperty &property) const override;
73  bool Assign(const BaseProperty &property) override;
74  };
75 
76 #ifdef _MSC_VER
77 #pragma warning(pop)
78 #endif
79 
80 } // namespace mitk
81 
82 #endif
mitk::BaseProperty
Abstract base class for properties.
Definition: mitkBaseProperty.h:36
mitkTransferFunction.h
mitk::FromJSON
MITKCORE_EXPORT void FromJSON(const nlohmann::json &j, AffineTransform3D::Pointer transform)
Read transform from JSON array (16 elements, resp. 4x4 matrix).
mitkNewMacro1Param
#define mitkNewMacro1Param(classname, type)
Definition: mitkCommon.h:68
itk::SmartPointer< Self >
mitk
Find image slices visible on a given plane.
Definition: RenderingTests.dox:1
mitk::TransferFunctionProperty
The TransferFunctionProperty class Property class for the mitk::TransferFunction.
Definition: mitkTransferFunctionProperty.h:36
json
nlohmann::json json
Definition: mitkModelTestFixture.h:29
mitk::TransferFunctionProperty::ValueType
mitk::TransferFunction::Pointer ValueType
Definition: mitkTransferFunctionProperty.h:39
mitk::ToJSON
MITKCORE_EXPORT void ToJSON(nlohmann::json &j, AffineTransform3D::ConstPointer transform)
Write transform (4x4 matrix) as JSON array with 16 elements.
itk
SET FUNCTIONS.
Definition: itkIntelligentBinaryClosingFilter.h:30
mitkClassMacro
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:36
mitk::TransferFunction
The TransferFunction class A wrapper class for VTK scalar opacity, gradient opacity,...
Definition: mitkTransferFunction.h:55
mitkBaseProperty.h
MITKCORE_EXPORT
#define MITKCORE_EXPORT
Definition: MitkCoreExports.h:15