Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members  
igtlTransformMessage.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 __igtlTransformMessage_h
16 #define __igtlTransformMessage_h
17 
18 #include "igtlObject.h"
19 #include "igtlMath.h"
20 #include "igtlMessageBase.h"
21 
22 namespace igtl
23 {
24 
27 {
28 public:
33 
36 
37 protected:
38  GetTransformMessage() : HeaderOnlyMessageBase() { this->m_DefaultBodyType = "GET_TRANS"; };
40 };
41 
42 
43 
51 {
52 
53 public:
54 
59 
62 
63 public:
64 
66  void SetPosition(float p[3]);
67 
69  void GetPosition(float p[3]);
70 
72  void SetPosition(float px, float py, float pz);
73 
75  void GetPosition(float* px, float* py, float* pz);
76 
78  void SetNormals(float o[3][3]);
79 
81  void GetNormals(float o[3][3]);
82 
84  void SetNormals(float t[3], float s[3], float n[3]);
85 
87  void GetNormals(float t[3], float s[3], float n[3]);
88 
90  void SetMatrix(Matrix4x4& mat);
91 
93  void GetMatrix(Matrix4x4& mat);
94 
95 
96 protected:
99 
100 protected:
101 
102  virtual int GetBodyPackSize();
103  virtual int PackBody();
104  virtual int UnpackBody();
105 
108 
110  unsigned char* m_Transform;
111 
112 };
113 
114 
115 } // namespace igtl
116 
117 #endif // _igtlTransformMessage_h
118 
119 
120 
A class for header-only message types, which are used for quearying.
#define igtlTypeMacro(thisClass, superclass)
Definition: igtlMacro.h:486
The "igtl" namespace contains all OpenIGTLink classes. There are several nested namespaces within the...
unsigned char * m_Transform
The byte array for the serialized transform data.
#define IGTLCommon_EXPORT
A class for the GET_TRANS message type.
SmartPointer< Self > Pointer
SmartPointer< const Self > ConstPointer
HeaderOnlyMessageBase Superclass
#define igtlNewMacro(x)
Definition: igtlMacro.h:431
Matrix4x4 matrix
The transformation matrix.
SmartPointer< const Self > ConstPointer
float Matrix4x4[4][4]
Definition: igtlMath.h:23
SmartPointer< Self > Pointer

Generated at Sat Apr 15 2017 02:30:07 for OpenIGTLink by doxygen 1.8.13 written by Dimitri van Heesch, © 1997-2012