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

#47 in Video

Download history 924/week @ 2024-07-25 798/week @ 2024-08-01 790/week @ 2024-08-08 591/week @ 2024-08-15 748/week @ 2024-08-22 723/week @ 2024-08-29 868/week @ 2024-09-05 780/week @ 2024-09-12 944/week @ 2024-09-19 1430/week @ 2024-09-26 1010/week @ 2024-10-03 790/week @ 2024-10-10 927/week @ 2024-10-17 751/week @ 2024-10-24 660/week @ 2024-10-31 673/week @ 2024-11-07

3,156 downloads per month
Used in 8 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.7–1.6MB
~34K SLoC