Medical Imaging Interaction Toolkit  2023.12.00
Medical Imaging Interaction Toolkit
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
mitkClaronTrackingDevice.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 mitkClaronTrackingDevice_h
14 #define mitkClaronTrackingDevice_h
15 
16 
17 #include <thread>
18 #include <vector>
19 #include <mitkIGTConfig.h>
20 #include <mitkTrackingDevice.h>
21 #include <mitkClaronTool.h>
22 
23 //only include MicronTracker if cmake Variable is on else the ClaronInterfaceStub is included
24 #ifdef MITK_USE_MICRON_TRACKER
25 #include <mitkClaronInterface.h>
26 #else
28 #endif
29 
30 namespace mitk
31 {
38  class MITKIGT_EXPORT ClaronTrackingDevice : public TrackingDevice
39  {
40  public:
41 
43  itkFactorylessNewMacro(Self);
44  itkCloneMacro(Self);
45 
49  bool IsDeviceInstalled() override;
50 
56  bool StartTracking() override;
57 
62  bool StopTracking() override;
63 
68  bool OpenConnection() override;
69 
73  bool CloseConnection() override;
74 
78  unsigned int GetToolCount() const override;
79 
85  TrackingTool* GetTool(unsigned int toolNumber) const override;
86 
87 
99  mitk::TrackingTool* AddTool(const char* toolName, const char* fileName);
100 
101 
107  DEPRECATED(bool IsMicronTrackerInstalled());
108 
110  itkSetMacro(CalibrationDir,std::string);
111 
113  itkGetMacro(CalibrationDir,std::string);
114 
115  protected:
117  ~ClaronTrackingDevice() override;
118 
125  bool InternalAddTool(ClaronTool::Pointer tool);
126 
132  void TrackTools();
133 
140  std::vector<ClaronTool::Pointer> DetectTools();
141 
145  std::vector<ClaronTool::Pointer> GetAllTools();
146 
150  ClaronInterface* GetDevice();
151 
152  void ThreadStartTracking();
153 
154  std::vector<ClaronTool::Pointer> m_AllTools;
155  ClaronInterface::Pointer m_Device;
156  std::thread m_Thread;
157 
159  std::string m_CalibrationDir;
161  std::string m_ToolfilesDir;
162  };
163 }//mitk
164 #endif
mitk::ClaronInterface
An object of this class represents the interface to the MicronTracker. The methods of this class are ...
Definition: mitkClaronInterface.h:43
mitk::ClaronTrackingDevice::m_AllTools
std::vector< ClaronTool::Pointer > m_AllTools
vector holding all tools
Definition: mitkClaronTrackingDevice.h:154
mitkClaronInterfaceStub.h
DEPRECATED
#define DEPRECATED(func)
Definition: mitkCommon.h:175
mitk::ClaronTrackingDevice::m_Device
ClaronInterface::Pointer m_Device
represents the interface to the tracking hardware
Definition: mitkClaronTrackingDevice.h:155
mitkClaronInterface.h
mitk
Find image slices visible on a given plane.
Definition: RenderingTests.dox:1
mitk::ClaronTrackingDevice::m_CalibrationDir
std::string m_CalibrationDir
The directory where the camera calibration files can be found.
Definition: mitkClaronTrackingDevice.h:159
mitk::ClaronTrackingDevice
An object of this class represents the MicronTracker device. You can add tools to this device,...
Definition: mitkClaronTrackingDevice.h:38
mitk::TrackingDevice
Interface for all Tracking Devices.
Definition: mitkTrackingDevice.h:34
mitk::ClaronTrackingDevice::m_ToolfilesDir
std::string m_ToolfilesDir
The directory where the tool calibration files can be found.
Definition: mitkClaronTrackingDevice.h:161
mitkClaronTool.h
mitk::ClaronTrackingDevice::m_Thread
std::thread m_Thread
Definition: mitkClaronTrackingDevice.h:156
mitk::TrackingTool
Interface for all Tracking Tools.
Definition: mitkTrackingTool.h:42
mitkClassMacro
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:36
mitkTrackingDevice.h