[][src]Trait v4l::video::traits::Capture

pub trait Capture {
    pub fn enum_frameintervals(
        &self,
        fourcc: FourCC,
        width: u32,
        height: u32
    ) -> Result<Vec<FrameInterval>>;
pub fn enum_framesizes(&self, fourcc: FourCC) -> Result<Vec<FrameSize>>;
pub fn enum_formats(&self) -> Result<Vec<FormatDescription>>;
pub fn format(&self) -> Result<Format>;
pub fn set_format(&self, fmt: &Format) -> Result<Format>;
pub fn params(&self) -> Result<CaptureParameters>;
pub fn set_params(
        &self,
        params: &CaptureParameters
    ) -> Result<CaptureParameters>; }

Capture device protocol

Required methods

pub fn enum_frameintervals(
    &self,
    fourcc: FourCC,
    width: u32,
    height: u32
) -> Result<Vec<FrameInterval>>
[src]

Returns a vector of all frame intervals that the device supports for the given pixel format and frame size

pub fn enum_framesizes(&self, fourcc: FourCC) -> Result<Vec<FrameSize>>[src]

Returns a vector of valid framesizes that the device supports for the given pixel format

pub fn enum_formats(&self) -> Result<Vec<FormatDescription>>[src]

Returns a vector of valid formats for this device

The "emulated" field describes formats filled in by libv4lconvert. There may be a conversion related performance penalty when using them.

pub fn format(&self) -> Result<Format>[src]

Returns the format currently in use

pub fn set_format(&self, fmt: &Format) -> Result<Format>[src]

Modifies the capture format and returns the actual format

The driver tries to match the format parameters on a best effort basis. Thus, if the combination of format properties cannot be achieved, the closest possible settings are used and reported back.

Arguments

  • fmt - Desired format

pub fn params(&self) -> Result<CaptureParameters>[src]

Returns the parameters currently in use

pub fn set_params(
    &self,
    params: &CaptureParameters
) -> Result<CaptureParameters>
[src]

Modifies the capture parameters and returns the actual parameters

Arguments

  • params - Desired parameters
Loading content...

Implementors

impl Capture for Device[src]

Loading content...