From e1a54214bbed9b32e1aee0e849ae654c495afa80 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Mon, 25 Mar 2013 02:41:30 +0000 Subject: code cleanup: - remove unused defines. - quiet some shadow warnings. - bevel, ifdef out some asserts that are too common. - style --- source/blender/bmesh/tools/bmesh_bevel.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'source/blender/bmesh') diff --git a/source/blender/bmesh/tools/bmesh_bevel.c b/source/blender/bmesh/tools/bmesh_bevel.c index f685b741176..525bf3a2da7 100644 --- a/source/blender/bmesh/tools/bmesh_bevel.c +++ b/source/blender/bmesh/tools/bmesh_bevel.c @@ -43,11 +43,12 @@ #include "bmesh.h" #include "./intern/bmesh_private.h" - - #define BEVEL_EPSILON_D 1e-6 #define BEVEL_EPSILON 1e-6f +/* happens far too often, uncomment for development */ +// #define BEVEL_ASSERT_PROJECT + /* for testing */ // #pragma GCC diagnostic error "-Wpadded" @@ -369,7 +370,9 @@ static void offset_meet(EdgeHalf *e1, EdgeHalf *e2, BMVert *v, BMFace *f, /* intersect the lines; by construction they should be on the same plane and not parallel */ if (!isect_line_line_v3(off1a, off1b, off2a, off2b, meetco, isect2)) { +#ifdef BEVEL_ASSERT_PROJECT BLI_assert(!"offset_meet failure"); +#endif copy_v3_v3(meetco, off1a); /* just to do something */ } } @@ -485,7 +488,9 @@ static void project_to_edge(BMEdge *e, const float co_a[3], const float co_b[3], float otherco[3]; if (!isect_line_line_v3(e->v1->co, e->v2->co, co_a, co_b, projco, otherco)) { +#ifdef BEVEL_ASSERT_PROJECT BLI_assert(!"project meet failure"); +#endif copy_v3_v3(projco, e->v1->co); } } -- cgit v1.2.3