struct vb2_buffer — represents a video buffer
struct vb2_buffer { struct v4l2_buffer v4l2_buf; struct v4l2_plane v4l2_planes[VIDEO_MAX_PLANES]; struct vb2_queue * vb2_queue; unsigned int num_planes; enum vb2_buffer_state state; struct list_head queued_entry; struct list_head done_entry; struct vb2_plane planes[VIDEO_MAX_PLANES]; #ifdef CONFIG_VIDEO_ADV_DEBUG #endif };
struct v4l2_buffer associated with this buffer; can be read by the driver and relevant entries can be changed by the driver in case of CAPTURE types (such as timestamp)
struct v4l2_planes associated with this buffer; can
be read by the driver and relevant entries can be
changed by the driver in case of CAPTURE types
(such as bytesused); NOTE that even for single-planar
types, the v4l2_planes[0] struct should be used
instead of v4l2_buf for filling bytesused - drivers
should use the vb2_set_plane_payload
function for that
the queue to which this driver belongs
number of planes in the buffer on an internal driver queue
current buffer state; do not change
entry on the queued buffers list, which holds all buffers queued from userspace
entry on the list that stores all buffers ready to be dequeued to userspace
private per-plane information; do not change