24#include <linux/usb/video.h>
25#include <linux/videodev2.h>
73 bool multicam =
false);
102 bool const itsMulticam;
109 std::future<void> itsRunFuture;
110 std::atomic<bool> itsRunning;
112 void processEvents();
113 void processEventSetup(
struct usb_ctrlrequest
const & ctrl,
struct uvc_request_data & resp);
114 void processEventStandard(
struct usb_ctrlrequest
const & ctrl,
struct uvc_request_data & resp);
115 void processEventClass(
struct usb_ctrlrequest
const & ctrl,
struct uvc_request_data & resp);
118 void processEventControl(uint8_t req, uint8_t cs, uint8_t entity_id, uint8_t len,
struct uvc_request_data & resp);
119 void processEventStreaming(uint8_t req, uint8_t cs,
struct uvc_request_data & resp);
122 struct v4l2_format itsFormat;
124 void fillStreamingControl(
struct uvc_streaming_control * ctrl,
VideoMapping const & m);
125 std::atomic<bool> itsStreaming;
129 struct uvc_streaming_control itsProbe;
130 struct uvc_streaming_control itsCommit;
132 std::deque<RawImage> itsImageQueue;
133 std::deque<size_t> itsDoneImgs;
135 mutable std::timed_mutex itsMtx;
JeVois processing engine - gets images from camera sensor, processes them, and sends results over USB...
JeVois gadget driver - exposes a uvcvideo interface to host computer connected over USB.
void streamOff() override
Stop streaming.
void abortStream() override
Abort streaming.
void get(RawImage &img) override
Get a pre-allocated image so that we can fill the pixel data and later send out over USB using send()
virtual ~Gadget()
Close the device and free all resources.
void setFormat(jevois::VideoMapping const &m) override
Set the video format and frame rate.
void streamOn() override
Start streaming.
void send(RawImage const &img) override
Send an image out over USB to the host computer.
A raw image as coming from a V4L2 Camera and/or being sent out to a USB Gadget.
Collection of buffers for V4L2 video frames (Camera or Gadget) with hooks to the MMAP'd areas.
Base class for video output. Gadget, MovieOutput, VideoDisplay, and VideoOutputNone derive from it.
Main namespace for all JeVois classes and functions.
Simple struct to hold video mapping definitions for the processing Engine.