diff options
Diffstat (limited to 'gfx/models/obj.ll')
-rw-r--r-- | gfx/models/obj.ll | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/gfx/models/obj.ll b/gfx/models/obj.ll index 9329a5a..a9a857b 100644 --- a/gfx/models/obj.ll +++ b/gfx/models/obj.ll @@ -43,8 +43,8 @@ falsey (0|off) } <INITIAL>"f " { BEGIN(FACE); - faces.emplace_back(); - faces.back().emplace_back(); + objects.back().second.emplace_back(); + objects.back().second.back().emplace_back(); axis = 0; } <INITIAL>"mtllib " { @@ -81,7 +81,7 @@ falsey (0|off) // fprintf(stderr, "MTLLIB <%s>\n", YYText()); } <OBJECT>{linestring} { - // fprintf(stderr, "OBJECT <%s>\n", YYText()); + objects.emplace_back(YYText(), Faces{}); } <SMOOTH>{truthy} { // fprintf(stderr, "Set smooth\n"); @@ -99,13 +99,13 @@ falsey (0|off) texCoords.back()[axis++] = std::stof(YYText()); } <FACE>{index} { - faces.back().back()[axis] = std::stoi(YYText()); + objects.back().second.back().back()[axis] = std::stoi(YYText()); } <FACE>\/ { axis++; } <FACE>[ \t] { - faces.back().emplace_back(); + objects.back().second.back().emplace_back(); axis = 0; } |