Skip to content

Failure converting a trimesh mesh #778

@villares

Description

@villares

I have generated a scene that crashes on py5 conversion. I can open it on FreeCAD & Blender.
Image

Using this file to reproduce: https://github.com/villares/py5generator/blob/file_for_issue/waffle_scene.glb

import py5
import trimesh

m = trimesh.load_mesh('waffle_scene.glb')

def setup():
    py5.size(600, 600, py5.P3D)
    ps = py5.convert_shape(m)
    # py5.shape(ps) # doesn't reach this
    
py5.run_sketch()

I get this on py5 0.10.10a7:

py5 encountered an error in your code:

File "/home/villares/GitHub/python_play_reboot/py5_play/trimesh_sliceform/conversion_issue.py", line 10, in _py5_faux_setup
    7    def setup():
    8        py5.size(600, 600, py5.P3D)
    9        
--> 10       ps = py5.convert_shape(m)
    ..................................................
     m = <trimesh.Trimesh(vertices.shape=(7124, 3), faces.shape=(1419
          2, 3))>
    ..................................................

OverflowError: Python integer 65536 out of bounds for uint8

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions