[Bf-blender-cvs] [ced94bc11c8] master: Cleanup: code comments punctuation / spacing

Campbell Barton noreply at git.blender.org
Fri Jul 23 09:08:19 CEST 2021


Commit: ced94bc11c84f3c997949c2a0ec2449054a8e417
Author: Campbell Barton
Date:   Fri Jul 23 16:56:00 2021 +1000
Branches: master
https://developer.blender.org/rBced94bc11c84f3c997949c2a0ec2449054a8e417

Cleanup: code comments punctuation / spacing

===================================================================

M	intern/ghost/intern/GHOST_SystemWin32.h
M	release/datafiles/userdef/userdef_default.c
M	source/blender/blenkernel/BKE_customdata.h
M	source/blender/blenkernel/intern/boids.c
M	source/blender/blenkernel/intern/editmesh.c
M	source/blender/blenkernel/intern/icons.cc
M	source/blender/blenkernel/intern/layer.c
M	source/blender/blenkernel/intern/paint.c
M	source/blender/blenkernel/intern/subsurf_ccg.c
M	source/blender/blenkernel/intern/writeffmpeg.c
M	source/blender/blenlib/intern/BLI_kdopbvh.c
M	source/blender/blenlib/intern/math_interp.c
M	source/blender/blenlib/intern/math_matrix.c
M	source/blender/blenlib/intern/string_utils.c
M	source/blender/blenlib/tests/BLI_mesh_intersect_test.cc
M	source/blender/blenloader/intern/readfile.c
M	source/blender/bmesh/bmesh_class.h
M	source/blender/bmesh/intern/bmesh_query.h
M	source/blender/bmesh/tools/bmesh_region_match.c
M	source/blender/compositor/operations/COM_DoubleEdgeMaskOperation.cc
M	source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
M	source/blender/draw/engines/gpencil/shaders/gpencil_common_lib.glsl
M	source/blender/draw/intern/DRW_render.h
M	source/blender/draw/intern/draw_instance_data.c
M	source/blender/editors/armature/pose_lib_2.c
M	source/blender/editors/interface/interface_handlers.c
M	source/blender/editors/render/render_update.c
M	source/blender/editors/sculpt_paint/sculpt_filter_color.c
M	source/blender/editors/sculpt_paint/sculpt_paint_color.c
M	source/blender/editors/space_graph/graph_edit.c
M	source/blender/editors/space_graph/graph_view.c
M	source/blender/editors/space_image/image_buttons.c
M	source/blender/editors/space_node/node_relationships.cc
M	source/blender/editors/space_node/node_select.cc
M	source/blender/editors/space_outliner/outliner_select.c
M	source/blender/editors/transform/transform_convert_mesh.c
M	source/blender/editors/transform/transform_generics.c
M	source/blender/editors/transform/transform_orientations.c
M	source/blender/editors/uvedit/uvedit_select.c
M	source/blender/freestyle/intern/view_map/Interface0D.h
M	source/blender/freestyle/intern/view_map/Silhouette.h
M	source/blender/freestyle/intern/view_map/ViewMap.h
M	source/blender/gpencil_modifiers/intern/MOD_gpencil_ui_common.c
M	source/blender/gpencil_modifiers/intern/lineart/lineart_cpu.c
M	source/blender/gpu/intern/gpu_framebuffer.cc
M	source/blender/imbuf/intern/iris.c
M	source/blender/imbuf/intern/openexr/openexr_api.cpp
M	source/blender/imbuf/intern/scaling.c
M	source/blender/io/collada/ControllerExporter.cpp
M	source/blender/io/collada/DocumentExporter.cpp
M	source/blender/io/collada/MeshImporter.cpp
M	source/blender/makesdna/DNA_action_types.h
M	source/blender/makesdna/DNA_anim_types.h
M	source/blender/makesdna/DNA_constraint_types.h
M	source/blender/makesdna/DNA_ipo_types.h
M	source/blender/makesdna/DNA_light_types.h
M	source/blender/makesdna/DNA_mask_types.h
M	source/blender/makesdna/DNA_object_types.h
M	source/blender/makesdna/DNA_rigidbody_types.h
M	source/blender/makesdna/DNA_scene_types.h
M	source/blender/makesdna/DNA_screen_types.h
M	source/blender/makesdna/DNA_userdef_types.h
M	source/blender/makesdna/DNA_view2d_types.h
M	source/blender/makesdna/DNA_windowmanager_types.h
M	source/blender/makesrna/RNA_types.h
M	source/blender/makesrna/intern/rna_access.c
M	source/blender/makesrna/intern/rna_rna.c
M	source/blender/modifiers/intern/MOD_array.c
M	source/blender/modifiers/intern/MOD_nodes.cc
M	source/blender/modifiers/intern/MOD_ui_common.c
M	source/blender/modifiers/intern/MOD_weighted_normal.c
M	source/blender/modifiers/intern/MOD_weightvg_util.c
M	source/blender/nodes/composite/node_composite_tree.c
M	source/blender/python/BPY_extern.h
M	source/blender/python/intern/bpy_operator.c
M	source/blender/python/intern/bpy_rna_anim.c
M	source/blender/python/mathutils/mathutils_noise.c
M	source/blender/render/intern/texture_image.c
M	source/blender/sequencer/intern/effects.c
M	source/blender/sequencer/intern/strip_edit.c
M	source/blender/sequencer/intern/strip_time.c
M	source/blender/shader_fx/intern/FX_ui_common.c
M	source/blender/simulation/intern/implicit_blender.c
M	source/blender/simulation/intern/implicit_eigen.cpp
M	source/blender/windowmanager/intern/wm_keymap_utils.c
M	source/blender/windowmanager/wm_surface.h

