69 Camera(std::string
const & devname, jevois::CameraSensor s = jevois::CameraSensor::any,
70 unsigned int const nbufs = 0);
123 void queryControl(
struct v4l2_queryctrl & qc)
const override;
128 void queryMenu(
struct v4l2_querymenu & qm)
const override;
133 void getControl(
struct v4l2_control & ctrl)
const;
137 void setControl(
struct v4l2_control
const & ctrl)
override;
175 jevois::CameraSensor itsSensor;
176 std::vector<std::shared_ptr<jevois::CameraDevice>> itsDev;
177 int itsDevIdx = -1, itsDev2Idx = -1;
178 int itsFd = -1, itsFd2 = -1;
181 mutable std::timed_mutex itsMtx;
JeVois camera driver class - grabs frames from a Video4Linux camera sensor.
void abortStream() override
Abort streaming.
unsigned short readRegister(unsigned short reg)
Read a value from one of the camera's registers.
void getControl(struct v4l2_control &ctrl) const
Get a control's current value, throw if unsupported by hardware.
~Camera()
Close the device and free all resources.
void setFormat(VideoMapping const &m) override
Set the video format and frame rate.
void get(RawImage &img) override
Get the next captured buffer.
void done2(RawImage &img) override
Indicate that user processing is done with an image previously obtained via get2()
bool hasScaledImage() const override
Check whether a second input image scaled by the JeVoisPro Platform ISP is available.
void get2(RawImage &img) override
Get the next captured buffer, for second ISP-scaled image.
void unlock()
Unlock the camera that was previously locked by lock()
void streamOn() override
Start streaming.
void setControl(struct v4l2_control const &ctrl) override
Set a control, throw if control not supported or the hardware rejects the value.
Flags readFlags()
Get the sensor flags.
void queryMenu(struct v4l2_querymenu &qm) const override
Get the available menu entry names for a menu-type control, throw if unsupported by hardware.
int lock()
Lock the camera and return its file descriptor.
void queryControl(struct v4l2_queryctrl &qc) const override
Get information about a control, throw if unsupported by hardware.
void streamOff() override
Stop streaming.
void done(RawImage &img) override
Indicate that user processing is done with an image previously obtained via get()
void writeRegister(unsigned short reg, unsigned short val)
Write a value to one of the camera's registers.
A raw image as coming from a V4L2 Camera and/or being sent out to a USB Gadget.
Main namespace for all JeVois classes and functions.
Simple struct to hold video mapping definitions for the processing Engine.