commit f150aab5e67a545824004a49277c82f66c0c4651
Author: Robert Haschke <rhaschke@techfak.uni-bielefeld.de>
Date:   Sat Nov 14 14:57:52 2020 +0100

    clang-format-10

diff --git a/server/src/EmotionConfig.cpp b/server/src/EmotionConfig.cpp
index 47b8d66..e79556c 100644
--- a/server/src/EmotionConfig.cpp
+++ b/server/src/EmotionConfig.cpp
@@ -1,274 +1,278 @@
 /*
-* This file is part of hlrc_server
-*
-* Copyright(c) sschulz <AT> techfak.uni-bielefeld.de
-* http://opensource.cit-ec.de/projects/hlrc_server
-*
-* This file may be licensed under the terms of the
-* GNU General Public License Version 3 (the ``GPL''),
-* or (at your option) any later version.
-*
-* Software distributed under the License is distributed
-* on an ``AS IS'' basis, WITHOUT WARRANTY OF ANY KIND, either
-* express or implied. See the GPL for the specific language
-* governing rights and limitations.
-*
-* You should have received a copy of the GPL along with this
-* program. If not, go to http://www.gnu.org/licenses/gpl.html
-* or write to the Free Software Foundation, Inc.,
-* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-*
-* The development of this software was supported by the
-* Excellence Cluster EXC 277 Cognitive Interaction Technology.
-* The Excellence Cluster EXC 277 is a grant of the Deutsche
-* Forschungsgemeinschaft (DFG) in the context of the German
-* Excellence Initiative.
-*
-*/
+ * This file is part of hlrc_server
+ *
+ * Copyright(c) sschulz <AT> techfak.uni-bielefeld.de
+ * http://opensource.cit-ec.de/projects/hlrc_server
+ *
+ * This file may be licensed under the terms of the
+ * GNU General Public License Version 3 (the ``GPL''),
+ * or (at your option) any later version.
+ *
+ * Software distributed under the License is distributed
+ * on an ``AS IS'' basis, WITHOUT WARRANTY OF ANY KIND, either
+ * express or implied. See the GPL for the specific language
+ * governing rights and limitations.
+ *
+ * You should have received a copy of the GPL along with this
+ * program. If not, go to http://www.gnu.org/licenses/gpl.html
+ * or write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ *
+ * The development of this software was supported by the
+ * Excellence Cluster EXC 277 Cognitive Interaction Technology.
+ * The Excellence Cluster EXC 277 is a grant of the Deutsche
+ * Forschungsgemeinschaft (DFG) in the context of the German
+ * Excellence Initiative.
+ *
+ */
 
 #include "EmotionConfig.h"
 using namespace boost;
 
