mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 14:47:41 +02:00
Merge pull request #58 from ZappoMan/view_frustum_work
fixed yaw/ideal yaw problem correctly
This commit is contained in:
commit
7475887939
2 changed files with 2 additions and 14 deletions
|
@ -45,6 +45,7 @@ void Camera::update( float deltaTime )
|
||||||
}
|
}
|
||||||
|
|
||||||
_position += ( _idealPosition - _position ) * t;
|
_position += ( _idealPosition - _position ) * t;
|
||||||
|
_yaw += ( _idealYaw - _yaw ) * t;
|
||||||
|
|
||||||
// generate the ortho-normals for the orientation based on the Euler angles
|
// generate the ortho-normals for the orientation based on the Euler angles
|
||||||
_orientation.setToIdentity();
|
_orientation.setToIdentity();
|
||||||
|
|
|
@ -29,21 +29,8 @@ public:
|
||||||
|
|
||||||
void update( float deltaTime );
|
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 setMode ( CameraMode m ) { _mode = m; }
|
||||||
void setYaw ( float y ) { _yaw = y; }
|
void setYaw ( float y ) { _idealYaw = y; }
|
||||||
void setPitch ( float p ) { _pitch = p; }
|
void setPitch ( float p ) { _pitch = p; }
|
||||||
void setRoll ( float r ) { _roll = r; }
|
void setRoll ( float r ) { _roll = r; }
|
||||||
void setUp ( float u ) { _up = u; }
|
void setUp ( float u ) { _up = u; }
|
||||||
|
|
Loading…
Reference in a new issue