Trait v4l::io::traits::CaptureStream

source ·
pub trait CaptureStream<'a>: Stream {
    // Required methods
    fn queue(&mut self, index: usize) -> Result<()>;
    fn dequeue(&mut self) -> Result<usize>;
    fn next(&'a mut self) -> Result<(&Self::Item, &Metadata)>;
}

Required Methods§

source

fn queue(&mut self, index: usize) -> Result<()>

Insert a buffer into the drivers’ incoming queue

source

fn dequeue(&mut self) -> Result<usize>

Remove a buffer from the drivers’ outgoing queue

source

fn next(&'a mut self) -> Result<(&Self::Item, &Metadata)>

Fetch a new frame by first queueing and then dequeueing. First time initialization is performed if necessary.

Implementors§

source§

impl<'a> CaptureStream<'a> for v4l::io::userptr::stream::Stream

source§

impl<'a, 'b> CaptureStream<'b> for v4l::io::mmap::stream::Stream<'a>