diff options
author | Nicholas Bishop <nicholasbishop@gmail.com> | 2012-05-11 00:36:13 +0400 |
---|---|---|
committer | Nicholas Bishop <nicholasbishop@gmail.com> | 2012-05-11 00:36:13 +0400 |
commit | ee9f917f08c5c90235b4f216a1736dbb3d39d730 (patch) | |
tree | 7efffa9a97b0df1524b963f63fa944794f7032d8 /source/blender/editors | |
parent | 415d346db65976a531a44a106b0eb2cdcfc153dc (diff) |
Add keymap and menu entries for masking.
* Add CTRL+IKEY to invert the mask.
* Add ALT+MKEY to clear the mask.
* Change the 'Hide' menu in sculpt mode to 'Hide/Mask', adds entires
for clearing, filling, and inverting the mask, as well as hiding
masked regions.
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/sculpt_paint/paint_ops.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_ops.c b/source/blender/editors/sculpt_paint/paint_ops.c index 4efaae36543..b1711817ead 100644 --- a/source/blender/editors/sculpt_paint/paint_ops.c +++ b/source/blender/editors/sculpt_paint/paint_ops.c @@ -634,6 +634,15 @@ void ED_keymap_paint(wmKeyConfig *keyconf) for (i = 0; i <= 5; i++) RNA_int_set(WM_keymap_add_item(keymap, "OBJECT_OT_subdivision_set", ZEROKEY + i, KM_PRESS, KM_CTRL, 0)->ptr, "level", i); + /* Clear mask */ + kmi= WM_keymap_add_item(keymap, "PAINT_OT_mask_flood_fill", MKEY, KM_PRESS, KM_ALT, 0); + RNA_enum_set(kmi->ptr, "mode", PAINT_MASK_FLOOD_VALUE); + RNA_float_set(kmi->ptr, "value", 0); + + /* Invert mask */ + kmi= WM_keymap_add_item(keymap, "PAINT_OT_mask_flood_fill", IKEY, KM_PRESS, KM_CTRL, 0); + RNA_enum_set(kmi->ptr, "mode", PAINT_MASK_INVERT); + /* multires switch */ kmi = WM_keymap_add_item(keymap, "OBJECT_OT_subdivision_set", PAGEUPKEY, KM_PRESS, 0, 0); RNA_int_set(kmi->ptr, "level", 1); |