encoder error: Failed loading the input mesh
I'm getting errors encoding some meshes - here is a sample mesh exported to obj and ply button.zip
encoding the mesh exported without normals:
$ draco_encoder -i button.obj -o o.drc
Failed loading the input mesh.
I found that the same mesh when exported to PLY with normals gives another error message:
$ draco_encoder -i button_normals.ply -o o.drc
Encoder options:
Compression level = 7
Positions: Quantization = 14 bits
Normals: Quantization = 10 bits
terminate called after throwing an instance of 'std::out_of_range'
what(): vector::_M_range_check: __n (which is 223) >= this->size() (which is 114)
Aborted (core dumped)
I have a project with >1000 meshes and ~5% of them fail to encode with draco while they all encode properly with CTM or corto
if you need anything else to investigate the problem please let me know.
@llin55 Thanks for the report. I'll investigate it
@llin55 The problem is that the input files contain non-triangular polygons that are currently not supported by Draco. To be more specific Draco automatically triangulates quad polygons into two triangles but the linked .obj has a 20-side polygonal face that Draco currently cannot process.
While in future releases we may add support for general polygons, for now I would recommend to triangulate your models before they are send to draco (that can be done for example by Meshlab).
@ondys Has the problem been solved?
Has it?
any news?
yes, mesh triangulation solves the problem
yes, mesh triangulation solves the problem
what does mesh triangulation mean
Hi, What about mesh that are not supposed to be triangulated? (Points or curves) I supposed that we have to use PointCloud encoder but can we mix mesh buffer and point cloud buffer in the same draco buffer?
Is there a way to uniformise them to mesh?
This error can also happen if you have degenerate indices (if a tri is specified by indices i0,i1,i2 and i0 == i1 || i0 == i2 || i1 == i2). If you prune these indices, make sure that the indices count is > 0 otherwise you will get a different error ("Could not convert indices")