History

[media] videodev2.h: add V4L2_FIELD_HAS_T_OR_B macro

Add a macro to test if the field consists of a single top or bottom field. Anyone who needs to work with fields as opposed to frame will need this.

Hans Verkuil committed 12 years ago

Commit e34c4db1 parent 72be89c1 file · +4 −0Browse files

Showing the changes to include/uapi/linux (1 of 1 file). Show all

Unified · Split

include/uapi/linux/videodev2.h+4−0
@@ -124,6 +124,10 @@ enum v4l2_field { · 123 unmodified lines
124 (field) == V4L2_FIELD_INTERLACED_BT ||\124 (field) == V4L2_FIELD_INTERLACED_BT ||\
125 (field) == V4L2_FIELD_SEQ_TB ||\125 (field) == V4L2_FIELD_SEQ_TB ||\
126 (field) == V4L2_FIELD_SEQ_BT)126 (field) == V4L2_FIELD_SEQ_BT)
127#define V4L2_FIELD_HAS_T_OR_B(field) \
128 ((field) == V4L2_FIELD_BOTTOM ||\
129 (field) == V4L2_FIELD_TOP ||\
130 (field) == V4L2_FIELD_ALTERNATE)
127 131
128enum v4l2_buf_type {132enum v4l2_buf_type {
129 V4L2_BUF_TYPE_VIDEO_CAPTURE = 1,133 V4L2_BUF_TYPE_VIDEO_CAPTURE = 1,