Fix for #29 Normal Generation by Smoothing Group Id - Commit 3

This commit is contained in:
gopalss
2018-01-30 10:31:02 -05:00
parent 1f7b4a49c0
commit 1754669b07
2 changed files with 4 additions and 4 deletions

View File

@@ -727,10 +727,6 @@ static void Draw(const std::vector<DrawObject>& drawObjects,
glBindTexture(GL_TEXTURE_2D, 0);
}
static bool bDrawWireFrame = false;
if (!bDrawWireFrame)
return;
// draw wireframe
glDisable(GL_POLYGON_OFFSET_FILL);
glPolygonMode(GL_FRONT, GL_LINE);

View File

@@ -1944,6 +1944,8 @@ bool LoadObj(attrib_t *attrib, std::vector<shape_t> *shapes,
}
tags.push_back(tag);
continue;
}
if (token[0] == 's' && IS_SPACE(token[1])) {
@@ -1971,6 +1973,8 @@ bool LoadObj(attrib_t *attrib, std::vector<shape_t> *shapes,
shape.mesh.num_face_vertices.clear();
shape.smoothingGroupId = smGroupId;
currentSmoothingId = smGroupId;
continue;
} // smoothing group id
// Ignore unknown command.