Showing the changes to interface/src/Application.cpp (1 of 2 files). Show all
Unified · Split
| @@ -609,8 +609,11 @@ void Application::paintGL() { · 608 unmodified lines | |||
| 609 | 609 | ||
| 610 | if (_myCamera.getMode() == CAMERA_MODE_FIRST_PERSON) { | 610 | if (_myCamera.getMode() == CAMERA_MODE_FIRST_PERSON) { |
| 611 | _myCamera.setTightness(0.0f); // In first person, camera follows (untweaked) head exactly without delay | 611 | _myCamera.setTightness(0.0f); // In first person, camera follows (untweaked) head exactly without delay |
| 612 | _myCamera.setTargetPosition(_myAvatar->getHead()->getEyePosition()); | 612 | if (!OculusManager::isConnected()) { |
| 613 | _myCamera.setTargetRotation(_myAvatar->getHead()->getCameraOrientation()); | 613 | _myCamera.setTargetPosition(_myAvatar->getHead()->getEyePosition()); |
| 614 | _myCamera.setTargetRotation(_myAvatar->getHead()->getCameraOrientation()); | ||
| 615 | } | ||
| 616 | // OculusManager::display() updates camera position and rotation a bit further on. | ||
| 614 | 617 | ||
| 615 | } else if (_myCamera.getMode() == CAMERA_MODE_THIRD_PERSON) { | 618 | } else if (_myCamera.getMode() == CAMERA_MODE_THIRD_PERSON) { |
| 616 | //Note, the camera distance is set in Camera::setMode() so we dont have to do it here. | 619 | //Note, the camera distance is set in Camera::setMode() so we dont have to do it here. |
| @@ -640,7 +643,9 @@ void Application::paintGL() { · 23 unmodified lines | |||
| 640 | } | 643 | } |
| 641 | 644 | ||
| 642 | // Update camera position | 645 | // Update camera position |
| 643 | _myCamera.update( 1.f/_fps ); | 646 | if (!OculusManager::isConnected()) { |
| 647 | _myCamera.update(1.f / _fps); | ||
| 648 | } | ||
| 644 | 649 | ||
| 645 | // Note: whichCamera is used to pick between the normal camera myCamera for our | 650 | // Note: whichCamera is used to pick between the normal camera myCamera for our |
| 646 | // main camera, vs, an alternate camera. The alternate camera we support right now | 651 | // main camera, vs, an alternate camera. The alternate camera we support right now |
| @@ -682,6 +687,7 @@ void Application::paintGL() { · 35 unmodified lines | |||
| 682 | } else { | 687 | } else { |
| 683 | OculusManager::display(_myAvatar->getWorldAlignedOrientation(), _myAvatar->getDefaultEyePosition(), *whichCamera); | 688 | OculusManager::display(_myAvatar->getWorldAlignedOrientation(), _myAvatar->getDefaultEyePosition(), *whichCamera); |
| 684 | } | 689 | } |
| 690 | _myCamera.update(1.f / _fps); | ||
| 685 | 691 | ||
| 686 | } else if (TV3DManager::isConnected()) { | 692 | } else if (TV3DManager::isConnected()) { |
| 687 | 693 | ||