diff options
Diffstat (limited to 'source/blender/bmesh')
-rw-r--r-- | source/blender/bmesh/intern/bmesh_edgeloop.c | 4 | ||||
-rw-r--r-- | source/blender/bmesh/intern/bmesh_mesh_convert.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/intern/bmesh_mods.c | 4 | ||||
-rw-r--r-- | source/blender/bmesh/intern/bmesh_opdefines.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/intern/bmesh_operators.c | 4 | ||||
-rw-r--r-- | source/blender/bmesh/intern/bmesh_private.h | 17 | ||||
-rw-r--r-- | source/blender/bmesh/intern/bmesh_walkers_impl.c | 4 | ||||
-rw-r--r-- | source/blender/bmesh/operators/bmo_connect_pair.c | 10 | ||||
-rw-r--r-- | source/blender/bmesh/operators/bmo_join_triangles.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/operators/bmo_subdivide.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/operators/bmo_subdivide_edgering.c | 4 | ||||
-rw-r--r-- | source/blender/bmesh/tools/bmesh_bevel.c | 9 | ||||
-rw-r--r-- | source/blender/bmesh/tools/bmesh_separate.c | 2 | ||||
-rw-r--r-- | source/blender/bmesh/tools/bmesh_wireframe.c | 2 |
14 files changed, 36 insertions, 32 deletions
diff --git a/source/blender/bmesh/intern/bmesh_edgeloop.c b/source/blender/bmesh/intern/bmesh_edgeloop.c index 51a6ada6c42..f937ccbccc5 100644 --- a/source/blender/bmesh/intern/bmesh_edgeloop.c +++ b/source/blender/bmesh/intern/bmesh_edgeloop.c @@ -50,7 +50,7 @@ typedef struct BMEdgeLoopStore { #define EDGELOOP_EPS 1e-10f /* -------------------------------------------------------------------- */ -/* BM_mesh_edgeloops_find & Util Functions */ +/* BM_mesh_edgeloops_find & Util Functions. */ static int bm_vert_other_tag(BMVert *v, BMVert *v_prev, BMEdge **r_e) { @@ -187,7 +187,7 @@ int BM_mesh_edgeloops_find(BMesh *bm, } /* -------------------------------------------------------------------- */ -/* BM_mesh_edgeloops_find_path & Util Functions */ +/* BM_mesh_edgeloops_find_path & Util Functions. */ /** * Find s single, open edge loop - given 2 vertices. diff --git a/source/blender/bmesh/intern/bmesh_mesh_convert.c b/source/blender/bmesh/intern/bmesh_mesh_convert.c index ba413c3c547..9d29a90a7a4 100644 --- a/source/blender/bmesh/intern/bmesh_mesh_convert.c +++ b/source/blender/bmesh/intern/bmesh_mesh_convert.c @@ -1001,7 +1001,7 @@ void BM_mesh_bm_to_me(Main *bmain, BMesh *bm, Mesh *me, const struct BMeshToMesh /* Topology could be changed, ensure #CD_MDISPS are ok. */ multires_topology_changed(me); - /* To be removed as soon as COW is enabled by default.. */ + /* To be removed as soon as COW is enabled by default. */ BKE_mesh_runtime_clear_geometry(me); } diff --git a/source/blender/bmesh/intern/bmesh_mods.c b/source/blender/bmesh/intern/bmesh_mods.c index 548dba242bf..c2c5dc24fa9 100644 --- a/source/blender/bmesh/intern/bmesh_mods.c +++ b/source/blender/bmesh/intern/bmesh_mods.c @@ -118,7 +118,7 @@ bool BM_disk_dissolve(BMesh *bm, BMVert *v) if (keepedge == NULL && len == 3) { #if 0 /* handle specific case for three-valence. solve it by - * increasing valence to four. this may be hackish. . */ + * increasing valence to four. this may be hackish. */ BMLoop *l_a = BM_face_vert_share_loop(e->l->f, v); BMLoop *l_b = (e->l->v == v) ? e->l->next : e->l; @@ -369,7 +369,7 @@ BMFace *BM_face_split_n(BMesh *bm, #endif /* bmesh_kernel_split_face_make_edge returns in 'l_new' * a Loop for f_new going from 'v_a' to 'v_b'. - * The radial_next is for 'f' and goes from 'v_b' to 'v_a' */ + * The radial_next is for 'f' and goes from 'v_b' to 'v_a'. */ if (f_new) { e = l_new->e; diff --git a/source/blender/bmesh/intern/bmesh_opdefines.c b/source/blender/bmesh/intern/bmesh_opdefines.c index bccac006e8e..a5cce41eee4 100644 --- a/source/blender/bmesh/intern/bmesh_opdefines.c +++ b/source/blender/bmesh/intern/bmesh_opdefines.c @@ -1337,7 +1337,7 @@ static BMOpDefine bmo_bisect_plane_def = { {{'\0'}}, }, {{"geom_cut.out", BMO_OP_SLOT_ELEMENT_BUF, {BM_VERT | BM_EDGE}}, /* output geometry aligned with the plane (new and existing) */ - {"geom.out", BMO_OP_SLOT_ELEMENT_BUF, {BM_VERT | BM_EDGE | BM_FACE}}, /* input and output geometry (result of cut) */ + {"geom.out", BMO_OP_SLOT_ELEMENT_BUF, {BM_VERT | BM_EDGE | BM_FACE}}, /* input and output geometry (result of cut). */ {{'\0'}}}, bmo_bisect_plane_exec, (BMO_OPTYPE_FLAG_UNTAN_MULTIRES | diff --git a/source/blender/bmesh/intern/bmesh_operators.c b/source/blender/bmesh/intern/bmesh_operators.c index e47fd1c035d..65285d8d464 100644 --- a/source/blender/bmesh/intern/bmesh_operators.c +++ b/source/blender/bmesh/intern/bmesh_operators.c @@ -1293,7 +1293,7 @@ static void bmo_flag_layer_alloc(BMesh *bm) bm->ftoolflagpool = BLI_mempool_create( sizeof(BMFlagLayer) * bm->totflags, bm->totface, 512, BLI_MEMPOOL_NOP); - /* now go through and memcpy all the flags. Loops don't get a flag layer at this time.. */ + /* now go through and memcpy all the flags. Loops don't get a flag layer at this time. */ BMIter iter; int i; @@ -1346,7 +1346,7 @@ static void bmo_flag_layer_free(BMesh *bm) /* store memcpy size for reuse */ const size_t new_totflags_size = ((bm->totflags - 1) * sizeof(BMFlagLayer)); - /* de-increment the totflags first.. */ + /* de-increment the totflags first. */ bm->totflags--; bm->vtoolflagpool = BLI_mempool_create(new_totflags_size, bm->totvert, 512, BLI_MEMPOOL_NOP); diff --git a/source/blender/bmesh/intern/bmesh_private.h b/source/blender/bmesh/intern/bmesh_private.h index 2c3bac6df33..e1df7744e41 100644 --- a/source/blender/bmesh/intern/bmesh_private.h +++ b/source/blender/bmesh/intern/bmesh_private.h @@ -56,16 +56,17 @@ int bmesh_disk_count(const BMVert *v); /** * Internal BMHeader.api_flag * \note Ensure different parts of the API do not conflict - * on using these internal flags!*/ + * on using these internal flags! + */ enum { - _FLAG_JF = (1 << 0), /* join faces */ - _FLAG_MF = (1 << 1), /* make face */ - _FLAG_MV = (1 << 1), /* make face, vertex */ - _FLAG_OVERLAP = (1 << 2), /* general overlap flag */ - _FLAG_WALK = (1 << 3), /* general walk flag (keep clean) */ - _FLAG_WALK_ALT = (1 << 4), /* same as _FLAG_WALK, for when a second tag is needed */ + _FLAG_JF = (1 << 0), /* Join faces. */ + _FLAG_MF = (1 << 1), /* Make face. */ + _FLAG_MV = (1 << 1), /* Make face, vertex. */ + _FLAG_OVERLAP = (1 << 2), /* General overlap flag. */ + _FLAG_WALK = (1 << 3), /* General walk flag (keep clean). */ + _FLAG_WALK_ALT = (1 << 4), /* Same as #_FLAG_WALK, for when a second tag is needed. */ - _FLAG_ELEM_CHECK = (1 << 7), /* reserved for bmesh_elem_check */ + _FLAG_ELEM_CHECK = (1 << 7), /* Reserved for bmesh_elem_check. */ }; #define BM_ELEM_API_FLAG_ENABLE(element, f) \ diff --git a/source/blender/bmesh/intern/bmesh_walkers_impl.c b/source/blender/bmesh/intern/bmesh_walkers_impl.c index a8558ec4011..40f09d7e719 100644 --- a/source/blender/bmesh/intern/bmesh_walkers_impl.c +++ b/source/blender/bmesh/intern/bmesh_walkers_impl.c @@ -1631,7 +1631,7 @@ static void *bmw_NonManifoldedgeWalker_yield(BMWalker *walker) /** * Walk over manifold loops around `v` until loop-edge is found with `face_count` users. * or return NULL if not found. - * */ + */ static BMLoop *bmw_NonManifoldLoop_find_next_around_vertex(BMLoop *l, BMVert *v, int face_count) { BLI_assert(!BM_loop_is_manifold(l)); @@ -1667,7 +1667,7 @@ static void *bmw_NonManifoldedgeWalker_step(BMWalker *walker) v = BM_edge_other_vert(e, lwalk->lastv); /* If `lwalk.lastv` can't be walked along, start walking in the opposite direction - * on the initial edge, do this at most one time during this walk operation. */ + * on the initial edge, do this at most one time during this walk operation. */ if (UNLIKELY(pass == 1)) { e = lwalk->start; v = lwalk->startv; diff --git a/source/blender/bmesh/operators/bmo_connect_pair.c b/source/blender/bmesh/operators/bmo_connect_pair.c index 8a0673c9b33..b57c8686e1c 100644 --- a/source/blender/bmesh/operators/bmo_connect_pair.c +++ b/source/blender/bmesh/operators/bmo_connect_pair.c @@ -436,7 +436,7 @@ static bool state_step(PathContext *pc, PathLinkState *state) BM_ITER_ELEM (l_start, &liter, e, BM_LOOPS_OF_EDGE) { if ((l_start->f != ele_from) && FACE_WALK_TEST(l_start->f)) { MinDistDir mddir = MIN_DIST_DIR_INIT; - /* very similar to block below */ + /* Very similar to block below. */ state = state_step__face_edges(pc, state, &state_orig, l_start->next, l_start, &mddir); state = state_step__face_verts( pc, state, &state_orig, l_start->next->next, l_start, &mddir); @@ -446,7 +446,7 @@ static bool state_step(PathContext *pc, PathLinkState *state) else if (ele->head.htype == BM_VERT) { BMVert *v = (BMVert *)ele; - /* vert loops */ + /* Vert loops. */ { BMIter liter; BMLoop *l_start; @@ -454,11 +454,11 @@ static bool state_step(PathContext *pc, PathLinkState *state) BM_ITER_ELEM (l_start, &liter, v, BM_LOOPS_OF_VERT) { if ((l_start->f != ele_from) && FACE_WALK_TEST(l_start->f)) { MinDistDir mddir = MIN_DIST_DIR_INIT; - /* very similar to block above */ + /* Very similar to block above. */ state = state_step__face_edges( pc, state, &state_orig, l_start->next, l_start->prev, &mddir); if (l_start->f->len > 3) { - /* adjacent verts are handled in state_step__vert_edges */ + /* Adjacent verts are handled in #state_step__vert_edges. */ state = state_step__face_verts( pc, state, &state_orig, l_start->next->next, l_start->prev, &mddir); } @@ -466,7 +466,7 @@ static bool state_step(PathContext *pc, PathLinkState *state) } } - /* vert edges */ + /* Vert edges. */ { BMIter eiter; BMEdge *e; diff --git a/source/blender/bmesh/operators/bmo_join_triangles.c b/source/blender/bmesh/operators/bmo_join_triangles.c index 086114f64e9..c3e96a9b08e 100644 --- a/source/blender/bmesh/operators/bmo_join_triangles.c +++ b/source/blender/bmesh/operators/bmo_join_triangles.c @@ -44,7 +44,7 @@ static float quad_calc_error(const float v1[3], { /* Gives a 'weight' to a pair of triangles that join an edge * to decide how good a join they would make. */ - /* Note: this is more complicated than it needs to be and should be cleaned up.. */ + /* Note: this is more complicated than it needs to be and should be cleaned up. */ float error = 0.0f; /* Normal difference */ diff --git a/source/blender/bmesh/operators/bmo_subdivide.c b/source/blender/bmesh/operators/bmo_subdivide.c index 883420e59f6..ae4fa65b55c 100644 --- a/source/blender/bmesh/operators/bmo_subdivide.c +++ b/source/blender/bmesh/operators/bmo_subdivide.c @@ -240,7 +240,7 @@ static void interp_slerp_co_no_v3( } } -/* calculates offset for co, based on fractal, sphere or smooth settings */ +/* Calculates offset for co, based on fractal, sphere or smooth settings. */ static void alter_co(BMVert *v, BMEdge *UNUSED(e_orig), const SubDParams *params, diff --git a/source/blender/bmesh/operators/bmo_subdivide_edgering.c b/source/blender/bmesh/operators/bmo_subdivide_edgering.c index 16d7b79a028..d5b84cb2165 100644 --- a/source/blender/bmesh/operators/bmo_subdivide_edgering.c +++ b/source/blender/bmesh/operators/bmo_subdivide_edgering.c @@ -586,7 +586,7 @@ static void bm_edgering_pair_interpolate(BMesh *bm, } /* now normals are correct, don't touch! */ - /* calculate the center spline, multiple */ + /* Calculate the center spline, multiple. */ if ((interp_mode == SUBD_RING_INTERP_PATH) || falloff_cache) { float handle_a[3], handle_b[3]; float handle_len; @@ -1028,7 +1028,7 @@ static void bm_edgering_pair_subdiv(BMesh *bm, } while ((l_iter = l_iter->next) != l_first); } - /* clear tags so subdiv verts don't get tagged too */ + /* Clear tags so subdiv verts don't get tagged too. */ for (el_store_ring = eloops_ring->first; el_store_ring; el_store_ring = BM_EDGELOOP_NEXT(el_store_ring)) { bm_edgeloop_vert_tag(el_store_ring, false); diff --git a/source/blender/bmesh/tools/bmesh_bevel.c b/source/blender/bmesh/tools/bmesh_bevel.c index d39fb5e81f1..13cd2b392d0 100644 --- a/source/blender/bmesh/tools/bmesh_bevel.c +++ b/source/blender/bmesh/tools/bmesh_bevel.c @@ -288,7 +288,10 @@ typedef struct BevVert { VMesh *vmesh; } BevVert; -/* Face classification. Note: depends on F_RECON > F_EDGE > F_VERT .*/ +/** + * Face classification. + * \note depends on `F_RECON > F_EDGE > F_VERT`. + */ typedef enum { /** Used when there is no face at all. */ F_NONE, @@ -1680,7 +1683,7 @@ static void project_to_edge(const BMEdge *e, } /* If there is a bndv->ebev edge, find the mid control point if necessary. - * It is the closest point on the beveled edge to the line segment between bndv and bndv->next. */ + * It is the closest point on the beveled edge to the line segment between bndv and bndv->next. */ static void set_profile_params(BevelParams *bp, BevVert *bv, BoundVert *bndv) { bool do_linear_interp = true; @@ -2160,7 +2163,7 @@ static void calculate_profile(BevelParams *bp, BoundVert *bndv, bool reversed, b /* Calculate the 3D locations for the profile points */ calculate_profile_segments( pro, map, use_map, reversed, bp->seg, pro_spacing->xvals, pro_spacing->yvals, pro->prof_co); - /* Also calculate for the is the seg_2 case if it's needed .*/ + /* Also calculate for the is the seg_2 case if it's needed. */ if (need_2) { calculate_profile_segments(pro, map, diff --git a/source/blender/bmesh/tools/bmesh_separate.c b/source/blender/bmesh/tools/bmesh_separate.c index 701c7dc7e03..3c69ea111bf 100644 --- a/source/blender/bmesh/tools/bmesh_separate.c +++ b/source/blender/bmesh/tools/bmesh_separate.c @@ -67,7 +67,7 @@ void BM_mesh_separate_faces(BMesh *bm, BMFaceFilterFunc filter_fn, void *user_da BMFace **faces_a = faces_array_all; BMFace **faces_b = faces_array_all + faces_a_len; - /* Enable for all */ + /* Enable for all. */ BM_mesh_elem_hflag_enable_all(bm, BM_VERT, BM_ELEM_TAG, false); /* Disable vert tag on faces_b */ diff --git a/source/blender/bmesh/tools/bmesh_wireframe.c b/source/blender/bmesh/tools/bmesh_wireframe.c index a3db93be033..de2deee2929 100644 --- a/source/blender/bmesh/tools/bmesh_wireframe.c +++ b/source/blender/bmesh/tools/bmesh_wireframe.c @@ -195,7 +195,7 @@ void BM_mesh_wireframe(BMesh *bm, BMVert **verts_neg = MEM_mallocN(sizeof(BMVert *) * totvert_orig, __func__); BMVert **verts_pos = MEM_mallocN(sizeof(BMVert *) * totvert_orig, __func__); - /* will over-alloc, but makes for easy lookups by index to keep aligned */ + /* Will over-alloc, but makes for easy lookups by index to keep aligned. */ BMVert **verts_boundary = use_boundary ? MEM_mallocN(sizeof(BMVert *) * totvert_orig, __func__) : NULL; |