[Bf-blender-cvs] [7214001] master: Fix T37837: mirror modifier merge does not place vertices at the center.
Brecht Van Lommel
noreply at git.blender.org
Wed Dec 18 11:16:24 CET 2013
Commit: 7214001cdb142cb2556135b1f6e35290c62b9a69
Author: Brecht Van Lommel
Date: Wed Dec 18 11:14:24 2013 +0100
http://developer.blender.org/rB7214001cdb142cb2556135b1f6e35290c62b9a69
Fix T37837: mirror modifier merge does not place vertices at the center.
This was broken since BMesh.
===================================================================
M source/blender/modifiers/intern/MOD_mirror.c
===================================================================
diff --git a/source/blender/modifiers/intern/MOD_mirror.c b/source/blender/modifiers/intern/MOD_mirror.c
index 1b9fcd9..ec09b80 100644
--- a/source/blender/modifiers/intern/MOD_mirror.c
+++ b/source/blender/modifiers/intern/MOD_mirror.c
@@ -187,6 +187,10 @@ static DerivedMesh *doMirrorOnAxis(MirrorModifierData *mmd,
if (UNLIKELY(len_squared_v3v3(mv_prev->co, mv->co) < tolerance_sq)) {
*vtmap_a = maxVerts + i;
tot_vtargetmap++;
+
+ /* average location */
+ mid_v3_v3v3(mv->co, mv_prev->co, mv->co);
+ copy_v3_v3(mv_prev->co, mv->co);
}
else {
*vtmap_a = -1;
More information about the Bf-blender-cvs
mailing list