|
Blender V4.5
|
#include "BLI_compiler_attrs.h"#include "BLI_compiler_compat.h"#include "bmesh_class.hh"#include "bmesh_query_inline.hh"Go to the source code of this file.
Macros | |
| #define | BM_vert_edge_count_is_equal(v, n) |
| #define | BM_vert_edge_count_is_over(v, n) |
| #define | BM_edge_face_count_is_equal(e, n) |
| #define | BM_edge_face_count_is_over(e, n) |
| #define | BM_vert_face_count_is_equal(v, n) |
| #define | BM_vert_face_count_is_over(v, n) |
| #define BM_edge_face_count_is_equal | ( | e, | |
| n ) |
Definition at line 253 of file bmesh_query.hh.
Referenced by bm_edge_update_beauty_cost(), BM_mesh_beautify_fill(), and bmw_NonManifoldLoop_find_next_around_vertex().
| #define BM_edge_face_count_is_over | ( | e, | |
| n ) |
Definition at line 254 of file bmesh_query.hh.
Referenced by BM_faces_join(), edbm_loop_multiselect_exec(), EDBM_select_interior_faces(), edbm_select_non_manifold_exec(), and mouse_mesh_loop_edge().
| #define BM_vert_edge_count_is_equal | ( | v, | |
| n ) |
Definition at line 245 of file bmesh_query.hh.
Referenced by bmesh_kernel_unglue_region_make_vert(), edbm_rip_invoke__vert(), is_vertex_pole(), and is_vertex_pole_three().
| #define BM_vert_edge_count_is_over | ( | v, | |
| n ) |
Definition at line 246 of file bmesh_query.hh.
Referenced by bpy_bm_utils_vert_collapse_edge(), bpy_bm_utils_vert_collapse_faces(), is_vertex_pole(), and blender::bke::pbvh::pbvh_bmesh_split_edge().
| #define BM_vert_face_count_is_equal | ( | v, | |
| n ) |
Definition at line 261 of file bmesh_query.hh.
Referenced by BM_vert_dissolve(), edbm_rip_invoke__vert(), and blender::bke::pbvh::pbvh_bmesh_face_remove().
| #define BM_vert_face_count_is_over | ( | v, | |
| n ) |
Definition at line 262 of file bmesh_query.hh.
| float BM_edge_calc_face_angle | ( | const BMEdge * | e | ) |
Definition at line 1348 of file bmesh_query.cc.
References BM_edge_calc_face_angle(), BM_edge_calc_face_angle_ex(), DEG2RADF, and e.
Referenced by BM_edge_calc_face_angle(), BM_loop_is_adjacent(), and bm_vert_edge_face_angle().
| float BM_edge_calc_face_angle_ex | ( | const BMEdge * | e, |
| float | fallback ) |
BMESH EDGE/FACE ANGLE.
Calculates the angle between two faces. Assumes the face normals are correct.
Definition at line 1339 of file bmesh_query.cc.
References angle_normalized_v3v3(), BM_edge_calc_face_angle_ex(), BM_edge_is_manifold(), e, BMLoop::f, and BMFace::no.
Referenced by BM_edge_calc_face_angle(), BM_edge_calc_face_angle_ex(), BM_loop_is_adjacent(), bpy_bmedge_calc_face_angle(), and edbm_beautify_fill_exec().
| float BM_edge_calc_face_angle_signed | ( | const BMEdge * | e | ) |
Definition at line 1389 of file bmesh_query.cc.
References BM_edge_calc_face_angle_signed(), BM_edge_calc_face_angle_signed_ex(), DEG2RADF, and e.
Referenced by BM_edge_calc_face_angle_signed(), BM_loop_is_adjacent(), and blender::draw::statvis_calc_sharp().
| float BM_edge_calc_face_angle_signed_ex | ( | const BMEdge * | e, |
| float | fallback ) |
BMESH EDGE/FACE ANGLE.
Calculates the angle between two faces. Assumes the face normals are correct.
Definition at line 1379 of file bmesh_query.cc.
References angle(), angle_normalized_v3v3(), BM_edge_calc_face_angle_signed_ex(), BM_edge_is_convex(), BM_edge_is_manifold(), e, BMLoop::f, and BMFace::no.
Referenced by BM_edge_calc_face_angle_signed(), BM_edge_calc_face_angle_signed_ex(), BM_loop_is_adjacent(), bpy_bmedge_calc_face_angle_signed(), and tri_corner_test().
| float BM_edge_calc_face_angle_with_imat3 | ( | const BMEdge * | e, |
| const float | imat3[3][3] ) |
Definition at line 1374 of file bmesh_query.cc.
References BM_edge_calc_face_angle_with_imat3(), BM_edge_calc_face_angle_with_imat3_ex(), DEG2RADF, and e.
Referenced by BM_edge_calc_face_angle_with_imat3(), BM_loop_is_adjacent(), and similar_edge_select_exec().
| float BM_edge_calc_face_angle_with_imat3_ex | ( | const BMEdge * | e, |
| const float | imat3[3][3], | ||
| float | fallback ) |
BMESH EDGE/FACE ANGLE.
Calculates the angle between two faces in world space. Assumes the face normals are correct.
Definition at line 1353 of file bmesh_query.cc.
References angle_normalized_v3v3(), BM_edge_calc_face_angle_with_imat3_ex(), BM_edge_is_manifold(), copy_v3_v3(), e, BMLoop::f, mul_transposed_m3_v3(), BMFace::no, and normalize_v3().
Referenced by BM_edge_calc_face_angle_with_imat3(), BM_edge_calc_face_angle_with_imat3_ex(), and BM_loop_is_adjacent().
BMESH EDGE/FACE TANGENT.
Calculate the tangent at this loop corner or fallback to the face normal on straight lines. This vector always points inward into the face.
BM_edge_calc_face_tangent
| e | |
| e_loop | The loop to calculate the tangent at, used to get the face and winding direction. |
| r_tangent | The loop corner tangent to set |
Definition at line 1394 of file bmesh_query.cc.
References BM_edge_calc_face_tangent(), BM_edge_ordered_verts_ex(), BMVert::co, cross_v3_v3v3(), e, BMLoop::f, BMFace::no, normalize_v3(), sub_v3_v3v3(), and v2.
Referenced by BM_edge_calc_face_tangent(), BM_loop_is_adjacent(), bm_vert_boundary_tangent(), bm_vert_calc_surface_tangent(), bmo_face_inset_individual(), bmo_inset_region_exec(), and bpy_bmedge_calc_tangent().
| float BM_edge_calc_length | ( | const BMEdge * | e | ) |
Returns edge length
Definition at line 536 of file bmesh_query.cc.
References BM_edge_calc_length(), e, and len_v3v3().
Referenced by bevel_vert_construct(), bm_decim_build_edge_cost_single(), BM_edge_calc_length(), BM_face_calc_center_median_weighted(), bm_interior_face_group_calc_cost(), BM_vert_calc_median_tagged_edge_length(), BM_verts_in_edge(), bmo_face_inset_individual(), bmo_inset_region_exec(), edbm_calc_loop_co(), EDBM_select_interior_faces(), geometry_collide_offset(), offset_meet_lines_percent_or_absolute(), and vertex_collide_offset().
| float BM_edge_calc_length_squared | ( | const BMEdge * | e | ) |
Returns edge length squared (for comparisons)
Definition at line 541 of file bmesh_query.cc.
References BM_edge_calc_length_squared(), e, and len_squared_v3v3().
Referenced by BM_edge_calc_length_squared(), bm_edge_calc_rotate_cost(), bm_edge_length_cmp(), bm_edge_sort_length_cb(), BM_verts_in_edge(), bmo_dissolve_degenerate_exec(), edbm_polybuild_face_at_cursor_invoke(), blender::ed::transform::getTransformOrientation_ex(), blender::bke::pbvh::long_edge_queue_edge_add(), blender::bke::pbvh::long_edge_queue_edge_add_recursive(), blender::bke::pbvh::long_edge_queue_face_add(), blender::bke::pbvh::long_edge_queue_priority(), blender::bke::pbvh::short_edge_queue_edge_add(), and blender::bke::pbvh::short_edge_queue_priority().
Returns the edge existing between v_a and v_b, or nullptr if there isn't one.
Definition at line 1564 of file bmesh_query.cc.
References BLI_assert, BM_edge_exists(), BM_VERT, BM_vert_in_edge(), bmesh_disk_edge_next(), BMVert::e, BMVert::head, and BMHeader::htype.
Referenced by bev_rebuild_polygon(), bevel_build_edge_polygons(), BKE_mesh_remesh_voxel_fix_poles(), BM_edge_create(), BM_edge_exists(), BM_edge_rotate(), BM_edge_rotate_check_degenerate(), BM_edgeloop_edges_get(), bm_edgeloop_flag_set(), bm_edgenet_path_calc_best(), bm_edgering_pair_order(), bm_edgering_pair_order_is_flipped(), BM_edges_from_verts(), bm_face_connect_verts(), BM_face_create_ngon_verts(), BM_face_other_vert_loop(), bm_face_split_edge_find(), BM_face_split_edgenet_connect_islands(), bm_grid_fill(), bm_isect_edge_tri(), bm_isect_tri_tri(), BM_loop_is_adjacent(), bm_loop_pair_from_verts(), BM_mesh_intersect(), BM_mesh_intersect_edges(), BM_mesh_wireframe(), bm_vert_connect_select_history(), bm_vert_loop_pair(), BM_vert_splice_check_double(), bmesh_kernel_join_edge_kill_vert(), bmesh_kernel_join_vert_kill_edge(), bmo_extrude_face_region_exec(), bmo_subdivide_edges_exec(), bmo_triangle_fill_exec(), bmo_weld_verts_exec(), bmw_EdgeLoopWalker_step(), bpy_bm_utils_vert_splice(), bpy_bmedgeseq_get__method(), bpy_bmedgeseq_new(), bridge_loop_pair(), build_hull(), edbm_add_edge_face_exec__tricky_extend_sel(), EDBM_verts_mirror_get_edge(), blender::ed::transform::getTransformOrientation_ex(), is_vertex_diagonal(), knife_add_single_cut(), knife_make_face_cuts(), blender::bke::pbvh::merge_face_edge_data(), blender::bke::pbvh::merge_flap_edge_data(), blender::bke::pbvh::pbvh_bmesh_collapse_short_edges(), blender::bke::pbvh::pbvh_bmesh_subdivide_long_edges(), remdoubles_createface(), blender::ed::transform::transform_mesh_edge_slide_data_create(), and weld_cross_attrs_copy().
| int BM_edge_face_count | ( | const BMEdge * | e | ) |
Returns the number of faces around this edge
Definition at line 637 of file bmesh_query.cc.
References BM_edge_face_count(), e, and BMLoop::radial_next.
Referenced by bevel_vert_construct(), BKE_mesh_remesh_voxel_fix_poles(), BM_edge_face_count(), bm_uidwalk_init_from_edge(), bmw_NonManifoldedgeWalker_begin(), bmw_NonManifoldedgeWalker_step(), find_bevel_edge_order(), blender::bke::pbvh::pbvh_bmesh_edge_loops(), similar_edge_select_exec(), blender::bke::pbvh::try_merge_flap_edge_data_before_dissolve(), and verg_radial().
| int BM_edge_face_count_at_most | ( | const BMEdge * | e, |
| int | count_max ) |
Definition at line 653 of file bmesh_query.cc.
References BM_edge_face_count_at_most(), e, and BMLoop::radial_next.
Referenced by BM_edge_face_count_at_most(), and similar_edge_select_exec().
Utility function, since enough times we have an edge and want to access 2 connected faces.
Definition at line 546 of file bmesh_query.cc.
References BM_edge_face_pair(), e, BMLoop::f, and BMLoop::radial_next.
Referenced by BM_edge_calc_rotate(), BM_edge_face_pair(), BM_edge_rotate(), BM_edge_rotate_check(), bm_face_split_by_edges_island_connect(), BM_verts_in_edge(), bmo_dissolve_edges_exec(), bmo_join_triangles_exec(), bmo_rotate_edges_exec(), bmo_vert_calc_edge_angle_blended(), edbm_edge_rotate_selected_exec(), and hull_merge_triangles().
Returns an edge sharing the same vertices as this one. This isn't an invalid state but tools should clean up these cases before returning the mesh to the user.
Definition at line 1592 of file bmesh_query.cc.
References BM_edge_find_double(), BM_vert_in_edge(), bmesh_disk_edge_next(), e, UNLIKELY, and v.
Referenced by bm_decim_edge_collapse(), BM_edge_find_double(), BM_face_split_edgenet_connect_islands(), BM_loop_is_adjacent(), BM_mesh_edgesplit(), and bmo_spin_exec().
Only BMEdge.l access us needed, however when we want the first visible loop, a utility function is needed.
Definition at line 1609 of file bmesh_query.cc.
References BM_edge_find_first_loop_visible(), BM_elem_flag_test, BM_ELEM_HIDDEN, e, BMLoop::f, and BMLoop::radial_next.
Referenced by BM_edge_find_first_loop_visible(), and BM_edge_other_vert().
Returns whether or not a given edge is part of a given face.
Definition at line 428 of file bmesh_query.cc.
References BM_edge_in_face(), e, BMLoop::f, and BMLoop::radial_next.
Referenced by BM_edge_in_face(), BM_edge_share_face_check(), BM_edge_share_quad_check(), BM_face_share_edge_check(), BM_face_share_edge_count(), BM_face_split_edgenet(), bm_face_split_edgenet_partial_connect(), bm_isect_tri_tri(), bm_loop_customdata_merge(), bm_ray_cast_cb_elem_not_in_face_check(), bm_vert_pair_best_face_get(), bmesh_kernel_join_face_kill_edge(), edge_ray_cast(), edgering_find_order(), face_edges_add(), knife_calculate_snap_ref_edges(), knife_make_face_cuts(), knife_snap_angle_relative(), blender::bke::pbvh::merge_flap_edge_data(), blender::draw::mesh_render_data_edge_flag(), multires_unsubdivide_extract_single_grid_from_face_edge(), blender::bke::pbvh::pbvh_bmesh_collapse_edge(), and test_tagged_and_notface().
| BLI_INLINE bool BM_edge_in_loop | ( | const BMEdge * | e, |
| const BMLoop * | l ) |
References ATTR_NONNULL, ATTR_WARN_UNUSED_RESULT, BLI_INLINE, BM_edge_in_loop(), e, and l.
Referenced by BM_edge_in_loop(), and edbm_rip_invoke__vert().
| bool BM_edge_is_all_face_flag_test | ( | const BMEdge * | e, |
| char | hflag, | ||
| bool | respect_hide ) |
Definition at line 1962 of file bmesh_query.cc.
References BM_edge_is_all_face_flag_test(), BM_elem_flag_test, BM_ELEM_HIDDEN, e, BMLoop::f, and BMLoop::radial_next.
Referenced by BM_edge_is_all_face_flag_test(), BM_loop_is_adjacent(), bmw_edge_is_wire(), and EDBM_selectmode_convert().
| bool BM_edge_is_any_face_flag_test | ( | const BMEdge * | e, |
| char | hflag ) |
Definition at line 1980 of file bmesh_query.cc.
References BM_edge_is_any_face_flag_test(), BM_elem_flag_test, e, BMLoop::f, and BMLoop::radial_next.
Referenced by BM_edge_is_any_face_flag_test(), BM_loop_is_adjacent(), and edbm_select_linked_exec().
| bool BM_edge_is_any_face_len_test | ( | const BMEdge * | e, |
| int | len ) |
Definition at line 2029 of file bmesh_query.cc.
References BM_edge_is_any_face_len_test(), e, BMLoop::f, BMFace::len, len(), and BMLoop::radial_next.
Referenced by BM_edge_is_any_face_len_test(), BM_loop_is_adjacent(), EDBM_preselect_edgering_update_from_edge(), and ringsel_finish().
| bool BM_edge_is_any_vert_flag_test | ( | const BMEdge * | e, |
| char | hflag ) |
Definition at line 1996 of file bmesh_query.cc.
References BM_edge_is_any_vert_flag_test(), BM_elem_flag_test, and e.
Referenced by BM_edge_is_any_vert_flag_test(), BM_loop_is_adjacent(), and EDBM_selectmode_convert().
| BLI_INLINE bool BM_edge_is_boundary | ( | const BMEdge * | e | ) |
References ATTR_NONNULL, ATTR_WARN_UNUSED_RESULT, BLI_INLINE, BM_edge_is_boundary(), and e.
Referenced by bm_decim_build_edge_cost_single(), bm_decim_build_quadrics(), BM_disk_dissolve(), bm_edge_collapse(), BM_edge_is_boundary(), bm_edge_is_manifold_or_boundary(), bm_edge_is_single(), bm_edge_test_rail_cb(), BM_editselection_plane(), bm_extrude_region_edge_flag(), bm_face_is_loose(), bm_grid_fill(), bm_ray_cast_cb_elem_not_in_face_check(), bm_vert_dissolve_fan(), bm_vert_dissolve_fan_test(), BM_vert_is_boundary(), BM_vert_is_manifold(), bm_vert_is_manifold_flagged(), blender::ed::sculpt_paint::smooth::bmesh_four_neighbor_average(), bmesh_kernel_edge_separate(), bmesh_kernel_unglue_region_make_vert(), bmo_dissolve_verts_exec(), bmo_edge_copy(), bmo_extrude_face_region_exec(), bmo_inset_region_exec(), BMO_mesh_delete_oflag_context(), bmo_triangle_fill_exec(), bmw_EdgeboundaryWalker_begin(), bmw_EdgeboundaryWalker_step(), bmw_EdgeLoopWalker_begin(), bmw_EdgeLoopWalker_step(), bmw_FaceLoopWalker_edge_begins_loop(), bpy_bmedge_is_boundary_get(), bridge_loop_pair(), edbm_add_edge_face_exec__tricky_extend_sel(), edbm_bridge_tag_boundary_edges(), edbm_extrude_edge_exclude_mirror(), edbm_polybuild_face_at_cursor_invoke(), edbm_rip_invoke__vert(), edbm_select_loose_exec(), edbm_select_non_manifold_exec(), EDBM_unified_findnearest_from_raycast(), fill_laplacian_matrix(), geometry_extract_apply(), blender::ed::transform::getTransformOrientation_ex(), init_laplacian_matrix(), mouse_mesh_loop_edge(), blender::ed::transform::transform_mesh_edge_slide_data_create(), vert_is_boundary(), and view3d_preselect_update_preview_triangle_from_vert().
| BLI_INLINE bool BM_edge_is_contiguous | ( | const BMEdge * | e | ) |
References ATTR_NONNULL, ATTR_WARN_UNUSED_RESULT, BLI_INLINE, BM_edge_is_contiguous(), BM_edge_is_contiguous_loop_cd(), BM_edge_is_convex(), BM_loop_is_convex(), BM_loop_region_loops_count(), BM_loop_region_loops_count_at_most(), e, and l.
Referenced by bm_edge_calc_dissolve_error(), BM_edge_is_contiguous(), bm_edge_is_delimit(), bm_edge_is_delimiter(), BM_edge_rotate(), bm_face_split_by_concave(), bpy_bmedge_is_contiguous_get(), edbm_select_non_manifold_exec(), and select_linked_delimit_test().
| bool BM_edge_is_contiguous_loop_cd | ( | const BMEdge * | e, |
| int | cd_loop_type, | ||
| int | cd_loop_offset ) |
Definition at line 883 of file bmesh_query.cc.
References BLI_assert, BM_edge_is_contiguous_loop_cd(), BM_ELEM_CD_GET_VOID_P, CustomData_data_equals(), e, BMLoop::next, BMLoop::radial_next, and BMLoop::v.
Referenced by BM_edge_is_contiguous(), BM_edge_is_contiguous_loop_cd(), bm_edge_is_contiguous_loop_cd_all(), bm_edge_is_contiguous_loop_cd_all(), and select_linked_delimit_test().
| bool BM_edge_is_convex | ( | const BMEdge * | e | ) |
Check if the edge is convex or concave (depends on face winding)
Definition at line 866 of file bmesh_query.cc.
References BM_edge_is_convex(), BM_edge_is_manifold(), BMVert::co, cross, cross_v3_v3v3(), dot_v3v3(), e, equals_v3v3(), BMLoop::f, BMLoop::next, BMFace::no, sub_v3_v3v3(), and BMLoop::v.
Referenced by BM_edge_calc_face_angle_signed_ex(), BM_edge_is_contiguous(), BM_edge_is_convex(), and bpy_bmedge_is_convex_get().
| BLI_INLINE bool BM_edge_is_manifold | ( | const BMEdge * | e | ) |
References ATTR_NONNULL, ATTR_WARN_UNUSED_RESULT, BLI_INLINE, BM_edge_is_manifold(), BM_vert_is_boundary(), e, and v.
Referenced by add_neighbors(), bevel_build_edge_polygons(), bm_decim_build_edge_cost_single(), BM_disk_dissolve(), bm_edge_calc_dissolve_error(), BM_edge_calc_face_angle_ex(), BM_edge_calc_face_angle_signed_ex(), BM_edge_calc_face_angle_with_imat3_ex(), bm_edge_collapse(), bm_edge_collapse_loop_customdata(), BM_edge_is_convex(), bm_edge_is_delimiter(), BM_edge_is_manifold(), bm_edge_is_manifold_or_boundary(), bm_edge_to_quad_verts(), bm_edge_update_beauty_cost_single(), bm_faces_join_pair_by_edge(), BM_mesh_decimate_dissolve_ex(), bm_rotate_edges_shared(), bm_vert_dissolve_fan(), bm_vert_dissolve_fan_test(), bm_vert_edge_face_angle(), bm_vert_is_delimiter(), BM_vert_is_edge_pair_manifold(), BM_vert_other_disk_edge(), BM_vert_step_fan_loop(), bmesh_kernel_join_face_kill_edge(), bmo_bevel_exec(), bmo_inset_region_exec(), bmo_recalc_normal_loop_filter_cb(), bmo_triangle_fill_exec(), bmw_EdgeLoopWalker_step(), bmw_FaceLoopWalker_edge_begins_loop(), bmw_FaceLoopWalker_step(), bpy_bmedge_is_manifold_get(), edbm_rip_invoke__edge(), edbm_rip_invoke__vert(), edbm_select_by_pole_count_exec(), edbm_select_non_manifold_exec(), erot_state_ex(), blender::bke::pbvh::is_boundary_edge(), modify_mesh(), and blender::ed::transform::transform_mesh_edge_slide_data_create().
| BLI_INLINE bool BM_edge_is_wire | ( | const BMEdge * | e | ) |
References ATTR_NONNULL, ATTR_WARN_UNUSED_RESULT, BLI_INLINE, BM_edge_is_wire(), BM_vert_is_manifold(), BM_vert_is_manifold_region(), e, and v.
Referenced by ATTR_NONNULL(), bevel_vert_construct(), BM_edge_is_wire(), BM_edge_split(), bm_edge_test_rail_cb(), bm_log_faces_unmake(), BM_mesh_decimate_dissolve_ex(), BM_mesh_intersect_edges(), BM_mesh_region_match(), bm_vert_calc_surface_tangent(), bm_vert_collapse_is_degenerate(), bm_vert_dissolve_fan(), bm_vert_dissolve_fan_test(), bm_vert_fasthash_create(), bm_vert_fasthash_single(), bmo_dissolve_verts_exec(), bmo_extrude_face_region_exec(), bmo_region_extend_contract(), bmo_region_extend_expand(), bmw_edge_is_wire(), bmw_FaceLoopWalker_edge_begins_loop(), bpy_bmedge_is_wire_get(), edbm_add_edge_face_exec__tricky_extend_sel(), edbm_bridge_tag_boundary_edges(), edbm_delete_loose_exec(), edbm_face_split_by_edges_exec(), edbm_polybuild_face_at_cursor_invoke(), edbm_rip_invoke__edge(), edbm_rip_invoke__vert(), edbm_select_loose_exec(), edbm_select_non_manifold_exec(), knife_make_face_cuts(), blender::bke::pbvh::pbvh_bmesh_collapse_edge(), ringsel_finish(), and view3d_preselect_update_preview_triangle_from_vert().
Utility function, since enough times we have an edge and want to access 2 connected loops.
Definition at line 561 of file bmesh_query.cc.
References BM_edge_loop_pair(), e, and BMLoop::radial_next.
Referenced by bm_decim_triangulate_end(), bm_edge_collapse(), BM_edge_loop_pair(), bm_face_split_by_concave(), BM_normals_loops_edges_tag(), BM_verts_in_edge(), bmo_dissolve_edges_exec(), bmo_dissolve_verts_exec(), contig_ldata_across_edge(), DRW_text_edit_mesh_measure_stats(), edbm_polybuild_dissolve_at_cursor_invoke(), edbm_ripsel_edge_mark_step(), edbm_ripsel_looptag_helper(), edbm_select_sharp_edges_exec(), edbm_tagged_loop_pairs_to_fill(), modify_mesh(), blender::bke::pbvh::pbvh_bmesh_edge_loops(), and blender::ed::mesh::set_sharpness_by_angle_exec().
Definition at line 1151 of file bmesh_query.cc.
References BM_edge_ordered_verts(), BM_edge_ordered_verts_ex(), and BMEdge::l.
Referenced by BM_edge_calc_rotate(), BM_edge_ordered_verts(), BM_edge_rotate_check_degenerate(), BM_face_create_ngon_verts(), BM_loop_is_adjacent(), and blender::ed::transform::getTransformOrientation_ex().
| void BM_edge_ordered_verts_ex | ( | const BMEdge * | edge, |
| BMVert ** | r_v1, | ||
| BMVert ** | r_v2, | ||
| const BMLoop * | edge_loop ) |
Returns the verts of an edge as used in a face if used in a face at all, otherwise just assign as used in the edge.
Useful to get a deterministic winding order when calling BM_face_create_ngon() on an arbitrary array of verts, though be sure to pick an edge which has a face.
Definition at line 1140 of file bmesh_query.cc.
References BLI_assert, BM_edge_ordered_verts_ex(), BMLoop::e, BMLoop::next, and BMLoop::v.
Referenced by BM_edge_calc_face_tangent(), BM_edge_ordered_verts(), BM_edge_ordered_verts_ex(), BM_loop_is_adjacent(), and bmo_inset_region_exec().
Given a edge and a loop (assumes the edge is manifold). returns the other faces loop, sharing the same vertex.
+-------------------+ | | | | |l_other <-- return | +-------------------+ <-- A manifold edge between 2 faces |l e <-- edge | |^ <-------- loop | | | +-------------------+
Definition at line 444 of file bmesh_query.cc.
References BLI_assert, BM_edge_other_loop(), BM_vert_in_edge(), BMLoop::e, e, l, BMLoop::next, BMLoop::prev, BMLoop::radial_next, and BMLoop::v.
Referenced by BM_edge_other_loop(), BM_edge_other_vert(), bm_extrude_copy_face_loop_attributes(), bm_loop_customdata_merge(), BM_vert_step_fan_loop(), bmo_inset_region_exec(), and edbm_tagged_loop_pairs_do_fill_faces().
| BLI_INLINE BMVert * BM_edge_other_vert | ( | BMEdge * | e, |
| const BMVert * | v ) |
References ATTR_NONNULL, ATTR_WARN_UNUSED_RESULT, BLI_INLINE, BM_edge_find_first_loop_visible(), BM_edge_other_loop(), BM_edge_other_vert(), BM_face_other_edge_loop(), BM_face_other_vert_loop(), BM_loop_other_edge_loop(), BM_loop_other_vert_loop(), BM_loop_other_vert_loop_by_edge(), BM_vert_find_first_loop(), BM_vert_find_first_loop_visible(), BM_vert_pair_share_face_check(), BM_vert_step_fan_loop(), e, l, and v.
Referenced by adjust_miter_coords(), adjust_miter_inner_coords(), bevel_reattach_wires(), bevel_vert_construct(), BKE_mesh_remesh_voxel_fix_poles(), bm_edge_collapse(), bm_edge_info_average_length_fallback(), BM_edge_other_vert(), BM_edge_split(), bm_edge_subdiv_as_loop(), bm_edgenet_path_step(), bm_edgering_pair_calc(), bm_edgering_pair_order(), bm_edgering_pair_subdiv(), bm_edges_sort_winding(), bm_face_region_pivot_edge_find(), bm_face_region_vert_pass_id(), bm_face_split_by_edges(), BM_face_split_edgenet_connect_islands(), bm_face_split_edgenet_find_loop(), bm_face_split_edgenet_find_loop_pair(), bm_face_split_edgenet_find_loop_walk(), bm_face_split_edgenet_partial_connect(), BM_faces_join(), bm_loop_build(), BM_loop_other_vert_loop(), bm_loop_path_build_step(), BM_mesh_calc_edge_groups_as_arrays(), BM_mesh_edgeloops_find_path(), BM_mesh_intersect(), BM_mesh_intersect_edges(), bm_mesh_loops_calc_normals_for_loop(), bm_select_edgeloop_double_side_next(), bm_select_edgeloop_single_side_next(), bm_tag_untagged_neighbors(), bm_uidwalk_calc_vert_uid(), bm_vert_boundary_tangent(), BM_vert_calc_edge_angle_ex(), BM_vert_calc_median_tagged_edge_length(), BM_vert_collapse_edge(), BM_vert_collapse_faces(), bm_vert_collapse_is_degenerate(), bm_vert_dissolve_fan_test(), bm_vert_is_tag_edge_connect(), bm_vert_is_uid_connect(), bm_vert_other_tag(), bm_vert_pair_ends(), bm_vert_pair_share_best_splittable_face_cb(), BM_vert_splice_check_double(), bmesh_kernel_join_edge_kill_vert(), bmesh_kernel_join_vert_kill_edge(), bmesh_kernel_split_edge_make_vert(), bmo_edgeloop_fill_exec(), bmo_find_end_of_chain(), bmo_inset_region_exec(), bmo_offset_edgeloops_exec(), bmo_region_extend_expand(), bmo_smooth_vert_exec(), bmo_triangle_fill_exec(), bmo_vert_calc_edge_angle_blended(), bmw_ConnectedVertexWalker_step(), bmw_EdgeLoopWalker_begin(), bmw_EdgeLoopWalker_step(), bmw_IslandboundWalker_step(), bmw_LoopShellWireWalker_visitVert(), bmw_NonManifoldedgeWalker_step(), bpy_bmedge_other_vert(), edbm_add_edge_face_exec__tricky_extend_sel(), edbm_face_split_by_edges_exec(), edbm_fill_grid_vert_tag_angle(), edbm_polybuild_face_at_cursor_invoke(), edbm_rip_edge_invoke(), edbm_ripsel_edge_uid_step(), edbm_ripsel_looptag_helper(), edbm_tagged_loop_pairs_do_fill_faces(), edge_step(), edges_angle_kind(), edgetag_add_adjacent(), edgetag_cut_cost_vert(), blender::ed::transform::getTransformOrientation_ex(), blender::bke::pbvh::merge_face_edge_data(), blender::bke::pbvh::merge_flap_edge_data(), mesh_calc_path_region_elem(), offset_in_plane(), offset_meet(), offset_meet_edge(), offset_meet_lines_percent_or_absolute(), offset_on_edge_between(), pipe_test(), point_between_edges(), blender::ed::object::skin_root_clear(), skin_smooth_hulls(), slide_dist(), state_step(), blender::ed::transform::transform_convert_mesh_connectivity_distance(), blender::ed::transform::transform_mesh_vert_slide_data_create(), unsubdivide_build_base_mesh_from_tags(), unsubdivide_init_elem_ids(), uv_select_edgeloop_double_side_tag(), uv_select_edgeloop_single_side_tag(), verttag_add_adjacent(), and blender::ed::object::vgroup_smooth_subset().
| BMFace * BM_edge_pair_share_face_by_len | ( | BMEdge * | e_a, |
| BMEdge * | e_b, | ||
| BMLoop ** | r_l_a, | ||
| BMLoop ** | r_l_b, | ||
| bool | allow_adjacent ) |
Definition at line 200 of file bmesh_query.cc.
References BM_edge_pair_share_face_by_len(), BM_face_edge_share_loop(), BM_ITER_ELEM, BM_loop_is_adjacent(), BM_LOOPS_OF_EDGE, BMLoop::f, BMEdge::l, l_b, and BMFace::len.
Referenced by BM_edge_pair_share_face_by_len(), bm_vert_connect_select_history_edge_to_vert_path(), and BM_vert_pair_shared_face_cb().
Test if e1 shares any faces with e2
Definition at line 1046 of file bmesh_query.cc.
References BM_edge_in_face(), BM_edge_share_face_check(), BMLoop::f, BMEdge::l, l, and BMLoop::radial_next.
Referenced by BM_disk_dissolve(), BM_edge_share_face_check(), BM_loop_is_adjacent(), edbm_add_edge_face_exec__tricky_extend_sel(), and view3d_preselect_mesh_edgering_update_edges_from_edge().
Test if e1 shares any quad faces with e2
Definition at line 1064 of file bmesh_query.cc.
References BM_edge_in_face(), BM_edge_share_quad_check(), BMLoop::f, BMEdge::l, l, BMFace::len, and BMLoop::radial_next.
Referenced by BM_edge_share_quad_check(), BM_loop_is_adjacent(), edge_step(), and view3d_preselect_mesh_edgering_update_edges_from_edge().
Return the shared vertex between the two edges or NULL
Definition at line 1089 of file bmesh_query.cc.
References BLI_assert, BM_edge_share_vert(), BM_vert_in_edge(), BMEdge::v1, and BMEdge::v2.
Referenced by bm_edge_collapse(), BM_edge_share_vert(), BM_loop_is_adjacent(), BM_verts_from_edges(), and edbm_tagged_loop_pairs_do_fill_faces().
Tests to see if e1 shares a vertex with e2
Definition at line 1084 of file bmesh_query.cc.
References BM_edge_share_vert_check(), BMEdge::v1, and BMEdge::v2.
Referenced by BM_edge_share_vert_check(), bm_edgexedge_isect_cb(), BM_loop_is_adjacent(), BM_mesh_decimate_collapse(), bmo_edgenet_prepare_exec(), and bmo_subdivide_edges_exec().
Return the Loop Shared by Edge and Vert.
Finds the loop used which uses in face loop l
Definition at line 1101 of file bmesh_query.cc.
References BLI_assert, BM_edge_vert_share_loop(), BM_vert_in_edge(), BMLoop::e, l, BMLoop::next, BMLoop::v, and v.
Referenced by BM_edge_vert_share_loop(), BM_loop_is_adjacent(), and edbm_rip_invoke__vert().
Return the Loop Shared by Face and Edge.
Finds the loop used which uses e in face loop l
Definition at line 1125 of file bmesh_query.cc.
References BM_face_edge_share_loop(), e, BMLoop::f, and BMLoop::radial_next.
Referenced by bev_ccw_test(), BM_edge_pair_share_face_by_len(), BM_edge_rotate(), BM_face_edge_share_loop(), BM_face_other_edge_loop(), BM_loop_is_adjacent(), bmesh_kernel_join_face_kill_edge(), ED_uvedit_active_edge_loop_get(), edbm_add_edge_face_exec__tricky_finalize_sel(), blender::draw::extract_edituv_data_iter_subdiv_bm(), fast_bevel_edge_order(), geometry_collide_offset(), and knife_add_single_cut__is_linehit_outside_face().
Given a set of vertices (varr), find out if there is a face with exactly those vertices (and only those vertices).
Definition at line 1623 of file bmesh_query.cc.
References BM_DISK_EDGE_NEXT, BM_face_exists(), BMVert::e, e, BMLoop::f, BMEdge::l, BMFace::len, len(), BMLoop::next, BMLoop::prev, BMLoop::radial_next, and BMLoop::v.
Referenced by BM_face_create(), BM_face_exists(), BM_loop_is_adjacent(), bm_vert_dissolve_fan_test(), bmo_edgeloop_fill_exec(), bpy_bmfaceseq_get__method(), bpy_bmfaceseq_new(), bridge_loop_pair(), edbm_tagged_loop_pairs_do_fill_faces(), EDBM_verts_mirror_get_face(), blender::bke::pbvh::pbvh_bmesh_collapse_edge(), blender::bke::pbvh::pbvh_bmesh_face_create(), and remdoubles_createface().
Given a set of vertices and edges (varr, earr), find out if all those vertices are filled in by existing faces that only use those vertices.
This is for use in cases where creating a face is possible but would result in many overlapping faces.
An example of how this is used: when 2 triangles are selected that share an edge, pressing F-key would make a new overlapping quad (without a check like this)
earr and varr can be in any order, however they must form a closed loop.
Definition at line 1703 of file bmesh_query.cc.
References BM_EDGES_OF_VERT, BM_elem_flag_disable, BM_elem_flag_enable, BM_elem_flag_test, BM_ELEM_INTERNAL_TAG, BM_face_exists_multi(), BM_FACES_OF_EDGE, BM_ITER_ELEM, BM_VERTS_OF_FACE, e, i, len(), and v.
Referenced by bm_edgenet_face_from_path(), BM_face_exists_multi(), BM_face_exists_multi_edge(), and BM_loop_is_adjacent().
| bool BM_face_exists_multi_edge | ( | BMEdge ** | earr, |
| int | len ) |
Definition at line 1812 of file bmesh_query.cc.
References BLI_array_alloca, BM_face_exists_multi(), BM_face_exists_multi_edge(), BM_verts_from_edges(), BMESH_ASSERT, and len().
Referenced by BM_face_exists_multi_edge(), and BM_loop_is_adjacent().
Given a set of vertices (varr), find out if all those vertices overlap an existing face.
| varr | Array of unordered verts. |
| len | varr array length. |
Definition at line 1825 of file bmesh_query.cc.
References _FLAG_OVERLAP, BLI_assert, BLI_linklist_prepend_alloca, BM_ELEM_API_FLAG_DISABLE, BM_ELEM_API_FLAG_ENABLE, BM_ELEM_API_FLAG_TEST, BM_face_exists_overlap(), BM_FACES_OF_VERT, BM_ITER_ELEM, BM_verts_in_face_count(), i, len(), LinkNode::link, and LinkNode::next.
Referenced by BM_face_exists_overlap(), and BM_loop_is_adjacent().
| bool BM_face_exists_overlap_subset | ( | BMVert ** | varr, |
| int | len ) |
Given a set of vertices (varr), find out if there is a face that uses vertices only from this list (that the face is a subset or made from the vertices given).
| varr | Array of unordered verts. |
| len | varr array length. |
Definition at line 1863 of file bmesh_query.cc.
References _FLAG_OVERLAP, BLI_assert, BLI_linklist_prepend_alloca, BM_ELEM_API_FLAG_DISABLE, BM_ELEM_API_FLAG_ENABLE, BM_ELEM_API_FLAG_TEST, BM_face_exists_overlap_subset(), BM_FACE_FIRST_LOOP, BM_FACES_OF_VERT, BM_ITER_ELEM, i, BMFace::len, len(), LinkNode::link, BMLoop::next, LinkNode::next, and BMLoop::v.
Referenced by bm_edgenet_path_check_overlap(), BM_face_exists_overlap_subset(), and BM_loop_is_adjacent().
Check if the face has an exact duplicate (both winding directions).
Definition at line 1671 of file bmesh_query.cc.
References BM_face_find_double(), BM_FACE_FIRST_LOOP, BMLoop::e, BMLoop::f, l_b, BMFace::len, BMLoop::next, BMLoop::prev, BMLoop::radial_next, and BMLoop::v.
Referenced by bm_face_connect_verts(), BM_face_find_double(), BM_faces_join(), BM_loop_is_adjacent(), bmesh_kernel_join_edge_kill_vert(), and bmo_spin_exec().
Returns the loop of the longest edge in f.
Definition at line 1519 of file bmesh_query.cc.
References BM_face_find_longest_loop(), BM_FACE_FIRST_LOOP, BMVert::co, len_squared_v3v3(), BMLoop::next, and BMLoop::v.
Referenced by BM_face_calc_tangent_from_edge(), BM_face_calc_tangent_from_edge_pair(), BM_face_calc_tangent_pair_from_edge(), BM_face_find_longest_loop(), BM_loop_is_adjacent(), and skin_fix_hole_no_good_verts().
Returns the loop of the shortest edge in f.
Definition at line 1498 of file bmesh_query.cc.
References BM_face_find_shortest_loop(), BM_FACE_FIRST_LOOP, BMVert::co, FLT_MAX, len_squared_v3v3(), BMLoop::next, and BMLoop::v.
Referenced by BM_face_find_shortest_loop(), BM_loop_is_adjacent(), and collapse_face_corners().
| bool BM_face_is_any_edge_flag_test | ( | const BMFace * | f, |
| char | hflag ) |
Definition at line 2015 of file bmesh_query.cc.
References BM_elem_flag_test, BM_FACE_FIRST_LOOP, BM_face_is_any_edge_flag_test(), BMLoop::e, and BMLoop::next.
Referenced by BM_face_is_any_edge_flag_test(), BM_loop_is_adjacent(), and EDBM_selectmode_convert().
| bool BM_face_is_any_vert_flag_test | ( | const BMFace * | f, |
| char | hflag ) |
Definition at line 2001 of file bmesh_query.cc.
References BM_elem_flag_test, BM_FACE_FIRST_LOOP, BM_face_is_any_vert_flag_test(), BMLoop::next, and BMLoop::v.
Referenced by BM_face_is_any_vert_flag_test(), BM_loop_is_adjacent(), and EDBM_selectmode_convert().
| bool BM_face_is_normal_valid | ( | const BMFace * | f | ) |
Use within asserts to check normals are valid.
Definition at line 2045 of file bmesh_query.cc.
References BM_face_calc_normal(), BM_face_is_normal_valid(), eps, len_squared_v3v3(), and BMFace::no.
Referenced by bm_face_bisect_verts(), BM_face_interp_from_face(), BM_face_is_normal_valid(), BM_face_point_inside_test(), BM_face_splits_check_legal(), BM_face_triangulate(), BM_face_uv_point_inside_test(), bm_interp_face_store(), BM_loop_is_adjacent(), BM_vert_interp_from_face(), bmesh_calc_tessellation_for_face_impl(), hull_merge_triangles(), and recalc_face_normals_find_index().
Other Loop in Face Sharing an Edge.
Finds the other loop that shares v with e loop in f.
+----------+
| |
| f |
| |
+----------+ <-- return the face loop of this vertex.
v --> e
^ ^ <------- These vert args define direction
in the face to check.
The faces loop direction is ignored.
Definition at line 32 of file bmesh_query.cc.
References BLI_assert, BM_face_edge_share_loop(), BM_face_other_edge_loop(), BM_loop_other_edge_loop(), e, l, and v.
Referenced by BM_edge_other_vert(), and BM_face_other_edge_loop().
Other Loop in Face Sharing a Vertex.
Finds the other loop in a face.
This function returns a loop in f that shares an edge with v The direction is defined by v_prev, where the return value is the loop of what would be 'v_next'
+----------+ <-- return the face loop of this vertex.
| |
| f |
| |
+----------+
v_prev --> v
^^^^^^ ^ <-- These vert args define direction
in the face to check.
The faces loop direction is ignored.
Definition at line 45 of file bmesh_query.cc.
References BLI_assert, BM_edge_exists(), BM_face_other_vert_loop(), BM_face_vert_share_loop(), BMLoop::next, BMLoop::prev, BMLoop::v, and v.
Referenced by BM_edge_calc_rotate(), BM_edge_other_vert(), BM_edge_rotate_check(), BM_edge_rotate_check_degenerate(), BM_face_other_vert_loop(), BM_loop_other_vert_loop(), bmw_EdgeLoopWalker_step(), and edbm_rip_edge_side_measure().
Returns true if the faces share an edge
Definition at line 994 of file bmesh_query.cc.
References BM_edge_in_face(), BM_FACE_FIRST_LOOP, BM_face_share_edge_check(), BMLoop::e, and BMLoop::next.
Referenced by BM_face_share_edge_check(), BM_face_share_face_check(), BM_face_share_face_count(), bm_isect_tri_tri(), BM_loop_is_adjacent(), and face_step().
Counts the number of edges two faces share (if any)
Definition at line 978 of file bmesh_query.cc.
References BM_edge_in_face(), BM_FACE_FIRST_LOOP, BM_face_share_edge_count(), BMLoop::e, and BMLoop::next.
Referenced by BM_face_share_edge_count(), BM_loop_is_adjacent(), and bmesh_kernel_join_face_kill_edge().
same as BM_face_share_face_count but returns a bool
Definition at line 961 of file bmesh_query.cc.
References BM_EDGES_OF_FACE, BM_face_share_edge_check(), BM_face_share_face_check(), BM_FACES_OF_EDGE, BM_ITER_ELEM, and e.
Referenced by BM_face_share_face_check(), BM_loop_is_adjacent(), and hull_merge_triangles().
Returns the number of faces that are adjacent to both f1 and f2,
Definition at line 943 of file bmesh_query.cc.
References BM_EDGES_OF_FACE, BM_face_share_edge_check(), BM_face_share_face_count(), BM_FACES_OF_EDGE, BM_ITER_ELEM, and e.
Referenced by BM_face_share_face_count(), and BM_loop_is_adjacent().
Returns true if the faces share a vert.
Definition at line 1025 of file bmesh_query.cc.
References BM_FACE_FIRST_LOOP, BM_face_share_vert_check(), BM_vert_in_face(), BMLoop::next, and BMLoop::v.
Referenced by BM_face_share_vert_check(), and BM_loop_is_adjacent().
Counts the number of verts two faces share (if any).
Definition at line 1009 of file bmesh_query.cc.
References BM_FACE_FIRST_LOOP, BM_face_share_vert_count(), BM_vert_in_face(), BMLoop::next, and BMLoop::v.
Referenced by BM_face_share_vert_count(), bm_face_split_by_edges_island_connect(), and BM_loop_is_adjacent().
Return the Loop Shared by Face and Vertex.
Finds the loop used which uses v in face loop l
Definition at line 1110 of file bmesh_query.cc.
References BM_FACE_FIRST_LOOP, BM_face_vert_share_loop(), BMLoop::next, BMLoop::v, and v.
Referenced by BM_disk_dissolve(), BM_edge_rotate(), bm_face_bisect_verts(), bm_face_connect_verts(), BM_face_other_vert_loop(), BM_face_vert_share_loop(), BM_loop_is_adjacent(), bm_loop_normal_mark_indiv(), BM_vert_collapse_faces(), BM_vert_pair_share_face_by_angle(), BM_vert_pair_share_face_by_len(), BM_vert_pair_shared_face_cb(), bpy_bm_utils_face_split(), bpy_bm_utils_face_vert_separate(), ED_uvedit_active_vert_loop_get(), edbm_add_edge_face_exec__tricky_finalize_sel(), edbm_set_normals_from_faces_exec(), knife_add_single_cut__is_linehit_outside_face(), knife_verts_edge_in_face(), offset_meet_lines_percent_or_absolute(), remdoubles_splitface(), and update_uv_vert_map().
| float BM_loop_calc_face_angle | ( | const BMLoop * | l | ) |
Calculates the angle between the previous and next loops (angle at this loops face corner).
Definition at line 1202 of file bmesh_query.cc.
References angle_v3v3v3(), BM_loop_calc_face_angle(), BMVert::co, l, BMLoop::next, BMLoop::prev, and BMLoop::v.
Referenced by BM_loop_calc_face_angle(), BM_loop_is_adjacent(), BM_mesh_wireframe(), BM_vert_calc_shell_factor(), BM_vert_calc_shell_factor_ex(), bpy_bmloop_calc_angle(), and edbm_average_normals_exec().
| void BM_loop_calc_face_direction | ( | const BMLoop * | l, |
| float | r_dir[3] ) |
BM_loop_calc_face_direction.
Calculate the direction a loop is pointing.
| l | The loop to calculate the direction at |
| r_dir | Resulting direction |
Definition at line 1294 of file bmesh_query.cc.
References add_v3_v3v3(), BM_loop_calc_face_direction(), BMVert::co, l, BMLoop::next, normalize_v3(), BMLoop::prev, sub_v3_v3v3(), and BMLoop::v.
Referenced by BM_loop_calc_face_direction(), BM_loop_is_adjacent(), and blender::ed::transform::isect_face_dst().
| float BM_loop_calc_face_normal | ( | const BMLoop * | l, |
| float | r_normal[3] ) |
BM_loop_calc_face_normal.
Calculate the normal at this loop corner or fall back to the face normal on straight lines.
| l | The loop to calculate the normal at |
| r_normal | Resulting normal |
Definition at line 1280 of file bmesh_query.cc.
References BM_loop_calc_face_normal(), BMVert::co, copy_v3_v3(), cross_v3_v3v3(), BMLoop::f, l, len(), BMLoop::next, BMFace::no, normalize_v3(), BMLoop::prev, sub_v3_v3v3(), UNLIKELY, BMLoop::v, and v2.
Referenced by BM_loop_calc_face_normal(), BM_loop_is_adjacent(), and bpy_bmloop_calc_normal().
| float BM_loop_calc_face_normal_safe | ( | const BMLoop * | l, |
| float | r_normal[3] ) |
BM_loop_calc_face_normal_safe_ex with predefined sane epsilon.
Since this doesn't scale based on triangle size, fixed value works well.
Definition at line 1266 of file bmesh_query.cc.
References BM_loop_calc_face_normal_safe(), BM_loop_calc_face_normal_safe_ex(), and l.
Referenced by BM_loop_calc_face_normal_safe(), BM_loop_is_adjacent(), and blender::draw::statvis_calc_distort().
| float BM_loop_calc_face_normal_safe_ex | ( | const BMLoop * | l, |
| float | epsilon_sq, | ||
| float | r_normal[3] ) |
BM_loop_calc_face_normal.
Calculate the normal at this loop corner or fall back to the face normal on straight lines.
| l | The loop to calculate the normal at. |
| epsilon_sq | Value to avoid numeric errors (1e-5f works well). |
| r_normal | Resulting normal. |
Definition at line 1207 of file bmesh_query.cc.
References BM_loop_calc_face_normal_safe_ex(), BMVert::co, copy_v3_v3(), cross_v3_v3v3(), BMLoop::f, is_zero_v3(), l, len_squared_v3(), mul_v3_v3fl(), BMLoop::next, BMFace::no, normalize_v3(), BMLoop::prev, sub_v3_v3(), sub_v3_v3v3(), BMLoop::v, and v2.
Referenced by BM_loop_calc_face_normal_safe(), BM_loop_calc_face_normal_safe_ex(), and BM_loop_is_adjacent().
| float BM_loop_calc_face_normal_safe_vcos | ( | const BMLoop * | l, |
| const float | normal_fallback[3], | ||
| float const (*) | vertexCos[3], | ||
| float | r_normal[3] ) |
Definition at line 1271 of file bmesh_query.cc.
References BM_loop_calc_face_normal_safe_vcos(), BM_loop_calc_face_normal_safe_vcos_ex(), and l.
Referenced by BM_loop_calc_face_normal_safe_vcos(), BM_loop_is_adjacent(), and blender::draw::statvis_calc_distort().
| float BM_loop_calc_face_normal_safe_vcos_ex | ( | const BMLoop * | l, |
| const float | normal_fallback[3], | ||
| float const (*) | vertexCos[3], | ||
| float | epsilon_sq, | ||
| float | r_normal[3] ) |
A version of BM_loop_calc_face_normal_safe_ex which takes vertex coordinates.
Definition at line 1236 of file bmesh_query.cc.
References BM_elem_index_get, BM_loop_calc_face_normal_safe_vcos_ex(), copy_v3_v3(), cross_v3_v3v3(), i, is_zero_v3(), l, len_squared_v3(), mul_v3_v3fl(), BMLoop::next, normalize_v3(), BMLoop::prev, sub_v3_v3(), sub_v3_v3v3(), BMLoop::v, and v2.
Referenced by BM_loop_calc_face_normal_safe_vcos(), BM_loop_calc_face_normal_safe_vcos_ex(), and BM_loop_is_adjacent().
| void BM_loop_calc_face_tangent | ( | const BMLoop * | l, |
| float | r_tangent[3] ) |
BM_loop_calc_face_tangent.
Calculate the tangent at this loop corner or fall back to the face normal on straight lines. This vector always points inward into the face.
| l | The loop to calculate the tangent at |
| r_tangent | Resulting tangent |
Definition at line 1309 of file bmesh_query.cc.
References add_v3_v3v3(), BM_loop_calc_face_tangent(), BMVert::co, compare_v3v3(), cross_v3_v3v3(), dot_v3v3(), BMLoop::f, l, negate_v3(), BMLoop::next, BMFace::no, normalize_v3(), BMLoop::prev, sub_v3_v3v3(), UNLIKELY, and BMLoop::v.
Referenced by BM_loop_calc_face_tangent(), BM_loop_is_adjacent(), BM_mesh_wireframe(), bpy_bmloop_calc_tangent(), and edbm_calc_loop_co().
Definition at line 1173 of file bmesh_query.cc.
References BLI_assert, BM_loop_find_next_nodouble(), BMVert::co, ELEM, l, len_squared_v3v3(), BMLoop::next, UNLIKELY, and BMLoop::v.
Referenced by BM_loop_find_next_nodouble(), BM_loop_is_adjacent(), and blender::ed::transform::mesh_customdatacorrect_init_vert().
Definition at line 1156 of file bmesh_query.cc.
References BLI_assert, BM_loop_find_prev_nodouble(), BMVert::co, ELEM, l, len_squared_v3v3(), BMLoop::prev, UNLIKELY, and BMLoop::v.
Referenced by BM_loop_find_prev_nodouble(), BM_loop_is_adjacent(), and blender::ed::transform::mesh_customdatacorrect_init_vert().
| BLI_INLINE bool BM_loop_is_adjacent | ( | const BMLoop * | l_a, |
| const BMLoop * | l_b ) |
References ATTR_NONNULL, ATTR_WARN_UNUSED_RESULT, BLI_INLINE, bm, BM_edge_calc_face_angle(), BM_edge_calc_face_angle_ex(), BM_edge_calc_face_angle_signed(), BM_edge_calc_face_angle_signed_ex(), BM_edge_calc_face_angle_with_imat3(), BM_edge_calc_face_angle_with_imat3_ex(), BM_edge_calc_face_tangent(), BM_edge_exists(), BM_edge_find_double(), BM_edge_is_all_face_flag_test(), BM_edge_is_any_face_flag_test(), BM_edge_is_any_face_len_test(), BM_edge_is_any_vert_flag_test(), BM_edge_ordered_verts(), BM_edge_ordered_verts_ex(), BM_edge_share_face_check(), BM_edge_share_quad_check(), BM_edge_share_vert(), BM_edge_share_vert_check(), BM_edge_vert_share_loop(), BM_face_edge_share_loop(), BM_face_exists(), BM_face_exists_multi(), BM_face_exists_multi_edge(), BM_face_exists_overlap(), BM_face_exists_overlap_subset(), BM_face_find_double(), BM_face_find_longest_loop(), BM_face_find_shortest_loop(), BM_face_is_any_edge_flag_test(), BM_face_is_any_vert_flag_test(), BM_face_is_normal_valid(), BM_face_share_edge_check(), BM_face_share_edge_count(), BM_face_share_face_check(), BM_face_share_face_count(), BM_face_share_vert_check(), BM_face_share_vert_count(), BM_face_vert_share_loop(), BM_loop_calc_face_angle(), BM_loop_calc_face_direction(), BM_loop_calc_face_normal(), BM_loop_calc_face_normal_safe(), BM_loop_calc_face_normal_safe_ex(), BM_loop_calc_face_normal_safe_vcos(), BM_loop_calc_face_normal_safe_vcos_ex(), BM_loop_calc_face_tangent(), BM_loop_find_next_nodouble(), BM_loop_find_prev_nodouble(), BM_loop_is_adjacent(), BM_loop_point_side_of_edge_test(), BM_loop_point_side_of_loop_test(), BM_loop_share_edge_check(), BM_mesh_calc_volume(), BM_vert_calc_edge_angle(), BM_vert_calc_edge_angle_ex(), BM_vert_calc_median_tagged_edge_length(), BM_vert_calc_shell_factor(), BM_vert_calc_shell_factor_ex(), BM_vert_is_all_edge_flag_test(), BM_vert_is_all_face_flag_test(), e, l, l_b, len(), and v.
Referenced by BM_edge_pair_share_face_by_len(), bm_face_bisect_verts(), bm_face_connect_verts(), BM_face_split(), bm_face_split_find(), BM_face_split_n(), BM_loop_is_adjacent(), BM_vert_pair_share_face_by_angle(), BM_vert_pair_share_face_by_len(), BM_vert_pair_shared_face_cb(), bpy_bm_utils_face_split(), connect_smallest_face(), knife_verts_edge_in_face(), and remdoubles_splitface().
| bool BM_loop_is_convex | ( | const BMLoop * | l | ) |
Check if the loop is convex or concave (depends on face normal)
Definition at line 1190 of file bmesh_query.cc.
References BM_loop_is_convex(), BMVert::co, cross_v3_v3v3(), dot_v3v3(), BMLoop::f, l, BMLoop::next, BMFace::no, BMLoop::prev, sub_v3_v3v3(), and BMLoop::v.
Referenced by BM_edge_is_contiguous(), bm_face_convex_tag_verts(), BM_loop_is_convex(), and bpy_bmloop_is_convex_get().
See BM_face_other_edge_loop This is the same functionality to be used when the edges loop is already known.
Definition at line 39 of file bmesh_query.cc.
References BLI_assert, BM_loop_other_edge_loop(), BM_vert_in_edge(), BMLoop::e, l, BMLoop::next, BMLoop::prev, BMLoop::v, and v.
Referenced by BM_edge_other_vert(), BM_face_other_edge_loop(), BM_loop_other_edge_loop(), bmo_vert_touches_unselected_face(), bmw_EdgeLoopWalker_step(), bmw_IslandboundWalker_step(), bmw_NonManifoldLoop_find_next_around_vertex(), edbm_rip_invoke__edge(), and edgering_find_order().
Other Loop in Face Sharing a Vert.
Finds the other loop that shares v with e loop in f.
+----------+ <-- return the face loop of this vertex.
| |
| |
| |
+----------+ <-- This vertex defines the direction.
l v
^ <------- This loop defines both the face to search
and the edge, in combination with 'v'
The faces loop direction is ignored.
Definition at line 67 of file bmesh_query.cc.
References BLI_assert, BM_edge_other_vert(), BM_face_other_vert_loop(), BM_loop_other_vert_loop(), BMLoop::e, e, BMLoop::f, l, BMLoop::next, BMLoop::prev, BMLoop::v, and v.
Referenced by BM_edge_other_vert(), BM_loop_other_vert_loop(), BM_vert_other_disk_edge(), and bmo_inset_region_exec().
Return the other loop that uses this edge.
In this case the loop defines the vertex, the edge passed in defines the direction to step.
+----------+ <-- Return the face-loop of this vertex.
| |
| e | <-- This edge defines the direction.
| |
+----------+ <-- This loop defines the face and vertex..
l
Definition at line 92 of file bmesh_query.cc.
References BLI_assert, BM_loop_other_vert_loop_by_edge(), BM_vert_in_edge(), BMLoop::e, e, l, BMLoop::next, BMLoop::prev, and BMLoop::v.
Referenced by BM_edge_other_vert(), BM_edge_uv_share_vert_check(), and BM_loop_other_vert_loop_by_edge().
| float BM_loop_point_side_of_edge_test | ( | const BMLoop * | l, |
| const float | co[3] ) |
Check if a point is inside the edge defined by a loop (within the plane defined by the loops edge & face normal).
Definition at line 246 of file bmesh_query.cc.
References BM_loop_point_side_of_edge_test(), BMVert::co, cross_v3_v3v3(), dist_signed_squared_to_plane_v3(), dot_v3v3(), BMLoop::f, l, BMLoop::next, BMFace::no, sub_v3_v3v3(), and BMLoop::v.
Referenced by BM_loop_is_adjacent(), BM_loop_point_side_of_edge_test(), and knife_add_single_cut__is_linehit_outside_face().
| float BM_loop_point_side_of_loop_test | ( | const BMLoop * | l, |
| const float | co[3] ) |
Check if a point is inside the corner defined by a loop (within the 2 planes defined by the loops corner & face normal).
Definition at line 240 of file bmesh_query.cc.
References BM_loop_point_side_of_loop_test(), BMVert::co, dist_signed_squared_to_corner_v3v3v3(), BMLoop::f, l, BMLoop::next, BMFace::no, BMLoop::prev, and BMLoop::v.
Referenced by BM_loop_is_adjacent(), BM_loop_point_side_of_loop_test(), and knife_add_single_cut__is_linehit_outside_face().
| int BM_loop_region_loops_count | ( | BMLoop * | l | ) |
Definition at line 850 of file bmesh_query.cc.
References BM_loop_region_loops_count(), BM_loop_region_loops_count_at_most(), and l.
Referenced by BM_edge_is_contiguous(), and BM_loop_region_loops_count().
| int BM_loop_region_loops_count_at_most | ( | BMLoop * | l, |
| int * | r_loop_total ) |
The number of loops connected to this loop (not including disconnected regions).
Definition at line 837 of file bmesh_query.cc.
References bm_loop_region_count__clear(), bm_loop_region_count__recursive(), BM_loop_region_loops_count_at_most(), BMLoop::e, l, and BMLoop::v.
Referenced by BM_edge_is_contiguous(), BM_loop_region_loops_count(), BM_loop_region_loops_count_at_most(), and BM_vert_is_manifold_region().
Returns true when 2 loops share an edge (are adjacent in the face-fan)
Definition at line 1040 of file bmesh_query.cc.
References BLI_assert, BM_loop_share_edge_check(), BMLoop::e, ELEM, l_b, BMLoop::prev, and BMLoop::v.
Referenced by BM_loop_is_adjacent(), BM_loop_share_edge_check(), facetag_add_adjacent(), and facetag_add_adjacent_uv().
| int int BM_mesh_calc_edge_groups | ( | BMesh * | bm, |
| int * | r_groups_array, | ||
| int(**) | r_group_index[2], | ||
| BMVertFilterFunc | filter_fn, | ||
| void * | user_data, | ||
| char | hflag_test ) |
Calculate isolated groups of edges with optional filtering.
| bm | the BMesh. |
| r_groups_array | Array of ints to fill in, length of bm->totedge (or when hflag_test is set, the number of flagged edges). |
| r_group_index | index, length pairs into r_groups_array, size of return value int pairs: (array_start, array_length). |
| filter_fn | Filter the edges or verts we step over (depends on htype_step) as to which types we deal with. |
| user_data | Optional user data for filter_fn, can be NULL. |
| hflag_test | Optional flag to test edges, use to exclude edges from the calculation, 0 for all edges. |
References ATTR_NONNULL, ATTR_WARN_UNUSED_RESULT, bm, and BM_mesh_calc_edge_groups().
| int int int BM_mesh_calc_edge_groups_as_arrays | ( | BMesh * | bm, |
| BMVert ** | verts, | ||
| BMEdge ** | edges, | ||
| BMFace ** | faces, | ||
| int(**) | r_groups[3] ) |
This is an alternative to BM_mesh_calc_edge_groups.
While we could call this, then create vertex & face arrays, it requires looping over geometry connectivity twice, this slows down edit-mesh separate by loose parts, see: #70864.
References ATTR_NONNULL, ATTR_WARN_UNUSED_RESULT, bm, BM_mesh_calc_edge_groups_as_arrays(), and bmesh_subd_falloff_calc().
| 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, | ||
| char | hflag_test, | ||
| char | htype_step ) |
Calculate isolated groups of faces with optional filtering.
| bm | the BMesh. |
| r_groups_array | Array of integers to fill in, length of bm->totface (or when hflag_test is set, the number of flagged faces). |
| r_group_index | index, length pairs into r_groups_array, size of return value int pairs: (array_start, array_length). |
| filter_fn | Filter the edge-loops or vert-loops we step over (depends on htype_step). |
| user_data | Optional user data for filter_fn, can be NULL. |
| hflag_test | Optional flag to test faces, use to exclude faces from the calculation, 0 for all faces. |
| htype_step | BM_VERT to walk over face-verts, BM_EDGE to walk over faces edges (having both set is supported too). |
References ATTR_NONNULL, ATTR_WARN_UNUSED_RESULT, bm, and BM_mesh_calc_face_groups().
| double BM_mesh_calc_volume | ( | BMesh * | bm, |
| bool | is_signed ) |
Definition at line 2088 of file bmesh_query.cc.
References bm, BM_FACES_OF_MESH, BM_ITER_MESH, BM_mesh_calc_volume(), bm_mesh_calc_volume_face(), and fabs().
Referenced by BM_loop_is_adjacent(), BM_mesh_calc_volume(), bpy_bmesh_calc_volume(), and validate_solution().
| float BM_vert_calc_edge_angle | ( | const BMVert * | v | ) |
Definition at line 1426 of file bmesh_query.cc.
References BM_vert_calc_edge_angle(), BM_vert_calc_edge_angle_ex(), DEG2RADF, and v.
Referenced by BM_loop_is_adjacent(), BM_vert_calc_edge_angle(), and bm_vert_edge_face_angle().
| float BM_vert_calc_edge_angle_ex | ( | const BMVert * | v, |
| float | fallback ) |
BMESH VERT/EDGE ANGLE.
Calculates the angle a verts 2 edges.
Definition at line 1407 of file bmesh_query.cc.
References angle_v3v3v3(), BM_edge_other_vert(), BM_vert_calc_edge_angle_ex(), bmesh_disk_edge_next(), BMVert::co, BMVert::e, M_PI, v, and v2.
Referenced by BM_loop_is_adjacent(), BM_vert_calc_edge_angle(), BM_vert_calc_edge_angle_ex(), and bpy_bmvert_calc_edge_angle().
| float BM_vert_calc_median_tagged_edge_length | ( | const BMVert * | v | ) |
Definition at line 1478 of file bmesh_query.cc.
References BM_edge_calc_length(), BM_edge_other_vert(), BM_EDGES_OF_VERT, BM_elem_flag_test, BM_ELEM_TAG, BM_ITER_ELEM_INDEX, BM_vert_calc_median_tagged_edge_length(), e, length(), and v.
Referenced by BM_loop_is_adjacent(), BM_mesh_wireframe(), and BM_vert_calc_median_tagged_edge_length().
| float BM_vert_calc_shell_factor | ( | const BMVert * | v | ) |
Definition at line 1431 of file bmesh_query.cc.
References BM_ITER_ELEM, BM_loop_calc_face_angle(), BM_LOOPS_OF_VERT, BM_vert_calc_shell_factor(), BMLoop::f, l, BMFace::no, BMVert::no, shell_v3v3_normalized_to_dist(), and v.
Referenced by BM_loop_is_adjacent(), BM_vert_calc_shell_factor(), BM_vert_calc_shell_factor_ex(), bmo_inset_region_exec(), and bpy_bmvert_calc_shell_factor().
| float BM_vert_calc_shell_factor_ex | ( | const BMVert * | v, |
| const float | no[3], | ||
| char | hflag ) |
Definition at line 1449 of file bmesh_query.cc.
References BM_elem_flag_test, BM_ITER_ELEM, BM_loop_calc_face_angle(), BM_LOOPS_OF_VERT, BM_vert_calc_shell_factor(), BM_vert_calc_shell_factor_ex(), BMLoop::f, l, BMFace::no, shell_v3v3_normalized_to_dist(), and v.
Referenced by BM_loop_is_adjacent(), BM_vert_calc_shell_factor_ex(), and blender::ed::transform::VertsToTransData().
| int BM_vert_edge_count | ( | const BMVert * | v | ) |
Returns the number of edges around this vertex.
Definition at line 615 of file bmesh_query.cc.
References BM_vert_edge_count(), bmesh_disk_count(), and v.
Referenced by BKE_mesh_remesh_voxel_fix_poles(), BM_vert_edge_count(), and similar_vert_select_exec().
| int BM_vert_edge_count_at_most | ( | const BMVert * | v, |
| int | count_max ) |
Definition at line 620 of file bmesh_query.cc.
References BM_vert_edge_count_at_most(), bmesh_disk_count_at_most(), and v.
Referenced by BM_vert_dissolve(), BM_vert_edge_count_at_most(), and edbm_select_by_pole_count_exec().
| int BM_vert_edge_count_nonwire | ( | const BMVert * | v | ) |
Definition at line 625 of file bmesh_query.cc.
References BM_EDGES_OF_VERT, BM_ITER_ELEM, BM_vert_edge_count_nonwire(), BMEdge::l, and v.
Referenced by BM_vert_edge_count_nonwire(), BM_vert_pair_shared_face_cb(), bmw_EdgeLoopWalker_begin(), and bmw_EdgeLoopWalker_step().
Access a verts 2 connected edges.
Definition at line 598 of file bmesh_query.cc.
References BM_DISK_EDGE_NEXT, BM_vert_edge_pair(), BMVert::e, and v.
Referenced by bm_vert_collapse_edge_and_merge(), bm_vert_collapse_is_degenerate(), BM_vert_edge_pair(), bmo_dissolve_edges_exec(), bmo_vert_calc_edge_angle_blended(), and blender::ed::transform::getTransformOrientation_ex().
| bool BM_vert_face_check | ( | const BMVert * | v | ) |
Return true if the vertex is connected to any faces.
same as BM_vert_face_count(v) != 0 or BM_vert_find_first_loop(v) == NULL.
Definition at line 682 of file bmesh_query.cc.
References BM_vert_face_check(), bmesh_disk_edge_next(), BMVert::e, BMEdge::l, and v.
Referenced by bevel_vert_two_edges(), BM_vert_face_check(), and blender::bke::pbvh::pbvh_bmesh_collapse_edge().
| int BM_vert_face_count | ( | const BMVert * | v | ) |
Returns the number of faces around this vert length matches BM_LOOPS_OF_VERT iterator
Definition at line 672 of file bmesh_query.cc.
References BM_vert_face_count(), bmesh_disk_facevert_count(), and v.
Referenced by BM_vert_face_count(), bmo_pointmerge_facedata_exec(), bmw_EdgeLoopWalker_begin(), and similar_vert_select_exec().
| int BM_vert_face_count_at_most | ( | const BMVert * | v, |
| int | count_max ) |
Definition at line 677 of file bmesh_query.cc.
References BM_vert_face_count_at_most(), bmesh_disk_facevert_count_at_most(), and v.
Referenced by BM_vert_face_count_at_most(), and blender::bke::pbvh::find_outer_flap_vert().
Get the first loop of a vert. Uses the same initialization code for the first loop of the iterator API
Definition at line 305 of file bmesh_query.cc.
References BM_vert_find_first_loop(), bmesh_disk_faceloop_find_first(), BMVert::e, and v.
Referenced by BM_edge_other_vert(), BM_mesh_partial_create_from_verts_group_multi(), BM_mesh_partial_create_from_verts_group_single(), BM_vert_find_first_loop(), BM_vert_is_manifold_region(), edbm_rip_invoke__vert(), blender::draw::extract_points_bm(), and blender::bke::pbvh::try_merge_flap_edge_data_before_dissolve().
A version of BM_vert_find_first_loop that ignores hidden loops.
Definition at line 309 of file bmesh_query.cc.
References BM_vert_find_first_loop_visible(), bmesh_disk_faceloop_find_first_visible(), BMVert::e, and v.
Referenced by BM_edge_other_vert(), and BM_vert_find_first_loop_visible().
| BLI_INLINE bool BM_vert_in_edge | ( | const BMEdge * | e, |
| const BMVert * | v ) |
References ATTR_NONNULL, ATTR_WARN_UNUSED_RESULT, BLI_INLINE, BM_vert_in_edge(), e, and v.
Referenced by bm_decim_edge_collapse(), bm_decim_triangulate_end(), bm_edge_collapse(), BM_edge_exists(), BM_edge_find_double(), BM_edge_other_loop(), BM_edge_share_vert(), BM_edge_splice(), BM_edge_split(), bm_edge_subdiv_as_loop(), BM_edge_vert_share_loop(), bm_loop_find_other_fan_loop_with_visible_face(), bm_loop_normal_mark_indiv(), BM_loop_other_edge_loop(), BM_loop_other_vert_loop_by_edge(), BM_mesh_intersect(), BM_mesh_validate(), BM_vert_in_edge(), BM_vert_other_disk_edge(), bm_vert_other_edge(), bmesh_disk_validate(), bmesh_edge_vert_swap__recursive(), bmesh_elem_check(), bmesh_kernel_join_edge_kill_vert(), bmesh_kernel_join_vert_kill_edge(), bmesh_kernel_split_edge_make_vert(), bmesh_kernel_vert_separate(), bmo_edgenet_prepare_exec(), edbm_rip_edge_side_measure(), edgetag_add_adjacent(), erot_state_ex(), blender::bke::pbvh::merge_face_edge_data(), uvedit_loop_find_other_boundary_loop_with_visible_face(), and vs_add().
Returns true if the vertex is used in a given face.
Definition at line 314 of file bmesh_query.cc.
References BM_vert_in_face(), BMFace::l_first, BMLoop::next, BMLoop::v, and v.
Referenced by BM_face_share_vert_check(), BM_face_share_vert_count(), bm_ray_cast_cb_elem_not_in_face_check(), BM_vert_in_face(), bm_vert_in_faces_radial(), BM_vert_pair_share_face_check(), BM_vert_pair_share_face_check_cb(), bmo_subdivide_edges_exec(), collapse_face_corners(), edbm_face_split_by_edges_exec(), multires_unsubdivide_extract_grids(), and blender::bke::pbvh::vert_in_face_adjacent_to_edge().
| bool BM_vert_is_all_edge_flag_test | ( | const BMVert * | v, |
| char | hflag, | ||
| bool | respect_hide ) |
Definition at line 1926 of file bmesh_query.cc.
References BM_EDGES_OF_VERT, BM_elem_flag_test, BM_ELEM_HIDDEN, BM_ITER_ELEM, BM_vert_is_all_edge_flag_test(), BMVert::e, and v.
Referenced by BM_loop_is_adjacent(), BM_vert_is_all_edge_flag_test(), and EDBM_selectmode_convert().
| bool BM_vert_is_all_face_flag_test | ( | const BMVert * | v, |
| char | hflag, | ||
| bool | respect_hide ) |
Definition at line 1944 of file bmesh_query.cc.
References BM_elem_flag_test, BM_ELEM_HIDDEN, BM_FACES_OF_VERT, BM_ITER_ELEM, BM_vert_is_all_face_flag_test(), BMVert::e, and v.
Referenced by BM_loop_is_adjacent(), BM_vert_is_all_face_flag_test(), and EDBM_selectmode_convert().
| bool BM_vert_is_boundary | ( | const BMVert * | v | ) |
Definition at line 926 of file bmesh_query.cc.
References BM_edge_is_boundary(), BM_vert_is_boundary(), bmesh_disk_edge_next(), BMVert::e, and v.
Referenced by BM_edge_is_manifold(), BM_vert_is_boundary(), blender::ed::sculpt_paint::expand::boundary_from_enabled(), bpy_bmvert_is_boundary_get(), blender::ed::sculpt_paint::smooth::calc_relaxed_translations_bmesh(), geometry_extract_apply(), gizmo_preselect_elem_test_select(), is_vertex_pole(), is_vertex_pole_three(), blender::ed::transform::mesh_vert_is_inner(), unsubdivide_is_center_vertex_tag_valid(), blender::ed::sculpt_paint::boundary::vert_is_boundary(), and blender::ed::sculpt_paint::vert_neighbors_get_interior_bmesh().
| bool BM_vert_is_edge_pair | ( | const BMVert * | v | ) |
Fast alternative to (BM_vert_edge_count(v) == 2).
Definition at line 576 of file bmesh_query.cc.
References BM_DISK_EDGE_NEXT, BM_vert_is_edge_pair(), BMVert::e, e, and v.
Referenced by bm_face_split(), bm_loop_collapse_is_degenerate(), BM_mesh_decimate_dissolve_ex(), BM_mesh_intersect(), BM_vert_is_edge_pair(), bm_vert_other_edge(), bmo_dissolve_edges_exec(), bmo_dissolve_faces_exec(), bmo_dissolve_verts_exec(), bmo_extrude_face_region_exec(), bmo_find_end_of_chain(), bmo_offset_edgeloops_exec(), edbm_polybuild_delete_at_cursor_invoke(), edbm_polybuild_dissolve_at_cursor_invoke(), and blender::ed::transform::mesh_vert_is_inner().
| bool BM_vert_is_edge_pair_manifold | ( | const BMVert * | v | ) |
Fast alternative to (BM_vert_edge_count(v) == 2) that checks both edges connect to the same faces.
Definition at line 586 of file bmesh_query.cc.
References BM_DISK_EDGE_NEXT, BM_edge_is_manifold(), BM_vert_is_edge_pair_manifold(), BMVert::e, e, and v.
Referenced by bm_loop_pair_ends(), bm_loop_region_test_chain(), BM_vert_is_edge_pair_manifold(), bm_vert_pair_ends(), bm_vert_region_test_chain(), mesh_calc_path_region_elem(), and mesh_calc_path_region_elem().
| bool BM_vert_is_manifold | ( | const BMVert * | v | ) |
A vertex is non-manifold if it meets the following conditions: 1: Loose - (has no edges/faces incident upon it). 2: Joins two distinct regions - (two pyramids joined at the tip). 3: Is part of an edge with more than 2 faces. 4: Is part of a wire edge.
Definition at line 713 of file bmesh_query.cc.
References BLI_assert, BM_edge_is_boundary(), BM_vert_is_manifold(), BM_vert_step_fan_loop(), bmesh_disk_edge_next(), BMLoop::e, BMVert::e, BMEdge::l, BMLoop::next, BMLoop::radial_next, BMLoop::v, and v.
Referenced by BM_disk_dissolve(), BM_edge_is_wire(), BM_vert_dissolve(), BM_vert_is_manifold(), bpy_bmvert_is_manifold_get(), calc_solidify_normals(), edbm_select_by_pole_count_exec(), and edbm_select_non_manifold_exec().
| bool BM_vert_is_manifold_region | ( | const BMVert * | v | ) |
A version of BM_vert_is_manifold which only checks if we're connected to multiple isolated regions.
Definition at line 855 of file bmesh_query.cc.
References BM_loop_region_loops_count_at_most(), BM_vert_find_first_loop(), BM_vert_is_manifold_region(), and v.
Referenced by BM_edge_is_wire(), BM_vert_is_manifold_region(), and edbm_rip_invoke__vert().
| bool BM_vert_is_wire | ( | const BMVert * | v | ) |
Tests whether or not the vertex is part of a wire edge. (ie: has no faces attached to it)
Definition at line 696 of file bmesh_query.cc.
References BM_vert_is_wire(), bmesh_disk_edge_next(), BMVert::e, BMEdge::l, and v.
Referenced by bm_vert_connect_select_history(), BM_vert_is_wire(), bpy_bmvert_is_wire_get(), edbm_polybuild_delete_at_cursor_invoke(), edbm_rip_invoke__vert(), and unsubdivide_is_all_quads().
The function takes a vertex at the center of a fan and returns the opposite edge in the fan. All edges in the fan must be manifold, otherwise return NULL.
Definition at line 490 of file bmesh_query.cc.
References BLI_assert, BM_edge_is_manifold(), BM_loop_other_vert_loop(), BM_vert_in_edge(), BM_vert_other_disk_edge(), BMLoop::e, i, BMEdge::l, BMLoop::prev, BMLoop::radial_next, and v.
Referenced by BM_vert_other_disk_edge(), and edbm_rip_invoke__edge().
| BMFace * BM_vert_pair_share_face_by_angle | ( | BMVert * | v_a, |
| BMVert * | v_b, | ||
| BMLoop ** | r_l_a, | ||
| BMLoop ** | r_l_b, | ||
| bool | allow_adjacent ) |
Given 2 verts, find a face they share that has the lowest angle across these verts and give back both loops.
This can be better than BM_vert_pair_share_face_by_len because concave splits are ranked lowest.
Definition at line 259 of file bmesh_query.cc.
References bm_face_calc_split_dot(), BM_face_vert_share_loop(), BM_ITER_ELEM, BM_loop_is_adjacent(), BM_LOOPS_OF_VERT, BM_vert_pair_share_face_by_angle(), dot(), BMVert::e, BMLoop::f, and l_b.
Referenced by BM_face_splits_check_optimal(), BM_vert_pair_share_face_by_angle(), and BM_vert_pair_shared_face_cb().
| bool BMFace BMFace * BM_vert_pair_share_face_by_len | ( | BMVert * | v_a, |
| BMVert * | v_b, | ||
| BMLoop ** | r_l_a, | ||
| BMLoop ** | r_l_b, | ||
| bool | allow_adjacent ) |
Given 2 verts, find the smallest face they share and give back both loops.
Definition at line 172 of file bmesh_query.cc.
References BM_face_vert_share_loop(), BM_ITER_ELEM, BM_loop_is_adjacent(), BM_LOOPS_OF_VERT, BM_vert_pair_share_face_by_len(), BMVert::e, BMLoop::f, l_b, and BMFace::len.
Referenced by BM_vert_pair_share_face_by_len(), BM_vert_pair_shared_face_cb(), and connect_smallest_face().
Check if verts share a face.
Definition at line 106 of file bmesh_query.cc.
References BM_FACES_OF_VERT, BM_ITER_ELEM, BM_vert_in_face(), BM_vert_pair_share_face_check(), and BMVert::e.
Referenced by BM_edge_other_vert(), BM_mesh_intersect(), BM_mesh_intersect_edges(), BM_vert_pair_share_face_check(), BM_vert_splice(), and bpy_bm_utils_vert_splice().
| bool BM_vert_pair_share_face_check_cb | ( | BMVert * | v_a, |
| BMVert * | v_b, | ||
| bool(* | test_fn )(BMFace *f, void *user_data), | ||
| void * | user_data ) |
References ATTR_NONNULL, ATTR_WARN_UNUSED_RESULT, and BM_vert_pair_share_face_check_cb().
Utility function to step around a fan of loops, using an edge to mark the previous side.
Definition at line 469 of file bmesh_query.cc.
References BLI_assert, BM_edge_is_manifold(), BM_edge_other_loop(), BM_vert_step_fan_loop(), BMLoop::e, l, and BMLoop::prev.
Referenced by bevel_harden_normals(), bm_edge_collapse_loop_customdata(), BM_edge_other_vert(), BM_loop_check_cyclic_smooth_fan(), bm_mesh_loops_calc_normals_for_loop(), BM_vert_is_manifold(), BM_vert_step_fan_loop(), edbm_average_normals_exec(), and normals_split().
| BLI_INLINE bool BM_verts_in_edge | ( | const BMVert * | v1, |
| const BMVert * | v2, | ||
| const BMEdge * | e ) |
References ATTR_NONNULL, ATTR_WARN_UNUSED_RESULT, BLI_INLINE, BM_edge_calc_length(), BM_edge_calc_length_squared(), BM_edge_face_pair(), BM_edge_loop_pair(), BM_verts_in_edge(), e, and v2.
Referenced by BM_verts_in_edge(), bmesh_disk_edge_exists(), bmesh_kernel_join_edge_kill_vert(), and bmesh_kernel_split_edge_make_vert().
Return true if all verts are in the face.
Definition at line 378 of file bmesh_query.cc.
References _FLAG_OVERLAP, BM_ELEM_API_FLAG_DISABLE, BM_ELEM_API_FLAG_ENABLE, BM_ELEM_API_FLAG_TEST, BM_verts_in_face(), i, BMFace::l_first, BMFace::len, len(), BMLoop::next, and BMLoop::v.
Referenced by BM_verts_in_face().
Compares the number of vertices in an array that appear in a given face
Definition at line 338 of file bmesh_query.cc.
References _FLAG_OVERLAP, BM_ELEM_API_FLAG_DISABLE, BM_ELEM_API_FLAG_ENABLE, BM_ELEM_API_FLAG_TEST, BM_verts_in_face_count(), i, BMFace::l_first, len(), BMLoop::next, and BMLoop::v.
Referenced by BM_face_exists_overlap(), and BM_verts_in_face_count().
| int int int float bmesh_subd_falloff_calc | ( | int | falloff, |
| float | val ) |
Definition at line 2473 of file bmesh_query.cc.
References BLI_assert, bmesh_subd_falloff_calc(), sqrtf, SUBD_FALLOFF_INVSQUARE, SUBD_FALLOFF_LIN, SUBD_FALLOFF_ROOT, SUBD_FALLOFF_SHARP, SUBD_FALLOFF_SMOOTH, and SUBD_FALLOFF_SPHERE.
Referenced by alter_co(), BM_mesh_calc_edge_groups_as_arrays(), bmesh_subd_falloff_calc(), and bmo_subdivide_edgering_exec().