Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYimingWu <xp8110@outlook.com>2021-07-04 08:23:52 +0300
committerYimingWu <xp8110@outlook.com>2021-07-04 08:23:52 +0300
commit442f269a72e8f07393fd246f642e210171a1c9bc (patch)
treeecab515215209172245f7709a0c07c1b14dab96c /source/blender/editors/mesh/editmesh_tools.c
parent87dae08dd3f2a80dd208576b130cabaca21c9912 (diff)
parent2d146b61d8583ec7169c5c04263d475a542b06ce (diff)
Merge remote-tracking branch 'origin/master' into lineart-bvh
Diffstat (limited to 'source/blender/editors/mesh/editmesh_tools.c')
-rw-r--r--source/blender/editors/mesh/editmesh_tools.c34
1 files changed, 17 insertions, 17 deletions
diff --git a/source/blender/editors/mesh/editmesh_tools.c b/source/blender/editors/mesh/editmesh_tools.c
index c09ce126b7f..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);
@@ -4038,7 +4038,7 @@ static float bm_edge_seg_isect(const float sco_a[2],
b2 = ((x22 * y21) - (x21 * y22)) / xdiff2;
}
else {
- m2 = MAXSLOPE; /* Vertical slope */
+ m2 = MAXSLOPE; /* Vertical slope. */
b2 = x22;
}
@@ -4088,7 +4088,7 @@ static float bm_edge_seg_isect(const float sco_a[2],
/* Calculate the distance from point to line. */
if (m2 != MAXSLOPE) {
- /* sqrt(m2 * m2 + 1); Only looking for change in sign. Skip extra math .*/
+ /* `sqrt(m2 * m2 + 1);` Only looking for change in sign. Skip extra math. */
dist = (y12 - m2 * x12 - b2);
}
else {
@@ -4110,8 +4110,8 @@ static float bm_edge_seg_isect(const float sco_a[2],
m1 = MAXSLOPE;
b1 = x12;
}
- x2max = max_ff(x21, x22) + 0.001f; /* prevent missed edges */
- x2min = min_ff(x21, x22) - 0.001f; /* due to round off error */
+ x2max = max_ff(x21, x22) + 0.001f; /* Prevent missed edges. */
+ x2min = min_ff(x21, x22) - 0.001f; /* Due to round off error. */
y2max = max_ff(y21, y22) + 0.001f;
y2min = min_ff(y21, y22) - 0.001f;
@@ -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;
@@ -4753,7 +4753,7 @@ static int edbm_separate_exec(bContext *C, wmOperator *op)
.calc_object_remap = true,
}));
- DEG_id_tag_update(&me->id, ID_RECALC_GEOMETRY);
+ DEG_id_tag_update(&me->id, ID_RECALC_GEOMETRY_ALL_MODES);
WM_event_add_notifier(C, NC_GEOM | ND_DATA, me);
}
@@ -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++;
@@ -8219,7 +8219,7 @@ enum {
EDBM_CLNOR_MODAL_POINTTO_SET_USE_SELECTED = 114,
};
-/* called in transform_ops.c, on each regeneration of keymaps */
+/* Called in transform_ops.c, on each regeneration of key-maps. */
wmKeyMap *point_normals_modal_keymap(wmKeyConfig *keyconf)
{
static const EnumPropertyItem modal_items[] = {