10 unstable releases (4 breaking)

0.5.2 Nov 4, 2022
0.5.0 Jul 24, 2022
0.3.0 Mar 17, 2022
0.2.0 Nov 11, 2021

#4 in #lottie

Download history 23/week @ 2024-04-22 40/week @ 2024-04-29 26/week @ 2024-05-06 25/week @ 2024-05-13 39/week @ 2024-05-20 49/week @ 2024-05-27 40/week @ 2024-06-03 48/week @ 2024-06-10 19/week @ 2024-06-17 23/week @ 2024-06-24 41/week @ 2024-07-01 9/week @ 2024-07-08 23/week @ 2024-07-15 10/week @ 2024-07-22 16/week @ 2024-07-29 25/week @ 2024-08-05

75 downloads per month
Used in 6 crates (3 directly)

MIT license

17KB
336 lines

rlottie rlottie on crates.io rlottie docs License: MIT

Safe bindings to rlottie.


lib.rs:

Safe Rust bindings to rlottie.

Example

use rlottie::{Animation, Surface};

let mut animation = Animation::from_file(path_to_lottie_json)?;
let size = animation.size();
let mut surface = Surface::new(size);
for frame in 0 .. animation.totalframe() {
	animation.render(frame, &mut surface);
	for (x, y, color) in surface.pixels() {
		println!("frame {frame} at ({x}, {y}): {color:?}");
	}
}

Dependencies

~0.4–3MB
~56K SLoC