129 Depsgraph &depsgraph,
151 switch (brush_type) {
189 void redraw(
bool final)
override;
192 void done(
bool is_cancel,
bool stroke_started)
override;
195 std::unique_ptr<CurvesSculptStrokeOperation> operation_;
201 return float3(mouse.x, mouse.y, 0.0f);
231 operation_->on_stroke_extended(*
this, stroke_extension);
250 if (
brush ==
nullptr) {
296 ot->
name =
"Stroke Curves Sculpt";
297 ot->
idname =
"SCULPT_CURVES_OT_brush_stroke";
377 ot->
name =
"Curve Sculpt Mode Toggle";
378 ot->
idname =
"CURVES_OT_sculptmode_toggle";
379 ot->
description =
"Enter/Exit sculpt mode for curves";
402 const auto next_partial_random_value = [&]() {
403 return rng.
get_float() * (1.0f - min_value) + min_value;
405 const auto next_bool_random_value = [&]() {
return rng.
get_float() <= probability; };
407 for (
Curves *curves_id : unique_curves) {
413 if (!was_anything_selected) {
414 selection.
fill(1.0f);
420 if (constant_per_curve) {
421 for (
const int curve_i :
curves.curves_range()) {
422 const float random_value = next_partial_random_value();
423 const IndexRange points = points_by_curve[curve_i];
424 for (
const int point_i : points) {
425 selection[point_i] *= random_value;
430 for (
const int point_i : selection.
index_range()) {
431 const float random_value = next_partial_random_value();
432 selection[point_i] *= random_value;
437 if (constant_per_curve) {
438 for (
const int curve_i :
curves.curves_range()) {
439 const bool random_value = next_bool_random_value();
440 const IndexRange points = points_by_curve[curve_i];
447 for (
const int point_i : selection.
index_range()) {
448 const bool random_value = next_bool_random_value();
450 selection[point_i] = 0.0f;
459 for (
const int curve_i :
curves.curves_range()) {
460 const float random_value = next_partial_random_value();
461 selection[curve_i] *= random_value;
465 for (
const int curve_i :
curves.curves_range()) {
466 const bool random_value = next_bool_random_value();
468 selection[curve_i] = 0.0f;
509 ot->
name =
"Select Random";
511 ot->
description =
"Randomizes existing selection or create new random selection";
525 "Source of randomness",
529 ot->
srna,
"partial",
false,
"Partial",
"Allow points or curves to be selected partially");
536 "Chance of every point or curve being included in the selection",
545 "Minimum value for the random selection",
549 "constant_per_curve",
551 "Constant per Curve",
552 "The generated random number is the same for every control point of a curve");
579 data.unselected_points.foreach_index(
580 [&](
const int point_i,
const int index_pos) {
581 const float distance_to_selected =
data.distances_to_selected[index_pos];
582 const float selection = distance_to_selected <=
distance ? 1.0f : 0.0f;
583 points_selection[point_i] = selection;
586 data.selected_points.foreach_index(
590 data.selected_points.foreach_index(
591 [&](
const int point_i,
const int index_pos) {
592 const float distance_to_unselected =
data.distances_to_unselected[index_pos];
593 const float selection = distance_to_unselected <= -
distance ? 0.0f : 1.0f;
594 points_selection[point_i] = selection;
597 data.unselected_points.foreach_index(
606 for (std::unique_ptr<GrowOperatorDataPerCurve> &curve_op_data : op_data.
per_curve) {
607 Curves &curves_id = *curve_op_data->curves_id;
609 const float distance = curve_op_data->pixel_to_distance_factor * mouse_diff_x;
615 switch (selection.
domain) {
625 for (
const int curve_i :
curves.curves_range()) {
626 const IndexRange points = points_by_curve[curve_i];
628 const float max_selection = *std::max_element(points_selection.
begin(),
629 points_selection.
end());
630 curves_selection[curve_i] = max_selection;
661 original_selection.varray.size());
675 KDTreeNew<float3> kdtree(positions, curve_op_data.selected_points);
676 curve_op_data.distances_to_selected.reinitialize(curve_op_data.unselected_points.size());
677 curve_op_data.unselected_points.foreach_index(
678 [&](const int point, const int pos) {
679 float distance_sq = FLT_MAX;
680 kdtree.find_nearest(positions[point], &distance_sq);
681 curve_op_data.distances_to_selected[pos] = std::sqrt(distance_sq);
688 curve_op_data.distances_to_unselected.reinitialize(curve_op_data.selected_points.size());
689 curve_op_data.selected_points.foreach_index(
690 [&](
const int point,
const int pos) {
692 kdtree.find_nearest(positions[point], &distance_sq);
693 curve_op_data.distances_to_unselected[pos] = std::sqrt(distance_sq);
698 const float4x4 &curves_to_world_mat = curves_ob.object_to_world();
706 curve_op_data.selected_points.index_range(),
709 [&](
const IndexRange range,
float pixel_to_distance_factor) {
710 for (const int i : range) {
711 const int point_i = curve_op_data.selected_points[i];
712 const float3 &pos_cu = positions[point_i];
714 const float2 pos_re = ED_view3d_project_float_v2_m4(®ion, pos_cu, projection);
715 if (pos_re.x < 0 || pos_re.y < 0 || pos_re.x > region.winx || pos_re.y > region.winy) {
720 const float2 pos_offset_re = pos_re + float2(1, 0);
721 float3 pos_offset_wo;
722 ED_view3d_win_to_3d(&v3d,
724 math::transform_point(curves_to_world_mat, pos_cu),
727 const float3 pos_offset_cu = math::transform_point(world_to_curves_mat, pos_offset_wo);
728 const float dist_cu = math::distance(pos_cu, pos_offset_cu);
729 const float dist_re = math::distance(pos_re, pos_offset_re);
730 const float factor = dist_cu / dist_re;
731 math::min_inplace(pixel_to_distance_factor, factor);
733 return pixel_to_distance_factor;
735 [](
const float a,
const float b) {
return std::min(a,
b); });
750 Curves &curves_id = *id_cast<Curves *>(active_ob->
data);
751 auto curve_op_data = std::make_unique<GrowOperatorDataPerCurve>();
752 curve_op_data->curves_id = &curves_id;
754 op_data->
per_curve.append(std::move(curve_op_data));
763 const int mouse_x =
event->xy[0];
765 switch (event->
type) {
771 MEM_delete(&op_data);
777 for (std::unique_ptr<GrowOperatorDataPerCurve> &curve_op_data : op_data.
per_curve) {
778 Curves &curves_id = *curve_op_data->curves_id;
782 attributes.
remove(
".selection");
783 if (!curve_op_data->original_selection.is_empty()) {
796 MEM_delete(&op_data);
810 ot->
name =
"Select Grow";
812 ot->
description =
"Select curves which are close to curves that are selected already";
827 "By how much to grow the selection",
842 if (
brush ==
nullptr) {
889 points_wo.
append(op_data.
pos_cu + min_distance * tangent_x_cu);
890 points_wo.
append(op_data.
pos_cu + min_distance * tangent_y_cu);
891 points_wo.
append(op_data.
pos_cu - min_distance * tangent_x_cu);
892 points_wo.
append(op_data.
pos_cu - min_distance * tangent_y_cu);
895 for (
const float3 &pos_wo : points_wo) {
904 int needed_points = 0;
905 for (
const float2 &pos_re : points_re) {
907 const int needed_points_iter = (brush_radius * 2.0f) /
distance;
909 needed_points = std::max(needed_points_iter, needed_points);
913 return std::min(300, needed_points);
934 const int points_per_axis_num = 2 * points_per_side + 1;
937 for (
const int x_i :
IndexRange(points_per_axis_num)) {
938 for (
const int y_i :
IndexRange(points_per_axis_num)) {
939 const float x_iter = min_distance * (x_i - (points_per_axis_num - 1) / 2.0f);
940 const float y_iter = min_distance * (y_i - (points_per_axis_num - 1) / 2.0f);
943 x_iter * tangent_x_cu + y_iter * tangent_y_cu;
945 points_wo.
append(point_pos_wo);
971 format3d,
"color", gpu::VertAttrType::SFLOAT_32_32_32_32);
983 const int alpha_border_re = 20;
984 const float dist_to_inner_border_re = brush_radius_re - alpha_border_re;
986 for (
const float3 &pos_wo : points_wo) {
990 const float dist_to_point_re =
math::distance(pos_re, brush_origin_re);
992 1.0f - ((dist_to_point_re - dist_to_inner_border_re) / alpha_border_re), 0.0f, 1.0f);
995 immAttr4f(col3d, 0.9f, 0.9f, 0.9f, alpha);
1009 GPU_scissor(scissor[0], scissor[1], scissor[2], scissor[3]);
1034 Curves &curves_id_orig = *id_cast<Curves *>(curves_ob_orig.
data);
1035 Object &surface_ob_orig = *curves_id_orig.surface;
1037 if (surface_ob_eval ==
nullptr) {
1041 if (surface_me_eval ==
nullptr) {
1045 const bke::bvh::Tree &surface_bvh_eval = surface_me_eval->bvh_tris();
1047 const int2 mouse_pos_int_re{
event->mval};
1048 const float2 mouse_pos_re{mouse_pos_int_re};
1050 float3 ray_start_wo, ray_end_wo;
1052 depsgraph, region, v3d, mouse_pos_re, ray_start_wo, ray_end_wo,
true);
1061 const std::optional<bke::bvh::RayHit> ray_hit = surface_bvh_eval.
ray_intersect(ray);
1067 const float3 hit_pos_su = ray_hit->position(ray);
1077 op_data->
pos_cu = hit_pos_cu;
1091 wm->runtime->paintcursors.clear_no_delete();
1110 auto finish = [&]() {
1119 MEM_delete(&op_data);
1122 switch (event->
type) {
1124 const int2 mouse_pos_int_re{
event->xy};
1125 const float2 mouse_pos_re{mouse_pos_int_re};
1127 const float mouse_diff_x = mouse_pos_int_re.x - op_data.
initial_mouse.x;
1128 const float factor =
powf(2, mouse_diff_x /
UI_UNIT_X / 10.0f);
1163 ot->
name =
"Edit Minimum Distance";
1165 ot->
description =
"Change the minimum distance used by the density brush";
Low-level operations for curves.
General operations, lookup, etc. for blender objects.
#define OPERATOR_RETVAL_CHECK(ret)
#define BLI_assert_unreachable()
Span< T > as_span() const
GArray(Allocator allocator={}) noexcept
const void * data() const
static GVArray from_span(GSpan span)
constexpr IndexRange()=default
constexpr MutableSpan slice(const int64_t start, const int64_t size) const
constexpr void fill(const T &value) const
constexpr IndexRange index_range() const
constexpr const T * end() const
constexpr const T * begin() const
void append(const T &value)
bool add(const StringRef name, const AttrDomain domain, const AttrType data_type, const AttributeInit &initializer)
bool remove(const StringRef name)
std::optional< RayHit > ray_intersect(const Ray &ray) const
NonCopyable(const NonCopyable &other)=delete
NonMovable(NonMovable &&other)=delete
IndexMask complement(const IndexMask &universe, LinearAllocator<> &memory) const
float distance(float, float) RET
AttrType cpp_type_to_attribute_type(const CPPType &type)
bool has_anything_selected(const VArray< bool > &varray, const IndexRange range_to_check)
IndexMask retrieve_selected_points(const bke::CurvesGeometry &curves, LinearAllocator<> &memory)
VectorSet< Curves * > get_unique_editable_curves(const bContext &C)
bool editable_curves_poll(bContext *C)
bool curves_with_surface_poll(bContext *C)
bool curves_poll(bContext *C)
bool mode_compat_set(bContext *C, Object *ob, eObjectMode mode, ReportList *reports)
static wmOperatorStatus min_distance_edit_invoke(bContext *C, wmOperator *op, const wmEvent *event)
static int calculate_points_per_side(bContext *C, MinDistanceEditData &op_data)
static wmOperatorStatus min_distance_edit_modal(bContext *C, wmOperator *op, const wmEvent *event)
static void min_distance_edit_draw(bContext *C, const int2 &, const float2 &, void *customdata)
static bool min_distance_edit_poll(bContext *C)
static int select_grow_update(bContext *C, wmOperator *op, const float mouse_diff_x)
static void update_points_selection(const GrowOperatorDataPerCurve &data, const float distance, MutableSpan< float > points_selection)
static wmOperatorStatus select_grow_modal(bContext *C, wmOperator *op, const wmEvent *event)
static void select_grow_invoke_per_curve(const Curves &curves_id, const Object &curves_ob, const ARegion ®ion, const View3D &v3d, const RegionView3D &rv3d, GrowOperatorDataPerCurve &curve_op_data)
static wmOperatorStatus select_grow_invoke(bContext *C, wmOperator *op, const wmEvent *event)
static wmOperatorStatus select_random_exec(bContext *C, wmOperator *op)
static void select_random_ui(bContext *, wmOperator *op)
bool curves_sculpt_poll(bContext *C)
std::unique_ptr< CurvesSculptStrokeOperation > new_add_operation()
std::unique_ptr< CurvesSculptStrokeOperation > new_pinch_operation(BrushStrokeMode brush_mode, const Scene &scene)
static wmOperatorStatus sculpt_curves_stroke_modal(bContext *C, wmOperator *op, const wmEvent *event)
static void curves_sculptmode_exit(bContext *C)
std::unique_ptr< CurvesSculptStrokeOperation > new_comb_operation()
float brush_strength_get(const Paint &paint, const Brush &brush, const StrokeExtension &stroke_extension)
std::unique_ptr< CurvesSculptStrokeOperation > new_selection_paint_operation(BrushStrokeMode brush_mode, BrushSwitchMode brush_switch_mode, const Scene &scene)
static void SCULPT_CURVES_OT_select_grow(wmOperatorType *ot)
bke::SpanAttributeWriter< float > float_selection_ensure(Curves &curves_id)
static wmOperatorStatus curves_sculptmode_toggle_exec(bContext *C, wmOperator *op)
static void CURVES_OT_sculptmode_toggle(wmOperatorType *ot)
static void curves_sculptmode_enter(bContext *C)
std::unique_ptr< CurvesSculptStrokeOperation > new_snake_hook_operation()
bool curves_sculpt_poll_view3d(bContext *C)
static wmOperatorStatus sculpt_curves_stroke_invoke(bContext *C, wmOperator *op, const wmEvent *event)
std::unique_ptr< CurvesSculptStrokeOperation > new_smooth_operation()
std::unique_ptr< CurvesSculptStrokeOperation > new_cut_operation()
std::unique_ptr< CurvesSculptStrokeOperation > new_delete_operation()
std::unique_ptr< CurvesSculptStrokeOperation > new_grow_shrink_operation(const BrushStrokeMode brush_mode, const Scene &scene)
float brush_radius_get(const Paint &paint, const Brush &brush, const StrokeExtension &stroke_extension)
static std::unique_ptr< CurvesSculptStrokeOperation > start_brush_operation(wmOperator &op, Scene &scene, Depsgraph &depsgraph, ARegion ®ion, View3D &v3d, const Object &object, const StrokeExtension &stroke_start)
static void SCULPT_CURVES_OT_select_random(wmOperatorType *ot)
std::unique_ptr< CurvesSculptStrokeOperation > new_density_operation(BrushStrokeMode brush_mode, const Scene &scene, const Depsgraph &depsgraph, const ARegion ®ion, const View3D &v3d, const Object &object, const StrokeExtension &stroke_start)
static void SCULPT_CURVES_OT_min_distance_edit(wmOperatorType *ot)
static void sculpt_curves_stroke_cancel(bContext *C, wmOperator *op)
std::unique_ptr< CurvesSculptStrokeOperation > new_slide_operation()
std::unique_ptr< CurvesSculptStrokeOperation > new_puff_operation()
float brush_strength_factor(const Brush &brush, const StrokeExtension &stroke_extension)
float brush_radius_factor(const Brush &brush, const StrokeExtension &stroke_extension)
static void SCULPT_CURVES_OT_brush_stroke(wmOperatorType *ot)
constexpr ParallelGrainSize grain_size(int grain_size)
T distance(const T &a, const T &b)
T length(const VecBase< T, Size > &a)
CartesianBasis invert(const CartesianBasis &basis)
AxisSigned cross(const AxisSigned a, const AxisSigned b)
MatBase< T, NumCol, NumRow > normalize(const MatBase< T, NumCol, NumRow > &a)
VecBase< T, 3 > transform_direction(const MatBase< T, 3, 3 > &mat, const VecBase< T, 3 > &direction)
VecBase< T, 3 > transform_point(const CartesianBasis &basis, const VecBase< T, 3 > &v)
void parallel_invoke(Functions &&...functions)
Value parallel_reduce(IndexRange range, int64_t grain_size, const Value &identity, const Function &function, const Reduction &reduction)
void WM_main_add_notifier(uint type, void *reference)
void WM_operatortype_append(void(*opfunc)(wmOperatorType *))
int RNA_enum_get(PointerRNA *ptr, const char *name)
void wmViewport(const rcti *winrct)
void immAttr4f(uint attr_id, float x, float y, float z, float w)
VecBase< int32_t, 4 > int4
void wmWindowViewport(const wmWindow *win)
float4x4 ED_view3d_ob_project_mat_get(const RegionView3D *rv3d, const Object *ob)
Depsgraph * CTX_data_depsgraph_pointer(const bContext *C)
GPUVertFormat * immVertexFormat()
float BKE_brush_radius_get(const Paint *paint, const Brush *brush)
void GPU_point_size(float size)
void immBegin(GPUPrimType, uint vertex_len)
int RNA_int_get(PointerRNA *ptr, const char *name)
wmWindow * CTX_wm_window(const bContext *C)
void ED_view3d_project_v2(const ARegion *region, const float world[3], float r_region_co[2])
MatBase< float, 4, 4 > float4x4
void ED_region_tag_redraw(ARegion *region)
bool BKE_brush_use_alpha_pressure(const Brush *brush)
void ED_paint_cursor_start(Paint *paint, bool(*poll)(bContext *C))
void BKE_brush_tag_unsaved_changes(Brush *brush)
VecBase< float, 4 > float4
void immBindBuiltinProgram(GPUBuiltinShader shader_id)
void imm_draw_circle_wire_2d(uint shdr_pos, float x, float y, float radius, int nsegments)
VecBase< int32_t, 2 > int2
VecBase< float, 2 > float2
void DEG_id_tag_update(ID *id, unsigned int flags)
BMesh const char void * data
T * DEG_get_evaluated(const Depsgraph *depsgraph, T *id)
@ GPU_SHADER_3D_UNIFORM_COLOR
@ GPU_SHADER_3D_POINT_VARYING_SIZE_VARYING_COLOR
void GPU_scissor_get(int coords[4])
wmWindowManager * CTX_wm_manager(const bContext *C)
void BKE_paint_brushes_ensure(Main *bmain, Paint *paint)
void WM_toolsystem_update_from_context_view3d(bContext *C)
void RNA_def_property_subtype(PropertyRNA *prop, PropertySubType subtype)
void GPU_program_point_size(bool enable)
void WM_global_report(eReportType type, const char *message)
@ CURVES_SCULPT_BRUSH_TYPE_COMB
@ CURVES_SCULPT_BRUSH_TYPE_SMOOTH
@ CURVES_SCULPT_BRUSH_TYPE_ADD
@ CURVES_SCULPT_BRUSH_TYPE_SLIDE
@ CURVES_SCULPT_BRUSH_TYPE_DENSITY
@ CURVES_SCULPT_BRUSH_TYPE_PINCH
@ CURVES_SCULPT_BRUSH_TYPE_SNAKE_HOOK
@ CURVES_SCULPT_BRUSH_TYPE_GROW_SHRINK
@ CURVES_SCULPT_BRUSH_TYPE_DELETE
@ CURVES_SCULPT_BRUSH_TYPE_CUT
@ CURVES_SCULPT_BRUSH_TYPE_PUFF
@ CURVES_SCULPT_BRUSH_TYPE_SELECTION_PAINT
RegionView3D * CTX_wm_region_view3d(const bContext *C)
bool RNA_boolean_get(PointerRNA *ptr, const char *name)
void GPU_matrix_projection_set(const float m[4][4])
void GPU_matrix_translate_2f(float x, float y)
uint GPU_vertformat_attr_add(GPUVertFormat *format, StringRef name, gpu::VertAttrType type)
void WM_event_add_notifier(const bContext *C, uint type, void *reference)
wmMsgBus * CTX_wm_message_bus(const bContext *C)
wmPaintCursor * WM_paint_cursor_activate(short space_type, short region_type, wmPaintCursorPoll poll, wmPaintCursorDraw draw, void *customdata)
void paint_stroke_operator_properties(wmOperatorType *ot)
bool BKE_brush_use_size_pressure(const Brush *brush)
void immAttr1f(uint attr_id, float x)
const Brush * BKE_paint_brush_for_read(const Paint *paint)
wmEventHandler_Op * WM_event_add_modal_handler(bContext *C, wmOperator *op)
void GPU_scissor(int x, int y, int width, int height)
void immVertex3fv(uint attr_id, const float data[3])
PropertyRNA * RNA_def_int(StructOrFunctionRNA *cont_, const char *identifier, const int default_value, const int hardmin, const int hardmax, const char *ui_name, const char *ui_description, const int softmin, const int softmax)
Main * CTX_data_main(const bContext *C)
void GPU_matrix_pop_projection()
Paint * BKE_paint_get_active_from_context(const bContext *C)
bool ED_view3d_win_to_segment_clipped(const Depsgraph *depsgraph, const ARegion *region, const View3D *v3d, const float mval[2], float r_ray_start[3], float r_ray_end[3], bool do_clip_planes)
void paint_init_pivot(Object *ob, Scene *scene, Paint *paint)
Paint * BKE_paint_get_active_from_paintmode(Scene *sce, PaintMode mode)
Brush * BKE_paint_brush(Paint *paint)
Scene * CTX_data_scene(const bContext *C)
void GPU_blend(GPUBlend blend)
@ OPTYPE_DEPENDS_ON_CURSOR
VecBase< float, 3 > float3
void ED_operatortypes_sculpt_curves()
PropertyRNA * RNA_def_boolean(StructOrFunctionRNA *cont_, const char *identifier, const bool default_value, const char *ui_name, const char *ui_description)
bool BKE_paint_ensure(ToolSettings *ts, Paint **r_paint)
void immUniformColor3fvAlpha(const float rgb[3], float a)
void GPU_matrix_push_projection()
PropertyRNA * RNA_def_float(StructOrFunctionRNA *cont_, const char *identifier, const float default_value, const float hardmin, const float hardmax, const char *ui_name, const char *ui_description, const float softmin, const float softmax)
Object * CTX_data_active_object(const bContext *C)
ARegion * CTX_wm_region(const bContext *C)
void GPU_matrix_set(const float m[4][4])
float BKE_curvemapping_evaluateF(const CurveMapping *cumap, int cur, float value)
float RNA_float_get(PointerRNA *ptr, const char *name)
View3D * CTX_wm_view3d(const bContext *C)
float BKE_brush_alpha_get(const Paint *paint, const Brush *brush)
Mesh * BKE_object_get_evaluated_mesh(const Object *object_eval)
MINLINE float clamp_f(float value, float min, float max)
bool WM_paint_cursor_end(wmPaintCursor *handle)
struct BrushCurvesSculptSettings * curves_sculpt_settings
struct ToolSettings * toolsettings
MutableVArraySpan< T > span
wmOperatorStatus modal(bContext *C, wmOperator *op, const wmEvent *event)
void update_step(wmOperator *op, const StrokeStep &stroke_step) override
void redraw(bool final) override
std::optional< float3 > get_location(float2 mouse, bool force_original) override
SculptCurvesBrushStroke(bContext *C, wmOperator *op, const wmEvent *event)
bool test_cancel() override
bool test_start(wmOperator *op, float2 mouse) override
void done(bool is_cancel, bool stroke_started) override
ListBaseT< wmPaintCursor > orig_paintcursors
float4x4 curves_to_world_mat
float initial_minimum_distance
Array< float > distances_to_unselected
IndexMask unselected_points
IndexMaskMemory unselected_points_memory
IndexMask selected_points
Array< float > distances_to_selected
float pixel_to_distance_factor
IndexMaskMemory selected_points_memory
GArray original_selection
Vector< std::unique_ptr< GrowOperatorDataPerCurve > > per_curve
void prop(PointerRNA *ptr, PropertyRNA *prop, int index, int value, eUI_Item_Flag flag, std::optional< StringRef > name_opt, int icon, std::optional< StringRef > placeholder=std::nullopt)
wmOperatorStatus(*) exec(bContext *C, wmOperator *op) ATTR_WARN_UNUSED_RESULT
void(*) cancel(bContext *C, wmOperator *op)
void(*) ui(bContext *C, wmOperator *op)
bool(*) poll(bContext *C) ATTR_WARN_UNUSED_RESULT
wmOperatorStatus(*) invoke(bContext *C, wmOperator *op, const wmEvent *event) ATTR_WARN_UNUSED_RESULT
wmOperatorStatus(*) modal(bContext *C, wmOperator *op, const wmEvent *event) ATTR_WARN_UNUSED_RESULT
struct ReportList * reports
struct wmOperatorType * type
#define WM_msg_publish_rna_prop(mbus, id_, data_, type_, prop_)