libavdevice/v4l2.c File Reference
#include "config.h"
#include "libavformat/avformat.h"
#include <unistd.h>
#include <fcntl.h>
#include <sys/ioctl.h>
#include <sys/mman.h>
#include <sys/time.h>
#include <asm/types.h>
#include <linux/videodev2.h>
#include <time.h>
#include <strings.h>
Go to the source code of this file.
|
Data Structures |
struct | video_data |
struct | buff_data |
struct | fmt_map |
Enumerations |
enum | io_method { io_read,
io_mmap,
io_userptr
} |
Functions |
static int | device_open (AVFormatContext *ctx, uint32_t *capabilities) |
static int | device_init (AVFormatContext *ctx, int *width, int *height, uint32_t pix_fmt) |
static int | first_field (int fd) |
static uint32_t | fmt_ff2v4l (enum PixelFormat pix_fmt, enum CodecID codec_id) |
static enum PixelFormat | fmt_v4l2ff (uint32_t v4l2_fmt, enum CodecID codec_id) |
static enum CodecID | fmt_v4l2codec (uint32_t v4l2_fmt) |
static int | mmap_init (AVFormatContext *ctx) |
static int | read_init (AVFormatContext *ctx) |
static void | mmap_release_buffer (AVPacket *pkt) |
static int | mmap_read_frame (AVFormatContext *ctx, AVPacket *pkt) |
static int | read_frame (AVFormatContext *ctx, AVPacket *pkt) |
static int | mmap_start (AVFormatContext *ctx) |
static void | mmap_close (struct video_data *s) |
static int | v4l2_set_parameters (AVFormatContext *s1, AVFormatParameters *ap) |
static uint32_t | device_try_init (AVFormatContext *s1, const AVFormatParameters *ap, int *width, int *height, enum CodecID *codec_id) |
static int | v4l2_read_header (AVFormatContext *s1, AVFormatParameters *ap) |
static int | v4l2_read_packet (AVFormatContext *s1, AVPacket *pkt) |
static int | v4l2_read_close (AVFormatContext *s1) |
Variables |
static const int | desired_video_buffers = 256 |
static struct fmt_map | fmt_conversion_table [] |
AVInputFormat | v4l2_demuxer |
Enumeration Type Documentation
- Enumerator:
-
io_read |
|
io_mmap |
|
io_userptr |
|
Definition at line 49 of file v4l2.c.
Function Documentation
static int device_init |
( |
AVFormatContext * |
ctx, |
|
|
int * |
width, |
|
|
int * |
height, |
|
|
uint32_t |
pix_fmt | |
|
) |
| | [static] |
static int device_open |
( |
AVFormatContext * |
ctx, |
|
|
uint32_t * |
capabilities | |
|
) |
| | [static] |
static int first_field |
( |
int |
fd |
) |
[static] |
static enum CodecID fmt_v4l2codec |
( |
uint32_t |
v4l2_fmt |
) |
[static] |
static void mmap_close |
( |
struct video_data * |
s |
) |
[static] |
static void mmap_release_buffer |
( |
AVPacket * |
pkt |
) |
[static] |
Variable Documentation
Initial value:
Definition at line 703 of file v4l2.c.