[−][src]Struct quicksilver::graphics::Animation
Deprecated since 0.3.16:
Animation is too inflexible for most users; an external solution is a better option
A linear series of images with a constant frame delay
Frames advance by discrete ticks, which should be run in the update
section of a
quicksilver application loop rather than the draw
section. Draws may happen as
often as possible, whereas updates will have consistent rates
Methods
impl Animation
[src]
pub fn new<I>(images: I, frame_delay: u32) -> Animation where
I: IntoIterator<Item = Image>,
[src]
I: IntoIterator<Item = Image>,
Create a new animation from a series of images and a frame delay
pub fn from_spritesheet<R>(
sheet: Image,
regions: R,
frame_delay: u32
) -> Animation where
R: IntoIterator<Item = Rectangle>,
[src]
sheet: Image,
regions: R,
frame_delay: u32
) -> Animation where
R: IntoIterator<Item = Rectangle>,
Create a new animation from regions of images from a spritesheet
pub fn tick(&mut self)
[src]
Tick the animation forward by one step
pub fn current_frame(&self) -> &Image
[src]
Get the current frame of the animation
Trait Implementations
Auto Trait Implementations
impl !Send for Animation
impl !Sync for Animation
impl Unpin for Animation
impl !UnwindSafe for Animation
impl !RefUnwindSafe for Animation
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> SetParameter for T
fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
T: Parameter<Self>,
T: Parameter<Self>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
[src]
SS: SubsetOf<SP>,
fn to_subset(&self) -> Option<SS>
[src]
fn is_in_subset(&self) -> bool
[src]
unsafe fn to_subset_unchecked(&self) -> SS
[src]
fn from_subset(element: &SS) -> SP
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,
fn vzip(self) -> V
impl<T> Downcast for T where
T: Any,
T: Any,