Cleanup: spelling in comments

This commit is contained in:
Campbell Barton
2024-07-25 10:17:42 +10:00
parent 62afbbef9b
commit 2edc2393d2
25 changed files with 32 additions and 29 deletions

View File

@@ -850,7 +850,7 @@ Span<const FCurve *> fcurves_for_action_slot(const Action &action, slot_handle_t
*
* This is a utility function whose purpose is unclear after multi-layer Actions are introduced.
* It might still be useful, it might not be.
*
* The use of this function is an indicator for code that might have to be altered when
* multi-layered Actions are getting implemented.
*/

View File

@@ -1172,7 +1172,7 @@ bool ChannelBag::fcurve_remove(FCurve &fcurve_to_remove)
dna::array::remove_index(
&this->fcurve_array, &this->fcurve_array_num, nullptr, fcurve_index, fcurve_ptr_destructor);
/* As an optimisation, this function could call `DEG_relations_tag_update(bmain)` to prune any
/* As an optimization, this function could call `DEG_relations_tag_update(bmain)` to prune any
* relationships that are now no longer necessary. This is not needed for correctness of the
* depsgraph evaluation results though. */

View File

@@ -29,7 +29,7 @@ class AssetLibrary;
class AssetRepresentation;
class AssetStorage {
/* Uses shared pointers so the UI can aquire weak pointers. It can then ensure pointers are not
/* Uses shared pointers so the UI can acquire weak pointers. It can then ensure pointers are not
* dangling before accessing. */
using StorageT = Set<std::shared_ptr<AssetRepresentation>>;

View File

@@ -509,7 +509,7 @@ void mesh_remesh_reproject_attributes(const Mesh &src, Mesh &dst)
/* The main idea in the following code is to trade some complexity in sampling for the benefit of
* only using and building a single BVH tree. Since sculpt mode doesn't generally deal with loose
* vertices and edges, we use the standard "triangles" BVH which won't contain them. Also, only
* relying on a single BVH should reduce memory usage, and work better if the BVH and pbvh::Tree
* relying on a single BVH should reduce memory usage, and work better if the BVH and #pbvh::Tree
* are ever merged.
*
* One key decision is separating building transfer index maps from actually transferring any

View File

@@ -47,7 +47,7 @@
#define MAX_TREETYPE 32
/* Setting zero so we can catch bugs in BLI_task/KDOPBVH.
* TODO(sergey): Deduplicate the limits with blender::bke::pbvh::Tree from BKE.
* TODO(sergey): Deduplicate the limits with #blender::bke::pbvh::Tree from BKE.
*/
#ifndef NDEBUG
# define KDOPBVH_THREAD_LEAF_THRESHOLD 0

View File

@@ -255,7 +255,7 @@ static OldNewMap *oldnewmap_new()
}
/**
* \return `true` if the \a oldaddr key has been sucessfully added to the \a onm, and no existing
* \return `true` if the \a oldaddr key has been successfully added to the \a onm, and no existing
* entry was overwritten.
*/
static bool oldnewmap_insert(OldNewMap *onm, const void *oldaddr, void *newaddr, int nr)

View File

@@ -95,7 +95,7 @@ void Camera::sync()
int2 display_extent = inst_.film.display_extent_get();
int2 film_extent = inst_.film.film_extent_get();
int2 film_offset = inst_.film.film_offset_get();
/* Overscan in film pixel. Not the same as `render_overscan_get`. */
/* Over-scan in film pixel. Not the same as `render_overscan_get`. */
int film_overscan = inst_.film.overscan_pixels_get(overscan_, film_extent);
rcti film_rect;

View File

@@ -86,8 +86,8 @@ class Film {
int2 display_extent;
eViewLayerEEVEEPassType enabled_passes_ = eViewLayerEEVEEPassType(0);
/* Store the pass types needed by the viewport compositor separatly, because some passes might be
* enabled but not used by the viewport compositor, so they needn't be written. */
/* Store the pass types needed by the viewport compositor separately, because some passes might
* be enabled but not used by the viewport compositor, so they needn't be written. */
eViewLayerEEVEEPassType viewport_compositor_enabled_passes_ = eViewLayerEEVEEPassType(0);
PassCategory enabled_categories_ = PassCategory(0);
bool use_reprojection_ = false;

View File

@@ -523,7 +523,7 @@ void Instance::render_frame(RenderEngine *engine, RenderLayer *render_layer, con
if ((sampling.sample_index() == 1) || ((sampling.sample_index() % 25) == 0) ||
sampling.finished())
{
/* TODO: Use fmt. */
/* TODO: Use `fmt`. */
std::string re_info = "Rendering " + std::to_string(sampling.sample_index()) + " / " +
std::to_string(sampling.sample_count()) + " samples";
RE_engine_update_stats(engine, nullptr, re_info.c_str());

View File

@@ -278,7 +278,7 @@ GPU_SHADER_CREATE_INFO(eevee_surf_shadow_tbdr)
.define("SHADOW_UPDATE_TBDR")
.builtins(BuiltinBits::LAYER)
/* Use greater depth write to avoid loosing the early Z depth test but ensure correct fragment
ordering after slope bias. */
* ordering after slope bias. */
.depth_write(DepthWrite::GREATER)
/* F32 color attachment for on-tile depth accumulation without atomics. */
.fragment_out(0, Type::FLOAT, "out_depth", DualBlend::NONE, SHADOW_ROG_ID);

View File

@@ -790,7 +790,7 @@ static GPENCIL_tObject *grease_pencil_object_cache_populate(GPENCIL_PrivateData
visible_strokes.foreach_index([&](const int stroke_i, const int pos) {
const IndexRange points = points_by_curve[stroke_i];
/* The material index is allowed to be negative as it's stored as a generic attribure. We
/* The material index is allowed to be negative as it's stored as a generic attribute. We
* clamp it here to avoid crashing in the rendering code. Any stroke with a material < 0 will
* use the first material in the first material slot.*/
const int material_index = std::max(stroke_materials[stroke_i], 0);

View File

@@ -1573,9 +1573,9 @@ static size_t animfilter_action_slots(bAnimContext *ac,
BLI_assert(slot);
/* In some cases (see `ob_to_keylist()` and friends) fake bDopeSheet and fake bAnimContext are
* created. These are mostly null-initialised, and so do not have a bmain. This means that
* created. These are mostly null-initialized, and so do not have a bmain. This means that
* lookup of the animated ID is not possible, which can result in failure to look up the proper
* F-Curve display name. For the `..._to_keylist` functions that doens't matter, as those are
* F-Curve display name. For the `..._to_keylist` functions that doesn't matter, as those are
* only interested in the key data anyway. So rather than trying to get a reliable `bmain`
* through the maze, this code just treats it as optional (even though ideally it should always
* be known). */

View File

@@ -1311,7 +1311,7 @@ void ED_view3d_buttons_region_layout_ex(const bContext *C,
* \param frame_selected Frame the newly out-of-local view to show currently visible selected
* objects. Will only do something if a valid #depsgraph pointer is also provided.
* \param smooth_viewtx Smooth transition time (in milliseconds) between current view and final
* view, if changes are hapenning. Currently only used if #frame_selected is enabled.
* view, if changes are happening. Currently only used if #frame_selected is enabled.
*
* \return `true` if the local view was actually exited.
*/

View File

@@ -120,7 +120,7 @@ struct SeqStripDrawData {
/* Horizontal strip positions (1.0 is one frame). */
float left_handle, right_handle; /* Left and right strip sides. */
float content_start, content_end; /* Start and end of actual content (only relevant for strips
that have holdout regions). */
* that have holdout regions). */
float handle_width;
/* Vertical strip positions (1.0 is one channel). */
float bottom;

View File

@@ -51,11 +51,11 @@ struct VKGraphicsInfo {
bool operator==(const VertexIn &other) const
{
// TODO: use an exact implementation and remove the hash compare.
/*
/* TODO: use an exact implementation and remove the hash compare. */
#if 0
return vk_topology == other.vk_topology && attributes.hash() == other.attributes.hash() &&
bindings.hash() == other.bindings.hash();
*/
#endif
return hash() == other.hash();
}

View File

@@ -188,7 +188,7 @@ typedef struct LightCache {
LightCacheTexture cube_tx;
/** Does not contains valid GPUTexture, only data. */
LightCacheTexture *cube_mips;
/* All lightprobes data contained in the cache. */
/* All light-probes data contained in the cache. */
LightProbeCache *cube_data;
LightGridCache *grid_data;
} LightCache;

View File

@@ -235,7 +235,7 @@ enum PropertyFlag {
*/
PROP_HIDDEN = (1 << 19),
/**
* Donnot preserve the last value for repeated operator calls.
* Doesn't preserve the last value for repeated operator calls.
*
* Also don't save in presets, as if #PROP_SKIP_PRESET was set.
*/

View File

@@ -483,7 +483,7 @@ static void rna_PaintModeSettings_canvas_source_update(bContext *C, PointerRNA *
{
Scene *scene = CTX_data_scene(C);
Object *ob = CTX_data_active_object(C);
/* When canvas source changes the pbvh::Tree would require updates when switching between color
/* When canvas source changes the #pbvh::Tree would require updates when switching between color
* attributes. */
if (ob && ob->type == OB_MESH) {
BKE_texpaint_slots_refresh_object(scene, ob);