diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-09-06 10:27:22 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-09-06 10:27:22 +0400 |
commit | 6fdb2ed861b8edf022e51bbc783acabbd2a0e581 (patch) | |
tree | 3b2872aca31f1494a9e8a5d9c1dfb2cfdb69c0d1 /source/blender/bmesh/intern/bmesh_polygon.h | |
parent | 6439ae9d51dfe3a77ff778e35cf83909bbc93acc (diff) |
bmesh utility functions BM_face_as_array_loop_tri, BM_face_as_array_loop_quad
also set attributes for the header and remove debug print in mask.c
Diffstat (limited to 'source/blender/bmesh/intern/bmesh_polygon.h')
-rw-r--r-- | source/blender/bmesh/intern/bmesh_polygon.h | 41 |
1 files changed, 22 insertions, 19 deletions
diff --git a/source/blender/bmesh/intern/bmesh_polygon.h b/source/blender/bmesh/intern/bmesh_polygon.h index 90f0075da26..14fe1e76360 100644 --- a/source/blender/bmesh/intern/bmesh_polygon.h +++ b/source/blender/bmesh/intern/bmesh_polygon.h @@ -30,34 +30,37 @@ #include "BLI_compiler_attrs.h" int BM_face_calc_tessellation(const BMFace *f, BMLoop **r_loops, int (*r_index)[3]) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(); -void BM_face_calc_normal(const BMFace *f, float r_no[3]); +void BM_face_calc_normal(const BMFace *f, float r_no[3]) ATTR_NONNULL(); void BM_face_calc_normal_vcos(BMesh *bm, BMFace *f, float r_no[3], - float const (*vertexCos)[3]); -float BM_face_calc_area(BMFace *f); -float BM_face_calc_perimeter(BMFace *f); -void BM_face_calc_plane(BMFace *f, float r_plane[3]); -void BM_face_calc_center_bounds(BMFace *f, float center[3]); -void BM_face_calc_center_mean(BMFace *f, float center[3]); + float const (*vertexCos)[3]) ATTR_NONNULL(); +float BM_face_calc_area(BMFace *f) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(); +float BM_face_calc_perimeter(BMFace *f) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(); +void BM_face_calc_plane(BMFace *f, float r_plane[3]) ATTR_NONNULL(); +void BM_face_calc_center_bounds(BMFace *f, float center[3]) ATTR_NONNULL(); +void BM_face_calc_center_mean(BMFace *f, float center[3]) ATTR_NONNULL(); void BM_face_calc_center_mean_vcos(BMesh *bm, BMFace *f, float r_cent[3], - float const (*vertexCos)[3]); -void BM_face_calc_center_mean_weighted(BMFace *f, float center[3]); + float const (*vertexCos)[3]) ATTR_NONNULL(); +void BM_face_calc_center_mean_weighted(BMFace *f, float center[3]) ATTR_NONNULL(); -void BM_face_normal_update(BMFace *f); +void BM_face_normal_update(BMFace *f) ATTR_NONNULL(); -void BM_edge_normals_update(BMEdge *e); +void BM_edge_normals_update(BMEdge *e) ATTR_NONNULL(); -void BM_vert_normal_update(BMVert *v); -void BM_vert_normal_update_all(BMVert *v); +void BM_vert_normal_update(BMVert *v) ATTR_NONNULL(); +void BM_vert_normal_update_all(BMVert *v) ATTR_NONNULL(); -void BM_face_normal_flip(BMesh *bm, BMFace *f); -bool BM_face_point_inside_test(BMFace *f, const float co[3]); +void BM_face_normal_flip(BMesh *bm, BMFace *f) ATTR_NONNULL(); +bool BM_face_point_inside_test(BMFace *f, const float co[3]) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(); void BM_face_triangulate(BMesh *bm, BMFace *f, BMFace **newfaces, - const bool use_beauty, const bool use_tag); + const bool use_beauty, const bool use_tag) ATTR_NONNULL(1, 2); -void BM_face_legal_splits(BMFace *f, BMLoop *(*loops)[2], int len); +void BM_face_legal_splits(BMFace *f, BMLoop *(*loops)[2], int len) ATTR_NONNULL(); -void BM_face_as_array_vert_tri(BMFace *f, BMVert *r_verts[3]); -void BM_face_as_array_vert_quad(BMFace *f, BMVert *r_verts[4]); +void BM_face_as_array_vert_tri(BMFace *f, BMVert *r_verts[3]) ATTR_NONNULL(); +void BM_face_as_array_vert_quad(BMFace *f, BMVert *r_verts[4]) ATTR_NONNULL(); + +void BM_face_as_array_loop_tri(BMFace *f, BMLoop *r_loops[3]) ATTR_NONNULL(); +void BM_face_as_array_loop_quad(BMFace *f, BMLoop *r_loops[4]) ATTR_NONNULL(); #endif /* __BMESH_POLYGON_H__ */ |