Adding FOURCC usb camera support (#1366)

* Adding FOURCC usb camera support

* Improved warnings

* more checks and warnings
This commit is contained in:
matlabbe
2024-10-27 18:09:07 -07:00
committed by GitHub
parent 2454b04f1f
commit 8b21c27f5f
6 changed files with 319 additions and 69 deletions

View File

@@ -69,6 +69,7 @@ public:
virtual std::string getSerial() const;
void setResolution(int width, int height) {_width=width, _height=height;}
void setFOURCC(const std::string & fourcc) { _fourcc = fourcc; }
protected:
virtual SensorData captureImage(SensorCaptureInfo * info = 0);
@@ -86,6 +87,7 @@ private:
int usbDevice2_;
int _width;
int _height;
std::string _fourcc;
};
} // namespace rtabmap

View File

@@ -62,6 +62,7 @@ public:
* has been loaded, thus resolution from calibration is used.
* */
void setResolution(int width, int height) {_width=width, _height=height;}
void setFOURCC(const std::string & fourcc) { _fourcc = fourcc; }
protected:
virtual SensorData captureImage(SensorCaptureInfo * info = 0);
@@ -79,6 +80,7 @@ private:
std::string _guid;
int _width;
int _height;
std::string _fourcc;
CameraModel _model;
};