Medical Imaging Interaction Toolkit  2018.4.99-08619e4f
Medical Imaging Interaction Toolkit
mitkNavigationDataObjectVisualizationFilter.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 
14 #ifndef MITKNAVIGATIONDATAOBJECTVISUALIZATIONFILTER_H_HEADER_INCLUDED_
15 #define MITKNAVIGATIONDATAOBJECTVISUALIZATIONFILTER_H_HEADER_INCLUDED_
16 
18 #include "mitkNavigationData.h"
19 #include "mitkBaseData.h"
20 
21 namespace mitk {
22 
31  {
32  public:
34 
35  itkFactorylessNewMacro(Self);
36 
37  itkCloneMacro(Self);
38 
52  enum RotationMode {RotationStandard, RotationTransposed};
53 
58 
62  typedef std::map<unsigned int, RepresentationPointer> RepresentationPointerMap;
63 
67  typedef std::map<unsigned int, std::vector<RepresentationPointer>> RepresentationVectorPointerMap;
68 
72  typedef RepresentationVectorPointerMap::size_type RepresentationPointerMapSizeType;
73 
80  void SetRepresentationObject(unsigned int index, BaseData::Pointer data);
81 
88  void SetRepresentationObjects(unsigned int index, const std::vector<BaseData::Pointer> &data);
89 
97  BaseData::Pointer GetRepresentationObject(unsigned int idx) const;
98 
106  std::vector<RepresentationPointer> GetAllRepresentationObjects(unsigned int idx) const;
107 
108  virtual void SetTransformPosition(unsigned int index, bool applyTransform);
109  virtual bool GetTransformPosition(unsigned int index) const;
110  virtual void TransformPositionOn(unsigned int index);
111  virtual void TransformPositionOff(unsigned int index);
112 
113  virtual void SetTransformOrientation(unsigned int index, bool applyTransform);
114  virtual bool GetTransformOrientation(unsigned int index) const;
115  virtual void TransformOrientationOn(unsigned int index);
116  virtual void TransformOrientationOff(unsigned int index);
117 
122  void SetOffset(int index, mitk::AffineTransform3D::Pointer offset);
123 
129  virtual void SetRotationMode(RotationMode r);
130 
132  mitk::AffineTransform3D::Pointer GetOffset(int index);
133 
138  RepresentationPointerMapSizeType GetNumberOfToolRepresentations() const
139  {
140  return m_RepresentationVectorMap.size();
141  }
142 
143  /*
144  * \brief Transfer the information from the input to the associated BaseData
145  */
146  void GenerateData() override;
147 
148 
149  protected:
150  typedef std::map<itk::ProcessObject::DataObjectPointerArraySizeType, bool> BooleanInputMap;
151  typedef std::map<unsigned int, mitk::AffineTransform3D::Pointer> OffsetPointerMap;
152 
157 
162 
167  RepresentationVectorPointerMap m_RepresentationVectorMap;
168  BooleanInputMap m_TransformPosition;
169  BooleanInputMap m_TransformOrientation;
170  OffsetPointerMap m_OffsetList;
171 
172  private:
173  RotationMode m_RotationMode;
174  };
175 } // namespace mitk
176 #endif /* MITKNAVIGATIONDATAOBJECTVISUALIZATIONFILTER_H_HEADER_INCLUDED_ */
std::map< itk::ProcessObject::DataObjectPointerArraySizeType, bool > BooleanInputMap
NavigationDataToNavigationDataFilter is the base class of all filters that receive NavigationDatas as...
std::map< unsigned int, RepresentationPointer > RepresentationPointerMap
STL map of index to BaseData . Using map to be able to set non continuous indices.
BooleanInputMap m_TransformPosition
if set to true, the filter will use the position part of the input navigation data at the given index...
DataCollection - Class to facilitate loading/accessing structured data.
RepresentationPointerMapSizeType GetNumberOfToolRepresentations() const
Get the number of added BaseData associated to NavigationData.
static Vector3D offset
#define MITKIGT_EXPORT
RepresentationVectorPointerMap::size_type RepresentationPointerMapSizeType
Size type of an std::vector.
std::map< unsigned int, std::vector< RepresentationPointer > > RepresentationVectorPointerMap
STL vector map of index to BaseData . Using map to be able to set non continuous indices.
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:40
BaseData::Pointer RepresentationPointer
Smart Pointer type to a BaseData.
BooleanInputMap m_TransformOrientation
if set to true, the filter will use the orientation part of the input navigation data at the given in...
RepresentationVectorPointerMap m_RepresentationVectorMap
An array of the BaseData which represent the tools.
std::map< unsigned int, mitk::AffineTransform3D::Pointer > OffsetPointerMap
Class that reads NavigationData from input and transfers the information to the geometry of the assoc...