diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2017-09-19 19:08:14 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2017-09-19 19:08:14 +0300 |
commit | af170839afc6334bb3ce9ea62624c6c103707dc6 (patch) | |
tree | f3536c500ad8982ce9d49dcd8014ce37904575a3 /source/blender/bmesh | |
parent | 2cdc2f2a2542f31c1c11a9913830f0ff7846888a (diff) | |
parent | b31faac17eaf66e034107f136bb00dd16361a0bf (diff) |
Merge branch 'master' into blender2.8
Diffstat (limited to 'source/blender/bmesh')
-rw-r--r-- | source/blender/bmesh/intern/bmesh_core.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/intern/bmesh_edgeloop.c | 24 | ||||
-rw-r--r-- | source/blender/bmesh/intern/bmesh_polygon.c | 6 | ||||
-rw-r--r-- | source/blender/bmesh/intern/bmesh_polygon_edgenet.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/intern/bmesh_queries.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/operators/bmo_bisect_plane.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/operators/bmo_connect.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/operators/bmo_offset_edgeloops.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/operators/bmo_removedoubles.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/operators/bmo_subdivide_edgering.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/tools/bmesh_bisect_plane.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/tools/bmesh_decimate_collapse.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/tools/bmesh_intersect.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/tools/bmesh_path_region.c | 2 |
14 files changed, 16 insertions, 38 deletions
diff --git a/source/blender/bmesh/intern/bmesh_core.c b/source/blender/bmesh/intern/bmesh_core.c index 6b22fd0a85c..c7ff93cf504 100644 --- a/source/blender/bmesh/intern/bmesh_core.c +++ b/source/blender/bmesh/intern/bmesh_core.c @@ -32,7 +32,7 @@ #include "BLI_array.h" #include "BLI_alloca.h" #include "BLI_linklist_stack.h" -#include "BLI_stackdefines.h" +#include "BLI_utildefines_stack.h" #include "BLT_translation.h" diff --git a/source/blender/bmesh/intern/bmesh_edgeloop.c b/source/blender/bmesh/intern/bmesh_edgeloop.c index 97840df3a5d..b3b23933d2f 100644 --- a/source/blender/bmesh/intern/bmesh_edgeloop.c +++ b/source/blender/bmesh/intern/bmesh_edgeloop.c @@ -32,6 +32,7 @@ #include "BLI_math_vector.h" #include "BLI_listbase.h" #include "BLI_mempool.h" +#include "BLI_utildefines_iter.h" #include "bmesh.h" @@ -707,29 +708,6 @@ void BM_edgeloop_expand( split_swap = !split_swap; } - /* TODO, move to generic define? */ - /** - * Even value distribution. - * - * \a src must be larger than \a dst, - * \a dst defines the number of iterations, their values are evenly spaced. - * - * The following pairs represent (src, dst) arguments and the values they loop over. - * <pre> - * (19, 4) -> [2, 7, 11. 16] - * (100, 5) -> [9, 29, 49, 69, 89] - * (100, 3) -> [16, 49, 83] - * (100, 100) -> [0..99] - * </pre> - * \note this is mainly useful for numbers that might not divide evenly into eachother. - */ -#define BLI_FOREACH_SPARSE_RANGE(src, dst, i) \ - for (int _src = (src), _src2 = _src * 2, _dst2 = (dst) * 2, _error = _dst2 - _src, i = 0, _delta; \ - ((void)(_delta = divide_floor_i(_error, _dst2)), \ - (void)(i -= _delta), \ - (i < _src)); \ - _error -= (_delta * _dst2) + _src2) - if (el_store->len < el_store_len) { LinkData *node_curr = el_store->verts.first; diff --git a/source/blender/bmesh/intern/bmesh_polygon.c b/source/blender/bmesh/intern/bmesh_polygon.c index f0023470099..7b9d17b27b5 100644 --- a/source/blender/bmesh/intern/bmesh_polygon.c +++ b/source/blender/bmesh/intern/bmesh_polygon.c @@ -1523,7 +1523,7 @@ void BM_mesh_calc_tessellation_beauty(BMesh *bm, BMLoop *(*looptris)[3], int *r_ * Use #BLI_polyfill_beautify_quad_rotate_calc since we have the normal. */ #if 0 - const bool split_24 = (BM_verts_calc_rotate_beauty( + const bool split_13 = (BM_verts_calc_rotate_beauty( l_v1->v, l_v2->v, l_v3->v, l_v4->v, 0, 0) < 0.0f); #else float axis_mat[3][3], v_quad[4][2]; @@ -1533,13 +1533,13 @@ void BM_mesh_calc_tessellation_beauty(BMesh *bm, BMLoop *(*looptris)[3], int *r_ mul_v2_m3v3(v_quad[2], axis_mat, l_v3->v->co); mul_v2_m3v3(v_quad[3], axis_mat, l_v4->v->co); - const bool split_24 = BLI_polyfill_beautify_quad_rotate_calc( + const bool split_13 = BLI_polyfill_beautify_quad_rotate_calc( v_quad[0], v_quad[1], v_quad[2], v_quad[3]) < 0.0f; #endif BMLoop **l_ptr_a = looptris[i++]; BMLoop **l_ptr_b = looptris[i++]; - if (split_24 == 0) { + if (split_13) { l_ptr_a[0] = l_v1; l_ptr_a[1] = l_v2; l_ptr_a[2] = l_v3; diff --git a/source/blender/bmesh/intern/bmesh_polygon_edgenet.c b/source/blender/bmesh/intern/bmesh_polygon_edgenet.c index 1b35f049838..8a3cb329610 100644 --- a/source/blender/bmesh/intern/bmesh_polygon_edgenet.c +++ b/source/blender/bmesh/intern/bmesh_polygon_edgenet.c @@ -32,7 +32,7 @@ #include "BLI_memarena.h" #include "BLI_array.h" #include "BLI_alloca.h" -#include "BLI_stackdefines.h" +#include "BLI_utildefines_stack.h" #include "BLI_linklist_stack.h" #include "BLI_sort.h" #include "BLI_sort_utils.h" diff --git a/source/blender/bmesh/intern/bmesh_queries.c b/source/blender/bmesh/intern/bmesh_queries.c index 88f45c06c20..5bdc3927e16 100644 --- a/source/blender/bmesh/intern/bmesh_queries.c +++ b/source/blender/bmesh/intern/bmesh_queries.c @@ -36,7 +36,7 @@ #include "BLI_math.h" #include "BLI_alloca.h" #include "BLI_linklist.h" -#include "BLI_stackdefines.h" +#include "BLI_utildefines_stack.h" #include "BKE_customdata.h" diff --git a/source/blender/bmesh/operators/bmo_bisect_plane.c b/source/blender/bmesh/operators/bmo_bisect_plane.c index 2c80ff651b8..ed232e81b82 100644 --- a/source/blender/bmesh/operators/bmo_bisect_plane.c +++ b/source/blender/bmesh/operators/bmo_bisect_plane.c @@ -29,7 +29,7 @@ #include "MEM_guardedalloc.h" #include "BLI_utildefines.h" -#include "BLI_stackdefines.h" +#include "BLI_utildefines_stack.h" #include "BLI_math.h" #include "bmesh.h" diff --git a/source/blender/bmesh/operators/bmo_connect.c b/source/blender/bmesh/operators/bmo_connect.c index c5c4ac959a9..0b5f1bb9ca1 100644 --- a/source/blender/bmesh/operators/bmo_connect.c +++ b/source/blender/bmesh/operators/bmo_connect.c @@ -27,7 +27,7 @@ */ #include "BLI_utildefines.h" -#include "BLI_stackdefines.h" +#include "BLI_utildefines_stack.h" #include "BLI_alloca.h" #include "BLI_linklist_stack.h" diff --git a/source/blender/bmesh/operators/bmo_offset_edgeloops.c b/source/blender/bmesh/operators/bmo_offset_edgeloops.c index a9840a72fc9..269f933f27f 100644 --- a/source/blender/bmesh/operators/bmo_offset_edgeloops.c +++ b/source/blender/bmesh/operators/bmo_offset_edgeloops.c @@ -33,7 +33,7 @@ #include "BLI_math.h" #include "BLI_alloca.h" -#include "BLI_stackdefines.h" +#include "BLI_utildefines_stack.h" #include "BKE_customdata.h" diff --git a/source/blender/bmesh/operators/bmo_removedoubles.c b/source/blender/bmesh/operators/bmo_removedoubles.c index d8e6f250adf..e85751531ae 100644 --- a/source/blender/bmesh/operators/bmo_removedoubles.c +++ b/source/blender/bmesh/operators/bmo_removedoubles.c @@ -31,7 +31,7 @@ #include "BLI_math.h" #include "BLI_alloca.h" #include "BLI_kdtree.h" -#include "BLI_stackdefines.h" +#include "BLI_utildefines_stack.h" #include "BLI_stack.h" #include "BKE_customdata.h" diff --git a/source/blender/bmesh/operators/bmo_subdivide_edgering.c b/source/blender/bmesh/operators/bmo_subdivide_edgering.c index 94b60a51f68..adcc0c71629 100644 --- a/source/blender/bmesh/operators/bmo_subdivide_edgering.c +++ b/source/blender/bmesh/operators/bmo_subdivide_edgering.c @@ -40,7 +40,7 @@ #include "MEM_guardedalloc.h" #include "BLI_utildefines.h" -#include "BLI_stackdefines.h" +#include "BLI_utildefines_stack.h" #include "BLI_alloca.h" #include "BLI_math.h" #include "BLI_listbase.h" diff --git a/source/blender/bmesh/tools/bmesh_bisect_plane.c b/source/blender/bmesh/tools/bmesh_bisect_plane.c index 676a8de94c8..f3927a3ff67 100644 --- a/source/blender/bmesh/tools/bmesh_bisect_plane.c +++ b/source/blender/bmesh/tools/bmesh_bisect_plane.c @@ -38,7 +38,7 @@ #include "MEM_guardedalloc.h" #include "BLI_utildefines.h" -#include "BLI_stackdefines.h" +#include "BLI_utildefines_stack.h" #include "BLI_alloca.h" #include "BLI_linklist.h" #include "BLI_linklist_stack.h" diff --git a/source/blender/bmesh/tools/bmesh_decimate_collapse.c b/source/blender/bmesh/tools/bmesh_decimate_collapse.c index c417131d588..36ae7231f94 100644 --- a/source/blender/bmesh/tools/bmesh_decimate_collapse.c +++ b/source/blender/bmesh/tools/bmesh_decimate_collapse.c @@ -40,7 +40,7 @@ #include "BLI_edgehash.h" #include "BLI_polyfill2d.h" #include "BLI_polyfill2d_beautify.h" -#include "BLI_stackdefines.h" +#include "BLI_utildefines_stack.h" #include "BKE_customdata.h" diff --git a/source/blender/bmesh/tools/bmesh_intersect.c b/source/blender/bmesh/tools/bmesh_intersect.c index cfb43181703..82545a5e011 100644 --- a/source/blender/bmesh/tools/bmesh_intersect.c +++ b/source/blender/bmesh/tools/bmesh_intersect.c @@ -44,7 +44,7 @@ #include "BLI_sort_utils.h" #include "BLI_linklist_stack.h" -#include "BLI_stackdefines.h" +#include "BLI_utildefines_stack.h" #ifndef NDEBUG # include "BLI_array_utils.h" #endif diff --git a/source/blender/bmesh/tools/bmesh_path_region.c b/source/blender/bmesh/tools/bmesh_path_region.c index 27609ec3d48..d23ea537d82 100644 --- a/source/blender/bmesh/tools/bmesh_path_region.c +++ b/source/blender/bmesh/tools/bmesh_path_region.c @@ -29,7 +29,7 @@ #include "BLI_math.h" #include "BLI_linklist.h" -#include "BLI_stackdefines.h" +#include "BLI_utildefines_stack.h" #include "BLI_alloca.h" #include "bmesh.h" |