Cleanup: spelling in comments

This commit is contained in:
Campbell Barton
2024-02-16 14:26:46 +11:00
parent 9992718703
commit 7582b15c4c
8 changed files with 20 additions and 18 deletions

View File

@@ -45,7 +45,7 @@ struct DupliObject {
float mat[4][4];
float orco[3], uv[2];
short type; /* from Object.transflag */
short type; /* From #Object::transflag. */
char no_draw;
/* If this dupli object is belongs to a preview, this is non-null. */
const blender::bke::GeometrySet *preview_base_geometry;

View File

@@ -74,7 +74,7 @@ void BKE_ffmpeg_context_free(void *context_v);
void BKE_ffmpeg_exit();
/**
* Gets a libswscale context for given size and format parameters.
* Gets a `libswscale` context for given size and format parameters.
* After you're done using the context, call #BKE_ffmpeg_sws_release_context
* to release it. Internally the contexts are coming from the context
* pool/cache.

View File

@@ -316,8 +316,8 @@ TEST(lib_remap, never_null_usage_storage_requested_on_delete)
remapper,
(ID_REMAP_SKIP_NEVER_NULL_USAGE | ID_REMAP_STORE_NEVER_NULL_USAGE));
/* Never null usages unassignement is not enforced (no #ID_REMAP_FORCE_NEVER_NULL_USAGE), so the
* obdta should still use the original mesh. */
/* Never null usages un-assignment is not enforced (no #ID_REMAP_FORCE_NEVER_NULL_USAGE),
* so the object-data should still use the original mesh. */
EXPECT_EQ(context.test_data.object->data, context.test_data.mesh);
EXPECT_NE(context.test_data.object->data, nullptr);
EXPECT_TRUE(remapper.never_null_users().contains(&context.test_data.object->id));

View File

@@ -69,17 +69,19 @@ class StepDrawingGeometryBase {
/* Index of this drawing in the original combined array of all drawings in GreasePencil ID. */
int index_;
/* Data from #GreasePencilDrawingBase that needs to be saved in udo steps. */
/* Data from #GreasePencilDrawingBase that needs to be saved in undo steps. */
uint32_t flag_;
protected:
/* Ensures that the drawing from the given array at the current index exists, and has the propoer
* type.
/**
* Ensures that the drawing from the given array at the current index exists,
* and has the proposer type.
*
* Non-existing drawings can happen after extenting the drawings array.
* Non-existing drawings can happen after extending the drawings array.
*
* Mismatch in drawing types can happen when some drawings have been deleted between the undo
* step storage, and the current state of the GreasePencil data. */
* step storage, and the current state of the GreasePencil data.
*/
void decode_valid_drawingtype_at_index_ensure(MutableSpan<GreasePencilDrawingBase *> &drawings,
const GreasePencilDrawingType drawing_type) const
{

View File

@@ -37,7 +37,7 @@ static void extend_curves_straight(const float used_percent_length,
float overshoot_point_param = used_percent_length * (new_size - 1);
if (start_points[curve]) {
/** Here we use the vector between two adjacent points around #overshoot_point_param as
* our reference forthe direction of extention, however to have better tolerance for jitter,
* our reference for the direction of extension, however to have better tolerance for jitter,
* using the vector (a_few_points_back - end_point) might be a better solution in the future.
*/
int index1 = math::floor(overshoot_point_param);
@@ -271,7 +271,7 @@ bke::CurvesGeometry extend_curves(bke::CurvesGeometry &src_curves,
OffsetIndices dst_indices = offset_indices::accumulate_counts_to_offsets(dst_points_by_curve);
int target_point_count = dst_points_by_curve.last();
/* Make dest to source map for points. */
/* Make destination to source map for points. */
Array<int> dst_to_src_point(target_point_count);
for (const int curve : src_curves.curves_range()) {
const int point_count = points_by_curve[curve].size();

View File

@@ -333,13 +333,13 @@ typedef enum {
int GPU_shader_get_builtin_uniform(GPUShader *shader, int builtin);
/**
* Compile all staticly defined shaders and print a report to the console.
* Compile all statically defined shaders and print a report to the console.
*
* This is used for platform support, where bug reports can list all failing shaders.
*/
void GPU_shader_compile_static();
/** DEPRECATED: Use hardcoded buffer location instead. */
/** DEPRECATED: Use hard-coded buffer location instead. */
typedef enum {
GPU_UNIFORM_BLOCK_VIEW = 0, /* viewBlock */
GPU_UNIFORM_BLOCK_MODEL, /* modelBlock */
@@ -353,7 +353,7 @@ typedef enum {
GPU_NUM_UNIFORM_BLOCKS, /* Special value, denotes number of builtin uniforms block. */
} GPUUniformBlockBuiltin;
/** DEPRECATED: Use hardcoded buffer location instead. */
/** DEPRECATED: Use hard-coded buffer location instead. */
int GPU_shader_get_builtin_block(GPUShader *shader, int builtin);
/** DEPRECATED: Kept only because of Python GPU API. */

View File

@@ -196,9 +196,9 @@ static void deform_drawing(const ModifierData &md,
/* Always do the stretching first since it might depend on points which could be deleted by the
* shrink. */
if (mmd.start_fac < 0.0f || mmd.end_fac < 0.0f || needs_additional_shrinking) {
/* `trim_curves()` accepts the `end` valueas if it's sampling from the beginning of the
* curve, so we need to get the lengths of the curves and substract it from the back when the
* modifier is in Absolute mode. For convenience, we always call `trim_curves()` in LENGTH
/* #trim_curves() accepts the `end` values if it's sampling from the beginning of the
* curve, so we need to get the lengths of the curves and subtract it from the back when the
* modifier is in Absolute mode. For convenience, we always call #trim_curves() in LENGTH
* mode since the function itself will need length to be sampled anyway. */
Array<float> starts(curves.curves_num());
Array<float> ends(curves.curves_num());

View File

@@ -1227,7 +1227,7 @@ static int arg_handle_debug_gpu_set(int /*argc*/, const char ** /*argv*/, void *
static const char arg_handle_debug_gpu_compile_shaders_set_doc[] =
"\n"
"\tCompile all staticly defined shaders to test platform compatibility.";
"\tCompile all statically defined shaders to test platform compatibility.";
static int arg_handle_debug_gpu_compile_shaders_set(int /*argc*/,
const char ** /*argv*/,
void * /*data*/)