mkeeter / kokopelli

Script-based CAD/CAM in Python (deprecated)
https://mattkeeter.com/projects/kokopelli
Other
298 stars 49 forks source link

Crash when loading a .stl file #16

Open tytouf opened 10 years ago

tytouf commented 10 years ago

The application crashes when loading a .stl file.

I connected gdb and it looks like the mesh->tdata and mesh->vdata are not correctly allocated when loading the .stl file.

Changing line 24 in libfab/formats/stl.c: mesh_reserve_v(mesh, mesh->vcount_3); with mesh_reserve_v(mesh, mesh->tcount_3); prevent the crash but then it does not seem to work correctly as my object is not displayed.

tytouf commented 10 years ago

I pushed a fix for that.

Unfortunately even after applying the fix, the model is not correctly rendered in the glcanvas.