87 #define USE_FACE_CREATE_SEL_EXTEND
108 uint objects_len = 0;
112 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
113 Object *obedit = objects[ob_index];
169 prop =
RNA_def_int(
ot->
srna,
"number_cuts", 1, 1, 100,
"Number of Cuts",
"", 1, 10);
175 ot->
srna,
"smoothness", 0.0f, 0.0f, 1e3f,
"Smoothness",
"Smoothness factor", 0.0f, 1.0f);
183 "When disabled, newly created faces are limited to 3 and 4 sided faces");
190 "How to subdivide quad corners (anything other than Straight Cut will prevent n-gons)");
198 "Fractal randomness factor",
202 "fractal_along_normal",
207 "Apply fractal displacement along normal only",
216 "Seed for the random number generator",
241 const int cuts_default)
254 ot->
srna,
"number_cuts", cuts_default, 0, 1000,
"Number of Cuts",
"", cuts_min, 64);
259 prop_subd_edgering_types,
262 "Interpolation method");
265 ot->
srna,
"smoothness", 1.0f, 0.0f, 1e3f,
"Smoothness",
"Smoothness factor", 0.0f, 2.0f);
269 "profile_shape_factor",
274 "How much intermediary new edges are shrunk/expanded",
299 uint objects_len = 0;
306 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
307 Object *obedit = objects[ob_index];
316 "subdivide_edgering edges=%he interp_mode=%i cuts=%i smooth=%f "
317 "profile_shape=%i profile_shape_factor=%f",
337 ot->
name =
"Subdivide Edge-Ring";
338 ot->
description =
"Subdivide perpendicular edges to the selected edge-ring";
339 ot->
idname =
"MESH_OT_subdivide_edgering";
362 uint objects_len = 0;
365 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
366 Object *obedit = objects[ob_index];
397 ot->
name =
"Un-Subdivide";
410 ot->
srna,
"iterations", 2, 1, 1000,
"Iterations",
"Number of times to un-subdivide", 1, 100);
429 const int totelem_old[3],
430 const int totelem_new[3])
434 "Removed: %d vertices, %d edges, %d faces",
435 totelem_old[0] - totelem_new[0],
436 totelem_old[1] - totelem_new[1],
437 totelem_old[2] - totelem_new[2]);
444 uint objects_len = 0;
447 bool changed_multi =
false;
449 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
450 Object *obedit = objects[ob_index];
496 changed_multi =
true;
526 ot->
description =
"Delete selected vertices, edges or faces";
541 prop_mesh_delete_types,
544 "Method used for deleting mesh data");
563 }
while ((l_iter = l_iter->
next) != l_first);
571 int totelem_old_sel[3];
574 uint objects_len = 0;
584 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
585 Object *obedit = objects[ob_index];
647 ot->
name =
"Delete Loose";
649 ot->
idname =
"MESH_OT_delete_loose";
674 uint objects_len = 0;
677 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
678 Object *obedit = objects[ob_index];
699 ot->
name =
"Collapse Edges & Faces";
701 "Collapse isolated edge and face regions, merging data such as UV's and vertex colors. "
702 "This can collapse edge-rings as well as regions of connected faces into vertices";
703 ot->
idname =
"MESH_OT_edge_collapse";
724 uint vote_on_smooth[2] = {0, 0};
732 return (vote_on_smooth[0] < vote_on_smooth[1]);
735 #ifdef USE_FACE_CREATE_SEL_EXTEND
748 if ((e_used ==
NULL) || (e_used != e_iter)) {
751 if (i >= e_arr_len) {
900 bool changed_multi =
false;
902 uint objects_len = 0;
905 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
906 Object *obedit = objects[ob_index];
918 #ifdef USE_FACE_CREATE_SEL_EXTEND
929 "contextual_create geom=%hfev mat_nr=%i use_smooth=%b",
943 #ifdef USE_FACE_CREATE_SEL_EXTEND
975 changed_multi =
true;
979 if (!changed_multi) {
989 ot->
name =
"Make Edge/Face";
991 ot->
idname =
"MESH_OT_edge_face_add";
1015 uint objects_len = 0;
1018 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
1019 Object *obedit = objects[ob_index];
1048 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
1049 Object *obedit = objects[ob_index];
1094 uint objects_len = 0;
1097 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
1098 Object *obedit = objects[ob_index];
1150 "Consider vertices instead of edges to select which edges to (un)tag as sharp");
1165 bool is_pair = (verts_len == 2);
1167 bool check_degenerate =
true;
1169 bool checks_succeded =
true;
1172 if (verts_len < 2) {
1192 check_degenerate =
false;
1201 "connect_vert_pair verts=%eb verts_exclude=%hv faces_exclude=%hf",
1206 checks_succeded =
false;
1213 "connect_verts verts=%eb faces_exclude=%hf check_degenerate=%b",
1217 check_degenerate)) {
1218 checks_succeded =
false;
1221 if (checks_succeded) {
1227 if (
len && is_pair) {
1253 uint objects_len = 0;
1254 uint failed_objects_len = 0;
1258 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
1259 Object *obedit = objects[ob_index];
1263 failed_objects_len++;
1273 ot->
name =
"Vertex Connect";
1274 ot->
idname =
"MESH_OT_vert_connect";
1275 ot->
description =
"Connect selected vertices of faces, splitting the face";
1342 bool changed =
false;
1343 bool has_wire =
false;
1359 if (has_wire ==
false) {
1364 ese = ese_last->
next;
1374 }
while ((
void)(ese_last = ese), (ese = ese->
next));
1381 if (changed ==
false) {
1399 ese = ese_prev->
next;
1411 }
while ((
void)(ese_prev = ese), (ese = ese->
next));
1413 if (changed ==
false) {
1459 for (ese = selected_orig.
first; ese; ese = ese->
next) {
1469 if ((e_curr->
v1 != l_curr->
v) == (e_prev->v1 != l_prev->
v)) {
1478 v = (&e_curr->
v1)[side];
1483 v = (&e_curr->
v1)[!side];
1500 uint objects_len = 0;
1501 uint failed_selection_order_len = 0;
1502 uint failed_connect_len = 0;
1506 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
1507 Object *obedit = objects[ob_index];
1520 failed_connect_len++;
1544 failed_selection_order_len++;
1555 if (failed_selection_order_len == objects_len) {
1559 if (failed_connect_len == objects_len) {
1570 ot->
name =
"Vertex Connect Path";
1571 ot->
idname =
"MESH_OT_vert_connect_path";
1572 ot->
description =
"Connect vertices by their selection order, creating edges, splitting faces";
1591 uint objects_len = 0;
1594 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
1595 Object *obedit = objects[ob_index];
1603 em, op,
"faces.out",
true,
"connect_verts_concave faces=%hf",
BM_ELEM_SELECT)) {
1616 ot->
name =
"Split Concave Faces";
1617 ot->
idname =
"MESH_OT_vert_connect_concave";
1638 uint objects_len = 0;
1642 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
1643 Object *obedit = objects[ob_index];
1654 "connect_verts_nonplanar faces=%hf angle_limit=%f",
1672 ot->
name =
"Split Non-Planar Faces";
1673 ot->
idname =
"MESH_OT_vert_connect_nonplanar";
1674 ot->
description =
"Split non-planar faces that exceed the angle threshold";
1706 uint objects_len = 0;
1713 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
1714 Object *obedit = objects[ob_index];
1722 "planar_faces faces=%hf iterations=%i factor=%f",
1739 ot->
name =
"Make Planar Faces";
1740 ot->
idname =
"MESH_OT_face_make_planar";
1771 em, op,
"edges.out",
false,
"split_edges edges=%he",
BM_ELEM_SELECT)) {
1800 if (eed->
l !=
NULL) {
1816 "split_edges edges=%he verts=%hv use_verts=%b",
1824 if (eed->
l !=
NULL) {
1834 for (
int i = 0; i < 2; i++) {
1858 uint objects_len = 0;
1861 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
1862 Object *obedit = objects[ob_index];
1890 ot->
description =
"Split selected edges so that each neighbor face gets its own copy";
1901 {
BM_EDGE,
"EDGE", 0,
"Faces by Edges",
"Split faces along selected edges"},
1905 "Faces & Edges by Vertices",
1906 "Split faces and edges connected to selected vertices"},
1923 uint objects_len = 0;
1927 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
1928 Object *obedit = objects[ob_index];
1940 "duplicate geom=%hvef use_select_history=%b use_edge_flip_from_face=%b",
1981 ot->
description =
"Duplicate selected vertices, edges or faces";
2005 return lnors_ed_arr;
2010 if (!lnors_ed_arr) {
2014 if (lnors_ed_arr->
totloop == 0) {
2031 for (
int i = 0; i < lnors_ed_arr_new_full->
totloop; i++, lnor_ed_new_full++) {
2076 }
while (
l != l_start);
2092 uint objects_len = 0;
2096 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
2097 Object *obedit = objects[ob_index];
2109 for (
int i = 0; i < lnors_ed_arr->
totloop; i++, lnor_ed++) {
2126 bool has_flipped_faces =
false;
2132 has_flipped_faces =
true;
2139 if (lnors_ed_arr !=
NULL) {
2151 ot->
name =
"Flip Normals";
2152 ot->
description =
"Flip the direction of selected faces' normals (and of their vertices)";
2153 ot->
idname =
"MESH_OT_flip_normals";
2165 "Custom Normals Only",
2166 "Only flip the custom loop normals of the selected elements");
2184 int tot_rotate_all = 0, tot_failed_all = 0;
2185 bool no_selected_edges =
true, invalid_selected_edges =
true;
2188 uint objects_len = 0;
2191 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
2192 Object *obedit = objects[ob_index];
2199 no_selected_edges =
false;
2222 invalid_selected_edges =
false;
2240 const int tot_failed = tot - tot_rotate;
2242 tot_rotate_all += tot_rotate;
2243 tot_failed_all += tot_failed;
2245 if (tot_failed != 0) {
2262 if (no_selected_edges) {
2264 op->
reports,
RPT_ERROR,
"Select edges or face pairs for edge loops to rotate about");
2270 if (invalid_selected_edges) {
2275 if (tot_failed_all != 0) {
2285 ot->
name =
"Rotate Selected Edge";
2286 ot->
description =
"Rotate selected edge or adjoining faces";
2287 ot->
idname =
"MESH_OT_edge_rotate";
2310 bool changed =
false;
2312 uint objects_len = 0;
2315 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
2316 Object *obedit = objects[ob_index];
2360 ot->
name =
"Hide Selected";
2362 ot->
description =
"Hide (un)selected vertices, edges or faces";
2373 ot->
srna,
"unselected",
false,
"Unselected",
"Hide unselected rather than selected");
2387 uint objects_len = 0;
2390 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
2391 Object *obedit = objects[ob_index];
2406 ot->
name =
"Reveal Hidden";
2408 ot->
description =
"Reveal all hidden vertices, edges and faces";
2431 uint objects_len = 0;
2434 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
2435 Object *obedit = objects[ob_index];
2456 if (lnors_ed_arr !=
NULL) {
2471 ot->
name =
"Recalculate Normals";
2472 ot->
description =
"Make face and vertex normals point either outside or inside the mesh";
2473 ot->
idname =
"MESH_OT_normals_make_consistent";
2505 uint objects_len = 0;
2508 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
2509 Object *obedit = objects[ob_index];
2512 bool mirrx =
false, mirry =
false, mirrz =
false;
2513 float clip_dist = 0.0f;
2548 for (
int i = 0; i < repeat; i++) {
2552 "smooth_vert verts=%hv factor=%f mirror_clip_x=%b mirror_clip_y=%b mirror_clip_z=%b "
2553 "clip_dist=%f use_axis_x=%b use_axis_y=%b use_axis_z=%b",
2583 ot->
name =
"Smooth Vertices";
2585 ot->
idname =
"MESH_OT_vertices_smooth";
2595 ot->
srna,
"factor", 0.0f, -10.0f, 10.0f,
"Smoothing",
"Smoothing factor", 0.0f, 1.0f);
2597 ot->
srna,
"repeat", 1, 1, 1000,
"Repeat",
"Number of times to smooth the mesh", 1, 100);
2619 int tot_invalid = 0;
2620 int tot_unselected = 0;
2635 uint objects_len = 0;
2638 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
2639 Object *obedit = objects[ob_index];
2650 bool is_invalid =
false;
2670 bool failed_repeat_loop =
false;
2671 for (
int i = 0; i < repeat; i++) {
2674 "smooth_laplacian_vert verts=%hv lambda_factor=%f lambda_border=%f "
2675 "use_x=%b use_y=%b use_z=%b preserve_volume=%b",
2683 failed_repeat_loop =
true;
2687 if (failed_repeat_loop) {
2701 if (tot_unselected == objects_len) {
2705 if (tot_invalid == objects_len) {
2716 ot->
name =
"Laplacian Smooth Vertices";
2718 ot->
idname =
"MESH_OT_vertices_smooth_laplacian";
2728 ot->
srna,
"repeat", 1, 1, 1000,
"Number of iterations to smooth the mesh",
"", 1, 200);
2730 ot->
srna,
"lambda_factor", 1.0f, 1e-7f, 1000.0f,
"Lambda factor",
"", 1e-7f, 1000.0f);
2736 "Lambda factor in border",
2750 "Apply volume preservation after smooth");
2778 uint objects_len = 0;
2781 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
2782 Object *obedit = objects[ob_index];
2800 ot->
name =
"Shade Smooth";
2801 ot->
description =
"Display faces smooth (using vertex normals)";
2802 ot->
idname =
"MESH_OT_faces_shade_smooth";
2821 uint objects_len = 0;
2824 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
2825 Object *obedit = objects[ob_index];
2845 ot->
idname =
"MESH_OT_faces_shade_flat";
2867 uint objects_len = 0;
2870 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
2871 Object *obedit = objects[ob_index];
2900 uint objects_len = 0;
2903 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
2904 Object *obedit = objects[ob_index];
2936 uint objects_len = 0;
2940 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
2941 Object *ob = objects[ob_index];
2972 uint objects_len = 0;
2976 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
2977 Object *obedit = objects[ob_index];
3025 ot->
name =
"Reverse UVs";
3026 ot->
idname =
"MESH_OT_uvs_reverse";
3027 ot->
description =
"Flip direction of UV coordinates inside faces";
3043 ot->
name =
"Rotate Colors";
3044 ot->
idname =
"MESH_OT_colors_rotate";
3061 ot->
name =
"Reverse Colors";
3062 ot->
idname =
"MESH_OT_colors_reverse";
3063 ot->
description =
"Flip direction of vertex colors inside faces";
3074 RNA_def_enum(
ot->
srna,
"axis", axis_items, DIRECTION_CW,
"Axis",
"Axis to mirror colors around");
3093 const bool use_first,
3094 const bool use_uvmerge,
3106 if (use_first ==
false) {
3129 em, wmop,
"pointmerge_facedata verts=%hv vert_snap=%e",
BM_ELEM_SELECT, mergevert)) {
3135 em, wmop,
"pointmerge verts=%hv merge_co=%v",
BM_ELEM_SELECT, mergevert->
co)) {
3145 const bool use_cursor,
3146 const bool use_uvmerge,
3151 float co[3], cent[3] = {0.0f, 0.0f, 0.0f};
3152 const float *vco =
NULL;
3175 fac = 1.0f / (
float)i;
3202 uint objects_len = 0;
3208 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
3209 Object *obedit = objects[ob_index];
3359 const bool use_sharp_edge_from_normals =
RNA_boolean_get(op->
ptr,
"use_sharp_edge_from_normals");
3361 int count_multi = 0;
3364 uint objects_len = 0;
3368 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
3369 Object *obedit = objects[ob_index];
3378 const int totvert_orig = em->
bm->
totvert;
3397 if (use_unselected) {
3405 if (!
EDBM_op_callf(em, op,
"weld_verts targetmap=%S", &bmop,
"targetmap.out")) {
3424 count_multi +=
count;
3438 ot->
name =
"Merge by Distance";
3439 ot->
description =
"Merge vertices based on their proximity";
3440 ot->
idname =
"MESH_OT_remove_doubles";
3455 "Maximum distance between elements to merge",
3462 "Merge selected to other unselected vertices");
3465 "use_sharp_edge_from_normals",
3468 "Calculate sharp edges using custom normal data (when available)");
3494 for (
int i = 0; i < totshape; i++) {
3505 int tot_shapekeys = 0;
3506 int tot_selected_verts_objects = 0;
3508 uint objects_len = 0;
3511 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
3512 Object *obedit = objects[ob_index];
3519 tot_selected_verts_objects++;
3529 if (tot_selected_verts_objects == 0) {
3533 if (tot_shapekeys == 0) {
3536 objects_len > 1 ?
"Meshes do not have shape keys" :
3537 "Mesh does not have shape keys");
3547 ot->
name =
"Shape Propagate";
3548 ot->
description =
"Apply selected vertex locations to all other shape keys";
3549 ot->
idname =
"MESH_OT_shape_propagate_to_all";
3570 Key *key_ref = me_ref->
key;
3577 int totshape_ref = 0;
3586 if (totshape_ref == 0 || shape_ref < 0) {
3590 if (shape_ref >= totshape_ref) {
3600 int tot_selected_verts_objects = 0;
3601 uint objects_len = 0;
3604 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
3605 Object *obedit = objects[ob_index];
3615 tot_selected_verts_objects++;
3652 if (tot_selected_verts_objects == 0) {
3680 tmp.
value = totitem;
3719 ot->
name =
"Blend from Shape";
3721 ot->
idname =
"MESH_OT_blend_from_shape";
3738 RNA_def_float(
ot->
srna,
"blend", 1.0f, -1e3f, 1e3f,
"Blend",
"Blending factor", -2.0f, 2.0f);
3753 uint objects_len = 0;
3756 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
3757 Object *obedit = objects[ob_index];
3768 em, &bmop, op,
"solidify geom=%hf thickness=%f",
BM_ELEM_SELECT, thickness)) {
3799 ot->
description =
"Create a solid skin by extruding, compensating for sharp angles";
3810 ot->
srna,
"thickness", 0.01f, -1e4f, 1e4f,
"Thickness",
"", -10.0f, 10.0f);
3820 #define KNIFE_EXACT 1
3821 #define KNIFE_MIDPOINT 2
3822 #define KNIFE_MULTICUT 3
3834 const float sco_b[2],
3835 float (*mouse_path)[2],
3840 #define MAXSLOPE 100000
3841 float x11, y11, x12 = 0, y12 = 0, x2max, x2min, y2max;
3842 float y2min, dist, lastdist = 0, xdiff2, xdiff1;
3843 float m1, b1, m2, b2, x21, x22, y21, y22, xi;
3844 float yi, x1min, x1max, y1max, y1min, perc = 0;
3845 float threshold = 0.0;
3858 xdiff2 = (x22 - x21);
3860 m2 = (y22 - y21) / xdiff2;
3861 b2 = ((x22 * y21) - (x21 * y22)) / xdiff2;
3872 for (i = 0; i <
len; i++) {
3878 x11 = mouse_path[i][0];
3879 y11 = mouse_path[i][1];
3881 x12 = mouse_path[i][0];
3882 y12 = mouse_path[i][1];
3885 if ((x11 == x21 && y11 == y21) || (x12 == x21 && y12 == y21)) {
3891 if ((x11 == x22 && y11 == y22) || (x12 == x22 && y12 == y22)) {
3900 for (i = 0; i <
len; i++) {
3906 x11 = mouse_path[i][0];
3907 y11 = mouse_path[i][1];
3909 x12 = mouse_path[i][0];
3910 y12 = mouse_path[i][1];
3915 dist = (y12 - m2 * x12 - b2);
3926 if ((lastdist * dist) <= 0) {
3927 xdiff1 = (x12 - x11);
3929 m1 = (y12 - y11) / xdiff1;
3930 b1 = ((x12 * y11) - (x11 * y12)) / xdiff1;
3936 x2max =
max_ff(x21, x22) + 0.001f;
3937 x2min =
min_ff(x21, x22) - 0.001f;
3938 y2max =
max_ff(y21, y22) + 0.001f;
3939 y2min =
min_ff(y21, y22) - 0.001f;
3944 x1max =
max_ff(x11, x12);
3945 x1min =
min_ff(x11, x12);
3946 xi = (
min_ff(x2max, x1max) +
max_ff(x2min, x1min)) / 2.0f;
3948 y1max =
max_ff(y11, y12);
3949 y1min =
min_ff(y11, y12);
3950 yi = (
min_ff(y2max, y1max) +
max_ff(y2min, y1min)) / 2.0f;
3961 xi = (b1 - b2) / (m2 - m1);
3962 yi = (b1 * m2 - m1 * b2) / (m2 - m1);
3966 if ((xi >= x2min) && (xi <= x2max) && (yi <= y2max) && (yi >= y2min)) {
3969 if (xi <= (x21 + threshold) && xi >= (x21 - threshold)) {
3970 if (yi <= (y21 + threshold) && yi >= (y21 - threshold)) {
3976 if (xi <= (x22 + threshold) && xi >= (x22 - threshold)) {
3977 if (yi <= (y22 + threshold) && yi >= (y22 - threshold)) {
3984 if ((m2 <= 1.0f) && (m2 >= -1.0f)) {
3985 perc = (xi - x21) / (x22 - x21);
3988 perc = (yi - y21) / (y22 - y21);
4000 #define ELE_EDGE_CUT 1
4018 float(*screen_vert_coords)[2], (*sco)[2], (*mouse_path)[2];
4073 bool is_cut =
false;
4079 if ((sco_a[0] != FLT_MAX) && (sco_b[0] != FLT_MAX)) {
4082 if (isect != 0.0f) {
4129 ot->
description =
"Cut selected edges and faces into parts";
4172 .use_toolflags =
true,
4196 "duplicate geom=%hvef dest=%p",
4201 "delete geom=%hvef context=%i",
4234 .totedge = edges_len,
4235 .totloop = faces_len * 3,
4236 .totface = faces_len,
4244 if (use_custom_normals) {
4270 if (use_custom_normals) {
4274 for (
uint i = 0; i < verts_len; i++) {
4312 if ((totcolp && matarar) == 0) {
4322 if (mat_nr < ob->totcol) {
4323 ma_ob = ob->
mat[mat_nr];
4331 if (mat_nr < *totcolp) {
4332 ma_obdata = (*matarar)[mat_nr];
4345 (*matarar)[0] = ma_obdata;
4364 const short mat_nr = f_cmp->
mat_nr;
4370 if (f->
mat_nr == mat_nr) {
4379 }
while ((l_iter = l_iter->
next) != l_first);
4414 const bool clear_object_data =
true;
4422 int(*groups)[3] =
NULL;
4424 bm_old, vert_groups, edge_groups, face_groups, &groups);
4425 if (groups_len <= 1) {
4429 if (clear_object_data) {
4437 for (
int i = 1; i < groups_len; i++) {
4443 vert_groups + group_ofs[0],
4445 edge_groups + group_ofs[1],
4447 face_groups + group_ofs[2],
4451 group_ofs[0] += groups[i][0];
4452 group_ofs[1] += groups[i][1];
4453 group_ofs[2] += groups[i][2];
4459 if (clear_object_data) {
4464 .update_shapekey_indices =
true,
4484 bool changed_multi =
false;
4488 uint empty_selection_len = 0;
4491 for (
uint bs_index = 0; bs_index < bases_len; bs_index++) {
4492 Base *base = bases[bs_index];
4494 bool changed =
false;
4499 if (++empty_selection_len == bases_len) {
4525 changed_multi |= changed;
4537 Object *ob = base_iter->object;
4542 bool changed =
false;
4546 .use_toolflags =
true,
4568 .calc_object_remap =
true,
4577 changed_multi |= changed;
4584 if (changed_multi) {
4607 ot->
description =
"Separate selected geometry into a new mesh";
4632 bool has_selected_edges =
false, has_faces_filled =
false;
4635 uint objects_len = 0;
4638 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
4639 Object *obedit = objects[ob_index];
4642 const int totface_orig = em->
bm->
totface;
4647 has_selected_edges =
true;
4651 em, &bmop, op,
"triangle_fill edges=%he use_beauty=%b",
BM_ELEM_SELECT, use_beauty)) {
4662 has_faces_filled =
true;
4676 if (!has_selected_edges) {
4681 if (!has_faces_filled) {
4740 const float eps_even = 1e-3f;
4751 el_store = eloops.
first;
4768 for (
int i = 0; i < edges_len; i++) {
4773 span = verts_len / 4;
4776 span =
min_ii(span, (verts_len / 2) - 1);
4778 offset =
mod_i(offset, verts_len);
4780 if ((
count == 1) && ((verts_len & 1) == 0) && (verts_len == edges_len)) {
4794 float angle_best = -1.0f;
4795 for (v_link =
verts->first; v_link; v_link = v_link->
next) {
4797 if ((
angle > angle_best) || (v_link_best ==
NULL)) {
4799 v_link_best = v_link;
4803 v_act_link = v_link_best;
4804 v_act = v_act_link->
data;
4812 v_act = v_act_link->
data;
4829 for (v_link =
verts->first, i = 0; v_link; v_link = v_link->
next, i++) {
4833 ele_sort[i].
data =
v;
4844 for (i = 0; i < 4; i++) {
4850 for (v_link =
verts->first, i = 0; i < verts_len / 2; v_link = v_link->
next, i++) {
4865 for (i = 0; i < span; i++) {
4885 uint objects_len = 0;
4888 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
4890 Object *obedit = objects[ob_index];
4893 bool use_prepare =
true;
4895 const int totedge_orig = em->
bm->
totedge;
4896 const int totface_orig = em->
bm->
totface;
4937 "grid_fill edges=%he mat_nr=%i use_smooth=%b use_interp_simple=%b",
4941 use_interp_simple)) {
4991 prop =
RNA_def_int(
ot->
srna,
"span", 1, 1, 1000,
"Span",
"Number of grid columns", 1, 100);
4999 "Vertex that is the corner of the grid",
5004 "use_interp_simple",
5007 "Use simple interpolation of grid vertices");
5021 uint objects_len = 0;
5025 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
5026 Object *obedit = objects[ob_index];
5034 em, op,
"faces.out",
true,
"holes_fill edges=%he sides=%i",
BM_ELEM_SELECT, sides)) {
5065 "Number of sides in hole required to fill (zero fills all holes)",
5079 uint objects_len = 0;
5083 const float angle_max =
M_PI;
5087 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
5088 Object *obedit = objects[ob_index];
5095 if (angle_limit >= angle_max) {
5115 "beautify_fill faces=%hf edges=%he",
5134 ot->
name =
"Beautify Faces";
5135 ot->
idname =
"MESH_OT_beautify_fill";
5136 ot->
description =
"Rearrange some faces to try to get less degenerated geometry";
5172 uint objects_len = 0;
5175 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
5176 Object *obedit = objects[ob_index];
5187 "poke faces=%hf offset=%f use_relative_offset=%b center_mode=%i",
5190 use_relative_offset,
5221 "Weighted median face center"},
5240 ot->
srna,
"offset", 0.0f, -1e3f, 1e3f,
"Poke Offset",
"Poke Offset", -1.0f, 1.0f);
5242 "use_relative_offset",
5245 "Scale the offset by surrounding geometry");
5251 "Poke face center calculation");
5266 uint objects_len = 0;
5269 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
5270 Object *obedit = objects[ob_index];
5286 "triangulate faces=%hf quad_method=%i ngon_method=%i",
5320 ot->
name =
"Triangulate Faces";
5321 ot->
idname =
"MESH_OT_quads_convert_to_tris";
5336 "Method for splitting the quads into triangles");
5342 "Method for splitting the n-gons into triangles");
5355 uint objects_len = 0;
5364 is_face_pair = (totelem_sel[2] == 2);
5367 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
5368 Object *obedit = objects[ob_index];
5371 bool do_seam, do_sharp, do_uvs, do_vcols, do_materials;
5372 float angle_face_threshold, angle_shape_threshold;
5379 angle_face_threshold =
DEG2RADF(180.0f);
5387 angle_shape_threshold =
DEG2RADF(180.0f);
5406 "join_triangles faces=%hf angle_face_threshold=%f angle_shape_threshold=%f "
5407 "cmp_seam=%b cmp_sharp=%b cmp_uvs=%b cmp_vcols=%b cmp_materials=%b",
5409 angle_face_threshold,
5410 angle_shape_threshold,
5451 "Shape angle limit",
5466 ot->
name =
"Tris to Quads";
5467 ot->
idname =
"MESH_OT_tris_convert_to_quads";
5495 const float vertex_group_factor =
RNA_float_get(op->
ptr,
"vertex_group_factor");
5498 const float symmetry_eps = 0.00002f;
5499 const int symmetry_axis = use_symmetry ?
RNA_enum_get(op->
ptr,
"symmetry_axis") : -1;
5502 if (ratio == 1.0f) {
5507 uint objects_len = 0;
5511 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
5512 Object *obedit = objects[ob_index];
5522 const int defbase_act = obedit->
actdef - 1;
5524 if (use_vertex_group && (cd_dvert_offset == -1)) {
5526 use_vertex_group =
false;
5533 float weight = 0.0f;
5535 if (use_vertex_group) {
5538 if (invert_vertex_group) {
5539 weight = 1.0f - weight;
5547 vweights[i] = weight;
5556 ratio_adjust = ratio;
5567 int totface_basis = 0;
5568 int totface_adjacent = 0;
5573 const int f_len = f->
len > 4 ? (f->
len - 2) : 1;
5574 totface_basis += f_len;
5576 BMLoop *l_iter, *l_first;
5580 totface_adjacent += f_len;
5583 }
while ((l_iter = l_iter->
next) != l_first);
5586 ratio_adjust = ratio;
5587 ratio_adjust = 1.0f - ratio_adjust;
5588 ratio_adjust *= (
float)totface_adjacent / (
float)totface_basis;
5589 ratio_adjust = 1.0f - ratio_adjust;
5593 em->
bm, ratio_adjust, vweights, vertex_group_factor,
false, symmetry_axis, symmetry_eps);
5636 uiItemR(row, &
ptr,
"use_symmetry", 0,
"", ICON_NONE);
5645 ot->
name =
"Decimate Geometry";
5665 "Use active vertex group as an influence");
5667 "vertex_group_factor",
5672 "Vertex group strength",
5676 ot->
srna,
"invert_vertex_group",
false,
"Invert",
"Invert vertex group influence");
5694 ot->
srna,
"use_verts", value,
"Dissolve Vertices",
"Dissolve remaining vertices");
5706 "Split off face corners to maintain surrounding geometry");
5711 "use_boundary_tear",
5714 "Split off face corners instead of merging faces");
5723 uint objects_len = 0;
5727 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
5728 Object *obedit = objects[ob_index];
5739 "dissolve_verts verts=%hv use_face_split=%b use_boundary_tear=%b",
5742 use_boundary_tear)) {
5758 ot->
name =
"Dissolve Vertices";
5759 ot->
description =
"Dissolve vertices, merge edges and faces";
5760 ot->
idname =
"MESH_OT_dissolve_verts";
5785 uint objects_len = 0;
5788 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
5789 Object *obedit = objects[ob_index];
5800 "dissolve_edges edges=%he use_verts=%b use_face_split=%b",
5820 ot->
name =
"Dissolve Edges";
5822 ot->
idname =
"MESH_OT_dissolve_edges";
5845 uint objects_len = 0;
5848 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
5849 Object *obedit = objects[ob_index];
5862 "dissolve_faces faces=%hf use_verts=%b",
5880 ot->
name =
"Dissolve Faces";
5882 ot->
idname =
"MESH_OT_dissolve_faces";
5926 ot->
name =
"Dissolve Selection";
5927 ot->
description =
"Dissolve geometry based on the selection mode";
5928 ot->
idname =
"MESH_OT_dissolve_mode";
5951 const bool use_dissolve_boundaries =
RNA_boolean_get(op->
ptr,
"use_dissolve_boundaries");
5956 uint objects_len = 0;
5959 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
5960 Object *obedit = objects[ob_index];
6006 "dissolve_limit edges=%he verts=%hv angle_limit=%f use_dissolve_boundaries=%b delimit=%i",
6010 use_dissolve_boundaries,
6027 ot->
name =
"Limited Dissolve";
6028 ot->
idname =
"MESH_OT_dissolve_limited";
6030 "Dissolve selected edges and vertices, limited by the angle of surrounding geometry";
6051 "use_dissolve_boundaries",
6054 "Dissolve all vertices in between face boundaries");
6060 "Delimit dissolve operation");
6072 int totelem_old[3] = {0, 0, 0};
6073 int totelem_new[3] = {0, 0, 0};
6075 uint objects_len = 0;
6079 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
6080 Object *obedit = objects[ob_index];
6090 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
6091 Object *obedit = objects[ob_index];
6118 ot->
name =
"Degenerate Dissolve";
6119 ot->
idname =
"MESH_OT_dissolve_degenerate";
6120 ot->
description =
"Dissolve zero area faces and zero length edges";
6135 "Maximum distance between elements to merge",
6152 uint objects_len = 0;
6155 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
6156 Object *obedit = objects[ob_index];
6182 "dissolve_edges edges=%he use_verts=%b use_face_split=%b",
6203 ot->
name =
"Delete Edge Loop";
6204 ot->
description =
"Delete an edge loop by merging the faces on each side";
6205 ot->
idname =
"MESH_OT_delete_edgeloop";
6218 "Split off face corners to maintain surrounding geometry");
6230 uint objects_len = 0;
6233 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
6234 Object *obedit = objects[ob_index];
6269 ot->
description =
"Split off selected geometry from connected unselected geometry";
6317 return (x1->
srt >
x2->srt) - (x1->
srt <
x2->srt);
6343 int totelem[3] = {0, 0, 0};
6344 int affected[3] = {0, 0, 0};
6347 if (!(
types && flag && action)) {
6363 float fact = reverse ? -1.0 : 1.0;
6370 pb = pblock[0] =
MEM_callocN(
sizeof(
char) * totelem[0],
"sort_bmelem vert pblock");
6379 sb[affected[0]].org_idx = i;
6380 sb[affected[0]++].srt = co[coidx] * fact;
6389 pb = pblock[1] =
MEM_callocN(
sizeof(
char) * totelem[1],
"sort_bmelem edge pblock");
6399 sb[affected[1]].org_idx = i;
6400 sb[affected[1]++].srt = co[coidx] * fact;
6409 pb = pblock[2] =
MEM_callocN(
sizeof(
char) * totelem[2],
"sort_bmelem face pblock");
6419 sb[affected[2]].org_idx = i;
6420 sb[affected[2]++].srt = co[coidx] * fact;
6432 float fact = reverse ? -1.0 : 1.0;
6440 pb = pblock[0] =
MEM_callocN(
sizeof(
char) * totelem[0],
"sort_bmelem vert pblock");
6446 sb[affected[0]].org_idx = i;
6456 pb = pblock[1] =
MEM_callocN(
sizeof(
char) * totelem[1],
"sort_bmelem edge pblock");
6465 sb[affected[1]].org_idx = i;
6475 pb = pblock[2] =
MEM_callocN(
sizeof(
char) * totelem[2],
"sort_bmelem face pblock");
6484 sb[affected[2]].org_idx = i;
6496 pb = pblock[2] =
MEM_callocN(
sizeof(
char) * totelem[2],
"sort_bmelem face pblock");
6505 sb[affected[2]].org_idx = i;
6508 sb[affected[2]++].srt = srt * ((
float)totelem[2]) + ((
float)i);
6522 tb = tbuf[0] =
MEM_callocN(
sizeof(
int) * totelem[0],
"sort_bmelem vert tbuf");
6523 mp = map[0] =
MEM_callocN(
sizeof(
int) * totelem[0],
"sort_bmelem vert map");
6527 mp[affected[0]++] = i;
6537 tb = tbuf[1] =
MEM_callocN(
sizeof(
int) * totelem[1],
"sort_bmelem edge tbuf");
6538 mp = map[1] =
MEM_callocN(
sizeof(
int) * totelem[1],
"sort_bmelem edge map");
6542 mp[affected[1]++] = i;
6552 tb = tbuf[2] =
MEM_callocN(
sizeof(
int) * totelem[2],
"sort_bmelem face tbuf");
6553 mp = map[2] =
MEM_callocN(
sizeof(
int) * totelem[2],
"sort_bmelem face map");
6557 mp[affected[2]++] = i;
6567 int tot = totelem[j];
6568 int aff = affected[j];
6574 if (
ELEM(aff, 0, tot)) {
6581 memcpy(tb + (tot - aff), mp, aff *
sizeof(
int));
6584 memcpy(mp + aff, tb, (tot - aff) *
sizeof(
int));
6586 mp = map[j] = tbuf[j];
6591 for (i = tot, tb = tbuf[j] + tot - 1; i--; tb--) {
6603 pb = pblock[0] =
MEM_callocN(
sizeof(
char) * totelem[0],
"sort_bmelem vert pblock");
6609 sb[affected[0]].org_idx = i;
6622 pb = pblock[1] =
MEM_callocN(
sizeof(
char) * totelem[1],
"sort_bmelem edge pblock");
6628 sb[affected[1]].org_idx = i;
6641 pb = pblock[2] =
MEM_callocN(
sizeof(
char) * totelem[2],
"sort_bmelem face pblock");
6647 sb[affected[2]].org_idx = i;
6661 pb = pblock[0] =
MEM_callocN(
sizeof(
char) * totelem[0],
"sort_bmelem vert pblock");
6667 sb[affected[0]].org_idx = i;
6668 sb[affected[0]++].srt = (
float)-i;
6677 pb = pblock[1] =
MEM_callocN(
sizeof(
char) * totelem[1],
"sort_bmelem edge pblock");
6683 sb[affected[1]].org_idx = i;
6684 sb[affected[1]++].srt = (
float)-i;
6693 pb = pblock[2] =
MEM_callocN(
sizeof(
char) * totelem[2],
"sort_bmelem face pblock");
6699 sb[affected[2]].org_idx = i;
6700 sb[affected[2]++].srt = (
float)-i;
6712 if (affected[0] == 0 && affected[1] == 0 && affected[2] == 0) {
6731 if (pb && sb && !map[j]) {
6734 int tot = totelem[j];
6735 int aff = affected[j];
6739 mp = map[j] =
MEM_mallocN(
sizeof(
int) * tot,
"sort_bmelem map");
6740 p_blk = pb + tot - 1;
6741 s_blk = sb + aff - 1;
6742 for (i = tot; i--; p_blk--) {
6811 uint objects_len = 0;
6815 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
6816 Object *ob = objects[ob_index];
6826 int seed_iter =
seed;
6848 if (
STREQ(prop_id,
"seed")) {
6856 if (
STREQ(prop_id,
"reverse")) {
6873 "Sort selected elements from farthest to nearest one in current view"},
6878 "Sort selected elements from left to right one in current view"},
6883 "Sort selected elements from nearest to farthest from 3D cursor"},
6888 "Sort selected faces from smallest to greatest material index"},
6893 "Move all selected elements in first places, preserving their relative order.\n"
6894 "Warning: This will affect unselected elements' indices as well"},
6895 {
SRT_RANDOMIZE,
"RANDOMIZE", 0,
"Randomize",
"Randomize order of selected elements"},
6896 {
SRT_REVERSE,
"REVERSE", 0,
"Reverse",
"Reverse current order of selected elements"},
6901 {
BM_VERT,
"VERT", 0,
"Vertices",
""},
6902 {
BM_EDGE,
"EDGE", 0,
"Edges",
""},
6903 {
BM_FACE,
"FACE", 0,
"Faces",
""},
6908 ot->
name =
"Sort Mesh Elements";
6910 "The order of selected vertices/edges/faces is modified, based on a given method";
6911 ot->
idname =
"MESH_OT_sort_elements";
6928 "Type of reordering operation to apply");
6934 "Which elements to affect (vertices, edges and/or faces)");
6936 RNA_def_int(
ot->
srna,
"seed", 0, 0, INT_MAX,
"Seed",
"Seed for random-based operations", 0, 255);
6957 int totface_del = 0;
6968 bool is_all_sel =
true;
6983 if (is_all_sel ==
false) {
6996 const bool use_pairs,
6997 const bool use_cyclic,
6998 const bool use_merge,
6999 const float merge_factor,
7000 const int twist_offset)
7004 int totface_del = 0;
7014 totface_del_arr =
MEM_mallocN(
sizeof(*totface_del_arr) * totface_del, __func__);
7019 totface_del_arr[i++] = f;
7031 "bridge_loops edges=%he use_pairs=%b use_cyclic=%b use_merge=%b merge_factor=%f "
7040 if (use_faces && totface_del) {
7043 for (i = 0; i < totface_del; i++) {
7048 "delete geom=%hf context=%i",
7057 if (use_merge ==
false) {
7063 if (use_merge ==
false) {
7067 if (op_props.
cuts) {
7075 "subdivide_edgering edges=%S interp_mode=%i cuts=%i smooth=%f "
7076 "profile_shape=%i profile_shape_factor=%f",
7092 if (totface_del_arr) {
7114 uint objects_len = 0;
7117 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
7118 Object *obedit = objects[ob_index];
7126 op, em, obedit->
data, use_pairs, use_cyclic, use_merge, merge_factor, twist_offset);
7142 ot->
name =
"Bridge Edge Loops";
7143 ot->
description =
"Create a bridge of faces between two or more selected edge loops";
7144 ot->
idname =
"MESH_OT_bridge_edge_loops";
7158 "Method of bridging multiple loops");
7161 RNA_def_float(
ot->
srna,
"merge_factor", 0.5f, 0.0f, 1.0f,
"Merge Factor",
"", 0.0f, 1.0f);
7168 "Twist offset for closed loops",
7193 uint objects_len = 0;
7196 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
7197 Object *obedit = objects[ob_index];
7209 "wireframe faces=%hf use_replace=%b use_boundary=%b use_even_offset=%b "
7210 "use_relative_offset=%b "
7211 "use_crease=%b crease_weight=%f thickness=%f offset=%f",
7216 use_relative_offset,
7262 "Scale the offset to give more even thickness");
7264 "use_relative_offset",
7267 "Scale the offset by surrounding geometry");
7270 ot->
srna,
"thickness", 0.01f, 0.0f, 1e4f,
"Thickness",
"", 0.0f, 10.0f);
7278 "Crease hub edges for an improved subdivision surface");
7280 ot->
srna,
"crease_weight", 0.01f, 0.0f, 1e3f,
"Crease Weight",
"", 0.0f, 1.0f);
7293 bool changed_multi =
false;
7299 for (
uint base_index = 0; base_index < bases_len; base_index++) {
7311 "offset_edgeloops edges=%he use_cap_endpoint=%b",
7324 changed_multi =
true;
7328 if (changed_multi) {
7347 ot->
name =
"Offset Edge Loop";
7348 ot->
idname =
"MESH_OT_offset_edge_loops";
7349 ot->
description =
"Create offset edge loop from the current selection";
7362 ot->
srna,
"use_cap_endpoint",
false,
"Cap Endpoint",
"Extend loop around end-points");
7383 uint objects_len = 0;
7386 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
7387 Object *obedit = objects[ob_index];
7399 "convex_hull input=%hvef "
7400 "use_existing_faces=%b",
7402 use_existing_faces);
7415 if (delete_unused) {
7417 em, op,
"delete geom=%S context=%i", &bmop,
"geom_unused.out",
DEL_ONLYTAGGED)) {
7426 em, op,
"delete geom=%S context=%i", &bmop,
"geom_holes.out",
DEL_ONLYTAGGED)) {
7433 if (join_triangles) {
7438 "join_triangles faces=%S "
7439 "angle_face_threshold=%f angle_shape_threshold=%f",
7442 angle_face_threshold,
7443 angle_shape_threshold)) {
7464 ot->
name =
"Convex Hull";
7465 ot->
description =
"Enclose selected vertices in a convex polyhedron";
7466 ot->
idname =
"MESH_OT_convex_hull";
7469 ot->
exec = edbm_convex_hull_exec;
7480 "Delete selected elements that are not used by the hull");
7483 "use_existing_faces",
7485 "Use Existing Faces",
7486 "Skip hull triangles that are covered by a pre-existing face");
7492 "Delete selected faces that are used by the hull");
7495 ot->
srna,
"join_triangles",
true,
"Join Triangles",
"Merge adjacent triangles into quads");
7511 uint objects_len = 0;
7515 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
7516 Object *obedit = objects[ob_index];
7527 "symmetrize input=%hvef direction=%i dist=%f",
7553 ot->
description =
"Enforce symmetry (both form and topological) across an axis";
7568 "Which sides to copy from and to");
7575 "Limit for snap middle vertices to the axis center",
7588 const float eps = 0.00001f;
7589 const float eps_sq =
eps *
eps;
7590 const bool use_topology =
false;
7598 int totvertfound = 0, totvertmirr = 0, totvertfail = 0;
7601 int axis = axis_dir % 3;
7602 bool axis_sign = axis != axis_dir;
7605 uint objects_len = 0;
7609 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
7610 Object *obedit = objects[ob_index];
7635 int i_mirr = index[i];
7641 float co[3], co_mirr[3];
7643 if ((
v->
co[axis] > v_mirr->
co[axis]) == axis_sign) {
7648 co_mirr[axis] *= -1.0f;
7693 "%d already symmetrical, %d pairs mirrored, %d failed",
7694 totvertfound - totvertmirr,
7701 "%d already symmetrical, %d pairs mirrored",
7702 totvertfound - totvertmirr,
7712 ot->
name =
"Snap to Symmetry";
7713 ot->
description =
"Snap vertex pairs to their mirrored locations";
7714 ot->
idname =
"MESH_OT_symmetry_snap";
7728 "Which sides to copy from and to");
7735 "Distance within which matching vertices are searched",
7744 "Mix factor of the locations of the vertices",
7748 ot->
srna,
"use_center",
true,
"Center",
"Snap middle vertices to the axis center");
7753 #if defined(WITH_FREESTYLE)
7767 uint objects_len = 0;
7770 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
7771 Object *obedit = objects[ob_index];
7818 ot->
name =
"Mark Freestyle Edge";
7819 ot->
description =
"(Un)mark selected edges as Freestyle feature edges";
7820 ot->
idname =
"MESH_OT_mark_freestyle_edge";
7823 ot->
exec = edbm_mark_freestyle_edge_exec;
7847 uint objects_len = 0;
7850 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
7851 Object *obedit = objects[ob_index];
7896 ot->
name =
"Mark Freestyle Face";
7897 ot->
description =
"(Un)mark selected faces for exclusion from Freestyle feature edge detection";
7898 ot->
idname =
"MESH_OT_mark_freestyle_face";
7901 ot->
exec = edbm_mark_freestyle_face_exec;
7953 "Toggle inversion of affected normals"},
7958 "Interpolate between new and original normals"},
7965 "Follow mouse cursor position"},
7970 "Use current rotation/scaling pivot point coordinates"},
7975 "Use current edited object's location"},
7979 "Set and Use 3D Cursor",
7980 "Set new 3D cursor position and use it"},
7984 "Select and Use Mesh Item",
7985 "Select new active mesh element and use its location"},
7988 static const char *keymap_name =
"Custom Normals Modal Map";
8004 #define CLNORS_VALID_VEC_LEN (1e-4f)
8022 "Use static coordinates (defined by various means)"},
8040 return (lnors_ed_arr->
totloop != 0);
8072 int available_len =
sizeof(buf);
8074 #define WM_MODALKEY(_id) \
8075 WM_modalkeymap_operator_items_to_string_buf( \
8076 op->type, (_id), true, UI_MAX_SHORTCUT_STR, &available_len, &p)
8080 TIP_(
"%s: confirm, %s: cancel, "
8081 "%s: point to mouse (%s), %s: point to Pivot, "
8082 "%s: point to object origin, %s: reset normals, "
8083 "%s: set & point to 3D cursor, %s: select & point to mesh item, "
8084 "%s: invert normals (%s), %s: spherize (%s), %s: align (%s)"),
8134 if (do_align && !do_reset) {
8141 for (
int i = 0; i < lnors_ed_arr->
totloop; i++, lnor_ed++) {
8145 else if (do_spherize) {
8149 float spherized_normal[3];
8160 else if (do_align) {
8167 if (do_invert && !do_reset) {
8196 int new_mode = mode;
8197 bool force_mousemove =
false;
8198 bool do_reset =
false;
8203 switch (event->
val) {
8249 force_mousemove =
true;
8333 if (new_mode != mode) {
8429 if (
STREQ(prop_id,
"spherize_strength")) {
8454 ot->
name =
"Point Normals to Target";
8455 ot->
description =
"Point selected custom normals to specified Target";
8456 ot->
idname =
"MESH_OT_point_normals";
8474 "How to define coordinates to point custom normals to");
8488 "Target location to which normals will point",
8493 ot->
srna,
"spherize",
false,
"Spherize",
"Interpolate between original and new normals");
8496 "spherize_strength",
8500 "Spherize Strength",
8501 "Ratio of spherized normal to original normal",
8522 for (
int i = 0; i < lnors_ed_arr->
totloop; i++, lnor_ed++) {
8533 float avg_normal[3] = {0.0f, 0.0f, 0.0f};
8536 for (; loops; loops = loops->
next) {
8589 const BMEdge *e_org = l_curr->
e;
8590 BMLoop *lfan_pivot, *lfan_pivot_next;
8592 lfan_pivot = l_curr;
8593 e_next = lfan_pivot->
e;
8594 float avg_normal[3] = {0.0f};
8598 if (lfan_pivot_next) {
8602 e_next = (lfan_pivot->
e == e_next) ? lfan_pivot->
prev->
e : lfan_pivot->
e;
8611 lfan_pivot = lfan_pivot_next;
8625 }
while ((l_curr = l_curr->
next) != l_first);
8632 uint objects_len = 0;
8636 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
8637 Object *obedit = objects[ob_index];
8690 ot->
name =
"Merge Normals";
8691 ot->
description =
"Merge custom normals of selected vertices";
8692 ot->
idname =
"MESH_OT_merge_normals";
8710 ot->
name =
"Split Normals";
8711 ot->
description =
"Split custom normals of selected vertices";
8712 ot->
idname =
"MESH_OT_split_normals";
8739 "Take average of vertex normals"},
8744 "Set all vertex normals by face area"},
8749 "Set all vertex normals by corner angle"},
8756 uint objects_len = 0;
8766 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
8770 Object *obedit = objects[ob_index];
8783 float weight = absweight / 50.0f;
8784 if (absweight == 100.0f) {
8785 weight = (
float)SHRT_MAX;
8787 else if (absweight == 1.0f) {
8788 weight = 1 / (
float)SHRT_MAX;
8790 else if ((weight - 1) * 25 > 1) {
8791 weight = (weight - 1) * 25;
8814 const BMEdge *e_org = l_curr->
e;
8815 BMLoop *lfan_pivot, *lfan_pivot_next;
8817 lfan_pivot = l_curr;
8818 e_next = lfan_pivot->
e;
8822 if (lfan_pivot_next) {
8826 e_next = (lfan_pivot->
e == e_next) ? lfan_pivot->
prev->
e : lfan_pivot->
e;
8842 lfan_pivot = lfan_pivot_next;
8845 float wnor[3], avg_normal[3] = {0.0f},
count = 0;
8857 const float n_weight =
pow(weight,
count);
8868 mul_v3_fl(wnor, (1.0f / cur_val) * (1.0f / n_weight));
8884 }
while ((l_curr = l_curr->
next) != l_first);
8904 if (
STREQ(prop_id,
"weight")) {
8907 if (
STREQ(prop_id,
"threshold")) {
8932 ot->
name =
"Average Normals";
8933 ot->
description =
"Average custom normals of selected vertices";
8934 ot->
idname =
"MESH_OT_average_normals";
8949 "Averaging method");
8951 RNA_def_int(
ot->
srna,
"weight", 50, 1, 100,
"Weight",
"Weight applied per face", 1, 100);
8959 "Threshold value for different weights to be considered equal",
8986 "Multiply normal vector with selection"},
8991 "Reset buffer and/or normal of selected element"},
8999 uint objects_len = 0;
9005 bool done_copy =
false;
9007 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
9008 Object *obedit = objects[ob_index];
9032 "Can only copy one custom normal, vertex normal or face normal");
9036 if (lnors_ed_arr->
totloop == 1) {
9051 bool are_same_lnors =
true;
9052 for (
int i = 0; i < lnors_ed_arr->
totloop; i++, lnor_ed++) {
9054 are_same_lnors =
false;
9057 if (are_same_lnors) {
9071 for (
int i = 0; i < lnors_ed_arr->
totloop; i++, lnor_ed++) {
9073 float abs_normal[3];
9095 for (
int i = 0; i < lnors_ed_arr->
totloop; i++, lnor_ed++) {
9109 for (
int i = 0; i < lnors_ed_arr->
totloop; i++, lnor_ed++) {
9124 for (
int i = 0; i < lnors_ed_arr->
totloop; i++, lnor_ed++) {
9153 if (
STREQ(prop_id,
"absolute")) {
9176 ot->
name =
"Normals Vector Tools";
9177 ot->
description =
"Custom normals tools using Normal Vector of UI";
9178 ot->
idname =
"MESH_OT_normals_tools";
9193 "Mode of tools taking input from interface");
9199 "Absolute Coordinates",
9200 "Copy Absolute coordinates or Normal vector");
9212 uint objects_len = 0;
9216 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
9217 Object *obedit = objects[ob_index];
9224 BMIter fiter, viter, eiter, liter;
9268 for (; loops; loops = loops->
next) {
9302 ot->
name =
"Set Normals from Faces";
9303 ot->
description =
"Set the custom normals from the selected faces ones";
9304 ot->
idname =
"MESH_OT_set_normals_from_faces";
9325 uint objects_len = 0;
9329 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
9330 Object *obedit = objects[ob_index];
9352 for (
int i = 0; i < lnors_ed_arr->
totloop; i++, lnor_ed++) {
9354 float loop_normal[3];
9363 add_v3_v3(smooth_normal[i], loop_normal);
9371 for (
int i = 0; i < lnors_ed_arr->
totloop; i++, lnor_ed++) {
9372 float current_normal[3];
9384 mul_v3_fl(current_normal, 1.0f - factor);
9386 add_v3_v3(current_normal, smooth_normal[i]);
9410 ot->
name =
"Smooth Normals Vectors";
9411 ot->
description =
"Smooth custom normals based on adjacent vertex normals";
9412 ot->
idname =
"MESH_OT_smooth_normals";
9427 "Specifies weight of smooth vs original normal",
9441 uint objects_len = 0;
9445 for (
uint ob_index = 0; ob_index < objects_len; ob_index++) {
9446 Object *obedit = objects[ob_index];
9458 if (cd_prop_int_index == -1) {
9472 *strength = face_strength;
9479 if (*strength == face_strength) {
9506 ot->
name =
"Face Normals Strength";
9507 ot->
description =
"Set/Get strength of face (used in Weighted Normal modifier)";
9508 ot->
idname =
"MESH_OT_mod_weighted_strength";
9525 "Strength to use for assigning or selecting face influence for weighted normal modifier");
typedef float(TangentPoint)[2]
struct ScrArea * CTX_wm_area(const bContext *C)
struct Scene * CTX_data_scene(const bContext *C)
struct Object * CTX_data_edit_object(const bContext *C)
struct wmWindowManager * CTX_wm_manager(const bContext *C)
#define CTX_DATA_BEGIN(C, Type, instance, member)
struct ViewLayer * CTX_data_view_layer(const bContext *C)
struct View3D * CTX_wm_view3d(const bContext *C)
struct ARegion * CTX_wm_region(const bContext *C)
struct Main * CTX_data_main(const bContext *C)
int CustomData_number_of_layers(const struct CustomData *data, int type)
bool CustomData_has_layer(const struct CustomData *data, int type)
int CustomData_get_named_layer_index(const struct CustomData *data, int type, const char *name)
int CustomData_get_layer_index(const struct CustomData *data, int type)
void * CustomData_bmesh_get(const struct CustomData *data, void *block, int type)
int CustomData_get_n_offset(const struct CustomData *data, int type, int n)
int CustomData_get_offset(const struct CustomData *data, int type)
void * CustomData_bmesh_get_n(const struct CustomData *data, void *block, int type, int n)
void BKE_editmesh_lnorspace_update(BMEditMesh *em, struct Mesh *me)
void BKE_editmesh_ensure_autosmooth(BMEditMesh *em, struct Mesh *me)
BMEditMesh * BKE_editmesh_from_object(struct Object *ob)
Return the BMEditMesh for a given object.
struct KeyBlock * BKE_keyblock_find_name(struct Key *key, const char name[])
#define BKE_view_layer_array_from_objects_in_edit_mode(view_layer, v3d, r_len)
#define BKE_view_layer_array_from_objects_in_edit_mode_unique_data(view_layer, v3d, r_len)
#define BKE_view_layer_array_from_bases_in_edit_mode_unique_data(view_layer, v3d, r_len)
void id_us_plus(struct ID *id)
General operations, lookup, etc. for materials.
struct Material *** BKE_object_material_array_p(struct Object *ob)
void BKE_object_material_resize(struct Main *bmain, struct Object *ob, const short totcol, bool do_id_user)
struct Material *** BKE_id_material_array_p(struct ID *id)
short * BKE_id_material_len_p(struct ID *id)
void BKE_id_material_clear(struct Main *bmain, struct ID *id)
short * BKE_object_material_len_p(struct Object *ob)
void BKE_id_material_resize(struct Main *bmain, struct ID *id, short totcol, bool do_id_user)
void BKE_object_material_array_assign(struct Main *bmain, struct Object *ob, struct Material ***matar, int totcol, const bool to_object_only)
@ MLNOR_SPACEARR_BMLOOP_PTR
void BKE_lnor_space_custom_data_to_normal(MLoopNorSpace *lnor_space, const short clnor_data[2], float r_custom_lnor[3])
void BKE_lnor_space_custom_normal_to_data(MLoopNorSpace *lnor_space, const float custom_lnor[3], short r_clnor_data[2])
void BKE_report(ReportList *reports, ReportType type, const char *message)
void BKE_reportf(ReportList *reports, ReportType type, const char *format,...) ATTR_PRINTF_FORMAT(3
#define BLI_BITMAP_TEST(_bitmap, _index)
#define BLI_BITMAP_ENABLE(_bitmap, _index)
#define BLI_BITMAP_NEW(_tot, _alloc_string)
unsigned int BLI_ghashutil_strhash_p(const void *ptr)
A min-heap / priority queue ADT.
void BLI_heapsimple_free(HeapSimple *heap, HeapSimpleFreeFP ptrfreefp) ATTR_NONNULL(1)
HeapSimple * BLI_heapsimple_new(void) ATTR_WARN_UNUSED_RESULT
float BLI_heapsimple_top_value(const HeapSimple *heap) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
void * BLI_heapsimple_pop_min(HeapSimple *heap) ATTR_NONNULL(1)
bool BLI_heapsimple_is_empty(const HeapSimple *heap) ATTR_NONNULL(1)
void BLI_heapsimple_insert(HeapSimple *heap, float value, void *ptr) ATTR_NONNULL(1)
BLI_LINKSTACK_*** wrapper macros for using a LinkNode to store a stack of pointers,...
#define BLI_SMALLSTACK_DECLARE(var, type)
#define BLI_SMALLSTACK_POP(var)
#define BLI_SMALLSTACK_PUSH(var, data)
#define BLI_SMALLSTACK_IS_EMPTY(var)
BLI_INLINE bool BLI_listbase_is_empty(const struct ListBase *lb)
#define LISTBASE_FOREACH(type, var, list)
void BLI_listbase_rotate_first(struct ListBase *lb, void *vlink) ATTR_NONNULL(1
int BLI_listbase_count_at_most(const struct ListBase *listbase, const int count_max) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
int BLI_findindex(const struct ListBase *listbase, const void *vlink) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
void * BLI_findlink(const struct ListBase *listbase, int number) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
void * BLI_findptr(const struct ListBase *listbase, const void *ptr, const int offset) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
MINLINE float max_ff(float a, float b)
MINLINE int min_ii(int a, int b)
MINLINE int compare_ff(float a, float b, const float max_diff)
MINLINE float min_ff(float a, float b)
MINLINE int mod_i(int i, int n)
int is_quad_flip_v3(const float v1[3], const float v2[3], const float v3[3], const float v4[3])
void mul_m4_m4m4(float R[4][4], const float A[4][4], const float B[4][4])
bool invert_m4_m4(float R[4][4], const float A[4][4])
void mul_m4_v3(const float M[4][4], float r[3])
void mul_v3_m4v3(float r[3], const float M[4][4], const float v[3])
void interp_v3_v3v3(float r[3], const float a[3], const float b[3], const float t)
void minmax_v3v3_v3(float min[3], float max[3], const float vec[3])
MINLINE void madd_v3_v3fl(float r[3], const float a[3], float f)
MINLINE bool compare_v3v3(const float a[3], const float b[3], const float limit) ATTR_WARN_UNUSED_RESULT
MINLINE float normalize_v3(float r[3])
MINLINE void mul_v3_v3(float r[3], const float a[3])
MINLINE void sub_v3_v3(float r[3], const float a[3])
MINLINE float len_squared_v3v3(const float a[3], const float b[3]) ATTR_WARN_UNUSED_RESULT
MINLINE void sub_v3_v3v3(float r[3], const float a[3], const float b[3])
MINLINE void mul_v3_fl(float r[3], float f)
MINLINE void copy_v3_v3(float r[3], const float a[3])
MINLINE bool is_zero_v3(const float a[3]) ATTR_WARN_UNUSED_RESULT
MINLINE void negate_v3(float r[3])
void mid_v3_v3v3(float r[3], const float a[3], const float b[3])
MINLINE void zero_v3(float r[3])
float angle_v3v3v3(const float a[3], const float b[3], const float c[3]) ATTR_WARN_UNUSED_RESULT
MINLINE void mul_v3_v3fl(float r[3], const float a[3], float f)
MINLINE void add_v3_v3(float r[3], const float a[3])
MINLINE void copy_v2_fl(float r[2], float f)
void BLI_rng_free(struct RNG *rng) ATTR_NONNULL(1)
struct RNG * BLI_rng_new_srandom(unsigned int seed)
float BLI_rng_get_float(struct RNG *rng) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
int BLI_sortutil_cmp_float_reverse(const void *a_, const void *b_)
size_t BLI_snprintf(char *__restrict dst, size_t maxncpy, const char *__restrict format,...) ATTR_NONNULL(1
#define UNUSED_VARS_NDEBUG(...)
#define BLT_I18NCONTEXT_ID_CURVE
void DEG_id_tag_update(struct ID *id, int flag)
void DEG_relations_tag_update(struct Main *bmain)
#define ID_IS_LINKED(_id)
@ MOD_TRIANGULATE_QUAD_BEAUTY
@ MOD_TRIANGULATE_NGON_BEAUTY
#define MOD_WEIGHTEDNORMALS_FACEWEIGHT_CDLAYER_ID
Object is a sort of wrapper for general info.
#define SCE_SELECT_VERTEX
@ V3D_AROUND_CENTER_BOUNDS
@ V3D_AROUND_CENTER_MEDIAN
@ OP_IS_MODAL_GRAB_CURSOR
void EDBM_verts_mirror_apply(struct BMEditMesh *em, const int sel_from, const int sel_to)
void EDBM_selectmode_flush_ex(struct BMEditMesh *em, const short selectmode)
void ED_mesh_geometry_clear(struct Mesh *mesh)
bool EDBM_selectmode_disable_multi_ex(struct Scene *scene, struct Base **bases, const uint bases_len, const short selectmode_disable, const short selectmode_fallback)
bool EDBM_mesh_hide(struct BMEditMesh *em, bool swap)
void EDBM_automerge(struct Object *ob, bool update, const char hflag, const float dist)
void EDBM_select_flush(struct BMEditMesh *em)
void EDBM_verts_mirror_cache_end(struct BMEditMesh *em)
void EDBM_update_generic(struct Mesh *me, const bool do_tessellation, const bool is_destructive)
void EDBM_verts_mirror_cache_begin_ex(struct BMEditMesh *em, const int axis, const bool use_self, const bool use_select, const bool respecthide, const bool use_topology, float maxdist, int *r_index)
void EDBM_verts_mirror_cache_begin(struct BMEditMesh *em, const int axis, const bool use_self, const bool use_select, const bool respecthide, const bool use_topology)
bool EDBM_mesh_reveal(struct BMEditMesh *em, bool select)
void EDBM_flag_disable_all(struct BMEditMesh *em, const char hflag)
bool EDBM_select_pick(struct bContext *C, const int mval[2], bool extend, bool deselect, bool toggle)
void EDBM_selectmode_flush(struct BMEditMesh *em)
void EDBM_mesh_normals_update(struct BMEditMesh *em)
void EDBM_mesh_stats_multi(struct Object **objects, const uint objects_len, int totelem[3], int totelem_sel[3])
void ED_object_base_select(struct Base *base, eObjectSelect_Mode mode)
struct Base * ED_object_add_duplicate(struct Main *bmain, struct Scene *scene, struct ViewLayer *view_layer, struct Base *base, const eDupli_ID_Flags dupflag)
bool ED_object_calc_active_center_for_editmode(struct Object *obedit, const bool select_only, float r_center[3])
void ED_outliner_select_sync_from_object_tag(struct bContext *C)
void ED_area_status_text(ScrArea *area, const char *str)
bool ED_operator_editmesh(struct bContext *C)
bool ED_operator_scene_editable(struct bContext *C)
void ED_uvedit_live_unwrap(const struct Scene *scene, struct Object **objects, int objects_len)
void ED_view3d_init_mats_rv3d(struct Object *ob, struct RegionView3D *rv3d)
@ V3D_PROJ_TEST_CLIP_NEAR
void ED_view3d_win_to_3d_int(const struct View3D *v3d, const struct ARegion *region, const float depth_pt[3], const int mval[2], float r_out[3])
eV3DProjStatus ED_view3d_project_float_object(const struct ARegion *region, const float co[3], float r_co[2], const eV3DProjTest flag)
void ED_view3d_cursor3d_update(struct bContext *C, const int mval[2], const bool use_depth, enum eV3DCursorOrient orientation)
void view3d_operator_needs_opengl(const struct bContext *C)
struct RegionView3D * ED_view3d_context_rv3d(struct bContext *C)
NSNotificationCenter * center
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum const void *lists _GL_VOID_RET _GL_VOID const GLdouble *equation _GL_VOID_RET _GL_VOID GLdouble GLdouble blue _GL_VOID_RET _GL_VOID GLfloat GLfloat blue _GL_VOID_RET _GL_VOID GLint GLint blue _GL_VOID_RET _GL_VOID GLshort GLshort blue _GL_VOID_RET _GL_VOID GLubyte GLubyte blue _GL_VOID_RET _GL_VOID GLuint GLuint blue _GL_VOID_RET _GL_VOID GLushort GLushort blue _GL_VOID_RET _GL_VOID GLbyte GLbyte GLbyte alpha _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble alpha _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat alpha _GL_VOID_RET _GL_VOID GLint GLint GLint alpha _GL_VOID_RET _GL_VOID GLshort GLshort GLshort alpha _GL_VOID_RET _GL_VOID GLubyte GLubyte GLubyte alpha _GL_VOID_RET _GL_VOID GLuint GLuint GLuint alpha _GL_VOID_RET _GL_VOID GLushort GLushort GLushort alpha _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLint GLsizei GLsizei GLenum type _GL_VOID_RET _GL_VOID GLsizei GLenum GLenum const void *pixels _GL_VOID_RET _GL_VOID const void *pointer _GL_VOID_RET _GL_VOID GLdouble v _GL_VOID_RET _GL_VOID GLfloat v _GL_VOID_RET _GL_VOID GLint GLint i2 _GL_VOID_RET _GL_VOID GLint j _GL_VOID_RET _GL_VOID GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble GLdouble GLdouble zFar _GL_VOID_RET _GL_UINT GLdouble *equation _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLenum GLfloat *v _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLfloat *values _GL_VOID_RET _GL_VOID GLushort *values _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLenum GLdouble *params _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_BOOL GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLenum GLfloat param _GL_VOID_RET _GL_VOID GLenum GLint param _GL_VOID_RET _GL_VOID GLushort pattern _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint const GLdouble *points _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint GLdouble GLdouble GLint GLint const GLdouble *points _GL_VOID_RET _GL_VOID GLdouble GLdouble u2 _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLdouble GLdouble v2 _GL_VOID_RET _GL_VOID GLenum GLfloat param _GL_VOID_RET _GL_VOID GLenum GLint param _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLdouble GLdouble nz _GL_VOID_RET _GL_VOID GLfloat GLfloat nz _GL_VOID_RET _GL_VOID GLint GLint nz _GL_VOID_RET _GL_VOID GLshort GLshort nz _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_VOID GLsizei const GLfloat *values _GL_VOID_RET _GL_VOID GLsizei const GLushort *values _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID const GLuint const GLclampf *priorities _GL_VOID_RET _GL_VOID GLdouble y _GL_VOID_RET _GL_VOID GLfloat y _GL_VOID_RET _GL_VOID GLint y _GL_VOID_RET _GL_VOID GLshort y _GL_VOID_RET _GL_VOID GLdouble GLdouble z _GL_VOID_RET _GL_VOID GLfloat GLfloat z _GL_VOID_RET _GL_VOID GLint GLint z _GL_VOID_RET _GL_VOID GLshort GLshort z _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble w _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat w _GL_VOID_RET _GL_VOID GLint GLint GLint w _GL_VOID_RET _GL_VOID GLshort GLshort GLshort w _GL_VOID_RET _GL_VOID GLdouble GLdouble x2
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum type
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum const void *lists _GL_VOID_RET _GL_VOID const GLdouble *equation _GL_VOID_RET _GL_VOID GLdouble GLdouble blue _GL_VOID_RET _GL_VOID GLfloat GLfloat blue _GL_VOID_RET _GL_VOID GLint GLint blue _GL_VOID_RET _GL_VOID GLshort GLshort blue _GL_VOID_RET _GL_VOID GLubyte GLubyte blue _GL_VOID_RET _GL_VOID GLuint GLuint blue _GL_VOID_RET _GL_VOID GLushort GLushort blue _GL_VOID_RET _GL_VOID GLbyte GLbyte GLbyte alpha _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble alpha _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat alpha _GL_VOID_RET _GL_VOID GLint GLint GLint alpha _GL_VOID_RET _GL_VOID GLshort GLshort GLshort alpha _GL_VOID_RET _GL_VOID GLubyte GLubyte GLubyte alpha _GL_VOID_RET _GL_VOID GLuint GLuint GLuint alpha _GL_VOID_RET _GL_VOID GLushort GLushort GLushort alpha _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLint GLsizei GLsizei GLenum type _GL_VOID_RET _GL_VOID GLsizei GLenum GLenum const void *pixels _GL_VOID_RET _GL_VOID const void *pointer _GL_VOID_RET _GL_VOID GLdouble v _GL_VOID_RET _GL_VOID GLfloat v _GL_VOID_RET _GL_VOID GLint GLint i2 _GL_VOID_RET _GL_VOID GLint j _GL_VOID_RET _GL_VOID GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble GLdouble GLdouble zFar _GL_VOID_RET _GL_UINT GLdouble *equation _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLenum GLfloat *v _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLfloat *values _GL_VOID_RET _GL_VOID GLushort *values _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLenum GLdouble *params _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_BOOL GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLenum GLfloat param _GL_VOID_RET _GL_VOID GLenum GLint param _GL_VOID_RET _GL_VOID GLushort pattern _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint const GLdouble *points _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint GLdouble v1
Read Guarded memory(de)allocation.
#define RNA_BEGIN(sptr, itemptr, propname)
StructRNA RNA_OperatorMousePath
uiLayout * uiLayoutRowWithHeading(uiLayout *layout, bool align, const char *heading)
void uiLayoutSetActive(uiLayout *layout, bool active)
eAutoPropButsReturn uiDefAutoButsRNA(uiLayout *layout, struct PointerRNA *ptr, bool(*check_prop)(struct PointerRNA *ptr, struct PropertyRNA *prop, void *user_data), void *user_data, struct PropertyRNA *prop_activate_init, eButLabelAlign label_align, const bool compact)
uiLayout * uiLayoutColumn(uiLayout *layout, bool align)
void uiLayoutSetPropSep(uiLayout *layout, bool is_sep)
uiLayout * uiLayoutRow(uiLayout *layout, bool align)
void uiItemR(uiLayout *layout, struct PointerRNA *ptr, const char *propname, int flag, const char *name, int icon)
void uiLayoutSetPropDecorate(uiLayout *layout, bool is_sep)
void uiItemPointerR(uiLayout *layout, struct PointerRNA *ptr, const char *propname, struct PointerRNA *searchptr, const char *searchpropname, const char *name, int icon)
#define BM_elem_cb_check_hflag_disabled_simple(type, hflag_n)
#define BM_DISK_EDGE_NEXT(e, v)
#define BM_FACE_FIRST_LOOP(p)
#define BM_ELEM_CD_GET_VOID_P(ele, offset)
void BM_mesh_copy_init_customdata(BMesh *bm_dst, BMesh *bm_src, const BMAllocTemplate *allocsize)
void BM_mesh_copy_init_customdata_all_layers(BMesh *bm_dst, BMesh *bm_src, const char htype, const BMAllocTemplate *allocsize)
void BM_vert_separate(BMesh *bm, BMVert *v, BMEdge **e_in, int e_in_len, const bool copy_select, BMVert ***r_vout, int *r_vout_len)
void BM_vert_kill(BMesh *bm, BMVert *v)
void BM_face_kill(BMesh *bm, BMFace *f)
BMEdge * BM_edge_create(BMesh *bm, BMVert *v1, BMVert *v2, const BMEdge *e_example, const eBMCreateFlag create_flag)
Main function for creating a new edge.
void BM_mesh_decimate_collapse(BMesh *bm, const float factor, float *vweights, float vweight_factor, const bool do_triangulate, const int symmetry_axis, const float symmetry_eps)
BM_mesh_decimate.
void BM_mesh_delete_hflag_context(BMesh *bm, const char hflag, const int type)
void BM_mesh_edgeloops_free(ListBase *eloops)
int BM_mesh_edgeloops_find(BMesh *bm, ListBase *r_eloops, bool(*test_fn)(BMEdge *, void *user_data), void *user_data)
int BM_edgeloop_length_get(BMEdgeLoopStore *el_store)
bool BM_edgeloop_is_closed(BMEdgeLoopStore *el_store)
void BM_edgeloop_edges_get(struct BMEdgeLoopStore *el_store, BMEdge **e_arr)
ListBase * BM_edgeloop_verts_get(BMEdgeLoopStore *el_store)
bool BMO_error_occurred(BMesh *bm)
#define BM_elem_index_get(ele)
#define BM_elem_flag_disable(ele, hflag)
#define BM_elem_flag_set(ele, hflag, val)
#define BM_elem_index_set(ele, index)
#define BM_elem_flag_test(ele, hflag)
#define BM_elem_flag_test_bool(ele, hflag)
#define BM_elem_flag_enable(ele, hflag)
void BM_data_layer_add(BMesh *bm, CustomData *data, int type)
void BM_data_layer_add_named(BMesh *bm, CustomData *data, int type, const char *name)
void * BM_iter_at_index(BMesh *bm, const char itype, void *data, int index)
int BM_iter_elem_count_flag(const char itype, void *data, const char hflag, const bool value)
Elem Iter Flag Count.
#define BM_ITER_ELEM(ele, iter, data, itype)
#define BM_ITER_MESH(ele, iter, bm, itype)
#define BM_ITER_MESH_INDEX(ele, iter, bm, itype, indexvar)
ATTR_WARN_UNUSED_RESULT BMesh * bm
void BM_select_history_clear(BMesh *bm)
void BM_face_select_set(BMesh *bm, BMFace *f, const bool select)
Select Face.
void BM_vert_select_set(BMesh *bm, BMVert *v, const bool select)
Select Vert.
void BM_edge_select_set(BMesh *bm, BMEdge *e, const bool select)
Select Edge.
void BM_mesh_elem_hflag_disable_all(BMesh *bm, const char htype, const char hflag, const bool respecthide)
BMVert * BM_mesh_active_vert_get(BMesh *bm)
void BM_mesh_elem_hflag_enable_test(BMesh *bm, const char htype, const char hflag, const bool respecthide, const bool overwrite, const char hflag_test)
#define BM_select_history_store_notest(bm, ele)
#define BM_select_history_store_head_notest(bm, ele)
#define BM_select_history_store(bm, ele)
#define BM_SELECT_HISTORY_BACKUP(bm)
#define BM_SELECT_HISTORY_RESTORE(bm)
const BMAllocTemplate bm_mesh_allocsize_default
void BM_mesh_remap(BMesh *bm, const uint *vert_idx, const uint *edge_idx, const uint *face_idx)
void BM_lnorspace_update(BMesh *bm)
void BM_normals_loops_edges_tag(BMesh *bm, const bool do_edges)
void BM_mesh_elem_toolflags_ensure(BMesh *bm)
bool BM_custom_loop_normals_to_vector_layer(BMesh *bm)
void BM_mesh_free(BMesh *bm)
BMesh Free Mesh.
BMesh * BM_mesh_create(const BMAllocTemplate *allocsize, const struct BMeshCreateParams *params)
BMesh Make Mesh.
void BM_mesh_normals_update(BMesh *bm)
BMesh Compute Normals.
BMLoopNorEditDataArray * BM_loop_normal_editdata_array_init(BMesh *bm, const bool do_all_loops_of_vert)
void BM_mesh_elem_table_ensure(BMesh *bm, const char htype)
void BM_loop_normal_editdata_array_free(BMLoopNorEditDataArray *lnors_ed_arr)
void BM_mesh_elem_index_ensure(BMesh *bm, const char htype)
bool BM_loop_check_cyclic_smooth_fan(BMLoop *l_curr)
void BM_custom_loop_normals_from_vector_layer(BMesh *bm, bool add_sharp_edges)
BLI_INLINE BMVert * BM_vert_at_index(BMesh *bm, const int index)
void BM_mesh_bm_from_me(BMesh *bm, const Mesh *me, const struct BMeshFromMeshParams *params)
Mesh -> BMesh.
void BM_mesh_bm_to_me(Main *bmain, BMesh *bm, Mesh *me, const struct BMeshToMeshParams *params)
void BM_mesh_copy_arrays(BMesh *bm_src, BMesh *bm_dst, BMVert **verts_src, uint verts_src_len, BMEdge **edges_src, uint edges_src_len, BMFace **faces_src, uint faces_src_len)
void BMO_slot_buffer_hflag_enable(BMesh *bm, BMOpSlot slot_args[BMO_OP_MAX_SLOTS], const char *slot_name, const char htype, const char hflag, const bool do_flush)
BMO_FLAG_BUFFER.
@ BMO_SYMMETRIZE_NEGATIVE_X
void * BMO_slot_buffer_get_first(BMOpSlot slot_args[BMO_OP_MAX_SLOTS], const char *slot_name)
void BMO_slot_bool_set(BMOpSlot slot_args[BMO_OP_MAX_SLOTS], const char *slot_name, const bool i)
void * BMO_slot_buffer_alloc(BMOperator *op, BMOpSlot slot_args[BMO_OP_MAX_SLOTS], const char *slot_name, const int len)
void BMO_slot_buffer_hflag_disable(BMesh *bm, BMOpSlot slot_args[BMO_OP_MAX_SLOTS], const char *slot_name, const char htype, const char hflag, const bool do_flush)
BMO_FLAG_BUFFER.
void BMO_op_exec(BMesh *bm, BMOperator *op)
BMESH OPSTACK EXEC OP.
bool BMO_op_initf(BMesh *bm, BMOperator *op, const int flag, const char *fmt,...)
#define BMO_edge_flag_set(bm, e, oflag, val)
#define BMO_ITER(ele, iter, slot_args, slot_name, restrict_flag)
int BMO_slot_buffer_count(BMOpSlot slot_args[BMO_OP_MAX_SLOTS], const char *slot_name)
void BMO_slot_float_set(BMOpSlot slot_args[BMO_OP_MAX_SLOTS], const char *slot_name, const float f)
void BMO_op_finish(BMesh *bm, BMOperator *op)
BMESH OPSTACK FINISH OP.
BMOpSlot * BMO_slot_get(BMOpSlot slot_args[BMO_OP_MAX_SLOTS], const char *identifier)
BMESH OPSTACK GET SLOT.
@ DEL_FACES_KEEP_BOUNDARY
#define BMO_FLAG_DEFAULTS
void BMO_slot_int_set(BMOpSlot slot_args[BMO_OP_MAX_SLOTS], const char *slot_name, const int i)
void BMO_slot_buffer_from_enabled_flag(BMesh *bm, BMOperator *op, BMOpSlot slot_args[BMO_OP_MAX_SLOTS], const char *slot_name, const char htype, const short oflag)
void BMO_op_init(BMesh *bm, BMOperator *op, const int flag, const char *opname)
BMESH OPSTACK INIT OP.
bool BMO_op_callf(BMesh *bm, const int flag, const char *fmt,...)
BLI_INLINE void BMO_slot_map_float_insert(BMOperator *op, BMOpSlot *slot, void *element, const float val)
void BM_mesh_esubdivide(BMesh *bm, const char edge_hflag, const float smooth, const short smooth_falloff, const bool use_smooth_even, const float fractal, const float along_normal, const int numcuts, const int seltype, const int cornertype, const short use_single_edge, const short use_grid_fill, const short use_only_quads, const int seed)
@ SUBD_CORNER_STRAIGHT_CUT
@ SUBD_RING_INTERP_LINEAR
@ BMOP_POKE_MEDIAN_WEIGHTED
void BM_vert_normal_update(BMVert *v)
float BM_face_calc_area(const BMFace *f)
void BM_face_calc_center_median(const BMFace *f, float r_cent[3])
int BM_mesh_calc_edge_groups_as_arrays(BMesh *bm, BMVert **verts, BMEdge **edges, BMFace **faces, int(**r_groups)[3])
BMEdge * BM_edge_exists(BMVert *v_a, BMVert *v_b)
bool BM_vert_is_wire(const BMVert *v)
BMFace * BM_edge_pair_share_face_by_len(BMEdge *e_a, BMEdge *e_b, BMLoop **r_l_a, BMLoop **r_l_b, const bool allow_adjacent)
bool BM_edge_face_pair(BMEdge *e, BMFace **r_fa, BMFace **r_fb)
BMLoop * BM_face_edge_share_loop(BMFace *f, BMEdge *e)
Return the Loop Shared by Face and Edge.
bool BM_edge_share_face_check(BMEdge *e1, BMEdge *e2)
float BM_edge_calc_face_angle_ex(const BMEdge *e, const float fallback)
BMESH EDGE/FACE ANGLE.
float BM_loop_calc_face_angle(const BMLoop *l)
BMLoop * BM_vert_step_fan_loop(BMLoop *l, BMEdge **e_step)
BMLoop * BM_face_vert_share_loop(BMFace *f, BMVert *v)
Return the Loop Shared by Face and Vertex.
bool BM_vert_pair_share_face_check_cb(BMVert *v_a, BMVert *v_b, bool(*test_fn)(BMFace *, void *user_data), void *user_data)
BLI_INLINE bool BM_edge_is_boundary(const BMEdge *e) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL()
BLI_INLINE BMVert * BM_edge_other_vert(BMEdge *e, const BMVert *v) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL()
BLI_INLINE bool BM_edge_is_wire(const BMEdge *e) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL()
ATTR_WARN_UNUSED_RESULT const BMVert * v2
ATTR_WARN_UNUSED_RESULT const BMLoop * l
ATTR_WARN_UNUSED_RESULT const BMVert const BMEdge * e
ATTR_WARN_UNUSED_RESULT const BMVert * v
btMatrix3x3 absolute() const
Return the matrix with all values non negative.
static unsigned long seed
SIMD_FORCE_INLINE btScalar angle(const btVector3 &v) const
Return the angle between this and another vector.
bool EDBM_op_callf(BMEditMesh *em, wmOperator *op, const char *fmt,...)
bool EDBM_op_init(BMEditMesh *em, BMOperator *bmop, wmOperator *op, const char *fmt,...)
bool EDBM_op_call_and_selectf(BMEditMesh *em, wmOperator *op, const char *select_slot_out, const bool select_extend, const char *fmt,...)
bool EDBM_op_finish(BMEditMesh *em, BMOperator *bmop, wmOperator *op, const bool do_report)
bool EDBM_view3d_poll(bContext *C)
BLI_INLINE float fb(float length, float L)
void(* MEM_freeN)(void *vmemh)
void *(* MEM_callocN)(size_t len, const char *str)
void *(* MEM_mallocN)(size_t len, const char *str)
void MESH_OT_convex_hull(struct wmOperatorType *ot)
static void clear(Message *msg)
INLINE Rall1d< T, V, S > pow(const Rall1d< T, V, S > &arg, double m)
float RNA_property_float_get(PointerRNA *ptr, PropertyRNA *prop)
void RNA_property_int_set(PointerRNA *ptr, PropertyRNA *prop, int value)
void RNA_property_float_get_array(PointerRNA *ptr, PropertyRNA *prop, float *values)
void RNA_pointer_create(ID *id, StructRNA *type, void *data, PointerRNA *r_ptr)
int RNA_collection_length(PointerRNA *ptr, const char *name)
void RNA_id_pointer_create(ID *id, PointerRNA *r_ptr)
const char * RNA_property_identifier(const PropertyRNA *prop)
bool RNA_property_is_set(PointerRNA *ptr, PropertyRNA *prop)
PropertyRNA * RNA_struct_find_property(PointerRNA *ptr, const char *identifier)
void RNA_float_get_array(PointerRNA *ptr, const char *name, float *values)
bool RNA_property_boolean_get(PointerRNA *ptr, PropertyRNA *prop)
int RNA_property_int_get(PointerRNA *ptr, PropertyRNA *prop)
int RNA_int_get(PointerRNA *ptr, const char *name)
void RNA_property_boolean_set(PointerRNA *ptr, PropertyRNA *prop, bool value)
float RNA_float_get(PointerRNA *ptr, const char *name)
void RNA_property_float_set_array(PointerRNA *ptr, PropertyRNA *prop, const float *values)
int RNA_property_enum_get(PointerRNA *ptr, PropertyRNA *prop)
bool RNA_boolean_get(PointerRNA *ptr, const char *name)
void RNA_enum_set(PointerRNA *ptr, const char *name, int value)
int RNA_enum_get(PointerRNA *ptr, const char *name)
PropertyRNA * RNA_def_float(StructOrFunctionRNA *cont_, const char *identifier, float default_value, float hardmin, float hardmax, const char *ui_name, const char *ui_description, float softmin, float softmax)
PropertyRNA * RNA_def_boolean(StructOrFunctionRNA *cont_, const char *identifier, bool default_value, const char *ui_name, const char *ui_description)
PropertyRNA * RNA_def_enum_flag(StructOrFunctionRNA *cont_, const char *identifier, const EnumPropertyItem *items, int default_value, const char *ui_name, const char *ui_description)
void RNA_def_property_float_default(PropertyRNA *prop, float value)
void RNA_def_property_enum_default(PropertyRNA *prop, int value)
PropertyRNA * RNA_def_float_distance(StructOrFunctionRNA *cont_, const char *identifier, float default_value, float hardmin, float hardmax, const char *ui_name, const char *ui_description, float softmin, float softmax)
void RNA_def_property_ui_text(PropertyRNA *prop, const char *name, const char *description)
PropertyRNA * RNA_def_collection_runtime(StructOrFunctionRNA *cont_, const char *identifier, StructRNA *type, const char *ui_name, const char *ui_description)
void RNA_def_property_enum_items(PropertyRNA *prop, const EnumPropertyItem *item)
PropertyRNA * RNA_def_float_factor(StructOrFunctionRNA *cont_, const char *identifier, float default_value, float hardmin, float hardmax, const char *ui_name, const char *ui_description, float softmin, float softmax)
PropertyRNA * RNA_def_property(StructOrFunctionRNA *cont_, const char *identifier, int type, int subtype)
void RNA_enum_item_end(EnumPropertyItem **items, int *totitem)
void RNA_enum_item_add(EnumPropertyItem **items, int *totitem, const EnumPropertyItem *item)
void RNA_def_property_translation_context(PropertyRNA *prop, const char *context)
PropertyRNA * RNA_def_float_vector_xyz(StructOrFunctionRNA *cont_, const char *identifier, int len, const float *default_value, float hardmin, float hardmax, const char *ui_name, const char *ui_description, float softmin, float softmax)
void RNA_def_property_flag(PropertyRNA *prop, PropertyFlag flag)
PropertyRNA * RNA_def_int(StructOrFunctionRNA *cont_, const char *identifier, int default_value, int hardmin, int hardmax, const char *ui_name, const char *ui_description, int softmin, int softmax)
void RNA_def_enum_funcs(PropertyRNA *prop, EnumPropertyItemFunc itemfunc)
void RNA_enum_items_add_value(EnumPropertyItem **items, int *totitem, const EnumPropertyItem *item, int value)
void RNA_def_property_ui_range(PropertyRNA *prop, double min, double max, double step, int precision)
PropertyRNA * RNA_def_float_rotation(StructOrFunctionRNA *cont_, const char *identifier, int len, const float *default_value, float hardmin, float hardmax, const char *ui_name, const char *ui_description, float softmin, float softmax)
PropertyRNA * RNA_def_enum(StructOrFunctionRNA *cont_, const char *identifier, const EnumPropertyItem *items, int default_value, const char *ui_name, const char *ui_description)
const EnumPropertyItem rna_enum_mesh_delimit_mode_items[]
const EnumPropertyItem rna_enum_modifier_triangulate_ngon_method_items[]
const EnumPropertyItem rna_enum_axis_xyz_items[]
const EnumPropertyItem rna_enum_modifier_triangulate_quad_method_items[]
const EnumPropertyItem DummyRNA_NULL_items[]
const EnumPropertyItem rna_enum_proportional_falloff_curve_only_items[]
const EnumPropertyItem rna_enum_symmetrize_direction_items[]
struct BMEditSelection * next
struct BMEditSelection * prev
BMLoopNorEditData ** lidx_to_lnor_editdata
BMLoopNorEditData * lnor_editdata
int cd_custom_normal_offset
struct BMLoop * radial_next
struct BMOpSlot slots_out[BMO_OP_MAX_SLOTS]
struct BMOpSlot slots_in[BMO_OP_MAX_SLOTS]
struct MLoopNorSpaceArray * lnor_spacearr
float profile_shape_factor
MLoopNorSpace ** lspacearr
struct BMEditMesh * edit_mesh
struct ToolSettings * toolsettings
int(* invoke)(struct bContext *, struct wmOperator *, const struct wmEvent *) ATTR_WARN_UNUSED_RESULT
int(* modal)(struct bContext *, struct wmOperator *, const struct wmEvent *) ATTR_WARN_UNUSED_RESULT
bool(* poll)(struct bContext *) ATTR_WARN_UNUSED_RESULT
bool(* poll_property)(const struct bContext *C, struct wmOperator *op, const PropertyRNA *prop) ATTR_WARN_UNUSED_RESULT
void(* cancel)(struct bContext *, struct wmOperator *)
void(* ui)(struct bContext *, struct wmOperator *)
bool(* check)(struct bContext *, struct wmOperator *)
int(* exec)(struct bContext *, struct wmOperator *) ATTR_WARN_UNUSED_RESULT
struct ReportList * reports
struct wmOperatorType * type
static int blend(const Tex *tex, const float texvec[3], TexResult *texres)
__forceinline const avxb select(const avxb &m, const avxb &t, const avxb &f)
void WM_cursor_wait(bool val)
wmEventHandler_Op * WM_event_add_modal_handler(bContext *C, wmOperator *op)
bool WM_operator_poll(bContext *C, wmOperatorType *ot)
void WM_event_add_notifier(const bContext *C, uint type, void *reference)
int WM_gesture_lines_modal(bContext *C, wmOperator *op, const wmEvent *event)
int WM_gesture_lines_invoke(bContext *C, wmOperator *op, const wmEvent *event)
wmKeyMap * WM_modalkeymap_find(wmKeyConfig *keyconf, const char *idname)
void WM_modalkeymap_assign(wmKeyMap *km, const char *opname)
const char * WM_bool_as_string(bool test)
wmKeyMap * WM_modalkeymap_ensure(wmKeyConfig *keyconf, const char *idname, const EnumPropertyItem *items)
void WM_operatortype_props_advanced_begin(wmOperatorType *ot)
void WM_operator_type_modal_from_exec_for_object_edit_coords(wmOperatorType *ot)
int WM_menu_invoke(bContext *C, wmOperator *op, const wmEvent *UNUSED(event))