Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacques Lucke <jacques@blender.org>2022-02-18 11:12:41 +0300
committerJacques Lucke <jacques@blender.org>2022-02-18 11:14:54 +0300
commit61aaeb3745ad72c681c17f4535dd06ffaaf78c58 (patch)
treec843b445e3e68938aa8c1f5f704dc55eb2be5c6d /source/blender/editors/sculpt_paint/paint_ops.c
parent964d3a38fac8fd9ba90e6a94d26546f2d0651116 (diff)
Curves: initial brush system integration for curves sculpt mode
This adds the boilerplate code that is necessary to use the tool/brush/paint systems in the new sculpt curves mode. Two temporary dummy tools are part of this patch. They do nothing and only serve to test the boilerplate. When the first actual tool is added, those dummy tools will be removed. Differential Revision: https://developer.blender.org/D14117
Diffstat (limited to 'source/blender/editors/sculpt_paint/paint_ops.c')
-rw-r--r--source/blender/editors/sculpt_paint/paint_ops.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_ops.c b/source/blender/editors/sculpt_paint/paint_ops.c
index 1b876235ad0..926a564184a 100644
--- a/source/blender/editors/sculpt_paint/paint_ops.c
+++ b/source/blender/editors/sculpt_paint/paint_ops.c
@@ -39,6 +39,7 @@
#include "RNA_access.h"
#include "RNA_define.h"
+#include "curves_sculpt_intern.h"
#include "paint_intern.h"
#include "sculpt_intern.h"
@@ -758,6 +759,7 @@ static const ePaintMode brush_select_paint_modes[] = {
PAINT_MODE_VERTEX_GPENCIL,
PAINT_MODE_SCULPT_GPENCIL,
PAINT_MODE_WEIGHT_GPENCIL,
+ PAINT_MODE_SCULPT_CURVES,
};
static int brush_select_exec(bContext *C, wmOperator *op)
@@ -1388,6 +1390,10 @@ void ED_keymap_paint(wmKeyConfig *keyconf)
keymap = paint_stroke_modal_keymap(keyconf);
WM_modalkeymap_assign(keymap, "SCULPT_OT_brush_stroke");
+ /* Curves Sculpt mode. */
+ keymap = WM_keymap_ensure(keyconf, "Sculpt Curves", 0, 0);
+ keymap->poll = CURVES_SCULPT_mode_poll;
+
/* sculpt expand. */
sculpt_expand_modal_keymap(keyconf);
}