Cleanup: spelling in comments

This commit is contained in:
Campbell Barton 2022-03-23 12:15:50 +11:00
parent 6bb28a1a52
commit 4822153b85
8 changed files with 12 additions and 13 deletions

View File

@ -733,7 +733,7 @@ void BKE_image_format_to_imbuf(ImBuf *ibuf, const ImageFormatData *imf)
}
#endif
else {
/* R_IMF_IMTYPE_JPEG90, etc. default we save jpegs */
/* #R_IMF_IMTYPE_JPEG90, etc. default to JPEG. */
if (quality < 10) {
quality = 90;
}

View File

@ -85,4 +85,4 @@ TEST(math_vector, Clamp)
EXPECT_EQ(result_2.z, -50);
}
} // namespace blender::tests
} // namespace blender::tests

View File

@ -515,7 +515,7 @@ class Texture : NonCopyable {
/**
* Ensure the availability of mipmap views.
* Mip view covers all layers of array textures.
* MIP view covers all layers of array textures.
*/
bool ensure_mip_views(bool cube_as_array = false)
{

View File

@ -432,7 +432,7 @@ struct DRWView {
struct DRWView *parent;
ViewInfos storage;
/** Number of active clipplanes. */
/** Number of active clip planes. */
int clip_planes_len;
/** Does culling result needs to be updated. */
bool is_dirty;

View File

@ -1135,7 +1135,7 @@ static int object_origin_set_exec(bContext *C, wmOperator *op)
}
if (ob->data == nullptr) {
/* special support for dupligroups */
/* Special support for instanced collections. */
if ((ob->transflag & OB_DUPLICOLLECTION) && ob->instance_collection &&
(ob->instance_collection->id.tag & LIB_TAG_DOIT) == 0) {
if (ID_IS_LINKED(ob->instance_collection)) {

View File

@ -108,8 +108,7 @@ void MTLBackend::render_begin()
void MTLBackend::render_end()
{
/* If call-count reaches zero, drain auto release pool.
* Esures temporary objects are freed within a frame's
* lifetime. */
* Ensures temporary objects are freed within a frame's lifetime. */
BLI_assert(g_autoreleasepool != nil);
g_autoreleasepool_depth--;
BLI_assert(g_autoreleasepool_depth >= 0);
@ -136,7 +135,7 @@ bool MTLBackend::is_inside_render_boundary()
/** \name Platform
* \{ */
/* For Metal, platform_init needs to be called after MTLContext initialisation. */
/* For Metal, platform_init needs to be called after MTLContext initialization. */
void MTLBackend::platform_init(MTLContext *ctx)
{
if (GPG.initialized) {
@ -318,7 +317,7 @@ void MTLBackend::capabilities_init(MTLContext *ctx)
id<MTLDevice> device = nil; /*ctx->device TODO(Metal): Implement MTLContext. */
BLI_assert(device);
/* Initialise Capabilities. */
/* Initialize Capabilities. */
MTLBackend::capabilities.supports_argument_buffers_tier2 = ([device argumentBuffersSupport] ==
MTLArgumentBuffersTier2);
MTLBackend::capabilities.supports_family_mac1 = [device supportsFamily:MTLGPUFamilyMac1];
@ -398,8 +397,8 @@ void MTLBackend::capabilities_init(MTLContext *ctx)
GCaps.broken_amd_driver = false;
/* Metal related workarounds. */
/* Minimum per-vertex stride is 4 bytes in Metal. A bound vertex buffer must contribute atleast 4
* bytes per vertex. */
/* Minimum per-vertex stride is 4 bytes in Metal.
* A bound vertex buffer must contribute at least 4 bytes per vertex. */
GCaps.minimum_per_vertex_stride = 4;
}

View File

@ -21,7 +21,7 @@ namespace gpu {
/* Context-specific limits -- populated in 'MTLBackend::platform_init' */
typedef struct MTLCapabilities {
/* Variable Limits & faeture sets */
/* Variable Limits & feature sets. */
int max_color_render_targets = 4; /* Minimum = 4 */
int buffer_alignment_for_textures = 256; /* Upper bound = 256 bytes */
int minimum_buffer_offset_alignment = 256; /* Upper bound = 256 bytes */

View File

@ -27,7 +27,7 @@ GLStorageBuf::GLStorageBuf(size_t size, GPUUsageType usage, const char *name)
: StorageBuf(size, name)
{
usage_ = usage;
/* Do not create ubo GL buffer here to allow allocation from any thread. */
/* Do not create UBO GL buffer here to allow allocation from any thread. */
BLI_assert(size <= GLContext::max_ssbo_size);
}