File: igtl_test_data_trajectoryFormat2.h

package info (click to toggle)
openigtlink 3.0.0-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 3,080 kB
  • sloc: cpp: 20,076; ansic: 6,704; sh: 227; perl: 74; makefile: 46
file content (143 lines) | stat: -rw-r--r-- 6,567 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
/*=========================================================================

  Program:   OpenIGTLLink Library -- Dummy trajectory data
  Module:    $RCSfile: $
  Language:  C
  Date:      $Date: $
  Version:   $Revision: $

  Copyright (c) Insight Software Consortium. All rights reserved.

  This software is distributed WITHOUT ANY WARRANTY; without even
  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
  PURPOSE.  See the above copyright notices for more information.

=========================================================================*/

#ifndef __IGTL_TEST_DATA_TRAJECTORY_FORMAT2_H
#define __IGTL_TEST_DATA_TRAJECTORY_FORMAT2_H

unsigned char test_trajectory_message_Format2[] = {
  /*------- OpenIGTLink message header --------*/
  0x00, 0x02,                                     /* Version number */
  0x54, 0x52, 0x41, 0x4a, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00,                         /* TRAJECTORY */
  0x44, 0x65, 0x76, 0x69, 0x63, 0x65, 0x4e, 0x61,
  0x6d, 0x65, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00,                         /* Device name */
  0x00, 0x00, 0x00, 0x00, 0x49, 0x96, 0x02, 0xd4, /* Time stamp */
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x07, /* Body size */
  0x29, 0x44, 0x65, 0x7a, 0xc8, 0xa3, 0x96, 0xe9, /* CRC */
	
	
	/* Extended header
  0                 2                      4               8           12    
	+-----------------+----------------------+---------------+-------------+
	| EXT_HEADER_SIZE | METADATA_HEADER_SIZE | METADATA_SIZE | MESSAGE_ID  |
	+-----------------+----------------------+---------------+-------------+*/
  0x00, 0x0c, 0x00, 0x12, 0x00, 0x00, 0x00, 0x27,  
  0x00, 0x00, 0x00, 0x01, 
  
  /*---------- TRAJECTORY message body ------------*/
  /* Trajectory data 0 */
  0x54, 0x52, 0x41, 0x4a, 0x45, 0x43, 0x54, 0x4f,
  0x52, 0x59, 0x5f, 0x44, 0x45, 0x53, 0x43, 0x52,
  0x49, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x30,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* Trajectory description */

  0x54, 0x52, 0x41, 0x4a, 0x45, 0x43, 0x54, 0x4f,
  0x52, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* Group name (Trajectory etc.) */

  0x03,                                           /* Type */
  0x00,                                           /* Reserved */
  0xff, 0x00, 0x00, 0xff,                         /* RGBA */

  0x41, 0x20, 0x00, 0x00, 0x41, 0x70, 0x00, 0x00,
  0x41, 0xa0, 0x00, 0x00,                         /* Entry position */ 
  0x41, 0xc8, 0x00, 0x00, 0x41, 0xf0, 0x00, 0x00,
  0x42, 0x0c, 0x00, 0x00,                         /* Target position */
  0x40, 0xa0, 0x00, 0x00,                         /* Radius */

  0x49, 0x4d, 0x41, 0x47, 0x45, 0x5f, 0x30, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00,                         /* Owner image */

  /* Trajectory data 1 */
  0x54, 0x52, 0x41, 0x4a, 0x45, 0x43, 0x54, 0x4f,
  0x52, 0x59, 0x5f, 0x44, 0x45, 0x53, 0x43, 0x52,
  0x49, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x31,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* Trajectory description */

  0x54, 0x52, 0x41, 0x4a, 0x45, 0x43, 0x54, 0x4f,
  0x52, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* Group name (Trajectory etc.) */

  0x03,                                           /* Type */
  0x00,                                           /* Reserved */
  0x00, 0xff, 0x00, 0xff,                         /* RGBA */

  0x42, 0x20, 0x00, 0x00, 0x42, 0x34, 0x00, 0x00,
  0x42, 0x48, 0x00, 0x00,                         /* Entry position */ 
  0x42, 0x5c, 0x00, 0x00, 0x42, 0x70, 0x00, 0x00,
  0x42, 0x82, 0x00, 0x00,                         /* Target position */
  0x40, 0x20, 0x00, 0x00,                         /* Radius */

  0x49, 0x4d, 0x41, 0x47, 0x45, 0x5f, 0x30, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00,                         /* Owner image */

  /* Trajectory data 2 */
  0x54, 0x52, 0x41, 0x4a, 0x45, 0x43, 0x54, 0x4f,
  0x52, 0x59, 0x5f, 0x44, 0x45, 0x53, 0x43, 0x52,
  0x49, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x32,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* Trajectory description */

  0x54, 0x52, 0x41, 0x4a, 0x45, 0x43, 0x54, 0x4f,
  0x52, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* Group name (Trajectory etc.) */

  0x03,                                           /* Type */
  0x00,                                           /* Reserved */
  0x00, 0x00, 0xff, 0xff,                         /* RGBA */

  0x42, 0x8c, 0x00, 0x00, 0x42, 0x96, 0x00, 0x00,
  0x42, 0xa0, 0x00, 0x00,                         /* Entry position */ 
  0x42, 0xaa, 0x00, 0x00, 0x42, 0xb4, 0x00, 0x00,
  0x42, 0xbe, 0x00, 0x00,                         /* Target position */
  0x00, 0x00, 0x00, 0x00,                         /* Radius */

  0x49, 0x4d, 0x41, 0x47, 0x45, 0x5f, 0x30, 0x00,
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  0x00, 0x00, 0x00, 0x00,                         /* Owner image */
  
  /*---------- TRAJECTORY Meta data body ------------*/
  0x00, 0x02,                                     /* Index Count */
  0x00, 0x11, 0x00, 0x03, 0x00, 0x00, 0x00, 0x02, /* first element Key size(2 Bytes), value coding(2 Bytes), value size(4 Bytes)*/
  0x00, 0x12, 0x00, 0x03, 0x00, 0x00, 0x00, 0x02, /* second element Key size, value coding, value size*/
  
  0x46, 0x69, 0x72, 0x73, 0x74, 0x20, 0x70, 0x61, /* First Patient Age 22*/
  0x74, 0x69, 0x65, 0x6e, 0x74, 0x20, 0x61, 0x67,
  0x65, 0x32, 
  0x32, 0x53, 0x65, 0x63, 0x6f, 0x6e, 0x64, 0x20, /* Second Patient Age 25*/
  0x70, 0x61, 0x74, 0x69, 0x65, 0x6e, 0x74, 0x20,
  0x61, 0x67, 0x65, 0x32, 0x35
};

#endif /* IGTL_TEST_DATA_TRAJECTORY_FORMAT2_H */