Removal of redundant variables and functions from orientation sensor: Code cleanup 82/39482/2
authorAnkur <ankur29.garg@samsung.com>
Fri, 15 May 2015 12:45:27 +0000 (18:15 +0530)
committerAnkur Garg <ankur29.garg@samsung.com>
Fri, 15 May 2015 12:39:04 +0000 (05:39 -0700)
Cleanup of orientation sensor code: removal of unused variables and functions.

Change-Id: I54f99cd2193c78f40012a23766851f86830b5ed3

src/orientation/orientation_sensor.cpp
src/orientation/orientation_sensor.h

index b9291e8..3b27a7b 100755 (executable)
 #define ELEMENT_ROLL_ROTATION_COMPENSATION                                             "ROLL_ROTATION_COMPENSATION"
 #define ELEMENT_AZIMUTH_ROTATION_COMPENSATION                                  "AZIMUTH_ROTATION_COMPENSATION"
 
-void pre_process_data(sensor_data<float> &data_out, const float *data_in, float *bias, int *sign, float scale)
-{
-       data_out.m_data.m_vec[0] = sign[0] * (data_in[0] - bias[0]) / scale;
-       data_out.m_data.m_vec[1] = sign[1] * (data_in[1] - bias[1]) / scale;
-       data_out.m_data.m_vec[2] = sign[2] * (data_in[2] - bias[2]) / scale;
-}
-
 orientation_sensor::orientation_sensor()
 : m_accel_sensor(NULL)
 , m_gyro_sensor(NULL)
@@ -70,7 +63,6 @@ orientation_sensor::orientation_sensor()
 
        m_name = string(SENSOR_NAME);
        register_supported_event(ORIENTATION_RAW_DATA_EVENT);
-       m_enable_orientation = 0;
 
        if (!config.get(SENSOR_TYPE_ORIENTATION, ELEMENT_VENDOR, m_vendor)) {
                ERR("[VENDOR] is empty\n");
index 1128541..86c39f9 100755 (executable)
@@ -52,11 +52,6 @@ private:
 
        cmutex m_value_mutex;
 
-       orientation_filter<float> m_orientation_filter;
-       orientation_filter<float> m_orientation_filter_poll;
-
-       unsigned int m_enable_orientation;
-
        unsigned long long m_time;
        unsigned int m_interval;