93 const int timeline_frame,
97 if (
abs(position - timeline_frame) < *r_best_distance) {
98 *r_best_distance =
abs(position - timeline_frame);
99 *r_best_frame = position;
124 return timeline_frame;
277 switch (event->
type) {
330 ot->
name =
"Change Frame";
331 ot->
idname =
"ANIM_OT_change_frame";
332 ot->
description =
"Interactively change the current frame number";
359 if (
G.is_rendering) {
393 int frame_clamped = frame;
395 if (frame_clamped != frame) {
398 frame = frame_clamped;
419 ot->
name =
"Set Start Frame";
420 ot->
idname =
"ANIM_OT_start_frame_set";
421 ot->
description =
"Set the current frame as the preview or scene start frame";
448 int frame_clamped = frame;
450 if (frame_clamped != frame) {
453 frame = frame_clamped;
474 ot->
name =
"Set End Frame";
475 ot->
idname =
"ANIM_OT_end_frame_set";
476 ot->
description =
"Set the current frame as the preview or scene end frame";
525 ot->
name =
"Set Preview Range";
526 ot->
idname =
"ANIM_OT_previewrange_set";
527 ot->
description =
"Interactively define frame range used for playback";
576 ot->
name =
"Clear Preview Range";
577 ot->
idname =
"ANIM_OT_previewrange_clear";
struct ScrArea * CTX_wm_area(const bContext *C)
struct Scene * CTX_data_scene(const bContext *C)
struct SpaceSeq * CTX_wm_space_seq(const bContext *C)
struct bScreen * CTX_wm_screen(const bContext *C)
struct ARegion * CTX_wm_region(const bContext *C)
void CTX_wm_operator_poll_msg_set(struct bContext *C, const char *msg)
void BKE_report(ReportList *reports, eReportType type, const char *message)
int BKE_scene_frame_snap_by_seconds(struct Scene *scene, double interval_in_seconds, int frame)
MINLINE int round_fl_to_int(float a)
void DEG_id_tag_update(struct ID *id, int flag)
#define SCER_LOCK_FRAME_SELECTION
#define SEQ_SNAP_CURRENT_FRAME_TO_STRIPS
#define SCER_SHOW_SUBFRAME
#define FRAMENUMBER_MIN_CLAMP(cfra)
void ED_area_tag_redraw(ScrArea *area)
bool ED_operator_animview_active(struct bContext *C)
Sequence * ED_sequencer_special_preview_get(void)
bool ED_space_sequencer_check_show_strip(struct SpaceSeq *sseq)
void ED_sequencer_special_preview_set(struct bContext *C, const int mval[2])
void ED_sequencer_special_preview_clear(void)
Group Output data from inside of a node group A color picker Mix two input colors RGB to Convert a color s luminance to a grayscale value Generate a normal vector and a dot product Bright Control the brightness and contrast of the input color Vector Map an input vectors to used to fine tune the interpolation of the input Camera Retrieve information about the camera and how it relates to the current shading point s position CLAMP
#define SEQ_ITERATOR_FOREACH(var, collection)
float UI_view2d_region_to_view_x(const struct View2D *v2d, float x)
void ANIM_OT_keyframe_delete_button(struct wmOperatorType *ot)
void ANIM_OT_keyframe_delete_by_name(struct wmOperatorType *ot)
void ANIM_OT_keyframe_insert_button(struct wmOperatorType *ot)
void ANIM_OT_keying_set_add(struct wmOperatorType *ot)
void ANIM_OT_paste_driver_button(struct wmOperatorType *ot)
void ANIM_OT_copy_driver_button(struct wmOperatorType *ot)
void ANIM_OT_driver_button_remove(struct wmOperatorType *ot)
void ANIM_OT_keyingset_button_remove(struct wmOperatorType *ot)
void ANIM_OT_keyframe_clear_v3d(struct wmOperatorType *ot)
void ANIM_OT_keyingset_button_add(struct wmOperatorType *ot)
void ANIM_OT_keying_set_path_remove(struct wmOperatorType *ot)
void ANIM_OT_keyframe_insert(struct wmOperatorType *ot)
void ANIM_OT_keyframe_clear_button(struct wmOperatorType *ot)
void ANIM_OT_driver_button_edit(struct wmOperatorType *ot)
void ANIM_OT_driver_button_add(struct wmOperatorType *ot)
void ANIM_OT_keying_set_path_add(struct wmOperatorType *ot)
void ANIM_OT_keying_set_active_set(struct wmOperatorType *ot)
void ANIM_OT_keyframe_delete_v3d(struct wmOperatorType *ot)
void ANIM_OT_keyframe_delete(struct wmOperatorType *ot)
void ANIM_OT_keyframe_insert_menu(struct wmOperatorType *ot)
void ANIM_OT_keying_set_remove(struct wmOperatorType *ot)
void ANIM_OT_keyframe_insert_by_name(struct wmOperatorType *ot)
static int change_frame_invoke(bContext *C, wmOperator *op, const wmEvent *event)
static int seq_frame_apply_snap(bContext *C, Scene *scene, const int timeline_frame)
static void ANIM_OT_previewrange_set(wmOperatorType *ot)
static bool anim_set_end_frames_poll(bContext *C)
static void ANIM_OT_previewrange_clear(wmOperatorType *ot)
static int previewrange_clear_exec(bContext *C, wmOperator *UNUSED(op))
static bool use_sequencer_snapping(bContext *C)
static int anim_set_sfra_exec(bContext *C, wmOperator *op)
static void seq_frame_snap_update_best(const int position, const int timeline_frame, int *r_best_frame, int *r_best_distance)
static void ANIM_OT_start_frame_set(wmOperatorType *ot)
static int change_frame_exec(bContext *C, wmOperator *op)
static int anim_set_efra_exec(bContext *C, wmOperator *op)
static void ANIM_OT_end_frame_set(wmOperatorType *ot)
static void change_frame_cancel(bContext *C, wmOperator *UNUSED(op))
static int previewrange_define_exec(bContext *C, wmOperator *op)
static float frame_from_event(bContext *C, const wmEvent *event)
void ED_operatortypes_anim(void)
static int change_frame_modal(bContext *C, wmOperator *op, const wmEvent *event)
void ED_keymap_anim(wmKeyConfig *keyconf)
static bool change_frame_poll(bContext *C)
static void ANIM_OT_change_frame(wmOperatorType *ot)
static void change_frame_seq_preview_end(bContext *C)
static int seq_snap_threshold_get_frame_distance(bContext *C)
static void change_frame_apply(bContext *C, wmOperator *op)
static void change_frame_seq_preview_begin(bContext *C, const wmEvent *event)
SeqCollection * SEQ_query_all_strips(ListBase *seqbase)
void SEQ_collection_free(SeqCollection *collection)
static void area(int d1, int d2, int e1, int e2, float weights[2])
void RNA_boolean_set(PointerRNA *ptr, const char *name, bool value)
float RNA_float_get(PointerRNA *ptr, const char *name)
void RNA_float_set(PointerRNA *ptr, const char *name, float value)
bool RNA_boolean_get(PointerRNA *ptr, const char *name)
PropertyRNA * RNA_def_float(StructOrFunctionRNA *cont_, const char *identifier, float default_value, float hardmin, float hardmax, const char *ui_name, const char *ui_description, float softmin, float softmax)
PropertyRNA * RNA_def_boolean(StructOrFunctionRNA *cont_, const char *identifier, bool default_value, const char *ui_name, const char *ui_description)
void RNA_def_property_flag(PropertyRNA *prop, PropertyFlag flag)
ListBase * SEQ_active_seqbase_get(const Editing *ed)
int SEQ_tool_settings_snap_distance_get(Scene *scene)
short SEQ_tool_settings_snap_flag_get(Scene *scene)
Editing * SEQ_editing_get(const Scene *scene)
int SEQ_time_left_handle_frame_get(const Scene *UNUSED(scene), const Sequence *seq)
int SEQ_time_right_handle_frame_get(const Scene *scene, const Sequence *seq)
struct ToolSettings * toolsettings
int(* invoke)(struct bContext *, struct wmOperator *, const struct wmEvent *) ATTR_WARN_UNUSED_RESULT
int(* modal)(struct bContext *, struct wmOperator *, const struct wmEvent *) ATTR_WARN_UNUSED_RESULT
bool(* poll)(struct bContext *) ATTR_WARN_UNUSED_RESULT
void(* cancel)(struct bContext *, struct wmOperator *)
int(* exec)(struct bContext *, struct wmOperator *) ATTR_WARN_UNUSED_RESULT
struct ReportList * reports
bool ED_time_scrub_event_in_region(const ARegion *region, const wmEvent *event)
wmEventHandler_Op * WM_event_add_modal_handler(bContext *C, wmOperator *op)
void WM_event_add_notifier(const bContext *C, uint type, void *reference)
void WM_gesture_box_cancel(bContext *C, wmOperator *op)
int WM_gesture_box_invoke(bContext *C, wmOperator *op, const wmEvent *event)
int WM_gesture_box_modal(bContext *C, wmOperator *op, const wmEvent *event)
wmKeyMap * WM_keymap_ensure(wmKeyConfig *keyconf, const char *idname, int spaceid, int regionid)
void WM_operator_properties_border_to_rcti(struct wmOperator *op, rcti *rect)
void WM_operator_properties_border(wmOperatorType *ot)
void WM_operatortype_append(void(*opfunc)(wmOperatorType *))