85#define PARTIAL_TYPE_MAX 2
138 custom_data->
data =
nullptr;
178#define USE_FACE_SUBSTITUTE
179#ifdef USE_FACE_SUBSTITUTE
180# define FACE_SUBSTITUTE_INDEX INT_MIN
188 BMFace *best_face =
nullptr;
193 BMFace *f_test = l_radial_next->
f;
210 if (best_face ==
nullptr) {
238 }
while ((l_iter = l_iter->
next) != l_first);
242 tcld->
bm_origfaces, cd_face_map, cd_loop_map, f_substitute,
true,
true);
247 *((
BMFace **)&f_copy->
no[0]) = f_substitute_copy;
254 return *((
BMFace **)&f_copy->
no[0]);
280 for (j = 0; j < l_num; j++) {
290#ifdef USE_FACE_SUBSTITUTE
304 loop_weights[j] = 0.0f;
318 bm,
v, layer_nr, loop_weights, tcld->
arena);
336 params.use_toolflags =
false;
359 int *customdatalayer_map =
static_cast<int *
>(
361 int layer_math_map_len = 0;
364 customdatalayer_map[layer_math_map_len++] = i;
378 const bool use_merge_group)
414 for (
int j = tc->
data_len; j--; tob++, i++) {
432 if (!customdatacorrect) {
466 bool use_merge_group =
false;
472 use_merge_group =
true;
499 if (tc->custom.type.data !=
nullptr) {
524 return td ? td->iloc :
v->
co;
534 const float *co_orig_3d = td->iloc;
541 const float *v_proj_axis =
v->
no;
545 if (do_loop_weight) {
552 loop_weights = do_loop_weight ?
static_cast<float *
>(
BLI_array_alloca(loop_weights, l_num)) :
554 for (j = 0; j < l_num; j++) {
560#ifdef USE_FACE_SUBSTITUTE
573 if (do_loop_weight) {
574 const float eps = 1.0e-8f;
603 if (co_prev_ok && co_next_ok) {
607 loop_weights[j] = (dist >= 0.0f) ? 1.0f : ((dist <= -
eps) ? 0.0f : (1.0f + (dist /
eps)));
608 if (
UNLIKELY(!isfinite(loop_weights[j]))) {
609 loop_weights[j] = 0.0f;
613 loop_weights[j] = 0.0f;
621 if (do_loop_weight) {
641 const bool update_loop_mdisps = is_moved && do_loop_mdisps && (tcld->
cd_loop_mdisp_offset != -1);
642 if (update_loop_mdisps) {
652 float f_copy_center[3];
663 faces_center[j_other],
675 if (tcld ==
nullptr) {
682 for (
int i = tc->
data_len; i--; tob++) {
685 if (use_merge_group) {
694 if (use_merge_group) {
726 BMLoop *l_iter, *l_first, *l_copy;
732 l_copy = l_copy->
next;
733 }
while ((l_iter = l_iter->
next) != l_first);
745 const bool calc_single_islands,
746 const bool calc_island_center,
747 const bool calc_island_axismtx,
758 int *groups_array =
nullptr;
759 int(*group_index)[2] =
nullptr;
762 if (has_only_single_islands && !calc_single_islands) {
766 data.island_vert_map =
static_cast<int *
>(
773 if (!has_only_single_islands) {
775 groups_array =
static_cast<int *
>(
784 groups_array =
static_cast<int *
>(
794 if (calc_island_center) {
795 data.center =
static_cast<float(*)[3]
>(
796 MEM_mallocN(
sizeof(*data.center) * data.island_tot, __func__));
799 if (calc_island_axismtx) {
800 data.axismtx =
static_cast<float(*)[3][3]
>(
801 MEM_mallocN(
sizeof(*data.axismtx) * data.island_tot, __func__));
812 for (i = 0; i < data.island_tot; i++) {
815 const int fg_sta = group_index[i][0];
816 const int fg_len = group_index[i][1];
817 float co[3], no[3], tangent[3];
830 for (j = 0; j < fg_len; j++) {
831 ese.
ele =
static_cast<BMElem *
>(ele_array[groups_array[fg_sta + j]]);
840 float tmp_no[3], tmp_tangent[3];
860 mul_v3_v3fl(data.center[i], co, 1.0f /
float(fg_len));
885 if (calc_single_islands) {
888 int group_tot_single = 0;
892 group_tot_single += 1;
896 if (group_tot_single != 0) {
897 if (calc_island_center) {
899 data.center,
sizeof(*data.center) * (data.island_tot + group_tot_single)));
901 if (calc_island_axismtx) {
902 data.axismtx =
static_cast<float(*)[3][3]
>(
MEM_reallocN(
903 data.axismtx,
sizeof(*data.axismtx) * (data.island_tot + group_tot_single)));
908 data.island_vert_map[i] = data.island_tot;
915 invert_m3(data.axismtx[data.island_tot]);
918 unit_m3(data.axismtx[data.island_tot]);
922 data.island_tot += 1;
928 *r_island_data =
data;
933 if (island_data->
center) {
956 const float mtx[3][3])
964 if (dists[i0] <= dists[i1]) {
974 if (dists[i0] <= dists[i2]) {
978 float vm0[3], vm1[3], vm2[3];
991 dist0 = dists[i1] +
len_v3(vec);
994 if (dist0 < dists[i0]) {
996 if (index !=
nullptr) {
997 index[i0] = index[i1];
1009 if (edge->l ==
nullptr) {
1025 const float mtx[3][3],
1052 if (index !=
nullptr) {
1058 if (index !=
nullptr) {
1105 if (dists[i1] > dists[i2]) {
1138 BMVert *v_other = l_other->v;
1164 for (
LinkNode *lnk = queue_next; lnk; lnk = lnk->
next) {
1187#define TRANSFORM_MAXDIST_MIRROR 0.00002f
1191 if (quadrant[0] && ((co[0] * quadrant[0]) < -epsilon)) {
1194 if (quadrant[1] && ((co[1] * quadrant[1]) < -epsilon)) {
1197 if (quadrant[2] && ((co[2] * quadrant[2]) < -epsilon)) {
1204 const bool use_select,
1205 const bool use_topology,
1206 const bool mirror_axis[3],
1218 float select_sum[3] = {0};
1231 for (
int a = 0; a < 3; a++) {
1232 if (mirror_axis[a]) {
1233 quadrant[a] = select_sum[a] >= 0.0f ? 1 : -1;
1240 uint mirror_elem_len = 0;
1241 int *index[3] = {
nullptr,
nullptr,
nullptr};
1242 bool is_single_mirror_axis = (mirror_axis[0] + mirror_axis[1] + mirror_axis[2]) == 1;
1243 bool test_selected_only = use_select && is_single_mirror_axis;
1244 for (
int a = 0; a < 3; a++) {
1245 if (!mirror_axis[a]) {
1249 index[a] =
static_cast<int *
>(
MEM_mallocN(totvert *
sizeof(*index[a]), __func__));
1255 int i_mirr = index[a][i];
1268 if (vert_map[i_mirr].
flag != 0) {
1285 if (!mirror_elem_len) {
1289 else if (!is_single_mirror_axis) {
1291 for (
int a = 0; a < 3; a++) {
1292 if (!mirror_axis[a]) {
1297 for (i = 0; i < totvert; i++) {
1298 int i_mirr = index[a][i];
1302 if (vert_map[i].index != -1 && !(vert_map[i].
flag &
flag)) {
1303 if (vert_map[i_mirr].index == -1) {
1317 r_mirror_data->
vert_map = vert_map;
1339 float(*quats)[4] =
nullptr;
1354 t->
depsgraph, scene_eval, obedit_eval, em_eval, r_crazyspace_data->
defmats, defcos);
1362 if ((totleft > 0) || (totleft == -1))
1369 quats =
static_cast<float(*)[4]
>(
1374 r_crazyspace_data->
quats = quats;
1378 const float smtx[3][3],
1379 const float defmat[3][3],
1380 const float quat[4],
1384 if (quat || defmat) {
1385 float mat[3][3], qmat[3][3], imat[3][3];
1415 if (r_crazyspace_data->
quats) {
1427 const int island_index,
1428 const float iloc[3],
1431 if (island_data->
center && island_index != -1) {
1446 const int island_index)
1469 if ((island_index != -1) && island_data->
axismtx) {
1496 Mesh *mesh =
static_cast<Mesh *
>(tc->obedit->data);
1500 float mtx[3][3], smtx[3][3];
1540 if (data_len == 0) {
1556 if (is_island_center) {
1563 const bool calc_island_center = !is_snap_rotate;
1569 em, calc_single_islands, calc_island_center, calc_island_axismtx, &island_data);
1572 copy_m3_m4(mtx, tc->obedit->object_to_world().ptr());
1579 int *dists_index =
nullptr;
1580 float *dists =
nullptr;
1583 if (is_island_center) {
1590 if (tc->use_mirror_axis_any) {
1593 const bool mirror_axis[3] = {
1594 bool(tc->use_mirror_axis_x), bool(tc->use_mirror_axis_y), bool(tc->use_mirror_axis_z)};
1596 em, use_select, use_topology, mirror_axis, &mirror_data);
1618 tc->data_len = data_len;
1637 int island_index = -1;
1639 const int connected_index = (dists_index && dists_index[a] != -1) ? dists_index[a] : a;
1651 td_mirror->extra = eve;
1652 td_mirror->loc = eve->
co;
1675 tob->
dist = dists[a];
1686 !crazyspace_data.
defmats.is_empty() ? crazyspace_data.
defmats[a].ptr() :
nullptr,
1688 crazyspace_data.
quats[a] :
1692 if (tc->use_mirror_axis_any) {
1724 if (looptri_is_dirty) {
1744 if (pupdate->
cache) {
1775 return pupdate->
cache;
1779 pupdate->
cache =
nullptr;
1787 int *verts_group =
nullptr;
1788 int verts_group_count = 0;
1791 int verts_mask_count = 0;
1795 verts_group =
static_cast<int *
>(
1799 for (i = 0, td = tc->
data; i < tc->
data_len; i++, td++) {
1800 if (td->
factor == 0.0f) {
1808 verts_group[v_index] = -1;
1812 verts_group[v_index] = 1;
1819 verts_mask_count += 1;
1829 if (verts_group[v_mirr_index] == 0 &&
equals_v3v3(td_mirror->loc, td_mirror->iloc)) {
1839 if (verts_group[v_mirr_index] == -1) {
1840 verts_group[v_mirr_other_index] = -1;
1847 verts_mask_count += 1;
1855 for (i = 0, td = tc->
data; i < tc->
data_len; i++, td++) {
1856 if (td->
factor == 0.0f) {
1863 verts_mask_count += 1;
1879 verts_mask_count += 1;
1883 switch (partial_type) {
1886 params.do_tessellate =
true;
1887 params.do_normals =
true;
1889 em->
bm, &
params, verts_mask, verts_mask_count);
1894 params.do_tessellate =
true;
1895 params.do_normals =
true;
1897 em->
bm, &
params, verts_group, verts_group_count) :
1899 em->
bm, &
params, verts_mask, verts_mask_count));
1917 return pupdate->
cache;
1975 r_partial_state->
for_normals = partial_for_normals;
2011 params.face_normals =
true;
2022 params.face_normals = face_normals;
2043 for (i = 0, td = tc->
data; i < tc->
data_len; i++, td++) {
2061 td_mirror->loc[0] *= -1;
2064 td_mirror->loc[1] *= -1;
2067 td_mirror->loc[2] *= -1;
2077 if (!is_canceling) {
2125 if (use_automerge) {
2132 if (tc->use_mirror_axis_any) {
2138 for (
int i = tc->data_mirror_len; i--; td_mirror++) {
2181 int td_selected_len = 0;
2183 for (
int i = 0; i < tc->
data_len; i++, td++) {
2195 for (
int i = 0; i < tc->
data_len; i++, td++) {
2200 const int size_prev = r_loc_dst_buffer.
size();
2204 r_loc_dst_buffer.
append(td->iloc);
2214 r_loc_dst_buffer.
append(v_other->
co);
2229 int size = sv.co_link_curr;
2230 sv.co_link_orig_3d = r_loc_dst_buffer.
as_span().slice(start, size);
2231 sv.co_link_curr = 0;
2268 if ((fac > -FLT_EPSILON) && (fac < 1.0f + FLT_EPSILON)) {
2273 if (dist_sq_test < dist_sq_best) {
2275 dist_sq_best = dist_sq_test;
2280 }
while ((l_iter = l_iter->
next) != l_last);
2312 int td_selected_len = 0;
2318 for (
int i = 0; i < tc->
data_len; i++, td++) {
2323 v =
static_cast<BMVert *
>(td->extra);
2325 if (numsel == 0 || numsel > 2) {
2354 for (
int i = 0; i < tc->
data_len; i++, td++) {
2364 v =
static_cast<BMVert *
>(td->extra);
2380 if (
ELEM(-1, td_index_1, td_index_2)) {
2384 int slot_1 =
int(td_connected[td_index_1][0] != -1);
2385 int slot_2 =
int(td_connected[td_index_2][0] != -1);
2387 td_connected[td_index_1][slot_1] = td_index_2;
2388 td_connected[td_index_2][slot_2] = td_index_1;
2402 int i_prev = td_connected[i][1];
2403 while (!
ELEM(i_prev, -1, i)) {
2404 int tmp = td_connected[i_prev][0] != i_curr ? td_connected[i_prev][0] :
2405 td_connected[i_prev][1];
2419 struct SlideTempDataMesh {
2429 bool vert_is_edge_pair;
2438 int find_best_dir(
const SlideTempDataMesh *curr_side_other,
2442 bool *r_do_isect_curr_dirs)
const
2444 *r_do_isect_curr_dirs =
false;
2446 if (f_curr == curr_side_other->fdata[0].f || v_dst == curr_side_other->fdata[0].v_dst) {
2450 if (f_curr == curr_side_other->fdata[1].f || v_dst == curr_side_other->fdata[1].v_dst) {
2454 if (curr_side_other->fdata[0].f || curr_side_other->fdata[1].f) {
2460 if (l_other->
f == curr_side_other->fdata[0].f) {
2464 if (l_other->
f == curr_side_other->fdata[1].f) {
2468 l_other = (l_other->
v == this->v ? l_other->
prev : l_other->
next)->radial_next;
2469 }
while (l_other->
f != l_edge->
f);
2471 if (best_dir != -1) {
2472 *r_do_isect_curr_dirs =
true;
2477 if (
ELEM(
nullptr, this->fdata[0].f, this->fdata[1].f)) {
2478 return int(this->fdata[0].f !=
nullptr);
2486 *r_do_isect_curr_dirs =
true;
2493 if (is_boundary_0 && !is_boundary_1) {
2497 if (is_boundary_1 && !is_boundary_0) {
2504 float3 dir_curr = dst - src;
2509 return int(dot0 < dot1);
2511 } prev = {}, curr = {},
next = {}, next_next = {}, tmp = {};
2513 next.i = td_connected[i_curr][0] != i_prev ? td_connected[i_curr][0] : td_connected[i_curr][1];
2522 curr.sv = &r_sv[curr.i];
2523 curr.v =
static_cast<BMVert *
>(curr.sv->td->extra);
2533 while (curr.i != -1) {
2535 next_next.i = td_connected[
next.i][0] != curr.i ? td_connected[
next.i][0] :
2536 td_connected[
next.i][1];
2537 if (next_next.i != -1) {
2538 next_next.sv = &r_sv[next_next.i];
2539 next_next.v =
static_cast<BMVert *
>(next_next.sv->td->extra);
2553 if (
l->
v == curr.v) {
2556 l_edge_next = l2->
e;
2557 v1_dst = l1->
prev->
v;
2558 v2_dst = l2->
next->
v;
2563 l_edge_next = l2->
prev->
e;
2564 v1_dst = l1->
next->
v;
2565 v2_dst = l2->
prev->
v;
2572 bool isect_curr_dirs =
false;
2575 int best_dir = curr.find_best_dir(&tmp, f_curr, l1, v1_dst, &isect_curr_dirs);
2577 if (curr.fdata[best_dir].f ==
nullptr) {
2578 curr.fdata[best_dir].f = f_curr;
2579 if (curr.vert_is_edge_pair) {
2583 curr.fdata[best_dir].v_dst = v1_dst;
2584 curr.fdata[best_dir].dst = v1_dst->
co;
2589 next.fdata[best_dir].f = f_curr;
2590 if (l_edge_next ==
next.e ||
next.vert_is_edge_pair) {
2592 next.fdata[best_dir].v_dst =
nullptr;
2597 next.fdata[best_dir].v_dst = v2_dst;
2598 next.fdata[best_dir].dst = v2_dst->
co;
2601 if (isect_curr_dirs) {
2603 float3 &dst0 = prev.fdata[best_dir].dst;
2604 float3 &dst1 = curr.fdata[best_dir].dst;
2621 float3 iloc = curr.sv->td->iloc;
2622 if (curr.fdata[0].f) {
2623 curr.sv->dir_side[0] = curr.fdata[0].dst - iloc;
2625 if (curr.fdata[1].f) {
2626 curr.sv->dir_side[1] = curr.fdata[1].dst - iloc;
2628 curr.sv->edge_len =
math::distance(curr.sv->dir_side[0], curr.sv->dir_side[1]);
2629 curr.sv->loop_nr = loop_nr;
2631 if (i_prev != -1 && prev.i == i_prev) {
2645 *r_group_len = loop_nr;
Main * CTX_data_main(const bContext *C)
blender::Array< blender::float3 > BKE_crazyspace_get_mapped_editverts(Depsgraph *depsgraph, Object *obedit)
int BKE_crazyspace_get_first_deform_matrices_editbmesh(Depsgraph *depsgraph, Scene *, Object *, BMEditMesh *em, blender::Array< blender::float3x3, 0 > &deformmats, blender::Array< blender::float3, 0 > &deformcos)
void BKE_crazyspace_set_quats_editmesh(BMEditMesh *em, blender::Span< blender::float3 > origcos, blender::Span< blender::float3 > mappedcos, float(*quats)[4], bool use_select)
int CustomData_get_offset(const CustomData *data, eCustomDataType type)
BMCustomDataCopyMap CustomData_bmesh_copy_map_calc(const CustomData &src, const CustomData &dst, eCustomDataMask mask_exclude=0)
bool CustomData_layer_has_math(const CustomData *data, int layer_n)
bool CustomData_has_layer(const CustomData *data, eCustomDataType type)
bool CustomData_has_math(const CustomData *data)
BMEditMesh * BKE_editmesh_from_object(Object *ob)
Return the BMEditMesh for a given object.
void BKE_editmesh_looptris_calc_with_partial_ex(BMEditMesh *em, BMPartialUpdate *bmpinfo, const BMeshCalcTessellation_Params *params)
void BKE_editmesh_looptris_calc(BMEditMesh *em)
void BKE_editmesh_looptris_and_normals_calc(BMEditMesh *em)
int BKE_modifiers_get_cage_index(const Scene *scene, Object *ob, int *r_lastPossibleCageIndex, bool is_virtual)
bool BKE_modifiers_is_correctable_deformed(const Scene *scene, Object *ob)
void BKE_scene_graph_evaluated_ensure(Depsgraph *depsgraph, Main *bmain)
#define BLI_array_alloca(arr, realsize)
#define BLI_assert_unreachable()
#define BLI_BITMAP_NEW(_num, _alloc_string)
#define BLI_BITMAP_TEST(_bitmap, _index)
#define BLI_BITMAP_ENABLE(_bitmap, _index)
BLI_INLINE void * BLI_ghashIterator_getKey(GHashIterator *ghi) ATTR_WARN_UNUSED_RESULT
BLI_INLINE void * BLI_ghashIterator_getValue(GHashIterator *ghi) ATTR_WARN_UNUSED_RESULT
#define GHASH_ITER(gh_iter_, ghash_)
GHash * BLI_ghash_ptr_new(const char *info) ATTR_MALLOC ATTR_WARN_UNUSED_RESULT
GHash * BLI_ghash_ptr_new_ex(const char *info, unsigned int nentries_reserve) ATTR_MALLOC ATTR_WARN_UNUSED_RESULT
void * BLI_ghash_lookup(const GHash *gh, const void *key) ATTR_WARN_UNUSED_RESULT
void BLI_ghash_insert(GHash *gh, void *key, void *val)
void BLI_ghash_free(GHash *gh, GHashKeyFreeFP keyfreefp, GHashValFreeFP valfreefp)
bool BLI_ghash_ensure_p(GHash *gh, void *key, void ***r_val) ATTR_WARN_UNUSED_RESULT
BLI_LINKSTACK_*** wrapper macros for using a LinkNode to store a stack of pointers,...
#define BLI_LINKSTACK_PUSH(var, ptr)
#define BLI_LINKSTACK_DECLARE(var, type)
#define BLI_LINKSTACK_SIZE(var)
#define BLI_LINKSTACK_FREE(var)
#define BLI_LINKSTACK_INIT(var)
#define BLI_LINKSTACK_POP(var)
#define BLI_LINKSTACK_SWAP(var_a, var_b)
float geodesic_distance_propagate_across_triangle(const float v0[3], const float v1[3], const float v2[3], float dist1, float dist2)
int isect_line_line_epsilon_v3(const float v1[3], const float v2[3], const float v3[3], const float v4[3], float r_i1[3], float r_i2[3], float epsilon)
void axis_dominant_v3_to_m3(float r_mat[3][3], const float normal[3])
Normal to x,y matrix.
MINLINE int poly_to_tri_count(int poly_count, int corner_count)
float line_point_factor_v3(const float p[3], const float l1[3], const float l2[3])
bool isect_line_plane_v3(float r_isect_co[3], const float l1[3], const float l2[3], const float plane_co[3], const float plane_no[3]) ATTR_WARN_UNUSED_RESULT
float dist_signed_squared_to_corner_v3v3v3(const float p[3], const float v1[3], const float v2[3], const float v3[3], const float axis_ref[3])
void mul_m3_v3(const float M[3][3], float r[3])
void pseudoinverse_m3_m3(float inverse[3][3], const float mat[3][3], float epsilon)
void copy_m3_m3(float m1[3][3], const float m2[3][3])
void unit_m3(float m[3][3])
void copy_m3_m4(float m1[3][3], const float m2[4][4])
#define PSEUDOINVERSE_EPSILON
bool invert_m3_m3(float inverse[3][3], const float mat[3][3])
void mul_v3_m3v3(float r[3], const float M[3][3], const float a[3])
#define mul_m3_series(...)
void mul_m3_m3m3(float R[3][3], const float A[3][3], const float B[3][3])
bool invert_m3(float mat[3][3])
void quat_to_mat3(float m[3][3], const float q[4])
MINLINE bool equals_v3v3(const float v1[3], const float v2[3]) ATTR_WARN_UNUSED_RESULT
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 copy_v3_v3(float r[3], const float a[3])
void project_plane_normalized_v3_v3v3(float out[3], const float p[3], const float v_plane[3])
void copy_vn_i(int *array_tar, int size, int val)
MINLINE bool is_zero_v3(const float v[3]) ATTR_WARN_UNUSED_RESULT
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 float normalize_v3(float n[3])
MINLINE float len_v3(const float a[3]) ATTR_WARN_UNUSED_RESULT
void * BLI_memarena_alloc(struct MemArena *ma, size_t size) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1) ATTR_MALLOC ATTR_ALLOC_SIZE(2)
void BLI_memarena_free(struct MemArena *ma) ATTR_NONNULL(1)
struct MemArena * BLI_memarena_new(size_t bufsize, const char *name) ATTR_WARN_UNUSED_RESULT ATTR_RETURNS_NONNULL ATTR_NONNULL(2) ATTR_MALLOC
#define BLI_MEMARENA_STD_BUFSIZE
#define POINTER_OFFSET(v, ofs)
void DEG_id_tag_update(ID *id, unsigned int flags)
ID * DEG_get_evaluated_id(const Depsgraph *depsgraph, ID *id)
@ UVCALC_TRANSFORM_CORRECT_SLIDE
@ UVCALC_TRANSFORM_CORRECT
@ UVCALC_TRANSFORM_CORRECT_KEEP_CONNECTED
@ V3D_AROUND_LOCAL_ORIGINS
void EDBM_automerge_and_split(Object *obedit, bool split_edges, bool split_faces, bool update, char hflag, float dist)
void EDBM_automerge(Object *obedit, bool update, char hflag, float dist)
void EDBM_selectmode_flush_ex(BMEditMesh *em, short selectmode)
void EDBM_verts_mirror_cache_begin_ex(BMEditMesh *em, int axis, bool use_self, bool use_select, bool respecthide, bool use_topology, float maxdist, int *r_index)
void ED_mesh_mirror_spatial_table_end(Object *ob)
Read Guarded memory(de)allocation.
#define MEM_reallocN(vmemh, len)
#define BM_FACE_FIRST_LOOP(p)
void BM_elem_attrs_copy(BMesh *bm, const BMCustomDataCopyMap &map, const BMVert *src, BMVert *dst)
void BM_mesh_copy_init_customdata_all_layers(BMesh *bm_dst, BMesh *bm_src, const char htype, const BMAllocTemplate *allocsize)
BMFace * BM_face_copy(BMesh *bm_dst, const BMCustomDataCopyMap &cd_face_map, const BMCustomDataCopyMap &cd_loop_map, BMFace *f, const bool copy_verts, const bool copy_edges)
#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_enable(ele, hflag)
void BM_face_interp_multires_ex(BMesh *bm, BMFace *f_dst, const BMFace *f_src, const float f_dst_center[3], const float f_src_center[3], const int cd_loop_mdisp_offset)
void BM_vert_loop_groups_data_layer_merge(BMesh *bm, LinkNode *groups, const int layer_n)
void BM_vert_loop_groups_data_layer_merge_weights(BMesh *bm, LinkNode *groups, const int layer_n, const float *loop_weights)
void BM_loop_interp_from_face(BMesh *bm, BMLoop *l_dst, const BMFace *f_src, const bool do_vertex, const bool do_multires)
LinkNode * BM_vert_loop_groups_data_layer_create(BMesh *bm, BMVert *v, const int layer_n, const float *loop_weights, MemArena *arena)
int BM_iter_mesh_count_flag(const char itype, BMesh *bm, const char hflag, const bool value)
Mesh Iter Flag Count.
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)
#define BM_iter_init(iter, bm, itype, data)
#define BM_ITER_ELEM_INDEX(ele, iter, data, itype, indexvar)
ATTR_WARN_UNUSED_RESULT BMesh const char itype
ATTR_WARN_UNUSED_RESULT BMesh * bm
void BM_editselection_center(BMEditSelection *ese, float r_center[3])
void BM_editselection_plane(BMEditSelection *ese, float r_plane[3])
void BM_editselection_normal(BMEditSelection *ese, float r_normal[3])
void BM_mesh_elem_hflag_disable_all(BMesh *bm, const char htype, const char hflag, const bool respecthide)
const BMAllocTemplate bm_mesh_allocsize_default
void bmesh_edit_begin(BMesh *, BMOpTypeFlag)
BMesh Begin Edit.
void BM_mesh_free(BMesh *bm)
BMesh Free Mesh.
void BM_mesh_elem_table_ensure(BMesh *bm, const char htype)
void BM_mesh_elem_index_ensure(BMesh *bm, const char htype)
void bmesh_edit_end(BMesh *bm, BMOpTypeFlag type_flag)
BMesh End Edit.
BMesh * BM_mesh_create(const BMAllocTemplate *allocsize, const BMeshCreateParams *params)
BMesh Make Mesh.
BLI_INLINE BMVert * BM_vert_at_index(BMesh *bm, const int index)
void BM_mesh_normals_update_with_partial_ex(BMesh *, const BMPartialUpdate *bmpinfo, const BMeshNormalsUpdate_Params *params)
BMPartialUpdate * BM_mesh_partial_create_from_verts(BMesh *bm, const BMPartialUpdate_Params *params, const BLI_bitmap *verts_mask, const int verts_mask_count)
BMPartialUpdate * BM_mesh_partial_create_from_verts_group_multi(BMesh *bm, const BMPartialUpdate_Params *params, const int *verts_group, const int verts_group_count)
BMPartialUpdate * BM_mesh_partial_create_from_verts_group_single(BMesh *bm, const BMPartialUpdate_Params *params, const BLI_bitmap *verts_mask, const int verts_mask_count)
void BM_mesh_partial_destroy(BMPartialUpdate *bmpinfo)
@ BMO_OPTYPE_FLAG_UNTAN_MULTIRES
bool BM_vert_calc_normal_ex(const BMVert *v, const char hflag, float r_no[3])
void BM_face_calc_center_median(const BMFace *f, float r_cent[3])
int BM_mesh_calc_face_groups(BMesh *bm, int *r_groups_array, int(**r_group_index)[2], BMLoopFilterFunc filter_fn, BMLoopPairFilterFunc filter_pair_fn, void *user_data, const char hflag_test, const char htype_step)
float BM_vert_calc_shell_factor_ex(const BMVert *v, const float no[3], const char hflag)
BMLoop * BM_loop_find_next_nodouble(BMLoop *l, BMLoop *l_stop, const float eps_sq)
BMEdge * BM_edge_exists(BMVert *v_a, BMVert *v_b)
void BM_loop_calc_face_direction(const BMLoop *l, float r_dir[3])
BM_loop_calc_face_direction.
int BM_mesh_calc_edge_groups(BMesh *bm, int *r_groups_array, int(**r_group_index)[2], BMVertFilterFunc filter_fn, void *user_data, const char hflag_test)
bool BM_vert_is_edge_pair(const BMVert *v)
bool BM_vert_is_boundary(const BMVert *v)
BMLoop * BM_loop_find_prev_nodouble(BMLoop *l, BMLoop *l_stop, const float eps_sq)
BLI_INLINE bool BM_edge_is_manifold(const BMEdge *e) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL()
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()
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
static DBVT_INLINE btScalar size(const btDbvtVolume &a)
IndexRange index_range() const
void append(const T &value)
void reserve(const int64_t min_capacity)
Span< T > as_span() const
draw_view in_light_buf[] float
draw_view push_constant(Type::INT, "radiance_src") .push_constant(Type capture_info_buf storage_buf(1, Qualifier::READ, "ObjectBounds", "bounds_buf[]") .push_constant(Type draw_view int
void *(* MEM_mallocN)(size_t len, const char *str)
void MEM_freeN(void *vmemh)
void *(* MEM_callocN)(size_t len, const char *str)
bool shape_key_report_if_locked(const Object *obedit, ReportList *reports)
T distance(const T &a, const T &b)
T dot(const QuaternionBase< T > &a, const QuaternionBase< T > &b)
T midpoint(const T &a, const T &b)
MatBase< T, NumCol, NumRow > normalize(const MatBase< T, NumCol, NumRow > &a)
VecBase< float, 3 > float3
blender::Array< std::array< BMLoop *, 3 > > looptris
struct BMLoop * radial_next
ePartialType for_looptris
struct ToolSettings * toolsettings
int customdatalayer_map_len
int * customdatalayer_map
TransCustomDataMergeGroup * data
struct TransCustomDataLayer::@569 merge_group
LinkNode ** cd_loop_groups
TransCustomDataLayer * cd_layer_correct
PartialTypeState partial_update_state_prev
TransCustomData_PartialUpdate partial_update[PARTIAL_TYPE_MAX]
void(* free_cb)(TransInfo *, TransDataContainer *tc, TransCustomData *custom_data)
TransCustomDataContainer custom
TransDataMirror * data_mirror
blender::float3 dir_side[2]
blender::Array< blender::float3x3, 0 > defmats
MirrorDataVert * vert_map