[Bf-blender-cvs] [1143bf281af] master: Cleanup: spelling in comments, comment block formatting

Campbell Barton noreply at git.blender.org
Sat Nov 13 03:09:44 CET 2021


Commit: 1143bf281afc69b931f7d0eb1daa4b800dcc513d
Author: Campbell Barton
Date:   Sat Nov 13 13:07:13 2021 +1100
Branches: master
https://developer.blender.org/rB1143bf281afc69b931f7d0eb1daa4b800dcc513d

Cleanup: spelling in comments, comment block formatting

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

M	intern/cycles/device/hip/device_impl.cpp
M	intern/cycles/kernel/device/metal/compat.h
M	intern/cycles/kernel/device/metal/context_end.h
M	intern/ghost/GHOST_Types.h
M	intern/ghost/intern/GHOST_SystemCocoa.mm
M	intern/ghost/intern/GHOST_XrAction.cpp
M	intern/ghost/intern/GHOST_XrControllerModel.cpp
M	source/blender/blenkernel/BKE_action.h
M	source/blender/blenkernel/BKE_lib_id.h
M	source/blender/blenkernel/BKE_spline.hh
M	source/blender/blenkernel/intern/fcurve_driver.c
M	source/blender/editors/animation/anim_motion_paths.c
M	source/blender/editors/curve/editcurve.c
M	source/blender/editors/curve/editcurve_paint.c
M	source/blender/editors/mesh/editmesh_extrude.c
M	source/blender/editors/mesh/editmesh_extrude_spin.c
M	source/blender/editors/physics/particle_edit.c
M	source/blender/editors/sculpt_paint/paint_image_proj.c
M	source/blender/editors/sculpt_paint/sculpt_intern.h
M	source/blender/editors/space_info/info_stats.cc
M	source/blender/editors/space_node/node_relationships.cc
M	source/blender/editors/space_node/space_node.cc
M	source/blender/editors/space_view3d/view3d_gizmo_ruler.c
M	source/blender/editors/space_view3d/view3d_view.c
M	source/blender/editors/transform/transform_convert_action.c
M	source/blender/editors/transform/transform_snap_object.c
M	source/blender/makesdna/DNA_constraint_types.h
M	source/blender/makesdna/DNA_node_types.h
M	source/blender/makesdna/DNA_object_types.h
M	source/blender/makesdna/DNA_screen_types.h
M	source/blender/makesdna/DNA_texture_types.h
M	source/blender/makesdna/DNA_view3d_types.h
M	source/blender/makesrna/intern/rna_animviz.c
M	source/blender/modifiers/intern/MOD_meshdeform.c
M	source/blender/modifiers/intern/MOD_uvproject.c
M	source/blender/windowmanager/xr/intern/wm_xr_operators.c

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

