Skip to content

Loading custom objects? #8

Answered by rafael-fuente
sidgairo18 asked this question in Q&A
Discussion options

You must be logged in to vote

I have implemented a class named TriangleMesh to load arbitrary .obj files as triangle meshes. So, first convert your .stl file to a .obj format.

However, the rendering is quite slow because we need to loop for every triangle of the mesh, and Python loops are very slow. A bounding volume hierarchy acceleration structure could be implemented, but I think renders will still take a lot of time.

If you want to render arbitrary triangle meshes, Python isn't the language to work with. An implementation in a compiled language like C++ should be needed for speed.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by rafael-fuente
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #7 on June 06, 2021 17:33.