Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorCampbell Barton <campbell@blender.org>2022-10-07 02:32:02 +0300
committerCampbell Barton <campbell@blender.org>2022-10-07 02:42:56 +0300
commitecc404ea1a37a682c0b75ec10fcece9325a15e9d (patch)
treecc5da944238a717ad28a079a3c008d51b871dbbd /source
parentb04b87b32244fe1aa00878ca596b3c763dc7297b (diff)
Cleanup: spelling in comments
Diffstat (limited to 'source')
-rw-r--r--source/blender/blenkernel/intern/cdderivedmesh.c4
-rw-r--r--source/blender/blenkernel/intern/layer.c2
-rw-r--r--source/blender/blenkernel/intern/lib_override.cc2
-rw-r--r--source/blender/blenkernel/intern/multires.cc17
-rw-r--r--source/blender/blenkernel/intern/shrinkwrap.cc21
-rw-r--r--source/blender/blenkernel/intern/subdiv_ccg.cc4
-rw-r--r--source/blender/bmesh/intern/bmesh_query.h2
-rw-r--r--source/blender/draw/intern/draw_pbvh.cc2
-rw-r--r--source/blender/editors/sculpt_paint/paint_image_proj.c4
-rw-r--r--source/blender/modifiers/intern/MOD_multires.cc4
-rw-r--r--source/blender/sequencer/SEQ_time.h4
11 files changed, 32 insertions, 34 deletions
diff --git a/source/blender/blenkernel/intern/cdderivedmesh.c b/source/blender/blenkernel/intern/cdderivedmesh.c
index 1f97f8a848c..41993764c0c 100644
--- a/source/blender/blenkernel/intern/cdderivedmesh.c
+++ b/source/blender/blenkernel/intern/cdderivedmesh.c
@@ -198,7 +198,7 @@ static DerivedMesh *cdDM_from_mesh_ex(Mesh *mesh,
DM_TYPE_CDDM,
mesh->totvert,
mesh->totedge,
- 0 /* mesh->totface */,
+ 0 /* `mesh->totface` */,
mesh->totloop,
mesh->totpoly);
@@ -213,7 +213,7 @@ static DerivedMesh *cdDM_from_mesh_ex(Mesh *mesh,
&dm->faceData,
cddata_masks.fmask | CD_MASK_ORIGINDEX,
alloctype,
- 0 /* mesh->totface */);
+ 0 /* `mesh->totface` */);
CustomData_merge(&mesh->ldata, &dm->loopData, cddata_masks.lmask, alloctype, mesh->totloop);
CustomData_merge(&mesh->pdata, &dm->polyData, cddata_masks.pmask, alloctype, mesh->totpoly);
diff --git a/source/blender/blenkernel/intern/layer.c b/source/blender/blenkernel/intern/layer.c
index fe11dc99bac..fcb0adfde34 100644
--- a/source/blender/blenkernel/intern/layer.c
+++ b/source/blender/blenkernel/intern/layer.c
@@ -988,7 +988,7 @@ void BKE_main_view_layers_synced_ensure(const Main *bmain)
BKE_scene_view_layers_synced_ensure(scene);
}
- /* NOTE: This is not (yet?) covered by the dirty tag and deffered resync system */
+ /* NOTE: This is not (yet?) covered by the dirty tag and differed re-sync system */
BKE_layer_collection_local_sync_all(bmain);
}
diff --git a/source/blender/blenkernel/intern/lib_override.cc b/source/blender/blenkernel/intern/lib_override.cc
index 04679b72b2d..07eb4741b1f 100644
--- a/source/blender/blenkernel/intern/lib_override.cc
+++ b/source/blender/blenkernel/intern/lib_override.cc
@@ -1389,7 +1389,7 @@ bool BKE_lib_override_library_create(Main *bmain,
id_hierarchy_root_reference = id_root_reference;
}
- /* While in theory it _should_ be enough to ensure sync of given viewlayer (if any), or at least
+ /* While in theory it _should_ be enough to ensure sync of given view-layer (if any), or at least
* of given scene, think for now it's better to get a fully synced Main at this point, this code
* may do some very wide remapping/data access in some cases. */
BKE_main_view_layers_synced_ensure(bmain);
diff --git a/source/blender/blenkernel/intern/multires.cc b/source/blender/blenkernel/intern/multires.cc
index 83189adfcdb..61cfe043927 100644
--- a/source/blender/blenkernel/intern/multires.cc
+++ b/source/blender/blenkernel/intern/multires.cc
@@ -69,8 +69,8 @@ void multires_customdata_delete(Mesh *me)
if (me->edit_mesh) {
BMEditMesh *em = me->edit_mesh;
/* CustomData_external_remove is used here only to mark layer
- * as non-external for further free-ing, so zero element count
- * looks safer than em->totface */
+ * as non-external for further freeing, so zero element count
+ * looks safer than `em->bm->totface`. */
CustomData_external_remove(&em->bm->ldata, &me->id, CD_MDISPS, 0);
if (CustomData_has_layer(&em->bm->ldata, CD_MDISPS)) {
@@ -1359,11 +1359,9 @@ static void multires_sync_levels(Scene *scene, Object *ob_src, Object *ob_dst)
MultiresModifierData *mmd_dst = get_multires_modifier(scene, ob_dst, true);
if (!mmd_src) {
- /* object could have MDISP even when there is no multires modifier
- * this could lead to troubles due to i've got no idea how mdisp could be
- * up-sampled correct without modifier data.
- * just remove mdisps if no multires present (nazgul) */
-
+ /* NOTE(@sergey): object could have MDISP even when there is no multires modifier
+ * this could lead to troubles due to I've got no idea how mdisp could be
+ * up-sampled correct without modifier data. Just remove mdisps if no multires present. */
multires_customdata_delete(static_cast<Mesh *>(ob_src->data));
}
@@ -1404,9 +1402,8 @@ static void multires_apply_smat(struct Depsgraph * /*depsgraph*/,
multires_apply_uniform_scale(object, scale);
}
else {
- /* TODO(sergey): This branch of code actually requires more work to
- * preserve all the details.
- */
+ /* TODO(@sergey): This branch of code actually requires more work to
+ * preserve all the details. */
const float scale = mat3_to_scale(smat);
multires_apply_uniform_scale(object, scale);
}
diff --git a/source/blender/blenkernel/intern/shrinkwrap.cc b/source/blender/blenkernel/intern/shrinkwrap.cc
index 2b8af00d281..91683788422 100644
--- a/source/blender/blenkernel/intern/shrinkwrap.cc
+++ b/source/blender/blenkernel/intern/shrinkwrap.cc
@@ -61,7 +61,8 @@ struct ShrinkwrapCalcData {
MVert *vert; /* Array of verts being projected. */
const float (*vert_normals)[3];
- float (*vertexCos)[3]; /* vertexs being shrinkwraped */
+ /* Vertices being shrink-wrapped. */
+ float (*vertexCos)[3];
int numVerts;
const MDeformVert *dvert; /* Pointer to mdeform array */
@@ -332,8 +333,8 @@ void BKE_shrinkwrap_compute_boundary_data(Mesh *mesh)
/**
* Shrink-wrap to the nearest vertex
*
- * it builds a #BVHTree of vertices we can attach to and then
- * for each vertex performs a nearest vertex search on the tree
+ * it builds a BVH-tree of vertices we can attach to and then
+ * for each vertex performs a nearest vertex search on the tree.
*/
static void shrinkwrap_calc_nearest_vertex_cb_ex(void *__restrict userdata,
const int i,
@@ -535,12 +536,12 @@ static void shrinkwrap_calc_normal_projection_cb_ex(void *__restrict userdata,
hit->index = -1;
- /* TODO: we should use FLT_MAX here, but sweepsphere code isn't prepared for that */
+ /* TODO: we should use FLT_MAX here, but sweep-sphere code isn't prepared for that. */
hit->dist = BVH_RAYCAST_DIST_MAX;
bool is_aux = false;
- /* Project over positive direction of axis */
+ /* Project over positive direction of axis. */
if (calc->smd->shrinkOpts & MOD_SHRINKWRAP_PROJECT_ALLOW_POS_DIR) {
if (aux_tree) {
if (BKE_shrinkwrap_project_normal(0, tmp_co, tmp_no, 0.0, local2aux, aux_tree, hit)) {
@@ -1091,10 +1092,10 @@ void BKE_shrinkwrap_find_nearest_surface(ShrinkwrapTreeData *tree,
}
}
-/*
- * Shrinkwrap moving vertexs to the nearest surface point on the target
+/**
+ * Shrink-wrap moving vertices to the nearest surface point on the target.
*
- * it builds a BVHTree from the target mesh and then performs a
+ * It builds a #BVHTree from the target mesh and then performs a
* NN matches for each vertex
*/
static void shrinkwrap_calc_nearest_surface_point_cb_ex(void *__restrict userdata,
@@ -1408,11 +1409,11 @@ void shrinkwrapModifier_deform(ShrinkwrapModifierData *smd,
calc.aux_target = DEG_get_evaluated_object(ctx->depsgraph, smd->auxTarget);
if (mesh != nullptr && smd->shrinkType == MOD_SHRINKWRAP_PROJECT) {
- /* Setup arrays to get vertexs positions, normals and deform weights */
+ /* Setup arrays to get vertices position, normals and deform weights. */
calc.vert = BKE_mesh_verts_for_write(mesh);
calc.vert_normals = BKE_mesh_vertex_normals_ensure(mesh);
- /* Using vertexs positions/normals as if a subsurface was applied */
+ /* Using vertices positions/normals as if a subsurface was applied */
if (smd->subsurfLevels) {
SubsurfModifierData ssmd = {{nullptr}};
ssmd.subdivType = ME_CC_SUBSURF; /* catmull clark */
diff --git a/source/blender/blenkernel/intern/subdiv_ccg.cc b/source/blender/blenkernel/intern/subdiv_ccg.cc
index 8c44d53e5bd..704e0690892 100644
--- a/source/blender/blenkernel/intern/subdiv_ccg.cc
+++ b/source/blender/blenkernel/intern/subdiv_ccg.cc
@@ -363,7 +363,7 @@ static int *static_or_heap_storage_get(StaticOrHeapIntStorage *storage, int heap
if (heap_len <= storage->static_storage_len) {
return storage->static_storage;
}
- /* Make sure heap ius big enough. */
+ /* Make sure heap is big enough. */
if (heap_len > storage->heap_storage_len) {
MEM_SAFE_FREE(storage->heap_storage);
storage->heap_storage = static_cast<int *>(
@@ -1708,7 +1708,7 @@ static int adjacent_edge_point_index_from_coord(const SubdivCCG *subdiv_ccg,
directional_edge_vertex_index = edge_vertices_indices[1];
}
- /* Flip the index if the edde points opposite direction. */
+ /* Flip the index if the edge points opposite direction. */
if (adjacent_vertex_index != directional_edge_vertex_index) {
const int num_edge_points = subdiv_ccg->grid_size * 2;
adjacent_edge_point_index = num_edge_points - adjacent_edge_point_index - 1;
diff --git a/source/blender/bmesh/intern/bmesh_query.h b/source/blender/bmesh/intern/bmesh_query.h
index 9d690395d72..c3a30df11d6 100644
--- a/source/blender/bmesh/intern/bmesh_query.h
+++ b/source/blender/bmesh/intern/bmesh_query.h
@@ -708,7 +708,7 @@ double BM_mesh_calc_volume(BMesh *bm, bool is_signed) ATTR_WARN_UNUSED_RESULT AT
* Calculate isolated groups of faces with optional filtering.
*
* \param bm: the BMesh.
- * \param r_groups_array: Array of ints to fill in, length of bm->totface
+ * \param r_groups_array: Array of integers to fill in, length of `bm->totface`
* (or when hflag_test is set, the number of flagged faces).
* \param r_group_index: index, length pairs into \a r_groups_array, size of return value
* int pairs: (array_start, array_length).
diff --git a/source/blender/draw/intern/draw_pbvh.cc b/source/blender/draw/intern/draw_pbvh.cc
index 02e7f937987..cab260f87ac 100644
--- a/source/blender/draw/intern/draw_pbvh.cc
+++ b/source/blender/draw/intern/draw_pbvh.cc
@@ -729,7 +729,7 @@ struct PBVHBatches {
GPUVertBufRaw access;
GPU_vertbuf_attr_get_raw_data(vbo.vert_buf, 0, &access);
-#if 0 /* Enable to fuzz gpu data (to check for overallocation). */
+#if 0 /* Enable to fuzz GPU data (to check for over-allocation). */
existing_data = GPU_vertbuf_get_data(vbo.vert_buf);
uchar *c = static_cast<uchar *>(existing_data);
for (int i : IndexRange(vert_count * access.stride)) {
diff --git a/source/blender/editors/sculpt_paint/paint_image_proj.c b/source/blender/editors/sculpt_paint/paint_image_proj.c
index 1eae5550703..66132fe4b92 100644
--- a/source/blender/editors/sculpt_paint/paint_image_proj.c
+++ b/source/blender/editors/sculpt_paint/paint_image_proj.c
@@ -6250,8 +6250,8 @@ static int texture_paint_image_from_view_exec(bContext *C, wmOperator *op)
err_out);
if (!ibuf) {
- /* Mostly happens when OpenGL offscreen buffer was failed to create, */
- /* but could be other reasons. Should be handled in the future. nazgul */
+ /* NOTE(@sergey): Mostly happens when OpenGL off-screen buffer was failed to create, */
+ /* but could be other reasons. Should be handled in the future. */
BKE_reportf(op->reports, RPT_ERROR, "Failed to create OpenGL off-screen buffer: %s", err_out);
return OPERATOR_CANCELLED;
}
diff --git a/source/blender/modifiers/intern/MOD_multires.cc b/source/blender/modifiers/intern/MOD_multires.cc
index 6342ff384a4..e4c90eb237b 100644
--- a/source/blender/modifiers/intern/MOD_multires.cc
+++ b/source/blender/modifiers/intern/MOD_multires.cc
@@ -212,7 +212,7 @@ static Mesh *modifyMesh(ModifierData *md, const ModifierEvalContext *ctx, Mesh *
MultiresRuntimeData *runtime_data = multires_ensure_runtime(mmd);
Subdiv *subdiv = subdiv_descriptor_ensure(mmd, &subdiv_settings, mesh);
if (subdiv == nullptr) {
- /* Happens on bad topology, ut also on empty input mesh. */
+ /* Happens on bad topology, also on empty input mesh. */
return result;
}
const bool use_clnors = mmd->flags & eMultiresModifierFlag_UseCustomNormals &&
@@ -308,7 +308,7 @@ static void deformMatrices(ModifierData *md,
MultiresRuntimeData *runtime_data = multires_ensure_runtime(mmd);
Subdiv *subdiv = subdiv_descriptor_ensure(mmd, &subdiv_settings, mesh);
if (subdiv == nullptr) {
- /* Happens on bad topology, ut also on empty input mesh. */
+ /* Happens on bad topology, also on empty input mesh. */
return;
}
BKE_subdiv_displacement_attach_from_multires(subdiv, mesh, mmd);
diff --git a/source/blender/sequencer/SEQ_time.h b/source/blender/sequencer/SEQ_time.h
index 8a67753d9d2..11dbe0dab0a 100644
--- a/source/blender/sequencer/SEQ_time.h
+++ b/source/blender/sequencer/SEQ_time.h
@@ -43,7 +43,7 @@ void SEQ_timeline_boundbox(const struct Scene *scene,
const struct ListBase *seqbase,
struct rctf *rect);
/**
- * Get FPS rate of source media. Movie, scene and movieclip strips are supported.
+ * Get FPS rate of source media. Movie, scene and movie-clip strips are supported.
* Returns 0 for unsupported strip or if media can't be loaded.
*/
float SEQ_time_sequence_get_fps(struct Scene *scene, struct Sequence *seq);
@@ -132,7 +132,7 @@ float SEQ_time_content_end_frame_get(const struct Scene *scene, const struct Seq
*/
void SEQ_time_start_frame_set(const struct Scene *scene, struct Sequence *seq, int timeline_frame);
/**
- * Update length of metastrip after any contained strip length or position has changed.
+ * Update length of meta-strip after any contained strip length or position has changed.
* \note this function is currently only used internally and in versioning code.
*/
void SEQ_time_update_meta_strip_range(const struct Scene *scene, struct Sequence *seq_meta);