rave_nvcodec/lib.rs
1#![doc = include_str!("../README.md")]
2//!
3//! # Stub mode
4//!
5//! When the `rave_nvcodec_stub` cfg is active (set by `build.rs` when the
6//! NVIDIA Video Codec SDK headers or libraries are not found), the `nvdec`
7//! and `nvenc` modules are replaced with stubs that return
8//! [`EngineError::Decode`](rave_core::error::EngineError::Decode) /
9//! [`EngineError::Encode`](rave_core::error::EngineError::Encode) immediately.
10//! This allows the workspace to build and run tests on CI runners without a
11//! GPU or NVIDIA drivers installed.
12
13pub mod config;
14
15#[cfg(rave_nvcodec_stub)]
16#[path = "nvdec_stub.rs"]
17pub mod nvdec;
18#[cfg(not(rave_nvcodec_stub))]
19pub mod nvdec;
20
21#[cfg(rave_nvcodec_stub)]
22#[path = "nvenc_stub.rs"]
23pub mod nvenc;
24#[cfg(not(rave_nvcodec_stub))]
25pub mod nvenc;
26
27pub mod sys;