Cleanup: spelling in comments

This commit is contained in:
Campbell Barton 2023-07-05 13:58:04 +10:00
parent 39cafb43d3
commit 785bd13b9a
46 changed files with 112 additions and 97 deletions

View File

@ -128,7 +128,7 @@ bool device_memory::is_resident(Device *sub_device) const
return device->is_resident(device_pointer, sub_device);
}
/* Device Sub Ptr */
/* Device Sub `ptr`. */
device_sub_ptr::device_sub_ptr(device_memory &mem, size_t offset, size_t size) : device(mem.device)
{

View File

@ -72,8 +72,8 @@ ccl_device_forceinline Spectrum bsdf_ashikhmin_shirley_eval(ccl_private const Sh
/* pump from original paper
* (first derivative disc., but cancels the HdotI in the pdf nicely) */
float pump = 1.0f / fmaxf(1e-6f, (HdotI * fmaxf(NdotI, NdotO)));
/* pump from d-brdf paper */
/*float pump = 1.0f / fmaxf(1e-4f, ((NdotI + NdotO) * (NdotI * NdotO))); */
/* `pump` from D-BRDF paper. */
// float pump = 1.0f / fmaxf(1e-4f, ((NdotI + NdotO) * (NdotI * NdotO)));
float n_x = bsdf_ashikhmin_shirley_roughness_to_exponent(bsdf->alpha_x);
float n_y = bsdf_ashikhmin_shirley_roughness_to_exponent(bsdf->alpha_y);

View File

@ -120,8 +120,8 @@ ccl_device_forceinline float3 microfacet_beckmann_sample_vndf(const float3 wi,
/* Sample slope X.
*
* Compute a coarse approximation using the approximation:
* exp(-ierf(x)^2) ~= 1 - x * x
* solve y = 1 + b + K * (1 - b * b)
* `exp(-ierf(x)^2) ~= 1 - x * x`
* `solve y = 1 + b + K * (1 - b * b)`
*/
const float K = tan_theta_i * SQRT_PI_INV;
const float y_approx = rand.x * (1.0f + erf_a + K * (1 - erf_a * erf_a));

View File

@ -206,7 +206,7 @@ ccl_device_forceinline float3 primitive_uv(KernelGlobals kg, ccl_private const S
return make_float3(uv.x, uv.y, 1.0f);
}
/* Ptex coordinates */
/* PTEX coordinates. */
ccl_device bool primitive_ptex(KernelGlobals kg,
ccl_private ShaderData *sd,

View File

@ -81,7 +81,7 @@ static GHOST_TKey convertKey(int rawCode, unichar recvChar, UInt16 keyAction)
{
// printf("\nrecvchar %c 0x%x",recvChar,recvChar);
switch (rawCode) {
/* Physical key-codes: (not used due to map changes in int'l keyboards). */
/* Physical key-codes: (not used due to map changes in international keyboards). */
#if 0
case kVK_ANSI_A: return GHOST_kKeyA;
case kVK_ANSI_B: return GHOST_kKeyB;
@ -110,7 +110,7 @@ static GHOST_TKey convertKey(int rawCode, unichar recvChar, UInt16 keyAction)
case kVK_ANSI_Y: return GHOST_kKeyY;
case kVK_ANSI_Z: return GHOST_kKeyZ;
#endif
/* Numbers keys: mapped to handle some int'l keyboard (e.g. French). */
/* Numbers keys: mapped to handle some international keyboard (e.g. French). */
case kVK_ANSI_1:
return GHOST_kKey1;
case kVK_ANSI_2:
@ -258,7 +258,7 @@ static GHOST_TKey convertKey(int rawCode, unichar recvChar, UInt16 keyAction)
return GHOST_kKeyUnknown;
default: {
/* Alphanumerical or punctuation key that is remappable in int'l keyboards. */
/* Alphanumerical or punctuation key that is remappable in international keyboards. */
if ((recvChar >= 'A') && (recvChar <= 'Z')) {
return (GHOST_TKey)(recvChar - 'A' + GHOST_kKeyA);
}
@ -275,7 +275,7 @@ static GHOST_TKey convertKey(int rawCode, unichar recvChar, UInt16 keyAction)
kTISPropertyUnicodeKeyLayoutData);
CFRelease(kbdTISHandle);
/* Get actual character value of the "remappable" keys in int'l keyboards,
/* Get actual character value of the "remappable" keys in international keyboards,
* if keyboard layout is not correctly reported (e.g. some non Apple keyboards in Tiger),
* then fallback on using the received #charactersIgnoringModifiers. */
if (uchrHandle) {

View File

@ -16,25 +16,28 @@ struct Mesh;
struct Subdiv;
struct SubdivToMeshSettings {
/* Resolution at which regular ptex (created for quad polygon) are being
/**
* Resolution at which regular PTEX (created for quad polygon) are being
* evaluated. This defines how many vertices final mesh will have: every
* regular ptex has resolution^2 vertices. Special (irregular, or ptex
* regular PTEX has resolution^2 vertices. Special (irregular, or PTEX
* created for a corner of non-quad polygon) will have resolution of
* `resolution - 1`.
*/
int resolution;
/* When true, only edges emitted from coarse ones will be displayed. */
/** When true, only edges emitted from coarse ones will be displayed. */
bool use_optimal_display;
};
/* Create real hi-res mesh from subdivision, all geometry is "real". */
/** Create real hi-res mesh from subdivision, all geometry is "real". */
Mesh *BKE_subdiv_to_mesh(Subdiv *subdiv,
const SubdivToMeshSettings *settings,
const Mesh *coarse_mesh);
/* Interpolate a position along the `coarse_edge` at the relative `u` coordinate. If `is_simple` is
* false, this will perform a B-Spline interpolation using the edge neighbors, otherwise a linear
* interpolation will be done base on the edge vertices. */
/**
* Interpolate a position along the `coarse_edge` at the relative `u` coordinate.
* If `is_simple` is false, this will perform a B-Spline interpolation using the edge neighbors,
* otherwise a linear interpolation will be done base on the edge vertices.
*/
void BKE_subdiv_mesh_interpolate_position_on_edge(const float (*coarse_positions)[3],
const blender::int2 *coarse_edges,
blender::GroupedSpan<int> vert_to_edge_map,

View File

@ -1421,7 +1421,7 @@ static void mesh_normals_loop_custom_set(Span<float3> positions,
{
/* We *may* make that poor #bke::mesh::normals_calc_loop() even more complex by making it
* handling that feature too, would probably be more efficient in absolute. However, this
* function *is not* performance-critical, since it is mostly expected to be called by io add-ons
* function *is not* performance-critical, since it is mostly expected to be called by IO add-ons
* when importing custom normals, and modifier (and perhaps from some editing tools later?). So
* better to keep some simplicity here, and just call #bke::mesh::normals_calc_loop() twice! */
CornerNormalSpaceArray lnors_spacearr;

View File

@ -2732,12 +2732,10 @@ void BKE_pbvh_raycast_project_ray_root(
* This happens when initializing rays by the viewport clipping
* bounds, which are then divided by the object's scale.
* So if the clip end if 10000 and we divide by 0.00001 we
* get a really large number that we cannd add 1e-3 (0.001) to.
* get a really large number that we canned add 1e-3 (0.001) to.
*
* To solve this, we compute a margin using the next possible floating
* point value after ray start.
*/
* point value after ray start. */
float epsilon = std::nextafterf(rootmin_start, rootmin_start + 1.0f) - rootmin_start;
rootmin_end = rootmin_start + epsilon * 500.0f;
}

View File

@ -264,7 +264,7 @@ static void vertex_interpolation_from_corner(const SubdivMeshContext *ctx,
const CustomData *vertex_data = &ctx->coarse_mesh->vdata;
LoopsOfPtex loops_of_ptex;
loops_of_ptex_get(&loops_of_ptex, coarse_poly, corner);
/* Ptex face corner corresponds to a poly loop with same index. */
/* PTEX face corner corresponds to a poly loop with same index. */
CustomData_copy_data(vertex_data,
&vertex_interpolation->vertex_data_storage,
ctx->coarse_corner_verts[coarse_poly.start() + corner],
@ -394,7 +394,7 @@ static void loop_interpolation_from_corner(const SubdivMeshContext *ctx,
const CustomData *loop_data = &ctx->coarse_mesh->ldata;
LoopsOfPtex loops_of_ptex;
loops_of_ptex_get(&loops_of_ptex, coarse_poly, corner);
/* Ptex face corner corresponds to a poly loop with same index. */
/* PTEX face corner corresponds to a poly loop with same index. */
CustomData_free_elem(&loop_interpolation->loop_data_storage, 0, 1);
CustomData_copy_data(
loop_data, &loop_interpolation->loop_data_storage, coarse_poly.start() + corner, 0, 1);

View File

@ -146,7 +146,7 @@ inline void gather(const VArray<T> &src,
}
/**
* Count the number of occurences of each index.
* Count the number of occurrences of each index.
* \param indices: The indices to count.
* \param counts: The number of occurrences of each index. Typically initialized to zero.
* Must be large enough to contain the maximum index.

View File

@ -470,7 +470,7 @@ static void bchunk_list_ensure_min_size_last(const BArrayInfo *info,
{
BChunkRef *cref = chunk_list->chunk_refs.last;
if (cref && cref->prev) {
/* Both are decref'd after use (end of this block) */
/* Both are decrefed after use (end of this block). */
BChunk *chunk_curr = cref->link;
BChunk *chunk_prev = cref->prev->link;

View File

@ -96,7 +96,7 @@ MALWAYS_INLINE __m128 _bli_math_rsqrt(__m128 in)
return r;
}
/* Calculate powf(x, 1.0f / 2.4) */
/* Calculate `powf(x, 1.0f / 2.4)`. */
MALWAYS_INLINE __m128 _bli_math_fastpow512(const __m128 arg)
{
/* 5/12 is too small, so compute the 4th root of 20/12 instead.

View File

@ -567,7 +567,7 @@ void BLI_ewa_imp2radangle(
*b = sqrtf(F2 / d);
*ecc = *a / *b;
}
/* incr theta by 0.5*pi (angle of major axis) */
/* Increase theta by `0.5 * pi` (angle of major axis). */
*th = 0.5f * (atan2f(B, AmC) + (float)M_PI);
}
}

View File

@ -2216,34 +2216,34 @@ void vec_apply_track(float vec[3], short axis)
switch (axis) {
case 0: /* pos-x */
/* vec[0] = 0.0; */
// vec[0] = 0.0;
vec[1] = tvec[2];
vec[2] = -tvec[1];
break;
case 1: /* pos-y */
/* vec[0] = tvec[0]; */
/* vec[1] = 0.0; */
/* vec[2] = tvec[2]; */
// vec[0] = tvec[0];
// vec[1] = 0.0;
// vec[2] = tvec[2];
break;
case 2: /* pos-z */
/* vec[0] = tvec[0]; */
/* vec[1] = tvec[1]; */
/* vec[2] = 0.0; */
// vec[0] = tvec[0];
// vec[1] = tvec[1];
// vec[2] = 0.0;
break;
case 3: /* neg-x */
/* vec[0] = 0.0; */
// vec[0] = 0.0;
vec[1] = tvec[2];
vec[2] = -tvec[1];
break;
case 4: /* neg-y */
vec[0] = -tvec[2];
/* vec[1] = 0.0; */
// vec[1] = 0.0;
vec[2] = tvec[0];
break;
case 5: /* neg-z */
vec[0] = -tvec[0];
vec[1] = -tvec[1];
/* vec[2] = 0.0; */
// vec[2] = 0.0;
break;
}
}

View File

@ -391,7 +391,7 @@ static void do_versions_nodetree_image_layer_2_64_5(bNodeTree *ntree)
LISTBASE_FOREACH (bNodeSocket *, sock, &node->outputs) {
NodeImageLayer *output = MEM_cnew<NodeImageLayer>("node image layer");
/* take pass index both from current storage ptr (actually an int) */
/* Take pass index both from current storage pointer (actually an int). */
output->pass_index = POINTER_AS_INT(sock->storage);
/* replace socket data pointer */
@ -678,7 +678,7 @@ LISTBASE_FOREACH (bNodeTree *, ntree, &bmain->nodetrees) {
}
{
/* support old particle dupliobject rotation settings */
/* Support old particle dupli-object rotation settings. */
LISTBASE_FOREACH (ParticleSettings *, part, &bmain->particles) {
if (ELEM(part->ren_as, PART_DRAW_OB, PART_DRAW_GR)) {
part->draw |= PART_DRAW_ROTATE_OB;
@ -1330,7 +1330,7 @@ if (!MAIN_VERSION_ATLEAST(bmain, 263, 14)) {
}
FOREACH_NODETREE_END;
/* keep compatibility for dupliobject particle size */
/* Keep compatibility for dupli-object particle size. */
LISTBASE_FOREACH (ParticleSettings *, part, &bmain->particles) {
if (ELEM(part->ren_as, PART_DRAW_OB, PART_DRAW_GR)) {
if ((part->draw & PART_DRAW_ROTATE_OB) == 0) {
@ -1810,11 +1810,15 @@ if (bmain->versionfile < 267) {
}
}
/* TIP: to initialize new variables added, use the new function
* DNA_struct_elem_find(fd->filesdna, "structname", "typename", "varname")
* example:
* if (!DNA_struct_elem_find(fd->filesdna, "UserDef", "short", "image_gpubuffer_limit"))
/**
* TIP: to initialize new variables added, use the new function:
* `DNA_struct_elem_find(fd->filesdna, "structname", "typename", "varname")`, example:
*
* \code{.cc}
* if (!DNA_struct_elem_find(fd->filesdna, "UserDef", "short", "image_gpubuffer_limit")) {
* user->image_gpubuffer_limit = 10;
* }
* \endcode
*/
}

View File

@ -21,7 +21,7 @@ void ReflectionProbeModule::init()
max_mipmap_levels);
GPU_texture_mipmap_mode(probes_tx_, true, true);
/* Cubemap is half of the resolution of the octahedral map. */
/* Cube-map is half of the resolution of the octahedral map. */
cubemap_tx_.ensure_cube(
GPU_RGBA16F, max_resolution_ / 2, GPU_TEXTURE_USAGE_ATTACHMENT, nullptr, 1);
GPU_texture_mipmap_mode(cubemap_tx_, false, true);

View File

@ -73,7 +73,7 @@ class ReflectionProbeModule {
void remap_to_octahedral_projection();
/* Capture View requires access to the cubemaps texture for frame-buffer configuration. */
/* Capture View requires access to the cube-maps texture for frame-buffer configuration. */
friend class CaptureView;
};

View File

@ -145,7 +145,7 @@ class MainView {
/* -------------------------------------------------------------------- */
/** \name Capture View
*
* View for capturing cubemap renders outside a ShadingView.
* View for capturing cube-map renders outside a ShadingView.
* \{ */
class CaptureView {

View File

@ -12,7 +12,7 @@
extern "C" {
#endif
#define MAX_LAYER_NAME_CT 4 /* u0123456789, u, au, a0123456789 */
#define MAX_LAYER_NAME_CT 4 /* `u0123456789, u, au, a0123456789`. */
#define MAX_LAYER_NAME_LEN (GPU_MAX_SAFE_ATTR_NAME + 2)
#define MAX_THICKRES 2 /* see eHairType */
#define MAX_HAIR_SUBDIV 4 /* see hair_subdiv rna */

View File

@ -2577,7 +2577,9 @@ static uint dupliobject_instancer_hash(const void *ptr)
return hash;
}
/* Compare function that matches dupliobject_hash */
/**
* Compare function that matches #dupliobject_hash.
*/
static bool dupliobject_cmp(const void *a_, const void *b_)
{
const DupliObject *a = static_cast<const DupliObject *>(a_);

View File

@ -130,7 +130,7 @@ void INFO_OT_report_replay(wmOperatorType *ot)
ot->exec = report_replay_exec;
/* flags */
/* ot->flag = OPTYPE_REGISTER; */
// ot->flag = OPTYPE_REGISTER;
/* properties */
}
@ -186,7 +186,7 @@ void INFO_OT_select_pick(wmOperatorType *ot)
ot->exec = select_report_pick_exec;
/* flags */
/* ot->flag = OPTYPE_REGISTER; */
// ot->flag = OPTYPE_REGISTER;
/* properties */
PropertyRNA *prop;
@ -307,7 +307,7 @@ void INFO_OT_select_box(wmOperatorType *ot)
ot->poll = ED_operator_info_active;
/* flags */
/* ot->flag = OPTYPE_REGISTER; */
// ot->flag = OPTYPE_REGISTER;
/* properties */
WM_operator_properties_gesture_box(ot);

View File

@ -1075,7 +1075,7 @@ int transformEvent(TransInfo *t, const wmEvent *event)
}
}
/* Need to reinit after mode change. */
/* Need to reinitialize after mode change. */
initSnapping(t, NULL);
applyMouseInput(t, &t->mouse, t->mval, t->values);
t->redraw |= TREDRAW_HARD;

View File

@ -330,7 +330,7 @@ eRedrawFlag handleSnapping(TransInfo *t, const wmEvent *event)
#if 0 /* XXX need a proper selector for all snap mode */
if (BIF_snappingSupported(t->obedit) && (event->type == EVT_TABKEY) &&
(event->modifier & KM_SHIFT)) {
/* toggle snap and reinit */
/* Toggle snap and reinitialize. */
t->settings->snap_flag ^= SCE_SNAP;
initSnapping(t, nullptr);
status = TREDRAW_HARD;

View File

@ -34,7 +34,7 @@ struct SnapCache_EditMesh : public SnapObjectContext::SnapCache {
struct BMEditMesh *em;
/** Default callbacks to BVH nearest and ray-cast used only for tris. */
/** Default callbacks to BVH nearest and ray-cast used only for triangles. */
BVHTree_NearestPointCallback nearest_callback;
BVHTree_RayCastCallback raycast_callback;

View File

@ -588,7 +588,7 @@ inline MTLPixelFormat mtl_format_get_writeable_view_format(MTLPixelFormat format
* manual data upload */
return MTLPixelFormatInvalid;
case MTLPixelFormatDepth24Unorm_Stencil8:
/* No direct format, but we'll just mirror the bytes -- Uint
/* No direct format, but we'll just mirror the bytes -- `Uint`
* should ensure bytes are not re-normalized or manipulated */
/* return MTLPixelFormatR32Uint; */
return MTLPixelFormatInvalid;

View File

@ -68,7 +68,7 @@ typedef struct LogImageFile {
float referenceWhite;
float gamma;
/* io stuff */
/* IO stuff. */
FILE *file;
unsigned char *memBuffer;
uintptr_t memBufferSize;

View File

@ -37,7 +37,7 @@ void InstanceWriter::add_material_bindings(COLLADASW::BindMaterial &bind_materia
COLLADASW::InstanceMaterial im(ostr.str(),
COLLADASW::URI(COLLADABU::Utils::EMPTY_STRING, matid));
// create <bind_vertex_input> for each uv map
/* Create <bind_vertex_input> for each uv map. */
Mesh *me = (Mesh *)ob->data;
int num_layers = CustomData_number_of_layers(&me->ldata, CD_PROP_FLOAT2);

View File

@ -1111,24 +1111,26 @@ typedef enum eChildOf_Flags {
CHILDOF_SET_INVERSE = (1 << 9),
} eChildOf_Flags;
/* Pivot Constraint */
/* Restrictions for Pivot Constraint axis to consider for enabling constraint */
/** Pivot Constraint
*
* Restrictions for Pivot Constraint axis to consider for enabling constraint.
*/
typedef enum ePivotConstraint_Axis {
/* do not consider this activity-clamping */
/** Do not consider this activity-clamping. */
PIVOTCON_AXIS_NONE = -1,
/* consider -ve x-axis rotations */
/** Consider -VE X-axis rotations. */
PIVOTCON_AXIS_X_NEG = 0,
/* consider -ve y-axis rotations */
/** Consider -VE Y-axis rotations. */
PIVOTCON_AXIS_Y_NEG = 1,
/* consider -ve z-axis rotations */
/** Consider -VE Z-axis rotations. */
PIVOTCON_AXIS_Z_NEG = 2,
/* consider +ve x-axis rotations */
/** Consider +VE X-axis rotations. */
PIVOTCON_AXIS_X = 3,
/* consider +ve y-axis rotations */
/** Consider +VE Y-axis rotations. */
PIVOTCON_AXIS_Y = 4,
/* consider +ve z-axis rotations */
/** Consider +VE Z-axis rotations. */
PIVOTCON_AXIS_Z = 5,
} ePivotConstraint_Axis;

View File

@ -69,7 +69,7 @@ typedef struct FluidsimSettings {
char surfdataPath[1024];
/* store start coords of axis aligned bounding box together with size */
/* values are inited during derived mesh display */
/* values are initialized during derived mesh display. */
float bbStart[3], bbSize[3];
/* animated params */

View File

@ -703,7 +703,7 @@ enum {
RGN_FLAG_HIDDEN = (1 << 0),
RGN_FLAG_TOO_SMALL = (1 << 1),
/**
* Force delayed reinit of region size data, so that region size is calculated
* Force delayed re-initialization of region size data, so that region size is calculated
* just big enough to show all its content (if enough space is available).
* Note that only ED_region_header supports this right now.
*/

View File

@ -168,12 +168,14 @@ static void rna_AnimData_tweakmode_set(PointerRNA *ptr, const bool value)
}
}
/* This is used to avoid the check for NLA tracks when enabling tweak
* mode while loading overrides. This is necessary because the normal
/**
* This is used to avoid the check for NLA tracks when enabling tweak
* mode while loading overrides. This is necessary because the normal
* RNA tweak-mode setter refuses to enable tweak mode if there are no
* NLA tracks since that's normally an invalid state... but the
* overriden NLA tracks are only added *after* setting the tweak mode
* override. */
* overridden NLA tracks are only added *after* setting the tweak mode
* override.
*/
bool rna_AnimData_tweakmode_override_apply(Main * /*bmain*/,
PointerRNA *ptr_dst,
PointerRNA *ptr_src,

View File

@ -308,7 +308,7 @@ static void rna_def_canvas_surface(BlenderRNA *brna)
/* Surface format */
static const EnumPropertyItem prop_dynamicpaint_surface_format[] = {
/*{MOD_DPAINT_SURFACE_F_PTEX, "PTEX", ICON_TEXTURE_SHADED, "Ptex", ""}, */
// {MOD_DPAINT_SURFACE_F_PTEX, "PTEX", ICON_TEXTURE_SHADED, "Ptex", ""},
{MOD_DPAINT_SURFACE_F_VERTEX, "VERTEX", ICON_OUTLINER_DATA_MESH, "Vertex", ""},
{MOD_DPAINT_SURFACE_F_IMAGESEQ, "IMAGE", ICON_FILE_IMAGE, "Image Sequence", ""},
{0, nullptr, 0, nullptr, nullptr},

View File

@ -231,7 +231,7 @@ static void rna_Image_gl_free(Image *image)
{
BKE_image_free_gputextures(image);
/* remove the nocollect flag, image is available for garbage collection again */
/* Remove the no-collect flag, image is available for garbage collection again. */
image->flag &= ~IMA_NOCOLLECT;
}

View File

@ -658,7 +658,7 @@ static void rna_def_strip_fcurves(BlenderRNA *brna, PropertyRNA *cprop)
RNA_def_struct_sdna(srna, "NlaStrip");
RNA_def_struct_ui_text(srna, "NLA-Strip F-Curves", "Collection of NLA strip F-Curves");
/* Strip.fcurves.find(...) */
/* `Strip.fcurves.find(...)`. */
func = RNA_def_function(srna, "find", "rna_NlaStrip_fcurve_find");
RNA_def_function_ui_description(
func,
@ -679,7 +679,7 @@ static void rna_def_nlastrip(BlenderRNA *brna)
StructRNA *srna;
PropertyRNA *prop;
/* enum defs */
/* Enum definitions. */
static const EnumPropertyItem prop_type_items[] = {
{NLASTRIP_TYPE_CLIP, "CLIP", 0, "Action Clip", "NLA Strip references some Action"},
{NLASTRIP_TYPE_TRANSITION,
@ -1106,4 +1106,4 @@ void RNA_def_nla(BlenderRNA *brna)
rna_def_nlastrip(brna);
}
#endif
#endif

View File

@ -380,7 +380,7 @@ static void rna_Particle_uv_on_emitter(ParticleData *particle,
return;
}
/* get uvco & mcol */
/* Get UV-coordinate & color. */
int num = particle->num_dmcache;
int from = modifier->psys->part->from;
@ -396,7 +396,7 @@ static void rna_Particle_uv_on_emitter(ParticleData *particle,
}
}
/* get uvco */
/* Get UV-coordinate. */
if (r_uv && ELEM(from, PART_FROM_FACE, PART_FROM_VOLUME) &&
!ELEM(num, DMCACHE_NOTFOUND, DMCACHE_ISCHILD))
{

View File

@ -475,7 +475,7 @@ static void rna_def_view2d_api(StructRNA *srna)
static void rna_def_view2d(BlenderRNA *brna)
{
StructRNA *srna;
/* PropertyRNA *prop; */
// PropertyRNA *prop;
srna = RNA_def_struct(brna, "View2D", nullptr);
RNA_def_struct_ui_text(srna, "View2D", "Scroll and zoom for a 2D region");

View File

@ -1109,8 +1109,8 @@ void RNA_api_macro(StructRNA *srna)
void RNA_api_keyconfig(StructRNA * /*srna*/)
{
/* FunctionRNA *func; */
/* PropertyRNA *parm; */
// FunctionRNA *func;
// PropertyRNA *parm;
}
void RNA_api_keymap(StructRNA *srna)

View File

@ -417,7 +417,7 @@ static void cuboid_do(CastModifierData *cmd,
coord = 1;
}
if (d[2] > dmax) {
/* dmax = d[2]; */ /* commented, we don't need it */
// dmax = d[2]; /* commented, we don't need it */
coord = 2;
}

View File

@ -63,7 +63,7 @@ static void node_composit_init_keying(bNodeTree * /*ntree*/, bNode *node)
static void node_composit_buts_keying(uiLayout *layout, bContext * /*C*/, PointerRNA *ptr)
{
/* bNode *node = (bNode*)ptr->data; */ /* UNUSED */
// bNode *node = (bNode*)ptr->data; /* UNUSED */
uiItemR(layout, ptr, "blur_pre", UI_ITEM_R_SPLIT_EMPTY_NAME, nullptr, ICON_NONE);
uiItemR(layout, ptr, "screen_balance", UI_ITEM_R_SPLIT_EMPTY_NAME, nullptr, ICON_NONE);

View File

@ -32,7 +32,7 @@
#endif /* !WITH_PYTHON_SAFETY */
/* sanity checks on above defs */
/* Sanity checks on above defines. */
#if defined(USE_PYRNA_INVALIDATE_WEAKREF) && !defined(USE_WEAKREFS)
# define USE_WEAKREFS
#endif

View File

@ -1109,7 +1109,7 @@ static void create_ao_raytree(MultiresBakeRender *bkr, MAOBakeData *ao_data)
grid_data = hidm->getGridData(hidm);
hidm->getGridKey(hidm, &key);
/* face_side = (grid_size << 1) - 1; */ /* UNUSED */
// face_side = (grid_size << 1) - 1; /* UNUSED */
faces_num = grids_num * (grid_size - 1) * (grid_size - 1);
raytree = ao_data->raytree = RE_rayobject_create(

View File

@ -1786,7 +1786,7 @@ static bool render_init_from_main(Render *re,
return false;
}
/* initstate makes new result, have to send changed tags around */
/* Init-state makes new result, have to send changed tags around. */
ntreeCompositTagRender(re->scene);
re->display_init(re->dih, re->result);

View File

@ -844,8 +844,8 @@ static void feline_eval(TexResult *texr, ImBuf *ibuf, float fx, float fy, afdata
float dv = maxn ? sinf(AFD->theta) * ll : 0.0f;
// const float D = -0.5f*(du*du + dv*dv) / (AFD->majrad*AFD->majrad);
const float D = (EWA_MAXIDX + 1) * 0.25f * (du * du + dv * dv) / (AFD->majrad * AFD->majrad);
float d; /* TXF alpha: cw = 0.0f; */
int n; /* TXF alpha: clip = 0; */
float d; /* TXF alpha: `cw = 0.0f`. */
int n; /* TXF alpha: `clip = 0`. */
/* Have to use same scaling for du/dv here as for Ux/Vx/Uy/Vy (*after* D is calculated.) */
du *= AFD->dusc;
dv *= AFD->dvsc;

View File

@ -805,7 +805,7 @@ static int cg_filtered(lfVector *ldV, fmatrix3x3 *lA, lfVector *lB, lfVector *z,
conjgrad_loopcount++;
}
/* conjgrad_lasterror = s; */ /* UNUSED */
// conjgrad_lasterror = s; /* UNUSED */
del_lfvector(q);
del_lfvector(d);

View File

@ -1465,7 +1465,7 @@ static void playanim_window_open(const char *title, int posx, int posy, int size
static void playanim_window_zoom(PlayState *ps, const float zoom_offset)
{
int sizex, sizey;
/* int ofsx, ofsy; */ /* UNUSED */
// int ofsx, ofsy; /* UNUSED */
if (ps->zoom + zoom_offset > 0.0f) {
ps->zoom += zoom_offset;
@ -1473,12 +1473,12 @@ static void playanim_window_zoom(PlayState *ps, const float zoom_offset)
// playanim_window_get_position(&ofsx, &ofsy);
playanim_window_get_size(&sizex, &sizey);
/* ofsx += sizex / 2; */ /* UNUSED */
/* ofsy += sizey / 2; */ /* UNUSED */
// ofsx += sizex / 2; /* UNUSED */
// ofsy += sizey / 2; /* UNUSED */
sizex = ps->zoom * ps->ibufx;
sizey = ps->zoom * ps->ibufy;
/* ofsx -= sizex / 2; */ /* UNUSED */
/* ofsy -= sizey / 2; */ /* UNUSED */
// ofsx -= sizex / 2; /* UNUSED */
// ofsy -= sizey / 2; /* UNUSED */
// window_set_position(g_WS.ghost_window, sizex, sizey);
GHOST_SetClientSize(g_WS.ghost_window, sizex, sizey);
}

View File

@ -303,6 +303,7 @@ dict_custom = {
"skippable",
"sortable",
"stepsize",
"stepwise",
"stitchable",
"subclass",
"subclasses",
@ -489,6 +490,7 @@ dict_custom = {
"coord",
"coords",
"ctrl", # control (modifier key).
"ie",
"init",
"iter", # iteration.
"multi",
@ -516,6 +518,7 @@ dict_custom = {
"decimator",
"decref",
"decrefed",
"decrefing",
"diff",
"diffs",
"endian",
@ -528,6 +531,7 @@ dict_custom = {
"http",
"incref",
"increfed",
"increfing",
"intelisense",
"jitter",
"jittered",