Cleanup: use usernames in code-comments

Also remove my name in a few cases where it doesn't seem necessary.
This commit is contained in:
Campbell Barton
2024-01-14 11:48:51 +11:00
parent 4e898dd944
commit c00cd902ce
15 changed files with 41 additions and 42 deletions

View File

@@ -152,10 +152,8 @@ struct LayerTypeInfo {
* (there should be (sub element count)^2 weights per element)
* count gives the number of elements in sources
*
* \note in some cases \a dest pointer is in \a sources
* so all functions have to take this into account and delay
* applying changes while reading from sources.
* See bug #32395 - Campbell.
* \note in some cases `dest` pointer is in `sources` so all functions have to take this
* into account and delay applying changes while reading from sources. See #32395.
*/
cd_interp interp;

View File

@@ -46,8 +46,6 @@
* This is getting a bit complicated with the addition of unfilled splines and end capping -
* If large changes are needed here we would be better off using an iterable
* BLI_mempool for triangles and converting to a contiguous array afterwards.
*
* - Campbell
*/
#include <algorithm> /* For `min/max`. */

View File

@@ -81,7 +81,7 @@ BLI_INLINE void bm_vert_calc_normals_accum_loop(const BMLoop *l_iter,
static void bm_vert_calc_normals_impl(BMVert *v)
{
/* Note on redundant unit-length edge-vector calculation:
/* NOTE(@ideasman42): Regarding redundant unit-length edge-vector calculation:
*
* This functions calculates unit-length edge-vector for every loop edge
* in practice this means 2x `sqrt` calls per face-corner connected to each vertex.
@@ -106,7 +106,7 @@ static void bm_vert_calc_normals_impl(BMVert *v)
*
* In conclusion, the cost of caching & looking up edge-vectors both globally or per-vertex
* doesn't save enough time to make it worthwhile.
* - Campbell. */
*/
float *v_no = v->no;
zero_v3(v_no);

View File

@@ -1383,8 +1383,8 @@ static bool ui_but_event_property_operator_string(const bContext *C,
{
/* Context toggle operator names to check. */
/* This function could use a refactor to generalize button type to operator relationship
* as well as which operators use properties. - Campbell */
/* NOTE(@ideasman42): This function could use a refactor to generalize button type to operator
* relationship as well as which operators use properties. */
const char *ctx_toggle_opnames[] = {
"WM_OT_context_toggle",
"WM_OT_context_toggle_enum",

View File

@@ -969,15 +969,14 @@ uiButStore *UI_butstore_create(uiBlock *block)
void UI_butstore_free(uiBlock *block, uiButStore *bs_handle)
{
/* Workaround for button store being moved into new block,
/* NOTE(@ideasman42): Workaround for button store being moved into new block,
* which then can't use the previous buttons state
* ('ui_but_update_from_old_block' fails to find a match),
* (#ui_but_update_from_old_block fails to find a match),
* keeping the active button in the old block holding a reference
* to the button-state in the new block: see #49034.
*
* Ideally we would manage moving the 'uiButStore', keeping a correct state.
* All things considered this is the most straightforward fix - Campbell.
*/
* All things considered this is the most straightforward fix. */
if (block != bs_handle->block && bs_handle->block != nullptr) {
block = bs_handle->block;
}

View File

@@ -805,7 +805,8 @@ static int edbm_rip_invoke__vert(bContext *C, const wmEvent *event, Object *obed
} while ((l_iter = l_iter->radial_next) != l_first);
}
else {
/* looks like there are no split edges, we could just return/report-error? - Campbell */
/* NOTE(@ideasman42): It looks like there are no split edges,
* we could just return/report-error? */
}
}

View File

@@ -110,14 +110,17 @@ struct UndoMesh {
int selectmode;
char uv_selectmode;
/** \note
* This isn't a perfect solution, if you edit keys and change shapes this works well
* (fixing #32442), but editing shape keys, going into object mode, removing or changing their
* order, then go back into editmode and undo will give issues - where the old index will be
* out of sync with the new object index.
/**
* The active shape key associated with this mesh.
*
* NOTE(@ideasman42): This isn't a perfect solution, if you edit keys and change shapes this
* works well (fixing #32442), but editing shape keys, going into object mode, removing or
* changing their order, then go back into edit-mode and undo will give issues - where the old
* index will be out of sync with the new object index.
*
* There are a few ways this could be made to work but for now its a known limitation with mixing
* object and editmode operations - Campbell. */
* object and edit-mode operations.
*/
int shapenr;
#ifdef USE_ARRAY_STORE

View File

@@ -550,8 +550,8 @@ static void createTransObject(bContext *C, TransInfo *t)
td->flag |= TD_SKIP;
}
else if (BKE_object_is_in_editmode(ob)) {
/* The object could have edit-mode data from another view-layer,
* it's such a corner-case it can be skipped for now - Campbell. */
/* NOTE(@ideasman42): The object could have edit-mode data from another view-layer,
* it's such a corner-case it can be skipped for now. */
td->flag |= TD_SKIP;
}
}

View File

@@ -1363,10 +1363,10 @@ static void edge_slide_apply_elem(const TransDataEdgeSlideVert *sv,
}
else {
/**
* Implementation note, even mode ignores the starting positions and uses
* NOTE(@ideasman42): Implementation note, even mode ignores the starting positions and uses
* only the a/b verts, this could be changed/improved so the distance is
* still met but the verts are moved along their original path (which may not be straight),
* however how it works now is OK and matches 2.4x - Campbell
* however how it works now is OK and matches 2.4x.
*
* \note `len_v3v3(curr_sv->dir_side[0], curr_sv->dir_side[1])`
* is the same as the distance between the original vert locations,

View File

@@ -3112,10 +3112,10 @@ void UV_OT_select_linked_pick(wmOperatorType *ot)
* \{ */
/**
* \note This is based on similar use case to #MESH_OT_split(), which has a similar effect
* but in this case they are not joined to begin with (only having the behavior of being joined)
* so its best to call this #uv_select_split() instead of just split(), but assigned to the same
* key as #MESH_OT_split - Campbell.
* NOTE(@ideasman42): This is based on similar use case to #MESH_OT_split(),
* which has a similar effect but in this case they are not joined to begin with
* (only having the behavior of being joined) so its best to call this #uv_select_split()
* instead of just split(), but assigned to the same key as #MESH_OT_split.
*/
static int uv_select_split_exec(bContext *C, wmOperator *op)
{

View File

@@ -31,7 +31,7 @@
namespace blender::geometry {
/* Store information about an island's placement such as translation, rotation and reflection. */
/** Store information about an island's placement such as translation, rotation and reflection. */
class UVPhi {
public:
UVPhi();

View File

@@ -506,11 +506,11 @@ static bool rna_Armature_collections_override_apply(Main *bmain,
* handled below this switch. */
break;
case LIBOVERRIDE_OP_REPLACE:
/* These are stored by Blender when overridable properties are changed on the root
* collections, However, these are *also* created on the `armature.collections_all` property,
* which is actually where these per-collection overrides are handled. This doesn't seem to
* be proper behavior, but I (Sybren) also don't want to spam the console about this as this
* is not something a user could fix. */
/* NOTE(@sybren): These are stored by Blender when overridable properties are changed on the
* root collections, However, these are *also* created on the `armature.collections_all`
* property, which is actually where these per-collection overrides are handled.
* This doesn't seem to be proper behavior, but I also don't want to spam the console about
* this as this is not something a user could fix. */
return false;
default:
/* Any other operation is simply not supported, and also not expected to exist. */

View File

@@ -1092,9 +1092,9 @@ void RNA_def_struct_sdna(StructRNA *srna, const char *structname)
ds = rna_find_def_struct(srna);
/* There are far too many structs which initialize without valid DNA struct names,
* this can't be checked without adding an option to disable
* (tested this and it means changes all over - Campbell) */
/* NOTE(@ideasman42): There are far too many structs which initialize without valid DNA struct
* names, this can't be checked without adding an option to disable
* (tested this and it means changes all over). */
#if 0
if (DNA_struct_find_nr_wrapper(DefRNA.sdna, structname) == -1) {
if (!DefRNA.silent) {

View File

@@ -8949,13 +8949,13 @@ void pyrna_free_types()
/**
* \warning memory leak!
*
* There is currently a bug where moving the registration of a Python class does
* NOTE(@ideasman42): There is currently a bug where moving the registration of a Python class does
* not properly manage reference-counts from the Python class. As the `srna` owns
* the Python class this should not be so tricky, but changing the references as
* you'd expect when changing ownership crashes blender on exit so I had to comment out
* the #Py_DECREF. This is not so bad because the leak only happens when re-registering
* (continuously running `SCRIPT_OT_reload`).
* - Should still be fixed - Campbell
* This should still be fixed.
*/
PyDoc_STRVAR(pyrna_register_class_doc,
".. function:: register_class(cls)\n"

View File

@@ -93,9 +93,9 @@ typedef struct TexResult {
/* This one uses nodes. */
/**
* \warning if the texres's values are not declared zero,
* WARNING(@ideasman42): if the texres's values are not declared zero,
* check the return value to be sure the color values are set before using the r/g/b values,
* otherwise you may use uninitialized values - Campbell
* otherwise you may use uninitialized values.
*
* Use it for stuff which is out of render pipeline.
*/