00001 /*========================================================================= 00002 00003 Program: Medical Imaging & Interaction Toolkit 00004 Language: C++ 00005 Date: $Date$ 00006 Version: $Revision$ 00007 00008 Copyright (c) German Cancer Research Center, Division of Medical and 00009 Biological Informatics. All rights reserved. 00010 See MITKCopyright.txt or https://www.mitk.org/copyright.html for details. 00011 00012 This software is distributed WITHOUT ANY WARRANTY; without even 00013 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00014 PURPOSE. See the above copyright notices for more information. 00015 00016 =========================================================================*/ 00017 00018 00019 #ifndef MITKTRACKINGDEVICESOURCE_H_HEADER_INCLUDED_ 00020 #define MITKTRACKINGDEVICESOURCE_H_HEADER_INCLUDED_ 00021 00022 #include <mitkNavigationDataSource.h> 00023 #include "mitkTrackingDevice.h" 00024 00025 namespace mitk { 00044 class MitkIGT_EXPORT TrackingDeviceSource : public NavigationDataSource 00045 { 00046 public: 00047 mitkClassMacro(TrackingDeviceSource, NavigationDataSource); 00048 itkNewMacro(Self); 00049 00053 virtual void SetTrackingDevice(mitk::TrackingDevice* td); 00054 00058 itkGetConstObjectMacro(TrackingDevice, mitk::TrackingDevice); 00059 00066 void Connect(); 00067 00074 void Disconnect(); 00075 00083 void StartTracking(); 00084 00091 void StopTracking(); 00092 00097 virtual bool IsConnected(); 00098 00103 virtual bool IsTracking(); 00104 00108 virtual void UpdateOutputInformation(); 00109 00110 protected: 00111 TrackingDeviceSource(); 00112 virtual ~TrackingDeviceSource(); 00113 00122 virtual void GenerateData(); 00123 00127 void CreateOutputs(); 00128 00129 mitk::TrackingDevice::Pointer m_TrackingDevice; 00130 }; 00131 } // namespace mitk 00132 #endif /* MITKTrackingDeviceSource_H_HEADER_INCLUDED_ */