diff --git a/source/blender/blenkernel/BKE_bake_items.hh b/source/blender/blenkernel/BKE_bake_items.hh index cfbb537d5c1..858e6216786 100644 --- a/source/blender/blenkernel/BKE_bake_items.hh +++ b/source/blender/blenkernel/BKE_bake_items.hh @@ -35,7 +35,7 @@ struct BakeState { Map> items_by_id; }; -/** Same as above, but does not own the bake items. */ +/** Same as #BakeState, but does not own the bake items. */ struct BakeStateRef { Map items_by_id; diff --git a/source/blender/blenkernel/BKE_customdata.hh b/source/blender/blenkernel/BKE_customdata.hh index 5063fd714c0..35be7b73ad4 100644 --- a/source/blender/blenkernel/BKE_customdata.hh +++ b/source/blender/blenkernel/BKE_customdata.hh @@ -233,7 +233,7 @@ void CustomData_reset(CustomData *data); void CustomData_free(CustomData *data, int totelem); /** - * Same as above, but only frees layers which matches the given mask. + * Same as #CustomData_free, but only frees layers which matches the given mask. */ void CustomData_free_typemask(CustomData *data, int totelem, eCustomDataMask mask); @@ -258,7 +258,7 @@ const void *CustomData_add_layer_with_data(CustomData *data, const blender::ImplicitSharingInfo *sharing_info); /** - * Same as above but accepts a name. + * Same as #CustomData_add_layer but accepts a name. */ void *CustomData_add_layer_named(CustomData *data, eCustomDataType type, @@ -304,7 +304,7 @@ bool CustomData_free_layer_named(CustomData *data, blender::StringRef name, cons bool CustomData_free_layer_active(CustomData *data, eCustomDataType type, int totelem); /** - * Same as above, but free all layers with type. + * Same as #CustomData_free_layer_active, but free all layers with type. */ void CustomData_free_layers(CustomData *data, eCustomDataType type, int totelem); diff --git a/source/blender/blenkernel/BKE_fcurve.hh b/source/blender/blenkernel/BKE_fcurve.hh index 25e8eff0f70..0236e94de16 100644 --- a/source/blender/blenkernel/BKE_fcurve.hh +++ b/source/blender/blenkernel/BKE_fcurve.hh @@ -331,7 +331,7 @@ FCurve *BKE_fcurve_find_by_rna(PointerRNA *ptr, bool *r_driven, bool *r_special); /** - * Same as above, but takes a context data, + * Same as #BKE_fcurve_find_by_rna, but takes a context data, * temp hack needed for complex paths like texture ones. * * \param r_special: Optional, ignored when NULL. Set to `true` if the given RNA `ptr` is a NLA diff --git a/source/blender/blenkernel/BKE_idprop.hh b/source/blender/blenkernel/BKE_idprop.hh index 2179faf36c6..b35632c8f88 100644 --- a/source/blender/blenkernel/BKE_idprop.hh +++ b/source/blender/blenkernel/BKE_idprop.hh @@ -178,7 +178,7 @@ void IDP_FreeFromGroup(IDProperty *group, IDProperty *prop) ATTR_NONNULL(); IDProperty *IDP_GetPropertyFromGroup(const IDProperty *prop, const char *name) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(); /** - * Same as above but ensure type match. + * Same as #IDP_GetPropertyFromGroup but ensure the `type` matches. */ IDProperty *IDP_GetPropertyTypeFromGroup(const IDProperty *prop, const char *name, diff --git a/source/blender/blenkernel/BKE_image.h b/source/blender/blenkernel/BKE_image.h index a2ccf4effac..d93460ed10a 100644 --- a/source/blender/blenkernel/BKE_image.h +++ b/source/blender/blenkernel/BKE_image.h @@ -350,7 +350,7 @@ void BKE_image_all_free_anim_ibufs(struct Main *bmain, int cfra); void BKE_image_free_all_gputextures(struct Main *bmain); /** - * Same as above but only free animated images. + * Same as #BKE_image_free_all_gputextures but only free animated images. */ void BKE_image_free_anim_gputextures(struct Main *bmain); void BKE_image_free_old_gputextures(struct Main *bmain); diff --git a/source/blender/blenkernel/BKE_node.hh b/source/blender/blenkernel/BKE_node.hh index d65e3ca09a5..b86874ded27 100644 --- a/source/blender/blenkernel/BKE_node.hh +++ b/source/blender/blenkernel/BKE_node.hh @@ -662,17 +662,18 @@ void nodeAttachNode(bNodeTree *ntree, bNode *node, bNode *parent); void nodeDetachNode(bNodeTree *ntree, bNode *node); /** - * Same as above but expects that the socket definitely is in the node tree. + * Finds a node based on given socket and returns true on success. + */ +bool nodeFindNodeTry(bNodeTree *ntree, bNodeSocket *sock, bNode **r_node, int *r_sockindex); + +/** + * Same as #nodeFindNodeTry but expects that the socket definitely is in the node tree. */ void nodeFindNode(bNodeTree *ntree, bNodeSocket *sock, bNode **r_node, int *r_sockindex); /** * Finds a node based on its name. */ bNode *nodeFindNodebyName(bNodeTree *ntree, const char *name); -/** - * Finds a node based on given socket and returns true on success. - */ -bool nodeFindNodeTry(bNodeTree *ntree, bNodeSocket *sock, bNode **r_node, int *r_sockindex); bool nodeIsParentAndChild(const bNode *parent, const bNode *child); diff --git a/source/blender/blenkernel/BKE_object.hh b/source/blender/blenkernel/BKE_object.hh index 41dede9c97d..00606f7c46e 100644 --- a/source/blender/blenkernel/BKE_object.hh +++ b/source/blender/blenkernel/BKE_object.hh @@ -507,7 +507,8 @@ Mesh *BKE_object_get_evaluated_mesh_no_subsurf(const Object *object); /** Get evaluated mesh for given object. */ Mesh *BKE_object_get_evaluated_mesh(const Object *object); /** - * Same as above, but does not check if the object's geometry is fully evaluated already. + * Same as #BKE_object_get_evaluated_mesh, but does not check + * if the object's geometry is fully evaluated already. * This should barely ever be used. */ Mesh *BKE_object_get_evaluated_mesh_no_subsurf_unchecked(const Object *object); diff --git a/source/blender/blenlib/intern/BLI_ghash.c b/source/blender/blenlib/intern/BLI_ghash.c index c2cadc39539..11bfdf95f13 100644 --- a/source/blender/blenlib/intern/BLI_ghash.c +++ b/source/blender/blenlib/intern/BLI_ghash.c @@ -801,7 +801,7 @@ bool BLI_ghash_remove(GHash *gh, void *BLI_ghash_popkey(GHash *gh, const void *key, GHashKeyFreeFP keyfreefp) { - /* Same as above but return the value, + /* Same as #BLI_ghash_remove but return the value, * no free value argument since it will be returned. */ const uint hash = ghash_keyhash(gh, key); diff --git a/source/blender/blenlib/tests/BLI_ghash_test.cc b/source/blender/blenlib/tests/BLI_ghash_test.cc index cd72c03b70d..055390a748d 100644 --- a/source/blender/blenlib/tests/BLI_ghash_test.cc +++ b/source/blender/blenlib/tests/BLI_ghash_test.cc @@ -110,7 +110,7 @@ TEST(ghash, InsertRemove) BLI_ghash_free(ghash, nullptr, nullptr); } -/* Same as above, but this time we allow ghash to shrink. */ +/* Same as `InsertRemove`, but this time we allow ghash to shrink. */ TEST(ghash, InsertRemoveShrink) { GHash *ghash = BLI_ghash_new(BLI_ghashutil_inthash_p, BLI_ghashutil_intcmp, __func__); diff --git a/source/blender/depsgraph/DEG_depsgraph_query.hh b/source/blender/depsgraph/DEG_depsgraph_query.hh index bfe83c22952..f268b4d6396 100644 --- a/source/blender/depsgraph/DEG_depsgraph_query.hh +++ b/source/blender/depsgraph/DEG_depsgraph_query.hh @@ -124,7 +124,7 @@ Depsgraph *DEG_get_depsgraph_by_id(const ID &id); bool DEG_is_original_id(const ID *id); bool DEG_is_original_object(const Object *object); -/* Opposite of the above. +/* Opposite of the above (`DEG_is_original_*`). * * If the data-block is not original it must be evaluated, and vice versa. */ @@ -156,10 +156,16 @@ bool DEG_id_is_fully_evaluated(const Depsgraph *depsgraph, const ID *id_eval); */ bool DEG_object_geometry_is_evaluated(const Object &object); -/** Same as above but for the transformation of the object. */ +/** + * Same as #DEG_object_geometry_is_evaluated + * but for the transformation of the object. + */ bool DEG_object_transform_is_evaluated(const Object &object); -/** Same as above but for the geometry of all objects in the collection. */ +/** + * Same as #DEG_object_geometry_is_evaluated + * but for the geometry of all objects in the collection. + */ bool DEG_collection_geometry_is_evaluated(const Collection &collection); /** \} */ diff --git a/source/blender/editors/include/ED_keyframes_edit.hh b/source/blender/editors/include/ED_keyframes_edit.hh index f962bd16bce..e3b974fa1ea 100644 --- a/source/blender/editors/include/ED_keyframes_edit.hh +++ b/source/blender/editors/include/ED_keyframes_edit.hh @@ -309,7 +309,7 @@ short ANIM_animchannel_keyframes_loop(KeyframeEditData *ked, KeyframeEditFunc key_cb, FcuEditFunc fcu_cb); /** - * Same as above, except bAnimListElem wrapper is not needed. + * Same as #ANIM_animchannel_keyframes_loop, except #bAnimListElem wrapper is not needed. * \param keytype: is #eAnim_KeyType. */ short ANIM_animchanneldata_keyframes_loop(KeyframeEditData *ked, diff --git a/source/blender/editors/include/UI_interface_c.hh b/source/blender/editors/include/UI_interface_c.hh index 94aebfd0231..3a78d85b637 100644 --- a/source/blender/editors/include/UI_interface_c.hh +++ b/source/blender/editors/include/UI_interface_c.hh @@ -3188,7 +3188,7 @@ void UI_fontstyle_draw(const uiFontStyle *fs, const uchar col[4], const uiFontStyleDraw_Params *fs_params); /** - * Drawn same as above, but at 90 degree angle. + * Drawn same as #UI_fontstyle_draw, but at 90 degree angle. */ void UI_fontstyle_draw_rotated(const uiFontStyle *fs, const rcti *rect, diff --git a/source/blender/editors/include/UI_view2d.hh b/source/blender/editors/include/UI_view2d.hh index 58b8ec00225..2679d81d5a9 100644 --- a/source/blender/editors/include/UI_view2d.hh +++ b/source/blender/editors/include/UI_view2d.hh @@ -367,7 +367,8 @@ bool UI_view2d_view_to_region_rcti_clip(const View2D *v2d, const rctf *rect_src, */ View2D *UI_view2d_fromcontext(const bContext *C); /** - * Same as above, but it returns region-window. Utility for pull-downs or buttons. + * Same as #UI_view2d_fromcontext, but it returns region-window. + * Utility for pull-downs or buttons. */ View2D *UI_view2d_fromcontext_rwin(const bContext *C); diff --git a/source/blender/editors/sculpt_paint/paint_image_proj.cc b/source/blender/editors/sculpt_paint/paint_image_proj.cc index 8ba28db6a26..4dd9caa28d9 100644 --- a/source/blender/editors/sculpt_paint/paint_image_proj.cc +++ b/source/blender/editors/sculpt_paint/paint_image_proj.cc @@ -2337,7 +2337,9 @@ static void rect_to_uvspace_ortho(const rctf *bucket_bounds, interp_v2_v2v2v2(bucket_bounds_uv[flip ? 0 : 3], uv1co, uv2co, uv3co, w); } -/* same as above but use barycentric_weights_v2_persp */ +/** + * Same as #rect_to_uvspace_ortho but use #barycentric_weights_v2_persp. + */ static void rect_to_uvspace_persp(const rctf *bucket_bounds, const float *v1coSS, const float *v2coSS, diff --git a/source/blender/editors/space_view3d/space_view3d.cc b/source/blender/editors/space_view3d/space_view3d.cc index 7aeb04adb07..133644e999b 100644 --- a/source/blender/editors/space_view3d/space_view3d.cc +++ b/source/blender/editors/space_view3d/space_view3d.cc @@ -1277,7 +1277,7 @@ static void view3d_main_region_listener(const wmRegionListenerParams *params) ED_region_tag_redraw(region); break; case NC_TEXTURE: - /* same as above */ + /* Same as #NC_IMAGE. */ ED_region_tag_redraw(region); break; case NC_MOVIECLIP: diff --git a/source/blender/editors/transform/transform_data.hh b/source/blender/editors/transform/transform_data.hh index 8da02c6f4ca..bd5f96a4b84 100644 --- a/source/blender/editors/transform/transform_data.hh +++ b/source/blender/editors/transform/transform_data.hh @@ -187,7 +187,7 @@ enum { * option enabled and rotating also transforms it. */ TD_PBONE_LOCAL_MTX_P = 1 << 17, - /** Same as above but for a child bone. */ + /** Same as #TD_PBONE_LOCAL_MTX_P but for a child bone. */ TD_PBONE_LOCAL_MTX_C = 1 << 18, /* Grease pencil layer frames. */ TD_GREASE_PENCIL_FRAME = 1 << 19, diff --git a/source/blender/gpu/intern/gpu_select_pick.cc b/source/blender/gpu/intern/gpu_select_pick.cc index 95d0863f2b7..7fbb5553c7e 100644 --- a/source/blender/gpu/intern/gpu_select_pick.cc +++ b/source/blender/gpu/intern/gpu_select_pick.cc @@ -163,7 +163,7 @@ static bool depth_buf_subrect_depth_any_filled(const DepthBufCache *rect_src, const DepthBufCache *rect_dst, const SubRectStride *sub_rect) { - /* Same as above but different rectangle sizes. */ + /* Same as #depth_buf_rect_depth_any_filled but different rectangle sizes. */ const depth_t *prev = rect_src->buf + sub_rect->start; const depth_t *curr = rect_dst->buf + sub_rect->start; for (uint i = 0; i < sub_rect->span_len; i++) { diff --git a/source/blender/makesdna/DNA_scene_types.h b/source/blender/makesdna/DNA_scene_types.h index 347a1125143..baa958be679 100644 --- a/source/blender/makesdna/DNA_scene_types.h +++ b/source/blender/makesdna/DNA_scene_types.h @@ -2046,7 +2046,7 @@ typedef struct Scene { * only used by #BKE_object_handle_update() */ struct CustomData_MeshMasks customdata_mask; - /** XXX: same as above but for temp operator use (viewport renders). */ + /** XXX: same as `customdata_mask` but for temp operator use (viewport renders). */ struct CustomData_MeshMasks customdata_mask_modal; /* Color Management. */ diff --git a/source/blender/makesrna/RNA_define.hh b/source/blender/makesrna/RNA_define.hh index d4e40302f3f..315253b0176 100644 --- a/source/blender/makesrna/RNA_define.hh +++ b/source/blender/makesrna/RNA_define.hh @@ -195,7 +195,7 @@ PropertyRNA *RNA_def_enum(StructOrFunctionRNA *cont, const char *ui_name, const char *ui_description); /** - * Same as above but sets #PROP_ENUM_FLAG before setting the default value. + * Same as #RNA_def_enum but sets #PROP_ENUM_FLAG before setting the default value. */ PropertyRNA *RNA_def_enum_flag(StructOrFunctionRNA *cont, const char *identifier, diff --git a/source/blender/makesrna/intern/rna_space.cc b/source/blender/makesrna/intern/rna_space.cc index 3a959624a79..e25cfbb4b88 100644 --- a/source/blender/makesrna/intern/rna_space.cc +++ b/source/blender/makesrna/intern/rna_space.cc @@ -1065,7 +1065,7 @@ static void rna_RegionView3D_quadview_update(Main * /*main*/, Scene * /*scene*/, } } -/* same as above but call clip==true */ +/** Same as #rna_RegionView3D_quadview_update but call `clip == true`. */ static void rna_RegionView3D_quadview_clip_update(Main * /*main*/, Scene * /*scene*/, PointerRNA *ptr) diff --git a/source/blender/makesrna/intern/rna_userdef.cc b/source/blender/makesrna/intern/rna_userdef.cc index 67705d2dc7c..dd5882939e8 100644 --- a/source/blender/makesrna/intern/rna_userdef.cc +++ b/source/blender/makesrna/intern/rna_userdef.cc @@ -1407,7 +1407,7 @@ static size_t max_memory_in_megabytes() return (limit_bytes >> 20); } -/* Same as above, but clipped to int capacity. */ +/* Same as #max_memory_in_megabytes, but clipped to int capacity. */ static int max_memory_in_megabytes_int() { const size_t limit_megabytes = max_memory_in_megabytes(); diff --git a/source/blender/nodes/NOD_geometry_nodes_lazy_function.hh b/source/blender/nodes/NOD_geometry_nodes_lazy_function.hh index 2cc57bbd703..1a2b8bcaaf3 100644 --- a/source/blender/nodes/NOD_geometry_nodes_lazy_function.hh +++ b/source/blender/nodes/NOD_geometry_nodes_lazy_function.hh @@ -60,8 +60,9 @@ struct OutputCopy { }; /** - * Same as above, but the values can be output by move, instead of copy. This can reduce the amount - * of unnecessary copies, when the old simulation state is not needed anymore. + * Same as #OutputCopy, but the values can be output by move, instead of copy. + * This can reduce the amount of unnecessary copies, + * when the old simulation state is not needed anymore. */ struct OutputMove { float delta_time; diff --git a/source/blender/python/mathutils/mathutils.h b/source/blender/python/mathutils/mathutils.h index 676a64ea40b..3bd079ec308 100644 --- a/source/blender/python/mathutils/mathutils.h +++ b/source/blender/python/mathutils/mathutils.h @@ -96,9 +96,9 @@ typedef int (*BaseMathCheckFunc)(BaseMathObject *); typedef int (*BaseMathGetFunc)(BaseMathObject *, int); /** Sets the users vector values once its modified. */ typedef int (*BaseMathSetFunc)(BaseMathObject *, int); -/** Same as above but only for an index. */ +/** Same as #BaseMathGetFunc but only for an index. */ typedef int (*BaseMathGetIndexFunc)(BaseMathObject *, int, int); -/** Same as above but only for an index. */ +/** Same as #BaseMathSetFunc but only for an index. */ typedef int (*BaseMathSetIndexFunc)(BaseMathObject *, int, int); struct Mathutils_Callback {