pub struct RanimScene {
pub root: AnimStack,
pub(crate) time_marks: Vec<(f64, TimeMark)>,
}Expand description
Animation definition builder passed to scene constructors.
The public RanimScene::root stack is the scene’s animation composition
root. Calling RanimScene::play is a convenience alias for pushing into
that stack.
Fields§
§root: AnimStackRoot animation stack. Modules pushed here share the same local origin.
time_marks: Vec<(f64, TimeMark)>Implementations§
Source§impl RanimScene
impl RanimScene
Sourcepub fn play<A: Animation + 'static>(&mut self, animation: A) -> &mut Self
pub fn play<A: Animation + 'static>(&mut self, animation: A) -> &mut Self
Push an animation module into the root stack.
Sourcepub fn insert_time_mark(&mut self, sec: f64, time_mark: TimeMark)
pub fn insert_time_mark(&mut self, sec: f64, time_mark: TimeMark)
Insert a time mark.
Sourcepub fn seal(self) -> SealedRanimScene
pub fn seal(self) -> SealedRanimScene
Finish the definition and produce an immutable, evaluable recipe.
Trait Implementations§
Source§impl Debug for RanimScene
impl Debug for RanimScene
Source§impl Default for RanimScene
impl Default for RanimScene
Source§fn default() -> RanimScene
fn default() -> RanimScene
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for RanimScene
impl !RefUnwindSafe for RanimScene
impl !Send for RanimScene
impl !Sync for RanimScene
impl Unpin for RanimScene
impl UnsafeUnpin for RanimScene
impl !UnwindSafe for RanimScene
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
§impl<T> FromWorld for Twhere
T: Default,
impl<T> FromWorld for Twhere
T: Default,
§fn from_world(_world: &mut World) -> T
fn from_world(_world: &mut World) -> T
Creates Self using default().
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> IntoResult<T> for T
impl<T> IntoResult<T> for T
§fn into_result(self) -> Result<T, RunSystemError>
fn into_result(self) -> Result<T, RunSystemError>
Converts this type into the system output type.