From 1c23a067069463190b084af9560d4fe6263e6fe2 Mon Sep 17 00:00:00 2001 From: Hans Goudey Date: Fri, 21 Jan 2022 16:04:16 -0600 Subject: Fix: Applying object transform can create normal layers Because this operator is used on original objects, it's best to tag the normals dirty instead of explicitly calculating them, to avoid unnecessarily storing normal layers on an original object (since they might have to be recalculated during evaluation anyway). There may be other places this change is helpful, but being conservative is likely better for now. Related to T95125 --- source/blender/editors/object/object_transform.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source/blender/editors') diff --git a/source/blender/editors/object/object_transform.c b/source/blender/editors/object/object_transform.c index c320313643d..6d04bd3f9d5 100644 --- a/source/blender/editors/object/object_transform.c +++ b/source/blender/editors/object/object_transform.c @@ -811,8 +811,8 @@ static int apply_objects_internal(bContext *C, /* adjust data */ BKE_mesh_transform(me, mat, true); - /* update normals */ - BKE_mesh_calc_normals(me); + /* If normal layers exist, they are now dirty. */ + BKE_mesh_normals_tag_dirty(me); } else if (ob->type == OB_ARMATURE) { bArmature *arm = ob->data; -- cgit v1.2.3