38#define FOREACH_SELECTED_BEZT_BEGIN(bezt, nurbs) \
39 LISTBASE_FOREACH (Nurb *, nu, nurbs) { \
40 if (nu->type == CU_BEZIER) { \
41 for (int i = 0; i < nu->pntsu; i++) { \
42 BezTriple *bezt = nu->bezt + i; \
43 if (BEZT_ISSEL_ANY(bezt) && !bezt->hide) {
45#define FOREACH_SELECTED_BEZT_END \
49 BKE_nurb_handles_calc(nu); \
54#define SEL_DIST_FACTOR 0.2f
125 {
HD_AUTO,
"AUTO", 0,
"Auto",
""},
126 {
HD_VECT,
"VECTOR", 0,
"Vector",
""},
127 {0,
nullptr, 0,
nullptr,
nullptr},
137 {
OFF,
"OFF", 0,
"None",
""},
138 {
ON_PRESS,
"ON_PRESS", 0,
"On Press",
"Move handles after closing the spline"},
139 {
ON_CLICK,
"ON_CLICK", 0,
"On Click",
"Spline closes on release if not dragged"},
140 {0,
nullptr, 0,
nullptr,
nullptr},
147 const float eps = 1e-6f;
154 const float *plane_co = vc->
obedit->object_to_world().location();
166 float location_test[3];
187 const float pos_2d[2],
188 const float depth[3],
198 const float depth[3],
201 const float pos_2d_fl[2] = {
float(pos_2d[0]),
float(pos_2d[1])};
206 const float pos_3d[3],
259 const float disp_2d[2],
261 const bool link_handles,
262 const bool lock_angle)
271 float pos[2], dst[2];
286 const int other_handle = bezt_idx == 2 ? 0 : 2;
315 const bool bezt_only,
322 for (
int i = 0; i < nu->pntsu; i++) {
349 else if (!bezt_only) {
350 for (
int i = 0; i < nu->pntsu; i++) {
351 if (!nu->bp->hide && (nu->bp + i)->f1 &
SELECT) {
372 const bool bezt_only)
385 float mval_3d[3], center_mid[3];
393 for (
int i = 0; i < nu->pntsu; i++) {
406 vc, bezt, 0, disp_2d,
distance, link_handles, lock_angle);
410 vc, bezt, 2, disp_2d,
distance, link_handles, lock_angle);
416 else if (!bezt_only) {
417 for (
int i = 0; i < nu->pntsu; i++) {
420 float pos[2], dst[2];
440 if (cu->
actnu == nu_index) {
462 memmove(nu->
bp + index, nu->
bp + index + 1, (nu->
pntsu - index) *
sizeof(
BPoint));
472 const float point[2],
483 int closest_handle = 0;
485 Nurb *closest_bezt_nu =
nullptr;
488 BPoint *closest_bp =
nullptr;
489 Nurb *closest_bp_nu =
nullptr;
493 for (
int i = 0; i < nu->pntsu; i++) {
496 int start = 0, end = 3;
508 for (
int j = start; j < end; j++) {
511 if (dist < min_dist_bezt) {
512 min_dist_bezt = dist;
514 closest_bezt_nu = nu;
522 for (
int i = 0; i < nu->pntsu; i++) {
529 if (dist < min_dist_bp) {
541 if (min_dist_bezt < threshold_dist || min_dist_bp < threshold_dist) {
542 if (min_dist_bp < min_dist_bezt) {
544 *r_nu = closest_bp_nu;
547 *r_bezt = closest_bezt;
548 *r_bezt_idx = closest_handle;
549 *r_nu = closest_bezt_nu;
561 const float parameter,
564 float tmp1[3], tmp2[3], tmp3[3];
577 float handle_prev[3],
578 float new_left_handle[3],
579 float new_right_handle[3],
580 float handle_next[3],
581 const float point_next[3],
582 const float parameter)
584 float center_point[3];
585 interp_v3_v3v3(center_point, handle_prev, handle_next, parameter);
588 interp_v3_v3v3(new_left_handle, handle_prev, center_point, parameter);
589 interp_v3_v3v3(new_right_handle, center_point, handle_next, parameter);
606 const int index =
data->bezt_index + 1;
609 BezTriple *new_bezt = new_bezt_array + index;
615 if (index < nu->pntsu) {
625 next_bezt = new_bezt_array;
628 next_bezt = new_bezt + 1;
639 (new_bezt - 1)->vec[2],
647 nu->
bezt = new_bezt_array;
661 const int index =
data->bp_index + 1;
664 BPoint *new_bp = new_bp_array + index;
670 if (index < nu->pntsu) {
680 next_bp = new_bp_array;
683 next_bp = new_bp + 1;
692 nu->
bp = new_bp_array;
710 const float point1[2],
711 const float point2[2],
713 const int resolu_idx,
718 float edge[2], vec1[2], vec2[2];
722 const float len_vec1 =
len_v2(vec1);
723 const float len_vec2 =
len_v2(vec2);
724 const float dot1 =
dot_v2v2(edge, vec1);
725 const float dot2 =
dot_v2v2(edge, vec2);
730 if ((dot1 > 0) == (dot2 > 0)) {
732 if (*r_min_dist > perp_dist) {
733 *r_min_dist = perp_dist;
734 *r_min_i = point_idx;
739 if (*r_min_dist > len_vec2) {
740 *r_min_dist = len_vec2;
741 *r_min_i = point_idx;
742 *r_param = resolu_idx;
753 float min_dist = cd->
min_dist, param = 0.0f;
758 for (
int i = 0; i < end; i++) {
759 float *points =
static_cast<float *
>(
MEM_mallocN(
sizeof(
float[3]) * (resolu + 1), __func__));
765 for (
int j = 0; j < 3; j++) {
775 float point1[2], point2[2];
779 if (min_dist > len_vec1) {
785 for (
int j = 0; j < resolu; j++) {
801 float point1[2], point2[2];
803 for (
int i = 0; i < end; i++) {
821 const float point[2],
822 const float sel_dist,
842 cd.
mval[0] =
event->mval[0];
843 cd.
mval[1] =
event->mval[1];
856 if (near_spline && !cd.
nurb->
hide) {
905 if (*r_bezt || *r_bp) {
918 a = nu->pntsu * nu->pntsv;
921 if (*r_bezt || *r_bp) {
938 const float disp_3d[3])
943 BezTriple *last_bezt = nu1->bezt + nu1->pntsu - 1;
945 const bool last_sel =
BEZT_ISSEL_ANY(last_bezt) && nu1->pntsu > 1;
959 nu1->bezt = new_bezt;
977 nu1->bezt = new_bezt;
984 cu->
actnu = nu_index;
995 nu1->bezt = new_bezt;
997 cu->
actnu = nu_index;
1006 BPoint *last_bp = nu1->bp + nu1->pntsu - 1;
1007 const bool first_sel = nu1->bp->
f1 &
SELECT;
1008 const bool last_sel = last_bp->
f1 &
SELECT && nu1->pntsu > 1;
1018 add_v3_v3((new_bp + nu1->pntsu + 1)->vec, disp_3d);
1034 cu->
actnu = nu_index;
1037 else if (last_sel) {
1043 add_v3_v3((new_bp + nu1->pntsu)->vec, disp_3d);
1048 cu->
actnu = nu_index;
1063 if (nu1->pntsu > 1) {
1071 end = nu1->pntsu - 1;
1073 for (
int i = start; i < end; i++) {
1078 (nu1->bp + i)->f1 &= ~
SELECT;
1095 const int extrude_handle)
1099 float center[3] = {0.0f, 0.0f, 0.0f};
1127 if (old_last_nu != new_last_nu) {
1130 new_last_nu->
bezt ? (
const void *)new_last_nu->
bezt :
1131 (
const void *)new_last_nu->
bp);
1138 bezt->h1 = extrude_handle;
1139 bezt->h2 = extrude_handle;
1151 const float sel_dist)
1198 const float t_sq = t * t;
1199 const float t_cu = t_sq * t;
1200 const float one_minus_t = 1 - t;
1201 const float one_minus_t_sq = one_minus_t * one_minus_t;
1202 const float one_minus_t_cu = one_minus_t_sq * one_minus_t;
1226 const float denom = 3.0f * one_minus_t * t_sq;
1227 k1[0] = (mouse_3d[0] - one_minus_t_cu * bezt1->
vec[1][0] - t_cu * bezt2->
vec[1][0]) / denom;
1228 k1[1] = (mouse_3d[1] - one_minus_t_cu * bezt1->
vec[1][1] - t_cu * bezt2->
vec[1][1]) / denom;
1229 k1[2] = (mouse_3d[2] - one_minus_t_cu * bezt1->
vec[1][2] - t_cu * bezt2->
vec[1][2]) / denom;
1243 float handle_vec[3];
1258 float handle_vec[3];
1305 const bool found_point = nu !=
nullptr;
1307 bool deleted =
false;
1314 if (next_bezt && prev_bezt) {
1316 const uint span_step[2] = {
uint(bez_index),
uint(bez_index)};
1325 if (nu->
pntsu == 0) {
1346 if (nu->pntsu == 1) {
1349 if (nu->bezt == bezt) {
1353 else if (nu->bezt + nu->pntsu - 1 == bezt) {
1372 int displacement[2];
1374 const float disp_fl[2] = {
float(displacement[0]),
float(displacement[1])};
1376 vc, adj_bezt, bezt_idx, disp_fl, 0.0f,
false,
false);
1390 if (sel_bezt || (sel_bp && sel_nu->
pntsu > 2)) {
1391 const bool is_bezt_endpoint = ((sel_nu->
type ==
CU_BEZIER) &&
1395 if (!(is_bezt_endpoint || is_bp_endpoint)) {
1407 vc, &(cu->
editnurb->
nurbs), mval_fl, &nu, &bezt, &bp, &bezt_idx);
1462 if (bezt_idx == 0) {
1474 else if (bezt_idx == 2) {
1516 "FREE_ALIGN_TOGGLE",
1518 "Free-Align Toggle",
1519 "Move handle of newly added point freely"},
1523 "Move Adjacent Handle",
1524 "Move the closer handle of the adjacent vertex"},
1528 "Move Entire Point",
1529 "Move the entire point using its handles"},
1534 "Mirror the movement of one handle onto the other"},
1539 "Move the handle along its current angle"},
1540 {0,
nullptr, 0,
nullptr,
nullptr},
1573 params.deselect_all =
false;
1589 const int close_spline_method =
RNA_enum_get(op->
ptr,
"close_spline_method");
1603 if (cpd->
msd ==
nullptr) {
1689 else if (extrude_point) {
1695 if (!cpd->
changed && toggle_vector) {
1699 if (bezt_idx == 1 && cycle_handle_type) {
1727 else if (select_point) {
1732 if (cpd->
msd !=
nullptr) {
1770 const int close_spline_method =
RNA_enum_get(op->
ptr,
"close_spline_method");
1788 &vc, nurbs, mval_fl, &nu1, &bezt1, &bp1, &bezt_idx);
1790 if (move_point && nu1 && !nu1->
hide &&
1820 if (insert_point && !move_seg) {
1825 else if (extrude_point) {
1839 ot->name =
"Curve Pen";
1840 ot->idname =
"CURVE_OT_pen";
1841 ot->description =
"Construct and edit splines";
1858 "Add a point connected to the last selected point");
1863 "Extrude Handle Type",
1864 "Type of the extruded handle");
1865 RNA_def_boolean(
ot->srna,
"delete_point",
false,
"Delete Point",
"Delete an existing point");
1867 ot->srna,
"insert_point",
false,
"Insert Point",
"Insert Point into a curve segment");
1868 RNA_def_boolean(
ot->srna,
"move_segment",
false,
"Move Segment",
"Delete an existing point");
1870 ot->srna,
"select_point",
false,
"Select Point",
"Select a point or its handles");
1871 RNA_def_boolean(
ot->srna,
"move_point",
false,
"Move Point",
"Move a point or its handles");
1876 "Make a spline cyclic by clicking endpoints");
1878 "close_spline_method",
1881 "Close Spline Method",
1882 "The condition for close spline to activate");
1884 ot->srna,
"toggle_vector",
false,
"Toggle Vector",
"Toggle between Vector and Auto handles");
1886 "cycle_handle_type",
1888 "Cycle Handle Type",
1889 "Cycle between all four handle types");
Depsgraph * CTX_data_ensure_evaluated_depsgraph(const bContext *C)
Object * CTX_data_edit_object(const bContext *C)
void BKE_nurb_handles_calc(Nurb *nu)
void BKE_nurb_free(Nurb *nu)
void BKE_curve_nurb_vert_active_set(Curve *cu, const Nurb *nu, const void *vert)
void BKE_nurb_knot_calc_u(Nurb *nu)
void BKE_curve_forward_diff_bezier(float q0, float q1, float q2, float q3, float *p, int it, int stride)
ListBase * BKE_curve_editNurbs_get(Curve *cu)
void BKE_curve_nurb_vert_active_validate(Curve *cu)
BezTriple * BKE_nurb_bezt_get_next(Nurb *nu, BezTriple *bezt)
void BKE_curve_editNurb_keyIndex_delCV(GHash *keyindex, const void *cv)
int BKE_curve_nurb_vert_index_get(const Nurb *nu, const void *vert)
BezTriple * BKE_nurb_bezt_get_prev(Nurb *nu, BezTriple *bezt)
#define LISTBASE_FOREACH(type, var, list)
void BLI_remlink(struct ListBase *listbase, void *vlink) ATTR_NONNULL(1)
int BLI_findindex(const struct ListBase *listbase, const void *vlink) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
MINLINE float max_ff(float a, float b)
MINLINE float min_ff(float a, float b)
MINLINE float interpf(float target, float origin, float t)
bool isect_ray_plane_v3_factor(const float ray_origin[3], const float ray_direction[3], const float plane_co[3], const float plane_no[3], float *r_lambda)
void mul_m4_v3(const float M[4][4], float r[3])
void mul_v3_m4v3(float r[3], const float mat[4][4], const float vec[3])
bool invert_m4_m4(float inverse[4][4], const float mat[4][4])
MINLINE void sub_v2_v2v2_int(int r[2], const int a[2], const int b[2])
MINLINE float len_v2(const float v[2]) ATTR_WARN_UNUSED_RESULT
MINLINE float len_v3v3(const float a[3], const float b[3]) ATTR_WARN_UNUSED_RESULT
float angle_v2v2(const float a[2], const float b[2]) ATTR_WARN_UNUSED_RESULT
MINLINE void sub_v3_v3v3(float r[3], const float a[3], const float b[3])
MINLINE float len_v2v2(const float v1[2], const float v2[2]) ATTR_WARN_UNUSED_RESULT
void interp_v2_v2v2(float r[2], const float a[2], const float b[2], float t)
MINLINE void copy_v2_v2(float r[2], const float a[2])
MINLINE void mul_v3_fl(float r[3], float f)
MINLINE void copy_v2_v2_int(int r[2], const int a[2])
MINLINE void copy_v3_v3(float r[3], const float a[3])
float cos_v2v2v2(const float p1[2], const float p2[2], const float p3[2]) ATTR_WARN_UNUSED_RESULT
MINLINE float dot_v3v3(const float a[3], const float b[3]) ATTR_WARN_UNUSED_RESULT
void interp_v3_v3v3(float r[3], const float a[3], const float b[3], float t)
MINLINE void add_v3_v3v3(float r[3], const float a[3], const float b[3])
MINLINE float normalize_v3_v3(float r[3], const float a[3])
MINLINE float len_manhattan_v2v2(const float a[2], const float b[2]) ATTR_WARN_UNUSED_RESULT
MINLINE void add_v2_v2v2(float r[2], const float a[2], const float b[2])
MINLINE void sub_v2_v2v2(float r[2], const float a[2], const float b[2])
MINLINE float mul_project_m4_v3_zfac(const float mat[4][4], const float co[3]) ATTR_WARN_UNUSED_RESULT
MINLINE float dot_v2v2(const float a[2], const float b[2]) ATTR_WARN_UNUSED_RESULT
MINLINE void madd_v3_v3v3fl(float r[3], const float a[3], const float b[3], float f)
MINLINE void zero_v3(float r[3])
MINLINE void add_v3_v3(float r[3], const float a[3])
MINLINE float normalize_v3_length(float n[3], float unit_length)
void DEG_id_tag_update(ID *id, unsigned int flags)
#define BEZT_DESEL_IDX(bezt, i)
#define BEZT_ISSEL_IDX(bezt, i)
#define BEZT_ISSEL_ANY_HIDDENHANDLES(v3d, bezt)
#define BEZT_ISSEL_ANY(bezt)
#define BEZT_DESEL_ALL(bezt)
#define BEZT_SEL_IDX(bezt, i)
bool ED_operator_editcurve(bContext *C)
float ED_view3d_select_dist_px()
void ED_view3d_global_to_vector(const RegionView3D *rv3d, const float coord[3], float r_out[3])
eV3DProjStatus ED_view3d_project_float_object(const ARegion *region, const float co[3], float r_co[2], eV3DProjTest flag)
void ED_view3d_win_to_3d_int(const View3D *v3d, const ARegion *region, const float depth_pt[3], const int mval[2], float r_out[3])
void ED_view3d_win_to_3d(const View3D *v3d, const ARegion *region, const float depth_pt[3], const float mval[2], float r_out[3])
ViewContext ED_view3d_viewcontext_init(bContext *C, Depsgraph *depsgraph)
Read Guarded memory(de)allocation.
in reality light always falls off quadratically Particle Retrieve the data of the particle that spawned the object for example to give variation to multiple instances of an object Point Retrieve information about points in a point cloud Retrieve the edges of an object as it appears to Cycles topology will always appear triangulated Convert a blackbody temperature to an RGB value Normal Generate a perturbed normal from an RGB normal map image Typically used for faking highly detailed surfaces Generate an OSL shader from a file or text data block Image Sample an image file as a texture Gabor Generate Gabor noise Gradient Generate interpolated color and intensity values based on the input vector Magic Generate a psychedelic color texture Voronoi Generate Worley noise based on the distance to random points Typically used to generate textures such as or biological cells Brick Generate a procedural texture producing bricks Texture Retrieve multiple types of texture coordinates nTypically used as inputs for texture nodes Vector Convert a point
BPy_StructRNA * depsgraph
void ed_dissolve_bez_segment(BezTriple *bezt_prev, BezTriple *bezt_next, const Nurb *nu, const Curve *cu, const uint span_len, const uint span_step[2])
bool curve_toggle_cyclic(View3D *v3d, ListBase *editnurb, int direction)
int ed_editcurve_addvert(Curve *cu, EditNurb *editnurb, View3D *v3d, const float location_init[3])
void ED_curve_beztcpy(EditNurb *editnurb, BezTriple *dst, BezTriple *src, int count)
ListBase * object_editcurve_get(Object *ob)
bool ED_curve_editnurb_select_pick(bContext *C, const int mval[2], const int dist_px, const SelectPick_Params *params)
void ED_curve_bpcpy(EditNurb *editnurb, BPoint *dst, BPoint *src, int count)
static void insert_bp_to_nurb(Nurb *nu, const CutData *data, Curve *cu)
static void move_adjacent_handle(const ViewContext *vc, const wmEvent *event, ListBase *nurbs)
static void move_segment(const ViewContext *vc, MoveSegmentData *seg_data, const wmEvent *event)
static bool update_cut_data_for_all_nurbs(const ViewContext *vc, const ListBase *nurbs, const float point[2], const float sel_dist, CutData *cd)
static void toggle_handle_types(BezTriple *bezt, int bezt_idx, CurvePenData *cpd)
static void move_bezt_by_displacement(BezTriple *bezt, const float disp_3d[3])
static bool insert_point_to_segment(const ViewContext *vc, const wmEvent *event)
static void delete_bp_from_nurb(const BPoint *bp, Nurb *nu, EditNurb *editnurb)
static void extrude_vertices_from_selected_endpoints(EditNurb *editnurb, ListBase *nurbs, Curve *cu, const float disp_3d[3])
static void delete_bezt_from_nurb(const BezTriple *bezt, Nurb *nu, EditNurb *editnurb)
static bool is_cyclic(const Nurb *nu)
static void extrude_points_from_selected_vertices(const ViewContext *vc, const wmEvent *event, const int extrude_handle)
static void delete_nurb(Curve *cu, Nurb *nu)
static void toggle_select_bezt(BezTriple *bezt, const int bezt_idx, Curve *cu, Nurb *nu)
static void screenspace_to_worldspace(const ViewContext *vc, const float pos_2d[2], const float depth[3], float r_pos_3d[3])
static void move_bezt_to_location(BezTriple *bezt, const float location[3])
static void move_all_selected_points(const ViewContext *vc, const wmEvent *event, CurvePenData *cpd, ListBase *nurbs, const bool bezt_only)
static bool worldspace_to_screenspace(const ViewContext *vc, const float pos_3d[3], float r_pos_2d[2])
@ PEN_MODAL_MOVE_ADJACENT
@ PEN_MODAL_FREE_ALIGN_TOGGLE
static bool delete_point_under_mouse(const ViewContext *vc, const wmEvent *event)
static void get_updated_data_for_edge(const float point[2], const float point1[2], const float point2[2], const int point_idx, const int resolu_idx, float *r_min_dist, int *r_min_i, float *r_param)
static CutData init_cut_data(const wmEvent *event)
static void toggle_bezt_free_align_handles(BezTriple *bezt)
static void toggle_sel_bezt_free_align_handles(ListBase *nurbs)
static void get_first_selected_point(Curve *cu, View3D *v3d, Nurb **r_nu, BezTriple **r_bezt, BPoint **r_bp)
static void deselect_all_center_vertices(ListBase *nurbs)
static void remove_handle_movement_constraints(BezTriple *bezt, const bool f1, const bool f3)
static void screenspace_to_worldspace_int(const ViewContext *vc, const int pos_2d[2], const float depth[3], float r_pos_3d[3])
static int curve_pen_invoke(bContext *C, wmOperator *op, const wmEvent *event)
static void init_selected_bezt_handles(ListBase *nurbs)
static void move_bp_to_location(const ViewContext *vc, BPoint *bp, const float mval[2])
static bool is_last_bezt(const Nurb *nu, const BezTriple *bezt)
static int get_nurb_index(const ListBase *nurbs, const Nurb *nurb)
void CURVE_OT_pen(wmOperatorType *ot)
static bool is_spline_nearby(ViewContext *vc, wmOperator *op, const wmEvent *event, const float sel_dist)
wmKeyMap * curve_pen_modal_keymap(wmKeyConfig *keyconf)
static void get_bezier_interpolated_point(const BezTriple *bezt1, const BezTriple *bezt2, const float parameter, float r_point[3])
#define FOREACH_SELECTED_BEZT_END
static void toggle_select_bp(BPoint *bp, Curve *cu, Nurb *nu)
static const EnumPropertyItem prop_close_spline_method[]
static void move_bezt_handle_or_vertex_by_displacement(const ViewContext *vc, BezTriple *bezt, const int bezt_idx, const float disp_2d[2], const float distance, const bool link_handles, const bool lock_angle)
static const EnumPropertyItem prop_handle_types[]
static int curve_pen_modal(bContext *C, wmOperator *op, const wmEvent *event)
static bool get_closest_vertex_to_point_in_nurbs(const ViewContext *vc, const ListBase *nurbs, const float point[2], Nurb **r_nu, BezTriple **r_bezt, BPoint **r_bp, int *r_bezt_idx)
static bool get_selected_center(const ListBase *nurbs, const bool mid_only, const bool bezt_only, float r_center[3])
#define FOREACH_SELECTED_BEZT_BEGIN(bezt, nurbs)
static bool make_cyclic_if_endpoints(const ViewContext *vc, Nurb *sel_nu, BezTriple *sel_bezt, BPoint *sel_bp)
static void update_location_for_2d_curve(const ViewContext *vc, float location[3])
static void cycle_handles(BezTriple *bezt)
static void insert_bezt_to_nurb(Nurb *nu, const CutData *data, Curve *cu)
static void update_cut_data_for_nurb(const ViewContext *vc, CutData *cd, Nurb *nu, const int resolu, const float point[2])
static void calculate_new_bezier_point(const float point_prev[3], float handle_prev[3], float new_left_handle[3], float new_right_handle[3], float handle_next[3], const float point_next[3], const float parameter)
bool ED_curve_deselect_all(EditNurb *editnurb)
draw_view in_light_buf[] float
void *(* MEM_mallocN)(size_t len, const char *str)
void MEM_freeN(void *vmemh)
void *(* MEM_callocN)(size_t len, const char *str)
float distance(float a, float b)
bool RNA_boolean_get(PointerRNA *ptr, const char *name)
int RNA_enum_get(PointerRNA *ptr, const char *name)
PropertyRNA * RNA_def_enum(StructOrFunctionRNA *cont_, const char *identifier, const EnumPropertyItem *items, const int default_value, const char *ui_name, const char *ui_description)
PropertyRNA * RNA_def_boolean(StructOrFunctionRNA *cont_, const char *identifier, const bool default_value, const char *ui_name, const char *ui_description)
bool WM_event_drag_test(const wmEvent *event, const int prev_xy[2])
wmEventHandler_Op * WM_event_add_modal_handler(bContext *C, wmOperator *op)
void WM_event_add_notifier(const bContext *C, uint type, void *reference)
#define ISMOUSE_MOTION(event_type)
wmKeyMap * WM_modalkeymap_ensure(wmKeyConfig *keyconf, const char *idname, const EnumPropertyItem *items)
void WM_modalkeymap_assign(wmKeyMap *km, const char *opname)
wmKeyMap * WM_modalkeymap_find(wmKeyConfig *keyconf, const char *idname)
void WM_operator_properties_mouse_select(wmOperatorType *ot)