diff options
Diffstat (limited to 'source/blender/blenkernel/intern/brush.c')
-rw-r--r-- | source/blender/blenkernel/intern/brush.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/blenkernel/intern/brush.c b/source/blender/blenkernel/intern/brush.c index 064e902f831..e52d1d3b683 100644 --- a/source/blender/blenkernel/intern/brush.c +++ b/source/blender/blenkernel/intern/brush.c @@ -661,8 +661,8 @@ float BKE_brush_sample_masktex(const Scene *scene, Brush *br, float x = 0.0f, y = 0.0f; /* Quite warnings */ float co[3]; - x = point_2d[0] - br->stencil_pos[0]; - y = point_2d[1] - br->stencil_pos[1]; + x = point_2d[0] - br->mask_stencil_pos[0]; + y = point_2d[1] - br->mask_stencil_pos[1]; if (rotation > 0.001f || rotation < -0.001f) { const float angle = atan2f(y, x) + rotation; @@ -672,12 +672,12 @@ float BKE_brush_sample_masktex(const Scene *scene, Brush *br, y = flen * sinf(angle); } - if (fabsf(x) > br->stencil_dimension[0] || fabsf(y) > br->stencil_dimension[1]) { + if (fabsf(x) > br->mask_stencil_dimension[0] || fabsf(y) > br->mask_stencil_dimension[1]) { zero_v4(rgba); return 0.0f; } - x /= (br->stencil_dimension[0]); - y /= (br->stencil_dimension[1]); + x /= (br->mask_stencil_dimension[0]); + y /= (br->mask_stencil_dimension[1]); x *= mtex->size[0]; y *= mtex->size[1]; |