This is an automated email from the ASF dual-hosted git repository. acassis pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/nuttx.git
commit 34a64454a9b8b1e2c95dc571d3d93a35f1a193ba Author: niyinghao <[email protected]> AuthorDate: Wed Sep 3 20:38:57 2025 +0800 sys/videoio: add more v4l2-buffer flags from linux/videodev2.h Add V4L2_BUF_FLAG_PFRAME, V4L2_BUF_FLAG_BFRAME and V4L2_BUF_FLAG_ERROR with the values Linux uses. V4L2_BUF_FLAG_ERROR moves from the NuttX-specific value 0x0001 to the Linux value 0x00000040. Signed-off-by: niyinghao <[email protected]> --- include/sys/videoio.h | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/include/sys/videoio.h b/include/sys/videoio.h index 92823f2d0b8..a398199cc7e 100644 --- a/include/sys/videoio.h +++ b/include/sys/videoio.h @@ -240,10 +240,6 @@ extern "C" #define V4L2_REQBUFS_COUNT_MAX CONFIG_VIDEO_REQBUFS_COUNT_MAX -/* Buffer error flag */ - -#define V4L2_BUF_FLAG_ERROR (0x0001) - /* Values for v4l2_std_id */ /* One bit for each */ @@ -804,6 +800,18 @@ typedef struct v4l2_buffer v4l2_buffer_t; #define V4L2_BUF_FLAG_KEYFRAME 0x00000008 +/* Image is a P-frame */ + +#define V4L2_BUF_FLAG_PFRAME 0x00000010 + +/* Image is a B-frame */ + +#define V4L2_BUF_FLAG_BFRAME 0x00000020 + +/* Buffer is ready, but the data contained within is corrupted. */ + +#define V4L2_BUF_FLAG_ERROR 0x00000040 + /* mem2mem encoder/decoder */ #define V4L2_BUF_FLAG_LAST 0x00100000
