commit ea068cf1895f60473f109326def6bff27dd7e4e3
Author: sschulz <sschulz@techfak.uni-bielefeld.de>
Date:   Mon Feb 22 11:04:00 2016 +0100

    cleaning up and naming convention

diff --git a/src/server/motion_generator.cpp b/src/server/motion_generator.cpp
index 595252b..f9402d1 100644
--- a/src/server/motion_generator.cpp
+++ b/src/server/motion_generator.cpp
@@ -32,9 +32,9 @@ using humotion::server::MotionGenerator;
 
 //! constructor
 MotionGenerator::MotionGenerator(JointInterface *j) {
-    joint_interface = j;
-    last_mouth_target_update = boost::posix_time::ptime(boost::posix_time::min_date_time);
-    last_gaze_target_update  = boost::posix_time::ptime(boost::posix_time::min_date_time);
+    joint_interface_ = j;
+    last_mouth_target_update_ = boost::posix_time::ptime(boost::posix_time::min_date_time);
+    last_gaze_target_update_  = boost::posix_time::ptime(boost::posix_time::min_date_time);
 }
 
 
@@ -49,9 +49,9 @@ MotionGenerator::~MotionGenerator() {
 //! \return Timestamp of this dataset
 humotion::Timestamp MotionGenerator::get_timestamped_state(int joint_id,
                                                            float *position, float *velocity) {
-    humotion::Timestamp stamp = joint_interface->get_ts_position(joint_id).get_last_timestamp();
-    *position = joint_interface->get_ts_position(joint_id).get_interpolated_value(stamp);
-    *velocity = joint_interface->get_ts_speed(joint_id).get_interpolated_value(stamp);
+    humotion::Timestamp stamp = joint_interface_->get_ts_position(joint_id).get_last_timestamp();
+    *position = joint_interface_->get_ts_position(joint_id).get_interpolated_value(stamp);
+    *velocity = joint_interface_->get_ts_speed(joint_id).get_interpolated_value(stamp);
     return stamp;
 }
 
@@ -59,7 +59,7 @@ humotion::Timestamp MotionGenerator::get_timestamped_state(int joint_id,
 //! \param joint_id
 //! \return float value of joint speed
 float MotionGenerator::get_current_speed(int joint_id) {
-    return joint_interface->get_ts_speed(joint_id).get_newest_value();
+    return joint_interface_->get_ts_speed(joint_id).get_newest_value();
 }
 
 //! fetch the latest (=current) position of a joint
@@ -71,57 +71,57 @@ float MotionGenerator::get_current_position(int joint_id) {
     Timestamp diff=now-tsl;
     printf("TIME DIFF %fs %fns\n",diff.sec, diff.nsec);*/
 
-    return joint_interface->get_ts_position(joint_id).get_newest_value();
+    return joint_interface_->get_ts_position(joint_id).get_newest_value();
 }
 
 //! update gaze target:
 //! \param GazeState with target values for the overall gaze
 void MotionGenerator::set_gaze_target(GazeState new_gaze_target) {
     // store value for next iteration
-    requested_gaze_state        = new_gaze_target;
+    requested_gaze_state_        = new_gaze_target;
 
     // keep track if the gaze targets are comming in regulary
-    last_gaze_target_update = boost::get_system_time();
+    last_gaze_target_update_ = boost::get_system_time();
 }
 
 //! update mouth state:
 //! \param MouthState with target values for the mouth joints
 void MotionGenerator::set_mouth_target(MouthState s) {
     // store value
-    requested_mouth_target = s;
+    requested_mouth_target_ = s;
 
     // keep track if the mouth targets are comming in regulary
-    last_mouth_target_update = boost::get_system_time();
+    last_mouth_target_update_ = boost::get_system_time();
 }
 
 
 //! was there incoming gaze data the last second?
 //! \return true if there was data incoming in the last second, false otherwise
 bool MotionGenerator::gaze_target_input_active() {
-    if (last_gaze_target_update  + boost::posix_time::milliseconds(1000)
+    if (last_gaze_target_update_  + boost::posix_time::milliseconds(1000)
             > boost::get_system_time() ) {
         // incoming data -> if gaze is disabled, enable it!
-        joint_interface->enable_gaze_joints();
+        joint_interface_->enable_gaze_joints();
         return true;
     }
 
     // else: no incoming data, disable!
-    joint_interface->disable_gaze_joints();
+    joint_interface_->disable_gaze_joints();
     return false;
 }
 
 //! was there incoming mouth data the last second?
 //! \return true if there was data incoming in the last second, false otherwise
 bool MotionGenerator::mouth_target_input_active() {
-    if (last_mouth_target_update + boost::posix_time::milliseconds(1000)
+    if (last_mouth_target_update_ + boost::posix_time::milliseconds(1000)
             > boost::get_system_time() ) {
         // incoming data -> if mouth is disabled, enable it!
-        joint_interface->enable_mouth_joints();
+        joint_interface_->enable_mouth_joints();
         return true;
     }
 
     // else: no incoming data, disable!
-    joint_interface->disable_mouth_joints();
+    joint_interface_->disable_mouth_joints();
     return false;
 }
 
@@ -130,8 +130,8 @@ float MotionGenerator::limit_target(int joint_id, float val) {
     assert(joint_id < JointInterface::JOINT_ID_ENUM_SIZE);
 
     // fetch min/max for joint:
-    float min = joint_interface->get_joint_min(joint_id);
-    float max = joint_interface->get_joint_max(joint_id);
+    float min = joint_interface_->get_joint_min(joint_id);
+    float max = joint_interface_->get_joint_max(joint_id);
 
     if (max < min) {
         printf("> ERROR: how can min (%4.2f) be bigger than max (%4.2f)?? EXITING NOW\n", min, max);
