libavcodec/dv.c File Reference

#include "avcodec.h"
#include "dsputil.h"
#include "mpegvideo.h"
#include "simple_idct.h"
#include "dvdata.h"

Go to the source code of this file.

Data Structures

struct  DVVideoContext
struct  dv_vlc_pair
struct  BlockInfo
struct  EncBlockInfo

Defines

#define ALT_BITSTREAM_READER
#define DV_ANCHOR_SIZE   (2*12*27)
#define TEX_VLC_BITS   9
#define DV_VLC_MAP_RUN_SIZE   64
#define DV_VLC_MAP_LEV_SIZE   512
#define SC(x, y)   ((s[x] - s[y]) ^ ((s[x] - s[y]) >> 7))

Functions

static void dv_build_unquantize_tables (DVVideoContext *s, uint8_t *perm)
static int dvvideo_init (AVCodecContext *avctx)
static int get_bits_left (GetBitContext *s)
static int get_bits_size (GetBitContext *s)
static int put_bits_left (PutBitContext *s)
static void dv_decode_ac (GetBitContext *gb, BlockInfo *mb, DCTELEM *block)
static void bit_copy (PutBitContext *pb, GetBitContext *gb)
static void dv_decode_video_segment (DVVideoContext *s, const uint8_t *buf_ptr1, const uint16_t *mb_pos_ptr)
static av_always_inline int dv_rl2vlc (int run, int l, int sign, uint32_t *vlc)
static av_always_inline int dv_rl2vlc_size (int run, int l)
static av_always_inline
PutBitContext
dv_encode_ac (EncBlockInfo *bi, PutBitContext *pb_pool, PutBitContext *pb_end)
static av_always_inline void dv_set_class_number (DCTELEM *blk, EncBlockInfo *bi, const uint8_t *zigzag_scan, const int *weight, int bias)
static av_always_inline int dv_guess_dct_mode (DCTELEM *blk)
static void dv_guess_qnos (EncBlockInfo *blks, int *qnos)
static void dv_encode_video_segment (DVVideoContext *s, uint8_t *dif, const uint16_t *mb_pos_ptr)
static int dv_decode_mt (AVCodecContext *avctx, void *sl)
static int dv_write_pack (enum dv_pack_type pack_id, DVVideoContext *c, uint8_t *buf)
static void dv_format_frame (DVVideoContext *c, uint8_t *buf)
static int dvvideo_close (AVCodecContext *c)

Variables

static void * dv_anchor [DV_ANCHOR_SIZE]
static RL_VLC_ELEM dv_rl_vlc [1184]
static struct dv_vlc_pair dv_vlc_map [DV_VLC_MAP_RUN_SIZE][DV_VLC_MAP_LEV_SIZE]
static const uint16_t block_sizes [6]
static const int vs_total_ac_bits = (100 * 4 + 68*2) * 5
static const int mb_area_start [5] = { 1, 6, 21, 43, 64 }


Define Documentation

#define ALT_BITSTREAM_READER

Definition at line 36 of file dv.c.

#define DV_ANCHOR_SIZE   (2*12*27)

Definition at line 63 of file dv.c.

Referenced by dvvideo_init().

#define DV_VLC_MAP_LEV_SIZE   512

Definition at line 74 of file dv.c.

Referenced by dvvideo_init().

#define DV_VLC_MAP_RUN_SIZE   64

Definition at line 73 of file dv.c.

Referenced by dvvideo_init().

#define SC ( x,
 )     ((s[x] - s[y]) ^ ((s[x] - s[y]) >> 7))

Definition at line 737 of file dv.c.

Referenced by dv_guess_dct_mode().

#define TEX_VLC_BITS   9


Function Documentation

static void bit_copy ( PutBitContext pb,
GetBitContext gb 
) [inline, static]

Definition at line 352 of file dv.c.

Referenced by dv_decode_video_segment().

static void dv_build_unquantize_tables ( DVVideoContext s,
uint8_t perm 
) [static]

Definition at line 85 of file dv.c.

Referenced by dvvideo_init().

static void dv_decode_ac ( GetBitContext gb,
BlockInfo mb,
DCTELEM block 
) [static]

