diff --git a/src/viewer/simpleViewer.cpp b/src/viewer/simpleViewer.cpp index 64a70c0..1247ec3 100644 --- a/src/viewer/simpleViewer.cpp +++ b/src/viewer/simpleViewer.cpp @@ -153,16 +153,6 @@ void Viewer::draw() modelViewMatrix.rotate(30,0,1,0); - - glBindVertexArray(m_VAOs[VAO_Sphere]); - m_program->setUniformValue(m_isSkyLoc, false); - m_program->setUniformValue(m_mvMatrixLocation, modelViewMatrix); - m_program->setUniformValue(m_normalMatrixLoc, modelViewMatrix.normalMatrix()); - m_program->setUniformValue(m_colorLocation, QColor(255, 255, 255, 255)); - m_program->setUniformValue(m_drawTextLoc, false); - - glDrawElements(GL_TRIANGLES, numTriSphere * 3, GL_UNSIGNED_INT, 0); - m_program->setUniformValue(m_projMatrixLocation, projectionMatrix); m_program->setUniformValue(m_mvMatrixLocation, modelViewMatrix); @@ -277,7 +267,7 @@ void Viewer::init() SceneGroup *c = new SceneGroup(); c->addChild(cube); - //c->addChild(selection); + c->addChild(selection); root.addChild(c); } } @@ -483,7 +473,7 @@ void Viewer::initGeometries() GLfloat sphereVertices[numVerticesSphere][3]; GLfloat sphereNormals[numVerticesSphere][3]; - GLfloat sphereIndices[numTriSphere * 3][3]; + GLuint sphereIndices[numTriSphere * 3][3]; // Create Sphere // Generate surrounding vertices @@ -619,7 +609,6 @@ void Viewer::initGeometries() void Viewer::visit(Cube &s) { - return; QMatrix4x4 modelViewMatrix = modelStack.top() * QMatrix4x4(s.transform); int faces = floor(numVerticesCube/6);