Blender
V3.3
|
#include "BLI_listbase.h"
#include "BLI_math.h"
#include "BLI_utildefines.h"
#include "bmesh.h"
#include "intern/bmesh_operators_private.h"
Go to the source code of this file.
Macros | |
#define | EDGE_MARK 4 |
#define | EDGE_OUT 8 |
#define | FACE_OUT 16 |
Functions | |
static void | bm_bridge_splice_loops (BMesh *bm, LinkData *el_a, LinkData *el_b, const float merge_factor) |
static void | bm_vert_loop_pair (BMesh *bm, BMVert *v1, BMVert *v2, BMLoop **l1, BMLoop **l2) |
static float | bm_edgeloop_offset_length (LinkData *el_a, LinkData *el_b, LinkData *el_b_first, const float len_max) |
static void | bm_bridge_best_rotation (struct BMEdgeLoopStore *el_store_a, struct BMEdgeLoopStore *el_store_b) |
static void | bm_face_edges_tag_out (BMesh *bm, BMFace *f) |
static bool | bm_edge_test_cb (BMEdge *e, void *bm_v) |
static void | bridge_loop_pair (BMesh *bm, struct BMEdgeLoopStore *el_store_a, struct BMEdgeLoopStore *el_store_b, const bool use_merge, const float merge_factor, const int twist_offset) |
void | bmo_bridge_loops_exec (BMesh *bm, BMOperator *op) |
Connect verts across faces (splits faces) and bridge tool.
Definition in file bmo_bridge.c.
#define EDGE_MARK 4 |
Definition at line 17 of file bmo_bridge.c.
#define EDGE_OUT 8 |
Definition at line 18 of file bmo_bridge.c.
#define FACE_OUT 16 |
Definition at line 19 of file bmo_bridge.c.
|
static |
Definition at line 86 of file bmo_bridge.c.
References BLI_listbase_rotate_first(), bm_edgeloop_offset_length(), BM_edgeloop_verts_get(), ListBase::first, len, LinkData::next, and NULL.
Referenced by bridge_loop_pair().
|
static |
Definition at line 22 of file bmo_bridge.c.
References BLI_assert, bm, BM_data_interp_from_verts(), BMO_op_exec(), BMO_op_finish(), BMO_op_init(), BMO_slot_get(), BMO_slot_map_elem_insert(), BMVert::co, LinkData::data, interp_v3_v3v3(), LinkData::next, and BMOperator::slots_in.
Referenced by bridge_loop_pair().
Definition at line 120 of file bmo_bridge.c.
References BMO_edge_flag_test, e, and EDGE_MARK.
Referenced by bmo_bridge_loops_exec().
|
static |
Definition at line 72 of file bmo_bridge.c.
References BLI_assert, LinkData::data, len, len_v3v3(), LinkData::next, NULL, and LinkData::prev.
Referenced by bm_bridge_best_rotation().
Definition at line 111 of file bmo_bridge.c.
References bm, BM_FACE_FIRST_LOOP, BMO_edge_flag_enable, BMLoop::e, EDGE_OUT, and BMLoop::next.
Referenced by bridge_loop_pair().
|
static |
Definition at line 49 of file bmo_bridge.c.
References bm, BM_edge_exists(), BM_iter_at_index(), BM_LOOPS_OF_VERT, e, l, BMLoop::next, BMLoop::v, v1, and v2.
Referenced by bridge_loop_pair().
void bmo_bridge_loops_exec | ( | BMesh * | bm, |
BMOperator * | op | ||
) |
Definition at line 544 of file bmo_bridge.c.
References bm, BM_EDGE, bm_edge_test_cb(), BM_edgeloop_length_get(), BM_FACE, BM_mesh_edgeloops_calc_center(), BM_mesh_edgeloops_calc_normal(), BM_mesh_edgeloops_calc_order(), BM_mesh_edgeloops_find(), BM_mesh_edgeloops_free(), BMO_ERROR_CANCEL, BMO_error_raise(), BMO_slot_bool_get(), BMO_slot_buffer_flag_enable(), BMO_slot_buffer_from_enabled_flag(), BMO_slot_float_get(), BMO_slot_int_get(), bridge_loop_pair(), count, EDGE_MARK, EDGE_OUT, FACE_OUT, ListBase::first, BMEdgeLoopStore::next, LinkData::next, NULL, BMOperator::slots_in, and BMOperator::slots_out.
|
static |
This is a corner case:
(loop a) (loop b) +--------+ +--------+
When loops are aligned to the direction between the loops values of 'dir_a/b' is degenerate, in this case compare the original directions (before they were corrected by 'el_dir'), see: T43013
Definition at line 125 of file bmo_bridge.c.
References add_v3_v3v3(), BLI_assert, BLI_listbase_rotate_first(), BLI_rfindlink(), bm, bm_bridge_best_rotation(), bm_bridge_splice_loops(), BM_CREATE_NOP, BM_EDGE, BM_edge_exists(), BM_edge_is_boundary(), BM_EDGELINK_NEXT, BM_edgeloop_calc_normal(), BM_edgeloop_calc_normal_aligned(), BM_edgeloop_center_get(), BM_edgeloop_copy(), BM_edgeloop_expand(), BM_edgeloop_flip(), BM_edgeloop_free(), BM_edgeloop_is_closed(), BM_edgeloop_length_get(), BM_edgeloop_normal_get(), BM_edgeloop_verts_get(), BM_elem_attrs_copy(), BM_elem_flag_enable, BM_elem_flag_set, BM_ELEM_TAG, BM_FACE, BM_face_create_verts(), bm_face_edges_tag_out(), BM_face_exists(), BM_FACE_FIRST_LOOP, BM_face_normal_update(), BM_iter_at_index(), BM_LOOPS_OF_VERT, BM_mesh_elem_hflag_disable_all(), bm_vert_loop_pair(), BMO_edge_flag_disable, BMO_face_flag_enable, BMO_ITER, BMO_op_exec(), BMO_op_finish(), BMO_op_initf(), BMO_slot_buffer_flag_enable(), BMO_slot_buffer_hflag_enable(), cross_v3_v3v3(), LinkData::data, dot_v3v3(), e, EDGE_OUT, ELEM, eps, BMLoop::f, fabsf, FACE_OUT, ListBase::first, is_zero_v3(), l_b, ListBase::last, len_squared_v3(), LIKELY, mod_i(), BMLoop::next, LinkData::next, normalize_v3_v3(), NULL, op_sub(), sub_v3_v3v3(), SWAP, BMesh::totface, and UNLIKELY.
Referenced by bmo_bridge_loops_exec().