[][src]Trait v4l::device::Device

pub trait Device {
    fn fd(&self) -> c_int;
fn typ(&self) -> Type; }

Manage buffers for a device

Required methods

fn fd(&self) -> c_int

Returns the raw fd of the device

fn typ(&self) -> Type

Type of the device (capture, overlay, output)

Loading content...

Implementors

impl Device for Device[src]

fn fd(&self) -> c_int[src]

Returns the raw fd of the device

Example

use v4l::capture::Device as CaptureDevice;
use v4l::device::Device;

if let Ok(dev) = CaptureDevice::new(0) {
    print!("Device file descriptor: {}", dev.fd());
}
Loading content...