Three.js: apply export scale factor to edges.

pull/4/head
EvilSpirit 2016-03-25 21:07:50 +06:00 committed by whitequark
parent e17a24814b
commit 46b67d5457
1 changed files with 6 additions and 1 deletions

View File

@ -1030,7 +1030,12 @@ void SolveSpaceUI::ExportMeshAsThreeJsTo(FILE *f, const std::string &filename,
// Output edges. Assume user's model colors do not obscure white edges.
for(e = sel->l.First(); e; e = sel->l.NextAfter(e)) {
fprintf(f, " [[%f, %f, %f], [%f, %f, %f]],\n",
CO(e->a), CO(e->b));
e->a.x / SS.exportScale,
e->a.y / SS.exportScale,
e->a.z / SS.exportScale,
e->b.x / SS.exportScale,
e->b.y / SS.exportScale,
e->b.z / SS.exportScale);
}
fputs(" ]\n};\n", f);