mirror of
https://github.com/opencv/opencv.git
synced 2025-07-30 01:06:38 +08:00
videoio: fix V4L compilation for older kernels
This commit is contained in:
parent
e0e537d94e
commit
9fc83ac544
@ -260,6 +260,10 @@ typedef uint32_t __u32;
|
|||||||
#define V4L2_CID_IRIS_ABSOLUTE (V4L2_CID_CAMERA_CLASS_BASE+17)
|
#define V4L2_CID_IRIS_ABSOLUTE (V4L2_CID_CAMERA_CLASS_BASE+17)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifndef v4l2_fourcc_be
|
||||||
|
#define v4l2_fourcc_be(a, b, c, d) (v4l2_fourcc(a, b, c, d) | (1U << 31))
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifndef V4L2_PIX_FMT_Y10
|
#ifndef V4L2_PIX_FMT_Y10
|
||||||
#define V4L2_PIX_FMT_Y10 v4l2_fourcc('Y', '1', '0', ' ')
|
#define V4L2_PIX_FMT_Y10 v4l2_fourcc('Y', '1', '0', ' ')
|
||||||
#endif
|
#endif
|
||||||
|
@ -22,6 +22,9 @@
|
|||||||
#include <linux/videodev2.h>
|
#include <linux/videodev2.h>
|
||||||
|
|
||||||
// workarounds for older versions
|
// workarounds for older versions
|
||||||
|
#ifndef v4l2_fourcc_be
|
||||||
|
#define v4l2_fourcc_be(a, b, c, d) (v4l2_fourcc(a, b, c, d) | (1U << 31))
|
||||||
|
#endif
|
||||||
#ifndef V4L2_PIX_FMT_Y10
|
#ifndef V4L2_PIX_FMT_Y10
|
||||||
#define V4L2_PIX_FMT_Y10 v4l2_fourcc('Y', '1', '0', ' ')
|
#define V4L2_PIX_FMT_Y10 v4l2_fourcc('Y', '1', '0', ' ')
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user