OBJExporter - exports bigger obj file size that what was loaded into scene

Okay, this is a limitation of the OBJLoader, not the exporter. The loader is only able to produce a so called non-indexed geometry. When this geometry representation is exported again, the resulting file gets bigger.

An indexed geometry is useful if a lot of vertices are shared. In this case, a vertex is define only once and face indices just point to it. A non-indexed geometry has no shared vertices. All faces have unique vertices even if certain vertices have identical values.

Sorry, there is no easy way to fix this in OBJLoader but you might want to try OBJLoader2 which supports indexed-geometries.

2 Likes