-EmotionConfig::EmotionConfig(){
-    select_config(NEUTRAL);
+EmotionConfig::EmotionConfig() {
+	select_config(NEUTRAL);
 }
 
-EmotionConfig::EmotionConfig(EmotionType e){
-    select_config(e);
+EmotionConfig::EmotionConfig(EmotionType e) {
+	select_config(e);
 }
 
-EmotionConfig::~EmotionConfig(){
+EmotionConfig::~EmotionConfig() {
 }
 
+bool EmotionConfig::is_active() {
+	if (get_system_time() >= end_time) {
+		return false;
+	}
 
-bool EmotionConfig::is_active(){
-    if (get_system_time() >= end_time){
-        return false;
-    }
-
-    return true;
+	return true;
 }
 
-void EmotionConfig::set_duration(unsigned long ms){
-    //set a timeout:
-    end_time = get_system_time() + posix_time::milliseconds(ms);
+void EmotionConfig::set_duration(unsigned long ms) {
+	// set a timeout:
+	end_time = get_system_time() + posix_time::milliseconds(ms);
 }
 
-void EmotionConfig::select_config(EmotionType e){
-    // default overblend time
-    overblend_time_ms = 500;
-
-    switch((int) e){
-        default:
-        case(NEUTRAL): init_neutral(); break;
-        case(HAPPY  ): init_happy(); break;
-        case(SAD    ): init_sad(); break;
-        case(ANGRY  ): init_angry(); break;
-        case(SURPRISED): init_surprised(); break;
-        case(FEAR):      init_fear(); break;
-    }
+void EmotionConfig::select_config(EmotionType e) {
+	// default overblend time
+	overblend_time_ms = 500;
+
+	switch ((int)e) {
+		default:
+		case (NEUTRAL):
+			init_neutral();
+			break;
+		case (HAPPY):
+			init_happy();
+			break;
+		case (SAD):
+			init_sad();
+			break;
+		case (ANGRY):
+			init_angry();
+			break;
+		case (SURPRISED):
+			init_surprised();
+			break;
+		case (FEAR):
+			init_fear();
+			break;
+	}
 }
 
-void EmotionConfig::init_neutral(){
-    //neutral = look straight
-    gaze_override.pan_offset = 0.0;
-    gaze_override.tilt_offset = 0.0;
-    gaze_override.roll_offset = 0.0;
-    gaze_override.gaze_type = humotion::GazeState::GAZETYPE_ABSOLUTE; //GAZETYPE_OVERRIDE;
-
-    //not setable right now
-    gaze_override.vergence = 0.0;
-
-    gaze_override.eyelid_opening_upper = 25.0;
-    gaze_override.eyelid_opening_lower = 30.0;
-
-    //eyebrow angles
-    gaze_override.eyebrow_left = -3.0;
-    gaze_override.eyebrow_right = 3.0;
-
-    //eyeblink request
-    gaze_override.eyeblink_request_left  = 0;
-    gaze_override.eyeblink_request_right = 0;
-
-    //mouth:
-    /*mouth_override.position_left   = 14.7;
-    mouth_override.opening_left    = 0.0;
-    mouth_override.position_center = 16.0;
-    mouth_override.opening_center  = 1.0;
-    mouth_override.position_right  = 14.7;
-    mouth_override.opening_right   = 0.0;*/
-    /*mouth_override.position_left   = 11.54200000000000000000;
-    mouth_override.opening_left    = 0; //2.412000;
-    mouth_override.position_center = 12.50000000000000000;
-    mouth_override.opening_center  = 0; //1.737000;
-    mouth_override.position_right  = 11.5250000000000000000;
-    mouth_override.opening_right   = 0;//2.412000;
-    */
-    
-    mouth_override.position_left   = 20;
-    mouth_override.opening_left    = 0.0;
-    mouth_override.position_center = 22;
-    mouth_override.opening_center  = 2.0;
-    mouth_override.position_right  = 20-2;
-    mouth_override.opening_right   = 0.0;
-
+void EmotionConfig::init_neutral() {
+	// neutral = look straight
+	gaze_override.pan_offset = 0.0;
+	gaze_override.tilt_offset = 0.0;
+	gaze_override.roll_offset = 0.0;
+	gaze_override.gaze_type = humotion::GazeState::GAZETYPE_ABSOLUTE; // GAZETYPE_OVERRIDE;
+
+	// not setable right now
+	gaze_override.vergence = 0.0;
+
+	gaze_override.eyelid_opening_upper = 25.0;
+	gaze_override.eyelid_opening_lower = 30.0;
+
+	// eyebrow angles
+	gaze_override.eyebrow_left = -3.0;
+	gaze_override.eyebrow_right = 3.0;
+
+	// eyeblink request
+	gaze_override.eyeblink_request_left = 0;
+	gaze_override.eyeblink_request_right = 0;
+
+	// mouth:
+	/*mouth_override.position_left   = 14.7;
+	mouth_override.opening_left    = 0.0;
+	mouth_override.position_center = 16.0;
+	mouth_override.opening_center  = 1.0;
+	mouth_override.position_right  = 14.7;
+	mouth_override.opening_right   = 0.0;*/
+	/*mouth_override.position_left   = 11.54200000000000000000;
+	mouth_override.opening_left    = 0; //2.412000;
+	mouth_override.position_center = 12.50000000000000000;
+	mouth_override.opening_center  = 0; //1.737000;
+	mouth_override.position_right  = 11.5250000000000000000;
+	mouth_override.opening_right   = 0;//2.412000;
+	*/
+
+	mouth_override.position_left = 20;
+	mouth_override.opening_left = 0.0;
+	mouth_override.position_center = 22;
+	mouth_override.opening_center = 2.0;
+	mouth_override.position_right = 20 - 2;
+	mouth_override.opening_right = 0.0;
 }
 
-void EmotionConfig::init_happy(){
-    //neutral = look straight
-    gaze_override.pan_offset = 0.0;
-    gaze_override.tilt_offset = 0.0;
-    gaze_override.roll_offset = 0.0;
-    gaze_override.gaze_type = humotion::GazeState::GAZETYPE_ABSOLUTE; //GAZETYPE_OVERRIDE;
-
-    //not setable right now
-    gaze_override.vergence = 0.0;
-
-    gaze_override.eyelid_opening_upper = 30.0;
-    gaze_override.eyelid_opening_lower = 30.0;
-
-    //eyebrow angles
-    gaze_override.eyebrow_left = -1.0;
-    gaze_override.eyebrow_right = 1.0;
-
-    //eyeblink request
-    gaze_override.eyeblink_request_left  = humotion::GazeState::EYEBLINK_TIME_DEFAULT;
-    gaze_override.eyeblink_request_right = humotion::GazeState::EYEBLINK_TIME_DEFAULT;
-/*
-    mouth_override.position_left   = -1+9.5;
-    mouth_override.opening_left    = 0.0;
-    mouth_override.position_center = 24.3;
-    mouth_override.opening_center  = 7.0;
-    mouth_override.position_right  = -1+10.5;
-    mouth_override.opening_right   = 0.0;*/
-  
-    mouth_override.position_left   = 18; //13.56850000000000000000;
-    mouth_override.opening_left    = 0; //.791000;
-    mouth_override.position_center = 26; //14.18400000000000000000;
-    mouth_override.opening_center  = 5;
-    mouth_override.position_right  = 18; //15.31800000000000000000;
-    mouth_override.opening_right   = 0; //2.791000;
-
- 
-
+void EmotionConfig::init_happy() {
+	// neutral = look straight
+	gaze_override.pan_offset = 0.0;
+	gaze_override.tilt_offset = 0.0;
+	gaze_override.roll_offset = 0.0;
+	gaze_override.gaze_type = humotion::GazeState::GAZETYPE_ABSOLUTE; // GAZETYPE_OVERRIDE;
+
+	// not setable right now
+	gaze_override.vergence = 0.0;
+
+	gaze_override.eyelid_opening_upper = 30.0;
+	gaze_override.eyelid_opening_lower = 30.0;
+
+	// eyebrow angles
+	gaze_override.eyebrow_left = -1.0;
+	gaze_override.eyebrow_right = 1.0;
+
+	// eyeblink request
+	gaze_override.eyeblink_request_left = humotion::GazeState::EYEBLINK_TIME_DEFAULT;
+	gaze_override.eyeblink_request_right = humotion::GazeState::EYEBLINK_TIME_DEFAULT;
+	/*
+	    mouth_override.position_left   = -1+9.5;
+	    mouth_override.opening_left    = 0.0;
+	    mouth_override.position_center = 24.3;
+	    mouth_override.opening_center  = 7.0;
+	    mouth_override.position_right  = -1+10.5;
+	    mouth_override.opening_right   = 0.0;*/
+
+	mouth_override.position_left = 18;   // 13.56850000000000000000;
+	mouth_override.opening_left = 0;     //.791000;
+	mouth_override.position_center = 26; // 14.18400000000000000000;
+	mouth_override.opening_center = 5;
+	mouth_override.position_right = 18; // 15.31800000000000000000;
+	mouth_override.opening_right = 0;   // 2.791000;
 }
 
-void EmotionConfig::init_sad(){
-    gaze_override.pan_offset = 0.0;
-    gaze_override.tilt_offset = -3.0;
-    gaze_override.roll_offset = -3.0;
-    gaze_override.gaze_type = humotion::GazeState::GAZETYPE_ABSOLUTE; //GAZETYPE_OVERRIDE;
-
-    //not setable right now
-    gaze_override.vergence = 0.0;
-
-    gaze_override.eyelid_opening_upper = 15.0;
-    gaze_override.eyelid_opening_lower = 40.0;
-
-    //eyebrow angles
-    gaze_override.eyebrow_left = -20.0;
-    gaze_override.eyebrow_right = 20.0;
-
-    //eyeblink request
-    gaze_override.eyeblink_request_left  = 3 * humotion::GazeState::EYEBLINK_TIME_DEFAULT;
-    gaze_override.eyeblink_request_right = 3 * humotion::GazeState::EYEBLINK_TIME_DEFAULT;
-
-    //mouth:
-    mouth_override.position_left   = 21.0;
-    mouth_override.opening_left    = 0.0;
-    mouth_override.position_center = 16.0;
-    mouth_override.opening_center  = 0.0;
-    mouth_override.position_right  = 21.0;
-    mouth_override.opening_right   = 0.0;
+void EmotionConfig::init_sad() {
+	gaze_override.pan_offset = 0.0;
+	gaze_override.tilt_offset = -3.0;
+	gaze_override.roll_offset = -3.0;
+	gaze_override.gaze_type = humotion::GazeState::GAZETYPE_ABSOLUTE; // GAZETYPE_OVERRIDE;
+
+	// not setable right now
+	gaze_override.vergence = 0.0;
+
+	gaze_override.eyelid_opening_upper = 15.0;
+	gaze_override.eyelid_opening_lower = 40.0;
+
+	// eyebrow angles
+	gaze_override.eyebrow_left = -20.0;
+	gaze_override.eyebrow_right = 20.0;
+
+	// eyeblink request
+	gaze_override.eyeblink_request_left = 3 * humotion::GazeState::EYEBLINK_TIME_DEFAULT;
+	gaze_override.eyeblink_request_right = 3 * humotion::GazeState::EYEBLINK_TIME_DEFAULT;
+
+	// mouth:
+	mouth_override.position_left = 21.0;
+	mouth_override.opening_left = 0.0;
+	mouth_override.position_center = 16.0;
+	mouth_override.opening_center = 0.0;
+	mouth_override.position_right = 21.0;
+	mouth_override.opening_right = 0.0;
 }
 
-void EmotionConfig::init_angry(){
-    gaze_override.pan_offset = 0.0;
-    gaze_override.tilt_offset = -5.0;
-    gaze_override.roll_offset = 0.0;
-    gaze_override.gaze_type = humotion::GazeState::GAZETYPE_ABSOLUTE; //GAZETYPE_OVERRIDE;
-
-    //not setable right now
-    gaze_override.vergence = 0.0;
-
-    gaze_override.eyelid_opening_upper = 18.0;
-    gaze_override.eyelid_opening_lower = 18.0;
-
-    //eyebrow angles
-    gaze_override.eyebrow_left =  21.0;
-    gaze_override.eyebrow_right = -21.0;
-
-    //eyeblink request
-    gaze_override.eyeblink_request_left  = 0;
-    gaze_override.eyeblink_request_right = 0;
-
-    //mouth:
-    mouth_override.position_left   = 21;
-    mouth_override.opening_left    = 6.0;
-    mouth_override.position_center = 22.3;
-    mouth_override.opening_center  = 0.0;
-    mouth_override.position_right  = 21;
-    mouth_override.opening_right   = 6.0;
+void EmotionConfig::init_angry() {
+	gaze_override.pan_offset = 0.0;
+	gaze_override.tilt_offset = -5.0;
+	gaze_override.roll_offset = 0.0;
+	gaze_override.gaze_type = humotion::GazeState::GAZETYPE_ABSOLUTE; // GAZETYPE_OVERRIDE;
+
+	// not setable right now
+	gaze_override.vergence = 0.0;
+
+	gaze_override.eyelid_opening_upper = 18.0;
+	gaze_override.eyelid_opening_lower = 18.0;
+
+	// eyebrow angles
+	gaze_override.eyebrow_left = 21.0;
+	gaze_override.eyebrow_right = -21.0;
+
+	// eyeblink request
+	gaze_override.eyeblink_request_left = 0;
+	gaze_override.eyeblink_request_right = 0;
+
+	// mouth:
+	mouth_override.position_left = 21;
+	mouth_override.opening_left = 6.0;
+	mouth_override.position_center = 22.3;
+	mouth_override.opening_center = 0.0;
+	mouth_override.position_right = 21;
+	mouth_override.opening_right = 6.0;
 }
 
-void EmotionConfig::init_surprised(){
-    gaze_override.pan_offset  = 0.0;
-    gaze_override.tilt_offset = 8.0;
-    gaze_override.roll_offset = 0.0;
-    gaze_override.gaze_type = humotion::GazeState::GAZETYPE_ABSOLUTE; //GAZETYPE_OVERRIDE;
-
-    //not setable right now
-    gaze_override.vergence = 0.0;
-
-    //eyelids
-    gaze_override.eyelid_opening_upper = 60.0;
-    gaze_override.eyelid_opening_lower = 60.0;
-
-    //eyebrow angles
-    gaze_override.eyebrow_left =  -2.0;
-    gaze_override.eyebrow_right =  2.0;
-
-    //eyeblink request
-    gaze_override.eyeblink_request_left  = humotion::GazeState::EYEBLINK_TIME_DEFAULT;
-    gaze_override.eyeblink_request_right = humotion::GazeState::EYEBLINK_TIME_DEFAULT;
-
-    //mouth:
-    mouth_override.position_left   = 22;
-    mouth_override.opening_left    = 0.0;
-    mouth_override.position_center = 26.0;
-    mouth_override.opening_center  = 10.0;
-    mouth_override.position_right  = 22.0;
-    mouth_override.opening_right   = 0.0;
-
-    
+void EmotionConfig::init_surprised() {
+	gaze_override.pan_offset = 0.0;
+	gaze_override.tilt_offset = 8.0;
+	gaze_override.roll_offset = 0.0;
+	gaze_override.gaze_type = humotion::GazeState::GAZETYPE_ABSOLUTE; // GAZETYPE_OVERRIDE;
+
+	// not setable right now
+	gaze_override.vergence = 0.0;
+
+	// eyelids
+	gaze_override.eyelid_opening_upper = 60.0;
+	gaze_override.eyelid_opening_lower = 60.0;
+
+	// eyebrow angles
+	gaze_override.eyebrow_left = -2.0;
+	gaze_override.eyebrow_right = 2.0;
+
+	// eyeblink request
+	gaze_override.eyeblink_request_left = humotion::GazeState::EYEBLINK_TIME_DEFAULT;
+	gaze_override.eyeblink_request_right = humotion::GazeState::EYEBLINK_TIME_DEFAULT;
+
+	// mouth:
+	mouth_override.position_left = 22;
+	mouth_override.opening_left = 0.0;
+	mouth_override.position_center = 26.0;
+	mouth_override.opening_center = 10.0;
+	mouth_override.position_right = 22.0;
+	mouth_override.opening_right = 0.0;
 }
 
-void EmotionConfig::init_fear(){
-    gaze_override.pan_offset  = 5.0;
-    gaze_override.tilt_offset = 0.0;
-    gaze_override.roll_offset = 0.0;
-    gaze_override.gaze_type = humotion::GazeState::GAZETYPE_ABSOLUTE;
-
-    //not setable right now
-    gaze_override.vergence = 0.0;
-
-    gaze_override.eyelid_opening_upper = 50.0;
-    gaze_override.eyelid_opening_lower = 50.0;
-
-
-    //eyebrow angles
-    gaze_override.eyebrow_left =  -23.0;
-    gaze_override.eyebrow_right =  23.0;
-
-    //eyeblink request
-    gaze_override.eyeblink_request_left  = 0;
-    gaze_override.eyeblink_request_right = 0;
-
-    //mouth:
-    mouth_override.position_left   = 14;
-    mouth_override.opening_left    = 0.0;
-    mouth_override.position_center = 21;
-    mouth_override.opening_center  = 5;
-    mouth_override.position_right  = 35.9;
-    mouth_override.opening_right   = 0.0;
+void EmotionConfig::init_fear() {
+	gaze_override.pan_offset = 5.0;
+	gaze_override.tilt_offset = 0.0;
+	gaze_override.roll_offset = 0.0;
+	gaze_override.gaze_type = humotion::GazeState::GAZETYPE_ABSOLUTE;
+
+	// not setable right now
+	gaze_override.vergence = 0.0;
+
+	gaze_override.eyelid_opening_upper = 50.0;
+	gaze_override.eyelid_opening_lower = 50.0;
+
+	// eyebrow angles
+	gaze_override.eyebrow_left = -23.0;
+	gaze_override.eyebrow_right = 23.0;
+
+	// eyeblink request
+	gaze_override.eyeblink_request_left = 0;
+	gaze_override.eyeblink_request_right = 0;
+
+	// mouth:
+	mouth_override.position_left = 14;
+	mouth_override.opening_left = 0.0;
+	mouth_override.position_center = 21;
+	mouth_override.opening_center = 5;
+	mouth_override.position_right = 35.9;
+	mouth_override.opening_right = 0.0;
 }
