• Home
Name Date Size #Lines LOC

..--

src/03-May-2024-1,9161,499

tests/03-May-2024-186142

Cargo.tomlD03-May-2024223 1713

README.mdD03-May-20241.1 KiB3223

bindgen.shD03-May-20241.5 KiB4735

build.rsD03-May-2024631 157

README.md

1# Libvda Rust wrapper
2
3Note: This crate is specific to ChromeOS and requires the native
4(libvda)\[https://source.chromium.org/chromiumos/chromiumos/codesearch/+/main:src/platform2/arc/vm/libvda\]
5library at link time.
6
7Rust wrapper for libvda. This library is used to enable communication with Chrome's GPU process to
8perform hardware accelerated decoding and encoding. It is currently in development to be used by
9crosvm's virtio-video device.
10
11### Building for the host environment
12
13You can also execute `cargo` directly for faster build and tests. This would be useful when you are
14developing this crate. Since this crate depends on libvda.so, you need to install it to host
15environment first.
16
17```shell
18(chroot)$ sudo emerge chromeos-base/libvda        # Install libvda.so to host.
19# Build
20(chroot)$ cargo build
21# Unit tests
22(chroot)$ cargo test
23```
24
25## Updating generated bindings
26
27`src/bindings.rs` is automatically generated from `libvda_common.h`. `src/decode/bindings.rs` is
28automatically generated from `libvda_decode.h`. `src/encode/bindings.rs` is automatically generated
29from `libvda_encode.h`.
30
31See the header of the bindings file for the generation command.
32