History

Merge branch 'master' of https://github.com/worklist/hifi into 19483

stojce committed 12 years ago

Commit 36d21e82 parents 669ab21 ea63f0526 files · +48 −27060Browse files

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

Unified · Split

interface/src/Application.cpp+13−2
@@ -1474,6 +1474,11 @@ void Application::setFullscreen(bool fullscreen) { · 1473 unmodified lines
14741474 (_window->windowState() & ~Qt::WindowFullScreen));
14751475 }
14761476
1477+void Application::setEnable3DTVMode(bool enable3DTVMode) {
1478+ resizeGL(_glWidget->width(),_glWidget->height());
1479+}
1480+
1481+
14771482 void Application::setRenderVoxels(bool voxelRender) {
14781483 _voxelEditSender.setShouldSend(voxelRender);
14791484 if (!voxelRender) {
@@ -2075,17 +2080,23 @@ void Application::updateMyAvatarLookAtPosition(glm::vec3& lookAtSpot, glm::vec3& · 595 unmodified lines
20752080 bool showWarnings = Menu::getInstance()->isOptionChecked(MenuOption::PipelineWarnings);
20762081 PerformanceWarning warn(showWarnings, "Application::updateMyAvatarLookAtPosition()");
20772082
2083+ const float FAR_AWAY_STARE = TREE_SCALE;
20782084 if (_myCamera.getMode() == CAMERA_MODE_MIRROR) {
20792085 lookAtSpot = _myCamera.getPosition();
20802086
2087+ } else if (_mouseHidden) {
2088+ // if the mouse cursor is hidden, just look straight ahead
2089+ glm::vec3 rayOrigin, rayDirection;
2090+ _viewFrustum.computePickRay(0.5f, 0.5f, rayOrigin, rayDirection);
2091+ lookAtSpot = rayOrigin + rayDirection * FAR_AWAY_STARE;
2092+
20812093 } else if (!_lookatTargetAvatar) {
20822094 if (_isHoverVoxel) {
20832095 // Look at the hovered voxel
20842096 lookAtSpot = getMouseVoxelWorldCoordinates(_hoverVoxel);
20852097
20862098 } else {
2087− // Just look in direction of the mouse ray
2088− const float FAR_AWAY_STARE = TREE_SCALE;
2099+ // Just look in direction of the mouse ray
20892100 lookAtSpot = lookAtRayOrigin + lookAtRayDirection * FAR_AWAY_STARE;
20902101 }
20912102 }

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