[Bf-blender-cvs] [5c14270fd8f] greasepencil-object: GP: Add small offset to collision point

Antonioya noreply at git.blender.org
Thu Jan 3 20:09:33 CET 2019


Commit: 5c14270fd8fc24bdc7e46f80f78b7b206c4b01d5
Author: Antonioya
Date:   Thu Jan 3 20:09:21 2019 +0100
Branches: greasepencil-object
https://developer.blender.org/rB5c14270fd8fc24bdc7e46f80f78b7b206c4b01d5

GP: Add small offset to collision point

===================================================================

M	source/blender/editors/gpencil/gpencil_utils.c

===================================================================

diff --git a/source/blender/editors/gpencil/gpencil_utils.c b/source/blender/editors/gpencil/gpencil_utils.c
index 41453dabc6f..2990ebb0001 100644
--- a/source/blender/editors/gpencil/gpencil_utils.c
+++ b/source/blender/editors/gpencil/gpencil_utils.c
@@ -2226,7 +2226,7 @@ int ED_gpencil_select_stroke_segment(
 
 		if (hit_b) {
 			f = gp_calc_factor(p2d_a1, p2d_a2, r_hit2d);
-			interp_v3_v3v3(r_hitb, &pta1->x, &pta2->x, f);
+			interp_v3_v3v3(r_hitb, &pta1->x, &pta2->x, f + 0.1f);
 			if (f > min_factor) {
 				hit_pointb = pta1;
 			}



More information about the Bf-blender-cvs mailing list