Skip to main content

VideoFrameSource

Trait VideoFrameSource 

Source
pub trait VideoFrameSource<T, const CHANNELS: usize> {
    // Required method
    fn next_frame(&mut self) -> VisionResult<Option<VideoFrame<T, CHANNELS>>>;
}
Expand description

Pull-based video source implemented by optional codec/camera adapters.

Required Methods§

Source

fn next_frame(&mut self) -> VisionResult<Option<VideoFrame<T, CHANNELS>>>

Returns the next frame, or None at end of stream.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<T, const CHANNELS: usize> VideoFrameSource<T, CHANNELS> for MemoryVideoSource<T, CHANNELS>

Available on crate feature video-adapters only.