Name

struct vb2_buffer — represents a video buffer

Synopsis

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
};  

Members

v4l2_buf

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)

v4l2_planes[VIDEO_MAX_PLANES]

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

vb2_queue

the queue to which this driver belongs

num_planes

number of planes in the buffer on an internal driver queue

state

current buffer state; do not change

queued_entry

entry on the queued buffers list, which holds all buffers queued from userspace

done_entry

entry on the list that stores all buffers ready to be dequeued to userspace

planes[VIDEO_MAX_PLANES]

private per-plane information; do not change