draw all triangles instead of the first 12,

added todo section to the README.md,
clean up code
This commit is contained in:
Anakin
2016-10-23 16:01:06 +02:00
parent 6d5489a96c
commit 5cec0128cd
6 changed files with 38 additions and 16 deletions

View File

@@ -247,7 +247,7 @@ void OpenGLController::updateScene()
glVertexAttribPointer(1, 2, GL_FLOAT, GL_FALSE, 0, 0);
//draw objects
glDrawArrays(GL_TRIANGLES, 0, 12 * 3);
glDrawArrays(GL_TRIANGLES, 0, ui32MeshSize * 3);
//close attributes
glDisableVertexAttribArray(0);
@@ -288,6 +288,7 @@ void OpenGLController::loadMsh(const char * path)
vfVertices = obj.getVertex();
vfUV = obj.getUV();
listTextures = obj.getTexture();
ui32MeshSize = obj.getSize().front();
}
catch (std::invalid_argument e)
{