Working version for linux

This commit is contained in:
jancoow
2016-06-20 20:00:58 +02:00
parent f84fcfa4e2
commit 030a136e8b
11 changed files with 36 additions and 24 deletions
+2 -2
View File
@@ -138,7 +138,7 @@ Model::Model(std::string fileName)
radius = fmax(radius, (center.x - v.x) * (center.x - v.x) + (center.z - v.z) * (center.z - v.z));
radius = sqrt(radius);
for each(ObjGroup *group in groups)
for (ObjGroup *group : groups)
{
Optimise(group);
}
@@ -148,7 +148,7 @@ void Model::Optimise(ObjGroup *t)
{
for (Face &face : t->faces)
{
for each(auto &vertex in face.vertices)
for (auto &vertex : face.vertices)
{
t->VertexArray.push_back(Vertex(vertices[vertex.position].x, vertices[vertex.position].y, vertices[vertex.position].z,
normals[vertex.normal].x, normals[vertex.normal].y, normals[vertex.normal].z,