[Bf-blender-cvs] [82d6a30015a] master: Disable cursor drawing while navigating
Campbell Barton
noreply at git.blender.org
Thu Oct 5 08:53:25 CEST 2017
Commit: 82d6a30015a753efd7ed4145e85141a30ebb5f67
Author: Campbell Barton
Date: Thu Oct 5 17:35:46 2017 +1100
Branches: master
https://developer.blender.org/rB82d6a30015a753efd7ed4145e85141a30ebb5f67
Disable cursor drawing while navigating
Was performing ray-casts in sculpt mode on every update.
===================================================================
M source/blender/editors/sculpt_paint/paint_cursor.c
===================================================================
diff --git a/source/blender/editors/sculpt_paint/paint_cursor.c b/source/blender/editors/sculpt_paint/paint_cursor.c
index 6145c549e9b..5bc21457d54 100644
--- a/source/blender/editors/sculpt_paint/paint_cursor.c
+++ b/source/blender/editors/sculpt_paint/paint_cursor.c
@@ -42,6 +42,7 @@
#include "DNA_scene_types.h"
#include "DNA_screen_types.h"
#include "DNA_userdef_types.h"
+#include "DNA_view3d_types.h"
#include "BKE_brush.h"
#include "BKE_context.h"
@@ -1002,8 +1003,9 @@ static void paint_draw_cursor(bContext *C, int x, int y, void *UNUSED(unused))
* mouse over too, not just during a stroke */
view3d_set_viewcontext(C, &vc);
- get_imapaint_zoom(C, &zoomx, &zoomy);
- zoomx = max_ff(zoomx, zoomy);
+ if (vc.rv3d->rflag & RV3D_NAVIGATING) {
+ return;
+ }
/* skip everything and draw brush here */
if (brush->flag & BRUSH_CURVE) {
@@ -1011,6 +1013,9 @@ static void paint_draw_cursor(bContext *C, int x, int y, void *UNUSED(unused))
return;
}
+ get_imapaint_zoom(C, &zoomx, &zoomy);
+ zoomx = max_ff(zoomx, zoomy);
+
/* set various defaults */
translation[0] = x;
translation[1] = y;
More information about the Bf-blender-cvs
mailing list