From 132e58610d6c71c38bafcc5034e942bde8f01ad6 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Thu, 9 Jun 2022 10:16:26 +1000 Subject: Cleanup: spelling in comments & variables --- source/blender/blenlib/BLI_hash_tables.hh | 6 +++--- source/blender/compositor/operations/COM_TonemapOperation.h | 4 ++-- source/blender/draw/engines/eevee_next/eevee_view.hh | 2 +- source/blender/editors/armature/pose_lib.c | 2 +- source/blender/editors/gpencil/drawgpencil.c | 4 ++-- source/blender/editors/gpencil/gpencil_select.c | 2 +- source/blender/editors/object/object_modes.c | 10 +++++----- source/blender/gpu/metal/mtl_backend.mm | 2 +- source/blender/io/stl/importer/stl_import_mesh.hh | 2 +- source/blender/makesrna/intern/rna_internal_types.h | 2 +- .../blender/nodes/geometry/nodes/node_geo_curve_spline_type.cc | 5 +++-- source/blender/render/intern/pipeline.c | 6 +++--- 12 files changed, 24 insertions(+), 23 deletions(-) (limited to 'source/blender') diff --git a/source/blender/blenlib/BLI_hash_tables.hh b/source/blender/blenlib/BLI_hash_tables.hh index 334634613a2..156fe481828 100644 --- a/source/blender/blenlib/BLI_hash_tables.hh +++ b/source/blender/blenlib/BLI_hash_tables.hh @@ -209,11 +209,11 @@ template struct TemplatedKeyInfo }; /** - * 0xffff...ffff indicates an empty slot. - * 0xffff...fffe indicates a removed slot. + * `0xffff...ffff` indicates an empty slot. + * `0xffff...fffe` indicates a removed slot. * * Those specific values are used, because with them a single comparison is enough to check whether - * a slot is occupied. The keys 0x0000...0000 and 0x0000...0001 also satisfy this constraint. + * a slot is occupied. The keys `0x0000...0000` and `0x0000...0001` also satisfy this constraint. * However, nullptr is much more likely to be used as valid key. */ template struct PointerKeyInfo { diff --git a/source/blender/compositor/operations/COM_TonemapOperation.h b/source/blender/compositor/operations/COM_TonemapOperation.h index 84ee9c563fd..7868aa140dc 100644 --- a/source/blender/compositor/operations/COM_TonemapOperation.h +++ b/source/blender/compositor/operations/COM_TonemapOperation.h @@ -81,8 +81,8 @@ class TonemapOperation : public MultiThreadedOperation { }; /** - * \brief class of tonemap, implementing the photoreceptor tonemap - * most parts have already been done in TonemapOperation + * \brief class of tone-map, implementing the photo-receptor tone-map + * most parts have already been done in #TonemapOperation. * \ingroup operation */ diff --git a/source/blender/draw/engines/eevee_next/eevee_view.hh b/source/blender/draw/engines/eevee_next/eevee_view.hh index 95ec1760c63..fb74412f557 100644 --- a/source/blender/draw/engines/eevee_next/eevee_view.hh +++ b/source/blender/draw/engines/eevee_next/eevee_view.hh @@ -41,7 +41,7 @@ class ShadingView { /** Matrix to apply to the viewmat. */ const float (*face_matrix_)[4]; - /** Post-fx modules. */ + /** Post-FX modules. */ // DepthOfField dof_; // MotionBlur mb_; VelocityView velocity_; diff --git a/source/blender/editors/armature/pose_lib.c b/source/blender/editors/armature/pose_lib.c index e0e5693c79b..ea54c3014ca 100644 --- a/source/blender/editors/armature/pose_lib.c +++ b/source/blender/editors/armature/pose_lib.c @@ -1431,7 +1431,7 @@ static int poselib_preview_handle_event(bContext *UNUSED(C), wmOperator *op, con ret = OPERATOR_PASS_THROUGH; break; - /* quicky compare to original */ + /* Quickly compare to original. */ case EVT_TABKEY: pld->flag &= ~PL_PREVIEW_SHOWORIGINAL; pld->redraw = PL_PREVIEW_REDRAWALL; diff --git a/source/blender/editors/gpencil/drawgpencil.c b/source/blender/editors/gpencil/drawgpencil.c index 011a5a66695..24de50db397 100644 --- a/source/blender/editors/gpencil/drawgpencil.c +++ b/source/blender/editors/gpencil/drawgpencil.c @@ -80,9 +80,9 @@ typedef enum eDrawStrokeFlags { GP_DRAWDATA_ONLYI2D = (1 << 3), /** special hack for drawing strokes in Image Editor (weird coordinates) */ GP_DRAWDATA_IEDITHACK = (1 << 4), - /** don't draw xray in 3D view (which is default) */ + /** Don't draw XRAY in 3D view (which is default). */ GP_DRAWDATA_NO_XRAY = (1 << 5), - /** no onionskins should be drawn (for animation playback) */ + /** No onion-skins should be drawn (for animation playback). */ GP_DRAWDATA_NO_ONIONS = (1 << 6), /** draw strokes as "volumetric" circular billboards */ GP_DRAWDATA_VOLUMETRIC = (1 << 7), diff --git a/source/blender/editors/gpencil/gpencil_select.c b/source/blender/editors/gpencil/gpencil_select.c index a37dc99229c..e903d11a1e0 100644 --- a/source/blender/editors/gpencil/gpencil_select.c +++ b/source/blender/editors/gpencil/gpencil_select.c @@ -1701,7 +1701,7 @@ static int gpencil_circle_select_exec(bContext *C, wmOperator *op) const bool select = (sel_op != SEL_OP_SUB); bool changed = false; - /* for bounding rect around circle (for quicky intersection testing) */ + /* For bounding `rect` around circle (for quickly intersection testing). */ rcti rect = {0}; rect.xmin = mx - radius; rect.ymin = my - radius; diff --git a/source/blender/editors/object/object_modes.c b/source/blender/editors/object/object_modes.c index fdf2cae026d..0055cdf9ea1 100644 --- a/source/blender/editors/object/object_modes.c +++ b/source/blender/editors/object/object_modes.c @@ -458,7 +458,7 @@ static bool object_transfer_mode_to_base(bContext *C, wmOperator *op, Base *base return false; } - bool mode_transfered = false; + bool mode_transferred = false; ED_undo_group_begin(C); @@ -480,11 +480,11 @@ static bool object_transfer_mode_to_base(bContext *C, wmOperator *op, Base *base WM_event_add_notifier(C, NC_SCENE | ND_OB_SELECT, scene); WM_toolsystem_update_from_context_view3d(C); - mode_transfered = true; + mode_transferred = true; } ED_undo_group_end(C); - return mode_transfered; + return mode_transferred; } static int object_transfer_mode_invoke(bContext *C, wmOperator *op, const wmEvent *event) @@ -493,8 +493,8 @@ static int object_transfer_mode_invoke(bContext *C, wmOperator *op, const wmEven const eObjectMode src_mode = (eObjectMode)ob_src->mode; Base *base_dst = ED_view3d_give_base_under_cursor(C, event->mval); - const bool mode_transfered = object_transfer_mode_to_base(C, op, base_dst); - if (!mode_transfered) { + const bool mode_transferred = object_transfer_mode_to_base(C, op, base_dst); + if (!mode_transferred) { return OPERATOR_CANCELLED; } diff --git a/source/blender/gpu/metal/mtl_backend.mm b/source/blender/gpu/metal/mtl_backend.mm index 8bdec962af0..1064091a036 100644 --- a/source/blender/gpu/metal/mtl_backend.mm +++ b/source/blender/gpu/metal/mtl_backend.mm @@ -256,7 +256,7 @@ bool MTLBackend::metal_is_supported() NSOperatingSystemVersion version = [[NSProcessInfo processInfo] operatingSystemVersion]; - /* Metal Viewport requires macOS Version 10.15 onwards. */ + /* Metal Viewport requires macOS Version 10.15 onward. */ bool supported_os_version = version.majorVersion >= 11 || (version.majorVersion == 10 ? version.minorVersion >= 15 : false); if (!supported_os_version) { diff --git a/source/blender/io/stl/importer/stl_import_mesh.hh b/source/blender/io/stl/importer/stl_import_mesh.hh index 7827d2a408c..a01e5be09a4 100644 --- a/source/blender/io/stl/importer/stl_import_mesh.hh +++ b/source/blender/io/stl/importer/stl_import_mesh.hh @@ -19,7 +19,7 @@ namespace blender::io::stl { class Triangle { public: int v1, v2, v3; - /* Based on an old version of Python's frozenset hash + /* Based on an old version of Python's frozen-set hash * https://web.archive.org/web/20220520211017/https://stackoverflow.com/questions/20832279/python-frozenset-hashing-algorithm-implementation */ uint64_t hash() const diff --git a/source/blender/makesrna/intern/rna_internal_types.h b/source/blender/makesrna/intern/rna_internal_types.h index 4f88959b5ba..a5b06cabade 100644 --- a/source/blender/makesrna/intern/rna_internal_types.h +++ b/source/blender/makesrna/intern/rna_internal_types.h @@ -532,7 +532,7 @@ struct StructRNA { /* property to iterate over properties */ PropertyRNA *iteratorproperty; - /* struct this is derivedfrom */ + /** Struct this is derived from. */ struct StructRNA *base; /* only use for nested structs, where both the parent and child access diff --git a/source/blender/nodes/geometry/nodes/node_geo_curve_spline_type.cc b/source/blender/nodes/geometry/nodes/node_geo_curve_spline_type.cc index 0a4078772b9..8479d61a890 100644 --- a/source/blender/nodes/geometry/nodes/node_geo_curve_spline_type.cc +++ b/source/blender/nodes/geometry/nodes/node_geo_curve_spline_type.cc @@ -176,7 +176,8 @@ static void nurbs_to_bezier_assign(const Span src, dst.last() = src.last(); break; default: - /* Every 3rd NURBS position (starting from index 1) should have its attributes transfered. */ + /* Every 3rd NURBS position (starting from index 1) should have its attributes transferred. + */ scale_input_assign(src, 3, 1, dst); } } @@ -448,7 +449,7 @@ static void convert_to_bezier(const CurveComponent &src_component, Vector nurbs_positions_vector; if (src_cyclic[i] && is_nurbs_to_bezier_one_to_one(knots_mode)) { /* For conversion treat this as periodic closed curve. Extend NURBS hull to first and - * second point which will act as a sceleton for placing Bezier handles. */ + * second point which will act as a skeleton for placing Bezier handles. */ nurbs_positions_vector.extend(src_curve_positions); nurbs_positions_vector.append(src_curve_positions[0]); nurbs_positions_vector.append(src_curve_positions[1]); diff --git a/source/blender/render/intern/pipeline.c b/source/blender/render/intern/pipeline.c index 43497fb8318..075f1ece647 100644 --- a/source/blender/render/intern/pipeline.c +++ b/source/blender/render/intern/pipeline.c @@ -981,7 +981,7 @@ static void render_result_uncrop(Render *re) render_result_free(re->result); re->result = rres; - /* weak... the display callback wants an active renderlayer pointer... */ + /* Weak, the display callback wants an active render-layer pointer. */ re->result->renlay = render_get_active_layer(re, re->result); BLI_rw_mutex_unlock(&re->resultmutex); @@ -1313,8 +1313,8 @@ static void do_render_sequencer(Render *re) true, &context); - /* the renderresult gets destroyed during the rendering, so we first collect all ibufs - * and then we populate the final renderesult */ + /* The render-result gets destroyed during the rendering, so we first collect all ibufs + * and then we populate the final render-result. */ for (view_id = 0; view_id < tot_views; view_id++) { context.view_id = view_id; -- cgit v1.2.3