Struct immi::animations::Zoom [] [src]

pub struct Zoom {
    pub initial_zoom: f32,
}

Zooms the element from initial_zoom to 1.0.

Fields

initial_zoom: f32

The initial zoom of the element at the start of the animation.

1.0 is the normal size. 2.0 means twice bigger. 0.5 means twice smaller.

Methods

impl Zoom
[src]

fn new(initial_zoom: f32) -> Zoom

Builds a Zoom object.

Trait Implementations

impl Animation for Zoom
[src]

fn animate(&self, percent: f32) -> Matrix

Takes an animation percentage between 0.0 and 1.0. Returns the most-inner matrix to multiply the element with. Read more