Skip to content
Snippets Groups Projects
Commit 9ab813dd authored by Ludwig Jaeck's avatar Ludwig Jaeck
Browse files

reduces stream operations 2

parent 838d917d
No related branches found
No related tags found
1 merge request!10De/Serialization for wavefront object files
Pipeline #79499 passed
......@@ -30,8 +30,7 @@ std::ostream& serialize_as_wavefront(std::ostream& out, const ff::Polyhedron* po
for (auto& poly : polyhedron->topology().faces) {
if (poly.vertexIndices.size() == 0)
continue;
out << "f"
<< " ";
out << "f ";
for (size_t i = 0; i < poly.vertexIndices.size(); i++) {
out << poly.vertexIndices[i] + 1;
out << (i == poly.vertexIndices.size() - 1 ? "\n" : " ");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment