1#ifndef INCLUDED_ANALOGFLY
2#define INCLUDED_ANALOGFLY
7#include "vrpn_Analog.h"
8#include "vrpn_Button.h"
9#include "vrpn_Configure.h"
10#include "vrpn_Shared.h"
11#include "vrpn_Tracker.h"
12#include "vrpn_Types.h"
27 { name = NULL; channel = 0; offset = 0.0f; thresh = 0.0f;
28 scale = 1.0f; power = 1.0f; };
43 x.name = y.name = z.name =
44 sx.name = sy.name = sz.name = reset_name = clutch_name = NULL;
109 float update_rate,
bool absolute = vrpn_FALSE,
110 bool reportChanges = VRPN_FALSE,
bool worldFrame = VRPN_FALSE);
117 double d_update_interval;
118 struct timeval d_prevtime;
120 bool d_reportChanges;
129 bool d_clutch_engaged;
130 bool d_clutch_was_off;
132 q_matrix_type d_initMatrix, d_currentMatrix, d_clutchMatrix;
134 void update_matrix_based_on_values (
double time_interval);
135 void convert_matrix_to_tracker (
void);
137 bool shouldReport (
double elapsedInterval)
const;
141 virtual void reset(
void);
143 static void VRPN_CALLBACK handle_analog_update (
void * userdata,
145 static void VRPN_CALLBACK handle_reset_press (
void * userdata,
const vrpn_BUTTONCB info);
146 static void VRPN_CALLBACK handle_clutch_press (
void * userdata,
const vrpn_BUTTONCB info);
Generic connection class not specific to the transport mechanism.
定义 vrpn_Connection.h:562
定义 vrpn_Tracker_AnalogFly.h:22
定义 vrpn_Tracker_AnalogFly.h:67
定义 vrpn_Tracker_AnalogFly.h:38
char * reset_name
Button device that is used to reset the matrix to the origin
定义 vrpn_Tracker_AnalogFly.h:55
vrpn_TAF_axis x
Translation along each of these three axes
定义 vrpn_Tracker_AnalogFly.h:48
char * clutch_name
Clutch device that is used to enable relative motion over
定义 vrpn_Tracker_AnalogFly.h:61
vrpn_TAF_axis sx
Rotation in the positive direction about the three axes
定义 vrpn_Tracker_AnalogFly.h:51
This class will turn an analog device such as a joystick or a camera
定义 vrpn_Tracker_AnalogFly.h:105
This structure is what is passed to a vrpn_Connection message callback.
定义 vrpn_Connection.h:41