diff options
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/blenkernel/BKE_multires.h | 4 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/multires.c | 11 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/multires_reshape.c | 2 |
3 files changed, 10 insertions, 7 deletions
diff --git a/source/blender/blenkernel/BKE_multires.h b/source/blender/blenkernel/BKE_multires.h index c3b1163cd3e..3ea5986a0ae 100644 --- a/source/blender/blenkernel/BKE_multires.h +++ b/source/blender/blenkernel/BKE_multires.h @@ -91,8 +91,8 @@ int multires_get_level(const struct Scene *scene, bool render, bool ignore_simplify); struct Mesh *BKE_multires_create_mesh(struct Depsgraph *depsgraph, - struct MultiresModifierData *mmd, - struct Object *ob); + struct Object *object, + struct MultiresModifierData *mmd); void multiresModifier_del_levels(struct MultiresModifierData *mmd, struct Scene *scene, struct Object *object, diff --git a/source/blender/blenkernel/intern/multires.c b/source/blender/blenkernel/intern/multires.c index 290bed02913..b8464bf02c0 100644 --- a/source/blender/blenkernel/intern/multires.c +++ b/source/blender/blenkernel/intern/multires.c @@ -270,14 +270,17 @@ static MDisps *multires_mdisps_initialize_hidden(Mesh *me, int level) return mdisps; } -Mesh *BKE_multires_create_mesh(struct Depsgraph *depsgraph, MultiresModifierData *mmd, Object *ob) +Mesh *BKE_multires_create_mesh(struct Depsgraph *depsgraph, + Object *object, + MultiresModifierData *mmd) { - Object *ob_eval = DEG_get_evaluated_object(depsgraph, ob); + Object *object_eval = DEG_get_evaluated_object(depsgraph, object); Scene *scene_eval = DEG_get_evaluated_scene(depsgraph); - Mesh *deformed_mesh = mesh_get_eval_deform(depsgraph, scene_eval, ob_eval, &CD_MASK_BAREMESH); + Mesh *deformed_mesh = mesh_get_eval_deform( + depsgraph, scene_eval, object_eval, &CD_MASK_BAREMESH); ModifierEvalContext modifier_ctx = { .depsgraph = depsgraph, - .object = ob_eval, + .object = object_eval, .flag = MOD_APPLY_USECACHE | MOD_APPLY_IGNORE_SIMPLIFY, }; diff --git a/source/blender/blenkernel/intern/multires_reshape.c b/source/blender/blenkernel/intern/multires_reshape.c index 657dfcec42f..6097121fefd 100644 --- a/source/blender/blenkernel/intern/multires_reshape.c +++ b/source/blender/blenkernel/intern/multires_reshape.c @@ -109,7 +109,7 @@ bool multiresModifier_reshapeFromDeformModifier(struct Depsgraph *depsgraph, /* Create mesh for the multires, ignoring any further modifiers (leading * deformation modifiers will be applied though). */ - Mesh *multires_mesh = BKE_multires_create_mesh(depsgraph, &highest_mmd, object); + Mesh *multires_mesh = BKE_multires_create_mesh(depsgraph, object, &highest_mmd); int num_deformed_verts; float(*deformed_verts)[3] = BKE_mesh_vert_coords_alloc(multires_mesh, &num_deformed_verts); |