diff options
author | Campbell Barton <ideasman42@gmail.com> | 2016-05-11 21:37:36 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2016-05-11 21:37:36 +0300 |
commit | 674bf2fe58bc43cbb82098ec504960c008e8c9fe (patch) | |
tree | 401b26bf3056ad70eaf370b69f8f6f998b76a146 | |
parent | 5d93836a61284dbe1874ccf181e2bd6e9983a0de (diff) |
BMesh: add check for manifold loop
-rw-r--r-- | source/blender/bmesh/intern/bmesh_queries_inline.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/source/blender/bmesh/intern/bmesh_queries_inline.h b/source/blender/bmesh/intern/bmesh_queries_inline.h index 430ba10fb42..09cf39b526d 100644 --- a/source/blender/bmesh/intern/bmesh_queries_inline.h +++ b/source/blender/bmesh/intern/bmesh_queries_inline.h @@ -146,6 +146,13 @@ BLI_INLINE bool BM_loop_is_adjacent(const BMLoop *l_a, const BMLoop *l_b) return (ELEM(l_b, l_a->next, l_a->prev)); } +ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1) +BLI_INLINE bool BM_loop_is_manifold(const BMLoop *l) +{ + return ((l != l->radial_next) && + (l == l->radial_next->radial_next)); +} + /** * Check if we have a single wire edge user. */ |