Libav
Functions | Variables
ffv1dec.c File Reference

FF Video Codec 1 (a lossless codec) decoder. More...

#include "libavutil/avassert.h"
#include "libavutil/pixdesc.h"
#include "libavutil/crc.h"
#include "libavutil/opt.h"
#include "libavutil/imgutils.h"
#include "libavutil/timer.h"
#include "avcodec.h"
#include "internal.h"
#include "get_bits.h"
#include "put_bits.h"
#include "rangecoder.h"
#include "golomb.h"
#include "mathops.h"
#include "ffv1.h"

Go to the source code of this file.

Functions

static av_flatten int get_symbol_inline (RangeCoder *c, uint8_t *state, int is_signed)
 
static av_noinline int get_symbol (RangeCoder *c, uint8_t *state, int is_signed)
 
static int get_vlc_symbol (GetBitContext *gb, VlcState *const state, int bits)
 
static av_always_inline void decode_line (FFV1Context *s, int w, int16_t *sample[2], int plane_index, int bits)
 
static void decode_plane (FFV1Context *s, uint8_t *src, int w, int h, int stride, int plane_index)
 
static void decode_rgb_frame (FFV1Context *s, uint8_t *src[3], int w, int h, int stride[3])
 
static int decode_slice_header (FFV1Context *f, FFV1Context *fs)
 
static int decode_slice (AVCodecContext *c, void *arg)
 
static int read_quant_table (RangeCoder *c, int16_t *quant_table, int scale)
 
static int read_quant_tables (RangeCoder *c, int16_t quant_table[MAX_CONTEXT_INPUTS][256])
 
static int read_extra_header (FFV1Context *f)
 
static int read_header (FFV1Context *f)
 
static av_cold int ffv1_decode_init (AVCodecContext *avctx)
 
static int ffv1_decode_frame (AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt)
 
static av_cold int ffv1_decode_close (AVCodecContext *avctx)
 

Variables

AVCodec ff_ffv1_decoder
 

Detailed Description

FF Video Codec 1 (a lossless codec) decoder.

Definition in file ffv1dec.c.

Function Documentation

◆ get_symbol_inline()

static av_flatten int get_symbol_inline ( RangeCoder c,
uint8_t state,
int  is_signed 
)
inlinestatic

Definition at line 43 of file ffv1dec.c.

Referenced by decode_line(), and get_symbol().

◆ get_symbol()

static av_noinline int get_symbol ( RangeCoder c,
uint8_t state,
int  is_signed 
)
static

Definition at line 63 of file ffv1dec.c.

Referenced by decode_slice_header(), read_extra_header(), read_header(), and read_quant_table().

◆ get_vlc_symbol()

static int get_vlc_symbol ( GetBitContext gb,
VlcState *const  state,
int  bits 
)
inlinestatic

Definition at line 68 of file ffv1dec.c.

Referenced by decode_line().

◆ decode_line()

static av_always_inline void decode_line ( FFV1Context s,
int  w,
int16_t *  sample[2],
int  plane_index,
int  bits 
)
static

Definition at line 95 of file ffv1dec.c.

Referenced by decode_plane(), and decode_rgb_frame().

◆ decode_plane()

static void decode_plane ( FFV1Context s,
uint8_t src,
int  w,
int  h,
int  stride,
int  plane_index 
)
static

Definition at line 166 of file ffv1dec.c.

Referenced by decode_slice().

◆ decode_rgb_frame()

static void decode_rgb_frame ( FFV1Context s,
uint8_t src[3],
int  w,
int  h,
int  stride[3] 
)
static

Definition at line 207 of file ffv1dec.c.

Referenced by decode_slice().

◆ decode_slice_header()

static int decode_slice_header ( FFV1Context f,
FFV1Context fs 
)
static

Definition at line 265 of file ffv1dec.c.

Referenced by decode_slice().

◆ decode_slice()

static int decode_slice ( AVCodecContext c,
void arg 
)
static

Definition at line 337 of file ffv1dec.c.

Referenced by dxtory_decode_v2(), and ffv1_decode_frame().

◆ read_quant_table()

static int read_quant_table ( RangeCoder c,
int16_t *  quant_table,
int  scale 
)
static

Definition at line 415 of file ffv1dec.c.

Referenced by read_quant_tables().

◆ read_quant_tables()

static int read_quant_tables ( RangeCoder c,
int16_t  quant_table[MAX_CONTEXT_INPUTS][256] 
)
static

Definition at line 442 of file ffv1dec.c.

Referenced by read_extra_header(), and read_header().

◆ read_extra_header()

static int read_extra_header ( FFV1Context f)
static

Definition at line 457 of file ffv1dec.c.

Referenced by ffv1_decode_init().

◆ read_header()

static int read_header ( FFV1Context f)
static

◆ ffv1_decode_init()

static av_cold int ffv1_decode_init ( AVCodecContext avctx)
static

Definition at line 820 of file ffv1dec.c.

◆ ffv1_decode_frame()

static int ffv1_decode_frame ( AVCodecContext avctx,
void data,
int *  got_frame,
AVPacket avpkt 
)
static

Definition at line 840 of file ffv1dec.c.

◆ ffv1_decode_close()

static av_cold int ffv1_decode_close ( AVCodecContext avctx)
static

Definition at line 954 of file ffv1dec.c.

Variable Documentation

◆ ff_ffv1_decoder

AVCodec ff_ffv1_decoder
Initial value:
= {
.name = "ffv1",
.long_name = NULL_IF_CONFIG_SMALL("FFmpeg video codec #1"),
.priv_data_size = sizeof(FFV1Context),
.capabilities = AV_CODEC_CAP_DR1 |
}
static av_cold int ffv1_decode_close(AVCodecContext *avctx)
Definition: ffv1dec.c:954
static int ffv1_decode_frame(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt)
Definition: ffv1dec.c:840
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
Definition: internal.h:148
static av_cold int ffv1_decode_init(AVCodecContext *avctx)
Definition: ffv1dec.c:820
static int decode(AVCodecContext *avctx, AVFrame *frame, int *got_frame, AVPacket *pkt)
Definition: avconv.c:1288
#define AV_CODEC_CAP_SLICE_THREADS
Codec supports slice-based (or partition-based) multithreading.
Definition: avcodec.h:897
static av_cold int init(AVCodecParserContext *s)
Definition: h264_parser.c:582
#define AV_CODEC_CAP_DR1
Codec uses get_buffer() for allocating buffers and supports custom allocators.
Definition: avcodec.h:838

Definition at line 965 of file ffv1dec.c.