Skip to content

Commit

Permalink
Removed vrpn_bool from the interface definitions for some classes, re…
Browse files Browse the repository at this point in the history
…placing it with bool. This fixes a compiler bug on 64-bit Linux and there is not reason for us to use a non-standard bool in these locations.
  • Loading branch information
Russell Taylor committed Mar 17, 2012
1 parent 1bfa547 commit e130a2a
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 14 deletions.
6 changes: 3 additions & 3 deletions vrpn_Tracker_AnalogFly.C
Expand Up @@ -17,8 +17,8 @@ static double duration(struct timeval t1, struct timeval t2)
vrpn_Tracker_AnalogFly::vrpn_Tracker_AnalogFly
(const char * name, vrpn_Connection * trackercon,
vrpn_Tracker_AnalogFlyParam * params, float update_rate,
vrpn_bool absolute, vrpn_bool reportChanges,
vrpn_bool worldFrame) :
bool absolute, bool reportChanges,
bool worldFrame) :
vrpn_Tracker (name, trackercon),
d_reset_button(NULL),
d_which_button (params->reset_which),
Expand Down Expand Up @@ -517,7 +517,7 @@ void vrpn_Tracker_AnalogFly::convert_matrix_to_tracker (void)
}
}

vrpn_bool vrpn_Tracker_AnalogFly::shouldReport
bool vrpn_Tracker_AnalogFly::shouldReport
(double elapsedInterval) const {

// If we haven't had enough time pass yet, don't report.
Expand Down
12 changes: 6 additions & 6 deletions vrpn_Tracker_AnalogFly.h
Expand Up @@ -107,8 +107,8 @@ class VRPN_API vrpn_Tracker_AnalogFly : public vrpn_Tracker {
public:
vrpn_Tracker_AnalogFly (const char * name, vrpn_Connection * trackercon,
vrpn_Tracker_AnalogFlyParam * params,
float update_rate, vrpn_bool absolute = vrpn_FALSE,
vrpn_bool reportChanges = VRPN_FALSE, vrpn_bool worldFrame = VRPN_FALSE);
float update_rate, bool absolute = vrpn_FALSE,
bool reportChanges = VRPN_FALSE, bool worldFrame = VRPN_FALSE);

virtual ~vrpn_Tracker_AnalogFly (void);

Expand All @@ -124,9 +124,9 @@ class VRPN_API vrpn_Tracker_AnalogFly : public vrpn_Tracker {

double d_update_interval; //< How long to wait between sends
struct timeval d_prevtime; //< Time of the previous report
vrpn_bool d_absolute; //< Report absolute (vs. differential)?
vrpn_bool d_reportChanges;
vrpn_bool d_worldFrame;
bool d_absolute; //< Report absolute (vs. differential)?
bool d_reportChanges;
bool d_worldFrame;

vrpn_TAF_fullaxis d_x, d_y, d_z, d_sx, d_sy, d_sz;
vrpn_Button_Remote * d_reset_button;
Expand All @@ -141,7 +141,7 @@ class VRPN_API vrpn_Tracker_AnalogFly : public vrpn_Tracker {
void update_matrix_based_on_values (double time_interval);
void convert_matrix_to_tracker (void);

vrpn_bool shouldReport (double elapsedInterval) const;
bool shouldReport (double elapsedInterval) const;

int setup_channel (vrpn_TAF_fullaxis * full);
int teardown_channel (vrpn_TAF_fullaxis * full);
Expand Down
4 changes: 2 additions & 2 deletions vrpn_Tracker_ButtonFly.C
Expand Up @@ -19,7 +19,7 @@ static double duration(struct timeval t1, struct timeval t2)
vrpn_Tracker_ButtonFly::vrpn_Tracker_ButtonFly
(const char * name, vrpn_Connection * trackercon,
vrpn_Tracker_ButtonFlyParam * params, float update_rate,
vrpn_bool reportChanges) :
bool reportChanges) :
vrpn_Tracker (name, trackercon),
d_vel_scale(NULL),
d_vel_scale_value(1.0),
Expand Down Expand Up @@ -457,7 +457,7 @@ void vrpn_Tracker_ButtonFly::convert_matrix_to_tracker (void)
}
}

vrpn_bool vrpn_Tracker_ButtonFly::shouldReport
bool vrpn_Tracker_ButtonFly::shouldReport
(double elapsedInterval) {
int i;
bool found_any;
Expand Down
6 changes: 3 additions & 3 deletions vrpn_Tracker_ButtonFly.h
Expand Up @@ -118,7 +118,7 @@ class VRPN_API vrpn_Tracker_ButtonFly : public vrpn_Tracker {
vrpn_Tracker_ButtonFly (const char * name, vrpn_Connection * trackercon,
vrpn_Tracker_ButtonFlyParam * params,
float update_rate,
vrpn_bool reportChanges = VRPN_FALSE);
bool reportChanges = VRPN_FALSE);

virtual ~vrpn_Tracker_ButtonFly (void);

Expand All @@ -133,7 +133,7 @@ class VRPN_API vrpn_Tracker_ButtonFly : public vrpn_Tracker {

double d_update_interval; //< How long to wait between sends
struct timeval d_prevtime; //< Time of the previous report
vrpn_bool d_reportChanges; //< Report only when something changes?
bool d_reportChanges; //< Report only when something changes?

vrpn_TBF_fullaxis d_axes[vrpn_BUTTONFLY_MAXAXES];
int d_num_axes;
Expand Down Expand Up @@ -166,7 +166,7 @@ class VRPN_API vrpn_Tracker_ButtonFly : public vrpn_Tracker {
void update_matrix_based_on_values (double time_interval);
void convert_matrix_to_tracker (void);

vrpn_bool shouldReport (double elapsedInterval);
bool shouldReport (double elapsedInterval);

int setup_channel(vrpn_TBF_fullaxis * full);
int teardown_channel(vrpn_TBF_fullaxis * full);
Expand Down

0 comments on commit e130a2a

Please sign in to comment.