FFmpeg
Loading...
Searching...
No Matches
v210dec.c File Reference
#include "avcodec.h"
#include "codec_internal.h"
#include "v210dec.h"
#include "v210dec_init.h"
#include "libavutil/bswap.h"
#include "libavutil/imgutils.h"
#include "libavutil/internal.h"
#include "libavutil/intreadwrite.h"
#include "libavutil/mem.h"
#include "thread.h"

Go to the source code of this file.

Data Structures

struct  ThreadData
 Used for passing data between threads. More...
 

Macros

#define V210DEC_FLAGS   AV_OPT_FLAG_DECODING_PARAM | AV_OPT_FLAG_VIDEO_PARAM
 

Functions

static av_cold int decode_init (AVCodecContext *avctx)
 
static void decode_row (const uint32_t *src, uint16_t *y, uint16_t *u, uint16_t *v, const int width, void(*unpack_frame)(const uint32_t *src, uint16_t *y, uint16_t *u, uint16_t *v, int width))
 
static int v210_decode_slice (AVCodecContext *avctx, void *arg, int jobnr, int threadnr)
 
static int v210_stride (int width, int align)
 
static int decode_frame (AVCodecContext *avctx, AVFrame *pic, int *got_frame, AVPacket *avpkt)
 

Variables

static const AVOption v210dec_options []
 
static const AVClass v210dec_class
 
const FFCodec ff_v210_decoder
 

Macro Definition Documentation

◆ V210DEC_FLAGS

Definition at line 219 of file v210dec.c.

Function Documentation

◆ decode_init()

static av_cold int decode_init ( AVCodecContext * avctx)
static

Definition at line 41 of file v210dec.c.

◆ decode_row()

static void decode_row ( const uint32_t * src,
uint16_t * y,
uint16_t * u,
uint16_t * v,
const int width,
void(* unpack_frame )(const uint32_t *src, uint16_t *y, uint16_t *u, uint16_t *v, int width) )
static

Definition at line 55 of file v210dec.c.

Referenced by decode_frame(), and v210_decode_slice().

◆ v210_decode_slice()

static int v210_decode_slice ( AVCodecContext * avctx,
void * arg,
int jobnr,
int threadnr )
static

Definition at line 107 of file v210dec.c.

Referenced by decode_frame().

◆ v210_stride()

static int v210_stride ( int width,
int align )
static

Definition at line 131 of file v210dec.c.

Referenced by decode_frame().

◆ decode_frame()

static int decode_frame ( AVCodecContext * avctx,
AVFrame * pic,
int * got_frame,
AVPacket * avpkt )
static

Definition at line 136 of file v210dec.c.

Variable Documentation

◆ v210dec_options

const AVOption v210dec_options[]
static
Initial value:
= {
{"custom_stride", "Custom V210 stride", 0x42 , AV_OPT_TYPE_INT,
{.i64 = 0}, -1, INT_MAX, V210DEC_FLAGS},
{NULL}
}
#define NULL
Definition coverity.c:32
@ AV_OPT_TYPE_INT
Underlying C type is int.
Definition opt.h:258
#define V210DEC_FLAGS
Definition v210dec.c:219

Definition at line 220 of file v210dec.c.

◆ v210dec_class

const AVClass v210dec_class
static
Initial value:
= {
.class_name = "V210 Decoder",
.item_name = av_default_item_name,
.option = v210dec_options,
}
const char * av_default_item_name(void *ptr)
Return the context name.
Definition log.c:241
#define LIBAVUTIL_VERSION_INT
Definition version.h:85
static const AVOption v210dec_options[]
Definition v210dec.c:220

Definition at line 226 of file v210dec.c.

◆ ff_v210_decoder

const FFCodec ff_v210_decoder
Initial value:
= {
.p.name = "v210",
CODEC_LONG_NAME("Uncompressed 4:2:2 10-bit"),
.p.type = AVMEDIA_TYPE_VIDEO,
.priv_data_size = sizeof(V210DecContext),
.p.capabilities = AV_CODEC_CAP_DR1 |
.p.priv_class = &v210dec_class,
}
#define FF_CODEC_DECODE_CB(func)
#define CODEC_LONG_NAME(str)
int(* init)(AVBSFContext *ctx)
Definition dts2pts.c:608
#define AV_CODEC_CAP_DR1
Codec uses get_buffer() or get_encode_buffer() for allocating buffers and supports custom allocators.
Definition codec.h:49
#define AV_CODEC_CAP_SLICE_THREADS
Codec supports slice-based (or partition-based) multithreading.
Definition codec.h:102
#define AV_CODEC_CAP_FRAME_THREADS
Codec supports frame-level multithreading.
Definition codec.h:98
@ AV_CODEC_ID_V210
Definition codec_id.h:177
@ AVMEDIA_TYPE_VIDEO
Definition avutil.h:200
static av_cold int decode_init(AVCodecContext *avctx)
Definition 4xm.c:998
static int decode_frame(AVCodecContext *avctx, AVFrame *picture, int *got_frame, AVPacket *avpkt)
Definition 4xm.c:837
static const AVClass v210dec_class
Definition v210dec.c:226

Definition at line 233 of file v210dec.c.