Go to the documentation of this file.
24 #ifndef AVCODEC_V4L2_CONTEXT_H
25 #define AVCODEC_V4L2_CONTEXT_H
28 #include <linux/videodev2.h>
187 #endif // AVCODEC_V4L2_CONTEXT_H
enum AVPixelFormat av_pix_fmt
AVPixelFormat corresponding to this buffer context.
AVPixelFormat
Pixel format.
int ff_v4l2_context_dequeue_packet(V4L2Context *ctx, AVPacket *pkt)
Dequeues a buffer from a V4L2Context to an AVPacket.
void ff_v4l2_context_release(V4L2Context *ctx)
Releases a V4L2Context.
enum AVCodecID av_codec_id
AVCodecID corresponding to this buffer context.
This structure describes decoded (raw) audio or video data.
int streamon
Whether the stream has been started (VIDIOC_STREAMON has been sent).
int ff_v4l2_context_get_format(V4L2Context *ctx, int probe)
Queries the driver for a valid v4l2 format and copies it to the context.
V4L2Buffer (wrapper for v4l2_buffer management)
int ff_v4l2_context_enqueue_frame(V4L2Context *ctx, const AVFrame *f)
Enqueues a buffer to a V4L2Context from an AVFrame.
Rational number (pair of numerator and denominator).
enum v4l2_buf_type type
Type of this buffer context.
int ff_v4l2_context_init(V4L2Context *ctx)
Initializes a V4L2Context.
int ff_v4l2_context_enqueue_packet(V4L2Context *ctx, const AVPacket *pkt)
Enqueues a buffer to a V4L2Context from an AVPacket.
AVCodecID
Identify the syntax and semantics of the bitstream.
int width
Width and height of the frames it produces (in case of a capture context, e.g.
int ff_v4l2_context_set_format(V4L2Context *ctx)
Sets the V4L2Context format in the v4l2 driver.
int num_buffers
Readonly after init.
V4L2Buffer * buffers
Indexed array of V4L2Buffers.
int ff_v4l2_context_set_status(V4L2Context *ctx, uint32_t cmd)
Sets the status of a V4L2Context.
static int probe(const AVProbeData *p)
int done
Either no more buffers available or an unrecoverable error was notified by the V4L2 kernel driver: on...
const char * name
context name.
This structure stores compressed data.
struct v4l2_format format
Format returned by the driver after initializing the buffer context.
AVRational sample_aspect_ratio
int ff_v4l2_context_dequeue_frame(V4L2Context *ctx, AVFrame *f, int timeout)
Dequeues a buffer from a V4L2Context to an AVFrame.