vrpn  07.33
Virtual Reality Peripheral Network
vrpn_Tracker.h
Go to the documentation of this file.
1 #ifndef vrpn_TRACKER_H
2 #define vrpn_TRACKER_H
3 #include <stdio.h> // for NULL, FILE
4 
5 // NOTE: a vrpn tracker must call user callbacks with tracker data (pos and
6 // ori info) which represent the transformation xfSourceFromSensor.
7 // This means that the pos info is the position of the origin of
8 // the sensor coord sys in the source coord sys space, and the
9 // quat represents the orientation of the sensor relative to the
10 // source space (ie, its value rotates the source's axes so that
11 // they coincide with the sensor's)
12 // Positions from all trackers in VRPN are reported in meters.
13 // Velocities are reported in meters/second.
14 // Accelerations are reported in meters/second/second.
15 // These are all reported in three-element double arrays
16 // in the order (X=0, Y=1, Z=2).
17 // They are translated into this format from the native format for each device.
18 // Orientations from all trackers in VRPN are reported in quaternions
19 // (see Quatlib for more info) in four-element double arrays
20 // in the order (X=0, Y=1, Z=2, W=3).
21 // They are translated into this format from the native format for each device.
22 
23 // to use time synched tracking, just pass in a sync connection to the
24 // client and the server
25 
26 #include "vrpn_BaseClass.h" // for vrpn_Callback_List, etc
27 #include "vrpn_Configure.h" // for VRPN_CALLBACK, VRPN_API, etc
28 #include "vrpn_Connection.h"
29 #include "vrpn_Shared.h" // for timeval
30 #include "vrpn_Types.h" // for vrpn_float64, vrpn_int32, etc
31 
33 
34 // tracker status flags
35 const int vrpn_TRACKER_SYNCING = (3);
37 const int vrpn_TRACKER_REPORT_READY = (1);
38 const int vrpn_TRACKER_PARTIAL = (0);
39 const int vrpn_TRACKER_RESETTING = (-1);
40 const int vrpn_TRACKER_FAIL = (-2);
41 
42 // index for the change_list that should be called for all sensors.
43 // Not an in-range index.
44 const int vrpn_ALL_SENSORS = -1;
45 
46 typedef vrpn_float64 vrpn_Tracker_Pos[3];
47 typedef vrpn_float64 vrpn_Tracker_Quat[4];
48 
50 public:
51  // vrpn_Tracker.cfg, in the "local" directory, is the default config file
52  // . You can specify a different config file in the constructor. When
53  // you do this, you must also specify a vrpn_Connection. Pass in NULL
54  // if you don't have one. This awkwardness is because C++ requires that
55  // only the rightmost arguments can use the default values, and that the
56  // order of arguments must match the base class :(
57  vrpn_Tracker(const char *name, vrpn_Connection *c = NULL,
58  const char *tracker_cfg_file_name = NULL);
59 
60  virtual ~vrpn_Tracker(void);
61 
62  int read_config_file(FILE *config_file, const char *tracker_name);
63  void print_latest_report(void);
64  // a tracker server should call the following to register the
65  // default xform and workspace request handlers
66  int register_server_handlers(void);
67  void get_local_t2r(vrpn_float64 *vec, vrpn_float64 *quat);
68  void get_local_u2s(vrpn_int32 sensor, vrpn_float64 *vec,
69  vrpn_float64 *quat);
70  static int VRPN_CALLBACK
71  handle_t2r_request(void *userdata, vrpn_HANDLERPARAM p);
72  static int VRPN_CALLBACK
73  handle_u2s_request(void *userdata, vrpn_HANDLERPARAM p);
74  static int VRPN_CALLBACK
75  handle_workspace_request(void *userdata, vrpn_HANDLERPARAM p);
76  // static int VRPN_CALLBACK handle_update_rate_request (void *,
77  // vrpn_HANDLERPARAM);
78 
79 protected:
80  vrpn_int32 position_m_id; // ID of tracker position message
81  vrpn_int32 velocity_m_id; // ID of tracker velocity message
82  vrpn_int32 accel_m_id; // ID of tracker acceleration message
83  vrpn_int32 tracker2room_m_id; // ID of tracker tracker2room message
84  vrpn_int32 unit2sensor_m_id; // ID of tracker unit2sensor message
85  vrpn_int32 request_t2r_m_id; // ID of tracker2room request message
86  vrpn_int32 request_u2s_m_id; // ID of unit2sensor request message
87  vrpn_int32 request_workspace_m_id; // ID of workspace request message
88  vrpn_int32 workspace_m_id; // ID of workspace message
89  vrpn_int32 update_rate_id; // ID of update rate message
90  vrpn_int32 connection_dropped_m_id; // ID of connection dropped message
91  vrpn_int32 reset_origin_m_id; // ID of reset origin message
92 
93  // Description of the next report to go out
94  vrpn_int32 d_sensor; // Current sensor
95  vrpn_float64 pos[3], d_quat[4]; // Current pose, (x,y,z), (qx,qy,qz,qw)
96  vrpn_float64 vel[3], vel_quat[4]; // Cur velocity and dQuat/vel_quat_dt
97  vrpn_float64 vel_quat_dt; // delta time (in secs) for vel_quat
98  vrpn_float64 acc[3], acc_quat[4]; // Cur accel and d2Quat/acc_quat_dt2
99  vrpn_float64 acc_quat_dt; // delta time (in secs) for acc_quat
100  struct timeval timestamp; // Current timestamp
101  vrpn_int32 frame_count; // Current framecount
102 
103  // The timestamp that the last report was received (Used by the Liberty
104  // Driver)
105  // Other trackers use timestamp as the watchdog, however due to variable USB
106  // latency the Liberty driver uses the device timestamp and not the computer
107  // clock
108  // at the time the report was received. This however can drift
109  // from the computer time, and hence it can cause a reset when things are
110  // working fine
111  struct timeval watchdog_timestamp;
112 
113  vrpn_float64 tracker2room[3], tracker2room_quat[4]; // Current t2r xform
114  vrpn_int32 num_sensors;
115 
116  // Arrays of values, one per sensor. Includes function to ensure there are
117  // enough there for a specified number of sensors.
119  vrpn_Tracker_Quat *unit2sensor_quat; // Current u2s xforms
121  bool ensure_enough_unit2sensors(unsigned num);
122 
123  // bounding box for the tracker workspace (in tracker space)
124  // these are the points with (x,y,z) minimum and maximum
125  // note: we assume the bounding box edges are aligned with the tracker
126  // coordinate system
127  vrpn_float64 workspace_min[3], workspace_max[3];
128 
129  int status; // What are we doing?
130 
131  virtual int register_types(void); //< Called by BaseClass init()
132  virtual int encode_to(char *buf); // Encodes the position report
133  // Not all trackers will call the velocity and acceleration packers
134  virtual int encode_vel_to(char *buf); // Encodes the velocity report
135  virtual int encode_acc_to(char *buf); // Encodes the acceleration report
136  virtual int encode_tracker2room_to(char *buf); // Encodes the tracker2room
137  virtual int encode_unit2sensor_to(char *buf); // and unit2sensor xforms
138  virtual int encode_workspace_to(char *buf); // Encodes workspace info
139 };
140 
141 #ifndef VRPN_CLIENT_ONLY
142 #define VRPN_TRACKER_BUF_SIZE 100
143 
145 public:
146  vrpn_Tracker_Serial(const char *name, vrpn_Connection *c,
147  const char *port = "/dev/ttyS1", long baud = 38400);
148  virtual ~vrpn_Tracker_Serial();
149 
150 protected:
151  char portname[VRPN_TRACKER_BUF_SIZE];
152  long baudrate;
154 
155  unsigned char buffer[VRPN_TRACKER_BUF_SIZE]; // Characters read in from the
156  // tracker so far
157  vrpn_uint32 bufcount; // How many characters in the buffer?
158 
161  virtual int get_report(void) = 0;
162 
163  // Sends the report that was just read.
164  virtual void send_report(void);
165 
167  virtual void reset(void) = 0;
168 
169 public:
172  virtual void mainloop();
173 };
174 
175 // This driver uses the VRPN-preferred LibUSB-1.0 to control the device.
176 #if defined(VRPN_USE_LIBUSB_1_0)
177 struct libusb_device_handle; // IWYU pragma: keep
178 struct libusb_context; // IWYU pragma: keep
179 #define VRPN_TRACKER_USB_BUF_SIZE 1000
180 
182 public:
183  vrpn_Tracker_USB(const char *name, vrpn_Connection *c, vrpn_uint16 vendor,
184  vrpn_uint16 product, long baud = 115200);
185  virtual ~vrpn_Tracker_USB();
186 
187 protected:
188  struct libusb_device_handle *_device_handle; // Handle for the USB device
189  struct libusb_context *_context; // LibUSB context used for this device
190  vrpn_uint16 _vendor; // Vendor ID for usb device
191  vrpn_uint16 _product; // Product ID for usb device
192  long _baudrate;
193 
194  vrpn_uint8 buffer[VRPN_TRACKER_USB_BUF_SIZE]; // Characters read in from the
195  // tracker
196  vrpn_uint32 bufcount; // How many characters in the buffer?
197 
200  virtual int get_report(void) = 0;
201 
202  // Sends the report that was just read.
203  virtual void send_report(void);
204 
206  virtual void reset(void) = 0;
207 
208 public:
211  virtual void mainloop();
212 };
213 
214 // End of VRPN_USE_LIBUSB_1_0
215 #endif
216 
217 #endif // VRPN_CLIENT_ONLY
218 
219 // This is an example of a tracker server. It basically reports the
220 // position at the origin with zero velocity and acceleration over and
221 // over again at the rate requested. It is here mostly as an example of
222 // how to build a tracker server, and also serves as a test object for
223 // client codes and VRPN builds.
224 
226 public:
227  vrpn_Tracker_NULL(const char *name, vrpn_Connection *c,
228  vrpn_int32 sensors = 1, vrpn_float64 Hz = 1.0);
229  virtual void mainloop();
230 
231  void setRedundantTransmission(vrpn_RedundantTransmission *);
232 
233 protected:
234  vrpn_float64 update_rate;
235 
237 };
238 
239 // This is a tracker server that can be used by an application that
240 // just wants to generate tracker reports but does not really have
241 // a tracker device to drive. Similar to the vrpn_Analog_Server, it
242 // provides a quick and easy way for an application to report things.
243 //
244 // The application creates an object of this class, specifying the
245 // number of sensors and the connection that is to be used. It then
246 // reports poses (position + quat), pose velocities, and pose
247 // accelerations as desired using the provided functions. The
248 // mainloop() function needs to be called periodically even when
249 // there is nothing to report.
250 
252 public:
253  vrpn_Tracker_Server(const char *name, vrpn_Connection *c,
254  vrpn_int32 sensors = 1);
255 
257  virtual void mainloop();
258 
261  virtual int report_pose(
262  const int sensor, const struct timeval t,
263  const vrpn_float64 position[3], const vrpn_float64 quaternion[4],
264  const vrpn_uint32 class_of_service = vrpn_CONNECTION_LOW_LATENCY);
265  virtual int report_pose_velocity(
266  const int sensor, const struct timeval t,
267  const vrpn_float64 position[3], const vrpn_float64 quaternion[4],
268  const vrpn_float64 interval,
269  const vrpn_uint32 class_of_service = vrpn_CONNECTION_LOW_LATENCY);
270  virtual int report_pose_acceleration(
271  const int sensor, const struct timeval t,
272  const vrpn_float64 position[3], const vrpn_float64 quaternion[4],
273  const vrpn_float64 interval,
274  const vrpn_uint32 class_of_service = vrpn_CONNECTION_LOW_LATENCY);
275 };
276 
277 //----------------------------------------------------------
278 // ************** Users deal with the following *************
279 
280 // User routine to handle a tracker position update. This is called when
281 // the tracker callback is called (when a message from its counterpart
282 // across the connection arrives).
283 
284 typedef struct _vrpn_TRACKERCB {
285  struct timeval msg_time; // Time of the report
286  vrpn_int32 sensor; // Which sensor is reporting
287  vrpn_float64 pos[3]; // Position of the sensor
288  vrpn_float64 quat[4]; // Orientation of the sensor
291  void *userdata, const vrpn_TRACKERCB info);
292 
293 // User routine to handle a tracker velocity update. This is called when
294 // the tracker callback is called (when a message from its counterpart
295 // across the connetion arrives).
296 
297 typedef struct _vrpn_TRACKERVELCB {
298  struct timeval msg_time; // Time of the report
299  vrpn_int32 sensor; // Which sensor is reporting
300  vrpn_float64 vel[3]; // Velocity of the sensor
301  vrpn_float64 vel_quat[4]; // Future Orientation of the sensor
302  vrpn_float64 vel_quat_dt; // delta time (in secs) for vel_quat
305  void *userdata, const vrpn_TRACKERVELCB info);
306 
307 // User routine to handle a tracker acceleration update. This is called when
308 // the tracker callback is called (when a message from its counterpart
309 // across the connetion arrives).
310 
311 typedef struct _vrpn_TRACKERACCCB {
312  struct timeval msg_time; // Time of the report
313  vrpn_int32 sensor; // Which sensor is reporting
314  vrpn_float64 acc[3]; // Acceleration of the sensor
315  vrpn_float64 acc_quat[4]; // ?????
316  vrpn_float64 acc_quat_dt; // delta time (in secs) for acc_quat
317 
320  void *userdata, const vrpn_TRACKERACCCB info);
321 
322 // User routine to handle a tracker room2tracker xform update. This is called
323 // when the tracker callback is called (when a message from its counterpart
324 // across the connection arrives).
325 
326 typedef struct _vrpn_TRACKERTRACKER2ROOMCB {
327  struct timeval msg_time; // Time of the report
328  vrpn_float64 tracker2room[3]; // position offset
329  vrpn_float64 tracker2room_quat[4]; // orientation offset
332  void *userdata, const vrpn_TRACKERTRACKER2ROOMCB info);
333 
334 typedef struct _vrpn_TRACKERUNIT2SENSORCB {
335  struct timeval msg_time; // Time of the report
336  vrpn_int32 sensor; // Which sensor this is for
337  vrpn_float64 unit2sensor[3]; // position offset
338  vrpn_float64 unit2sensor_quat[4]; // orientation offset
341  void *userdata, const vrpn_TRACKERUNIT2SENSORCB info);
342 
343 typedef struct _vrpn_TRACKERWORKSPACECB {
344  struct timeval msg_time; // Time of the report
345  vrpn_float64 workspace_min[3]; // minimum corner of box (tracker CS)
346  vrpn_float64 workspace_max[3]; // maximum corner of box (tracker CS)
349  void *userdata, const vrpn_TRACKERWORKSPACECB info);
350 
351 // Structure to hold all of the callback lists for one sensor
352 // (also used for the "all sensors" sensor).
354 public:
359 
360  // This class requires deep copies.
362  {
363  d_change = from.d_change;
364  d_velchange = from.d_velchange;
365  d_accchange = from.d_accchange;
367  };
368 };
369 
370 // Open a tracker that is on the other end of a connection
371 // and handle updates from it. This is the type of tracker that user code will
372 // deal with.
373 
375 public:
376  // The name of the tracker to connect to, including connection name,
377  // for example "Ceiling_tracker@ceiling.cs.unc.edu". If you already
378  // have the connection open, you can specify it as the second parameter.
379  // This allows both servers and clients in the same thread, for example.
380  // If it is not specified, then the connection will be looked up based
381  // on the name passed in.
382  vrpn_Tracker_Remote(const char *name, vrpn_Connection *c = NULL);
383 
384  // unregister all of the handlers registered with the connection
385  virtual ~vrpn_Tracker_Remote(void);
386 
387  // request room from tracker xforms
388  int request_t2r_xform(void);
389  // request all available sensor from unit xforms
390  int request_u2s_xform(void);
391  // request workspace bounding box
392  int request_workspace(void);
393 
394  // set rate of p/v/a updates from the tracker
395  int set_update_rate(vrpn_float64 samplesPerSecond);
396 
397  // reset origin to current tracker location (e.g. - to reinitialize
398  // a PHANToM in its reset position)
399  int reset_origin(void);
400 
401  // This routine calls the mainloop of the connection it's on
402  virtual void mainloop();
403 
404  // **** to register handlers for sensor-specific messages: ****
405  // Default is to register them for all sensors.
406 
407  // (un)Register a callback handler to handle a position change
408  virtual int register_change_handler(void *userdata,
410  vrpn_int32 sensor = vrpn_ALL_SENSORS);
411  virtual int unregister_change_handler(void *userdata,
413  vrpn_int32 sensor = vrpn_ALL_SENSORS);
414 
415  // (un)Register a callback handler to handle a velocity change
416  virtual int register_change_handler(void *userdata,
418  vrpn_int32 sensor = vrpn_ALL_SENSORS);
419  virtual int unregister_change_handler(void *userdata,
421  vrpn_int32 sensor = vrpn_ALL_SENSORS);
422 
423  // (un)Register a callback handler to handle an acceleration change
424  virtual int register_change_handler(void *userdata,
426  vrpn_int32 sensor = vrpn_ALL_SENSORS);
427  virtual int unregister_change_handler(void *userdata,
429  vrpn_int32 sensor = vrpn_ALL_SENSORS);
430 
431  // (un)Register a callback handler to handle a unit2sensor change
432  virtual int
433  register_change_handler(void *userdata,
435  vrpn_int32 sensor = vrpn_ALL_SENSORS);
436  virtual int
437  unregister_change_handler(void *userdata,
439  vrpn_int32 sensor = vrpn_ALL_SENSORS);
440 
441  // **** to get workspace information ****
442  // (un)Register a callback handler to handle a workspace change
443  virtual int
444  register_change_handler(void *userdata,
446  {
447  return d_workspacechange_list.register_handler(userdata, handler);
448  };
449  virtual int
452  {
453  return d_workspacechange_list.unregister_handler(userdata, handler);
454  }
455 
456  // (un)Register a callback handler to handle a tracker2room change
457  virtual int
458  register_change_handler(void *userdata,
460  {
461  return d_tracker2roomchange_list.register_handler(userdata, handler);
462  };
463  virtual int
466  {
467  return d_tracker2roomchange_list.unregister_handler(userdata, handler);
468  };
469 
470 protected:
471  // Callbacks with one per sensor (plus one for "all")
472  vrpn_Tracker_Sensor_Callbacks all_sensor_callbacks;
475  bool ensure_enough_sensor_callbacks(unsigned num);
476 
477  // Callbacks that are one per tracker
480 
481  static int VRPN_CALLBACK
482  handle_change_message(void *userdata, vrpn_HANDLERPARAM p);
483  static int VRPN_CALLBACK
484  handle_vel_change_message(void *userdata, vrpn_HANDLERPARAM p);
485  static int VRPN_CALLBACK
486  handle_acc_change_message(void *userdata, vrpn_HANDLERPARAM p);
487  static int VRPN_CALLBACK
488  handle_tracker2room_change_message(void *userdata, vrpn_HANDLERPARAM p);
489  static int VRPN_CALLBACK
490  handle_unit2sensor_change_message(void *userdata, vrpn_HANDLERPARAM p);
491  static int VRPN_CALLBACK
492  handle_workspace_change_message(void *userdata, vrpn_HANDLERPARAM p);
493 };
494 
495 // End of vrpn_TRACKER_H
496 #endif
const vrpn_uint32 vrpn_CONNECTION_LOW_LATENCY
const int vrpn_ALL_SENSORS
Definition: vrpn_Tracker.h:44
vrpn_float64 vrpn_Tracker_Pos[3]
Definition: vrpn_Tracker.h:46
vrpn_int32 sensor
Definition: vrpn_Tracker.h:299
vrpn_int32 workspace_m_id
Definition: vrpn_Tracker.h:88
vrpn_Tracker_Sensor_Callbacks * sensor_callbacks
Definition: vrpn_Tracker.h:473
const int vrpn_TRACKER_REPORT_READY
Definition: vrpn_Tracker.h:37
vrpn_float64 acc_quat_dt
Definition: vrpn_Tracker.h:316
#define VRPN_TRACKER_USB_BUF_SIZE
Definition: vrpn_Tracker.h:179
vrpn_int32 velocity_m_id
Definition: vrpn_Tracker.h:81
vrpn_int32 tracker2room_m_id
Definition: vrpn_Tracker.h:83
vrpn_int32 update_rate_id
Definition: vrpn_Tracker.h:89
vrpn_float64 vel_quat_dt
Definition: vrpn_Tracker.h:302
virtual int unregister_change_handler(void *userdata, vrpn_TRACKERWORKSPACECHANGEHANDLER handler)
Definition: vrpn_Tracker.h:450
void(VRPN_CALLBACK * vrpn_TRACKERCHANGEHANDLER)(void *userdata, const vrpn_TRACKERCB info)
Definition: vrpn_Tracker.h:290
vrpn_float64 vel_quat_dt
Definition: vrpn_Tracker.h:97
vrpn_int32 request_workspace_m_id
Definition: vrpn_Tracker.h:87
vrpn_int32 connection_dropped_m_id
Definition: vrpn_Tracker.h:90
virtual int register_change_handler(void *userdata, vrpn_TRACKERWORKSPACECHANGEHANDLER handler)
Definition: vrpn_Tracker.h:444
vrpn_Callback_List< vrpn_TRACKERVELCB > d_velchange
Definition: vrpn_Tracker.h:356
vrpn_int32 reset_origin_m_id
Definition: vrpn_Tracker.h:91
void(VRPN_CALLBACK * vrpn_TRACKERACCCHANGEHANDLER)(void *userdata, const vrpn_TRACKERACCCB info)
Definition: vrpn_Tracker.h:319
Generic connection class not specific to the transport mechanism.
vrpn_RedundantTransmission * d_redundancy
Definition: vrpn_Tracker.h:236
virtual int register_types(void)=0
Register the types of messages this device sends/receives. Return 0 on success, -1 on fail.
#define VRPN_CALLBACK
const int vrpn_TRACKER_FAIL
Definition: vrpn_Tracker.h:40
vrpn_int32 d_sensor
Definition: vrpn_Tracker.h:94
void(VRPN_CALLBACK * vrpn_TRACKERTRACKER2ROOMCHANGEHANDLER)(void *userdata, const vrpn_TRACKERTRACKER2ROOMCB info)
Definition: vrpn_Tracker.h:331
#define VRPN_API
All types of client/server/peer objects in VRPN should be derived from the vrpn_BaseClass type descri...
const int vrpn_TRACKER_RESETTING
Definition: vrpn_Tracker.h:39
vrpn_float64 vrpn_Tracker_Quat[4]
Definition: vrpn_Tracker.h:47
virtual void mainloop()=0
Called once through each main loop iteration to handle updates. Remote object mainloop() should call ...
vrpn_int32 unit2sensor_m_id
Definition: vrpn_Tracker.h:84
vrpn_int32 accel_m_id
Definition: vrpn_Tracker.h:82
const int vrpn_TRACKER_PARTIAL
Definition: vrpn_Tracker.h:38
vrpn_Callback_List< vrpn_TRACKERACCCB > d_accchange
Definition: vrpn_Tracker.h:357
vrpn_Callback_List< vrpn_TRACKERCB > d_change
Definition: vrpn_Tracker.h:355
struct libusb_device_handle * _device_handle
Definition: vrpn_Tracker.h:188
void(VRPN_CALLBACK * vrpn_TRACKERUNIT2SENSORCHANGEHANDLER)(void *userdata, const vrpn_TRACKERUNIT2SENSORCB info)
Definition: vrpn_Tracker.h:340
This structure is what is passed to a vrpn_Connection message callback.
vrpn_Tracker_Quat * unit2sensor_quat
Definition: vrpn_Tracker.h:119
virtual int unregister_change_handler(void *userdata, vrpn_TRACKERTRACKER2ROOMCHANGEHANDLER handler)
Definition: vrpn_Tracker.h:464
struct libusb_context * _context
Definition: vrpn_Tracker.h:189
const int vrpn_TRACKER_SYNCING
Definition: vrpn_Tracker.h:35
vrpn_Tracker_Pos * unit2sensor
Definition: vrpn_Tracker.h:118
vrpn_int32 sensor
Definition: vrpn_Tracker.h:286
vrpn_int32 request_t2r_m_id
Definition: vrpn_Tracker.h:85
vrpn_uint32 bufcount
Definition: vrpn_Tracker.h:157
vrpn_float64 update_rate
Definition: vrpn_Tracker.h:234
vrpn_uint16 _product
Definition: vrpn_Tracker.h:191
virtual int register_change_handler(void *userdata, vrpn_TRACKERTRACKER2ROOMCHANGEHANDLER handler)
Definition: vrpn_Tracker.h:458
unsigned num_unit2sensors
Definition: vrpn_Tracker.h:120
vrpn_int32 num_sensors
Definition: vrpn_Tracker.h:114
void(VRPN_CALLBACK * vrpn_TRACKERWORKSPACECHANGEHANDLER)(void *userdata, const vrpn_TRACKERWORKSPACECB info)
Definition: vrpn_Tracker.h:348
vrpn_int32 sensor
Definition: vrpn_Tracker.h:313
const int vrpn_TRACKER_AWAITING_STATION
Definition: vrpn_Tracker.h:36
vrpn_int32 request_u2s_m_id
Definition: vrpn_Tracker.h:86
vrpn_float64 acc_quat_dt
Definition: vrpn_Tracker.h:99
vrpn_Callback_List< vrpn_TRACKERTRACKER2ROOMCB > d_tracker2roomchange_list
Definition: vrpn_Tracker.h:478
Class from which all user-level (and other) classes that communicate with vrpn_Connections should der...
void(VRPN_CALLBACK * vrpn_TRACKERVELCHANGEHANDLER)(void *userdata, const vrpn_TRACKERVELCB info)
Definition: vrpn_Tracker.h:304
vrpn_int32 frame_count
Definition: vrpn_Tracker.h:101
#define VRPN_TRACKER_BUF_SIZE
Definition: vrpn_Tracker.h:142
vrpn_uint16 _vendor
Definition: vrpn_Tracker.h:190
vrpn_Callback_List< vrpn_TRACKERWORKSPACECB > d_workspacechange_list
Definition: vrpn_Tracker.h:479
Helper class for vrpn_Connection that automates redundant transmission for unreliable (low-latency) m...
void operator=(const vrpn_Tracker_Sensor_Callbacks &from)
Definition: vrpn_Tracker.h:361
unsigned num_sensor_callbacks
Definition: vrpn_Tracker.h:474
vrpn_Callback_List< vrpn_TRACKERUNIT2SENSORCB > d_unit2sensorchange
Definition: vrpn_Tracker.h:358
vrpn_int32 position_m_id
Definition: vrpn_Tracker.h:80
vrpn_uint32 bufcount
Definition: vrpn_Tracker.h:196