Skip to main content

FrameEncoder

Trait FrameEncoder 

Source
pub trait FrameEncoder: Send + 'static {
    // Required methods
    fn encode(&mut self, frame: FrameEnvelope) -> Result<()>;
    fn flush(&mut self) -> Result<()>;
}
Expand description

Video frame encoder consuming GPU-resident NV12 frames.

Required Methods§

Source

fn encode(&mut self, frame: FrameEnvelope) -> Result<()>

Submit one GPU-resident NV12 frame for encoding.

Source

fn flush(&mut self) -> Result<()>

Flush any pending frames and finalise the bitstream.

Implementors§