History

resolve conflicts on merge with upstream master

Stephen Birarda committed 13 years ago

Commit 73d3ecc2 parents 8f1135f c48856d23 files · +1314 −291Browse files

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

Unified · Split

interface/src/Application.cpp+32−16
@@ -1394,13 +1394,13 @@ void Application::increaseVoxelSize() { · 1393 unmodified lines
13941394
13951395 const int MAXIMUM_EDIT_VOXEL_MESSAGE_SIZE = 1500;
13961396 struct SendVoxelsOperationArgs {
1397− unsigned char* newBaseOctCode;
1397+ const unsigned char* newBaseOctCode;
13981398 };
13991399
14001400 bool Application::sendVoxelsOperation(VoxelNode* node, void* extraData) {
14011401 SendVoxelsOperationArgs* args = (SendVoxelsOperationArgs*)extraData;
14021402 if (node->isColored()) {
1403− unsigned char* nodeOctalCode = node->getOctalCode();
1403+ const unsigned char* nodeOctalCode = node->getOctalCode();
14041404
14051405 unsigned char* codeColorBuffer = NULL;
14061406 int codeLength = 0;
@@ -2784,24 +2784,40 @@ void Application::displayOverlay() { · 1377 unmodified lines
27842784 if (Menu::getInstance()->isOptionChecked(MenuOption::HeadMouse)
27852785 && !Menu::getInstance()->isOptionChecked(MenuOption::Mirror)
27862786 && USING_INVENSENSE_MPU9150) {
2787− // Display small target box at center or head mouse target that can also be used to measure LOD
2788− glColor3f(1.0, 1.0, 1.0);
2787+ // Display small target box at center or head mouse target that can also be used to measure LOD
2788+ glColor3f(1.0, 1.0, 1.0);
2789+ glDisable(GL_LINE_SMOOTH);
2790+ const int PIXEL_BOX = 16;
2791+ glBegin(GL_LINES);
2792+ glVertex2f(_headMouseX - PIXEL_BOX/2, _headMouseY);
2793+ glVertex2f(_headMouseX + PIXEL_BOX/2, _headMouseY);
2794+ glVertex2f(_headMouseX, _headMouseY - PIXEL_BOX/2);
2795+ glVertex2f(_headMouseX, _headMouseY + PIXEL_BOX/2);
2796+ glEnd();
2797+ glEnable(GL_LINE_SMOOTH);
2798+ glColor3f(1.f, 0.f, 0.f);
2799+ glPointSize(3.0f);
2800+ glDisable(GL_POINT_SMOOTH);
2801+ glBegin(GL_POINTS);
2802+ glVertex2f(_headMouseX - 1, _headMouseY + 1);
2803+ glEnd();
2804+ // If Faceshift is active, show eye pitch and yaw as separate pointer
2805+ if (_faceshift.isActive()) {
2806+ const float EYE_TARGET_PIXELS_PER_DEGREE = 40.0;
2807+ int eyeTargetX = (_glWidget->width() / 2) - _faceshift.getEstimatedEyeYaw() * EYE_TARGET_PIXELS_PER_DEGREE;
2808+ int eyeTargetY = (_glWidget->height() / 2) - _faceshift.getEstimatedEyePitch() * EYE_TARGET_PIXELS_PER_DEGREE;
2809+
2810+ glColor3f(0.0, 1.0, 1.0);
27892811 glDisable(GL_LINE_SMOOTH);
2790− const int PIXEL_BOX = 16;
27912812 glBegin(GL_LINES);
2792− glVertex2f(_headMouseX - PIXEL_BOX/2, _headMouseY);
2793− glVertex2f(_headMouseX + PIXEL_BOX/2, _headMouseY);
2794− glVertex2f(_headMouseX, _headMouseY - PIXEL_BOX/2);
2795− glVertex2f(_headMouseX, _headMouseY + PIXEL_BOX/2);
2796− glEnd();
2797− glEnable(GL_LINE_SMOOTH);
2798− glColor3f(1.f, 0.f, 0.f);
2799− glPointSize(3.0f);
2800− glDisable(GL_POINT_SMOOTH);
2801− glBegin(GL_POINTS);
2802− glVertex2f(_headMouseX - 1, _headMouseY + 1);
2813+ glVertex2f(eyeTargetX - PIXEL_BOX/2, eyeTargetY);
2814+ glVertex2f(eyeTargetX + PIXEL_BOX/2, eyeTargetY);
2815+ glVertex2f(eyeTargetX, eyeTargetY - PIXEL_BOX/2);
2816+ glVertex2f(eyeTargetX, eyeTargetY + PIXEL_BOX/2);
28032817 glEnd();
2818+
28042819 }
2820+ }
28052821
28062822 // Show detected levels from the serial I/O ADC channel sensors
28072823 if (_displayLevels) _serialHeadSensor.renderLevels(_glWidget->width(), _glWidget->height());

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