Blender V5.0
ED_keyframing.hh
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2008 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
8
9#pragma once
10
11#include "DNA_anim_types.h"
12#include "RNA_types.hh"
13
14struct ID;
15struct Main;
16struct Scene;
17
18struct KeyingSet;
19
21struct FCurve;
22
23struct ReportList;
24struct bContext;
25
26struct EnumPropertyItem;
27struct PointerRNA;
28struct PropertyRNA;
29
30namespace blender::animrig {
31enum class ModifyKeyReturn;
32enum class ModifyKeyMode;
33} // namespace blender::animrig
34
35/* -------------------------------------------------------------------- */
38
46
47/* -------- */
48
58void ED_keyframes_add(FCurve *fcu, int num_keys_to_add);
59
61
62/* -------------------------------------------------------------------- */
65
69int ANIM_scene_get_keyingset_index(Scene *scene, KeyingSet *keyingset);
70
72 const bContext *C,
74 PropertyRNA *prop,
75 const char *edit_text,
77
79 const bContext *C,
81 PropertyRNA *prop,
82 const char *edit_text,
84
90 PropertyRNA *prop,
91 bool *r_free);
92
103KeyingSet *ANIM_keyingset_get_from_idname(Scene *scene, const char *idname);
104
109
111
112/* -------------------------------------------------------------------- */
115
121
138
144
145/* -------- */
146
155
164 const char rna_path[],
165 int array_index,
166 eDriverFCurveCreationMode creation_mode);
167
168FCurve *alloc_driver_fcurve(const char rna_path[],
169 int array_index,
170 eDriverFCurveCreationMode creation_mode);
171
172/* -------- */
173
188 ID *dst_id,
189 const char dst_path[],
190 int dst_index,
191 ID *src_id,
192 const char src_path[],
193 int src_index,
194 short flag,
195 int driver_type,
196 short mapping_type);
197
198/* -------- */
199
209 ReportList *reports, ID *id, const char rna_path[], int array_index, short flag, int type);
210
218bool ANIM_remove_driver(ID *id, const char rna_path[], int array_index);
219
220/* -------- */
221
227
233
234/* -------- */
235
240
247 ReportList *reports, ID *id, const char rna_path[], int array_index, short flag);
248
256 ReportList *reports, ID *id, const char rna_path[], int array_index, short flag);
257
258/* -------- */
259
264
268bool ANIM_driver_vars_copy(ReportList *reports, FCurve *fcu);
269
273bool ANIM_driver_vars_paste(ReportList *reports, FCurve *fcu, bool replace);
274
275/* -------- */
276
281void ANIM_copy_as_driver(ID *target_id, const char *target_path, const char *var_name);
282
284
285/* -------------------------------------------------------------------- */
288
296 PropertyRNA *prop,
297 FCurve *fcu,
298 const AnimationEvalContext *anim_eval_context);
299
bool ANIM_driver_vars_can_paste()
Definition drivers.cc:683
int ANIM_scene_get_keyingset_index(Scene *scene, KeyingSet *keyingset)
void ANIM_copy_as_driver(ID *target_id, const char *target_path, const char *var_name)
Definition drivers.cc:767
bool fcurve_is_changed(PointerRNA ptr, PropertyRNA *prop, FCurve *fcu, const AnimationEvalContext *anim_eval_context)
Lesser Keyframe Checking API call.
bool ANIM_paste_driver(ReportList *reports, ID *id, const char rna_path[], int array_index, short flag)
Main Driver Management API calls.
Definition drivers.cc:610
bool ANIM_driver_can_paste()
Definition drivers.cc:555
KeyingSet * ANIM_keyingset_get_from_idname(Scene *scene, const char *idname)
FCurve * verify_driver_fcurve(ID *id, const char rna_path[], int array_index, eDriverFCurveCreationMode creation_mode)
Definition drivers.cc:51
bool ANIM_copy_driver(ReportList *reports, ID *id, const char rna_path[], int array_index, short flag)
Main Driver Management API calls.
Definition drivers.cc:562
bool ANIM_driver_vars_copy(ReportList *reports, FCurve *fcu)
Definition drivers.cc:690
bool ANIM_keyingset_context_ok_poll(bContext *C, KeyingSet *keyingset)
void ED_keyframes_add(FCurve *fcu, int num_keys_to_add)
FCurve * alloc_driver_fcurve(const char rna_path[], int array_index, eDriverFCurveCreationMode creation_mode)
Definition drivers.cc:92
int ANIM_add_driver(ReportList *reports, ID *id, const char rna_path[], int array_index, short flag, int type)
Main Driver Management API calls.
Definition drivers.cc:383
int ANIM_add_driver_with_target(ReportList *reports, ID *dst_id, const char dst_path[], int dst_index, ID *src_id, const char src_path[], int src_index, short flag, int driver_type, short mapping_type)
Main Driver Management API calls.
Definition drivers.cc:272
bool ANIM_driver_vars_paste(ReportList *reports, FCurve *fcu, bool replace)
Definition drivers.cc:712
void ANIM_keyingset_visit_for_search_no_poll(const bContext *C, PointerRNA *ptr, PropertyRNA *prop, const char *edit_text, blender::FunctionRef< void(StringPropertySearchVisitParams)> visit_fn)
void ANIM_drivers_copybuf_free()
Definition drivers.cc:546
eCreateDriverFlags
@ CREATEDRIVER_WITH_DEFAULT_DVAR
eCreateDriver_MappingTypes
@ CREATEDRIVER_MAPPING_NONE_ALL
@ CREATEDRIVER_MAPPING_1_N
@ CREATEDRIVER_MAPPING_NONE
@ CREATEDRIVER_MAPPING_N_N
@ CREATEDRIVER_MAPPING_1_1
void update_autoflags_fcurve(FCurve *fcu, bContext *C, ReportList *reports, PointerRNA *ptr)
Lesser Key-framing API call.
const EnumPropertyItem * ANIM_keying_sets_enum_itemf(bContext *C, PointerRNA *ptr, PropertyRNA *prop, bool *r_free)
void ANIM_driver_vars_copybuf_free()
Definition drivers.cc:667
KeyingSet * ANIM_keyingset_get_from_enum_type(Scene *scene, int type)
eDriverFCurveCreationMode
@ DRIVER_FCURVE_LOOKUP_ONLY
@ DRIVER_FCURVE_KEYFRAMES
@ DRIVER_FCURVE_EMPTY
void ANIM_keyingset_visit_for_search(const bContext *C, PointerRNA *ptr, PropertyRNA *prop, const char *edit_text, blender::FunctionRef< void(StringPropertySearchVisitParams)> visit_fn)
bool ANIM_remove_driver(ID *id, const char rna_path[], int array_index)
Main Driver Management API calls.
Definition drivers.cc:505
#define C
Definition RandGen.cpp:29
const EnumPropertyItem prop_driver_create_mapping_types[]
Definition drivers.cc:810
Definition DNA_ID.h:414
PointerRNA * ptr
Definition wm_files.cc:4238
uint8_t flag
Definition wm_window.cc:145