diff options
author | Howard Trickey <howard.trickey@gmail.com> | 2014-04-16 22:17:30 +0400 |
---|---|---|
committer | Howard Trickey <howard.trickey@gmail.com> | 2014-04-16 22:19:36 +0400 |
commit | f2f3ef869237116cea90b8cd0bdaddc43c7f0af3 (patch) | |
tree | 065c2dbfe9b1528be50b1a0f1d9b593ebe3fad58 /source | |
parent | 53fd22acb4d3c1bf7164d1ecdda97c6f66e5be7a (diff) |
Fix Knife bug T39617: midpoint snap should affect intermediate points.
This reverts to the 2.69 behavior, where the snap-to-midpoint option
affected the intermediate crossed edges as well as the endpoints.
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/editors/mesh/editmesh_knife.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/editors/mesh/editmesh_knife.c b/source/blender/editors/mesh/editmesh_knife.c index 1fcff82c2a2..d973523437d 100644 --- a/source/blender/editors/mesh/editmesh_knife.c +++ b/source/blender/editors/mesh/editmesh_knife.c @@ -1395,6 +1395,12 @@ static void knife_find_line_hits(KnifeTool_OpData *kcd) isect_kind = isect_line_line_v3(kfe->v1->cageco, kfe->v2->cageco, r1, r2, p, p2); if (isect_kind >= 1 && point_is_visible(kcd, p, sint, &mats)) { memset(&hit, 0, sizeof(hit)); + if (kcd->snap_midpoints) { + /* choose intermediate point snap too */ + mid_v3_v3v3(p, kfe->v1->cageco, kfe->v2->cageco); + mid_v2_v2v2(sint, se1, se2); + lambda = 0.5f; + } hit.kfe = kfe; copy_v3_v3(hit.hit, p); copy_v3_v3(hit.cagehit, p); |