pub enum TimeMap {
Forward,
Reverse,
Freeze {
source_time: MediaTime,
},
Loop {
mode: LoopMode,
},
Curve {
keyframes: Vec<TimeKeyframe>,
before: Extrapolation,
after: Extrapolation,
},
}Expand description
How a clip plays its source range over its timeline range.
forward and reverse stretch the source range over the timeline range, so their speed
is the ratio of the two. A loop plays the source range at its own speed for as long as the
timeline range lasts. A curve names the source time at each timeline time, at any speed and
in either direction.
Variants§
Forward
From the start of the source range to its end.
Reverse
From the end of the source range to its start: pictures in reverse order and sound played backwards.
Freeze
One source instant for the whole clip, and silence.
Loop
The source range again and again, at its own speed.
Curve
Source time keyed over timeline time: speed ramps, reverse play and holds in one clip.
The picture shows the curve’s value rounded down to a tick and held inside
source_range; a falling stretch shows the instants it names, so it is not reverse’s
mirror by frame. Sound follows the curve and is silent where it stands still.
Fields
keyframes: Vec<TimeKeyframe>2 to MAX_KEYFRAMES keyframes, strictly ascending in time. They may lie outside
the clip’s timeline range.
before: ExtrapolationWhat the curve does before the first keyframe.
after: ExtrapolationWhat the curve does from the last keyframe on.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for TimeMap
impl<'de> Deserialize<'de> for TimeMap
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl StructuralPartialEq for TimeMap
Source§impl TimelineValue for TimeMap
impl TimelineValue for TimeMap
Source§fn keep_window(&mut self, window: (i64, i64))
fn keep_window(&mut self, window: (i64, i64))
window (ticks, end exclusive): those
inside it and the nearest one on each side, or all of them when the window reaches past
an end the value does not hold at.Source§fn via_clips(&self, _: &mut dyn FnMut(&ClipId))
fn via_clips(&self, _: &mut dyn FnMut(&ClipId))
visit with each clip a data binding of the value reads through: the value’s own
binding, or those of its split channels.Source§fn via_clips_mut(&mut self, _: &mut dyn FnMut(&mut ClipId))
fn via_clips_mut(&mut self, _: &mut dyn FnMut(&mut ClipId))
Self::via_clips, to point them at other clips.