Cleanup: spelling in comments

This commit is contained in:
Campbell Barton 2023-03-27 12:08:14 +11:00
parent 99d7816d06
commit bb2dc141f2
21 changed files with 75 additions and 56 deletions

View File

@ -309,7 +309,7 @@ class Device {
static uint devices_initialized_mask;
};
/* Device, which is GPU, with some common functionality for GPU backends */
/* Device, which is GPU, with some common functionality for GPU back-ends. */
class GPUDevice : public Device {
protected:
GPUDevice(const DeviceInfo &info_, Stats &stats_, Profiler &profiler_)

View File

@ -715,7 +715,7 @@ GHOST_WindowSDL *GHOST_SystemSDL::findGhostWindow(SDL_Window *sdl_win)
if (sdl_win == nullptr) {
return nullptr;
}
/* It is not entirely safe to do this as the backptr may point
/* It is not entirely safe to do this as the back-pointer may point
* to a window that has recently been removed.
* We should always check the window manager's list of windows
* and only process events on these windows. */

View File

@ -497,7 +497,7 @@ GHOST_WindowX11 *GHOST_SystemX11::findGhostWindow(Window xwind) const
return nullptr;
}
/* It is not entirely safe to do this as the backptr may point
/* It is not entirely safe to do this as the back-pointer may point
* to a window that has recently been removed.
* We should always check the window manager's list of windows
* and only process events on these windows. */

View File

@ -132,22 +132,22 @@ bool CustomData_bmesh_has_free(const struct CustomData *data);
bool CustomData_has_referenced(const struct CustomData *data);
/**
* Copies the "value" (e.g. mloopuv uv or mloopcol colors) from one block to
* Copies the "value" (e.g. `mloopuv` UV or `mloopcol` colors) from one block to
* another, while not overwriting anything else (e.g. flags). probably only
* implemented for mloopuv/mloopcol, for now.
* implemented for `mloopuv/mloopcol`, for now.
*/
void CustomData_data_copy_value(int type, const void *source, void *dest);
void CustomData_data_set_default_value(int type, void *elem);
/**
* Mixes the "value" (e.g. mloopuv uv or mloopcol colors) from one block into
* Mixes the "value" (e.g. `mloopuv` UV or `mloopcol` colors) from one block into
* another, while not overwriting anything else (e.g. flags).
*/
void CustomData_data_mix_value(
int type, const void *source, void *dest, int mixmode, float mixfactor);
/**
* Compares if data1 is equal to data2. type is a valid CustomData type
* Compares if data1 is equal to data2. type is a valid #CustomData type
* enum (e.g. #CD_PROP_FLOAT). the layer type's equal function is used to compare
* the data, if it exists, otherwise #memcmp is used.
*/

View File

