MITK-IGT
IGT Extension of MITK
Loading...
Searching...
No Matches
mitkUSProbe.h
Go to the documentation of this file.
1/*============================================================================
2
3The Medical Imaging Interaction Toolkit (MITK)
4
5Copyright (c) German Cancer Research Center (DKFZ)
6All rights reserved.
7
8Use of this source code is governed by a 3-clause BSD license that can be
9found in the LICENSE file.
10
11============================================================================*/
12
13#ifndef mitkUSProbe_h
14#define mitkUSProbe_h
15
16#include <MitkUSExports.h>
17#include <mitkCommon.h>
18#include <itkObject.h>
19#include <itkObjectFactory.h>
20#include <mitkVector.h>
21
22namespace mitk {
29 //Be sure to check the isEqualTo() method if you expand this class to see if it needs work!
30 class MITKUS_EXPORT USProbe : public itk::Object
31 {
32 public:
36 mitkNewMacro1Param(Self, std::string);
37
41 typedef struct USProbeCropping_
42 {
43 unsigned int top;
44 unsigned int bottom;
45 unsigned int left;
46 unsigned int right;
47
49 : top(0), bottom(0), left(0), right(0) { };
50
51 USProbeCropping_(unsigned int top, unsigned int bottom, unsigned int left, unsigned int right)
52 : top(top), bottom(bottom), left(left), right(right) { };
53 }USProbeCropping;
54
58 void SetProbeCropping(unsigned int top, unsigned int bottom, unsigned int left, unsigned int right);
59 USProbeCropping GetProbeCropping();
60
65 bool IsEqualToProbe(mitk::USProbe::Pointer probe);
66
70 void SetDepthAndSpacing(int depth, Vector3D spacing);
71
76 std::map<int, Vector3D> GetDepthsAndSpacing();
77
81 void SetDepth(int depth);
82
86 void RemoveDepth(int depthToRemove);
87
91 void SetSpacingForGivenDepth(int givenDepth, Vector3D spacing);
92
97 Vector3D GetSpacingForGivenDepth(int givenDepth);
98
103 bool IsDepthAndSpacingEmpty();
104
105 //## getter and setter ##
106
107 itkGetMacro(Name, std::string);
108 itkSetMacro(Name, std::string);
109 itkGetMacro(CurrentDepth, double);
110 itkSetMacro(CurrentDepth, double);
111
112 protected:
113 USProbe();
114 USProbe(std::string identifier);
115 ~USProbe() override;
116
117 std::string m_Name;
119
120 // Map containing the depths and the associated spacings as an std::vector with depth as key and spacing as value
121 std::map<int, Vector3D> m_DepthsAndSpacings;
122
124 };
125} // namespace mitk
126#endif
Right now, the US Probe is only a fancy name for a string. Later, it could handle probe specific para...
Definition mitkUSProbe.h:31
itkFactorylessNewMacro(Self)
mitkClassMacroItkParent(USProbe, itk::Object)
itkCloneMacro(Self) mitkNewMacro1Param(Self
itkSetMacro(Name, std::string)
itkGetMacro(Name, std::string)
double m_CurrentDepth
itkGetMacro(CurrentDepth, double)
std::string m_Name
USProbeCropping m_Cropping
itkSetMacro(CurrentDepth, double)
std::map< int, Vector3D > m_DepthsAndSpacings
IGT Exceptions.
Struct to define a probe specific ultrasound image cropping.
Definition mitkUSProbe.h:42
USProbeCropping_(unsigned int top, unsigned int bottom, unsigned int left, unsigned int right)
Definition mitkUSProbe.h:51