diff options
author | Campbell Barton <ideasman42@gmail.com> | 2021-12-10 13:42:06 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2021-12-10 13:42:06 +0300 |
commit | bd2b48e98d77c8437b8b0c77582084a3c984e45c (patch) | |
tree | 0d9eeff42d23943f9e01d2f6dbdb158944aa41d8 /source/blender/editors/armature | |
parent | 63f8d18c0fbc8bce12c65eb6bd49ec28eef703e4 (diff) |
Cleanup: move public doc-strings into headers for various API's
Some doc-strings were skipped because of blank-lines between
the doc-string and the symbol and needed to be moved manually.
- Added space below non doc-string comments to make it clear
these aren't comments for the symbols directly below them.
- Use doxy sections for some headers.
Ref T92709
Diffstat (limited to 'source/blender/editors/armature')
-rw-r--r-- | source/blender/editors/armature/armature_add.c | 7 | ||||
-rw-r--r-- | source/blender/editors/armature/armature_edit.c | 8 | ||||
-rw-r--r-- | source/blender/editors/armature/armature_intern.h | 80 | ||||
-rw-r--r-- | source/blender/editors/armature/armature_naming.c | 14 | ||||
-rw-r--r-- | source/blender/editors/armature/armature_ops.c | 3 | ||||
-rw-r--r-- | source/blender/editors/armature/armature_relations.c | 1 | ||||
-rw-r--r-- | source/blender/editors/armature/armature_select.c | 14 | ||||
-rw-r--r-- | source/blender/editors/armature/armature_utils.c | 84 | ||||
-rw-r--r-- | source/blender/editors/armature/editarmature_undo.c | 1 | ||||
-rw-r--r-- | source/blender/editors/armature/pose_edit.c | 9 | ||||
-rw-r--r-- | source/blender/editors/armature/pose_select.c | 16 | ||||
-rw-r--r-- | source/blender/editors/armature/pose_utils.c | 13 |
12 files changed, 108 insertions, 142 deletions
diff --git a/source/blender/editors/armature/armature_add.c b/source/blender/editors/armature/armature_add.c index 21a5c6c2865..02ecfdb4ea6 100644 --- a/source/blender/editors/armature/armature_add.c +++ b/source/blender/editors/armature/armature_add.c @@ -64,8 +64,6 @@ /* *************** Adding stuff in editmode *************** */ -/* default bone add, returns it selected, but without tail set */ -/* XXX should be used everywhere, now it mallocs bones still locally in functions */ EditBone *ED_armature_ebone_add(bArmature *arm, const char *name) { EditBone *bone = MEM_callocN(sizeof(EditBone), "eBone"); @@ -274,7 +272,6 @@ void ARMATURE_OT_click_extrude(wmOperatorType *ot) /* props */ } -/* adds an EditBone between the nominated locations (should be in the right space) */ EditBone *add_points_bone(Object *obedit, float head[3], float tail[3]) { EditBone *ebo; @@ -302,7 +299,6 @@ static EditBone *get_named_editbone(ListBase *edbo, const char *name) return NULL; } -/* Call this before doing any duplications. */ void preEditBoneDuplicate(ListBase *editbones) { /* clear temp */ @@ -1317,9 +1313,10 @@ static int armature_symmetrize_exec(bContext *C, wmOperator *op) return OPERATOR_FINISHED; } -/* following conventions from #MESH_OT_symmetrize */ void ARMATURE_OT_symmetrize(wmOperatorType *ot) { + /* NOTE: following conventions from #MESH_OT_symmetrize */ + /* subset of 'rna_enum_symmetrize_direction_items' */ static const EnumPropertyItem arm_symmetrize_direction_items[] = { {-1, "NEGATIVE_X", 0, "-X to +X", ""}, diff --git a/source/blender/editors/armature/armature_edit.c b/source/blender/editors/armature/armature_edit.c index fd5ae6c7099..b709980cabe 100644 --- a/source/blender/editors/armature/armature_edit.c +++ b/source/blender/editors/armature/armature_edit.c @@ -66,9 +66,6 @@ /* NOTE: these functions are exported to the Object module to be called from the tools there */ -/** - * See #BKE_armature_transform for object-mode transform. - */ void ED_armature_edit_transform(bArmature *arm, const float mat[4][4], const bool do_props) { EditBone *ebone; @@ -116,8 +113,6 @@ void ED_armature_transform(bArmature *arm, const float mat[4][4], const bool do_ } } -/* exported for use in editors/object/ */ -/* 0 == do center, 1 == center new, 2 == center cursor */ void ED_armature_origin_set( Main *bmain, Object *ob, const float cursor[3], int centermode, int around) { @@ -186,9 +181,6 @@ void ED_armature_origin_set( /** \name Bone Roll Calculate Operator * \{ */ -/* adjust bone roll to align Z axis with vector - * vec is in local space and is normalized - */ float ED_armature_ebone_roll_to_vector(const EditBone *bone, const float align_axis[3], const bool axis_only) diff --git a/source/blender/editors/armature/armature_intern.h b/source/blender/editors/armature/armature_intern.h index 3a6761ba915..77607cedcb1 100644 --- a/source/blender/editors/armature/armature_intern.h +++ b/source/blender/editors/armature/armature_intern.h @@ -39,8 +39,10 @@ struct bArmature; struct LinkData; struct ListBase; -/* ******************************************************* */ -/* Armature EditMode Operators */ +/* -------------------------------------------------------------------- */ +/** \name Armature EditMode Operators + * \{ */ + void ARMATURE_OT_bone_primitive_add(struct wmOperatorType *ot); void ARMATURE_OT_align(struct wmOperatorType *ot); @@ -82,8 +84,12 @@ void ARMATURE_OT_layers_show_all(struct wmOperatorType *ot); void ARMATURE_OT_armature_layers(struct wmOperatorType *ot); void ARMATURE_OT_bone_layers(struct wmOperatorType *ot); -/* ******************************************************* */ -/* Pose-Mode Operators */ +/** \} */ + +/* -------------------------------------------------------------------- */ +/** \name Pose-Mode Operators + * \{ */ + void POSE_OT_hide(struct wmOperatorType *ot); void POSE_OT_reveal(struct wmOperatorType *ot); @@ -131,8 +137,12 @@ void POSE_OT_quaternions_flip(struct wmOperatorType *ot); void POSE_OT_bone_layers(struct wmOperatorType *ot); -/* ******************************************************* */ -/* Pose Tool Utilities (for PoseLib, Pose Sliding, etc.) */ +/** \} */ + +/* -------------------------------------------------------------------- */ +/** \name Pose Tool Utilities (for PoseLib, Pose Sliding, etc.) + * \{ */ + /* pose_utils.c */ /* Temporary data linking PoseChannels with the F-Curves they affect */ @@ -173,21 +183,39 @@ typedef struct tPChanFCurveLink { /* ----------- */ +/** Returns a valid pose armature for this object, else returns NULL. */ struct Object *poseAnim_object_get(struct Object *ob_); +/** Get sets of F-Curves providing transforms for the bones in the Pose. */ void poseAnim_mapping_get(struct bContext *C, ListBase *pfLinks); +/** Free F-Curve <-> PoseChannel links. */ void poseAnim_mapping_free(ListBase *pfLinks); +/** + * Helper for apply() / reset() - refresh the data. + */ void poseAnim_mapping_refresh(struct bContext *C, struct Scene *scene, struct Object *ob); +/** + * Reset changes made to current pose. + */ void poseAnim_mapping_reset(ListBase *pfLinks); +/** Perform auto-key-framing after changes were made + confirmed. */ void poseAnim_mapping_autoKeyframe(struct bContext *C, struct Scene *scene, ListBase *pfLinks, float cframe); +/** + * Find the next F-Curve for a PoseChannel with matching path... + * - path is not just the pfl rna_path, since that path doesn't have property info yet. + */ LinkData *poseAnim_mapping_getNextFCurve(ListBase *fcuLinks, LinkData *prev, const char *path); -/* ******************************************************* */ -/* PoseLib */ +/** \} */ + +/* -------------------------------------------------------------------- */ +/** \name PoseLib + * \{ */ + /* pose_lib.c */ void POSELIB_OT_new(struct wmOperatorType *ot); @@ -207,8 +235,12 @@ void POSELIB_OT_apply_pose(struct wmOperatorType *ot); void POSELIB_OT_apply_pose_asset(struct wmOperatorType *ot); void POSELIB_OT_blend_pose_asset(struct wmOperatorType *ot); -/* ******************************************************* */ -/* Pose Sliding Tools */ +/** \} */ + +/* -------------------------------------------------------------------- */ +/** \name Pose Sliding Tools + * \{ */ + /* pose_slide.c */ void POSE_OT_push(struct wmOperatorType *ot); @@ -220,8 +252,11 @@ void POSE_OT_blend_to_neighbors(struct wmOperatorType *ot); void POSE_OT_propagate(struct wmOperatorType *ot); -/* ******************************************************* */ -/* Various Armature Edit/Pose Editing API's */ +/** \} */ + +/* -------------------------------------------------------------------- */ +/** \name Various Armature Edit/Pose Editing API's + * \{ */ /* Ideally, many of these defines would not be needed as everything would be strictly * self-contained within each file, @@ -232,7 +267,9 @@ struct EditBone *make_boneList(struct ListBase *edbo, struct ListBase *bones, struct Bone *actBone); -/* duplicate method */ +/* Duplicate method. */ + +/** Call this before doing any duplications. */ void preEditBoneDuplicate(struct ListBase *editbones); void postEditBoneDuplicate(struct ListBase *editbones, struct Object *ob); struct EditBone *duplicateEditBone(struct EditBone *cur_bone, @@ -240,20 +277,29 @@ struct EditBone *duplicateEditBone(struct EditBone *cur_bone, struct ListBase *editbones, struct Object *ob); -/* duplicate method (cross objects) */ -/* editbones is the target list */ +/* Duplicate method (cross objects). */ + +/** + * \param editbones: The target list. + */ struct EditBone *duplicateEditBoneObjects(struct EditBone *cur_bone, const char *name, struct ListBase *editbones, struct Object *src_ob, struct Object *dst_ob); +/** Adds an EditBone between the nominated locations (should be in the right space). */ struct EditBone *add_points_bone(struct Object *obedit, float head[3], float tail[3]); void bone_free(struct bArmature *arm, struct EditBone *bone); void armature_tag_select_mirrored(struct bArmature *arm); +/** + * Helper function for tools to work on mirrored parts. + * it leaves mirrored bones selected then too, which is a good indication of what happened. + */ void armature_select_mirrored_ex(struct bArmature *arm, const int flag); void armature_select_mirrored(struct bArmature *arm); +/** Only works when tagged. */ void armature_tag_unselect(struct bArmature *arm); struct EditBone *ED_armature_pick_ebone(struct bContext *C, @@ -291,6 +337,10 @@ struct Bone *ED_armature_pick_bone_from_selectbuffer(struct Base **bases, bool do_nearest, struct Base **r_base); +/** + * XXX: bone_looper is only to be used when we want to access settings + * (i.e. editability/visibility/selected) that context doesn't offer. + */ int bone_looper(struct Object *ob, struct Bone *bone, void *data, diff --git a/source/blender/editors/armature/armature_naming.c b/source/blender/editors/armature/armature_naming.c index 9d251c52217..750c64d74a7 100644 --- a/source/blender/editors/armature/armature_naming.c +++ b/source/blender/editors/armature/armature_naming.c @@ -80,7 +80,6 @@ static bool editbone_unique_check(void *arg, const char *name) return dupli && dupli != data->bone; } -/* If bone is already in list, pass it as param to ignore it. */ void ED_armature_ebone_unique_name(ListBase *ebones, char *name, EditBone *bone) { struct { @@ -154,9 +153,6 @@ static void constraint_bone_name_fix(Object *ob, } } -/* called by UI for renaming a bone */ -/* warning: make sure the original bone was not renamed yet! */ -/* seems messy, but that's what you get with not using pointers but channel names :) */ void ED_armature_bone_rename(Main *bmain, bArmature *arm, const char *oldnamep, @@ -395,16 +391,6 @@ typedef struct BoneFlipNameData { char name_flip[MAXBONENAME]; } BoneFlipNameData; -/** - * Renames (by flipping) all selected bones at once. - * - * This way if we are flipping related bones (e.g., Bone.L, Bone.R) at the same time - * all the bones are safely renamed, without conflicting with each other. - * - * \param arm: Armature the bones belong to - * \param bones_names: List of BoneConflict elems. - * \param do_strip_numbers: if set, try to get rid of dot-numbers at end of bone names. - */ void ED_armature_bones_flip_names(Main *bmain, bArmature *arm, ListBase *bones_names, diff --git a/source/blender/editors/armature/armature_ops.c b/source/blender/editors/armature/armature_ops.c index 75b0455d026..364e778fc2e 100644 --- a/source/blender/editors/armature/armature_ops.c +++ b/source/blender/editors/armature/armature_ops.c @@ -33,9 +33,10 @@ /* ************************** registration **********************************/ -/* Both operators ARMATURE_OT_xxx and POSE_OT_xxx here */ void ED_operatortypes_armature(void) { + /* Both operators `ARMATURE_OT_*` and `POSE_OT_*` are registered here. */ + /* EDIT ARMATURE */ WM_operatortype_append(ARMATURE_OT_bone_primitive_add); diff --git a/source/blender/editors/armature/armature_relations.c b/source/blender/editors/armature/armature_relations.c index b06e4b6a9e7..eebe8a447f7 100644 --- a/source/blender/editors/armature/armature_relations.c +++ b/source/blender/editors/armature/armature_relations.c @@ -269,7 +269,6 @@ static void joined_armature_fix_links( } } -/* join armature exec is exported for use in object->join objects operator... */ int ED_armature_join_objects_exec(bContext *C, wmOperator *op) { Main *bmain = CTX_data_main(C); diff --git a/source/blender/editors/armature/armature_select.c b/source/blender/editors/armature/armature_select.c index 937385f9ffa..5e4cb813064 100644 --- a/source/blender/editors/armature/armature_select.c +++ b/source/blender/editors/armature/armature_select.c @@ -139,7 +139,6 @@ Base *ED_armature_base_and_pchan_from_select_buffer(Base **bases, return base; } -/* For callers that don't need the pose channel. */ Base *ED_armature_base_and_bone_from_select_buffer(Base **bases, uint bases_len, int hit, @@ -1080,7 +1079,6 @@ bool ED_armature_edit_select_pick_bone(bContext *C, return true; } -/* context: editmode armature in view3d */ bool ED_armature_edit_select_pick( bContext *C, const int mval[2], bool extend, bool deselect, bool toggle) { @@ -1175,18 +1173,6 @@ static bool armature_edit_select_op_apply(bArmature *arm, return changed; } -/** - * Perform a selection operation on elements which have been 'touched', - * use for lasso & border select but can be used elsewhere too. - * - * Tagging is done via #EditBone.temp.i using: #BONESEL_ROOT, #BONESEL_TIP, #BONESEL_BONE - * And optionally ignoring end-points using the #BONESEL_ROOT, #BONESEL_TIP right shifted 16 bits. - * (used when the values are clipped outside the view). - * - * \param sel_op: #eSelectOp type. - * - * \note Visibility checks must be done by the caller. - */ bool ED_armature_edit_select_op_from_tagged(bArmature *arm, const int sel_op) { bool changed = false; diff --git a/source/blender/editors/armature/armature_utils.c b/source/blender/editors/armature/armature_utils.c index 4fe4422e4e0..1c48285563d 100644 --- a/source/blender/editors/armature/armature_utils.c +++ b/source/blender/editors/armature/armature_utils.c @@ -45,10 +45,10 @@ #include "armature_intern.h" -/* *************************************************************** */ -/* Validation */ +/* -------------------------------------------------------------------- */ +/** \name Validation + * \{ */ -/* Sync selection to parent for connected children */ void ED_armature_edit_sync_selection(ListBase *edbo) { EditBone *ebo; @@ -86,10 +86,6 @@ void ED_armature_edit_validate_active(struct bArmature *arm) } } -/* Update the layers_used variable after bones are moved between layer - * NOTE: Used to be done in drawing code in 2.7, but that won't work with - * Copy-on-Write, as drawing uses evaluated copies. - */ void ED_armature_edit_refresh_layer_used(bArmature *arm) { arm->layer_used = 0; @@ -98,11 +94,12 @@ void ED_armature_edit_refresh_layer_used(bArmature *arm) } } -/* *************************************************************** */ -/* Bone Operations */ +/** \} */ + +/* -------------------------------------------------------------------- */ +/** \name Bone Operations + * \{ */ -/* XXX bone_looper is only to be used when we want to access settings - * (i.e. editability/visibility/selected) that context doesn't offer */ int bone_looper(Object *ob, Bone *bone, void *data, int (*bone_func)(Object *, Bone *, void *)) { /* We want to apply the function bone_func to every bone @@ -129,8 +126,11 @@ int bone_looper(Object *ob, Bone *bone, void *data, int (*bone_func)(Object *, B return count; } -/* *************************************************************** */ -/* Bone Removal */ +/** \} */ + +/* -------------------------------------------------------------------- */ +/** \name Bone Removal + * \{ */ void bone_free(bArmature *arm, EditBone *bone) { @@ -155,9 +155,6 @@ void bone_free(bArmature *arm, EditBone *bone) BLI_freelinkN(arm->edbo, bone); } -/** - * \param clear_connected: When false caller is responsible for keeping the flag in a valid state. - */ void ED_armature_ebone_remove_ex(bArmature *arm, EditBone *exBone, bool clear_connected) { EditBone *curBone; @@ -190,13 +187,6 @@ bool ED_armature_ebone_is_child_recursive(EditBone *ebone_parent, EditBone *ebon return false; } -/** - * Finds the first parent shared by \a ebone_child - * - * \param ebone_child: Children bones to search - * \param ebone_child_tot: Size of the ebone_child array - * \return The shared parent or NULL. - */ EditBone *ED_armature_ebone_find_shared_parent(EditBone *ebone_child[], const uint ebone_child_tot) { #define EBONE_TEMP_UINT(ebone) (*((uint *)(&((ebone)->temp)))) @@ -284,20 +274,17 @@ void ED_armature_ebone_from_mat4(EditBone *ebone, const float mat[4][4]) ED_armature_ebone_from_mat3(ebone, mat3); } -/** - * Return a pointer to the bone of the given name - */ EditBone *ED_armature_ebone_find_name(const ListBase *edbo, const char *name) { return BLI_findstring(edbo, name, offsetof(EditBone, name)); } -/* *************************************************************** */ -/* Mirroring */ +/** \} */ + +/* -------------------------------------------------------------------- */ +/** \name Mirroring + * \{ */ -/** - * \see #BKE_pose_channel_get_mirrored (pose-mode, matching function) - */ EditBone *ED_armature_ebone_get_mirrored(const ListBase *edbo, EditBone *ebo) { char name_flip[MAXBONENAME]; @@ -317,8 +304,6 @@ EditBone *ED_armature_ebone_get_mirrored(const ListBase *edbo, EditBone *ebo) /* ------------------------------------- */ -/* helper function for tools to work on mirrored parts. - * it leaves mirrored bones selected then too, which is a good indication of what happened */ void armature_select_mirrored_ex(bArmature *arm, const int flag) { BLI_assert((flag & ~(BONE_SELECTED | BONE_ROOTSEL | BONE_TIPSEL)) == 0); @@ -375,7 +360,6 @@ void armature_tag_select_mirrored(bArmature *arm) } } -/* only works when tagged */ void armature_tag_unselect(bArmature *arm) { EditBone *curBone; @@ -465,8 +449,6 @@ void ED_armature_ebone_transform_mirror_update(bArmature *arm, EditBone *ebo, bo } } -/* if editbone (partial) selected, copy data */ -/* context; editmode armature, with mirror editing enabled */ void ED_armature_edit_transform_mirror_update(Object *obedit) { bArmature *arm = obedit->data; @@ -475,8 +457,11 @@ void ED_armature_edit_transform_mirror_update(Object *obedit) } } -/* *************************************************************** */ -/* Armature EditMode Conversions */ +/** \} */ + +/* -------------------------------------------------------------------- */ +/** \name Armature EditMode Conversions + * \{ */ /* converts Bones to EditBone list, used for tools as well */ static EditBone *make_boneList_recursive(ListBase *edbo, @@ -688,7 +673,6 @@ static void armature_finalize_restpose(ListBase *bonelist, ListBase *editbonelis } } -/* put EditMode back in Object */ void ED_armature_from_edit(Main *bmain, bArmature *arm) { EditBone *eBone, *neBone; @@ -838,7 +822,6 @@ void ED_armature_edit_free(struct bArmature *arm) } } -/* Put armature in EditMode */ void ED_armature_to_edit(bArmature *arm) { ED_armature_edit_free(arm); @@ -846,10 +829,11 @@ void ED_armature_to_edit(bArmature *arm) arm->act_edbone = make_boneList(arm->edbo, &arm->bonebase, arm->act_bone); } -/* *************************************************************** */ -/* Used by Undo for Armature EditMode. */ +/** \} */ -/* free's bones and their properties */ +/* -------------------------------------------------------------------- */ +/** \name Used by Undo for Armature EditMode + * \{ */ void ED_armature_ebone_listbase_free(ListBase *lb, const bool do_id_user) { @@ -908,10 +892,14 @@ void ED_armature_ebone_listbase_temp_clear(ListBase *lb) } } -/* *************************************************************** */ -/* Low level selection functions which hide connected-parent - * flag behavior which gets tricky to handle in selection operators. - * (no flushing in ED_armature_ebone_select.*, that should be explicit) */ +/** \} */ + +/* -------------------------------------------------------------------- */ +/** \name Low Level Selection Functions + * + * which hide connected-parent flag behavior which gets tricky to handle in selection operators. + * (no flushing in `ED_armature_ebone_select.*`, that should be explicit). + * \{ */ int ED_armature_ebone_selectflag_get(const EditBone *ebone) { @@ -964,3 +952,5 @@ void ED_armature_ebone_select_set(EditBone *ebone, bool select) } ED_armature_ebone_selectflag_set(ebone, flag); } + +/** \} */ diff --git a/source/blender/editors/armature/editarmature_undo.c b/source/blender/editors/armature/editarmature_undo.c index 832e75b2a8b..9117dfe892f 100644 --- a/source/blender/editors/armature/editarmature_undo.c +++ b/source/blender/editors/armature/editarmature_undo.c @@ -244,7 +244,6 @@ static void armature_undosys_foreach_ID_ref(UndoStep *us_p, } } -/* Export for ED_undo_sys. */ void ED_armature_undosys_type(UndoType *ut) { ut->name = "Edit Armature"; diff --git a/source/blender/editors/armature/pose_edit.c b/source/blender/editors/armature/pose_edit.c index 20d7baa39ed..772fe8f3196 100644 --- a/source/blender/editors/armature/pose_edit.c +++ b/source/blender/editors/armature/pose_edit.c @@ -72,9 +72,10 @@ # include "PIL_time_utildefines.h" #endif -/* matches logic with ED_operator_posemode_context() */ Object *ED_pose_object_from_context(bContext *C) { + /* NOTE: matches logic with #ED_operator_posemode_context(). */ + ScrArea *area = CTX_wm_area(C); Object *ob; @@ -90,7 +91,6 @@ Object *ED_pose_object_from_context(bContext *C) return ob; } -/* This function is used to process the necessary updates for */ bool ED_object_posemode_enter_ex(struct Main *bmain, Object *ob) { BLI_assert(!ID_IS_LINKED(ob)); @@ -195,11 +195,6 @@ static eAnimvizCalcRange pose_path_convert_range(ePosePathCalcRange range) return ANIMVIZ_CALC_RANGE_FULL; } -/* For the object with pose/action: update paths for those that have got them - * This should selectively update paths that exist... - * - * To be called from various tools that do incremental updates - */ void ED_pose_recalculate_paths(bContext *C, Scene *scene, Object *ob, ePosePathCalcRange range) { /* Transform doesn't always have context available to do update. */ diff --git a/source/blender/editors/armature/pose_select.c b/source/blender/editors/armature/pose_select.c index e5b8983af93..17347aa57fe 100644 --- a/source/blender/editors/armature/pose_select.c +++ b/source/blender/editors/armature/pose_select.c @@ -108,7 +108,6 @@ void ED_pose_bone_select_tag_update(Object *ob) DEG_id_tag_update(&arm->id, ID_RECALC_SELECT); } -/* Utility method for changing the selection status of a bone */ void ED_pose_bone_select(Object *ob, bPoseChannel *pchan, bool select) { bArmature *arm; @@ -238,10 +237,6 @@ void ED_armature_pose_select_pick_bone(ViewLayer *view_layer, } } -/** - * Called for mode-less pose selection. - * assumes the active object is still on old situation. - */ bool ED_armature_pose_select_pick_with_buffer(ViewLayer *view_layer, View3D *v3d, Base *base, @@ -269,14 +264,6 @@ bool ED_armature_pose_select_pick_with_buffer(ViewLayer *view_layer, return nearBone != NULL; } -/** - * While in weight-paint mode, a single pose may be active as well. - * While not common, it's possible we have multiple armatures deforming a mesh. - * - * This function de-selects all other objects, and selects the new base. - * It can't be set to the active object because we need - * to keep this set to the weight paint object. - */ void ED_armature_pose_select_in_wpaint_mode(ViewLayer *view_layer, Base *base_select) { BLI_assert(base_select && (base_select->object->type == OB_ARMATURE)); @@ -323,9 +310,6 @@ void ED_armature_pose_select_in_wpaint_mode(ViewLayer *view_layer, Base *base_se } } -/* 'select_mode' is usual SEL_SELECT/SEL_DESELECT/SEL_TOGGLE/SEL_INVERT. - * When true, 'ignore_visibility' makes this func also affect invisible bones - * (hidden or on hidden layers). */ bool ED_pose_deselect_all(Object *ob, int select_mode, const bool ignore_visibility) { bArmature *arm = ob->data; diff --git a/source/blender/editors/armature/pose_utils.c b/source/blender/editors/armature/pose_utils.c index 500b9663a6c..19a5348dbc0 100644 --- a/source/blender/editors/armature/pose_utils.c +++ b/source/blender/editors/armature/pose_utils.c @@ -132,9 +132,6 @@ static void fcurves_to_pchan_links_get(ListBase *pfLinks, } } -/** - * Returns a valid pose armature for this object, else returns NULL. - */ Object *poseAnim_object_get(Object *ob_) { Object *ob = BKE_object_pose_armature_get(ob_); @@ -144,9 +141,6 @@ Object *poseAnim_object_get(Object *ob_) return NULL; } -/** - * Get sets of F-Curves providing transforms for the bones in the Pose. - */ void poseAnim_mapping_get(bContext *C, ListBase *pfLinks) { /* for each Pose-Channel which gets affected, get the F-Curves for that channel @@ -192,7 +186,6 @@ void poseAnim_mapping_get(bContext *C, ListBase *pfLinks) } } -/* Free F-Curve <-> PoseChannel links. */ void poseAnim_mapping_free(ListBase *pfLinks) { tPChanFCurveLink *pfl, *pfln = NULL; @@ -219,7 +212,6 @@ void poseAnim_mapping_free(ListBase *pfLinks) /* ------------------------- */ -/* helper for apply() / reset() - refresh the data */ void poseAnim_mapping_refresh(bContext *C, Scene *UNUSED(scene), Object *ob) { DEG_id_tag_update(&ob->id, ID_RECALC_GEOMETRY); @@ -231,7 +223,6 @@ void poseAnim_mapping_refresh(bContext *C, Scene *UNUSED(scene), Object *ob) } } -/* reset changes made to current pose */ void poseAnim_mapping_reset(ListBase *pfLinks) { tPChanFCurveLink *pfl; @@ -268,7 +259,6 @@ void poseAnim_mapping_reset(ListBase *pfLinks) } } -/* perform auto-key-framing after changes were made + confirmed */ void poseAnim_mapping_autoKeyframe(bContext *C, Scene *scene, ListBase *pfLinks, float cframe) { ViewLayer *view_layer = CTX_data_view_layer(C); @@ -337,9 +327,6 @@ void poseAnim_mapping_autoKeyframe(bContext *C, Scene *scene, ListBase *pfLinks, /* ------------------------- */ -/* find the next F-Curve for a PoseChannel with matching path... - * - path is not just the pfl rna_path, since that path doesn't have property info yet - */ LinkData *poseAnim_mapping_getNextFCurve(ListBase *fcuLinks, LinkData *prev, const char *path) { LinkData *first = (prev) ? prev->next : (fcuLinks) ? fcuLinks->first : NULL; |