7 unstable releases

0.4.0 Apr 3, 2024
0.3.3 Sep 5, 2022
0.3.2 Apr 23, 2022
0.3.0 Aug 2, 2021
0.1.0 Jan 16, 2021

#60 in Video

Download history 281/week @ 2023-12-21 307/week @ 2023-12-28 273/week @ 2024-01-04 268/week @ 2024-01-11 270/week @ 2024-01-18 270/week @ 2024-01-25 602/week @ 2024-02-01 379/week @ 2024-02-08 410/week @ 2024-02-15 492/week @ 2024-02-22 470/week @ 2024-02-29 453/week @ 2024-03-07 432/week @ 2024-03-14 352/week @ 2024-03-21 455/week @ 2024-03-28 596/week @ 2024-04-04

1,901 downloads per month
Used in 7 crates

MIT license

13KB
242 lines

ffprobe-rs

crates.io Documentation

Simple wrapper for the ffprobe CLI utility, which is part of the ffmpeg tool suite.

This crate allows retrieving typed information about media files (images and videos) by invoking ffprobe with JSON output options and deserializing the data into convenient Rust types.

Example

fn main() {
    match ffprobe::ffprobe("path/to/video.mp4") {
        Ok(info) => {
	    dbg!(info);
        },
	Err(err) => {
	    eprintln!("Could not analyze file with ffprobe: {:?}", err);
	}
    }
}

lib.rs:

Simple wrapper for the ffprobe CLI utility, which is part of the ffmpeg tool suite.

This crate allows retrieving typed information about media files (images and videos) by invoking ffprobe with JSON output options and deserializing the data into convenient Rust types.

match ffprobe::ffprobe("path/to/video.mp4") {
   Ok(info) => {
       dbg!(info);
   },
   Err(err) => {
       eprintln!("Could not analyze file with ffprobe: {:?}", err);
    },
}

Dependencies

~0.6–1.4MB
~31K SLoC