Skip to content

Commit 6ddbb35

Browse files
committed
[#2] fix(zmodel): swap x and z coordinates for MRMs
1 parent e075f1b commit 6ddbb35

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/cli/zmodel/main.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ static void dump_wavefront(std::ostream& out,
3737
out << "# vertices\n";
3838

3939
for (const auto& item : mesh.positions) {
40-
out << "v " << item.x << " " << item.y << " " << item.z << "\n";
40+
out << "v " << item.z << " " << item.y << " " << item.x << "\n";
4141
}
4242

4343
unsigned wedge_offset = 0;
@@ -47,7 +47,7 @@ static void dump_wavefront(std::ostream& out,
4747
<< "usemtl " << msh.mat.name << "\n";
4848

4949
for (const auto& item : msh.wedges) {
50-
out << "vn " << item.normal.x << " " << item.normal.y << " " << item.normal.z << "\n";
50+
out << "vn " << item.normal.z << " " << item.normal.y << " " << item.normal.x << "\n";
5151
out << "vt " << item.texture.x << " " << item.texture.y << "\n";
5252
}
5353

0 commit comments

Comments
 (0)