diff options
author | Antonioya <blendergit@gmail.com> | 2019-01-01 18:44:10 +0300 |
---|---|---|
committer | Antonioya <blendergit@gmail.com> | 2019-01-01 18:44:10 +0300 |
commit | 4dd0a90f421387e6362315c294033f59dc94c0b6 (patch) | |
tree | 8507a99473326730d4b639ca8a19decc5bdb29e2 /source/blender/editors | |
parent | 4d795cee4938f080f83aa367272d1ad25bba1fbd (diff) |
GP: Don't use offset for Stroke projection
The offset is only used in Surface mode.
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/gpencil/gpencil_paint.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/source/blender/editors/gpencil/gpencil_paint.c b/source/blender/editors/gpencil/gpencil_paint.c index 9ec35105afd..ff9678550f9 100644 --- a/source/blender/editors/gpencil/gpencil_paint.c +++ b/source/blender/editors/gpencil/gpencil_paint.c @@ -370,7 +370,10 @@ static void gp_stroke_convertcoords(tGPsdata *p, const float mval[2], float out[ if (gpd->runtime.sbuffer_sflag & GP_STROKE_3DSPACE) { /* add small offset to keep stroke over the surface */ - if ((depth) && (gpd->zdepth_offset > 0.0f)) { + if ((depth) && + (gpd->zdepth_offset > 0.0f) && + (*p->align_flag & GP_PROJECT_DEPTH_VIEW)) + { *depth *= (1.0f - gpd->zdepth_offset); } |