Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Obj importer does not work with multiobject files #275

Open
korken89 opened this issue Apr 9, 2021 · 1 comment
Open

Obj importer does not work with multiobject files #275

korken89 opened this issue Apr 9, 2021 · 1 comment

Comments

@korken89
Copy link

korken89 commented Apr 9, 2021

Hi!

When importing OBJ files the importer does not under stand lines that start with o SOME_NAME, which is a new object within the file.
This causes the generated mesh to not make sense at all. Sometimes this also causes the imported to panic:

Warning: unknown line 1 ignored: `o SOLID.128'
At line 823: could not find the material Planed
Warning: unknown line 824 ignored: `s off'
thread 'main' panicked at 'index out of bounds: the len is 0 but the index is 14359', /home/emifre/.cargo/registry/src/github.com-1ecc6299db9ec823/kiss3d-0.30.0/src/loader/obj.rs:436:41
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

I am not sure how to help with this issue unfortunately.
Is there a way to get around it? For example I had a look for an STL importer, but this did not exist unfortunately.

@virtualritz
Copy link

Use the tobj crate until this is fixed? It supports triangulation on import so getting meshes in a format ready for kiss3d is painless.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants