pub struct Animation(_);
Implementations
sourceimpl Animation
impl Animation
pub fn from_file<P>(path: P) -> Option<Self> where
P: AsRef<Path>,
pub fn from_data<P>(data: String, key: String, resource_path: P) -> Option<Self> where
P: AsRef<Path>,
pub fn size(&self) -> Size
pub fn duration(&self) -> f64
pub fn totalframe(&self) -> u64
pub fn framerate(&self) -> f64
pub fn render_tree(&mut self, frame_num: u64, size: Size) -> LayerNode
pub fn frame_at_pos(&self, pos: f32) -> u64
pub fn render(
&mut self,
frame_num: u64,
buffer: &mut Vec<u32>,
size: Size
) -> Result<(), RenderError>
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Animation
impl !Send for Animation
impl !Sync for Animation
impl Unpin for Animation
impl UnwindSafe for Animation
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more