Skip to content
Snippets Groups Projects
Commit c3c0fd18 authored by Philipp Oeser's avatar Philipp Oeser
Browse files

3D Print Toolbox: update to 2.8 API

would fail to calculate Volume or Area for object with modifier

Fixes T58798
parent 816a19f2
No related branches found
No related tags found
No related merge requests found
......@@ -32,7 +32,7 @@ def bmesh_copy_from_object(obj, transform=True, triangulate=True, apply_modifier
if apply_modifiers and obj.modifiers:
import bpy
me = obj.to_mesh(bpy.context.scene, True, 'PREVIEW')
me = obj.to_mesh(depsgraph=bpy.context.depsgraph, apply_modifiers=True)
bm = bmesh.new()
bm.from_mesh(me)
bpy.data.meshes.remove(me)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment