Libav
Data Structures | Macros | Functions | Variables
rv10.c File Reference

RV10/RV20 decoder. More...

#include "libavutil/imgutils.h"
#include "avcodec.h"
#include "error_resilience.h"
#include "internal.h"
#include "mpegvideo.h"
#include "mpeg4video.h"
#include "h263.h"

Go to the source code of this file.

Data Structures

struct  RVDecContext
 

Macros

#define RV_GET_MAJOR_VER(x)   ((x) >> 28)
 
#define RV_GET_MINOR_VER(x)   (((x) >> 20) & 0xFF)
 
#define RV_GET_MICRO_VER(x)   (((x) >> 12) & 0xFF)
 
#define DC_VLC_BITS   14
 

Functions

int ff_rv_decode_dc (MpegEncContext *s, int n)
 
static int rv10_decode_picture_header (MpegEncContext *s)
 
static int rv20_decode_picture_header (RVDecContext *rv)
 
static av_cold int rv10_decode_init (AVCodecContext *avctx)
 
static av_cold int rv10_decode_end (AVCodecContext *avctx)
 
static int rv10_decode_packet (AVCodecContext *avctx, const uint8_t *buf, int buf_size, int buf_size2)
 
static int get_slice_offset (AVCodecContext *avctx, const uint8_t *buf, int n)
 
static int rv10_decode_frame (AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt)
 

Variables

static const uint16_t rv_lum_code [256]
 
static const uint8_t rv_lum_bits [256]
 
static const uint16_t rv_chrom_code [256]
 
static const uint8_t rv_chrom_bits [256]
 
static VLC rv_dc_lum
 
static VLC rv_dc_chrom
 
AVCodec ff_rv10_decoder
 
AVCodec ff_rv20_decoder
 

Detailed Description

RV10/RV20 decoder.

Definition in file rv10.c.

Macro Definition Documentation

#define RV_GET_MAJOR_VER (   x)    ((x) >> 28)

Definition at line 36 of file rv10.c.

Referenced by rv10_decode_init().

#define RV_GET_MINOR_VER (   x)    (((x) >> 20) & 0xFF)

Definition at line 37 of file rv10.c.

Referenced by rv10_decode_init(), and rv20_decode_picture_header().

#define RV_GET_MICRO_VER (   x)    (((x) >> 12) & 0xFF)

Definition at line 38 of file rv10.c.

Referenced by rv10_decode_init().

#define DC_VLC_BITS   14

Definition at line 40 of file rv10.c.

Referenced by ff_rv_decode_dc(), and rv10_decode_init().

Function Documentation

int ff_rv_decode_dc ( MpegEncContext s,
int  n 
)

Definition at line 189 of file rv10.c.

Referenced by h263_decode_block().

static int rv10_decode_picture_header ( MpegEncContext s)
static

Definition at line 240 of file rv10.c.

Referenced by rv10_decode_packet().

static int rv20_decode_picture_header ( RVDecContext rv)
static

Definition at line 299 of file rv10.c.

Referenced by rv10_decode_packet().

static av_cold int rv10_decode_init ( AVCodecContext avctx)
static

Definition at line 427 of file rv10.c.

static av_cold int rv10_decode_end ( AVCodecContext avctx)
static

Definition at line 503 of file rv10.c.

static int rv10_decode_packet ( AVCodecContext avctx,
const uint8_t buf,
int  buf_size,
int  buf_size2 
)
static

Definition at line 511 of file rv10.c.

Referenced by rv10_decode_frame().

static int get_slice_offset ( AVCodecContext avctx,
const uint8_t buf,
int  n 
)
static

Definition at line 647 of file rv10.c.

Referenced by rv10_decode_frame().

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

Definition at line 655 of file rv10.c.

Variable Documentation

const uint16_t rv_lum_code[256]
static

Definition at line 47 of file rv10.c.

Referenced by rv10_decode_init().

const uint8_t rv_lum_bits[256]
static

Definition at line 82 of file rv10.c.

Referenced by rv10_decode_init().

const uint16_t rv_chrom_code[256]
static

Definition at line 117 of file rv10.c.

Referenced by rv10_decode_init().

const uint8_t rv_chrom_bits[256]
static

Definition at line 152 of file rv10.c.

Referenced by rv10_decode_init().

VLC rv_dc_lum
static

Definition at line 187 of file rv10.c.

VLC rv_dc_chrom
static

Definition at line 187 of file rv10.c.

AVCodec ff_rv10_decoder
Initial value:
= {
.name = "rv10",
.long_name = NULL_IF_CONFIG_SMALL("RealVideo 1.0"),
.priv_data_size = sizeof(RVDecContext),
.capabilities = CODEC_CAP_DR1,
.pix_fmts = ff_pixfmt_list_420,
}
static int decode(MimicContext *ctx, int quality, int num_coeffs, int is_iframe)
Definition: mimic.c:269
#define CODEC_CAP_DR1
Codec uses get_buffer() for allocating buffers and supports custom allocators.
Definition: avcodec.h:711
enum AVPixelFormat ff_pixfmt_list_420[]
Definition: mpegvideo.c:107
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
Definition: internal.h:142
static int rv10_decode_frame(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt)
Definition: rv10.c:655
static av_cold int rv10_decode_end(AVCodecContext *avctx)
Definition: rv10.c:503
static av_cold int rv10_decode_init(AVCodecContext *avctx)
Definition: rv10.c:427
static void close(AVCodecParserContext *s)
Definition: h264_parser.c:489
static av_cold int init(AVCodecParserContext *s)
Definition: h264_parser.c:498

Definition at line 742 of file rv10.c.

AVCodec ff_rv20_decoder
Initial value:
= {
.name = "rv20",
.long_name = NULL_IF_CONFIG_SMALL("RealVideo 2.0"),
.priv_data_size = sizeof(RVDecContext),
.capabilities = CODEC_CAP_DR1 | CODEC_CAP_DELAY,
.pix_fmts = ff_pixfmt_list_420,
}
static int decode(MimicContext *ctx, int quality, int num_coeffs, int is_iframe)
Definition: mimic.c:269
#define CODEC_CAP_DR1
Codec uses get_buffer() for allocating buffers and supports custom allocators.
Definition: avcodec.h:711
enum AVPixelFormat ff_pixfmt_list_420[]
Definition: mpegvideo.c:107
#define CODEC_CAP_DELAY
Encoder or decoder requires flushing with NULL input at the end in order to give the complete and cor...
Definition: avcodec.h:740
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
Definition: internal.h:142
void ff_mpeg_flush(AVCodecContext *avctx)
Definition: mpegvideo.c:2433
static int rv10_decode_frame(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt)
Definition: rv10.c:655
static av_cold int rv10_decode_end(AVCodecContext *avctx)
Definition: rv10.c:503
static av_cold int rv10_decode_init(AVCodecContext *avctx)
Definition: rv10.c:427
static void close(AVCodecParserContext *s)
Definition: h264_parser.c:489
static av_cold void flush(AVCodecContext *avctx)
Flush (reset) the frame ID after seeking.
Definition: alsdec.c:1766
static av_cold int init(AVCodecParserContext *s)
Definition: h264_parser.c:498

Definition at line 755 of file rv10.c.