diff --git a/intern/cycles/device/hip/device_impl.cpp b/intern/cycles/device/hip/device_impl.cpp
index 7874471724a..71f3b7ce4fe 100644
--- a/intern/cycles/device/hip/device_impl.cpp
+++ b/intern/cycles/device/hip/device_impl.cpp
@@ -243,7 +243,7 @@ string HIPDevice::compile_kernel(const uint kernel_features, const char *name, c
   hipGetDeviceProperties(&props, hipDevId);
 
   /* gcnArchName can contain tokens after the arch name with features, ie.
-    "gfx1010:sramecc-:xnack-" so we tokenize it to get the first part. */
+   * `gfx1010:sramecc-:xnack-` so we tokenize it to get the first part. */
   char *arch = strtok(props.gcnArchName, ":");
   if (arch == NULL) {
     arch = props.gcnArchName;
diff --git a/intern/cycles/kernel/device/metal/compat.h b/intern/cycles/kernel/device/metal/compat.h
index 2fa9b7fed44..a839917a907 100644
--- a/intern/cycles/kernel/device/metal/compat.h
+++ b/intern/cycles/kernel/device/metal/compat.h
@@ -73,7 +73,8 @@ using namespace metal;
 #define ccl_gpu_kernel(block_num_threads, thread_num_registers)
 #define ccl_gpu_kernel_threads(block_num_threads)
 
-/* convert a comma-separated list into a semicolon-separated list (so that we can generate a struct based on kernel entrypoint parameters) */
+/* Convert a comma-separated list into a semicolon-separated list
+ * (so that we can generate a struct based on kernel entry-point parameters). */
 #define FN0()
 #define FN1(p1) p1;
 #define FN2(p1, p2) p1; p2;
@@ -94,7 +95,8 @@ using namespace metal;
 #define GET_LAST_ARG(p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, ...) p16
 #define PARAMS_MAKER(...) GET_LAST_ARG(__VA_ARGS__, FN16, FN15, FN14, FN13, FN12, FN11, FN10, FN9, FN8, FN7, FN6, FN5, FN4, FN3, FN2, FN1, FN0)
 
-/* generate a struct containing the entrypoint parameters and a "run" method which can access them implicitly via this-> */
+/* Generate a struct containing the entry-point parameters and a "run"
+ * method which can access them implicitly via this-> */
 #define ccl_gpu_kernel_signature(name, ...) \
 struct kernel_gpu_##name \
 { \
diff --git a/intern/cycles/kernel/device/metal/context_end.h b/intern/cycles/kernel/device/metal/context_end.h
index 811abdec150..e700f294440 100644
--- a/intern/cycles/kernel/device/metal/context_end.h
+++ b/intern/cycles/kernel/device/metal/context_end.h
@@ -17,7 +17,7 @@
 ; /* end of MetalKernelContext class definition */
 
 /* Silently redirect into the MetalKernelContext instance */
-/* NOTE: These macros will need maintaining as entrypoints change */
+/* NOTE: These macros will need maintaining as entry-points change. */
 
 #undef kernel_integrator_state
 #define kernel_integrator_state context.launch_params_metal.__integrator_state
diff --git a/intern/ghost/GHOST_Types.h b/intern/ghost/GHOST_Types.h
index 2c8014a08cc..ce0185bc7d0 100644
--- a/intern/ghost/GHOST_Types.h
+++ b/intern/ghost/GHOST_Types.h
@@ -654,8 +654,8 @@ enum {
   GHOST_kXrContextDebug = (1 << 0),
   GHOST_kXrContextDebugTime = (1 << 1),
 #  ifdef WIN32
-  /* Needed to avoid issues with the SteamVR OpenGL graphics binding (use DirectX fallback
-     instead). */
+  /* Needed to avoid issues with the SteamVR OpenGL graphics binding
+   * (use DirectX fallback instead). */
   GHOST_kXrContextGpuNVIDIA = (1 << 2),
 #  endif
 };
diff --git a/intern/ghost/intern/GHOST_SystemCocoa.mm b/intern/ghost/intern/GHOST_SystemCocoa.mm
index 204bbdaec50..b92c3e73a88 100644
--- a/intern/ghost/intern/GHOST_SystemCocoa.mm
+++ b/intern/ghost/intern/GHOST_SystemCocoa.mm
@@ -1245,7 +1245,7 @@ GHOST_TSuccess GHOST_SystemCocoa::handleDraggingEvent(GHOST_TEventType eventType
 
             /* Convert the image in a RGBA 32bit format */
             /* As Core Graphics does not support contexts with non premutliplied alpha,
-             we need to get alpha key values in a separate batch */
+             * we need to get alpha key values in a separate batch */
 
             /* First get RGB values w/o Alpha to avoid pre-multiplication,
              * 32bit but last byte is unused */
@@ -1479,8 +1479,8 @@ GHOST_TSuccess GHOST_SystemCocoa::handleMouseEvent(void *eventPtr)
   CocoaWindow *cocoawindow;
 
   /* [event window] returns other windows if mouse-over, that's OSX input standard
-     however, if mouse exits window(s), the windows become inactive, until you click.
-     We then fall back to the active window from ghost */
+   * however, if mouse exits window(s), the windows become inactive, until you click.
+   * We then fall back to the active window from ghost. */
   window = (GHOST_WindowCocoa *)m_windowManager->getWindowAssociatedWithOSWindow(
       (void *)[event window]);
   if (!window) {
diff --git a/intern/ghost/intern/GHOST_XrAction.cpp b/intern/ghost/intern/GHOST_XrAction.cpp
index 704b1ce9fac..f51f98c9b3d 100644
--- a/intern/ghost/intern/GHOST_XrAction.cpp
+++ b/intern/ghost/intern/GHOST_XrAction.cpp
@@ -216,8 +216,9 @@ GHOST_XrAction::GHOST_XrAction(XrInstance instance,
 
   XrActionCreateInfo action_info{XR_TYPE_ACTION_CREATE_INFO};
   strcpy(action_info.actionName, info.name);
-  strcpy(action_info.localizedActionName, info.name); /* Just use same name for localized. This can
-                                                         be changed in the future if necessary. */
+
+  /* Just use same name for localized. This can be changed in the future if necessary. */
+  strcpy(action_info.localizedActionName, info.name);
 
   switch (info.type) {
     case GHOST_kXrActionTypeBooleanInput:
diff --git a/intern/ghost/intern/GHOST_XrControllerModel.cpp b/intern/ghost/intern/GHOST_XrControllerModel.cpp
index ae15bf11aa0..27f92ffe7c5 100644
--- a/intern/ghost/intern/GHOST_XrControllerModel.cpp
+++ b/intern/ghost/intern/GHOST_XrControllerModel.cpp
@@ -97,8 +97,8 @@ static void read_vertices(const tinygltf::Accessor &accessor,
   validate_accessor(accessor, buffer_view, buffer, stride, packed_size);
 
   /* Resize the vertices vector, if necessary, to include room for the attribute data.
-     If there are multiple attributes for a primitive, the first one will resize, and the
-     subsequent will not need to. */
+   * If there are multiple attributes for a primitive, the first one will resize, and the
+   * subsequent will not need to. */
   primitive.vertices.resize(accessor.count);
 
   /* Copy the attribute value over from the glTF buffer into the appropriate vertex field. */
@@ -147,9 +147,9 @@ static void read_indices(const tinygltf::Accessor &accessor,
                          const tinygltf::Buffer &buffer,
                          GHOST_XrPrimitive &primitive)
 {
-  if (buffer_view.target != TINYGLTF_TARGET_ELEMENT_ARRAY_BUFFER &&
-      buffer_view.target != 0) { /* Allow 0 (not specified) even though spec doesn't seem to allow
-                                    this (BoomBox GLB fails). */
+
+  /* Allow 0 (not specified) even though spec doesn't seem to allow this (BoomBox GLB fails). */
+  if (buffer_view.target != TINYGLTF_TARGET_ELEMENT_ARRAY_BUFFER && buffer_view.target != 0) {
     throw GHOST_XrException(
         "glTF: Accessor for indices uses bufferview with invalid 'target' type.");
   }
@@ -164,8 +164,8 @@ static void read_indices(const tinygltf::Accessor &accessor,
 
   validate_accessor(accessor, buffer_view, buffer, component_size_bytes, component_size_bytes);
 
-  if ((accessor.count % 3) != 0) { /* Since only triangles are supported, enforce that the number
-                                      of indices is divisible by 3. */
+  /* Since only triangles are supported, enforce that the number of indices is divisible by 3. */
+  if ((accessor.count % 3) != 0) {
     throw GHOST_XrException("glTF: Unexpected number of indices for triangle primitive");
   }
 
diff --git a/source/blender/blenkernel/BKE_action.h b/source/blender/blenkernel/BKE_action.h
index db55daddba6..763e540fdd9 100644
--- a/source/blender/blenkernel/BKE_action.h
+++ b/source/blender/blenkernel/BKE_action.h
@@ -128,11 +128,12 @@ void action_groups_clear_tempflags(struct bAction *act);
 /**
  * Return whether the action has one unique point in time keyed.
  *
- * This is mostly for the pose library, which will have different behaviour depending on whether an
+ * This is mostly for the pose library, which will have different behavior depending on whether an
  * Action corresponds to a "pose" (one keyframe) or "animation snippet" (multiple keyframes).
  *
  * \return `false` when there is no keyframe at all or keys on different points in time, `true`
- * when exactly one point in time is keyed. */
+ * when exactly one point in time is keyed.
+ */
 bool BKE_action_has_single_frame(const struct bAction *act);
 
 /* Pose API ----------------- */
diff --git a/source/blender/blenkernel/BKE_lib_id.h b/source/blender/blenkernel/BKE_lib_id.h
index b38125b791d..4faf6d94df8 100644
--- a/source/blender/blenkernel/BKE_lib_id.h
+++ b/source/blender/blenkernel/BKE_lib_id.h
@@ -134,8 +134,10 @@ enum {
   LIB_ID_COPY_SHAPEKEY = 1 << 26,
   /** EXCEPTION! Specific deep-copy of node trees used e.g. for rendering purposes. */
   LIB_ID_COPY_NODETREE_LOCALIZE = 1 << 27,
-  /** EXCEPTION! Specific handling of RB objects regarding collections differs depending whether we
-     duplicate scene/collections, or objects. */
+  /**
+   * EXCEPTION! Specific handling of RB objects regarding collections differs depending whether we
+   * duplicate scene/collections, or objects.
+   */
   LIB_ID_COPY_RIGID_BODY_NO_COLLECTION_HANDLING = 1 << 28,
 
   /* *** Helper 'defines' gathering most common flag sets. *** */
diff --git a/source/blender/blenkernel/BKE_spline.hh b/source/blender/blenkernel/BKE_spline.hh
index 55a4f6ffcfd..1d34768b1a2 100644
--- a/source/blender/blenkernel/BKE_spline.hh
+++ b/source/blender/blenkernel/BKE_spline.hh
@@ -307,20 +307,20 @@ class BezierSpline final : public Spline {
   blender::MutableSpan<HandleType> handle_types_left();
   blender::Span<blender::float3> handle_positions_left() const;
   /**
-   * Get writable access to the hande position.
+   * Get writable access to the handle position.
    *
    * \param write_only: pass true for an uninitialized spline, this prevents accessing
-   * uninitialized memory while autogenerating handles.
+ 

@@ Diff output truncated at 10240 characters. @@



More information about the Bf-blender-cvs mailing list