diff options
author | Antony Riakiotakis <kalast@gmail.com> | 2013-04-23 02:20:38 +0400 |
---|---|---|
committer | Antony Riakiotakis <kalast@gmail.com> | 2013-04-23 02:20:38 +0400 |
commit | e066b077fb8cae95576b6e4db3fc5bb07e4ab358 (patch) | |
tree | 791eba58bca1187186cc67c9b5d8ab7609787bc4 /source/blender/editors/sculpt_paint/paint_cursor.c | |
parent | 15521ab0ff21368ffa19b75f926c806d5f8c2dad (diff) |
Overlay fixes:
* Clobbering enum
* Cursor overlay not dependent on mapping (again!)
* Brush overlay not updating when size is tweaked
Diffstat (limited to 'source/blender/editors/sculpt_paint/paint_cursor.c')
-rw-r--r-- | source/blender/editors/sculpt_paint/paint_cursor.c | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_cursor.c b/source/blender/editors/sculpt_paint/paint_cursor.c index cdee767879b..49863621b04 100644 --- a/source/blender/editors/sculpt_paint/paint_cursor.c +++ b/source/blender/editors/sculpt_paint/paint_cursor.c @@ -324,13 +324,11 @@ static int load_tex_cursor(Brush *br, ViewContext *vc, float zoom) if (refresh) { int s, r; - float radius; old_zoom = zoom; s = BKE_brush_size_get(vc->scene, br); r = 1; - radius = s * zoom; for (s >>= 1; s > 0; s >>= 1) r++; @@ -373,17 +371,11 @@ static int load_tex_cursor(Brush *br, ViewContext *vc, float zoom) x = (float)i / size; y = (float)j / size; - if (br->mtex.brush_map_mode == MTEX_MAP_MODE_TILED) { - x *= vc->ar->winx / radius; - y *= vc->ar->winy / radius; - } - else { - x -= 0.5f; - y -= 0.5f; + x -= 0.5f; + y -= 0.5f; - x *= 2; - y *= 2; - } + x *= 2; + y *= 2; len = sqrtf(x * x + y * y); |