@ -501,7 +501,7 @@ struct GPUTexture *BKE_image_create_gpu_texture_from_ibuf(struct Image *image, s
*
* This is provided as a separate function and not implemented as part of the GPU texture retrieval
* functions because the current cache system only allows a single pass, layer, and stereo view to
* be cached, so possible frequent invalidations of the cache can have performance implications,
* be cached, so possible frequent cache invalidation can have performance implications,
* and making invalidation explicit by calling this function will help make that clear and pave the
* way for a more complete cache system in the future.
*/

View File

@ -1015,7 +1015,7 @@ static void layerInterp_mloopcol(const void **sources,
/** \name Callbacks for #OrigSpaceLoop
* \{ */
/* origspace is almost exact copy of mloopuv's, keep in sync */
/* origspace is almost exact copy of #MLoopUV, keep in sync. */
static void layerCopyValue_mloop_origspace(const void *source,
void *dest,
const int /*mixmode*/,

View File

@ -24,7 +24,7 @@ struct ProjCameraInfo *BLI_uvproject_camera_info(struct Object *ob,
float winy);
/**
* Apply UV from uvinfo (camera).
* Apply UV from #ProjCameraInfo (camera).
*/
void BLI_uvproject_from_camera(float target[2], float source[3], struct ProjCameraInfo *uci);

View File

@ -113,7 +113,7 @@ TEST_F(ChangeWorkingDirectoryTest, change_working_directory)
<< "Returned CWD path unexpectedly different than given char buffer.";
#ifdef __APPLE__
/* The name returned by std::tmpnam is fine but the Apple OS method
/* The name returned by `std::tmpnam` is fine but the Apple OS method
* picks the true var folder, not the alias, meaning the below
* comparison always fails unless we prepend with the correct value. */
test_temp_dir = "/private" + test_temp_dir;

View File

@ -91,7 +91,7 @@
* \subsection bm_ops Operators
*
* Operators are an integral part of BMesh. Unlike regular blender operators,
* BMesh operators **bmo's** are designed to be nested (e.g. call other operators).
* BMesh operators (abbreviated to `bmo`) are designed to be nested (e.g. call other operators).
*
* Each operator has a number of input/output "slots"
* which are used to pass settings & data into/out of the operator

View File

@ -269,7 +269,7 @@ static void convolve(float *dst, MemoryBuffer *in1, MemoryBuffer *in2)
data1 = (fREAL *)MEM_callocN(3 * w2 * h2 * sizeof(fREAL), "convolve_fast FHT data1");
data2 = (fREAL *)MEM_callocN(w2 * h2 * sizeof(fREAL), "convolve_fast FHT data2");
/* Normalize convolutor. */
/* Normalize convolution. */
wt[0] = wt[1] = wt[2] = 0.0f;
for (y = 0; y < kernel_height; y++) {
colp = (fRGB *)&kernel_buffer[y * kernel_width * COM_DATA_TYPE_COLOR_CHANNELS];

View File

@ -41,7 +41,7 @@ static inline bool is_removable_relation(const Relation *relation)
/* If the relation connects two different IDs there is a high risk that the removal of the
* relation will make it so visibility flushing is not possible at runtime. This happens with
* relations like the DoF on camera of custom shape on bines: such relation do not lead to an
* relations like the DoF on camera of custom shape on bones: such relation do not lead to an
* actual depsgraph evaluation operation as they are handled on render engine level.
*
* The indirectly linked objects could have some of their components invisible as well, so

View File

@ -85,7 +85,7 @@ void eevee_shader_material_create_info_amend(GPUMaterial *gpumat,
info.vertex_inputs_.clear();
}
else if (do_fragment_attrib_load && !info.vertex_out_interfaces_.is_empty()) {
/* Codegen outputs only one interface. */
/* Code-generation outputs only one interface. */
const StageInterfaceInfo &iface = *info.vertex_out_interfaces_.first();
/* Globals the attrib_load() can write to when it is in the fragment shader. */
attr_load << "struct " << iface.name << " {\n";

View File

@ -3,7 +3,7 @@
#include "gpu_shader_create_info.hh"
/* -------------------------------------------------------------------- */
/** \name Outline Prepass
/** \name Outline Pre-pass
* \{ */
GPU_SHADER_INTERFACE_INFO(overlay_outline_prepass_iface, "interp").flat(Type::UINT, "ob_id");

View File

@ -1097,7 +1097,7 @@ static void extrude_points_from_selected_vertices(const ViewContext *vc,
if (sel_exists) {
float disp_3d[3];
sub_v3_v3v3(disp_3d, location, center);
/* Reimplemenented due to unexpected behavior for extrusion of 2-point spline. */
/* Reimplemented due to unexpected behavior for extrusion of 2-point spline. */
extrude_vertices_from_selected_endpoints(editnurb, nurbs, cu, disp_3d);
}
else {

View File

@ -805,7 +805,7 @@ static bool image_undosys_step_encode(struct bContext *C, struct Main * /*bmain*
us_reference = reinterpret_cast<ImageUndoStep *>(us_reference->step.prev);
}
/* Initialize undo tiles from ptiles (if they exist). */
/* Initialize undo tiles from paint-tiles (if they exist). */
for (PaintTile *ptile : us->paint_tile_map->map.values()) {
if (ptile->valid) {
UndoImageHandle *uh = uhandle_ensure(&us->handles, ptile->image, &ptile->iuser);

View File

@ -2722,7 +2722,8 @@ static void frame_node_prepare_for_draw(bNode &node, Span<bNode *> nodes)
const float has_label = node.label[0] != '\0';
const float label_height = frame_node_label_height(*data);
/* Add an additional 25 % to account for the descenders. This works well in most cases. */
/* Add an additional 25% to account for the glyphs descender.
* This works well in most cases. */
const float margin_top = 0.5f * margin + (has_label ? 1.25f * label_height : 0.5f * margin);
/* Initialize rect from current frame size. */

View File

@ -1166,8 +1166,8 @@ static bool uv_snap_uvs_to_adjacent_unselected(Scene *scene, Object *obedit)
bool changed = false;
const BMUVOffsets offsets = BM_uv_map_get_offsets(em->bm);
/* index every vert that has a selected UV using it, but only once so as to
* get unique indices and to count how much to malloc */
/* Index every vert that has a selected UV using it, but only once so as to
* get unique indices and to count how much to `malloc`. */
BM_ITER_MESH (f, &iter, bm, BM_FACES_OF_MESH) {
if (uvedit_face_visible_test(scene, f)) {
BM_elem_flag_enable(f, BM_ELEM_TAG);

View File

@ -11,7 +11,7 @@
typedef struct TestOutputRawData TestOutputRawData;
#endif
/* NOTE: float3 has differing stride and alignment rules across different GPU backends. If 12 byte
/* NOTE: float3 has differing stride and alignment rules across different GPU back-ends. If 12 byte
* stride and alignment is essential, use `packed_float3` to avoid data read issues. This is
* required in the common use-case where a float3 and an int/float are paired together for optimal
* data transfer. */

View File

@ -17,7 +17,7 @@
#define RUN_UNSUPPORTED false
/* Skip tests that haven't been developed yet due to non standard data types or it needs an
* framebuffer to create the texture. */
* frame-buffer to create the texture. */
#define RUN_SRGB_UNIMPLEMENTED false
#define RUN_NON_STANDARD_UNIMPLEMENTED false
#define RUN_COMPONENT_UNIMPLEMENTED false
@ -168,7 +168,7 @@ static void texture_create_upload_read_pixel()
}
/* -------------------------------------------------------------------- */
/** \name Roundtrip testing GPU_DATA_FLOAT
/** \name Round-trip testing GPU_DATA_FLOAT
* \{ */
static void test_texture_roundtrip__GPU_DATA_FLOAT__GPU_RGBA8()
{
@ -422,7 +422,7 @@ GPU_TEST(texture_roundtrip__GPU_DATA_FLOAT__GPU_DEPTH_COMPONENT16);
/* \} */
/* -------------------------------------------------------------------- */
/** \name Roundtrip testing GPU_DATA_HALF_FLOAT
/** \name Round-trip testing GPU_DATA_HALF_FLOAT
* \{ */
static void test_texture_roundtrip__GPU_DATA_HALF_FLOAT__GPU_RGBA16F()
@ -454,7 +454,7 @@ GPU_TEST(texture_roundtrip__GPU_DATA_HALF_FLOAT__GPU_RGB16F);
/* \} */
/* -------------------------------------------------------------------- */
/** \name Roundtrip testing GPU_DATA_INT
/** \name Round-trip testing GPU_DATA_INT
* \{ */
static void test_texture_roundtrip__GPU_DATA_INT__GPU_RGBA8I()
@ -534,7 +534,7 @@ GPU_TEST(texture_roundtrip__GPU_DATA_INT__GPU_RGB32I);
/* \} */
/* -------------------------------------------------------------------- */
/** \name Roundtrip testing GPU_DATA_UINT
/** \name Round-trip testing GPU_DATA_UINT
* \{ */
static void test_texture_roundtrip__GPU_DATA_UINT__GPU_RGBA8UI()
@ -648,7 +648,7 @@ GPU_TEST(texture_roundtrip__GPU_DATA_UINT__GPU_DEPTH_COMPONENT16);
/* \} */
/* -------------------------------------------------------------------- */
/** \name Roundtrip testing GPU_DATA_UBYTE
/** \name Round-trip testing GPU_DATA_UBYTE
* \{ */
static void test_texture_roundtrip__GPU_DATA_UBYTE__GPU_RGBA8UI()
@ -717,7 +717,7 @@ GPU_TEST(texture_roundtrip__GPU_DATA_UBYTE__GPU_SRGB8);
/* \} */
/* -------------------------------------------------------------------- */
/** \name Roundtrip testing GPU_DATA_UINT_24_8
/** \name Round-trip testing GPU_DATA_UINT_24_8
* \{ */
#if RUN_UNSUPPORTED
@ -737,7 +737,7 @@ GPU_TEST(texture_roundtrip__GPU_DATA_UINT_24_8__GPU_DEPTH24_STENCIL8);
/* \} */
/* -------------------------------------------------------------------- */
/** \name Roundtrip testing GPU_DATA_10_11_11_REV
/** \name Round-trip testing GPU_DATA_10_11_11_REV
* \{ */
static void test_texture_roundtrip__GPU_DATA_10_11_11_REV__GPU_R11F_G11F_B10F()
@ -749,7 +749,7 @@ GPU_TEST(texture_roundtrip__GPU_DATA_10_11_11_REV__GPU_R11F_G11F_B10F);
/* \} */
/* -------------------------------------------------------------------- */
/** \name Roundtrip testing GPU_DATA_2_10_10_10_REV
/** \name Round-trip testing GPU_DATA_2_10_10_10_REV
* \{ */
static void test_texture_roundtrip__GPU_DATA_2_10_10_10_REV__GPU_RGB10_A2()

View File

@ -89,7 +89,7 @@ typedef struct NoiseGpencilModifierData {
char layername[64];
/** Material name. */
char materialname[64] DNA_DEPRECATED;
/** Optional vertexgroup name, MAX_VGROUP_NAME. */
/** Optional vertex-group name, #MAX_VGROUP_NAME. */
char vgname[64];
/** Custom index for passes. */
int pass_index;
@ -175,7 +175,7 @@ typedef struct ThickGpencilModifierData {
char layername[64];
/** Material name. */
char materialname[64] DNA_DEPRECATED;
/** Optional vertexgroup name, MAX_VGROUP_NAME. */
/** Optional vertex-group name, #MAX_VGROUP_NAME. */
char vgname[64];
/** Custom index for passes. */
int pass_index;
@ -308,7 +308,7 @@ typedef struct OpacityGpencilModifierData {
char layername[64];
/** Material name. */
char materialname[64] DNA_DEPRECATED;
/** Optional vertexgroup name, MAX_VGROUP_NAME. */
/** Optional vertex-group name, #MAX_VGROUP_NAME. */
char vgname[64];
/** Custom index for passes. */
int pass_index;
@ -457,11 +457,11 @@ typedef struct BuildGpencilModifierData {
*/
short time_alignment;
/* Speed factor for GP_BUILD_TIMEMODE_DRAWSPEED. */
/** Speed factor for #GP_BUILD_TIMEMODE_DRAWSPEED. */
float speed_fac;
/* Maxmium time gap between strokes for GP_BUILD_TIMEMODE_DRAWSPEED. */
/** Maximum time gap between strokes for #GP_BUILD_TIMEMODE_DRAWSPEED. */
float speed_maxgap;
/* Which time mode should be used. */
/** Which time mode should be used. */
short time_mode;
char _pad[6];
@ -473,7 +473,7 @@ typedef struct BuildGpencilModifierData {
/** Weight fading at the end of the stroke. */
float fade_fac;
/** Target vertexgroup name, MAX_VGROUP_NAME. */
/** Target vertex-group name, #MAX_VGROUP_NAME. */
char target_vgname[64];
/** Fading strength of opacity and thickness */
float fade_opacity_strength;
@ -508,11 +508,11 @@ typedef enum eBuildGpencil_TimeAlignment {
} eBuildGpencil_TimeAlignment;
typedef enum eBuildGpencil_TimeMode {
/* Use a number of frames build. */
/** Use a number of frames build. */
GP_BUILD_TIMEMODE_FRAMES = 0,
/* Use manual percentage to build. */
/** Use manual percentage to build. */
GP_BUILD_TIMEMODE_PERCENTAGE = 1,
/* Use factor of recorded speed to build. */
/** Use factor of recorded speed to build. */
GP_BUILD_TIMEMODE_DRAWSPEED = 2,
} eBuildGpencil_TimeMode;
@ -536,7 +536,7 @@ typedef struct LatticeGpencilModifierData {
char layername[64];
/** Material name. */
char materialname[64] DNA_DEPRECATED;
/** Optional vertexgroup name, MAX_VGROUP_NAME. */
/** Optional vertex-group name, #MAX_VGROUP_NAME. */
char vgname[64];
/** Custom index for passes. */
int pass_index;
@ -685,7 +685,7 @@ typedef struct HookGpencilModifierData {
char layername[64];
/** Material name. */
char materialname[64] DNA_DEPRECATED;
/** Optional vertexgroup name, MAX_VGROUP_NAME. */
/** Optional vertex-group name, #MAX_VGROUP_NAME. */
char vgname[64];
/** Custom index for passes. */
int pass_index;
@ -694,7 +694,7 @@ typedef struct HookGpencilModifierData {
char _pad[4];
int flag;
/** Use enums from WarpGpencilModifier (exact same functionality). */
/** #eHookGpencil_Falloff. */
char falloff_type;
char _pad1[3];
/** Matrix making current transform unmodified. */
@ -790,7 +790,7 @@ typedef struct OffsetGpencilModifierData {
char layername[64];
/** Material name. */
char materialname[64] DNA_DEPRECATED;
/** Optional vertexgroup name, MAX_VGROUP_NAME. */
/** Optional vertex-group name, #MAX_VGROUP_NAME. */
char vgname[64];
/** Custom index for passes. */
int pass_index;
@ -832,7 +832,7 @@ typedef struct SmoothGpencilModifierData {
char layername[64];
/** Material name. */
char materialname[64] DNA_DEPRECATED;
/** Optional vertexgroup name, MAX_VGROUP_NAME. */
/** Optional vertex-group name, #MAX_VGROUP_NAME. */
char vgname[64];
/** Custom index for passes. */
int pass_index;
@ -871,7 +871,7 @@ typedef struct ArmatureGpencilModifierData {
struct Object *object;
/** Stored input of previous modifier, for vertex-group blending. */
float (*vert_coords_prev)[3];
/** MAX_VGROUP_NAME. */
/** #MAX_VGROUP_NAME. */
char vgname[64];
} ArmatureGpencilModifierData;
@ -919,7 +919,7 @@ typedef struct TintGpencilModifierData {
char layername[64];
/** Material name. */
char materialname[64] DNA_DEPRECATED;
/** Optional vertexgroup name, MAX_VGROUP_NAME. */
/** Optional vertex-group name, #MAX_VGROUP_NAME. */
char vgname[64];
/** Custom index for passes. */
int pass_index;
@ -965,7 +965,7 @@ typedef struct TextureGpencilModifierData {
char layername[64];
/** Material name. */
char materialname[64] DNA_DEPRECATED;
/** Optional vertexgroup name, MAX_VGROUP_NAME. */
/** Optional vertex-group name, #MAX_VGROUP_NAME. */
char vgname[64];
/** Custom index for passes. */
int pass_index;
@ -1010,13 +1010,13 @@ typedef enum eTextureGpencil_Mode {
typedef struct WeightProxGpencilModifierData {
GpencilModifierData modifier;
/** Target vertexgroup name, MAX_VGROUP_NAME. */
/** Target vertex-group name, #MAX_VGROUP_NAME. */
char target_vgname[64];
/** Material for filtering. */
struct Material *material;
/** Layer name. */
char layername[64];
/** Optional vertexgroup filter name, MAX_VGROUP_NAME. */
/** Optional vertex-group filter name, #MAX_VGROUP_NAME. */
char vgname[64];
/** Custom index for passes. */
int pass_index;
@ -1036,13 +1036,13 @@ typedef struct WeightProxGpencilModifierData {
typedef struct WeightAngleGpencilModifierData {
GpencilModifierData modifier;
/** Target vertexgroup name, MAX_VGROUP_NAME. */
/** Target vertex-group name, #MAX_VGROUP_NAME. */
char target_vgname[64];
/** Material for filtering. */
struct Material *material;
/** Layer name. */
char layername[64];
/** Optional vertexgroup filter name, MAX_VGROUP_NAME. */
/** Optional vertex-group filter name, #MAX_VGROUP_NAME. */
char vgname[64];
/** Custom index for passes. */
int pass_index;
@ -1209,7 +1209,7 @@ typedef struct LineartGpencilModifierData {
char _pad2[6];
struct LineartCache *cache;
/* Keep a pointer to the render buffer so we can call destroy from ModifierData. */
/** Keep a pointer to the render buffer so we can call destroy from #ModifierData. */
struct LineartData *la_data_ptr;
} LineartGpencilModifierData;
@ -1224,7 +1224,7 @@ typedef struct ShrinkwrapGpencilModifierData {
struct Material *material;
/** Layer name. */
char layername[64];
/** Optional vertexgroup filter name, MAX_VGROUP_NAME. */
/** Optional vertex-group filter name, #MAX_VGROUP_NAME. */
char vgname[64];
/** Custom index for passes. */
int pass_index;
@ -1274,7 +1274,7 @@ typedef struct EnvelopeGpencilModifierData {
struct Material *material;
/** Layer name. */
char layername[64];
/** Optional vertexgroup name, MAX_VGROUP_NAME. */
/** Optional vertex-group name, #MAX_VGROUP_NAME. */
char vgname[64];
/** Custom index for passes. */
int pass_index;

View File

@ -100,6 +100,7 @@ dict_custom = {
"dialogs",
"digitizers",
"dihedral",
"directionality",
"discoverability",
"discretization",
"discretized",
@ -144,6 +145,7 @@ dict_custom = {
"interdependencies",
"interferences",
"interocular",
"interpolator",
"invariant",
"invariants",
"invisibilities",
@ -157,6 +159,8 @@ dict_custom = {
"linearizing",
"linkable",
"lockless",
"looper",
"loopers",
"losslessly",
"luminances",
"mappable",
@ -174,6 +178,8 @@ dict_custom = {
"occludee",
"occluder",
"occluders",
"octant",
"octants",
"optionals",
"orthogonalize",
"orthogonally",
@ -186,6 +192,7 @@ dict_custom = {
"parallelize",
"parallelizing",
"parameterization",
"parameterless",
"parametrization",
"parentless",
"passepartout",
@ -247,6 +254,8 @@ dict_custom = {
"redistributions",
"registerable",
"reimplement",
"reimplemented",
"reimplementing",
"remappable",
"remapper",
"remappings",
@ -258,9 +267,14 @@ dict_custom = {
"reparameterization",
"reparametization",
"representable",
"reprojected",
"reprojecting",
"reprojection",
"reprojections",
"repurpose",
"respecialized",
"resynced",
"resyncing",
"retiming",
"reusability",
"saveable",
@ -325,6 +339,7 @@ dict_custom = {
"undistored",
"undistorted",
"undistorting",
"unduplicated",
"uneditable",
"unflagged",
"unflip",
@ -368,6 +383,7 @@ dict_custom = {
"unpoision",
"unproject",
"unquantifiable",
"unreferenced",
"unregister",
"unregistering",
"unregisters",
@ -429,6 +445,7 @@ dict_custom = {
"addon",
"addons",
"autocomplete",
"codegen",
"colospace",
"datablock",
"datablocks",
@ -451,6 +468,7 @@ dict_custom = {
"config", # configuration.
"coord",
"coords",
"ctrl", # control (modifier key).
"iter", # iteration.
"multi",
"numpad", # numeric-pad.