Medical Imaging Interaction Toolkit  2016.11.0
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,
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 
17 
18 #ifndef MITKNAVIGATIONDATAOBJECTVISUALIZATIONFILTER_H_HEADER_INCLUDED_
19 #define MITKNAVIGATIONDATAOBJECTVISUALIZATIONFILTER_H_HEADER_INCLUDED_
20 
22 #include "mitkNavigationData.h"
23 #include "mitkBaseData.h"
24 
25 namespace mitk {
26 
35  {
36  public:
38 
39  itkFactorylessNewMacro(Self)
40  itkCloneMacro(Self)
41 
42 
55  enum RotationMode {RotationStandard, RotationTransposed};
56 
61 
65  typedef std::map<unsigned int, RepresentationPointer> RepresentationPointerMap;
66 
70  typedef RepresentationPointerMap::size_type RepresentationPointerMapSizeType;
71 
78  void SetRepresentationObject(unsigned int index, BaseData* data);
79 
87  const BaseData* GetRepresentationObject(unsigned int idx);
88 
89  virtual void SetTransformPosition(unsigned int index, bool applyTransform);
90  virtual bool GetTransformPosition(unsigned int index) const;
91  virtual void TransformPositionOn(unsigned int index);
92  virtual void TransformPositionOff(unsigned int index);
93 
94  virtual void SetTransformOrientation(unsigned int index, bool applyTransform);
95  virtual bool GetTransformOrientation(unsigned int index) const;
96  virtual void TransformOrientationOn(unsigned int index);
97  virtual void TransformOrientationOff(unsigned int index);
98 
103  void SetOffset(int index, mitk::AffineTransform3D::Pointer offset);
104 
110  virtual void SetRotationMode(RotationMode r);
111 
113  mitk::AffineTransform3D::Pointer GetOffset(int index);
114 
119  RepresentationPointerMapSizeType GetNumberOfToolRepresentations() const
120  {
121  return m_RepresentationList.size();
122  }
123 
124  /*
125  * \brief Transfer the information from the input to the associated BaseData
126  */
127  virtual void GenerateData() override;
128 
129 
130  protected:
131  typedef std::map<itk::ProcessObject::DataObjectPointerArraySizeType, bool> BooleanInputMap;
132  typedef std::map<unsigned int, mitk::AffineTransform3D::Pointer> OffsetPointerMap;
133 
138 
143 
147  RepresentationPointerMap m_RepresentationList;
148  BooleanInputMap m_TransformPosition;
149  BooleanInputMap m_TransformOrientation;
150  OffsetPointerMap m_OffsetList;
151 
152  private:
153  RotationMode m_RotationMode;
154  };
155 } // namespace mitk
156 #endif /* MITKNAVIGATIONDATAOBJECTVISUALIZATIONFILTER_H_HEADER_INCLUDED_ */
std::map< itk::ProcessObject::DataObjectPointerArraySizeType, bool > BooleanInputMap
itk::SmartPointer< Self > Pointer
Base of all data objects.
Definition: mitkBaseData.h:39
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.
BaseData::ConstPointer RepresentationPointer
Smart Pointer type to a BaseData.
static Vector3D offset
RepresentationPointerMap::size_type RepresentationPointerMapSizeType
Size type of an std::vector.
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:44
BooleanInputMap m_TransformOrientation
if set to true, the filter will use the orientation part of the input navigation data at the given in...
RepresentationPointerMap m_RepresentationList
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...
RepresentationPointerMapSizeType GetNumberOfToolRepresentations() const
Get the number of added BaseData associated to NavigationData.