diff options
author | Campbell Barton <ideasman42@gmail.com> | 2021-06-26 14:35:18 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2021-06-26 14:50:48 +0300 |
commit | f1e49038543cf75766f4a220f62cdc6cdbc0e27d (patch) | |
tree | 0cec2c64739a6a4ca246fe26bed6fe629ea315cb /source/blender/editors/mesh | |
parent | fae5a907d4d1380f087f1226ebbd65d9d0718cc6 (diff) |
Cleanup: full sentences in comments, improve comment formatting
Diffstat (limited to 'source/blender/editors/mesh')
-rw-r--r-- | source/blender/editors/mesh/editmesh_extrude.c | 2 | ||||
-rw-r--r-- | source/blender/editors/mesh/editmesh_knife.c | 4 | ||||
-rw-r--r-- | source/blender/editors/mesh/editmesh_select.c | 2 | ||||
-rw-r--r-- | source/blender/editors/mesh/editmesh_tools.c | 22 | ||||
-rw-r--r-- | source/blender/editors/mesh/editmesh_utils.c | 10 | ||||
-rw-r--r-- | source/blender/editors/mesh/mesh_data.c | 2 | ||||
-rw-r--r-- | source/blender/editors/mesh/mesh_intern.h | 2 |
7 files changed, 22 insertions, 22 deletions
diff --git a/source/blender/editors/mesh/editmesh_extrude.c b/source/blender/editors/mesh/editmesh_extrude.c index e03390780f9..907881a44f3 100644 --- a/source/blender/editors/mesh/editmesh_extrude.c +++ b/source/blender/editors/mesh/editmesh_extrude.c @@ -509,7 +509,7 @@ static int edbm_extrude_context_exec(bContext *C, wmOperator *op) edbm_extrude_mesh(obedit, em, op); /* This normally happens when pushing undo but modal operators - * like this one don't push undo data until after modal mode is done.*/ + * like this one don't push undo data until after modal mode is done. */ EDBM_update(obedit->data, &(const struct EDBMUpdate_Params){ .calc_looptri = true, diff --git a/source/blender/editors/mesh/editmesh_knife.c b/source/blender/editors/mesh/editmesh_knife.c index af4ce0abe5f..0e2dd492e06 100644 --- a/source/blender/editors/mesh/editmesh_knife.c +++ b/source/blender/editors/mesh/editmesh_knife.c @@ -937,7 +937,7 @@ static KnifeVert *knife_split_edge(KnifeTool_OpData *kcd, static void knife_start_cut(KnifeTool_OpData *kcd) { kcd->prev = kcd->curr; - kcd->curr.is_space = 0; /*TODO: why do we do this? */ + kcd->curr.is_space = 0; /* TODO: why do we do this? */ if (kcd->prev.vert == NULL && kcd->prev.edge == NULL) { float origin[3], origin_ofs[3]; @@ -952,7 +952,7 @@ static void knife_start_cut(KnifeTool_OpData *kcd) zero_v3(kcd->prev.cage); } - copy_v3_v3(kcd->prev.co, kcd->prev.cage); /*TODO: do we need this? */ + copy_v3_v3(kcd->prev.co, kcd->prev.cage); /* TODO: do we need this? */ copy_v3_v3(kcd->curr.cage, kcd->prev.cage); copy_v3_v3(kcd->curr.co, kcd->prev.co); } diff --git a/source/blender/editors/mesh/editmesh_select.c b/source/blender/editors/mesh/editmesh_select.c index fc32a2d9bab..4a87266f1c9 100644 --- a/source/blender/editors/mesh/editmesh_select.c +++ b/source/blender/editors/mesh/editmesh_select.c @@ -1805,7 +1805,7 @@ static bool mouse_mesh_loop( V3D_PROJ_RET_OK) { tdist = len_squared_v2v2(mvalf, co); if (tdist < best_dist) { - /* printf("Best face: %p (%f)\n", f, tdist);*/ + // printf("Best face: %p (%f)\n", f, tdist); best_dist = tdist; efa = f; } diff --git a/source/blender/editors/mesh/editmesh_tools.c b/source/blender/editors/mesh/editmesh_tools.c index ee520753478..fe9656d277e 100644 --- a/source/blender/editors/mesh/editmesh_tools.c +++ b/source/blender/editors/mesh/editmesh_tools.c @@ -2309,8 +2309,8 @@ static int edbm_edge_rotate_selected_exec(bContext *C, wmOperator *op) } } - /* ok, we don't have two adjacent faces, but we do have two selected ones. - * that's an error condition.*/ + /* OK, we don't have two adjacent faces, but we do have two selected ones. + * that's an error condition. */ if (tot == 0) { continue; } @@ -3639,7 +3639,7 @@ void MESH_OT_remove_doubles(wmOperatorType *ot) /** \name Shape Key Propagate Operator * \{ */ -/* BMESH_TODO this should be properly encapsulated in a bmop. but later.*/ +/* BMESH_TODO this should be properly encapsulated in a bmop. but later. */ static bool shape_propagate(BMEditMesh *em) { BMIter iter; @@ -3732,7 +3732,7 @@ void MESH_OT_shape_propagate_to_all(wmOperatorType *ot) /** \name Blend from Shape Operator * \{ */ -/* BMESH_TODO this should be properly encapsulated in a bmop. but later.*/ +/* BMESH_TODO this should be properly encapsulated in a bmop. but later. */ static int edbm_blend_from_shape_exec(bContext *C, wmOperator *op) { Object *obedit_ref = CTX_data_edit_object(C); @@ -4139,9 +4139,9 @@ static float bm_edge_seg_isect(const float sco_a[2], yi = (b1 * m2 - m1 * b2) / (m2 - m1); } - /* Intersect inside bounding box of edge?*/ + /* Intersect inside bounding box of edge? */ if ((xi >= x2min) && (xi <= x2max) && (yi <= y2max) && (yi >= y2min)) { - /* test for vertex intersect that may be 'close enough'*/ + /* Test for vertex intersect that may be 'close enough'. */ if (mode != KNIFE_MULTICUT) { if (xi <= (x21 + threshold) && xi >= (x21 - threshold)) { if (yi <= (y21 + threshold) && yi >= (y21 - threshold)) { @@ -4244,7 +4244,7 @@ static int edbm_knife_cut_exec(bContext *C, wmOperator *op) return OPERATOR_CANCELLED; } - /* store percentage of edge cut for KNIFE_EXACT here.*/ + /* Store percentage of edge cut for KNIFE_EXACT here. */ BMOpSlot *slot_edge_percents = BMO_slot_get(bmop.slots_in, "edge_percents"); BM_ITER_MESH (be, &iter, bm, BM_EDGES_OF_MESH) { bool is_cut = false; @@ -6958,9 +6958,9 @@ static void sort_bmelem_flag(bContext *C, } } - /* printf("%d vertices: %d to be affected...\n", totelem[0], affected[0]);*/ - /* printf("%d edges: %d to be affected...\n", totelem[1], affected[1]);*/ - /* printf("%d faces: %d to be affected...\n", totelem[2], affected[2]);*/ + // printf("%d vertices: %d to be affected...\n", totelem[0], affected[0]); + // printf("%d edges: %d to be affected...\n", totelem[1], affected[1]); + // printf("%d faces: %d to be affected...\n", totelem[2], affected[2]); if (affected[0] == 0 && affected[1] == 0 && affected[2] == 0) { for (j = 3; j--;) { if (pblock[j]) { @@ -7221,7 +7221,7 @@ static int edbm_bridge_tag_boundary_edges(BMesh *bm) /* check if its only used by selected faces */ BM_ITER_ELEM (f, &fiter, e, BM_FACES_OF_EDGE) { if (BM_elem_flag_test(f, BM_ELEM_SELECT)) { - /* tag face for removal*/ + /* Tag face for removal. */ if (!BM_elem_flag_test(f, BM_ELEM_TAG)) { BM_elem_flag_enable(f, BM_ELEM_TAG); totface_del++; diff --git a/source/blender/editors/mesh/editmesh_utils.c b/source/blender/editors/mesh/editmesh_utils.c index 54a7b0dd22e..141b69f0465 100644 --- a/source/blender/editors/mesh/editmesh_utils.c +++ b/source/blender/editors/mesh/editmesh_utils.c @@ -1011,7 +1011,7 @@ BMFace *EDBM_uv_active_face_get(BMEditMesh *em, const bool sloppy, const bool se return NULL; } -/* can we edit UV's for this mesh?*/ +/* Can we edit UV's for this mesh? */ bool EDBM_uv_check(BMEditMesh *em) { /* some of these checks could be a touch overkill */ @@ -1689,8 +1689,8 @@ bool BMBVH_EdgeVisible(struct BMBVHTree *tree, scale_point(co1, co2, 0.99); scale_point(co3, co2, 0.99); - /* ok, idea is to generate rays going from the camera origin to the - * three points on the edge (v1, mid, v2)*/ + /* OK, idea is to generate rays going from the camera origin to the + * three points on the edge (v1, mid, v2). */ sub_v3_v3v3(dir1, origin, co1); sub_v3_v3v3(dir2, origin, co2); sub_v3_v3v3(dir3, origin, co3); @@ -1699,8 +1699,8 @@ bool BMBVH_EdgeVisible(struct BMBVHTree *tree, normalize_v3_length(dir2, epsilon); normalize_v3_length(dir3, epsilon); - /* offset coordinates slightly along view vectors, to avoid - * hitting the faces that own the edge.*/ + /* Offset coordinates slightly along view vectors, + * to avoid hitting the faces that own the edge. */ add_v3_v3v3(co1, co1, dir1); add_v3_v3v3(co2, co2, dir2); add_v3_v3v3(co3, co3, dir3); diff --git a/source/blender/editors/mesh/mesh_data.c b/source/blender/editors/mesh/mesh_data.c index 222476e6971..7c6dc6516ed 100644 --- a/source/blender/editors/mesh/mesh_data.c +++ b/source/blender/editors/mesh/mesh_data.c @@ -166,7 +166,7 @@ static void mesh_uv_reset_array(float **fuv, const int len) fuv[3][0] = 0.0; fuv[3][1] = 1.0; - /*make sure we ignore 2-sided faces*/ + /* Make sure we ignore 2-sided faces. */ } else if (len > 2) { float fac = 0.0f, dfac = 1.0f / (float)len; diff --git a/source/blender/editors/mesh/mesh_intern.h b/source/blender/editors/mesh/mesh_intern.h index 9e2e2786347..f25317e8e85 100644 --- a/source/blender/editors/mesh/mesh_intern.h +++ b/source/blender/editors/mesh/mesh_intern.h @@ -51,7 +51,7 @@ bool EDBM_op_call_and_selectf(struct BMEditMesh *em, const bool select_replace, const char *fmt, ...); -/* Same as above, but doesn't report errors.*/ +/* Same as above, but doesn't report errors. */ bool EDBM_op_call_silentf(struct BMEditMesh *em, const char *fmt, ...); /* these next two functions are the split version of EDBM_op_callf, so you can |