PDA

View Full Version : Obj exporter too slow



Dennik
05-23-2019, 09:40 AM
I have a dense laser scanned object that I brought into modeler and tried to export back to OBJ format.
The obj exporter is taking ages to save it. I'm talking 100kb per second speed on an SSD drive.
I know it shouldn't take too long cause I've saved it from other applications as well.
What's going on?

Sensei
05-23-2019, 10:24 AM
OBJ exporter is storing indexes to vertexes and indexes to polygons (faces),
so it has to convert internal LWPntID (pointer) to index,
and internal LWPolID (pointer) to index.
If functions of looking up points and polygons have not been optimized,
the whole exporting tool will be very slow (and getting slower and slower with increasing amount of geometry).

What is point and poly count of your object?

Dennik
05-23-2019, 10:48 AM
Its about 3.3mil polygons. About 1.6mil vertices.

Sensei
05-23-2019, 11:32 AM
Maybe as a workaround try exporting it in some common file format, and then use 3rd party app to export from it..

Dennik
05-23-2019, 11:37 AM
Yep. I exported it already through STL. Lightwave has got me used to workarounds for decades now.

Axis3d
05-23-2019, 01:52 PM
I'm trying out Meshlab. Its free and also has import/export options. It has mesh optimizations/cleaning up, and uses the gpu to speed up things.

jwiede
05-25-2019, 07:23 PM
Quality matters. Few customers will tolerate endless "necessary" workarounds. Oh well.

Sensei
05-25-2019, 11:02 PM
Quality matters. Few customers will tolerate endless "necessary" workarounds. Oh well.

During writing software you always deal with workarounds.. ;)
Not talking about LWSDK. But generally.
...or maybe I am always dealing with nonstandard things, which authors of API didn't think about in advance.. ;)

Workarounds on Android OS... entire code of app is just one big workaround.. ;)

jwiede
05-26-2019, 07:17 PM
Wavefront OBJ is among the oldest 3D formats out there, and still among the most-used. There's no acceptable excuse for any modern 3D pkg to lack efficient OBJ+MTL import/export, period.

Sensei
05-27-2019, 03:52 AM
Wavefront OBJ is among the oldest 3D formats out there, and still among the most-used. There's no acceptable excuse for any modern 3D pkg to lack efficient OBJ+MTL import/export, period.

Efficiency is relative.. ;)
With OBJ file format one desperate enough developer, could split parsing to separate threads and get ~8 times boost on 4 core (8 HT) machine etc. ..
Obviously it would cost money.. money spend on programmer salary. The more often used functionality of app, the more import is optimization.
How many times "average LW user" is loading/saving OBJ per day? Per month? Per year? I don't think so it is huge number.
If I would be annoyed by speed of OBJ exporter, I would write my own OBJ exporter in this hour.