diff options
Diffstat (limited to 'source/blender/editors/sculpt_paint/paint_mask.c')
-rw-r--r-- | source/blender/editors/sculpt_paint/paint_mask.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_mask.c b/source/blender/editors/sculpt_paint/paint_mask.c index 697d7c63d1f..e0b3905b30f 100644 --- a/source/blender/editors/sculpt_paint/paint_mask.c +++ b/source/blender/editors/sculpt_paint/paint_mask.c @@ -38,8 +38,8 @@ #include "DNA_meshdata_types.h" #include "DNA_object_types.h" -#include "BLI_pbvh.h" - +#include "BLI_utildefines.h" +#include "BKE_pbvh.h" #include "BKE_ccg.h" #include "BKE_context.h" #include "BKE_DerivedMesh.h" @@ -97,7 +97,7 @@ static int mask_flood_fill_exec(bContext *C, wmOperator *op) pbvh = dm->getPBVH(ob, dm); ob->sculpt->pbvh = pbvh; - BLI_pbvh_search_gather(pbvh, NULL, NULL, &nodes, &totnode); + BKE_pbvh_search_gather(pbvh, NULL, NULL, &nodes, &totnode); sculpt_undo_push_begin("Mask flood fill"); @@ -106,12 +106,12 @@ static int mask_flood_fill_exec(bContext *C, wmOperator *op) sculpt_undo_push_node(ob, nodes[i], SCULPT_UNDO_MASK); - BLI_pbvh_vertex_iter_begin(pbvh, nodes[i], vi, PBVH_ITER_UNIQUE) { + BKE_pbvh_vertex_iter_begin(pbvh, nodes[i], vi, PBVH_ITER_UNIQUE) { mask_flood_fill_set_elem(vi.mask, mode, value); - } BLI_pbvh_vertex_iter_end; + } BKE_pbvh_vertex_iter_end; - BLI_pbvh_node_mark_update(nodes[i]); - if (BLI_pbvh_type(pbvh) == PBVH_GRIDS) + BKE_pbvh_node_mark_update(nodes[i]); + if (BKE_pbvh_type(pbvh) == PBVH_GRIDS) multires_mark_as_modified(ob, MULTIRES_COORDS_MODIFIED); } @@ -128,13 +128,14 @@ static int mask_flood_fill_exec(bContext *C, wmOperator *op) void PAINT_OT_mask_flood_fill(struct wmOperatorType *ot) { static EnumPropertyItem mode_items[] = { - {PAINT_MASK_FLOOD_VALUE, "VALUE", 0, "Value", "Set mask to the level specified by the \"value\" property"}, + {PAINT_MASK_FLOOD_VALUE, "VALUE", 0, "Value", "Set mask to the level specified by the 'value' property"}, {PAINT_MASK_INVERT, "INVERT", 0, "Invert", "Invert the mask"}, {0}}; /* identifiers */ ot->name = "Mask Flood Fill"; ot->idname = "PAINT_OT_mask_flood_fill"; + ot->description = "Fill the whole mask with a given value, or invert its values"; /* api callbacks */ ot->exec = mask_flood_fill_exec; @@ -144,5 +145,6 @@ void PAINT_OT_mask_flood_fill(struct wmOperatorType *ot) /* rna */ RNA_def_enum(ot->srna, "mode", mode_items, PAINT_MASK_FLOOD_VALUE, "Mode", NULL); - RNA_def_float(ot->srna, "value", 0, 0, 1, "Value", "Mask level to use when mode is \"Value\"; zero means no masking and one is fully masked", 0, 1); + RNA_def_float(ot->srna, "value", 0, 0, 1, "Value", + "Mask level to use when mode is 'Value'; zero means no masking and one is fully masked", 0, 1); } |