HTDerekLiu / BlenderToolbox

Some simple Blender scripts for rendering paper figures
Apache License 2.0
624 stars 61 forks source link

Large mesh rendering crash #20

Closed Taiyuan-Zhang closed 7 months ago

Taiyuan-Zhang commented 8 months ago

I can't find a version of Blender 4.0.0. When using Blender 4.0.2 or 3.6, the rendering process will occupy 100% hard disk and then crash without any error or warning. Mesh of small size like spot.obj can be rendered, but a little bit larger model like armadillo crashes. It seems like it gets stuck at the set shading stage.

HTDerekLiu commented 7 months ago

Which material were you using? Some functions (e.g., drawEdgeSubset) will take a long time if you have too many edges because it is simply a for loop over them and then duplicate a mesh for each edge. But most functions should be fine, for instance, here is my simple test of the plastic material on an armadillo with 80K faces. demo_plastic

If there is a specific effect you hope to create, perhaps there is an alternative scalable way to achieve something similar.

HTDerekLiu commented 7 months ago

I just updated the drawEdgeSubset function and now it should be faster, if that is the one you are using. Currently the change is only on the repo, not in the version in pip yet. So you will have to use the old way: executing it by calling blender -b -P XXX.py for now. Hope that can solve your problem!