Cleanup: spelling in comments, correct outdated comments

This commit is contained in:
Campbell Barton 2021-06-03 10:46:16 +10:00
parent 2a868d277e
commit 17f72be3cb
6 changed files with 16 additions and 10 deletions

View File

@ -3294,7 +3294,11 @@ static void node_texture_set_butfunc(bNodeType *ntype)
}
}
/* ****** init draw callbacks for all tree types, only called in usiblender.c, once ************ */
/* -------------------------------------------------------------------- */
/** \name Init Draw Callbacks For All Tree Types
*
* Only called on node initialization, once.
* \{ */
static void node_property_update_default(Main *bmain, Scene *UNUSED(scene), PointerRNA *ptr)
{
@ -3366,6 +3370,8 @@ static void node_socket_undefined_interface_draw_color(bContext *UNUSED(C),
r_color[3] = 1.0f;
}
/** \} */
void ED_node_init_butfuncs(void)
{
/* Fallback types for undefined tree, nodes, sockets

View File

@ -1472,7 +1472,7 @@ int node_render_changed_exec(bContext *C, wmOperator *UNUSED(op))
RNA_string_set(&op_ptr, "layer", view_layer->name);
RNA_string_set(&op_ptr, "scene", sce->id.name + 2);
/* to keep keypositions */
/* To keep keyframe positions. */
sce->r.scemode |= R_NO_FRAME_UPDATE;
WM_operator_name_call(C, "RENDER_OT_render", WM_OP_INVOKE_DEFAULT, &op_ptr);

View File

@ -219,7 +219,7 @@ static void animation_basepath_change_free(AnimationBasePathChange *basepath_cha
/* returns 1 if its OK */
static int node_group_ungroup(Main *bmain, bNodeTree *ntree, bNode *gnode)
{
/* clear new pointers, set in copytree */
/* Clear new pointers, set in #ntreeCopyTree_ex_new_pointers. */
LISTBASE_FOREACH (bNode *, node, &ntree->nodes) {
node->new_node = nullptr;
}

View File

@ -2042,7 +2042,7 @@ static void node_parent_offset_apply(NodeInsertOfsData *data, bNode *parent, con
#define NODE_INSOFS_ANIM_DURATION 0.25f
/**
* Callback that applies NodeInsertOfsData.offset_x to a node or its parent, similar
* Callback that applies #NodeInsertOfsData.offset_x to a node or its parent, similar
* to node_link_insert_offset_output_chain_cb below, but with slightly different logic
*/
static bool node_link_insert_offset_frame_chain_cb(bNode *fromnode,

View File

@ -2064,7 +2064,7 @@ static bool lineart_triangle_edge_image_space_occlusion(SpinLock *UNUSED(spl),
dot_r = dot_v3v3_db(Rv, tri->gn);
dot_f = dot_v3v3_db(Cv, tri->gn);
/* NOTE(Yiming): When we don't use `dot_f==0` here, it's theoretically possibile that _some_
/* NOTE(Yiming): When we don't use `dot_f==0` here, it's theoretically possible that _some_
* faces in perspective mode would get erroneously caught in this condition where they really are
* legit faces that would produce occlusion, but haven't encountered those yet in my test files.
*/

View File

@ -526,8 +526,8 @@ static struct proxy_output_ctx *alloc_proxy_output_ffmpeg(
rv->c->time_base.num = 1;
rv->st->time_base = rv->c->time_base;
/* This range matches eFFMpegCrf. Crf_range_min corresponds to lowest quality, crf_range_max to
* highest quality. */
/* This range matches #eFFMpegCrf. `crf_range_min` corresponds to lowest quality,
* `crf_range_max` to highest quality. */
const int crf_range_min = 32;
const int crf_range_max = 17;
int crf = round_fl_to_int((quality / 100.0f) * (crf_range_max - crf_range_min) + crf_range_min);
@ -535,9 +535,9 @@ static struct proxy_output_ctx *alloc_proxy_output_ffmpeg(
AVDictionary *codec_opts = NULL;
/* High quality preset value. */
av_dict_set_int(&codec_opts, "crf", crf, 0);
/* Prefer smaller file-size. Presets from veryslow to veryfast produce output with very similar
* file-size, but there is big difference in performance. In some cases veryfast preset will
* produce smallest file-size. */
/* Prefer smaller file-size. Presets from `veryslow` to `veryfast` produce output with very
* similar file-size, but there is big difference in performance.
* In some cases `veryfast` preset will produce smallest file-size. */
av_dict_set(&codec_opts, "preset", "veryfast", 0);
av_dict_set(&codec_opts, "tune", "fastdecode", 0);