Merge pull request #4716 from HiMemX/master

Minor obj export bugfix
pull/4715/head
Kim Kulling 2022-09-08 12:51:31 +02:00 committed by GitHub
commit d475c132bf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -269,12 +269,12 @@ void ObjExporter::WriteGeometryFile(bool noMtl) {
if ( !useVc ) { if ( !useVc ) {
mOutput << "# " << vp.size() << " vertex positions" << endl; mOutput << "# " << vp.size() << " vertex positions" << endl;
for ( const vertexData& v : vp ) { for ( const vertexData& v : vp ) {
mOutput << "v " << v.vp.x << " " << v.vp.y << " " << v.vp.z << endl; mOutput << "v " << v.vp.x << " " << v.vp.y << " " << v.vp.z << endl;
} }
} else { } else {
mOutput << "# " << vp.size() << " vertex positions and colors" << endl; mOutput << "# " << vp.size() << " vertex positions and colors" << endl;
for ( const vertexData& v : vp ) { for ( const vertexData& v : vp ) {
mOutput << "v " << v.vp.x << " " << v.vp.y << " " << v.vp.z << " " << v.vc.r << " " << v.vc.g << " " << v.vc.b << endl; mOutput << "v " << v.vp.x << " " << v.vp.y << " " << v.vp.z << " " << v.vc.r << " " << v.vc.g << " " << v.vc.b << endl;
} }
} }
mOutput << endl; mOutput << endl;