| 1 | /* --------------------------------------------------------------------------- |
| 2 | ** This software is in the public domain, furnished "as is", without technical |
| 3 | ** support, and with no warranty, express or implied, as to its usefulness for |
| 4 | ** any purpose. |
| 5 | ** |
| 6 | ** V4l2Capture.h |
| 7 | ** |
| 8 | ** V4L2 Capture wrapper |
| 9 | ** |
| 10 | ** -------------------------------------------------------------------------*/ |
| 11 | |
| 12 | |
| 13 | #ifndef V4L2_CAPTURE |
| 14 | #define V4L2_CAPTURE |
| 15 | |
| 16 | #include "V4l2Access.h" |
| 17 | |
| 18 | // --------------------------------- |
| 19 | // V4L2 Capture |
| 20 | // --------------------------------- |
| 21 | class V4l2Capture : public V4l2Access |
| 22 | { |
| 23 | protected: |
| 24 | V4l2Capture(V4l2Device* device); |
| 25 | |
| 26 | public: |
| 27 | static V4l2Capture* create(const V4L2DeviceParameters & param, IoType iotype = V4l2Access::IOTYPE_MMAP); |
| 28 | virtual ~V4l2Capture(); |
| 29 | |
| 30 | size_t read(char* buffer, size_t bufferSize); |
| 31 | int isReadable(timeval* tv); |
| 32 | }; |
| 33 | |
| 34 | |
| 35 | #endif |
| 36 | |