Cleanup: spelling in comments

This commit is contained in:
2021-06-10 01:55:42 +10:00
parent 59553d47c0
commit 25d8ce16b5
5 changed files with 14 additions and 16 deletions

View File

@@ -1644,7 +1644,7 @@ void BKE_collection_parent_relations_rebuild(Collection *collection)
}
/* Can happen when remapping data partially out-of-Main (during advanced ID management
* operations like liboverride resync e.g.). */
* operations like lib-override resync e.g.). */
if ((child->collection->id.tag & (LIB_TAG_NO_MAIN | LIB_TAG_COPIED_ON_WRITE)) != 0) {
continue;
}

View File

@@ -70,20 +70,20 @@ typedef enum TaskPriority {
/**
* Task isolation helps avoid unexpected task scheduling decisions that can lead to bugs if wrong
* assumptions were made. Typically that happens when doing "nested threading", i.e. one thread
* schedules a bunch of main-tasks and those spawn new subtasks.
* schedules a bunch of main-tasks and those spawn new sub-tasks.
*
* What can happen is that when a main-task waits for its subtasks to complete on other threads,
* What can happen is that when a main-task waits for its sub-tasks to complete on other threads,
* another main-task is scheduled within the already running main-task. Generally, this is good,
* because it leads to better performance. However, sometimes code (often unintentionally) makes
* the assumption that at most one main-task runs on a thread at a time.
*
* The bugs often show themselves in two ways:
* - Deadlock, when a main-task holds a mutex while waiting for its subtasks to complete.
* - Data corruption, when a main-task makes wrong assumptions about a threadlocal variable.
* - Deadlock, when a main-task holds a mutex while waiting for its sub-tasks to complete.
* - Data corruption, when a main-task makes wrong assumptions about a thread-local variable.
*
* Task isolation can avoid these bugs by making sure that a main-task does not start executing
* another main-task while waiting for its subtasks. More precisely, a function that runs in an
* isolated region is only allowed to run subtasks that were spawned in the same isolated region.
* another main-task while waiting for its sub-tasks. More precisely, a function that runs in an
* isolated region is only allowed to run sub-tasks that were spawned in the same isolated region.
*
* Unfortunately, incorrect use of task isolation can lead to deadlocks itself. This can happen
* when threading primitives are used that separate spawning tasks from executing them. The problem

View File

@@ -107,7 +107,7 @@ static void space_image_gpu_texture_get(Image *image,
const DRWContextState *draw_ctx = DRW_context_state_get();
SpaceImage *sima = (SpaceImage *)draw_ctx->space_data;
if (BKE_image_is_multilayer(image)) {
/* update multiindex and pass for the current eye */
/* Update multi-index and pass for the current eye. */
BKE_image_multilayer_index(image->rr, &sima->iuser);
}
BKE_image_multiview_index(image, &sima->iuser);

View File

@@ -718,7 +718,7 @@ static bool rectf_curve_intersection(
* to select a curve by sampling it at various points instead of trying to select the
* keyframes directly.
* The selection actions done to a curve are actually done on all the keyframes of the curve.
* Note: This function is only called if no keyframe is in the seletion area.
* Note: This function is only called if no keyframe is in the selection area.
*/
static void box_select_graphcurves(bAnimContext *ac,
const rctf *rectf_view,
@@ -739,7 +739,7 @@ static void box_select_graphcurves(bAnimContext *ac,
FCurve *last_selected_curve = NULL;
/* Go through all the curves and try selecting them. This function is only called
* if no keyframe is in the seletion area, so we only have to check if the curve
* if no keyframe is in the selection area, so we only have to check if the curve
* intersects the area in order to check if the selection/deselection must happen.
*/

View File

@@ -70,9 +70,8 @@ static bool node_group_operator_active_poll(bContext *C)
SpaceNode *snode = CTX_wm_space_node(C);
/* Group operators only defined for standard node tree types.
* Disabled otherwise to allow pynodes define their own operators
* with same keymap.
*/
* Disabled otherwise to allow python-nodes define their own operators
* with same key-map. */
if (STR_ELEM(snode->tree_idname,
"ShaderNodeTree",
"CompositorNodeTree",
@@ -90,9 +89,8 @@ static bool node_group_operator_editable(bContext *C)
SpaceNode *snode = CTX_wm_space_node(C);
/* Group operators only defined for standard node tree types.
* Disabled otherwise to allow pynodes define their own operators
* with same keymap.
*/
* Disabled otherwise to allow python-nodes define their own operators
* with same key-map. */
if (ED_node_is_shader(snode) || ED_node_is_compositor(snode) || ED_node_is_texture(snode) ||
ED_node_is_geometry(snode)) {
return true;