Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <campbell@blender.org>2022-07-04 08:16:24 +0300
committerCampbell Barton <campbell@blender.org>2022-07-04 08:26:57 +0300
commit148dcb395401b6b11a5a56b03c449e9852e5e876 (patch)
tree3d55e9a96abf6fd680ee3081ede4913eb61d044a /source/blender
parentfaa97de208dab9c442213c8265092876138e3ec0 (diff)
Cleanup: spelling in comments
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/blenfont/intern/blf_glyph.c2
-rw-r--r--source/blender/blenfont/intern/blf_thumbs.c2
-rw-r--r--source/blender/blenkernel/BKE_image.h2
-rw-r--r--source/blender/blenkernel/intern/tracking.c2
-rw-r--r--source/blender/compositor/intern/COM_Converter.h4
-rw-r--r--source/blender/editors/space_text/text_format_lua.c13
-rw-r--r--source/blender/editors/space_text/text_format_osl.c11
-rw-r--r--source/blender/editors/space_text/text_format_pov.c11
-rw-r--r--source/blender/editors/space_text/text_format_pov_ini.c11
-rw-r--r--source/blender/editors/space_text/text_format_py.c11
-rw-r--r--source/blender/editors/uvedit/uvedit_ops.c14
-rw-r--r--source/blender/gpu/metal/mtl_backend.mm2
-rw-r--r--source/blender/gpu/metal/mtl_common.hh2
-rw-r--r--source/blender/gpu/metal/mtl_context.mm4
-rw-r--r--source/blender/gpu/metal/mtl_memory.hh19
-rw-r--r--source/blender/gpu/metal/mtl_memory.mm6
16 files changed, 63 insertions, 53 deletions
diff --git a/source/blender/blenfont/intern/blf_glyph.c b/source/blender/blenfont/intern/blf_glyph.c
index 63cf3b3e564..2eb43e3df43 100644
--- a/source/blender/blenfont/intern/blf_glyph.c
+++ b/source/blender/blenfont/intern/blf_glyph.c
@@ -378,7 +378,7 @@ static eUnicodeBlock unicode_blocks[] = {
{0xFE30, 0xFE4F, 65}, /* CJK Compatibility Forms. */
{0xFE50, 0xFE6F, 66}, /* Small Form Variants. */
{0xFE70, 0xFEFF, 67}, /* Arabic Presentation Forms-B. */
- {0xFF00, 0xFFEF, 68}, /* Halfwidth And Fullwidth Forms. */
+ {0xFF00, 0xFFEF, 68}, /* Half-width And Full-width Forms. */
{0xFFF0, 0xFFFF, 69}, /* Specials. */
{0x10000, 0x1013F, 101}, /* Linear B. */
{0x10140, 0x1018F, 102}, /* Ancient Greek Numbers. */
diff --git a/source/blender/blenfont/intern/blf_thumbs.c b/source/blender/blenfont/intern/blf_thumbs.c
index a75072f854f..9460e9413d1 100644
--- a/source/blender/blenfont/intern/blf_thumbs.c
+++ b/source/blender/blenfont/intern/blf_thumbs.c
@@ -87,7 +87,7 @@ void BLF_thumb_preview(const char *filepath,
font->pos[1] -= (int)((float)blf_font_ascender(font) * 1.1f);
/* We fallback to default english strings in case not enough chars are available in current
- * font for given translated string (useful in non-latin i18n context, like Chinese,
+ * font for given translated string (useful in non-Latin i18n context, like Chinese,
* since many fonts will then show nothing but ugly 'missing char' in their preview).
* Does not handle all cases, but much better than nothing.
*/
diff --git a/source/blender/blenkernel/BKE_image.h b/source/blender/blenkernel/BKE_image.h
index e54932fbc4e..6ec1285af0c 100644
--- a/source/blender/blenkernel/BKE_image.h
+++ b/source/blender/blenkernel/BKE_image.h
@@ -198,7 +198,7 @@ struct Image *BKE_image_add_from_imbuf(struct Main *bmain, struct ImBuf *ibuf, c
* For a non-viewer single-buffer image (single frame file, or generated image) replace its image
* buffer with the given one.
* If an unsupported image type (multi-layer, image sequence, ...) the function will assert in the
- * debug mode and will have an underfined behavior in the release mode.
+ * debug mode and will have an undefined behavior in the release mode.
*/
void BKE_image_replace_imbuf(struct Image *image, struct ImBuf *ibuf);
diff --git a/source/blender/blenkernel/intern/tracking.c b/source/blender/blenkernel/intern/tracking.c
index 6abc40e89bc..cd1af5a8de4 100644
--- a/source/blender/blenkernel/intern/tracking.c
+++ b/source/blender/blenkernel/intern/tracking.c
@@ -2839,7 +2839,7 @@ ImBuf *BKE_tracking_get_plane_imbuf(const ImBuf *frame_ibuf,
ImBuf *plane_ibuf = IMB_allocImBuf(
num_samples_x, num_samples_y, 32, frame_ibuf->rect_float ? IB_rectfloat : IB_rect);
- /* Calculate corner coordinates in pixel space, as spearate X/Y arrays. */
+ /* Calculate corner coordinates in pixel space, as separate X/Y arrays. */
const double src_pixel_x[4] = {corners[0][0] * frame_width,
corners[1][0] * frame_width,
corners[2][0] * frame_width,
diff --git a/source/blender/compositor/intern/COM_Converter.h b/source/blender/compositor/intern/COM_Converter.h
index e0164b9162d..eba61e07e1a 100644
--- a/source/blender/compositor/intern/COM_Converter.h
+++ b/source/blender/compositor/intern/COM_Converter.h
@@ -37,8 +37,8 @@ Node *COM_convert_bnode(bNode *b_node);
bool COM_bnode_is_fast_node(const bNode &b_node);
/**
- * \brief This function will add a datetype conversion rule when the to-socket does not support the
- * from-socket actual data type.
+ * \brief This function will add a date-type conversion rule when the to-socket does not support
+ * the from-socket actual data type.
*/
NodeOperation *COM_convert_data_type(const NodeOperationOutput &from,
const NodeOperationInput &to);
diff --git a/source/blender/editors/space_text/text_format_lua.c b/source/blender/editors/space_text/text_format_lua.c
index f7d7f9c6238..4b3ee1c15c7 100644
--- a/source/blender/editors/space_text/text_format_lua.c
+++ b/source/blender/editors/space_text/text_format_lua.c
@@ -264,7 +264,7 @@ static void txtfmt_lua_format_line(SpaceText *st, TextLine *line, const bool do_
cont = (*str == '"') ? FMT_CONT_QUOTEDOUBLE : FMT_CONT_QUOTESINGLE;
*fmt = FMT_TYPE_STRING;
}
- /* White-space (all ws. has been converted to spaces). */
+ /* White-space (all white-space has been converted to spaces). */
else if (*str == ' ') {
*fmt = FMT_TYPE_WHITESPACE;
}
@@ -287,18 +287,19 @@ static void txtfmt_lua_format_line(SpaceText *st, TextLine *line, const bool do_
else if ((*str != '#') && text_check_delim(*str)) {
*fmt = FMT_TYPE_SYMBOL;
}
- /* Identifiers and other text (no previous ws. or delims. so text continues) */
+ /* Identifiers and other text (no previous white-space/delimiters so text continues). */
else if (prev == FMT_TYPE_DEFAULT) {
str += BLI_str_utf8_size_safe(str) - 1;
*fmt = FMT_TYPE_DEFAULT;
}
- /* Not ws, a digit, punct, or continuing text. Must be new, check for special words */
+ /* Not white-space, a digit, punctuation, or continuing text.
+ * Must be new, check for special words. */
else {
- /* Keep aligned args for readability. */
+ /* Keep aligned arguments for readability. */
/* clang-format off */
- /* Special vars(v) or built-in keywords(b) */
- /* keep in sync with 'txtfmt_osl_format_identifier()' */
+ /* Special `vars(v)` or built-in `keywords(b)` */
+ /* keep in sync with `txtfmt_osl_format_identifier()`. */
if ((i = txtfmt_lua_find_specialvar(str)) != -1) { prev = FMT_TYPE_SPECIAL;
} else if ((i = txtfmt_lua_find_keyword(str)) != -1) { prev = FMT_TYPE_KEYWORD;
}
diff --git a/source/blender/editors/space_text/text_format_osl.c b/source/blender/editors/space_text/text_format_osl.c
index 27dc1174c49..575eadeee66 100644
--- a/source/blender/editors/space_text/text_format_osl.c
+++ b/source/blender/editors/space_text/text_format_osl.c
@@ -285,7 +285,7 @@ static void txtfmt_osl_format_line(SpaceText *st, TextLine *line, const bool do_
cont = (*str == '"') ? FMT_CONT_QUOTEDOUBLE : FMT_CONT_QUOTESINGLE;
*fmt = FMT_TYPE_STRING;
}
- /* White-space (all ws. has been converted to spaces). */
+ /* White-space (all white-space has been converted to spaces). */
else if (*str == ' ') {
*fmt = FMT_TYPE_WHITESPACE;
}
@@ -298,18 +298,19 @@ static void txtfmt_osl_format_line(SpaceText *st, TextLine *line, const bool do_
else if ((*str != '#') && text_check_delim(*str)) {
*fmt = FMT_TYPE_SYMBOL;
}
- /* Identifiers and other text (no previous ws. or delims. so text continues) */
+ /* Identifiers and other text (no previous white-space or delimiters. so text continues). */
else if (prev == FMT_TYPE_DEFAULT) {
str += BLI_str_utf8_size_safe(str) - 1;
*fmt = FMT_TYPE_DEFAULT;
}
- /* Not ws, a digit, punct, or continuing text. Must be new, check for special words */
+ /* Not white-space, a digit, punctuation, or continuing text.
+ * Must be new, check for special words. */
else {
- /* Keep aligned args for readability. */
+ /* Keep aligned arguments for readability. */
/* clang-format off */
/* Special vars(v) or built-in keywords(b) */
- /* keep in sync with 'txtfmt_osl_format_identifier()' */
+ /* keep in sync with `txtfmt_osl_format_identifier()`. */
if ((i = txtfmt_osl_find_specialvar(str)) != -1) { prev = FMT_TYPE_SPECIAL;
} else if ((i = txtfmt_osl_find_builtinfunc(str)) != -1) { prev = FMT_TYPE_KEYWORD;
} else if ((i = txtfmt_osl_find_reserved(str)) != -1) { prev = FMT_TYPE_RESERVED;
diff --git a/source/blender/editors/space_text/text_format_pov.c b/source/blender/editors/space_text/text_format_pov.c
index 7c2f098f0fa..7c2c4829ad3 100644
--- a/source/blender/editors/space_text/text_format_pov.c
+++ b/source/blender/editors/space_text/text_format_pov.c
@@ -857,7 +857,7 @@ static void txtfmt_pov_format_line(SpaceText *st, TextLine *line, const bool do_
cont = (*str == '"') ? FMT_CONT_QUOTEDOUBLE : FMT_CONT_QUOTESINGLE;
*fmt = FMT_TYPE_STRING;
}
- /* White-space (all ws. has been converted to spaces). */
+ /* White-space (all white-space has been converted to spaces). */
else if (*str == ' ') {
*fmt = FMT_TYPE_WHITESPACE;
}
@@ -880,18 +880,19 @@ static void txtfmt_pov_format_line(SpaceText *st, TextLine *line, const bool do_
else if (text_check_delim(*str)) {
*fmt = FMT_TYPE_SYMBOL;
}
- /* Identifiers and other text (no previous ws. or delims. so text continues) */
+ /* Identifiers and other text (no previous white-space/delimiters so text continues). */
else if (prev == FMT_TYPE_DEFAULT) {
str += BLI_str_utf8_size_safe(str) - 1;
*fmt = FMT_TYPE_DEFAULT;
}
- /* Not ws, a digit, punct, or continuing text. Must be new, check for special words */
+ /* Not white-space, a digit, punctuation, or continuing text.
+ * Must be new, check for special words. */
else {
- /* Keep aligned args for readability. */
+ /* Keep aligned arguments for readability. */
/* clang-format off */
/* Special vars(v) or built-in keywords(b) */
- /* keep in sync with 'txtfmt_pov_format_identifier()' */
+ /* keep in sync with `txtfmt_pov_format_identifier()`. */
if ((i = txtfmt_pov_find_specialvar(str)) != -1) { prev = FMT_TYPE_SPECIAL;
} else if ((i = txtfmt_pov_find_keyword(str)) != -1) { prev = FMT_TYPE_KEYWORD;
} else if ((i = txtfmt_pov_find_reserved_keywords(str)) != -1) { prev = FMT_TYPE_RESERVED;
diff --git a/source/blender/editors/space_text/text_format_pov_ini.c b/source/blender/editors/space_text/text_format_pov_ini.c
index 6844f08cca6..dda3b7089fe 100644
--- a/source/blender/editors/space_text/text_format_pov_ini.c
+++ b/source/blender/editors/space_text/text_format_pov_ini.c
@@ -435,7 +435,7 @@ static void txtfmt_pov_ini_format_line(SpaceText *st, TextLine *line, const bool
cont = (*str == '"') ? FMT_CONT_QUOTEDOUBLE : FMT_CONT_QUOTESINGLE;
*fmt = FMT_TYPE_STRING;
}
- /* White-space (all ws. has been converted to spaces). */
+ /* White-space (all white-space has been converted to spaces). */
else if (*str == ' ') {
*fmt = FMT_TYPE_WHITESPACE;
}
@@ -458,18 +458,19 @@ static void txtfmt_pov_ini_format_line(SpaceText *st, TextLine *line, const bool
else if ((*str != '#') && text_check_delim(*str)) {
*fmt = FMT_TYPE_SYMBOL;
}
- /* Identifiers and other text (no previous ws. or delims. so text continues) */
+ /* Identifiers and other text (no previous white-space/delimiters so text continues). */
else if (prev == FMT_TYPE_DEFAULT) {
str += BLI_str_utf8_size_safe(str) - 1;
*fmt = FMT_TYPE_DEFAULT;
}
- /* Not ws, a digit, punct, or continuing text. Must be new, check for special words */
+ /* Not white-space, a digit, punctuation, or continuing text.
+ * Must be new, check for special words */
else {
- /* Keep aligned args for readability. */
+ /* Keep aligned arguments for readability. */
/* clang-format off */
/* Special vars(v) or built-in keywords(b) */
- /* keep in sync with 'txtfmt_ini_format_identifier()' */
+ /* keep in sync with `txtfmt_ini_format_identifier()`. */
if ((i = txtfmt_ini_find_keyword(str)) != -1) { prev = FMT_TYPE_KEYWORD;
} else if ((i = txtfmt_ini_find_reserved(str)) != -1) { prev = FMT_TYPE_RESERVED;
}
diff --git a/source/blender/editors/space_text/text_format_py.c b/source/blender/editors/space_text/text_format_py.c
index 47d0168195b..aa361f07932 100644
--- a/source/blender/editors/space_text/text_format_py.c
+++ b/source/blender/editors/space_text/text_format_py.c
@@ -425,7 +425,7 @@ static void txtfmt_py_format_line(SpaceText *st, TextLine *line, const bool do_n
}
*fmt = FMT_TYPE_STRING;
}
- /* White-space (all ws. has been converted to spaces). */
+ /* White-space (all white-space has been converted to spaces). */
else if (*str == ' ') {
*fmt = FMT_TYPE_WHITESPACE;
}
@@ -447,18 +447,19 @@ static void txtfmt_py_format_line(SpaceText *st, TextLine *line, const bool do_n
else if ((*str != '@') && text_check_delim(*str)) {
*fmt = FMT_TYPE_SYMBOL;
}
- /* Identifiers and other text (no previous ws. or delims. so text continues) */
+ /* Identifiers and other text (no previous white-space/delimiters so text continues). */
else if (prev == FMT_TYPE_DEFAULT) {
str += BLI_str_utf8_size_safe(str) - 1;
*fmt = FMT_TYPE_DEFAULT;
}
- /* Not ws, a digit, punct, or continuing text. Must be new, check for special words */
+ /* Not white-space, a digit, punctuation, or continuing text.
+ * Must be new, check for special words. */
else {
- /* Keep aligned args for readability. */
+ /* Keep aligned arguments for readability. */
/* clang-format off */
/* Special vars(v) or built-in keywords(b) */
- /* keep in sync with 'txtfmt_py_format_identifier()' */
+ /* keep in sync with `txtfmt_py_format_identifier()`. */
if ((i = txtfmt_py_find_specialvar(str)) != -1) { prev = FMT_TYPE_SPECIAL;
} else if ((i = txtfmt_py_find_builtinfunc(str)) != -1) { prev = FMT_TYPE_KEYWORD;
} else if ((i = txtfmt_py_find_decorator(str)) != -1) { prev = FMT_TYPE_DIRECTIVE;
diff --git a/source/blender/editors/uvedit/uvedit_ops.c b/source/blender/editors/uvedit/uvedit_ops.c
index 70c0333fb27..4844ff22b68 100644
--- a/source/blender/editors/uvedit/uvedit_ops.c
+++ b/source/blender/editors/uvedit/uvedit_ops.c
@@ -411,7 +411,7 @@ static bool uvedit_uv_align_weld(Scene *scene,
return changed;
}
-/* Bitwise-or together, then choose MLoopUV with highest value. */
+/** Bitwise-or together, then choose #MLoopUV with highest value. */
typedef enum eUVEndPointPrecedence {
UVEP_INVALID = 0,
UVEP_SELECTED = (1 << 0),
@@ -427,7 +427,8 @@ static eUVEndPointPrecedence uvedit_line_update_get_precedence(const MLoopUV *lu
return precedence;
}
-/* Helper to find two endpoints (`a` and `b`) which have higher precedence, and are far apart.
+/**
+ * Helper to find two endpoints (`a` and `b`) which have higher precedence, and are far apart.
* Note that is only a heuristic and won't always find the best two endpoints.
*/
static bool uvedit_line_update_endpoint(const MLoopUV *luv,
@@ -442,7 +443,7 @@ static bool uvedit_line_update_endpoint(const MLoopUV *luv,
float len_sq_b = len_squared_v2v2(uv_b, luv->uv);
/* Caching the value of `len_sq_ab` is unlikely to be faster than recalculating.
- * Profile before optmizing. */
+ * Profile before optimizing. */
float len_sq_ab = len_squared_v2v2(uv_a, uv_b);
if ((*prec_a < flags && 0.0f < len_sq_b) || (*prec_a == flags && len_sq_ab < len_sq_b)) {
@@ -460,7 +461,8 @@ static bool uvedit_line_update_endpoint(const MLoopUV *luv,
return false;
}
-/* Find two end extreme points to specify a line, then straighten `len` elements
+/**
+ * Find two end extreme points to specify a line, then straighten `len` elements
* by moving UVs on the X-axis, Y-axis, or the closest point on the line segment.
*/
static bool uvedit_uv_straighten_elements(const UvElement *element,
@@ -532,7 +534,9 @@ static bool uvedit_uv_straighten_elements(const UvElement *element,
return changed;
}
-/* Group selected UVs into islands, then apply uvedit_uv_straighten_elements to each island. */
+/**
+ * Group selected UVs into islands, then apply uvedit_uv_straighten_elements to each island.
+ */
static bool uvedit_uv_straighten(Scene *scene, BMesh *bm, eUVWeldAlign tool)
{
const int cd_loop_uv_offset = CustomData_get_offset(&bm->ldata, CD_MLOOPUV);
diff --git a/source/blender/gpu/metal/mtl_backend.mm b/source/blender/gpu/metal/mtl_backend.mm
index 117b8352a0a..d2524cc16e3 100644
--- a/source/blender/gpu/metal/mtl_backend.mm
+++ b/source/blender/gpu/metal/mtl_backend.mm
@@ -127,7 +127,7 @@ void MTLBackend::render_end()
void MTLBackend::render_step()
{
- /* NOTE(Metal): Primarily called from main thread, but below datastructures
+ /* NOTE(Metal): Primarily called from main thread, but below data-structures
* and operations are thread-safe, and GPUContext rendering coordination
* is also thread-safe. */
diff --git a/source/blender/gpu/metal/mtl_common.hh b/source/blender/gpu/metal/mtl_common.hh
index 28404d91b4b..44ba786f90f 100644
--- a/source/blender/gpu/metal/mtl_common.hh
+++ b/source/blender/gpu/metal/mtl_common.hh
@@ -10,7 +10,7 @@
#define MTL_MAX_COMMAND_BUFFERS 64
/* Number of frames for which we retain in-flight resources such as scratch buffers.
- * Set as number of GPU frames in flight, plus an additioanl value for extra possible CPU frame. */
+ * Set as number of GPU frames in flight, plus an additional value for extra possible CPU frame. */
#define MTL_NUM_SAFE_FRAMES (MTL_MAX_DRAWABLES + 1)
#endif
diff --git a/source/blender/gpu/metal/mtl_context.mm b/source/blender/gpu/metal/mtl_context.mm
index 2cf70718b76..2ab2e20158a 100644
--- a/source/blender/gpu/metal/mtl_context.mm
+++ b/source/blender/gpu/metal/mtl_context.mm
@@ -16,7 +16,7 @@ using namespace blender::gpu;
namespace blender::gpu {
-/* Global memory mamnager */
+/* Global memory manager. */
MTLBufferPool MTLContext::global_memory_manager;
/* -------------------------------------------------------------------- */
@@ -51,7 +51,7 @@ MTLContext::MTLContext(void *ghost_window) : memory_manager(*this), main_command
this->memory_manager.init();
this->state_manager = new MTLStateManager(this);
- /* Ensure global memory manager is initialied */
+ /* Ensure global memory manager is initialized. */
MTLContext::global_memory_manager.init(this->device);
/* Initialize texture read/update structures. */
diff --git a/source/blender/gpu/metal/mtl_memory.hh b/source/blender/gpu/metal/mtl_memory.hh
index 81793b0647c..4dbc1b29c6b 100644
--- a/source/blender/gpu/metal/mtl_memory.hh
+++ b/source/blender/gpu/metal/mtl_memory.hh
@@ -23,7 +23,7 @@
* The Metal Backend Memory manager is designed to provide an interface
* for all other MTL_* modules where memory allocation is required.
*
- * Different allocation strategies and datastructures are used depending
+ * Different allocation strategies and data-structures are used depending
* on how the data is used by the backend. These aim to optimally handle
* system memory and abstract away any complexity from the MTL_* modules
* themselves.
@@ -107,8 +107,8 @@ class MTLBuffer {
/* Metal resource. */
id<MTLBuffer> metal_buffer_;
- /* Host-visible mapped-memory pointer. Behaviour depends on buffer type:
- * - Shared buffers: pointer represents base address of MTLBuffer whose data
+ /* Host-visible mapped-memory pointer. Behavior depends on buffer type:
+ * - Shared buffers: pointer represents base address of #MTLBuffer whose data
* access has shared access by both the CPU and GPU on
* Unified Memory Architectures (UMA).
* - Managed buffer: Host-side mapped buffer region for CPU (Host) access. Managed buffers
@@ -350,14 +350,14 @@ class MTLBufferPool {
bool ensure_initialised_ = false;
id<MTLDevice> device_ = nil;
- /* The buffer selection aims to pick a buffer which meets the minimum size requierments.
+ /* The buffer selection aims to pick a buffer which meets the minimum size requirements.
* To do this, we keep an ordered set of all available buffers. If the buffer is larger than the
- * desired allocation size, we check it aginst `mtl_buffer_size_threshold_factor_`, which defines
- * what % larger than the original allocation the buffer can be.
+ * desired allocation size, we check it against `mtl_buffer_size_threshold_factor_`,
+ * which defines what % larger than the original allocation the buffer can be.
* - A higher value results in greater re-use of previously allocated buffers of similar sizes.
- * - A lower value may result in more dynamic allocations, but minimised memory usage for a given
+ * - A lower value may result in more dynamic allocations, but minimized memory usage for a given
* scenario.
- * The current value of 1.26 is calibrated for optimal performance and memory utilisation. */
+ * The current value of 1.26 is calibrated for optimal performance and memory utilization. */
static constexpr float mtl_buffer_size_threshold_factor_ = 1.26;
/* Buffer pools using MTLResourceOptions as key for allocation type.
@@ -453,7 +453,8 @@ class MTLScratchBufferManager {
MTLScratchBufferManager(MTLContext &context) : context_(context){};
~MTLScratchBufferManager();
- /* Explicit initialisation and freeing of resources. Init must occur after device creation. */
+ /* Explicit initialization and freeing of resources.
+ * Initialization must occur after device creation. */
void init();
void free();
diff --git a/source/blender/gpu/metal/mtl_memory.mm b/source/blender/gpu/metal/mtl_memory.mm
index 5c5938997e6..6316a49407d 100644
--- a/source/blender/gpu/metal/mtl_memory.mm
+++ b/source/blender/gpu/metal/mtl_memory.mm
@@ -58,7 +58,7 @@ void MTLBufferPool::free()
gpu::MTLBuffer *MTLBufferPool::allocate_buffer(uint64_t size, bool cpu_visible, const void *bytes)
{
- /* Allocate buffer with default HW-compatible alignemnt of 256 bytes.
+ /* Allocate buffer with default HW-compatible alignment of 256 bytes.
* See https://developer.apple.com/metal/Metal-Feature-Set-Tables.pdf for more. */
return this->allocate_buffer_aligned(size, 256, cpu_visible, bytes);
}
@@ -342,7 +342,7 @@ void MTLBufferPool::insert_buffer_into_pool(MTLResourceOptions options, gpu::MTL
/* Ensure pool exists. */
this->ensure_buffer_pool(options);
- /* TODO(Metal): Support purgability - Allow buffer in pool to have its memory taken back by the
+ /* TODO(Metal): Support purgeability - Allow buffer in pool to have its memory taken back by the
* OS if needed. As we keep allocations around, they may not actually be in use, but we can
* ensure they do not block other apps from using memory. Upon a buffer being needed again, we
* can reset this state.
@@ -615,7 +615,7 @@ void MTLScratchBufferManager::init()
if (!this->initialised_) {
BLI_assert(context_.device);
- /* Initialise Scratch buffers */
+ /* Initialize Scratch buffers. */
for (int sb = 0; sb < mtl_max_scratch_buffers_; sb++) {
scratch_buffers_[sb] = new MTLCircularBuffer(
context_, mtl_scratch_buffer_initial_size_, true);