Name Date Size #Lines LOC

..--

src/H25-Apr-2025-1,419887

Cargo.tomlH A D25-Apr-2025214 1512

README.mdH A D25-Apr-20251 KiB2215

build.rsH A D25-Apr-20251.7 KiB5943

README.md

1# FFmpeg wrapper
2
3This is a minimal FFmpeg 5.0+ wrapper for use with the virtio-video device, allowing to run a
4virtual video device backed by software decoding or encoding. This is useful for development and
5testing in situations where no supported video acceleration is available on the host.
6
7Although several FFmpeg binding crates exist, most of them are not able to link against the system
8FFmpeg, and [the only one that does](https://crates.io/crates/ffmpeg-sys) is released under a
9software license that makes our lawyers nervous.
10
11So taking this in consideration, as well as the extra work that it is to depend on external Rust
12crates in ChromeOS, it is preferable to add our own simple bindings here that cover just the parts
13of FFmpeg that we need.
14
15This crate has minimal dependencies ; on the FFmpeg side, it just uses `libavcodec`, `libavutil` and
16`libswscale`.
17
18A few elements that bindgen cannot generate because they are behind C macros are re-defined in
19`avutil.rs` and `error.rs`, as well as tests to ensure their correctness.
20
21And that's about it.
22