History

Merge branch 'master' of https://github.com/highfidelity/hifi into domain-tunnel

Stephen Birarda committed 12 years ago

Commit 76d00f32 parents f637f5a 2a8b00224 files · +1219 −168Browse files

Showing the changes to interface/src/Application.cpp (1 of 24 files). Show all

Unified · Split

interface/src/Application.cpp+5−2
@@ -600,10 +600,14 @@ void Application::paintGL() { · 599 unmodified lines
600 600
601 if (_myCamera.getMode() == CAMERA_MODE_FIRST_PERSON) {601 if (_myCamera.getMode() == CAMERA_MODE_FIRST_PERSON) {
602 if (!OculusManager::isConnected()) {602 if (!OculusManager::isConnected()) {
603 // If there isn't an HMD, match exactly to avatar's head
603 _myCamera.setPosition(_myAvatar->getHead()->getEyePosition());604 _myCamera.setPosition(_myAvatar->getHead()->getEyePosition());
604 _myCamera.setRotation(_myAvatar->getHead()->getCameraOrientation());605 _myCamera.setRotation(_myAvatar->getHead()->getCameraOrientation());
606 } else {
607 // For an HMD, set the base position and orientation to that of the avatar body
608 _myCamera.setPosition(_myAvatar->getDefaultEyePosition());
609 _myCamera.setRotation(_myAvatar->getWorldAlignedOrientation());
605 }610 }
606 // OculusManager::display() updates camera position and rotation a bit further on.
607 611
608 } else if (_myCamera.getMode() == CAMERA_MODE_THIRD_PERSON) {612 } else if (_myCamera.getMode() == CAMERA_MODE_THIRD_PERSON) {
609 static const float THIRD_PERSON_CAMERA_DISTANCE = 1.5f;613 static const float THIRD_PERSON_CAMERA_DISTANCE = 1.5f;
@@ -659,7 +663,6 @@ void Application::paintGL() { · 49 unmodified lines
659 663
660 _viewFrustumOffsetCamera.setRotation(_myCamera.getRotation() * frustumRotation);664 _viewFrustumOffsetCamera.setRotation(_myCamera.getRotation() * frustumRotation);
661 665
662 _viewFrustumOffsetCamera.initialize(); // force immediate snap to ideal position and orientation
663 _viewFrustumOffsetCamera.update(1.f/_fps);666 _viewFrustumOffsetCamera.update(1.f/_fps);
664 whichCamera = &_viewFrustumOffsetCamera;667 whichCamera = &_viewFrustumOffsetCamera;
665 }668 }

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t