Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2019-05-16 16:01:17 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2019-05-16 17:43:14 +0300
commit901868a4b2fc6e70d9c74119d97c57de132859a3 (patch)
tree94f96b6fd5f8a1ec509c6551f504cad958c1688f /add_curve_ivygen.py
parent2e5b7a4a044ab982af66def583ae16bb563a1357 (diff)
Update for Depsgraph API changes
Addresses new behavior of object.to_mesh(). This is corresponding part for D4875. Reviewers: brecht Reviewed By: brecht Differential Revision: https://developer.blender.org/D4876
Diffstat (limited to 'add_curve_ivygen.py')
-rw-r--r--add_curve_ivygen.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/add_curve_ivygen.py b/add_curve_ivygen.py
index 60f6ec59..7c683846 100644
--- a/add_curve_ivygen.py
+++ b/add_curve_ivygen.py
@@ -439,12 +439,13 @@ def bvhtree_from_object(ob):
bm = bmesh.new()
depsgraph = context.evaluated_depsgraph_get()
- mesh = ob.evaluated_get(depsgraph).to_mesh()
+ ob_eval = ob.evaluated_get(depsgraph)
+ mesh = ob_eval.to_mesh()
bm.from_mesh(mesh)
bm.transform(ob.matrix_world)
bvhtree = BVHTree.FromBMesh(bm)
- bpy.data.meshes.remove(mesh)
+ ob_eval.to_mesh_clear()
return bvhtree
def check_mesh_faces(ob):