Blender V2.61 - r43446
|
#include <math.h>
#include <stdlib.h>
#include <string.h>
#include <float.h>
#include "MEM_guardedalloc.h"
#include "BLI_blenlib.h"
#include "BLI_math.h"
#include "BLI_utildefines.h"
#include "DNA_anim_types.h"
#include "DNA_object_types.h"
#include "DNA_scene_types.h"
#include "RNA_access.h"
#include "RNA_define.h"
#include "RNA_enum_types.h"
#include "BKE_fcurve.h"
#include "BKE_nla.h"
#include "BKE_context.h"
#include "BKE_report.h"
#include "UI_interface.h"
#include "UI_resources.h"
#include "UI_view2d.h"
#include "ED_anim_api.h"
#include "ED_keyframing.h"
#include "ED_keyframes_edit.h"
#include "ED_screen.h"
#include "ED_transform.h"
#include "ED_markers.h"
#include "WM_api.h"
#include "WM_types.h"
#include "graph_intern.h"
Go to the source code of this file.
Definition in file graph_edit.c.
#define CLEAR_CYCLIC_EXPO -2 |
Definition at line 1272 of file graph_edit.c.
Referenced by setexpo_graph_keys().
#define MAKE_CYCLIC_EXPO -1 |
Definition at line 1271 of file graph_edit.c.
Referenced by setexpo_graph_keys().
typedef struct tEulerFilter tEulerFilter |
static void bake_graph_curves | ( | bAnimContext * | ac, |
int | start, | ||
int | end | ||
) | [static] |
Definition at line 971 of file graph_edit.c.
References ANIM_animdata_filter(), ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_NODUPLIS, ANIMFILTER_SEL, BLI_freelistN(), bAnimContext::data, bAnimContext::datatype, FCurve::driver, fcurve_samplingcb_evalcurve(), fcurve_store_samples(), filter(), ListBase::first, bAnimListElem::key_data, bAnimListElem::next, and NULL.
Referenced by graphkeys_bake_exec().
static void clean_graph_keys | ( | bAnimContext * | ac, |
float | thresh | ||
) | [static] |
Definition at line 904 of file graph_edit.c.
References ANIM_animdata_filter(), ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_NODUPLIS, ANIMFILTER_SEL, BLI_freelistN(), clean_fcurve(), bAnimContext::data, bAnimContext::datatype, filter(), ListBase::first, bAnimListElem::key_data, bAnimListElem::next, and NULL.
Referenced by graphkeys_clean_exec().
static short copy_graph_keys | ( | bAnimContext * | ac | ) | [static] |
Definition at line 642 of file graph_edit.c.
References ANIM_animdata_filter(), ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_NODUPLIS, BLI_freelistN(), copy_animedit_keys(), bAnimContext::data, bAnimContext::datatype, filter(), free_anim_copybuf(), and NULL.
Referenced by graphkeys_copy_exec().
static void create_ghost_curves | ( | bAnimContext * | ac, |
int | start, | ||
int | end | ||
) | [static] |
Definition at line 280 of file graph_edit.c.
References NULL, and bAnimContext::sl.
Referenced by graphkeys_create_ghostcurves_exec().
static void delete_graph_keys | ( | bAnimContext * | ac | ) | [static] |
Definition at line 837 of file graph_edit.c.
References bAnimListElem::adt, ANIM_animdata_filter(), ANIM_fcurve_delete_from_animdata(), ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_NODUPLIS, BLI_freelistN(), bAnimContext::data, bAnimContext::datatype, delete_fcurve_keys(), filter(), ListBase::first, FMI_TYPE_GENERATE_CURVE, bAnimListElem::key_data, list_has_suitable_fmodifier(), FCurve::modifiers, bAnimListElem::next, NULL, and FCurve::totvert.
Referenced by graphkeys_delete_exec().
static void duplicate_graph_keys | ( | bAnimContext * | ac | ) | [static] |
Definition at line 768 of file graph_edit.c.
References ANIM_animdata_filter(), ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_NODUPLIS, BLI_freelistN(), bAnimContext::data, bAnimContext::datatype, duplicate_fcurve_keys(), filter(), ListBase::first, bAnimListElem::key_data, bAnimListElem::next, and NULL.
Referenced by graphkeys_duplicate_exec().
void get_graph_keyframe_extents | ( | bAnimContext * | ac, |
float * | xmin, | ||
float * | xmax, | ||
float * | ymin, | ||
float * | ymax, | ||
const short | selOnly | ||
) |
Definition at line 84 of file graph_edit.c.
References ANIM_animdata_filter(), ANIM_nla_mapping_get(), ANIM_unit_mapping_get_factor(), ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_NODUPLIS, BKE_nla_tweakedit_remap(), BLI_freelistN(), calc_fcurve_bounds(), bAnimContext::data, bAnimContext::datatype, RenderData::efra, fabsf, filter(), ListBase::first, bAnimListElem::id, if(), bAnimListElem::key_data, bAnimListElem::next, NLATIME_CONVERT_MAP, NULL, Scene::r, bAnimContext::scene, and RenderData::sfra.
Referenced by graph_main_area_draw(), graphkeys_previewrange_exec(), and graphkeys_viewall().
static int graph_fmodifier_add_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 2102 of file graph_edit.c.
References add_fmodifier(), ANIM_animdata_filter(), ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), ANIMFILTER_ACTIVE, ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_NODUPLIS, ANIMFILTER_SEL, BKE_report(), BLI_freelistN(), bAnimContext::data, bAnimListElem::data, bAnimContext::datatype, filter(), ListBase::first, FCurve::modifiers, NC_ANIMATION, bAnimListElem::next, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::ptr, wmOperator::reports, RNA_boolean_get(), RNA_enum_get(), RPT_ERROR, set_active_fmodifier(), and WM_event_add_notifier().
Referenced by GRAPH_OT_fmodifier_add().
static int graph_fmodifier_add_invoke | ( | bContext * | C, |
wmOperator * | op, | ||
wmEvent * | UNUSEDevent | ||
) | [static] |
Definition at line 2070 of file graph_edit.c.
References FMODIFIER_NUM_TYPES, get_fmodifier_typeinfo(), i, FModifierTypeInfo::name, NULL, OPERATOR_CANCELLED, wmOperator::ptr, RNA_boolean_get(), RNA_boolean_set(), RNA_enum_set(), UI_ITEM_O_RETURN_PROPS, uiItemFullO(), uiItemS(), uiPupMenuBegin(), uiPupMenuEnd(), uiPupMenuLayout(), and WM_OP_EXEC_REGION_WIN.
Referenced by GRAPH_OT_fmodifier_add().
static int graph_fmodifier_copy_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 2173 of file graph_edit.c.
References ANIM_animdata_get_context(), ANIM_fmodifiers_copy_to_buf(), BKE_report(), bAnimListElem::data, free_fmodifiers_copybuf(), get_active_fcurve_channel(), MEM_freeN(), FCurve::modifiers, OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::reports, and RPT_ERROR.
Referenced by GRAPH_OT_fmodifier_copy().
static int graph_fmodifier_paste_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 2229 of file graph_edit.c.
References ANIM_animdata_filter(), ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), ANIM_fmodifiers_paste_from_buf(), ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_SEL, BKE_report(), BLI_freelistN(), bAnimContext::data, bAnimListElem::data, bAnimContext::datatype, filter(), ListBase::first, FCurve::modifiers, NA_EDITED, NC_ANIMATION, ND_KEYFRAME, bAnimListElem::next, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::reports, RPT_ERROR, and WM_event_add_notifier().
Referenced by GRAPH_OT_fmodifier_paste().
void GRAPH_OT_bake | ( | wmOperatorType * | ot | ) |
Definition at line 1031 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_bake_exec(), graphop_selected_fcurve_poll(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, wmOperatorType::poll, and WM_operator_confirm().
Referenced by graphedit_operatortypes().
void GRAPH_OT_clean | ( | wmOperatorType * | ot | ) |
Definition at line 948 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, FLT_MAX, graphkeys_clean_exec(), graphop_editable_keyframes_poll(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, wmOperatorType::poll, wmOperatorType::prop, RNA_def_float(), and wmOperatorType::srna.
Referenced by graphedit_operatortypes().
void GRAPH_OT_click_insert | ( | wmOperatorType * | ot | ) |
Definition at line 619 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, FLT_MAX, graphkeys_click_insert_exec(), graphkeys_click_insert_invoke(), graphop_active_fcurve_poll(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, wmOperatorType::poll, RNA_def_float(), and wmOperatorType::srna.
Referenced by graphedit_operatortypes().
void GRAPH_OT_copy | ( | wmOperatorType * | ot | ) |
Definition at line 702 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_copy_exec(), graphop_editable_keyframes_poll(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, and wmOperatorType::poll.
Referenced by graphedit_operatortypes().
void GRAPH_OT_delete | ( | wmOperatorType * | ot | ) |
Definition at line 886 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_delete_exec(), graphop_editable_keyframes_poll(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, wmOperatorType::poll, and WM_operator_confirm().
Referenced by graphedit_operatortypes().
void GRAPH_OT_duplicate | ( | wmOperatorType * | ot | ) |
Definition at line 816 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_duplicate_exec(), graphkeys_duplicate_invoke(), graphop_editable_keyframes_poll(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, wmOperatorType::poll, RNA_def_enum(), wmOperatorType::srna, TFM_TRANSLATION, and transform_mode_types.
Referenced by graphedit_operatortypes().
void GRAPH_OT_euler_filter | ( | wmOperatorType * | ot | ) |
Definition at line 1698 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_euler_filter_exec(), graphop_editable_keyframes_poll(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, and wmOperatorType::poll.
Referenced by graphedit_operatortypes().
void GRAPH_OT_extrapolation_type | ( | wmOperatorType * | ot | ) |
Definition at line 1358 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_expo_exec(), graphop_editable_keyframes_poll(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, wmOperatorType::poll, wmOperatorType::prop, RNA_def_enum(), wmOperatorType::srna, and WM_menu_invoke().
Referenced by graphedit_operatortypes().
void GRAPH_OT_fmodifier_add | ( | wmOperatorType * | ot | ) |
Definition at line 2151 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, fmodifier_type_items, graph_fmodifier_add_exec(), graph_fmodifier_add_invoke(), graphop_selected_fcurve_poll(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, wmOperatorType::poll, wmOperatorType::prop, RNA_def_boolean(), RNA_def_enum(), and wmOperatorType::srna.
Referenced by graphedit_operatortypes().
void GRAPH_OT_fmodifier_copy | ( | wmOperatorType * | ot | ) |
Definition at line 2209 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graph_fmodifier_copy_exec(), graphop_active_fcurve_poll(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, and wmOperatorType::poll.
Referenced by graphedit_operatortypes().
void GRAPH_OT_fmodifier_paste | ( | wmOperatorType * | ot | ) |
Definition at line 2271 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graph_fmodifier_paste_exec(), graphop_active_fcurve_poll(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, and wmOperatorType::poll.
Referenced by graphedit_operatortypes().
void GRAPH_OT_frame_jump | ( | wmOperatorType * | ot | ) |
Definition at line 1772 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_framejump_exec(), graphop_visible_keyframes_poll(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, and wmOperatorType::poll.
Referenced by graphedit_operatortypes().
void GRAPH_OT_ghost_curves_clear | ( | wmOperatorType * | ot | ) |
Definition at line 417 of file graph_edit.c.
References wmOperatorType::description, ED_operator_graphedit_active(), wmOperatorType::exec, wmOperatorType::flag, graphkeys_clear_ghostcurves_exec(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, and wmOperatorType::poll.
Referenced by graphedit_operatortypes().
void GRAPH_OT_ghost_curves_create | ( | wmOperatorType * | ot | ) |
Definition at line 374 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_create_ghostcurves_exec(), graphop_visible_keyframes_poll(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, and wmOperatorType::poll.
Referenced by graphedit_operatortypes().
void GRAPH_OT_handle_type | ( | wmOperatorType * | ot | ) |
Definition at line 1504 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_handletype_exec(), graphop_editable_keyframes_poll(), wmOperatorType::idname, wmOperatorType::invoke, keyframe_handle_type_items, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, wmOperatorType::poll, wmOperatorType::prop, RNA_def_enum(), wmOperatorType::srna, and WM_menu_invoke().
Referenced by graphedit_operatortypes().
void GRAPH_OT_interpolation_type | ( | wmOperatorType * | ot | ) |
Definition at line 1427 of file graph_edit.c.
References beztriple_interpolation_mode_items, wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_ipo_exec(), graphop_editable_keyframes_poll(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, wmOperatorType::poll, wmOperatorType::prop, RNA_def_enum(), wmOperatorType::srna, and WM_menu_invoke().
Referenced by graphedit_operatortypes().
void GRAPH_OT_keyframe_insert | ( | wmOperatorType * | ot | ) |
Definition at line 512 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_insertkey_exec(), graphop_editable_keyframes_poll(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, wmOperatorType::poll, wmOperatorType::prop, RNA_def_enum(), wmOperatorType::srna, and WM_menu_invoke().
Referenced by graphedit_operatortypes().
void GRAPH_OT_mirror | ( | wmOperatorType * | ot | ) |
Definition at line 1994 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_mirror_exec(), graphop_editable_keyframes_poll(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, wmOperatorType::poll, wmOperatorType::prop, RNA_def_enum(), wmOperatorType::srna, and WM_menu_invoke().
Referenced by graphedit_operatortypes().
void GRAPH_OT_paste | ( | wmOperatorType * | ot | ) |
Definition at line 747 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_paste_exec(), graphop_editable_keyframes_poll(), wmOperatorType::idname, keyframe_paste_merge_items, KEYFRAME_PASTE_MERGE_MIX, KEYFRAME_PASTE_OFFSET_CFRA_START, keyframe_paste_offset_items, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, wmOperatorType::poll, RNA_def_enum(), and wmOperatorType::srna.
Referenced by graphedit_operatortypes().
void GRAPH_OT_previewrange_set | ( | wmOperatorType * | ot | ) |
Definition at line 182 of file graph_edit.c.
References wmOperatorType::description, ED_operator_graphedit_active(), wmOperatorType::exec, wmOperatorType::flag, graphkeys_previewrange_exec(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, and wmOperatorType::poll.
Referenced by graphedit_operatortypes().
void GRAPH_OT_sample | ( | wmOperatorType * | ot | ) |
Definition at line 1249 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_sample_exec(), graphop_editable_keyframes_poll(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, and wmOperatorType::poll.
Referenced by graphedit_operatortypes().
void GRAPH_OT_smooth | ( | wmOperatorType * | ot | ) |
Definition at line 2049 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_smooth_exec(), graphop_editable_keyframes_poll(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, and wmOperatorType::poll.
Referenced by graphedit_operatortypes().
void GRAPH_OT_snap | ( | wmOperatorType * | ot | ) |
Definition at line 1876 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, graphkeys_snap_exec(), graphop_editable_keyframes_poll(), wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, wmOperatorType::poll, wmOperatorType::prop, RNA_def_enum(), wmOperatorType::srna, and WM_menu_invoke().
Referenced by graphedit_operatortypes().
void GRAPH_OT_sound_bake | ( | wmOperatorType * | ot | ) |
Definition at line 1175 of file graph_edit.c.
References wmOperatorType::description, wmOperatorType::exec, FILE_OPENFILE, FILE_SPECIAL, wmOperatorType::flag, FOLDERFILE, graphkeys_sound_bake_exec(), graphkeys_sound_bake_invoke(), graphop_selected_fcurve_poll(), wmOperatorType::idname, wmOperatorType::invoke, MOVIEFILE, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, wmOperatorType::poll, RNA_def_boolean(), RNA_def_float(), SOUNDFILE, wmOperatorType::srna, WM_FILESEL_FILEPATH, and WM_operator_properties_filesel().
Referenced by graphedit_operatortypes().
void GRAPH_OT_view_all | ( | wmOperatorType * | ot | ) |
Definition at line 244 of file graph_edit.c.
References wmOperatorType::description, ED_operator_graphedit_active(), wmOperatorType::exec, wmOperatorType::flag, graphkeys_viewall_exec(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, and wmOperatorType::poll.
Referenced by graphedit_operatortypes().
void GRAPH_OT_view_selected | ( | wmOperatorType * | ot | ) |
Definition at line 259 of file graph_edit.c.
References wmOperatorType::description, ED_operator_graphedit_active(), wmOperatorType::exec, wmOperatorType::flag, graphkeys_view_selected_exec(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, and wmOperatorType::poll.
Referenced by graphedit_operatortypes().
static int graphkeys_bake_exec | ( | bContext * | C, |
wmOperator * | UNUSEDop | ||
) | [static] |
Definition at line 1002 of file graph_edit.c.
References ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), bake_graph_curves(), NA_EDITED, NC_ANIMATION, ND_KEYFRAME, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, PEFRA, PSFRA, bAnimContext::scene, and WM_event_add_notifier().
Referenced by GRAPH_OT_bake().
static int graphkeys_clean_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 924 of file graph_edit.c.
References ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), clean_graph_keys(), NA_EDITED, NC_ANIMATION, ND_KEYFRAME, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::ptr, RNA_float_get(), thresh, and WM_event_add_notifier().
Referenced by GRAPH_OT_clean().
static int graphkeys_clear_ghostcurves_exec | ( | bContext * | C, |
wmOperator * | UNUSEDop | ||
) | [static] |
Definition at line 394 of file graph_edit.c.
References ANIM_animdata_get_context(), CTX_wm_area(), ED_area_tag_redraw(), ListBase::first, free_fcurves(), SpaceIpo::ghostCurves, if(), NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, and bAnimContext::sl.
Referenced by GRAPH_OT_ghost_curves_clear().
static int graphkeys_click_insert_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 533 of file graph_edit.c.
References ANIM_animdata_get_context(), ANIM_nla_mapping_get(), ANIM_unit_mapping_get_factor(), BKE_nla_tweakedit_remap(), BKE_report(), bAnimListElem::data, ELEM, fcurve_is_keyframable(), FCURVE_PROTECTED, FCurve::flag, FCurve::fpt, get_active_fcurve_channel(), bAnimListElem::id, insert_vert_fcurve(), MEM_freeN(), NA_EDITED, NC_ANIMATION, ND_KEYFRAME, NLATIME_CONVERT_UNMAP, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::ptr, wmOperator::reports, RNA_float_get(), RPT_ERROR, bAnimContext::scene, simple_enum_gen::val, and WM_event_add_notifier().
Referenced by GRAPH_OT_click_insert(), and graphkeys_click_insert_invoke().
static int graphkeys_click_insert_invoke | ( | bContext * | C, |
wmOperator * | op, | ||
wmEvent * | evt | ||
) | [static] |
Definition at line 591 of file graph_edit.c.
References ANIM_animdata_get_context(), bAnimContext::ar, graphkeys_click_insert_exec(), OPERATOR_CANCELLED, wmOperator::ptr, RNA_float_set(), UI_view2d_region_to_view(), ARegion::v2d, ARegion::winrct, wmEvent::x, rcti::xmin, wmEvent::y, and rcti::ymin.
Referenced by GRAPH_OT_click_insert().
static int graphkeys_copy_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 684 of file graph_edit.c.
References ANIM_animdata_get_context(), BKE_report(), copy_graph_keys(), OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::reports, and RPT_ERROR.
Referenced by GRAPH_OT_copy().
static int graphkeys_create_ghostcurves_exec | ( | bContext * | C, |
wmOperator * | UNUSEDop | ||
) | [static] |
Definition at line 350 of file graph_edit.c.
References ANIM_animdata_get_context(), bAnimContext::ar, create_ghost_curves(), CTX_wm_area(), View2D::cur, ED_area_tag_redraw(), OPERATOR_CANCELLED, OPERATOR_FINISHED, ARegion::v2d, rctf::xmax, and rctf::xmin.
Referenced by GRAPH_OT_ghost_curves_create().
static int graphkeys_delete_exec | ( | bContext * | C, |
wmOperator * | UNUSEDop | ||
) | [static] |
Definition at line 866 of file graph_edit.c.
References ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), delete_graph_keys(), NA_EDITED, NC_ANIMATION, ND_KEYFRAME, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, and WM_event_add_notifier().
Referenced by GRAPH_OT_delete().
static int graphkeys_duplicate_exec | ( | bContext * | C, |
wmOperator * | UNUSEDop | ||
) | [static] |
Definition at line 789 of file graph_edit.c.
References ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), duplicate_graph_keys(), NA_EDITED, NC_ANIMATION, ND_KEYFRAME, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, and WM_event_add_notifier().
Referenced by GRAPH_OT_duplicate(), and graphkeys_duplicate_invoke().
static int graphkeys_duplicate_invoke | ( | bContext * | C, |
wmOperator * | op, | ||
wmEvent * | UNUSEDevent | ||
) | [static] |
Definition at line 809 of file graph_edit.c.
References graphkeys_duplicate_exec(), and OPERATOR_FINISHED.
Referenced by GRAPH_OT_duplicate().
static int graphkeys_euler_filter_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 1542 of file graph_edit.c.
References ANIM_animdata_filter(), ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_NODUPLIS, ANIMFILTER_SEL, FCurve::array_index, FCurve::bezt, BKE_report(), BKE_reportf(), BLI_addtail(), BLI_freelistN(), bAnimContext::data, bAnimListElem::data, bAnimContext::datatype, ELEM3, fabs(), fabsf, tEulerFilter::fcurves, filter(), ListBase::first, i, tEulerFilter::id, bAnimListElem::id, if(), M_PI, MEM_callocN(), NA_EDITED, ID::name, NC_ANIMATION, ND_KEYFRAME, tEulerFilter::next, bAnimListElem::next, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, tEulerFilter::prev, wmOperator::reports, tEulerFilter::rna_path, FCurve::rna_path, RPT_ERROR, RPT_WARNING, FCurve::totvert, BezTriple::vec, and WM_event_add_notifier().
Referenced by GRAPH_OT_euler_filter().
static int graphkeys_expo_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 1334 of file graph_edit.c.
References ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), NC_ANIMATION, ND_KEYFRAME_PROP, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::ptr, RNA_enum_get(), setexpo_graph_keys(), and WM_event_add_notifier().
Referenced by GRAPH_OT_extrapolation_type().
static int graphkeys_framejump_exec | ( | bContext * | C, |
wmOperator * | UNUSEDop | ||
) | [static] |
Definition at line 1716 of file graph_edit.c.
References ANIM_animdata_filter(), ANIM_animdata_get_context(), ANIM_fcurve_keyframes_loop(), ANIM_nla_mapping_apply_fcurve(), ANIM_nla_mapping_get(), ANIM_unit_mapping_apply_fcurve(), ANIM_UNITCONV_ONLYKEYS, ANIM_UNITCONV_RESTORE, ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_NODUPLIS, bezt_calc_average(), BLI_freelistN(), CFRA, SpaceIpo::cursorVal, bAnimContext::data, bAnimContext::datatype, KeyframeEditData::f1, KeyframeEditData::f2, filter(), ListBase::first, KeyframeEditData::i1, bAnimListElem::id, bAnimListElem::key_data, NC_SCENE, ND_FRAME, bAnimListElem::next, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, bAnimContext::scene, bAnimContext::sl, SUBFRA, and WM_event_add_notifier().
Referenced by GRAPH_OT_frame_jump().
static int graphkeys_handletype_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 1480 of file graph_edit.c.
References ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), NC_ANIMATION, ND_KEYFRAME_PROP, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::ptr, RNA_enum_get(), sethandles_graph_keys(), and WM_event_add_notifier().
Referenced by GRAPH_OT_handle_type().
static int graphkeys_insertkey_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 488 of file graph_edit.c.
References ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), insert_graph_keys(), NA_EDITED, NC_ANIMATION, ND_KEYFRAME, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::ptr, RNA_enum_get(), and WM_event_add_notifier().
Referenced by GRAPH_OT_keyframe_insert().
static int graphkeys_ipo_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 1403 of file graph_edit.c.
References ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), NC_ANIMATION, ND_KEYFRAME_PROP, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::ptr, RNA_enum_get(), setipo_graph_keys(), and WM_event_add_notifier().
Referenced by GRAPH_OT_interpolation_type().
static int graphkeys_mirror_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 1970 of file graph_edit.c.
References ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), mirror_graph_keys(), NA_EDITED, NC_ANIMATION, ND_KEYFRAME, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::ptr, RNA_enum_get(), and WM_event_add_notifier().
Referenced by GRAPH_OT_mirror().
static int graphkeys_paste_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 719 of file graph_edit.c.
References ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), NA_EDITED, NC_ANIMATION, ND_KEYFRAME, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, paste_graph_keys(), wmOperator::ptr, wmOperator::reports, bAnimContext::reports, RNA_enum_get(), and WM_event_add_notifier().
Referenced by GRAPH_OT_paste().
static int graphkeys_previewrange_exec | ( | bContext * | C, |
wmOperator * | UNUSEDop | ||
) | [static] |
Definition at line 155 of file graph_edit.c.
References ANIM_animdata_get_context(), FALSE, RenderData::flag, get_graph_keyframe_extents(), max, min, NC_SCENE, ND_FRAME, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, RenderData::pefra, RenderData::psfra, Scene::r, bAnimContext::scene, SCER_PRV_RANGE, and WM_event_add_notifier().
Referenced by GRAPH_OT_previewrange_set().
static int graphkeys_sample_exec | ( | bContext * | C, |
wmOperator * | UNUSEDop | ||
) | [static] |
Definition at line 1229 of file graph_edit.c.
References ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), NA_EDITED, NC_ANIMATION, ND_KEYFRAME, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, sample_graph_keys(), and WM_event_add_notifier().
Referenced by GRAPH_OT_sample().
static int graphkeys_smooth_exec | ( | bContext * | C, |
wmOperator * | UNUSEDop | ||
) | [static] |
Definition at line 2015 of file graph_edit.c.
References ANIM_animdata_filter(), ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_NODUPLIS, BLI_freelistN(), bAnimContext::data, bAnimContext::datatype, filter(), ListBase::first, bAnimListElem::key_data, NA_EDITED, NC_ANIMATION, ND_KEYFRAME, bAnimListElem::next, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, smooth_fcurve(), and WM_event_add_notifier().
Referenced by GRAPH_OT_smooth().
static int graphkeys_snap_exec | ( | bContext * | C, |
wmOperator * | op | ||
) | [static] |
Definition at line 1852 of file graph_edit.c.
References ANIM_animdata_get_context(), ANIM_editkeyframes_refresh(), NA_EDITED, NC_ANIMATION, ND_KEYFRAME, NULL, OPERATOR_CANCELLED, OPERATOR_FINISHED, wmOperator::ptr, RNA_enum_get(), snap_graph_keys(), and WM_event_add_notifier().
Referenced by GRAPH_OT_snap().
static int graphkeys_sound_bake_exec | ( | bContext * | UNUSEDC, |
wmOperator * | op | ||
) | [static] |
Definition at line 1155 of file graph_edit.c.
References BKE_report(), OPERATOR_CANCELLED, wmOperator::reports, and RPT_ERROR.
Referenced by GRAPH_OT_sound_bake().
static int graphkeys_sound_bake_invoke | ( | bContext * | C, |
wmOperator * | op, | ||
wmEvent * | event | ||
) | [static] |
Definition at line 1164 of file graph_edit.c.
References ANIM_animdata_get_context(), OPERATOR_CANCELLED, and WM_operator_filesel().
Referenced by GRAPH_OT_sound_bake().
static int graphkeys_view_selected_exec | ( | bContext * | C, |
wmOperator * | UNUSEDop | ||
) | [static] |
Definition at line 238 of file graph_edit.c.
References graphkeys_viewall(), and TRUE.
Referenced by GRAPH_OT_view_selected().
static int graphkeys_viewall | ( | bContext * | C, |
const short | selOnly | ||
) | [static] |
Definition at line 199 of file graph_edit.c.
References ANIM_animdata_get_context(), bAnimContext::ar, CTX_wm_area(), CTX_wm_screen(), View2D::cur, ED_area_tag_redraw(), get_graph_keyframe_extents(), OPERATOR_CANCELLED, OPERATOR_FINISHED, UI_view2d_sync(), ARegion::v2d, V2D_LOCK_COPY, rctf::xmax, rctf::xmin, rctf::ymax, and rctf::ymin.
Referenced by graphkeys_view_selected_exec(), and graphkeys_viewall_exec().
static int graphkeys_viewall_exec | ( | bContext * | C, |
wmOperator * | UNUSEDop | ||
) | [static] |
Definition at line 232 of file graph_edit.c.
References FALSE, and graphkeys_viewall().
Referenced by GRAPH_OT_view_all().
static void insert_graph_keys | ( | bAnimContext * | ac, |
short | mode | ||
) | [static] |
Definition at line 445 of file graph_edit.c.
References ANIM_animdata_filter(), ANIM_get_keyframing_flags(), ANIM_nla_mapping_get(), ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_NODUPLIS, ANIMFILTER_SEL, FCurve::array_index, BKE_nla_tweakedit_remap(), BLI_freelistN(), CFRA, FCurve::curval, bAnimContext::data, bAnimContext::datatype, filter(), ListBase::first, FCurve::grp, bAnimListElem::id, if(), insert_keyframe(), insert_vert_fcurve(), bAnimListElem::key_data, bActionGroup::name, bAnimListElem::next, NLATIME_CONVERT_UNMAP, NULL, bAnimContext::reports, FCurve::rna_path, and bAnimContext::scene.
Referenced by graphkeys_insertkey_exec().
static void mirror_graph_keys | ( | bAnimContext * | ac, |
short | mode | ||
) | [static] |
Definition at line 1908 of file graph_edit.c.
References ANIM_animdata_filter(), ANIM_editkeyframes_mirror(), ANIM_fcurve_keyframes_loop(), ANIM_nla_mapping_apply_fcurve(), ANIM_nla_mapping_get(), ANIM_unit_mapping_apply_fcurve(), ANIM_UNITCONV_ONLYKEYS, ANIM_UNITCONV_RESTORE, ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_NODUPLIS, BLI_freelistN(), calchandles_fcurve(), SpaceIpo::cursorVal, bAnimContext::data, bAnimContext::datatype, ED_markers_get_first_selected(), KeyframeEditData::f1, filter(), ListBase::first, TimeMarker::frame, GRAPHKEYS_MIRROR_MARKER, GRAPHKEYS_MIRROR_VALUE, bAnimListElem::id, bAnimListElem::key_data, bAnimContext::markers, bAnimListElem::next, NULL, KeyframeEditData::scene, bAnimContext::scene, and bAnimContext::sl.
Referenced by graphkeys_mirror_exec().
static short paste_graph_keys | ( | bAnimContext * | ac, |
const eKeyPasteOffset | offset_mode, | ||
const eKeyMergeMode | merge_mode | ||
) | [static] |
Definition at line 663 of file graph_edit.c.
References ANIM_animdata_filter(), ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_NODUPLIS, ANIMFILTER_SEL, BLI_freelistN(), bAnimContext::data, bAnimContext::datatype, filter(), NULL, and paste_animedit_keys().
Referenced by graphkeys_paste_exec().
static void sample_graph_keys | ( | bAnimContext * | ac | ) | [static] |
Definition at line 1209 of file graph_edit.c.
References ANIM_animdata_filter(), ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_NODUPLIS, BLI_freelistN(), bAnimContext::data, bAnimContext::datatype, filter(), ListBase::first, bAnimListElem::key_data, bAnimListElem::next, NULL, and sample_fcurve().
Referenced by graphkeys_sample_exec().
static void setexpo_graph_keys | ( | bAnimContext * | ac, |
short | mode | ||
) | [static] |
Definition at line 1285 of file graph_edit.c.
References add_fmodifier(), ANIM_animdata_filter(), ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_NODUPLIS, ANIMFILTER_SEL, BLI_freelistN(), CLEAR_CYCLIC_EXPO, bAnimContext::data, bAnimListElem::data, bAnimContext::datatype, FCurve::extend, filter(), ListBase::first, FMODIFIER_TYPE_CYCLES, if(), list_has_suitable_fmodifier(), MAKE_CYCLIC_EXPO, FCurve::modifiers, bAnimListElem::next, NULL, remove_fmodifier(), and FModifier::type.
Referenced by graphkeys_expo_exec().
static void sethandles_graph_keys | ( | bAnimContext * | ac, |
short | mode | ||
) | [static] |
Definition at line 1449 of file graph_edit.c.
References ANIM_animdata_filter(), ANIM_editkeyframes_handles(), ANIM_editkeyframes_ok(), ANIM_fcurve_keyframes_loop(), ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_NODUPLIS, BEZT_OK_SELECTED, BLI_freelistN(), calchandles_fcurve(), bAnimContext::data, bAnimContext::datatype, filter(), ListBase::first, if(), bAnimListElem::key_data, bAnimListElem::next, and NULL.
Referenced by graphkeys_handletype_exec().
static void setipo_graph_keys | ( | bAnimContext * | ac, |
short | mode | ||
) | [static] |
Definition at line 1380 of file graph_edit.c.
References ANIM_animdata_filter(), ANIM_editkeyframes_ipo(), ANIM_fcurve_keyframes_loop(), ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_NODUPLIS, BLI_freelistN(), calchandles_fcurve(), bAnimContext::data, bAnimContext::datatype, filter(), ListBase::first, bAnimListElem::key_data, bAnimListElem::next, and NULL.
Referenced by graphkeys_ipo_exec().
static void snap_graph_keys | ( | bAnimContext * | ac, |
short | mode | ||
) | [static] |
Definition at line 1801 of file graph_edit.c.
References ANIM_animdata_filter(), ANIM_editkeyframes_snap(), ANIM_fcurve_keyframes_loop(), ANIM_nla_mapping_apply_fcurve(), ANIM_nla_mapping_get(), ANIM_unit_mapping_apply_fcurve(), ANIM_UNITCONV_RESTORE, ANIMFILTER_CURVE_VISIBLE, ANIMFILTER_DATA_VISIBLE, ANIMFILTER_FOREDIT, ANIMFILTER_NODUPLIS, BLI_freelistN(), calchandles_fcurve(), SpaceIpo::cursorVal, bAnimContext::data, bAnimContext::datatype, KeyframeEditData::f1, filter(), ListBase::first, GRAPHKEYS_SNAP_NEAREST_MARKER, GRAPHKEYS_SNAP_VALUE, bAnimListElem::id, bAnimListElem::key_data, ListBase::last, KeyframeEditData::list, bAnimContext::markers, bAnimListElem::next, NULL, KeyframeEditData::scene, bAnimContext::scene, and bAnimContext::sl.
Referenced by graphkeys_snap_exec().
EnumPropertyItem prop_graphkeys_expo_types[] [static] |
{ {FCURVE_EXTRAPOLATE_CONSTANT, "CONSTANT", 0, "Constant Extrapolation", ""}, {FCURVE_EXTRAPOLATE_LINEAR, "LINEAR", 0, "Linear Extrapolation", ""}, {MAKE_CYCLIC_EXPO, "MAKE_CYCLIC", 0, "Make Cyclic (F-Modifier)", "Add Cycles F-Modifier if one doesn't exist already"}, {CLEAR_CYCLIC_EXPO, "CLEAR_CYCLIC", 0, "Clear Cyclic (F-Modifier)", "Remove Cycles F-Modifier if not needed anymore"}, {0, NULL, 0, NULL, NULL} }
Definition at line 1275 of file graph_edit.c.
EnumPropertyItem prop_graphkeys_insertkey_types[] [static] |
{ {1, "ALL", 0, "All Channels", ""}, {2, "SEL", 0, "Only Selected Channels", ""}, {0, NULL, 0, NULL, NULL} }
Definition at line 438 of file graph_edit.c.
EnumPropertyItem prop_graphkeys_mirror_types[] [static] |
{ {GRAPHKEYS_MIRROR_CFRA, "CFRA", 0, "By Times over Current Frame", ""}, {GRAPHKEYS_MIRROR_VALUE, "VALUE", 0, "By Values over Cursor Value", ""}, {GRAPHKEYS_MIRROR_YAXIS, "YAXIS", 0, "By Times over Time=0", ""}, {GRAPHKEYS_MIRROR_XAXIS, "XAXIS", 0, "By Values over Value=0", ""}, {GRAPHKEYS_MIRROR_MARKER, "MARKER", 0, "By Times over First Selected Marker", ""}, {0, NULL, 0, NULL, NULL} }
Definition at line 1898 of file graph_edit.c.
EnumPropertyItem prop_graphkeys_snap_types[] [static] |
{ {GRAPHKEYS_SNAP_CFRA, "CFRA", 0, "Current Frame", ""}, {GRAPHKEYS_SNAP_VALUE, "VALUE", 0, "Cursor Value", ""}, {GRAPHKEYS_SNAP_NEAREST_FRAME, "NEAREST_FRAME", 0, "Nearest Frame", ""}, {GRAPHKEYS_SNAP_NEAREST_SECOND, "NEAREST_SECOND", 0, "Nearest Second", ""}, {GRAPHKEYS_SNAP_NEAREST_MARKER, "NEAREST_MARKER", 0, "Nearest Marker", ""}, {GRAPHKEYS_SNAP_HORIZONTAL, "HORIZONTAL", 0, "Flatten Handles", ""}, {0, NULL, 0, NULL, NULL} }
Definition at line 1790 of file graph_edit.c.