Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
mitkTransferFunctionPropertySerializer.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 
13 #ifndef mitkTransferFunctionPropertySerializer_h
14 #define mitkTransferFunctionPropertySerializer_h
15 
18 
19 namespace mitk
20 {
36  {
37  public:
39  itkFactorylessNewMacro(Self);
40  itkCloneMacro(Self);
41 
52  tinyxml2::XMLElement *Serialize(tinyxml2::XMLDocument &doc) override;
53 
66  BaseProperty::Pointer Deserialize(const tinyxml2::XMLElement *element) override;
67 
79  static bool SerializeTransferFunction(const char *filename, TransferFunction::Pointer tf);
80 
91  static TransferFunction::Pointer DeserializeTransferFunction(const char *filePath);
92 
93  protected:
96  };
97 }
98 
99 #endif
#define MITKSCENESERIALIZATIONBASE_EXPORT
Base class for objects that serialize and deserialize BaseProperty types to/from XML.
Serializer for mitk::TransferFunctionProperty.
tinyxml2::XMLElement * Serialize(tinyxml2::XMLDocument &doc) override
Serializes the TransferFunctionProperty into an XML element.
mitkClassMacro(TransferFunctionPropertySerializer, BasePropertySerializer)
static TransferFunction::Pointer DeserializeTransferFunction(const char *filePath)
Deserializes a TransferFunction from an XML file.
BaseProperty::Pointer Deserialize(const tinyxml2::XMLElement *element) override
Deserializes an XML element back into a TransferFunctionProperty.
static bool SerializeTransferFunction(const char *filename, TransferFunction::Pointer tf)
Serializes a TransferFunction to an XML file.
Find image slices visible on a given plane.