mod image;
#[cfg(feature = "jpeg")]
mod jpg;
mod png;
mod snapshot;
#[cfg(test)]
mod tests;
pub use image::{Image, src_over, unpremultiply};
#[cfg(feature = "jpeg")]
pub use jpg::{Nv12Frame, write_jpg, write_jpg_nv12};
pub use png::write_png;
pub use snapshot::snapshot;
#[derive(Debug, thiserror::Error)]
#[non_exhaustive]
pub enum CaptureError {
#[error("the CRTC is not driving a mode")]
NoMode,
#[error("no plane on the CRTC could be read back")]
NothingReadable,
#[error("the image is empty")]
EmptyImage,
#[error("io: {0}")]
Io(#[source] std::io::Error),
}