Skip to main content

Module keyframe

Module keyframe 

Source
Expand description

The one keyframe form, [{"t": RationalTime, "v": value, "interp": "linear" | "ease" | "hold"}] (docs/timeline.md#effect-schemas), evaluated in Rust per frame: a thin wrapper over ffcine_core::anim’s tracks on Clock::Source.

t is a RationalTime (or plain seconds) in the clip’s source time (source_range.start_time plus the time since the clip’s first frame, docs/timeline.md). interp (or ease) shapes the segment from that key to the next, with any Interp (the text keyframes’ set). Before the first key the first value holds, after the last the last. A value may also be an expression over the source time st (docs/compositing.md#expressions).

Structs§

Key
A keyframe: value v at t on the track’s Clock, ease shaping the segment to the next key.

Enums§

Interp
How a segment moves from one key to the next (ffcine_core::anim::Ease). The shape of a move over its progress u (0..1): a key’s interp (alias ease).
Keyed
A parameter: a constant, keys sorted by time, or an expression track.

Traits§

Lerp
A value that can be keyframed. A value that can be keyframed: f64, [f64; N] (vectors, colours).

Functions§

ease
0.5 - 0.5 cos(pi u).
is_keys
Whether v is the keyframe form (an array of {t, v} objects).
seconds
Seconds from a RationalTime ({rate, value}) or a plain number.