Create a new (uninitialized) V4L2 backend. 创建新的(未初始化的)V4L2 后端。
()
| 98 | /// Create a new (uninitialized) V4L2 backend. |
| 99 | /// 创建新的(未初始化的)V4L2 后端。 |
| 100 | pub fn new() -> Self { |
| 101 | Self { |
| 102 | fd: -1, |
| 103 | buffers: Vec::new(), |
| 104 | pending_queue: None, |
| 105 | width: 0, |
| 106 | height: 0, |
| 107 | pixel_format: PixelFormat::Mjpeg, |
| 108 | streaming: false, |
| 109 | } |
| 110 | } |
| 111 | |
| 112 | /// Open a device, negotiate format, allocate mmap buffers. |
| 113 | /// 打开设备、协商格式、分配 mmap 缓冲区。 |
nothing calls this directly
no outgoing calls
no test coverage detected