Fixade lite i obj load

This commit is contained in:
ViktorLjung
2014-03-09 21:27:33 +01:00
parent 9198c2dcb5
commit 3138eea0c2
2 changed files with 8 additions and 10 deletions
+8 -4
View File
@@ -170,16 +170,20 @@ void Model::CreateBuffers( std::vector<glm::vec3> _Vertices, std::vector<glm::ve
GLERROR("GLEW: BufferFail4"); GLERROR("GLEW: BufferFail4");
glBindBuffer(GL_ARRAY_BUFFER, VertexBuffer); glBindBuffer(GL_ARRAY_BUFFER, VertexBuffer);
glVertexAttribPointer(0, 3, GL_FLOAT, GL_FALSE, 0, 0); glVertexAttribPointer(0, 1, GL_FLOAT, GL_FALSE, 0, 0);
GLERROR("GLEW: BufferFail5"); GLERROR("GLEW: BufferFail5");
glBindBuffer(GL_ARRAY_BUFFER, NormalBuffer);
glVertexAttribPointer(1, 1, GL_FLOAT, GL_FALSE, 0, 0);
GLERROR("GLEW: BufferFail5");
// glBindBuffer(GL_ARRAY_BUFFER, TextureCoordBuffer); glBindBuffer(GL_ARRAY_BUFFER, TextureCoordBuffer);
// glVertexAttribPointer(2, 2, GL_FLOAT, GL_FALSE, 0, 0); glVertexAttribPointer(2, 1, GL_FLOAT, GL_FALSE, 0, 0);
GLERROR("GLEW: BufferFail5");
glEnableVertexAttribArray(0); glEnableVertexAttribArray(0);
glEnableVertexAttribArray(1); glEnableVertexAttribArray(1);
/* glEnableVertexAttribArray(2);*/ glEnableVertexAttribArray(2);
GLERROR("GLEW: BufferFail5"); GLERROR("GLEW: BufferFail5");
} }
-6
View File
@@ -29,15 +29,9 @@ void Systems::RenderSystem::UpdateEntity( double dt, EntityID entity, EntityID p
m_Renderer->AddModelToDraw(model, transformComponent->Position, transformComponent->Orientation); m_Renderer->AddModelToDraw(model, transformComponent->Position, transformComponent->Orientation);
} }
void Systems::RenderSystem::Update( double dt )
{
}