13#ifndef VRPN_TRACKER_DTRACK_H
14#define VRPN_TRACKER_DTRACK_H
56#define vrpn_DTRACK_FLYSTICK_MAX_BUTTON 16
57#define vrpn_DTRACK_FLYSTICK_MAX_JOYSTICK 8
96 const char* dtrackHost,
int dtrackPort,
bool doFirewall,
97 float timeToReachJoy = 0.f,
98 int fixNbody = -1,
int fixNflystick = -1,
int* fixId = NULL,
99 bool act3DOFout =
false,
bool actTracing =
false );
114 struct timeval tim_first;
115 struct timeval tim_last;
118 unsigned int tracing_frames;
122 bool use_fix_numbering;
130 bool warning_nbodycal;
139 int dtrack2vrpn_marker(
int id,
const char* str_dtrack,
int id_dtrack,
140 const float* loc,
struct timeval
timestamp);
141 int dtrack2vrpn_body(
int id,
const char* str_dtrack,
int id_dtrack,
142 const float* loc,
const float* rot,
struct timeval
timestamp);
143 int dtrack2vrpn_flystickbuttons(
int id,
int id_dtrack,
144 int num_but,
const int* but,
struct timeval
timestamp);
145 int dtrack2vrpn_flystickanalogs(
int id,
int id_dtrack,
146 int num_ana,
const float* ana,
float dt,
struct timeval
timestamp);
152 unsigned int d_multicastIp;
158 unsigned int act_framecounter;
159 double act_timestamp;
160 unsigned int act_timestamp_sec;
161 unsigned int act_timestamp_usec;
162 unsigned int act_latency_usec;
164 bool output_3dof_marker;
170 bool act_has_bodycal_format;
173 int act_num_flystick;
175 bool act_has_old_flystick_format;
179 bool dtrack_init(
unsigned int serverIp,
int udpport,
bool doFirewall );
182 bool dtrack_receive();
vrpn_Analog(const char *name, vrpn_Connection *c=NULL)
virtual void mainloop()=0
Called once through each main loop iteration to handle updates. Remote object mainloop() should call ...
Generic connection class not specific to the transport mechanism.
vrpn_Tracker_DTrack(const char *name, vrpn_Connection *c, const char *dtrackHost, int dtrackPort, bool doFirewall, float timeToReachJoy=0.f, int fixNbody=-1, int fixNflystick=-1, int *fixId=NULL, bool act3DOFout=false, bool actTracing=false)
vrpn_Tracker(const char *name, vrpn_Connection *c=NULL, const char *tracker_cfg_file_name=NULL)
int button[vrpn_DTRACK_FLYSTICK_MAX_BUTTON]
float joystick[vrpn_DTRACK_FLYSTICK_MAX_JOYSTICK]
#define vrpn_DTRACK_FLYSTICK_MAX_BUTTON
#define vrpn_DTRACK_FLYSTICK_MAX_JOYSTICK
class VRPN_API vrpn_Connection