Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
mitk::python Namespace Reference

Functions

py::object propertyToPythonValue (const mitk::BaseProperty &prop)
 Converts a BaseProperty to its Python native value. More...
 
py::dict propertyToDict (const mitk::BaseProperty &prop)
 
mitk::BaseProperty::Pointer dictToProperty (const py::dict &d)
 
bool tryTemporoSpatialStringToDict (const mitk::BaseProperty &prop, py::dict &result)
 
mitk::BaseProperty::Pointer tryDictToTemporoSpatialString (const py::dict &d)
 

Function Documentation

◆ dictToProperty()

mitk::BaseProperty::Pointer mitk::python::dictToProperty ( const py::dict &  d)
inline

◆ propertyToDict()

py::dict mitk::python::propertyToDict ( const mitk::BaseProperty &  prop)
inline

Definition at line 100 of file PropertyConversionUtils.h.

◆ propertyToPythonValue()

py::object mitk::python::propertyToPythonValue ( const mitk::BaseProperty &  prop)
inline

Converts a BaseProperty to its Python native value.

This function converts MITK property objects to their corresponding Python types:

  • StringProperty -> str
  • BoolProperty -> bool
  • IntProperty -> int
  • FloatProperty -> float
  • DoubleProperty -> float
  • ColorProperty -> tuple(float, float, float)
  • Other types -> returns the property object itself
Parameters
propThe property to convert
Returns
Python object representing the property value

Definition at line 67 of file PropertyConversionUtils.h.

Referenced by bind_property_owner().

◆ tryDictToTemporoSpatialString()

mitk::BaseProperty::Pointer mitk::python::tryDictToTemporoSpatialString ( const py::dict &  d)
inline

◆ tryTemporoSpatialStringToDict()

bool mitk::python::tryTemporoSpatialStringToDict ( const mitk::BaseProperty &  prop,
py::dict &  result 
)
inline

Definition at line 33 of file TemporoSpatialStringSerialization.h.