diff --git a/intern/cycles/kernel/closure/volume_util.h b/intern/cycles/kernel/closure/volume_util.h index d807cb47759..4e97271a956 100644 --- a/intern/cycles/kernel/closure/volume_util.h +++ b/intern/cycles/kernel/closure/volume_util.h @@ -69,7 +69,7 @@ ccl_device float3 phase_rayleigh_sample(float3 D, float2 rand, ccl_private float } /* Given cosine between rays, return probability density that a photon bounces to that direction - * according to the Draine phase function. This is a generalisation of the Henyey-Greenstein + * according to the Draine phase function. This is a generalization of the Henyey-Greenstein * function which bridges the cases of HG and Rayleigh scattering. The parameter g mainly controls * the first moment , and alpha the second moment of the exact phase * function. alpha=0 reduces to HG function, g=0, alpha=1 reduces to Rayleigh function, alpha=1 @@ -91,7 +91,7 @@ ccl_device float phase_draine(float cos_theta, float g, float alpha) ((1 + (alpha * (1 + 2 * g2)) * (1 / 3.0f)) * M_4PI_F * fac * sqrtf(fac)); } -/* Adapted from the hlsl code provided in https://research.nvidia.com/labs/rtr/approximate-mie/ */ +/* Adapted from the HLSL code provided in https://research.nvidia.com/labs/rtr/approximate-mie/ */ ccl_device float phase_draine_sample_cos(float g, float alpha, float rand) { const float g2 = sqr(g), g3 = g * g2, g4 = sqr(g2), g6 = g2 * g4; diff --git a/intern/cycles/kernel/osl/shaders/node_scatter_volume.osl b/intern/cycles/kernel/osl/shaders/node_scatter_volume.osl index 726a29d6fd9..f7f0896ad01 100644 --- a/intern/cycles/kernel/osl/shaders/node_scatter_volume.osl +++ b/intern/cycles/kernel/osl/shaders/node_scatter_volume.osl @@ -25,8 +25,8 @@ shader node_scatter_volume(string phase = "Henyey-Greenstein", scatter = rayleigh(); } else if (phase == "Mie") { - /* Approxmiation of Mie phase function for water droplets using a mix of Draine and H-G. - * See kernel/svm/closure.h for details. */ + /* Approximation of Mie phase function for water droplets using a mix of Draine and H-G. + * See `kernel/svm/closure.h` for details. */ float d = max(Diameter, 2.0); float aniso_hg = exp(-0.0990567 / (d - 1.67154)); float aniso_d = exp(-2.20679 / (d + 3.91029) - 0.428934); diff --git a/intern/cycles/util/math_fast.h b/intern/cycles/util/math_fast.h index 822148fa1ad..94fe0c58501 100644 --- a/intern/cycles/util/math_fast.h +++ b/intern/cycles/util/math_fast.h @@ -639,7 +639,7 @@ ccl_device_inline float fast_inv_cbrtf(float x) { util_assert(x >= 0.0f); - /* Constant is roughly cbrt(2^127), but tweaked a bit to balance the error across the entire + /* Constant is roughly `cbrt(2^127)`, but tweaked a bit to balance the error across the entire * range. The exact value is not critical. */ float y = __int_as_float(0x54a24242 - __float_as_int(x) / 3); y = (2.0f / 3) * y + 1 / (3 * y * y * x); diff --git a/intern/ffmpeg/ffmpeg_compat.h b/intern/ffmpeg/ffmpeg_compat.h index 260384a5dc8..39eb91defd6 100644 --- a/intern/ffmpeg/ffmpeg_compat.h +++ b/intern/ffmpeg/ffmpeg_compat.h @@ -144,7 +144,7 @@ int64_t av_get_frame_duration_in_pts_units(const AVFrame *picture) FFMPEG_INLINE size_t ffmpeg_get_buffer_alignment() { - /* Note: even if av_frame_get_buffer suggests to pass 0 for alignment, + /* NOTE: even if av_frame_get_buffer suggests to pass 0 for alignment, * as of ffmpeg 6.1/7.0 it does not use correct alignment for AVX512 * CPU (frame.c get_video_buffer ends up always using 32 alignment, * whereas it should have used 64). Reported upstream: diff --git a/source/blender/blenkernel/BKE_blendfile_link_append.hh b/source/blender/blenkernel/BKE_blendfile_link_append.hh index 2538a907af4..45ccf4d16b7 100644 --- a/source/blender/blenkernel/BKE_blendfile_link_append.hh +++ b/source/blender/blenkernel/BKE_blendfile_link_append.hh @@ -58,7 +58,7 @@ enum { }; /* NOTE: These three structs are currently exposed in header to allow for their usage in RNA. - * Regualr C++ code should not access their content directly. + * Regular C++ code should not access their content directly. * * TODO: Refactor these three structs into classes, and integrated the whole API into them. */ struct BlendfileLinkAppendContext; diff --git a/source/blender/blenkernel/BKE_main.hh b/source/blender/blenkernel/BKE_main.hh index c03da01f120..0081320dc09 100644 --- a/source/blender/blenkernel/BKE_main.hh +++ b/source/blender/blenkernel/BKE_main.hh @@ -292,16 +292,16 @@ void BKE_main_init(Main &bmain); * This is similar to a call to #BKE_main_destroy followed by #BKE_main_init, however the internal * #Main::lock is kept unchanged, and the #Main::is_global_main flag is not reset to `true` either. * - * \note: Unlike #BKE_main_free, only process the given \a bmain, without handling any potential + * \note Unlike #BKE_main_free, only process the given \a bmain, without handling any potential * other linked Main. */ void BKE_main_clear(Main &bmain); /** * Clear and free all data in given \a bmain, but does not free \a bmain itself. * - * \note: In most cases, #BKE_main_free should be used instead of this function. + * \note In most cases, #BKE_main_free should be used instead of this function. * - * \note: Unlike #BKE_main_free, only process the given \a bmain, without handling any potential + * \note Unlike #BKE_main_free, only process the given \a bmain, without handling any potential * other linked Main. */ void BKE_main_destroy(Main &bmain); diff --git a/source/blender/blenkernel/intern/grease_pencil_convert_legacy.cc b/source/blender/blenkernel/intern/grease_pencil_convert_legacy.cc index 9a8c386aaca..d5baf5dbca8 100644 --- a/source/blender/blenkernel/intern/grease_pencil_convert_legacy.cc +++ b/source/blender/blenkernel/intern/grease_pencil_convert_legacy.cc @@ -1036,7 +1036,7 @@ static void legacy_gpencil_to_grease_pencil(ConversionData &conversion_data, /* Second loop, to write to layer attributes after all layers were created. */ MutableAttributeAccessor layer_attributes = grease_pencil.attributes_for_write(); - /* Note: Layer Adjustments like the tint and the radius offsets are deliberatly ignored here! + /* NOTE: Layer Adjustments like the tint and the radius offsets are deliberately ignored here! * These are converted to modifiers at the bottom of the stack to keep visual compatibility with * GPv2. */ SpanAttributeWriter layer_passes = layer_attributes.lookup_or_add_for_write_span( diff --git a/source/blender/blenlib/BLI_concurrent_map.hh b/source/blender/blenlib/BLI_concurrent_map.hh index edb58df7d3f..e74f91d24cf 100644 --- a/source/blender/blenlib/BLI_concurrent_map.hh +++ b/source/blender/blenlib/BLI_concurrent_map.hh @@ -42,7 +42,7 @@ namespace blender { * sure that only one thread can modify a value at a time. Multiple threads may read from the same * key at the same time though. * - * \note: #ConcurrentMap does not support iteration over all values. + * \note #ConcurrentMap does not support iteration over all values. * * This is a thin wrapper around #tbb::concurrent_hash_map that also has a fallback implementation * if TBB is not available. The fallback implementation is not optimized for performance. It mainly diff --git a/source/blender/blenloader/intern/readfile.cc b/source/blender/blenloader/intern/readfile.cc index 4c42dd616f6..914e4497bf4 100644 --- a/source/blender/blenloader/intern/readfile.cc +++ b/source/blender/blenloader/intern/readfile.cc @@ -1712,7 +1712,7 @@ static void switch_endian_structs(const SDNA *filesdna, BHead *bhead) * Generate the final allocation string reference for read blocks of data. If \a blockname is * given, use it as 'owner block' info, otherwise use the id type index to get that info. * - * \note: These strings are stored until Blender exits + * \note These strings are stored until Blender exits */ static const char *get_alloc_name(FileData *fd, BHead *bh, diff --git a/source/blender/editors/grease_pencil/intern/grease_pencil_edit.cc b/source/blender/editors/grease_pencil/intern/grease_pencil_edit.cc index 4d9591a83a2..1a741f8c5a8 100644 --- a/source/blender/editors/grease_pencil/intern/grease_pencil_edit.cc +++ b/source/blender/editors/grease_pencil/intern/grease_pencil_edit.cc @@ -3962,7 +3962,7 @@ static void join_object_with_active(Main &bmain, /* Rename animation paths to layers. */ BKE_fcurves_main_cb(&bmain, [&](ID *id, FCurve *fcu) { if (id == &grease_pencil_src.id && fcu->rna_path && strstr(fcu->rna_path, "layers[")) { - /* Have to use linear search, the layer name map only contains substrings of RNA paths. */ + /* Have to use linear search, the layer name map only contains sub-strings of RNA paths. */ for (auto [name_src, name_dst] : layer_name_map.items()) { if (name_dst != name_src) { const char *old_path = fcu->rna_path; diff --git a/source/blender/editors/interface/interface.cc b/source/blender/editors/interface/interface.cc index 4ccba77a85e..209bf1c4f33 100644 --- a/source/blender/editors/interface/interface.cc +++ b/source/blender/editors/interface/interface.cc @@ -4137,7 +4137,7 @@ void ui_block_cm_to_display_space_v3(uiBlock *block, float pixel[3]) /** * Factory function: Allocate button and set #uiBut.type. * - * \note: #ui_but_mem_delete is the matching 'destructor' function. + * \note #ui_but_mem_delete is the matching 'destructor' function. */ static uiBut *ui_but_new(const eButType type) { diff --git a/source/blender/editors/sculpt_paint/sculpt.cc b/source/blender/editors/sculpt_paint/sculpt.cc index c3c5a9c2f58..b26e91afb14 100644 --- a/source/blender/editors/sculpt_paint/sculpt.cc +++ b/source/blender/editors/sculpt_paint/sculpt.cc @@ -4909,7 +4909,7 @@ static void restore_from_undo_step_if_necessary(const Depsgraph &depsgraph, * rather than in the brush deformation calculation because that is called once for each symmetry * pass, potentially within the same BVH node. * - * Note: Despite the Cloth and Boundary brush using original coordinates, the brushes do not + * NOTE: Despite the Cloth and Boundary brush using original coordinates, the brushes do not * expect this restoration to happen on every stroke step. Performing this restoration causes * issues with the cloth simulation mode for those brushes. */ diff --git a/source/blender/geometry/intern/merge_curves.cc b/source/blender/geometry/intern/merge_curves.cc index 230b1940a0b..ae515423fc6 100644 --- a/source/blender/geometry/intern/merge_curves.cc +++ b/source/blender/geometry/intern/merge_curves.cc @@ -248,7 +248,7 @@ static bke::CurvesGeometry join_curves_ranges(const bke::CurvesGeometry &src_cur bke::CurvesGeometry dst_curves = bke::CurvesGeometry(src_curves.points_num(), old_curves_by_new.size()); - /* Note: using the offsets as an index map means the first curve of each range is used for + /* NOTE: using the offsets as an index map means the first curve of each range is used for * attributes. */ const Span old_by_new_map = old_curves_by_new.data().drop_back(1); bke::gather_attributes(src_curves.attributes(), diff --git a/source/blender/imbuf/tests/IMB_scaling_test.cc b/source/blender/imbuf/tests/IMB_scaling_test.cc index 6826be9eefb..6f0f192a763 100644 --- a/source/blender/imbuf/tests/IMB_scaling_test.cc +++ b/source/blender/imbuf/tests/IMB_scaling_test.cc @@ -127,7 +127,7 @@ TEST(imbuf_scaling, bilinear_2x_smaller) { ImBuf *res = scale_2x_smaller(false, false); const uchar4 *got = reinterpret_cast(res->byte_buffer.data); - /* Note: IMB_transform results in (191, 128, 64, 255), , + /* NOTE: #IMB_transform results in (191, 128, 64, 255), , * (55, 50, 48, 254) i.e. different rounding. */ EXPECT_EQ(uint4(got[0]), uint4(191, 127, 63, 255)); EXPECT_EQ(uint4(got[1]), uint4(133, 55, 31, 16)); diff --git a/source/blender/io/ply/importer/ply_import_mesh.cc b/source/blender/io/ply/importer/ply_import_mesh.cc index 9284aac7803..58061fd8692 100644 --- a/source/blender/io/ply/importer/ply_import_mesh.cc +++ b/source/blender/io/ply/importer/ply_import_mesh.cc @@ -99,8 +99,8 @@ Mesh *convert_ply_to_mesh(PlyData &data, const PLYImportParams ¶ms) uv_map.finish(); } - /* If we have custom vertex normals, set them (note: important to do this - * after initializing the loops). */ + /* If we have custom vertex normals, set them + * (NOTE: important to do this after initializing the loops). */ bool set_custom_normals_for_verts = false; if (!data.vertex_normals.is_empty()) { if (!data.face_sizes.is_empty()) { diff --git a/source/blender/makesdna/DNA_grease_pencil_types.h b/source/blender/makesdna/DNA_grease_pencil_types.h index ee8910c1c8d..530fd06968a 100644 --- a/source/blender/makesdna/DNA_grease_pencil_types.h +++ b/source/blender/makesdna/DNA_grease_pencil_types.h @@ -564,7 +564,7 @@ typedef struct GreasePencil { /** * Adds multiple layers with an empty name. - * Note: Evaluated Grease Pencil geometry is allowed to have layers with the same name. + * NOTE: Evaluated Grease Pencil geometry is allowed to have layers with the same name. */ void add_layers_for_eval(int num_new_layers); diff --git a/source/blender/sequencer/intern/thumbnail_cache.cc b/source/blender/sequencer/intern/thumbnail_cache.cc index 96817b4d885..0bf07acf524 100644 --- a/source/blender/sequencer/intern/thumbnail_cache.cc +++ b/source/blender/sequencer/intern/thumbnail_cache.cc @@ -282,7 +282,7 @@ void ThumbGenerationJob::run_fn(void *customdata, wmJobWorkerStatus *worker_stat Vector requests; while (!worker_status->stop) { /* Under cache mutex lock: copy all current requests into a vector for processing. - * Note: keep the requests set intact! We don't want to add new requests for same + * NOTE: keep the requests set intact! We don't want to add new requests for same * items while we are processing them. They will be removed from the set once * they are finished, one by one. */ {