Blender
V3.3
|
#include <Python.h>
#include <float.h>
#include "MEM_guardedalloc.h"
#include "BLI_string.h"
#include "BLI_string_utils.h"
#include "BLI_utildefines.h"
#include "DNA_anim_types.h"
#include "DNA_scene_types.h"
#include "ED_keyframes_edit.h"
#include "ED_keyframing.h"
#include "BKE_anim_data.h"
#include "BKE_animsys.h"
#include "BKE_context.h"
#include "BKE_fcurve.h"
#include "BKE_global.h"
#include "BKE_idtype.h"
#include "BKE_lib_id.h"
#include "BKE_report.h"
#include "RNA_access.h"
#include "RNA_enum_types.h"
#include "RNA_path.h"
#include "RNA_prototypes.h"
#include "WM_api.h"
#include "WM_types.h"
#include "bpy_capi_utils.h"
#include "bpy_rna.h"
#include "bpy_rna_anim.h"
#include "../generic/py_capi_rna.h"
#include "../generic/python_utildefines.h"
#include "DEG_depsgraph_build.h"
Go to the source code of this file.
Functions | |
static int | pyrna_struct_anim_args_parse_ex (PointerRNA *ptr, const char *error_prefix, const char *path, const char **r_path_full, int *r_index, bool *r_path_no_validate) |
static int | pyrna_struct_anim_args_parse (PointerRNA *ptr, const char *error_prefix, const char *path, const char **r_path_full, int *r_index) |
static int | pyrna_struct_anim_args_parse_no_resolve (PointerRNA *ptr, const char *error_prefix, const char *path, const char **r_path_full) |
static int | pyrna_struct_anim_args_parse_no_resolve_fallback (PointerRNA *ptr, const char *error_prefix, const char *path, const char **r_path_full, int *r_index) |
static int | pyrna_struct_keyframe_parse (PointerRNA *ptr, PyObject *args, PyObject *kw, const char *parse_str, const char *error_prefix, const char **r_path_full, int *r_index, float *r_cfra, const char **r_group_name, int *r_options) |
PyObject * | pyrna_struct_keyframe_insert (BPy_StructRNA *self, PyObject *args, PyObject *kw) |
PyObject * | pyrna_struct_keyframe_delete (BPy_StructRNA *self, PyObject *args, PyObject *kw) |
PyObject * | pyrna_struct_driver_add (BPy_StructRNA *self, PyObject *args) |
PyObject * | pyrna_struct_driver_remove (BPy_StructRNA *self, PyObject *args) |
Variables | |
char | pyrna_struct_keyframe_insert_doc [] |
char | pyrna_struct_keyframe_delete_doc [] |
char | pyrna_struct_driver_add_doc [] |
char | pyrna_struct_driver_remove_doc [] |
This file defines the animation related methods used in bpy_rna.c
Definition in file bpy_rna_anim.c.
|
static |
Definition at line 151 of file bpy_rna_anim.c.
References NULL, ptr, and pyrna_struct_anim_args_parse_ex().
Referenced by pyrna_struct_driver_add(), and pyrna_struct_keyframe_parse().
|
static |
Definition at line 51 of file bpy_rna_anim.c.
References BLI_strdup(), PointerRNA::data, NULL, PointerRNA::owner_id, ptr, RNA_path_from_ID_to_property(), RNA_path_resolve_property_full(), RNA_property_animateable(), RNA_property_array_check(), RNA_property_array_length(), RNA_struct_find_property(), RNA_struct_is_ID(), and PointerRNA::type.
Referenced by pyrna_struct_anim_args_parse(), and pyrna_struct_anim_args_parse_no_resolve_fallback().
|
static |
Unlike pyrna_struct_anim_args_parse r_path_full may be copied from path.
Definition at line 163 of file bpy_rna_anim.c.
References BLI_string_join_by_sep_charN, BLI_string_joinN, MEM_freeN, NULL, ptr, RNA_path_from_ID_to_struct(), RNA_struct_identifier(), RNA_struct_is_ID(), and PointerRNA::type.
Referenced by pyrna_struct_anim_args_parse_no_resolve_fallback().
|
static |
Definition at line 194 of file bpy_rna_anim.c.
References ptr, pyrna_struct_anim_args_parse_ex(), and pyrna_struct_anim_args_parse_no_resolve().
Referenced by pyrna_struct_driver_remove().
PyObject* pyrna_struct_driver_add | ( | BPy_StructRNA * | self, |
PyObject * | args | ||
) |
Definition at line 527 of file bpy_rna_anim.c.
References ANIM_add_driver(), BKE_animdata_from_id(), BKE_fcurve_find(), BKE_reports_init(), BPY_context_get(), BPy_reports_to_error(), blender::compositor::context, CREATEDRIVER_WITH_FMODIFIER, CTX_data_main(), DEG_relations_tag_update(), DRIVER_TYPE_PYTHON, AnimData::drivers, MEM_freeN, NC_ANIMATION, ND_FCURVES_ORDER, NULL, pyrna_struct_anim_args_parse(), PYRNA_STRUCT_CHECK_OBJ, pyrna_struct_CreatePyObject(), result, ret, RNA_pointer_create(), RPT_STORE, self, and WM_event_add_notifier().
PyObject* pyrna_struct_driver_remove | ( | BPy_StructRNA * | self, |
PyObject * | args | ||
) |
Definition at line 609 of file bpy_rna_anim.c.
References ANIM_remove_driver(), BKE_reports_init(), BPY_context_get(), BPy_reports_to_error(), blender::compositor::context, CTX_data_main(), DEG_relations_tag_update(), MEM_freeN, NC_ANIMATION, ND_FCURVES_ORDER, NULL, pyrna_struct_anim_args_parse_no_resolve_fallback(), PYRNA_STRUCT_CHECK_OBJ, result, RPT_STORE, self, and WM_event_add_notifier().
PyObject* pyrna_struct_keyframe_delete | ( | BPy_StructRNA * | self, |
PyObject * | args, | ||
PyObject * | kw | ||
) |
Definition at line 418 of file bpy_rna_anim.c.
References FCurve::bezt, BKE_fcurve_bezt_binarysearch_index(), BKE_fcurve_delete_key(), BKE_fcurve_find(), BKE_fcurve_handles_recalc(), BKE_fcurve_is_protected(), BKE_idtype_idcode_to_name(), BKE_reportf(), BKE_reports_init(), BLI_assert, BPy_reports_to_error(), PointerRNA::data, delete_keyframe(), NlaStrip::fcurves, G, GS, id, MEM_freeN, NlaStrip::name, ID::name, NULL, PointerRNA::owner_id, ptr, PYRNA_STRUCT_CHECK_OBJ, pyrna_struct_keyframe_parse(), result, RNA_property_identifier(), RNA_struct_find_property(), RPT_ERROR, RPT_STORE, RPT_WARNING, self, and FCurve::totvert.
PyObject* pyrna_struct_keyframe_insert | ( | BPy_StructRNA * | self, |
PyObject * | args, | ||
PyObject * | kw | ||
) |
Definition at line 301 of file bpy_rna_anim.c.
References BEZT_KEYTYPE_KEYFRAME, BKE_animsys_eval_context_construct(), BKE_fcurve_find(), BKE_id_is_in_global_main(), BKE_reportf(), BKE_reports_init(), BLI_assert, BPY_context_get(), BPy_reports_to_error(), C, CTX_data_depsgraph_pointer(), PointerRNA::data, depsgraph, NlaStrip::fcurves, G_MAIN, insert_keyframe(), insert_keyframe_direct(), MEM_freeN, NA_EDITED, NC_ANIMATION, ND_ANIMCHAN, NULL, options, ptr, PYRNA_STRUCT_CHECK_OBJ, pyrna_struct_keyframe_parse(), result, RNA_property_identifier(), RNA_struct_find_property(), RPT_ERROR, RPT_STORE, self, and WM_event_add_notifier().
|
static |
Definition at line 216 of file bpy_rna_anim.c.
References BPY_context_get(), RenderData::cfra, CTX_data_scene(), INSERTKEY_NO_USERPREF, NULL, ptr, pyrna_enum_bitfield_from_set(), pyrna_struct_anim_args_parse(), Scene::r, and rna_enum_keying_flag_items_api.
Referenced by pyrna_struct_keyframe_delete(), and pyrna_struct_keyframe_insert().
char pyrna_struct_driver_add_doc[] |
Definition at line 515 of file bpy_rna_anim.c.
char pyrna_struct_driver_remove_doc[] |
Definition at line 597 of file bpy_rna_anim.c.
char pyrna_struct_keyframe_delete_doc[] |
Definition at line 399 of file bpy_rna_anim.c.
char pyrna_struct_keyframe_insert_doc[] |
Definition at line 268 of file bpy_rna_anim.c.