From 4f5ddb3700fa0d372c65a1343334e6c697aba20f Mon Sep 17 00:00:00 2001 From: ZappoMan Date: Tue, 16 Apr 2013 15:46:20 -0700 Subject: [PATCH] fixed yaw/ideal yaw problem correctly --- interface/src/Camera.cpp | 1 + interface/src/Camera.h | 15 +-------------- 2 files changed, 2 insertions(+), 14 deletions(-) diff --git a/interface/src/Camera.cpp b/interface/src/Camera.cpp index a74aace71e..6ea15bab0a 100644 --- a/interface/src/Camera.cpp +++ b/interface/src/Camera.cpp @@ -45,6 +45,7 @@ void Camera::update( float deltaTime ) } _position += ( _idealPosition - _position ) * t; + _yaw += ( _idealYaw - _yaw ) * t; // generate the ortho-normals for the orientation based on the Euler angles _orientation.setToIdentity(); diff --git a/interface/src/Camera.h b/interface/src/Camera.h index c76d6d2e43..354a5d8d16 100644 --- a/interface/src/Camera.h +++ b/interface/src/Camera.h @@ -29,21 +29,8 @@ public: void update( float deltaTime ); - /* - void setMode ( CameraMode m ) { mode = m; } - void setYaw ( float y ) { idealYaw = y; } - void setPitch ( float p ) { pitch = p; } - void setRoll ( float r ) { roll = r; } - void setUp ( float u ) { up = u; } - void setDistance ( float d ) { distance = d; } - void setTargetPosition ( glm::vec3 t ) { targetPosition = t; } - void setPosition ( glm::vec3 p ) { position = p; } - void setTightness ( float t ) { tightness = t; } - void setOrientation ( Orientation o ) { orientation.set(o); } -*/ - void setMode ( CameraMode m ) { _mode = m; } - void setYaw ( float y ) { _yaw = y; } + void setYaw ( float y ) { _idealYaw = y; } void setPitch ( float p ) { _pitch = p; } void setRoll ( float r ) { _roll = r; } void setUp ( float u ) { _up = u; }