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 <ideasman42@gmail.com>2021-08-04 03:03:07 +0300
committerCampbell Barton <ideasman42@gmail.com>2021-08-04 03:03:07 +0300
commit0d2589d08c615d1bc07e5156b41b9ffda6c3ba27 (patch)
treebfe3c62930cf43bfd6fb7f3b2f35e7ca62ed9fb5 /source
parentfb87d236edb7e98c5fc526b9829e6bc6b8916828 (diff)
Cleanup: spelling
Diffstat (limited to 'source')
-rw-r--r--source/blender/blenlib/BLI_array.h2
-rw-r--r--source/blender/blenlib/intern/polyfill_2d_beautify.c2
-rw-r--r--source/blender/bmesh/tools/bmesh_decimate_collapse.c4
-rw-r--r--source/blender/compositor/operations/COM_GlareBaseOperation.h4
-rw-r--r--source/blender/editors/animation/time_scrub_ui.c4
-rw-r--r--source/blender/editors/mask/mask_select.c4
-rw-r--r--source/blender/editors/uvedit/uvedit_smart_stitch.c2
-rw-r--r--source/blender/io/usd/intern/usd_capi_import.cc5
-rw-r--r--source/blender/io/usd/intern/usd_reader_material.h21
-rw-r--r--source/blender/io/usd/intern/usd_reader_mesh.cc18
10 files changed, 33 insertions, 33 deletions
diff --git a/source/blender/blenlib/BLI_array.h b/source/blender/blenlib/BLI_array.h
index 6bf29a6168f..084f573e8c7 100644
--- a/source/blender/blenlib/BLI_array.h
+++ b/source/blender/blenlib/BLI_array.h
@@ -156,7 +156,7 @@ void _bli_array_grow_func(void **arr_p,
* \{ */
/**
- * not part of the 'API' but handy funcs,
+ * Not part of the 'API' but handy functions,
* same purpose as #BLI_array_staticdeclare()
* but use when the max size is known ahead of time */
#define BLI_array_fixedstack_declare(arr, maxstatic, realsize, allocstr) \
diff --git a/source/blender/blenlib/intern/polyfill_2d_beautify.c b/source/blender/blenlib/intern/polyfill_2d_beautify.c
index 7781e3a0f6f..ed07b002e32 100644
--- a/source/blender/blenlib/intern/polyfill_2d_beautify.c
+++ b/source/blender/blenlib/intern/polyfill_2d_beautify.c
@@ -25,7 +25,7 @@
* on a simple polygon representation where we _know_:
*
* - The polygon is primitive with no holes with a continuous boundary.
- * - Tris have consistent winding.
+ * - Triangles have consistent winding.
* - 2d (saves some hassles projecting face pairs on an axis for every edge-rotation)
* also saves us having to store all previous edge-states (see #EdRotState in bmesh_beautify.c)
*
diff --git a/source/blender/bmesh/tools/bmesh_decimate_collapse.c b/source/blender/bmesh/tools/bmesh_decimate_collapse.c
index 20b6903b239..97fccbe01fd 100644
--- a/source/blender/bmesh/tools/bmesh_decimate_collapse.c
+++ b/source/blender/bmesh/tools/bmesh_decimate_collapse.c
@@ -935,9 +935,9 @@ static bool bm_edge_collapse_is_degenerate_topology(BMEdge *e_first)
}
/**
- * special, highly limited edge collapse function
+ * Special, highly limited edge collapse function
* intended for speed over flexibility.
- * can only collapse edges connected to (1, 2) tris.
+ * can only collapse edges connected to (1, 2) triangles.
*
* Important - don't add vert/edge/face data on collapsing!
*
diff --git a/source/blender/compositor/operations/COM_GlareBaseOperation.h b/source/blender/compositor/operations/COM_GlareBaseOperation.h
index 50db4e02940..6dac6f5ecc7 100644
--- a/source/blender/compositor/operations/COM_GlareBaseOperation.h
+++ b/source/blender/compositor/operations/COM_GlareBaseOperation.h
@@ -23,8 +23,8 @@
namespace blender::compositor {
-/* utility functions used by glare, tonemap and lens distortion */
-/* soms macros for color handling */
+/* Utility functions used by glare, tone-map and lens distortion. */
+/* Some macros for color handling. */
typedef float fRGB[4];
/* TODO: replace with BLI_math_vector. */
diff --git a/source/blender/editors/animation/time_scrub_ui.c b/source/blender/editors/animation/time_scrub_ui.c
index 182e61e53b6..8aeb6a57124 100644
--- a/source/blender/editors/animation/time_scrub_ui.c
+++ b/source/blender/editors/animation/time_scrub_ui.c
@@ -244,8 +244,8 @@ void ED_time_scrub_channel_search_draw(const bContext *C, ARegion *region, bDope
UI_block_align_end(block);
UI_block_layout_resolve(block, NULL, NULL);
- /* Make sure the events are consumed from the search and dont reach other UI blocks since this is
- * drawn on top of animchannels. */
+ /* Make sure the events are consumed from the search and don't reach other UI blocks since this
+ * is drawn on top of animation-channels. */
UI_block_flag_enable(block, UI_BLOCK_CLIP_EVENTS);
UI_block_bounds_set_normal(block, 0);
UI_block_end(C, block);
diff --git a/source/blender/editors/mask/mask_select.c b/source/blender/editors/mask/mask_select.c
index 3bb05a27c54..8ddc3758e4e 100644
--- a/source/blender/editors/mask/mask_select.c
+++ b/source/blender/editors/mask/mask_select.c
@@ -164,8 +164,8 @@ void ED_mask_select_flush_all(Mask *mask)
LISTBASE_FOREACH (MaskSpline *, spline, &mask_layer->splines) {
spline->flag &= ~SELECT;
- /* intentionally _dont_ do this in the mask layer loop
- * so we clear flags on all splines */
+ /* Intentionally *don't* do this in the mask layer loop
+ * so we clear flags on all splines. */
if (mask_layer->restrictflag & MASK_RESTRICT_VIEW) {
continue;
}
diff --git a/source/blender/editors/uvedit/uvedit_smart_stitch.c b/source/blender/editors/uvedit/uvedit_smart_stitch.c
index 535a0e00347..1bcd1fad9d6 100644
--- a/source/blender/editors/uvedit/uvedit_smart_stitch.c
+++ b/source/blender/editors/uvedit/uvedit_smart_stitch.c
@@ -1769,7 +1769,7 @@ static void stitch_draw(const bContext *UNUSED(C), ARegion *UNUSED(region), void
GPU_blend(GPU_BLEND_ALPHA);
- /* Static Tris */
+ /* Static Triangles. */
if (stitch_preview->static_tris) {
UI_GetThemeColor4fv(TH_STITCH_PREVIEW_ACTIVE, col);
vbo = GPU_vertbuf_create_with_format(&format);
diff --git a/source/blender/io/usd/intern/usd_capi_import.cc b/source/blender/io/usd/intern/usd_capi_import.cc
index 8255fca284c..789ff20ba82 100644
--- a/source/blender/io/usd/intern/usd_capi_import.cc
+++ b/source/blender/io/usd/intern/usd_capi_import.cc
@@ -365,8 +365,7 @@ bool USD_import(struct bContext *C,
{
blender::io::usd::ensure_usd_plugin_path_registered();
- /* Using new here since MEM_* funcs do not call ctor to properly initialize
- * data. */
+ /* Using new here since `MEM_*` functions do not call constructor to properly initialize data. */
ImportJobData *job = new ImportJobData();
job->bmain = CTX_data_main(C);
job->scene = CTX_data_scene(C);
@@ -496,7 +495,7 @@ CacheReader *CacheReader_open_usd_object(CacheArchiveHandle *handle,
USDPrimReader *usd_reader = archive->create_reader(prim);
if (usd_reader == nullptr) {
- /* This object is not supported */
+ /* This object is not supported. */
return nullptr;
}
usd_reader->object(object);
diff --git a/source/blender/io/usd/intern/usd_reader_material.h b/source/blender/io/usd/intern/usd_reader_material.h
index 3e8fc675931..a17504bd590 100644
--- a/source/blender/io/usd/intern/usd_reader_material.h
+++ b/source/blender/io/usd/intern/usd_reader_material.h
@@ -55,28 +55,29 @@ struct NodePlacementContext {
/* Converts USD materials to Blender representation. */
-/* By default, the USDMaterialReader creates a Blender material with
+/**
+ By default, the #USDMaterialReader creates a Blender material with
* the same name as the USD material. If the USD material has a
- * UsdPreviewSurface source, the Blender material's viewport display
+ * #UsdPreviewSurface source, the Blender material's viewport display
* color, roughness and metallic properties are set to the corresponding
- * UsdPreoviewSurface inputs.
+ * #UsdPreoviewSurface inputs.
*
* If the Import USD Preview option is enabled, the current implementation
- * converts UsdPreviewSurface to Blender nodes as follows:
+ * converts #UsdPreviewSurface to Blender nodes as follows:
*
- * UsdPreviewSurface -> Pricipled BSDF
- * UsdUVTexture -> Texture Image + Normal Map
- * UsdPrimvarReader_float2 -> UV Map
+ * - #UsdPreviewSurface -> Principled BSDF
+ * - #UsdUVTexture -> Texture Image + Normal Map
+ * - UsdPrimvarReader_float2 -> UV Map
*
* Limitations: arbitrary primvar readers or UsdTransform2d not yet
- * supported. For UsdUVTexture, only the file, st and sourceColorSpace
+ * supported. For #UsdUVTexture, only the file, st and #sourceColorSpace
* inputs are handled.
*
* TODO(makowalski): Investigate adding support for converting additional
* shaders and inputs. Supporting certain types of inputs, such as texture
* scale and bias, will probably require creating Blender Group nodes with
- * the corresponding inputs. */
-
+ * the corresponding inputs.
+ */
class USDMaterialReader {
protected:
USDImportParams params_;
diff --git a/source/blender/io/usd/intern/usd_reader_mesh.cc b/source/blender/io/usd/intern/usd_reader_mesh.cc
index f13da4680e2..9c75bc8afae 100644
--- a/source/blender/io/usd/intern/usd_reader_mesh.cc
+++ b/source/blender/io/usd/intern/usd_reader_mesh.cc
@@ -61,7 +61,7 @@ static const pxr::TfToken normalsPrimvar("normals", pxr::TfToken::Immortal);
} // namespace usdtokens
namespace utils {
-/* Very similar to abc mesh utils. */
+/* Very similar to #blender::io::alembic::utils. */
static void build_mat_map(const Main *bmain, std::map<std::string, Material *> *r_mat_map)
{
if (r_mat_map == nullptr) {
@@ -71,7 +71,7 @@ static void build_mat_map(const Main *bmain, std::map<std::string, Material *> *
Material *material = static_cast<Material *>(bmain->materials.first);
for (; material; material = static_cast<Material *>(material->id.next)) {
- /* We have to do this because the stored material name is coming directly from usd. */
+ /* We have to do this because the stored material name is coming directly from USD. */
(*r_mat_map)[pxr::TfMakeValidIdentifier(material->id.name + 2)] = material;
}
}
@@ -212,7 +212,7 @@ void USDMeshReader::read_object_data(Main *bmain, const double motionSampleTime)
is_initial_load_ = false;
if (read_mesh != mesh) {
- /* XXX fixme after 2.80; mesh->flag isn't copied by BKE_mesh_nomain_to_mesh() */
+ /* FIXME: after 2.80; `mesh->flag` isn't copied by #BKE_mesh_nomain_to_mesh() */
/* read_mesh can be freed by BKE_mesh_nomain_to_mesh(), so get the flag before that happens. */
short autosmooth = (read_mesh->flag & ME_AUTOSMOOTH);
BKE_mesh_nomain_to_mesh(read_mesh, mesh, object_, &CD_MASK_MESH, true);
@@ -334,7 +334,7 @@ void USDMeshReader::read_uvs(Mesh *mesh, const double motionSampleTime, const bo
pxr::TfToken uv_token;
- /* If first time seeing uv token, store in map of <layer->uid, TfToken> */
+ /* If first time seeing uv token, store in map of `<layer->uid, TfToken>`. */
if (uv_token_map_.find(layer_name) == uv_token_map_.end()) {
uv_token = pxr::TfToken(layer_name);
uv_token_map_.insert(std::make_pair(layer_name, uv_token));
@@ -347,7 +347,7 @@ void USDMeshReader::read_uvs(Mesh *mesh, const double motionSampleTime, const bo
if (uv_token.IsEmpty()) {
continue;
}
- /* Early out if not first load and uvs arent animated. */
+ /* Early out if not first load and UVs aren't animated. */
if (!load_uvs && primvar_varying_map_.find(uv_token) != primvar_varying_map_.end() &&
!primvar_varying_map_.at(uv_token)) {
continue;
@@ -630,7 +630,7 @@ void USDMeshReader::read_mesh_sample(ImportSettings *settings,
const bool new_mesh)
{
/* Note that for new meshes we always want to read verts and polys,
- * regradless of the value of the read_flag, to avoid a crash downstream
+ * regardless of the value of the read_flag, to avoid a crash downstream
* in code that expect this data to be there. */
if (new_mesh || (settings->read_flag & MOD_MESHSEQ_READ_VERT) != 0) {
@@ -684,7 +684,7 @@ void USDMeshReader::assign_facesets_to_mpoly(double motionSampleTime,
}
/* Find the geom subsets that have bound materials.
- * We don't call pxr::UsdShadeMaterialBindingAPI::GetMaterialBindSubsets()
+ * We don't call #pxr::UsdShadeMaterialBindingAPI::GetMaterialBindSubsets()
* because this function returns only those subsets that are in the 'materialBind'
* family, but, in practice, applications (like Houdini) might export subsets
* in different families that are bound to materials.
@@ -780,7 +780,7 @@ Mesh *USDMeshReader::read_mesh(Mesh *existing_mesh,
bool is_uv = false;
- /* Assume all uvs are stored in one of these primvar types */
+ /* Assume all UVs are stored in one of these primvar types */
if (type == pxr::SdfValueTypeNames->TexCoord2hArray ||
type == pxr::SdfValueTypeNames->TexCoord2fArray ||
type == pxr::SdfValueTypeNames->TexCoord2dArray) {
@@ -817,7 +817,7 @@ Mesh *USDMeshReader::read_mesh(Mesh *existing_mesh,
Mesh *active_mesh = existing_mesh;
bool new_mesh = false;
- /* TODO(makowalski): inmplement the optimization of only updating the mesh points when
+ /* TODO(makowalski): implement the optimization of only updating the mesh points when
* the topology is consistent, as in the Alembic importer. */
ImportSettings settings;