mirror of
https://github.com/HifiExperiments/overte.git
synced 2025-08-07 21:40:20 +02:00
clean up
This commit is contained in:
parent
a75f655e40
commit
e923f5446d
2 changed files with 21 additions and 18 deletions
|
@ -403,7 +403,10 @@ void Avatar::simulate(float deltaTime) {
|
|||
if (tiltDecay < 0.0f) {tiltDecay = 0.0f;}
|
||||
_bodyPitch *= tiltDecay;
|
||||
_bodyRoll *= tiltDecay;
|
||||
|
||||
|
||||
//wtf? - why won't this compile?
|
||||
//angleBetween(&_orientation.getUp(), &_gravity);
|
||||
|
||||
// update position by velocity
|
||||
_position += _velocity * deltaTime;
|
||||
|
||||
|
|
|
@ -13,22 +13,22 @@
|
|||
|
||||
Camera::Camera() {
|
||||
_frustumNeedsReshape = false;
|
||||
_mode = CAMERA_MODE_THIRD_PERSON;
|
||||
_tightness = 10.0; // default
|
||||
_fieldOfView = 60.0; // default
|
||||
_nearClip = 0.08; // default
|
||||
_farClip = 50.0 * TREE_SCALE; // default
|
||||
_modeShift = 0.0;
|
||||
_yaw = 0.0;
|
||||
_pitch = 0.0;
|
||||
_roll = 0.0;
|
||||
_upShift = 0.0;
|
||||
_rightShift = 0.0;
|
||||
_distance = 0.0;
|
||||
_idealYaw = 0.0;
|
||||
_targetPosition = glm::vec3(0.0, 0.0, 0.0);
|
||||
_position = glm::vec3(0.0, 0.0, 0.0);
|
||||
_idealPosition = glm::vec3(0.0, 0.0, 0.0);
|
||||
_mode = CAMERA_MODE_THIRD_PERSON;
|
||||
_tightness = 10.0; // default
|
||||
_fieldOfView = 60.0; // default
|
||||
_nearClip = 0.08; // default
|
||||
_farClip = 50.0 * TREE_SCALE; // default
|
||||
_modeShift = 0.0;
|
||||
_yaw = 0.0;
|
||||
_pitch = 0.0;
|
||||
_roll = 0.0;
|
||||
_upShift = 0.0;
|
||||
_rightShift = 0.0;
|
||||
_distance = 0.0;
|
||||
_idealYaw = 0.0;
|
||||
_targetPosition = glm::vec3(0.0, 0.0, 0.0);
|
||||
_position = glm::vec3(0.0, 0.0, 0.0);
|
||||
_idealPosition = glm::vec3(0.0, 0.0, 0.0);
|
||||
_orientation.setToIdentity();
|
||||
}
|
||||
|
||||
|
@ -38,7 +38,7 @@ void Camera::update(float deltaTime) {
|
|||
if (_mode == CAMERA_MODE_NULL) {
|
||||
_modeShift = 0.0;
|
||||
} else {
|
||||
// use iterative forces to keep the camera at the desired position and angle
|
||||
// use iterative forces to push the camera towards the desired position and angle
|
||||
updateFollowMode(deltaTime);
|
||||
|
||||
if (_modeShift < 1.0f) {
|
||||
|
|
Loading…
Reference in a new issue