42 return l->v ==
v ?
l->prev :
l->next;
52 if (l_iter->
prev->
v == v_prev) {
55 if (l_iter->
next->
v == v_prev) {
75 if (
l->prev->v == v_prev) {
84 if (
l->prev->v ==
v) {
98 if (
l->prev->e ==
e) {
108 if (v_a->
e && v_b->
e) {
124 bool (*test_fn)(
BMFace *,
void *user_data),
127 if (v_a->
e && v_b->
e) {
132 if (test_fn(f, user_data)) {
145 const bool allow_adjacent,
151 if (v_a->
e && v_b->
e) {
159 callback(f, l_a,
l_b, user_data))
175 BMLoop *l_cur_a =
nullptr, *l_cur_b =
nullptr;
178 if (v_a->
e && v_b->
e) {
183 if ((f_cur ==
nullptr) || (l_a->
f->
len < f_cur->
len)) {
203 BMLoop *l_cur_a =
nullptr, *l_cur_b =
nullptr;
206 if (e_a->
l && e_b->
l) {
211 if ((f_cur ==
nullptr) || (l_a->
f->
len < f_cur->
len)) {
242 const float *axis =
l->f->no;
248 const float *axis =
l->f->no;
262 BMLoop *l_cur_a =
nullptr, *l_cur_b =
nullptr;
265 if (v_a->
e && v_b->
e) {
268 float dot_best = -1.0f;
274 if (f_cur ==
nullptr) {
282 if (dot_best == -1.0f) {
287 if (
dot > dot_best) {
318#ifdef USE_BMESH_HOLES
320 for (lst = f->loops.first; lst; lst = lst->next)
323#ifdef USE_BMESH_HOLES
324 l_iter = l_first = lst->first;
329 if (l_iter->
v ==
v) {
332 }
while ((l_iter = l_iter->
next) != l_first);
342#ifdef USE_BMESH_HOLES
348 for (
i = 0;
i <
len;
i++) {
352#ifdef USE_BMESH_HOLES
353 for (lst = f->loops.first; lst; lst = lst->next)
357#ifdef USE_BMESH_HOLES
358 l_iter = l_first = lst->first;
368 }
while ((l_iter = l_iter->
next) != l_first);
371 for (
i = 0;
i <
len;
i++) {
382#ifdef USE_BMESH_HOLES
394 for (
i = 0;
i <
len;
i++) {
398#ifdef USE_BMESH_HOLES
399 for (lst = f->loops.first; lst; lst = lst->next)
403#ifdef USE_BMESH_HOLES
404 l_iter = l_first = lst->first;
418 }
while ((l_iter = l_iter->
next) != l_first);
421 for (
i = 0;
i <
len;
i++) {
431 const BMLoop *l_iter, *l_first;
433 l_iter = l_first =
e->l;
435 if (l_iter->
f == f) {
438 }
while ((l_iter = l_iter->
radial_next) != l_first);
452 l_other = (
l->e ==
e) ?
l :
l->prev;
456 if (l_other->
v ==
l->v) {
459 else if (l_other->
next->
v ==
l->v) {
460 l_other = l_other->
next;
473 if (
l->e == e_prev) {
476 else if (
l->prev->e == e_prev) {
510 }
while (l_a != e_first->
l);
531 }
while (l_a != e_first->
l);
644 l_iter = l_first =
e->l;
647 }
while ((l_iter = l_iter->
radial_next) != l_first);
660 l_iter = l_first =
e->l;
663 if (
count == count_max) {
666 }
while ((l_iter = l_iter->
radial_next) != l_first);
684 if (
v->e !=
nullptr) {
685 const BMEdge *e_iter, *e_first;
686 e_first = e_iter =
v->e;
688 if (e_iter->
l !=
nullptr) {
701 e_first = e_iter =
v->e;
715 BMEdge *e_iter, *e_first, *e_prev;
717 int loop_num = 0, loop_num_region = 0, boundary_num = 0;
719 if (
v->e ==
nullptr) {
725 e_first = e_iter =
v->e;
737 if (e_iter->
l->
v ==
v) {
752 if (boundary_num == 3) {
758 e_first = l_first->
e;
759 l_first = (l_first->
v ==
v) ? l_first : l_first->
next;
766 loop_num_region += 1;
769 return (loop_num == loop_num_region);
772#define LOOP_VISIT _FLAG_WALK
773#define EDGE_VISIT _FLAG_WALK
783 l_iter = l_first =
e->l;
785 if (l_iter->
v ==
v) {
795 else if (l_iter->
next->
v ==
v) {
808 }
while ((l_iter = l_iter->
radial_next) != l_first);
819 e_iter = e_first =
l->e;
824 l_iter = l_first = e_iter->
l;
826 if (l_iter->
v ==
l->v) {
830 }
while ((l_iter = l_iter->
radial_next) != l_first);
842 *r_loop_total = count_total;
859 int count, count_total;
861 return (
count == count_total);
870 BMLoop *l2 =
e->l->radial_next;
884 const int cd_loop_type,
885 const int cd_loop_offset)
889 if (
e->l &&
e->l->radial_next !=
e->l) {
890 const BMLoop *l_base_v1 =
e->l;
891 const BMLoop *l_base_v2 =
e->l->next;
894 const BMLoop *l_iter =
e->l->radial_next;
898 const void *l_iter_cd_v1;
899 const void *l_iter_cd_v2;
901 if (l_iter->
v == l_base_v1->
v) {
903 l_iter_v2 = l_iter->
next;
906 l_iter_v1 = l_iter->
next;
909 BLI_assert((l_iter_v1->
v == l_base_v1->
v) && (l_iter_v2->
v == l_base_v2->
v));
931 e_first = e_iter =
v->e;
989 }
while ((l_iter = l_iter->
next) != l_first);
1004 }
while ((l_iter = l_iter->
next) != l_first);
1020 }
while ((l_iter = l_iter->
next) != l_first);
1035 }
while ((l_iter = l_iter->
next) != l_first);
1051 if (e1->
l && e2->
l) {
1059 }
while (
l != e1->
l);
1069 if (e1->
l && e2->
l) {
1079 }
while (
l != e1->
l);
1086 return (e1->
v1 == e2->
v1 || e1->
v1 == e2->
v2 || e1->
v2 == e2->
v1 || e1->
v2 == e2->
v2);
1117 if (l_iter->
v ==
v) {
1120 }
while ((l_iter = l_iter->
next) != l_first);
1130 l_iter = l_first =
e->l;
1132 if (l_iter->
f == f) {
1135 }
while ((l_iter = l_iter->
radial_next) != l_first);
1147 *r_v1 = edge_loop->
v;
1148 *r_v2 = edge_loop->
next->
v;
1163 l_step = l_step->
prev;
1180 l_step = l_step->
next;
1192 float e_dir_prev[3];
1193 float e_dir_next[3];
1216 float v1[3],
v2[3], v_tmp[3];
1220 const float fac = ((
v2[0] == 0.0f) ?
1221 ((
v2[1] == 0.0f) ? ((
v2[2] == 0.0f) ? 0.0f : v1[2] /
v2[2]) :
1237 const float normal_fallback[3],
1238 float const (*vertexCos)[3],
1239 const float epsilon_sq,
1246 float v1[3],
v2[3], v_tmp[3];
1250 const float fac = ((
v2[0] == 0.0f) ?
1251 ((
v2[1] == 0.0f) ? ((
v2[2] == 0.0f) ? 0.0f : v1[2] /
v2[2]) :
1272 const float normal_fallback[3],
1273 float const (*vertexCos)[3],
1322 if (
compare_v3v3(v_prev, v_next, FLT_EPSILON * 10.0f) ==
false) {
1343 const BMLoop *l2 =
e->l->radial_next;
1354 const float imat3[3][3],
1355 const float fallback)
1359 const BMLoop *l2 =
e->l->radial_next;
1360 float no1[3], no2[3];
1383 BMLoop *l2 =
e->l->radial_next;
1435 float accum_shell = 0.0f;
1436 float accum_angle = 0.0f;
1441 accum_angle += face_angle;
1444 if (accum_angle != 0.0f) {
1445 return accum_shell / accum_angle;
1453 float accum_shell = 0.0f;
1454 float accum_angle = 0.0f;
1455 int tot_sel = 0, tot = 0;
1461 accum_angle += face_angle;
1467 if (accum_angle != 0.0f) {
1468 return accum_shell / accum_angle;
1471 if (tot != 0 && tot_sel == 0) {
1506 BMLoop *shortest_loop = l_first;
1510 if (len_sq <= shortest_len) {
1511 shortest_loop = l_iter;
1512 shortest_len = len_sq;
1514 }
while ((l_iter = l_iter->
next) != l_first);
1516 return shortest_loop;
1521 float len_max_sq = 0.0f;
1527 BMLoop *longest_loop = l_first;
1531 if (len_sq >= len_max_sq) {
1532 longest_loop = l_iter;
1533 len_max_sq = len_sq;
1535 }
while ((l_iter = l_iter->
next) != l_first);
1537 return longest_loop;
1556 if (
e->v1 == v_b ||
e->v2 == v_b) {
1574 if ((e_a = v_a->
e) && (e_b = v_b->
e)) {
1575 BMEdge *e_a_iter = e_a, *e_b_iter = e_b;
1611 if (
e->l !=
nullptr) {
1612 BMLoop *l_iter, *l_first;
1613 l_iter = l_first =
e->l;
1618 }
while ((l_iter = l_iter->
radial_next) != l_first);
1626 BMEdge *e_iter, *e_first;
1627 e_iter = e_first = varr[0]->
e;
1633 BMLoop *l_iter_radial, *l_first_radial;
1634 l_iter_radial = l_first_radial = e_iter->
l;
1637 if ((l_iter_radial->
v == varr[0]) && (l_iter_radial->
f->
len ==
len)) {
1642 if (l_iter_radial->
next->
v == varr[1]) {
1645 if (l_walk->
v != varr[i_walk]) {
1648 }
while ((
void)(l_walk = l_walk->
next), ++i_walk !=
len);
1650 else if (l_iter_radial->
prev->
v == varr[1]) {
1653 if (l_walk->
v != varr[i_walk]) {
1656 }
while ((
void)(l_walk = l_walk->
prev), ++i_walk !=
len);
1659 if (i_walk ==
len) {
1660 return l_iter_radial->
f;
1663 }
while ((l_iter_radial = l_iter_radial->
radial_next) != l_first_radial);
1675 if (l_iter->f->len == l_first->
f->
len) {
1676 if (l_iter->v == l_first->
v) {
1677 BMLoop *l_a = l_first, *
l_b = l_iter, *l_b_init = l_iter;
1679 if (l_a->
e !=
l_b->e) {
1682 }
while (((
void)(l_a = l_a->
next), (
l_b =
l_b->next)) != l_b_init);
1683 if (
l_b == l_b_init) {
1688 BMLoop *l_a = l_first, *
l_b = l_iter, *l_b_init = l_iter;
1690 if (l_a->
e !=
l_b->e) {
1693 }
while (((
void)(l_a = l_a->
prev), (
l_b =
l_b->next)) != l_b_init);
1694 if (
l_b == l_b_init) {
1716 for (
i = 0;
i <
len;
i++) {
1734 for (
i = 0;
i <
len;
i++) {
1743 for (
i = 0;
i <
len;
i++) {
1775 for (
i = 0;
i <
len;
i++) {
1784 int tot_face_tag = 0;
1791 if (tot_face_tag != 2) {
1805 for (
i = 0;
i <
len;
i++) {
1830 BMFace *f_overlap =
nullptr;
1835 for (
i = 0;
i <
len;
i++) {
1842 for (
i = 0;
i <
len;
i++) {
1856 for (; f_lnk; f_lnk = f_lnk->
next) {
1867 bool is_init =
false;
1868 bool is_overlap =
false;
1873 for (
int i = 0;
i <
len;
i++) {
1881 for (
int i = 0;
i <
len;
i++) {
1885 BMLoop *l_iter, *l_first;
1887 if (is_init ==
false) {
1889 for (
int j = 0; j <
len; j++) {
1901 }
while ((l_iter = l_iter->
next) != l_first);
1913 if (is_init ==
true) {
1914 for (
int i = 0;
i <
len;
i++) {
1919 for (; f_lnk; f_lnk = f_lnk->
next) {
1965 BMLoop *l_iter, *l_first;
1967 l_iter = l_first =
e->l;
1974 }
while ((l_iter = l_iter->
radial_next) != l_first);
1983 BMLoop *l_iter, *l_first;
1985 l_iter = l_first =
e->l;
1990 }
while ((l_iter = l_iter->
radial_next) != l_first);
2011 }
while ((l_iter = l_iter->
next) != l_first);
2025 }
while ((l_iter = l_iter->
next) != l_first);
2032 BMLoop *l_iter, *l_first;
2034 l_iter = l_first =
e->l;
2039 }
while ((l_iter = l_iter->
radial_next) != l_first);
2047 const float eps = 0.0001f;
2061 const int tottri = f->
len - 2;
2068 for (
int j = 0; j < tottri; j++) {
2069 const float *p1 = loops[index[j][0]]->
v->
co;
2070 const float *p2 = loops[index[j][1]]->
v->
co;
2071 const float *p3 = loops[index[j][2]]->
v->
co;
2086 return (1.0 / 6.0) * vol;
2099 if (is_signed ==
false) {
2107 int *r_groups_array,
2108 int (**r_group_index)[2],
2112 const char hflag_test,
2113 const char htype_step)
2118 int group_index_len = 1;
2120 int group_index_len = 32;
2123 int (*group_index)[2] =
static_cast<int (*)[2]
>(
2124 MEM_mallocN(
sizeof(*group_index) * group_index_len, __func__));
2126 int *group_array = r_groups_array;
2165 while (tot_touch != tot_faces) {
2173 for (; f_next; f_next =
static_cast<BMFace *
>(BM_iter_step(&iter))) {
2186 if (group_index_len == group_curr) {
2187 group_index_len *= 2;
2188 group_index =
static_cast<int (*)[2]
>(
2189 MEM_reallocN(group_index,
sizeof(*group_index) * group_index_len));
2192 group_item = group_index[group_curr];
2197 BMLoop *l_iter, *l_first;
2210 if ((l_radial_iter != l_iter) &&
2211 ((filter_fn ==
nullptr) || filter_fn(l_iter, user_data)))
2214 if ((filter_pair_fn ==
nullptr) || filter_pair_fn(l_iter, l_radial_iter, user_data))
2216 BMFace *f_other = l_radial_iter->
f;
2222 }
while ((l_radial_iter = l_radial_iter->
radial_next) != l_iter);
2224 }
while ((l_iter = l_iter->
next) != l_first);
2232 if ((filter_fn ==
nullptr) || filter_fn(l_iter, user_data)) {
2235 if ((filter_pair_fn ==
nullptr) || filter_pair_fn(l_iter, l_other, user_data)) {
2244 }
while ((l_iter = l_iter->
next) != l_first);
2254 if (group_index_len != group_curr) {
2255 group_index =
static_cast<int (*)[2]
>(
2256 MEM_reallocN(group_index,
sizeof(*group_index) * group_curr));
2258 *r_group_index = group_index;
2264 int *r_groups_array,
2265 int (**r_group_index)[2],
2268 const char hflag_test)
2273 int group_index_len = 1;
2275 int group_index_len = 32;
2278 int (*group_index)[2] =
static_cast<int (*)[2]
>(
2279 MEM_mallocN(
sizeof(*group_index) * group_index_len, __func__));
2281 int *group_array = r_groups_array;
2317 while (tot_touch != tot_edges) {
2325 for (; e_next; e_next =
static_cast<BMEdge *
>(BM_iter_step(&iter))) {
2338 if (group_index_len == group_curr) {
2339 group_index_len *= 2;
2340 group_index =
static_cast<int (*)[2]
>(
2341 MEM_reallocN(group_index,
sizeof(*group_index) * group_index_len));
2344 group_item = group_index[group_curr];
2361 if ((filter_fn ==
nullptr) || filter_fn(
v, user_data)) {
2379 if (group_index_len != group_curr) {
2380 group_index =
static_cast<int (*)[2]
>(
2381 MEM_reallocN(group_index,
sizeof(*group_index) * group_curr));
2383 *r_group_index = group_index;
2426 if (v_stack_init->
e !=
nullptr) {
2427 BMVert *v_iter = v_stack_init;
2429 BMEdge *e_iter, *e_first;
2430 e_iter = e_first = v_iter->
e;
2436 if (e_iter->
l !=
nullptr) {
2437 BMLoop *l_iter, *l_first;
2438 l_iter = l_first = e_iter->
l;
2444 }
while ((l_iter = l_iter->
radial_next) != l_first);
2477 val = 3.0f * val * val - 2.0f * val * val * val;
2480 val =
sqrtf(2.0f * val - val * val);
2491 val = val * (2.0f - val);
CustomData interface, see also DNA_customdata_types.h.
bool CustomData_data_equals(eCustomDataType type, const void *data1, const void *data2)
#define BLI_array_alloca(arr, realsize)
#define BLI_linklist_prepend_alloca(listp, ptr)
MINLINE float shell_v3v3_normalized_to_dist(const float a[3], const float b[3])
float dist_signed_squared_to_plane_v3(const float p[3], const float plane[4])
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_transposed_m3_v3(const float M[3][3], float r[3])
MINLINE float len_squared_v3(const float v[3]) ATTR_WARN_UNUSED_RESULT
MINLINE float len_v3v3(const float a[3], const float b[3]) ATTR_WARN_UNUSED_RESULT
MINLINE void sub_v3_v3(float r[3], const float a[3])
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])
MINLINE double dot_v3v3_db(const double a[3], const double b[3]) ATTR_WARN_UNUSED_RESULT
MINLINE float dot_v3v3(const float a[3], const float b[3]) ATTR_WARN_UNUSED_RESULT
MINLINE void add_v3_v3v3(float r[3], const float a[3], const float b[3])
MINLINE void cross_v3_v3v3(float r[3], const float a[3], const float b[3])
MINLINE void negate_v3(float r[3])
MINLINE void copy_v3db_v3fl(double r[3], const float a[3])
MINLINE bool compare_v3v3(const float v1[3], const float v2[3], float limit) ATTR_WARN_UNUSED_RESULT
MINLINE bool is_zero_v3(const float v[3]) ATTR_WARN_UNUSED_RESULT
MINLINE void cross_v3_v3v3_db(double r[3], const double a[3], const double b[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)
float angle_normalized_v3v3(const float v1[3], const float v2[3]) ATTR_WARN_UNUSED_RESULT
MINLINE float normalize_v3(float n[3])
#define UNUSED_VARS_NDEBUG(...)
#define STACK_PUSH(stack, val)
#define STACK_DECLARE(stack)
#define STACK_SIZE(stack)
#define STACK_INIT(stack, stack_num)
#define STACK_PUSH_RET(stack)
static double angle(const Eigen::Vector3d &v1, const Eigen::Vector3d &v2)
Read Guarded memory(de)allocation.
#define MEM_reallocN(vmemh, len)
#define BM_DISK_EDGE_NEXT(e, v)
bool(*)(const BMLoop *, void *user_data) BMLoopFilterFunc
#define BM_FACE_FIRST_LOOP(p)
bool(*)(const BMVert *, void *user_data) BMVertFilterFunc
bool(*)(const BMLoop *, const BMLoop *, void *user_data) BMLoopPairFilterFunc
#define BM_ELEM_CD_GET_VOID_P(ele, offset)
bool BM_verts_from_edges(BMVert **vert_arr, BMEdge **edge_arr, const int len)
#define BM_elem_index_get(ele)
#define BM_elem_flag_disable(ele, hflag)
#define BM_elem_index_set(ele, index)
#define BM_elem_flag_test(ele, hflag)
#define BM_elem_flag_enable(ele, hflag)
#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_ELEM_INDEX(ele, iter, data, itype, indexvar)
#define BM_iter_new(iter, bm, itype, data)
void BM_mesh_elem_hflag_disable_all(BMesh *bm, const char htype, const char hflag, const bool respecthide)
float BM_face_calc_normal_subset(const BMLoop *l_first, const BMLoop *l_last, float r_no[3])
float BM_face_calc_normal(const BMFace *f, float r_no[3])
BMESH UPDATE FACE NORMAL.
void BM_face_calc_tessellation(const BMFace *f, const bool use_fixed_quad, BMLoop **r_loops, uint(*r_index)[3])
#define BM_ELEM_API_FLAG_DISABLE(element, f)
#define BM_ELEM_API_FLAG_TEST(element, f)
int bmesh_disk_count_at_most(const BMVert *v, int count_max)
#define BM_ELEM_API_FLAG_ENABLE(element, f)
int bmesh_disk_count(const BMVert *v)
BMLoop * BM_loop_other_edge_loop(BMLoop *l, BMVert *v)
bool BM_face_share_face_check(BMFace *f_a, BMFace *f_b)
float BM_vert_calc_edge_angle(const BMVert *v)
BMVert * BM_edge_share_vert(BMEdge *e1, BMEdge *e2)
int BM_mesh_calc_edge_groups_as_arrays(BMesh *bm, BMVert **verts, BMEdge **edges, BMFace **faces, int(**r_groups)[3])
float BM_loop_calc_face_normal_safe(const BMLoop *l, float r_normal[3])
int BM_edge_face_count_at_most(const BMEdge *e, const int count_max)
float BM_loop_point_side_of_loop_test(const BMLoop *l, const float co[3])
void BM_edge_ordered_verts_ex(const BMEdge *edge, BMVert **r_v1, BMVert **r_v2, const BMLoop *edge_loop)
bool BM_vert_is_wire(const BMVert *v)
bool BM_edge_is_contiguous_loop_cd(const BMEdge *e, const int cd_loop_type, const int cd_loop_offset)
bool BM_edge_is_all_face_flag_test(const BMEdge *e, const char hflag, const bool respect_hide)
BMLoop * BM_face_other_edge_loop(BMFace *f, BMEdge *e, BMVert *v)
Other Loop in Face Sharing an Edge.
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)
void BM_edge_ordered_verts(const BMEdge *edge, BMVert **r_v1, BMVert **r_v2)
bool BM_edge_share_quad_check(BMEdge *e1, BMEdge *e2)
int BM_vert_edge_count_at_most(const BMVert *v, const int count_max)
float BM_edge_calc_face_angle(const BMEdge *e)
bool BM_face_exists_multi(BMVert **varr, BMEdge **earr, int len)
bool BM_vert_pair_share_face_check(BMVert *v_a, BMVert *v_b)
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)
bool BM_edge_in_face(const BMEdge *e, const BMFace *f)
bool BM_face_is_any_edge_flag_test(const BMFace *f, const char hflag)
float BM_loop_calc_face_normal_safe_vcos(const BMLoop *l, const float normal_fallback[3], float const (*vertexCos)[3], float r_normal[3])
bool BM_edge_is_any_face_len_test(const BMEdge *e, const int len)
bool BM_face_exists_multi_edge(BMEdge **earr, int len)
bool BM_face_share_edge_check(BMFace *f_a, BMFace *f_b)
bool BM_loop_share_edge_check(BMLoop *l_a, BMLoop *l_b)
bool BM_face_is_any_vert_flag_test(const BMFace *f, const char hflag)
BMLoop * BM_vert_step_fan_loop(BMLoop *l, BMEdge **e_step)
float BM_vert_calc_median_tagged_edge_length(const BMVert *v)
BMLoop * BM_loop_find_next_nodouble(BMLoop *l, BMLoop *l_stop, const float eps_sq)
static int bm_loop_region_count__recursive(BMEdge *e, BMVert *v)
bool BM_vert_is_manifold_region(const BMVert *v)
void BM_loop_calc_face_tangent(const BMLoop *l, float r_tangent[3])
BM_loop_calc_face_tangent.
bool BM_edge_loop_pair(BMEdge *e, BMLoop **r_la, BMLoop **r_lb)
bool BM_vert_is_all_edge_flag_test(const BMVert *v, const char hflag, const bool respect_hide)
BMFace * BM_face_exists(BMVert *const *varr, int len)
bool BM_vert_is_manifold(const BMVert *v)
BMLoop * BM_face_find_shortest_loop(BMFace *f)
float BM_loop_calc_face_normal_safe_vcos_ex(const BMLoop *l, const float normal_fallback[3], float const (*vertexCos)[3], const float epsilon_sq, float r_normal[3])
int BM_face_share_vert_count(BMFace *f_a, BMFace *f_b)
int BM_face_share_edge_count(BMFace *f_a, BMFace *f_b)
bool BM_face_share_vert_check(BMFace *f_a, BMFace *f_b)
float BM_edge_calc_face_angle_with_imat3_ex(const BMEdge *e, const float imat3[3][3], const float fallback)
BMESH EDGE/FACE ANGLE.
float BM_edge_calc_length_squared(const BMEdge *e)
bool BM_edge_face_pair(BMEdge *e, BMFace **r_fa, BMFace **r_fb)
float BM_edge_calc_face_angle_signed(const BMEdge *e)
float BM_loop_calc_face_normal_safe_ex(const BMLoop *l, const float epsilon_sq, float r_normal[3])
BM_loop_calc_face_normal.
BMEdge * BM_vert_other_disk_edge(BMVert *v, BMEdge *e_first)
BMLoop * BM_edge_vert_share_loop(BMLoop *l, BMVert *v)
Return the Loop Shared by Edge and Vert.
float bmesh_subd_falloff_calc(const int falloff, float val)
BMEdge * BM_edge_find_double(BMEdge *e)
bool BM_edge_share_vert_check(BMEdge *e1, BMEdge *e2)
float BM_vert_calc_shell_factor(const BMVert *v)
bool BM_face_is_normal_valid(const BMFace *f)
BMEdge * BM_edge_exists(BMVert *v_a, BMVert *v_b)
BMFace * BM_vert_pair_shared_face_cb(BMVert *v_a, BMVert *v_b, const bool allow_adjacent, bool(*callback)(BMFace *, BMLoop *, BMLoop *, void *userdata), void *user_data, BMLoop **r_l_a, BMLoop **r_l_b)
BMFace * BM_face_find_double(BMFace *f)
int BM_vert_face_count(const BMVert *v)
BMLoop * BM_vert_find_first_loop(BMVert *v)
int BM_edge_face_count(const BMEdge *e)
BMLoop * BM_edge_find_first_loop_visible(BMEdge *e)
BMLoop * BM_edge_other_loop(BMEdge *e, BMLoop *l)
float BM_vert_calc_edge_angle_ex(const BMVert *v, const float fallback)
BMESH VERT/EDGE ANGLE.
bool BM_verts_in_face(BMVert **varr, int len, BMFace *f)
BMFace * BM_vert_pair_share_face_by_angle(BMVert *v_a, BMVert *v_b, BMLoop **r_l_a, BMLoop **r_l_b, const bool allow_adjacent)
static float bm_face_calc_split_dot(BMLoop *l_a, BMLoop *l_b)
BMLoop * BM_face_find_longest_loop(BMFace *f)
BMLoop * BM_face_other_vert_loop(BMFace *f, BMVert *v_prev, BMVert *v)
Other Loop in Face Sharing a Vertex.
void BM_loop_calc_face_direction(const BMLoop *l, float r_dir[3])
BM_loop_calc_face_direction.
bool BM_edge_share_face_check(BMEdge *e1, BMEdge *e2)
int BM_loop_region_loops_count(BMLoop *l)
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)
int BM_loop_region_loops_count_at_most(BMLoop *l, int *r_loop_total)
bool BM_vert_in_face(BMVert *v, BMFace *f)
bool BM_edge_is_any_vert_flag_test(const BMEdge *e, const char hflag)
BMFace * BM_vert_pair_share_face_by_len(BMVert *v_a, BMVert *v_b, BMLoop **r_l_a, BMLoop **r_l_b, const bool allow_adjacent)
BMLoop * BM_loop_other_vert_loop_by_edge(BMLoop *l, BMEdge *e)
float BM_edge_calc_length(const BMEdge *e)
float BM_edge_calc_face_angle_ex(const BMEdge *e, const float fallback)
BMESH EDGE/FACE ANGLE.
int BM_vert_edge_count(const BMVert *v)
bool BM_loop_is_convex(const BMLoop *l)
double BM_mesh_calc_volume(BMesh *bm, bool is_signed)
static int bm_loop_region_count__clear(BMLoop *l)
float BM_edge_calc_face_angle_with_imat3(const BMEdge *e, const float imat3[3][3])
float BM_loop_calc_face_angle(const BMLoop *l)
bool BM_vert_face_check(const BMVert *v)
static double bm_mesh_calc_volume_face(const BMFace *f)
bool BM_vert_is_edge_pair(const BMVert *v)
BMLoop * BM_face_edge_share_loop(BMFace *f, BMEdge *e)
Return the Loop Shared by Face and Edge.
int BM_vert_face_count_at_most(const BMVert *v, int count_max)
float BM_edge_calc_face_angle_signed_ex(const BMEdge *e, const float fallback)
BMESH EDGE/FACE ANGLE.
BMLoop * BM_vert_find_first_loop_visible(BMVert *v)
bool BM_vert_is_edge_pair_manifold(const BMVert *v)
int BM_face_share_face_count(BMFace *f_a, BMFace *f_b)
BMFace * BM_face_exists_overlap(BMVert **varr, const int len)
void BM_edge_calc_face_tangent(const BMEdge *e, const BMLoop *e_loop, float r_tangent[3])
BMESH EDGE/FACE TANGENT.
float BM_loop_calc_face_normal(const BMLoop *l, float r_normal[3])
BM_loop_calc_face_normal.
bool BM_vert_is_boundary(const BMVert *v)
int BM_vert_edge_count_nonwire(const BMVert *v)
bool BM_edge_is_convex(const BMEdge *e)
bool BM_vert_edge_pair(const BMVert *v, BMEdge **r_e_a, BMEdge **r_e_b)
BMLoop * BM_loop_other_vert_loop(BMLoop *l, BMVert *v)
Other Loop in Face Sharing a Vert.
bool BM_vert_is_all_face_flag_test(const BMVert *v, const char hflag, const bool respect_hide)
BMLoop * BM_loop_find_prev_nodouble(BMLoop *l, BMLoop *l_stop, const float eps_sq)
int BM_verts_in_face_count(BMVert **varr, int len, BMFace *f)
BMLoop * BM_face_vert_share_loop(BMFace *f, BMVert *v)
Return the Loop Shared by Face and Vertex.
bool BM_edge_is_any_face_flag_test(const BMEdge *e, const char hflag)
bool BM_face_exists_overlap_subset(BMVert **varr, const int len)
float BM_loop_point_side_of_edge_test(const BMLoop *l, const float co[3])
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_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 bool BM_loop_is_adjacent(const BMLoop *l_a, const BMLoop *l_b) 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_vert_in_edge(const 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 BMLoop * l_b
ATTR_WARN_UNUSED_RESULT const BMVert * v
BMLoop * bmesh_disk_faceloop_find_first_visible(const BMEdge *e, const BMVert *v)
BMLoop * bmesh_disk_faceloop_find_first(const BMEdge *e, const BMVert *v)
int bmesh_disk_facevert_count(const BMVert *v)
DISK COUNT FACE VERT.
int bmesh_disk_facevert_count_at_most(const BMVert *v, const int count_max)
BLI_INLINE BMEdge * bmesh_disk_edge_next(const BMEdge *e, const BMVert *v) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL()
dot(value.rgb, luminance_coefficients)") DEFINE_VALUE("REDUCE(lhs
VecBase< float, 3 > cross(VecOp< float, 3 >, VecOp< float, 3 >) RET
float length(VecOp< float, D >) RET
void * MEM_mallocN(size_t len, const char *str)
void * MEM_malloc_arrayN(size_t len, size_t size, const char *str)
void MEM_freeN(void *vmemh)
ccl_device_inline float2 fabs(const float2 a)
struct BMLoop * radial_next