pub struct CueAnimation {
pub tags: Vec<AnimatedTag>,
}Expand description
All animated tags found in a single cue, in the order parsed.
Fields§
Implementations§
Source§impl CueAnimation
impl CueAnimation
Sourcepub fn karaoke_spans(&self) -> Vec<KaraokeSpan>
pub fn karaoke_spans(&self) -> Vec<KaraokeSpan>
Resolve the cue’s \k family markers into cumulative
KaraokeSpans, milliseconds from the cue start.
Every AnimatedTag::Karaoke in tags (in document order)
becomes one span; each span begins where the previous one ended,
so the centisecond durations the \k tags carry add up into a
continuous syllable timeline. Cues with no karaoke markers yield
an empty vector. The centisecond → millisecond conversion is
exact (cs * 10).
Source§impl CueAnimation
impl CueAnimation
Sourcepub fn evaluate_at(&self, t_in_cue_ms: i32, cue_duration_ms: i32) -> RenderState
pub fn evaluate_at(&self, t_in_cue_ms: i32, cue_duration_ms: i32) -> RenderState
Sample the cue at t_in_cue_ms (milliseconds from cue start).
cue_duration_ms is needed because \move and \t accept
t1/t2 arguments that default to “the entire cue”.
Trait Implementations§
Source§impl Clone for CueAnimation
impl Clone for CueAnimation
Source§fn clone(&self) -> CueAnimation
fn clone(&self) -> CueAnimation
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CueAnimation
impl Debug for CueAnimation
Source§impl Default for CueAnimation
impl Default for CueAnimation
Source§fn default() -> CueAnimation
fn default() -> CueAnimation
Returns the “default value” for a type. Read more
Source§impl PartialEq for CueAnimation
impl PartialEq for CueAnimation
Source§fn eq(&self, other: &CueAnimation) -> bool
fn eq(&self, other: &CueAnimation) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for CueAnimation
Auto Trait Implementations§
impl Freeze for CueAnimation
impl RefUnwindSafe for CueAnimation
impl Send for CueAnimation
impl Sync for CueAnimation
impl Unpin for CueAnimation
impl UnsafeUnpin for CueAnimation
impl UnwindSafe for CueAnimation
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more