===================================================================

diff --git a/intern/ghost/intern/GHOST_SystemWin32.h b/intern/ghost/intern/GHOST_SystemWin32.h
index 6c786aedfb1..17e9adff8bc 100644
--- a/intern/ghost/intern/GHOST_SystemWin32.h
+++ b/intern/ghost/intern/GHOST_SystemWin32.h
@@ -360,8 +360,8 @@ class GHOST_SystemWin32 : public GHOST_System {
   static GHOST_EventKey *processKeyEvent(GHOST_WindowWin32 *window, RAWINPUT const &raw);
 
   /**
-   * Process special keys (VK_OEM_*), to see if current key layout
-   * gives us anything special, like ! on french AZERTY.
+   * Process special keys `VK_OEM_*`, to see if current key layout
+   * gives us anything special, like `!` on French AZERTY.
    * \param vKey: The virtual key from #hardKey.
    * \param scanCode: The ScanCode of pressed key (similar to PS/2 Set 1).
    */
diff --git a/release/datafiles/userdef/userdef_default.c b/release/datafiles/userdef/userdef_default.c
index 6220edce28f..d51a82c482b 100644
--- a/release/datafiles/userdef/userdef_default.c
+++ b/release/datafiles/userdef/userdef_default.c
@@ -113,7 +113,7 @@ const UserDef U_default = {
     .gp_eraser = 25,
     .gp_settings = 0,
 
-    /** Initialized by: #BKE_studiolight_default . */
+    /** Initialized by: #BKE_studiolight_default. */
     .light_param = {{0}},
     .light_ambient = {0, 0, 0},
 
diff --git a/source/blender/blenkernel/BKE_customdata.h b/source/blender/blenkernel/BKE_customdata.h
index c4db8ee925e..7a44553c565 100644
--- a/source/blender/blenkernel/BKE_customdata.h
+++ b/source/blender/blenkernel/BKE_customdata.h
@@ -501,7 +501,7 @@ enum {
   CD_FAKE = 1 << 8,
 
   /* Vertices. */
-  CD_FAKE_MDEFORMVERT = CD_FAKE | CD_MDEFORMVERT, /* *sigh* due to how vgroups are stored :( . */
+  CD_FAKE_MDEFORMVERT = CD_FAKE | CD_MDEFORMVERT, /* *sigh* due to how vgroups are stored :(. */
   CD_FAKE_SHAPEKEY = CD_FAKE |
                      CD_SHAPEKEY, /* Not available as real CD layer in non-bmesh context. */
 
diff --git a/source/blender/blenkernel/intern/boids.c b/source/blender/blenkernel/intern/boids.c
index efd0fc71b20..9caf416cd0c 100644
--- a/source/blender/blenkernel/intern/boids.c
+++ b/source/blender/blenkernel/intern/boids.c
@@ -1072,7 +1072,7 @@ static BoidState *get_boid_state(BoidSettings *boids, ParticleData *pa)
   return state;
 }
 
-#if 0 /* TODO  */
+#if 0 /* TODO */
 static int boid_condition_is_true(BoidCondition *cond)
 {
  return 0;
diff --git a/source/blender/blenkernel/intern/editmesh.c b/source/blender/blenkernel/intern/editmesh.c
index 9cae74e4e9a..83e03ef44f5 100644
--- a/source/blender/blenkernel/intern/editmesh.c
+++ b/source/blender/blenkernel/intern/editmesh.c
@@ -306,7 +306,7 @@ const float (*BKE_editmesh_vert_coords_when_deformed(struct Depsgraph *depsgraph
   }
   else if ((em->mesh_eval_final != NULL) &&
            (em->mesh_eval_final->runtime.wrapper_type == ME_WRAPPER_TYPE_BMESH)) {
-    /* If this is an edit-mesh type, leave NULL as we can use the vertex coords. . */
+    /* If this is an edit-mesh type, leave NULL as we can use the vertex coords. */
   }
   else {
     /* Constructive modifiers have been used, we need to allocate coordinates. */
diff --git a/source/blender/blenkernel/intern/icons.cc b/source/blender/blenkernel/intern/icons.cc
index 7e9f81f9c83..12a0a1e3ae7 100644
--- a/source/blender/blenkernel/intern/icons.cc
+++ b/source/blender/blenkernel/intern/icons.cc
@@ -667,7 +667,7 @@ void BKE_previewimg_blend_read(BlendDataReader *reader, PreviewImage *prv)
       BKE_previewimg_finish(prv, i);
     }
     else {
-      /* Only for old files that didn't write the flag . */
+      /* Only for old files that didn't write the flag. */
       prv->flag[i] |= PRV_UNFINISHED;
     }
   }
diff --git a/source/blender/blenkernel/intern/layer.c b/source/blender/blenkernel/intern/layer.c
index 730c989abc9..28282aaa823 100644
--- a/source/blender/blenkernel/intern/layer.c
+++ b/source/blender/blenkernel/intern/layer.c
@@ -1237,7 +1237,7 @@ void BKE_layer_collection_isolate_global(Scene *scene,
   bool hide_it = extend && (lc->runtime_flag & LAYER_COLLECTION_VISIBLE_VIEW_LAYER);
 
   if (!extend) {
-    /* Hide all collections . */
+    /* Hide all collections. */
     LISTBASE_FOREACH (LayerCollection *, lc_iter, &lc_master->layer_collections) {
       layer_collection_flag_set_recursive(lc_iter, LAYER_COLLECTION_HIDE);
     }
diff --git a/source/blender/blenkernel/intern/paint.c b/source/blender/blenkernel/intern/paint.c
index 1af66fa090b..a1fa6aae1ce 100644
--- a/source/blender/blenkernel/intern/paint.c
+++ b/source/blender/blenkernel/intern/paint.c
@@ -880,7 +880,7 @@ static int palettecolor_compare_luminance(const void *a1, const void *a2)
 
 void BKE_palette_sort_hsv(tPaletteColorHSV *color_array, const int totcol)
 {
-  /* Sort by Hue , Saturation and Value. */
+  /* Sort by Hue, Saturation and Value. */
   qsort(color_array, totcol, sizeof(tPaletteColorHSV), palettecolor_compare_hsv);
 }
 
diff --git a/source/blender/blenkernel/intern/subsurf_ccg.c b/source/blender/blenkernel/intern/subsurf_ccg.c
index cff2c5cc562..a1b45c2ac7d 100644
--- a/source/blender/blenkernel/intern/subsurf_ccg.c
+++ b/source/blender/blenkernel/intern/subsurf_ccg.c
@@ -423,7 +423,7 @@ static void set_subsurf_legacy_uv(CCGSubSurf *ss, DerivedMesh *dm, DerivedMesh *
 
   /* get some info from CCGSubSurf */
   totface = ccgSubSurf_getNumFaces(uvss);
-  /* edgeSize = ccgSubSurf_getEdgeSize(uvss); */ /*UNUSED*/
+  // edgeSize = ccgSubSurf_getEdgeSize(uvss); /* UNUSED */
   gridSize = ccgSubSurf_getGridSize(uvss);
   gridFaces = gridSize - 1;
 
diff --git a/source/blender/blenkernel/intern/writeffmpeg.c b/source/blender/blenkernel/intern/writeffmpeg.c
index 560ae30967f..9b3103a638b 100644
--- a/source/blender/blenkernel/intern/writeffmpeg.c
+++ b/source/blender/blenkernel/intern/writeffmpeg.c
@@ -1747,9 +1747,10 @@ void BKE_ffmpeg_preset_set(RenderData *rd, int preset)
       rd->ffcodecdata.type = FFMPEG_MPEG2;
       rd->ffcodecdata.video_bitrate = 6000;
 
-      /* Don't set resolution, see T21351.
-       * rd->xsch = 720;
-       * rd->ysch = isntsc ? 480 : 576; */
+#  if 0 /* Don't set resolution, see T21351. */
+      rd->xsch = 720;
+      rd->ysch = isntsc ? 480 : 576;
+#  endif
 
       rd->ffcodecdata.gop_size = isntsc ? 18 : 15;
       rd->ffcodecdata.rc_max_rate = 9000;
diff --git a/source/blender/blenlib/intern/BLI_kdopbvh.c b/source/blender/blenlib/intern/BLI_kdopbvh.c
index 3af942cd6d0..674654c99a8 100644
--- a/source/blender/blenlib/intern/BLI_kdopbvh.c
+++ b/source/blender/blenlib/intern/BLI_kdopbvh.c
@@ -22,7 +22,7 @@
  * \brief BVH-tree implementation.
  *
  * k-DOP BVH (Discrete Oriented Polytope, Bounding Volume Hierarchy).
- * A k-DOP is represented as k/2 pairs of min , max values for k/2 directions (intervals, "slabs").
+ * A k-DOP is represented as k/2 pairs of min, max values for k/2 directions (intervals, "slabs").
  *
  * See: http://www.gris.uni-tuebingen.de/people/staff/jmezger/papers/bvh.pdf
  *
diff --git a/source/blender/blenlib/intern/math_interp.c b/source/blender/blenlib/intern/math_interp.c
index 04fae6a0e68..bd48edf70c0 100644
--- a/source/blender/blenlib/intern/math_interp.c
+++ b/source/blender/blenlib/intern/math_interp.c
@@ -625,7 +625,7 @@ void BLI_ewa_filter(const int width,
    * Use a different radius based on interpolation switch,
    * just enough to anti-alias when interpolation is off,
    * and slightly larger to make result a bit smoother than bilinear interpolation when
-   * interpolation is on (minimum values: const float rmin = intpol ? 1.0f : 0.5f;) */
+   * interpolation is on (minimum values: `const float rmin = intpol ? 1.0f : 0.5f;`) */
   const float rmin = (intpol ? 1.5625f : 0.765625f) / ff2;
   BLI_ewa_imp2radangle(A, B, C, F, &a, &b, &th, &ecc);
   if ((b2 = b * b) < rmin) {
diff --git a/source/blender/blenlib/intern/math_matrix.c b/source/blender/blenlib/intern/math_matrix.c
index 5920788821c..b605c3eeead 100644
--- a/source/blender/blenlib/intern/math_matrix.c
+++ b/source/blender/blenlib/intern/math_matrix.c
@@ -276,7 +276,7 @@ void mul_m4_m4m4_uniq(float R[4][4], const float A[4][4], const float B[4][4])
 {
   BLI_assert(!ELEM(R, A, B));
 
-  /* matrix product: R[j][k] = A[j][i] . B[i][k] */
+  /* Matrix product: `R[j][k] = A[j][i] . B[i][k]`. */
 #ifdef BLI_HAVE_SSE2
   __m128 A0 = _mm_loadu_ps(A[0]);
   __m128 A1 = _mm_loadu_ps(A[1]);
@@ -321,7 +321,7 @@ void mul_m4_m4m4_db_uniq(double R[4][4], const double A[4][4], const double B[4]
 {
   BLI_assert(!ELEM(R, A, B));
 
-  /* matrix product: R[j][k] = A[j][i] . B[i][k] */
+  /* Matrix product: `R[j][k] = A[j][i] . B[i][k]`. */
 
   R[0][0] = B[0][0] * A[0][0] + B[0][1] * A[1][0] + B[0][2] * A[2][0] + B[0][3] * A[3][0];
   R[0][1] = B[0][0] * A[0][1] + B[0][1] * A[1][1] + B[0][2] * A[2][1] + B[0][3] * A[3][1];
@@ -349,7 +349,7 @@ void mul_m4db_m4db_m4fl_uniq(double R[4][4], const double A[4][4], const float B
   /* Remove second check since types don't match. */
   BLI_assert(!ELEM(R, A /*, B */));
 
-  /* matrix product: R[j][k] = A[j][i] . B[i][k] */
+  /* Matrix product: `R[j][k] = A[j][i] . B[i][k]`. */
 
   R[0][0] = B[0][0] * A[0][0] + B[0][1] * A[1][0] + B[0][2] * A[2][0] + B[0][3] * A[3][0];
   R[0][1] = B[0][0] * A[0][1] + B[0][1] * A[1][1] + B[0][2] * A[2][1] + B[0][3] * A[3][1];
diff --git a/source/blender/blenlib/intern/string_utils.c b/source/blender/blenlib/intern/string_utils.c
index 6a2ed8fac2c..d2666c6fe63 100644
--- a/source/blender/blenlib/intern/string_utils.c
+++ b/source/blender/blenlib/intern/string_utils.c
@@ -182,8 +182,8 @@ void BLI_string_flip_side_name(char *r_name,
 
   /* We first check the case with a .### extension, let's find the last period */
   if (isdigit(r_name[len - 1])) {
-    index = strrchr(r_name, '.');     /* last occurrence. */
-    if (index && isdigit(index[1])) { /* doesn't handle case bone.1abc2 correct..., whatever! */
+    index = strrchr(r_name, '.');     /* Last occurrence. */
+    if (index && isdigit(index[1])) { /* Doesn't handle case `bone.1abc2` correct..., whatever! */
       if (strip_number == false) {
         BLI_strncpy(number, index, name_len);
       }
@@ -194,7 +194,7 @@ void BLI_string_flip_side_name(char *r_name,
 
   BLI_strncpy(prefix, r_name, name_len);
 
-  /* first 

@@ Diff output truncated at 10240 characters. @@



More information about the Bf-blender-cvs mailing list