Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members  
igtlSensorMessage.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: The OpenIGTLink Library
4  Language: C++
5  Web page: http://openigtlink.org/
6 
7  Copyright (c) Insight Software Consortium. All rights reserved.
8 
9  This software is distributed WITHOUT ANY WARRANTY; without even
10  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
11  PURPOSE. See the above copyright notices for more information.
12 
13 =========================================================================*/
14 
15 #ifndef __igtlSensorMessage_h
16 #define __igtlSensorMessage_h
17 
18 #include <string>
19 
20 #include "igtlObject.h"
21 #include "igtlMath.h"
22 #include "igtlMessageBase.h"
23 #include "igtlTypes.h"
24 
25 #include "igtlUnit.h"
26 
27 namespace igtl
28 {
29 
34 {
35 public:
40 
43 
44 public:
45 
47  int SetLength(unsigned int n);
48 
50  unsigned int GetLength();
51 
53  int SetUnit(igtlUnit unit);
54 
56  int SetUnit(igtl::Unit * unit);
57 
59  igtlUnit GetUnit();
60 
62  int GetUnit(igtl::Unit * unit);
63 
65  int SetValue(igtlFloat64 * data);
66 
68  int SetValue(unsigned int i, igtlFloat64 value);
69 
71  igtlFloat64 GetValue(unsigned int i);
72 
73 protected:
74  SensorMessage();
75  ~SensorMessage();
76 
77 protected:
78 
79  virtual int GetBodyPackSize();
80  virtual int PackBody();
81  virtual int UnpackBody();
82 
84  igtlUint8 m_Length;
85 
87  igtlUint8 m_Status;
88 
91 
93  std::vector<igtlFloat64> m_Array;
94 };
95 
96 
97 } // namespace igtl
98 
99 #endif // _igtlSensorMessage_h
100 
101 
igtlUnit.h
igtlMessageBase.h
igtlNewMacro
#define igtlNewMacro(x)
Definition: igtlMacro.h:431
igtl::SensorMessage::m_Array
std::vector< igtlFloat64 > m_Array
The array of sensor values.
Definition: igtlSensorMessage.h:93
igtl::SensorMessage::m_Unit
igtlUnit m_Unit
Unit (generated by igtl::Unit::Pack()).
Definition: igtlSensorMessage.h:90
igtlMath.h
igtl::MessageBase
Definition: igtlMessageBase.h:55
igtl::SensorMessage::m_Length
igtlUint8 m_Length
Length of sensor array.
Definition: igtlSensorMessage.h:84
igtl::Unit
Definition: igtlUnit.h:44
igtl::SensorMessage::ConstPointer
SmartPointer< const Self > ConstPointer
Definition: igtlSensorMessage.h:39
igtl::SensorMessage::Pointer
SmartPointer< Self > Pointer
Definition: igtlSensorMessage.h:38
igtl
The "igtl" namespace contains all OpenIGTLink classes. There are several nested namespaces within the...
Definition: igtlBindMessage.h:25
IGTLCommon_EXPORT
#define IGTLCommon_EXPORT
Definition: igtlWin32Header.h:151
igtl::SensorMessage::Self
SensorMessage Self
Definition: igtlSensorMessage.h:36
igtl::igtlUnit
igtlUint64 igtlUnit
Definition: igtlUnit.h:28
igtl::SensorMessage::Superclass
MessageBase Superclass
Definition: igtlSensorMessage.h:37
igtl::SensorMessage::m_Status
igtlUint8 m_Status
Sensor status (Reserved).
Definition: igtlSensorMessage.h:87
igtl::SensorMessage
Definition: igtlSensorMessage.h:33
igtl::SmartPointer< Self >
igtlTypeMacro
#define igtlTypeMacro(thisClass, superclass)
Definition: igtlMacro.h:486
igtlObject.h
igtlTypes.h

Generated for OpenIGTLink by Doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2012