Definition at line 285 of file dv.c.

Referenced by dv_decode_video_segment().

static int dv_decode_mt ( AVCodecContext avctx,
void *  sl 
) [static]

Definition at line 989 of file dv.c.

static void dv_decode_video_segment ( DVVideoContext s,
const uint8_t buf_ptr1,
const uint16_t *  mb_pos_ptr 
) [inline, static]

Definition at line 365 of file dv.c.

Referenced by dv_decode_mt().

static av_always_inline PutBitContext* dv_encode_ac ( EncBlockInfo bi,
PutBitContext pb_pool,
PutBitContext pb_end 
) [static]

Definition at line 623 of file dv.c.

Referenced by dv_encode_video_segment().

static void dv_encode_video_segment ( DVVideoContext s,
uint8_t dif,
const uint16_t *  mb_pos_ptr 
) [inline, static]

Definition at line 831 of file dv.c.

static void dv_format_frame ( DVVideoContext c,
uint8_t buf 
) [static]

Definition at line 1144 of file dv.c.

static av_always_inline int dv_guess_dct_mode ( DCTELEM blk  )  [static]

Definition at line 738 of file dv.c.

Referenced by dv_encode_video_segment().

static void dv_guess_qnos ( EncBlockInfo blks,
int *  qnos 
) [inline, static]

Definition at line 762 of file dv.c.

Referenced by dv_encode_video_segment().

static av_always_inline int dv_rl2vlc ( int  run,
int  l,
int  sign,
uint32_t *  vlc 
) [static]

Definition at line 597 of file dv.c.

Referenced by dv_encode_ac().

static av_always_inline int dv_rl2vlc_size ( int  run,
int  l 
) [static]

Definition at line 603 of file dv.c.

Referenced by dv_guess_qnos(), and dv_set_class_number().

static av_always_inline void dv_set_class_number ( DCTELEM blk,
EncBlockInfo bi,
const uint8_t zigzag_scan,
const int *  weight,
int  bias 
) [static]

Definition at line 666 of file dv.c.

Referenced by dv_encode_video_segment().

static int dv_write_pack ( enum dv_pack_type  pack_id,
DVVideoContext c,
uint8_t buf 
) [inline, static]

Definition at line 1072 of file dv.c.

Referenced by dv_format_frame(), dv_inject_audio(), and dv_inject_metadata().

static int dvvideo_close ( AVCodecContext c  )  [static]

Definition at line 1223 of file dv.c.

static int dvvideo_init ( AVCodecContext avctx  )  [static]

Definition at line 110 of file dv.c.

static int get_bits_left ( GetBitContext s  )  [inline, static]

Definition at line 269 of file dv.c.

Referenced by bit_copy(), and dv_decode_video_segment().

static int get_bits_size ( GetBitContext s  )  [inline, static]

Definition at line 274 of file dv.c.

Referenced by dv_decode_ac().

static int put_bits_left ( PutBitContext s  )  [inline, static]

Definition at line 279 of file dv.c.

Referenced by dv_encode_ac().


Variable Documentation

const uint16_t block_sizes[6] [static]

Initial value:

 {
    112, 112, 112, 112, 80, 80
}

Definition at line 261 of file dv.c.

Referenced by dv_decode_video_segment(), and dv_encode_video_segment().

void* dv_anchor[DV_ANCHOR_SIZE] [static]

Definition at line 65 of file dv.c.

Referenced by dvvideo_init().

RL_VLC_ELEM dv_rl_vlc[1184] [static]

Definition at line 78 of file dv.c.

struct dv_vlc_pair dv_vlc_map[DV_VLC_MAP_RUN_SIZE][DV_VLC_MAP_LEV_SIZE] [static]

const int mb_area_start[5] = { 1, 6, 21, 43, 64 } [static]

Definition at line 267 of file dv.c.

Referenced by dv_guess_qnos(), and dv_set_class_number().

const int vs_total_ac_bits = (100 * 4 + 68*2) * 5 [static]

Definition at line 265 of file dv.c.

Referenced by dv_encode_video_segment(), and dv_guess_qnos().


Generated on Thu Apr 2 07:15:41 2009 for ffmpeg by  doxygen 1.5.6