| 
    FFmpeg
    
   | 
 
#include "avcodec.h"#include "codec_internal.h"#include "decode.h"#include "get_bits.h"#include "golomb.h"#include "libavutil/mem.h"#include "rv60data.h"#include "rv60dsp.h"#include "rv60vlcs.h"#include "threadprogress.h"#include "unary.h"#include "videodsp.h"#include "libavutil/attributes.h"Go to the source code of this file.
Data Structures | |
| struct | CoeffVLCs | 
| struct | Slice | 
| struct | ThreadContext | 
| struct | MV | 
| struct | MVInfo | 
| struct | BlockInfo | 
| struct | PUInfo | 
| struct | RV60Context | 
| struct | IntraPredContext | 
| struct | CUContext | 
| struct | Dimensions | 
Macros | |
| #define | MAX_VLC_SIZE 864 | 
| #define | CUR_PIC 0 | 
| #define | LAST_PIC 1 | 
| #define | NEXT_PIC 2 | 
| #define | MK_UNIQUELIST(name, type, max_size) | 
| #define | MEDIAN(x) | 
| #define | FILTER1(src, src_stride, src_y_ofs, step) | 
| #define | FILTER2(src, src_stride, src_y_ofs, step) | 
| #define | FILTER3(src, src_stride, src_y_ofs, step) | 
| #define | FILTER_CASE(idx, dst, dst_stride, filter, w, h) | 
| #define | FILTER_BLOCK(dst, dst_stride, src, src_stride, src_y_ofs, w, h, cond, step) | 
| #define | STRENGTH(el, lim) (FFABS(el) < (lim) ? 3 : 1) | 
| #define | CLIP_SYMM(a, b) av_clip(a, -(b), b) | 
Enumerations | |
| enum | CUType { CU_INTRA = 0, CU_INTER_MV, CU_SKIP, CU_INTER } | 
| enum | PUType {  PU_FULL = 0, PU_N2HOR, PU_N2VER, PU_QUARTERS, PU_N4HOR, PU_N34HOR, PU_N4VER, PU_N34VER }  | 
| enum | IntraMode { INTRAMODE_INDEX = 0, INTRAMODE_DC64, INTRAMODE_PLANE64, INTRAMODE_MODE } | 
| enum | MVRefEnum {  MVREF_NONE = 0, MVREF_REF0, MVREF_REF1, MVREF_BREF, MVREF_REF0ANDBREF, MVREF_SKIP0, MVREF_SKIP1, MVREF_SKIP2, MVREF_SKIP3 }  | 
| enum | { TRANSFORM_NONE = 0, TRANSFORM_16X16, TRANSFORM_8X8, TRANSFORM_4X4 } | 
Functions | |
| static const VLCElem * | gen_vlc (const uint8_t *bits, int size, VLCInitState *state) | 
| static void | build_coeff_vlc (const CoeffLens *lens, CoeffVLCs *vlc, int count, VLCInitState *state) | 
| static av_cold void | rv60_init_static_data (void) | 
| static int | progress_init (RV60Context *s, unsigned count) | 
| static av_cold int | rv60_decode_init (AVCodecContext *avctx) | 
| static int | update_dimensions_clear_info (RV60Context *s, int width, int height) | 
| static int | read_code012 (GetBitContext *gb) | 
| static int | read_frame_header (RV60Context *s, GetBitContext *gb, int *width, int *height) | 
| static int | read_slice_sizes (RV60Context *s, GetBitContext *gb) | 
| static int | read_intra_mode (GetBitContext *gb, int *param) | 
| static int | has_top_block (const RV60Context *s, int xpos, int ypos, int dx, int dy, int size) | 
| static int | has_left_block (const RV60Context *s, int xpos, int ypos, int dx, int dy, int size) | 
| static int | has_top_right_block (const RV60Context *s, int xpos, int ypos, int dx, int dy, int size) | 
| static int | has_left_down_block (const RV60Context *s, int xpos, int ypos, int dx, int dy, int size) | 
| static void | ipred_init (IntraPredContext *i) | 
| static void | populate_ipred (const RV60Context *s, CUContext *cu, const uint8_t *src, int stride, int xoff, int yoff, int size, int is_luma) | 
| static void | pred_plane (const IntraPredContext *p, uint8_t *dst, int stride, int size) | 
| static void | pred_dc (const IntraPredContext *p, uint8_t *dst, int stride, int size, int filter) | 
| static void | filter_weak (uint8_t *dst, const uint8_t *src, int size) | 
| static void | filter_bilin32 (uint8_t *dst, int v0, int v1, int size) | 
| static void | pred_hor_angle (uint8_t *dst, int stride, int size, int weight, const uint8_t *src) | 
| static void | pred_ver_angle (uint8_t *dst, int stride, int size, int weight, const uint8_t *src) | 
| static int | pred_angle (const IntraPredContext *p, uint8_t *dst, int stride, int size, int imode, int filter) | 
| static int | pu_is_intra (const PUInfo *pu) | 
| static int | ipm_compar (const void *a, const void *b) | 
| static int | reconstruct_intra (const RV60Context *s, const CUContext *cu, int size, int sub) | 
| static int | get_skip_mv_index (enum MVRefEnum mvref) | 
| static void | add_if_valid (unique_list_mvinfo *skip_cand, const MVInfo *mvi) | 
| static void | fill_mv_skip_cand (RV60Context *s, const CUContext *cu, unique_list_mvinfo *skip_cand, int size) | 
| static void | get_mv_dimensions (Dimensions *dim, enum PUType pu_type, int part_no, int size) | 
| static int | has_hor_split (enum PUType pu_type) | 
| static int | has_ver_split (enum PUType pu_type) | 
| static int | pu_type_num_parts (enum PUType pu_type) | 
| static void | get_next_mv (const RV60Context *s, const Dimensions *dim, enum PUType pu_type, int part_no, int *mv_pos, int *mv_x, int *mv_y) | 
| static int | mv_is_ref0 (enum MVRefEnum mvref) | 
| static int | mv_is_forward (enum MVRefEnum mvref) | 
| static int | mv_is_backward (enum MVRefEnum mvref) | 
| static int | mvinfo_matches_forward (const MVInfo *a, const MVInfo *b) | 
| static int | mvinfo_matches_backward (const MVInfo *a, const MVInfo *b) | 
| static int | mvinfo_is_deblock_cand (const MVInfo *a, const MVInfo *b) | 
| static void | mv_pred (MV *ret, MV a, MV b, MV c) | 
| static void | predict_mv (const RV60Context *s, MVInfo *dst, int mv_x, int mv_y, int mv_w, const MVInfo *src) | 
| static void | reconstruct (RV60Context *s, const CUContext *cu, int size) | 
| static void | read_mv (GetBitContext *gb, MV *mv) | 
| static void | read_mv_info (RV60Context *s, GetBitContext *gb, MVInfo *mvinfo, int size, enum PUType pu_type) | 
| static void | luma_mc (uint8_t *dst, int dst_stride, const uint8_t *src, int src_stride, int w, int h, int cx, int cy) | 
| static void | chroma_mc (uint8_t *dst, int dst_stride, const uint8_t *src, int src_stride, int w, int h, int x, int y) | 
| static int | check_pos (int x, int y, int cw, int ch, int w, int h, int dx, int dy, int e0, int e1, int e2, int e3) | 
| static void | mc (RV60Context *s, uint8_t *frame_data[3], int frame_linesize[3], const AVFrame *ref, int x, int y, int w, int h, MV mv, int avg) | 
| static void | avg_plane (uint8_t *dst, int dst_stride, const uint8_t *src, int src_stride, int w, int h) | 
| static void | avg (AVFrame *frame, uint8_t *prev_frame_data[3], int prev_frame_linesize[3], int x, int y, int w, int h) | 
| static int | get_c4x4_set (int qp, int is_intra) | 
| static int | quant (int v, int q) | 
| static int | decode_coeff (GetBitContext *gb, const CoeffVLCs *vlcs, int inval, int val) | 
| static void | decode_2x2_dc (GetBitContext *gb, const CoeffVLCs *vlcs, int16_t *coeffs, int stride, int block2, int dsc, int q_dc, int q_ac) | 
| static void | decode_2x2 (GetBitContext *gb, const CoeffVLCs *vlcs, int16_t *coeffs, int stride, int block2, int dsc, int q_ac) | 
| static void | decode_4x4_block_dc (GetBitContext *gb, const CoeffVLCs *vlcs, int is_luma, int16_t *coeffs, int stride, int q_dc, int q_ac) | 
| static void | decode_4x4_block (GetBitContext *gb, const CoeffVLCs *vlcs, int is_luma, int16_t *coeffs, int stride, int q_ac) | 
| static void | decode_cu_4x4in16x16 (GetBitContext *gb, int is_intra, int qp, int sel_qp, int16_t *y_coeffs, int16_t *u_coeffs, int16_t *v_coeffs, int cbp) | 
| static int | decode_cbp8 (GetBitContext *gb, int subset, int qp) | 
| static void | decode_cu_8x8 (GetBitContext *gb, int is_intra, int qp, int sel_qp, int16_t *y_coeffs, int16_t *u_coeffs, int16_t *v_coeffs, int ccbp, int mode4x4) | 
| static void | decode_cu_16x16 (GetBitContext *gb, int is_intra, int qp, int sel_qp, int16_t *y_coeffs, int16_t *u_coeffs, int16_t *v_coeffs, int ccbp) | 
| static int | decode_super_cbp (GetBitContext *gb, const VLCElem *vlc[4]) | 
| static int | decode_cbp16 (GetBitContext *gb, int subset, int qp) | 
| static int | decode_cu_r (RV60Context *s, AVFrame *frame, ThreadContext *thread, GetBitContext *gb, int xpos, int ypos, int log_size, int qp, int sel_qp) | 
| static int | deblock_get_pos (RV60Context *s, int xpos, int ypos) | 
| static void | deblock_set_strength (RV60Context *s, int xpos, int ypos, int size, int q, int strength) | 
| static int | deblock_get_top_strength (const RV60Context *s, int pos) | 
| static int | deblock_get_left_strength (const RV60Context *s, int pos) | 
| static void | deblock_set_top_strength (RV60Context *s, int pos, int strength) | 
| static void | deblock_set_left_strength (RV60Context *s, int pos, int strength) | 
| static void | derive_deblock_strength (RV60Context *s, int xpos, int ypos, int size) | 
| static void | filter_luma_edge (uint8_t *dst, int step, int stride, int mode1, int mode2, int lim1, int lim2) | 
| static void | filter_chroma_edge (uint8_t *dst, int step, int stride, int mode1, int mode2, int lim1, int lim2) | 
| static void | deblock_edge_ver (AVFrame *frame, int xpos, int ypos, int dblk_l, int dblk_r, int deblock_chroma) | 
| static void | deblock_edge_hor (AVFrame *frame, int xpos, int ypos, int dblk_t, int dblk_d, int deblock_chroma) | 
| static void | deblock8x8 (const RV60Context *s, AVFrame *frame, int xpos, int ypos, int dblkpos) | 
| static void | deblock (const RV60Context *s, AVFrame *frame, int xpos, int ypos, int size, int dpos) | 
| static void | deblock_cu_r (RV60Context *s, AVFrame *frame, ThreadContext *thread, int xpos, int ypos, int log_size, int qp) | 
| static int | read_qp_offset (GetBitContext *gb, int qp_off_type) | 
| static int | calc_sel_qp (int osvquant, int qp) | 
| static int | decode_slice (AVCodecContext *avctx, void *tdata, int cu_y, int threadnr) | 
| static int | rv60_decode_frame (AVCodecContext *avctx, AVFrame *frame, int *got_frame, AVPacket *avpkt) | 
| static av_cold void | rv60_flush (AVCodecContext *avctx) | 
| static av_cold int | rv60_decode_end (AVCodecContext *avctx) | 
Variables | |
| static const int8_t | frame_types [4] = {AV_PICTURE_TYPE_I, AV_PICTURE_TYPE_P, AV_PICTURE_TYPE_B, AV_PICTURE_TYPE_NONE} | 
| static const uint8_t | skip_mv_ref [4] = {MVREF_SKIP0, MVREF_SKIP1, MVREF_SKIP2, MVREF_SKIP3} | 
| static const VLCElem * | cbp8_vlc [7][4] | 
| static const VLCElem * | cbp16_vlc [7][4][4] | 
| static CoeffVLCs | intra_coeff_vlc [5] | 
| static CoeffVLCs | inter_coeff_vlc [7] | 
| static VLCElem | table_data [129148] | 
| const FFCodec | ff_rv60_decoder | 
| #define MEDIAN | ( | x | ) | 
| enum CUType | 
| enum PUType | 
| enum IntraMode | 
| enum MVRefEnum | 
| anonymous enum | 
      
  | 
  static | 
Definition at line 103 of file rv60dec.c.
Referenced by build_coeff_vlc(), and rv60_init_static_data().
      
  | 
  static | 
Definition at line 124 of file rv60dec.c.
Referenced by rv60_init_static_data().
      
  | 
  static | 
Definition at line 136 of file rv60dec.c.
Referenced by rv60_decode_init().
      
  | 
  static | 
Definition at line 233 of file rv60dec.c.
Referenced by rv60_decode_frame().
      
  | 
  static | 
      
  | 
  static | 
Definition at line 277 of file rv60dec.c.
Referenced by rv60_decode_frame().
      
  | 
  static | 
Definition at line 339 of file rv60dec.c.
Referenced by read_frame_header(), read_intra_mode(), and read_qp_offset().
      
  | 
  static | 
Definition at line 346 of file rv60dec.c.
Referenced by rv60_decode_frame().
      
  | 
  static | 
Definition at line 394 of file rv60dec.c.
Referenced by rv60_decode_frame().
      
  | 
  static | 
Definition at line 422 of file rv60dec.c.
Referenced by decode_cu_r().
      
  | 
  static | 
Definition at line 433 of file rv60dec.c.
Referenced by has_top_right_block(), predict_mv(), and reconstruct_intra().
      
  | 
  static | 
Definition at line 438 of file rv60dec.c.
Referenced by has_left_down_block(), and reconstruct_intra().
      
  | 
  static | 
Definition at line 443 of file rv60dec.c.
Referenced by populate_ipred().
      
  | 
  static | 
Definition at line 453 of file rv60dec.c.
Referenced by populate_ipred().
      
  | 
  static | 
Definition at line 487 of file rv60dec.c.
Referenced by populate_ipred().
      
  | 
  static | 
Definition at line 494 of file rv60dec.c.
Referenced by decode_cu_r().
      
  | 
  static | 
Definition at line 538 of file rv60dec.c.
Referenced by pred_angle().
      
  | 
  static | 
Definition at line 569 of file rv60dec.c.
Referenced by pred_angle().
      
  | 
  static | 
Definition at line 601 of file rv60dec.c.
Referenced by pred_angle().
      
  | 
  static | 
Definition at line 609 of file rv60dec.c.
Referenced by pred_angle().
      
  | 
  static | 
Definition at line 619 of file rv60dec.c.
Referenced by pred_angle().
      
  | 
  static | 
Definition at line 640 of file rv60dec.c.
Referenced by pred_angle().
      
  | 
  static | 
Definition at line 660 of file rv60dec.c.
Referenced by decode_cu_r().
      
  | 
  static | 
Definition at line 760 of file rv60dec.c.
Referenced by reconstruct_intra().
      
  | 
  static | 
Definition at line 765 of file rv60dec.c.
Referenced by reconstruct_intra().
      
  | 
  static | 
Definition at line 798 of file rv60dec.c.
Referenced by reconstruct().
      
  | 
  static | 
Definition at line 861 of file rv60dec.c.
Referenced by reconstruct().
      
  | 
  static | 
Definition at line 871 of file rv60dec.c.
Referenced by fill_mv_skip_cand().
      
  | 
  static | 
Definition at line 877 of file rv60dec.c.
Referenced by reconstruct().
      
  | 
  static | 
Definition at line 904 of file rv60dec.c.
Referenced by decode_cu_r(), and reconstruct().
      
  | 
  static | 
Definition at line 941 of file rv60dec.c.
Referenced by get_next_mv().
      
  | 
  static | 
Definition at line 946 of file rv60dec.c.
Referenced by get_next_mv().
      
  | 
  static | 
Definition at line 951 of file rv60dec.c.
Referenced by decode_cu_r(), and reconstruct().
      
  | 
  static | 
Definition at line 960 of file rv60dec.c.
Referenced by decode_cu_r(), and reconstruct().
      
  | 
  static | 
Definition at line 980 of file rv60dec.c.
Referenced by mvinfo_matches_forward().
      
  | 
  static | 
Definition at line 985 of file rv60dec.c.
Referenced by mvinfo_is_deblock_cand(), and predict_mv().
      
  | 
  static | 
Definition at line 990 of file rv60dec.c.
Referenced by mvinfo_is_deblock_cand(), mvinfo_matches_backward(), and predict_mv().
Definition at line 995 of file rv60dec.c.
Referenced by predict_mv().
Definition at line 1000 of file rv60dec.c.
Referenced by predict_mv().
Definition at line 1005 of file rv60dec.c.
Referenced by derive_deblock_strength().
Definition at line 1026 of file rv60dec.c.
Referenced by predict_mv().
      
  | 
  static | 
Definition at line 1044 of file rv60dec.c.
Referenced by reconstruct().
      
  | 
  static | 
Definition at line 1136 of file rv60dec.c.
Referenced by decode_cu_r().
      
  | 
  static | 
Definition at line 1194 of file rv60dec.c.
Referenced by read_mv_info().
      
  | 
  static | 
Definition at line 1200 of file rv60dec.c.
Referenced by decode_cu_r().
      
  | 
  static | 
      
  | 
  static | 
      
  | 
  static | 
      
  | 
  static | 
Definition at line 1331 of file rv60dec.c.
Referenced by decode_cu_r().
      
  | 
  static | 
      
  | 
  static | 
Definition at line 1406 of file rv60dec.c.
Referenced by decode_cu_r(), and mc().
      
  | 
  static | 
Definition at line 1416 of file rv60dec.c.
Referenced by decode_cu_16x16(), decode_cu_4x4in16x16(), and decode_cu_8x8().
      
  | 
  static | 
Definition at line 1424 of file rv60dec.c.
Referenced by decode_2x2(), and decode_2x2_dc().
      
  | 
  static | 
Definition at line 1429 of file rv60dec.c.
Referenced by decode_2x2(), and decode_2x2_dc().
      
  | 
  static | 
Definition at line 1446 of file rv60dec.c.
Referenced by decode_4x4_block_dc().
      
  | 
  static | 
Definition at line 1465 of file rv60dec.c.
Referenced by decode_4x4_block(), and decode_4x4_block_dc().
      
  | 
  static | 
Definition at line 1484 of file rv60dec.c.
Referenced by decode_cu_16x16(), decode_cu_4x4in16x16(), and decode_cu_8x8().
      
  | 
  static | 
Definition at line 1506 of file rv60dec.c.
Referenced by decode_cu_16x16(), decode_cu_4x4in16x16(), and decode_cu_8x8().
      
  | 
  static | 
Definition at line 1528 of file rv60dec.c.
Referenced by decode_cu_r().
      
  | 
  static | 
Definition at line 1552 of file rv60dec.c.
Referenced by decode_cu_r().
      
  | 
  static | 
Definition at line 1558 of file rv60dec.c.
Referenced by decode_cu_r().
      
  | 
  static | 
Definition at line 1592 of file rv60dec.c.
Referenced by decode_cu_r().
      
  | 
  static | 
Definition at line 1628 of file rv60dec.c.
Referenced by decode_cbp16().
      
  | 
  static | 
Definition at line 1653 of file rv60dec.c.
Referenced by decode_cu_r().
      
  | 
  static | 
Definition at line 1659 of file rv60dec.c.
Referenced by decode_slice().
      
  | 
  static | 
Definition at line 1918 of file rv60dec.c.
Referenced by deblock_cu_r(), deblock_set_strength(), and derive_deblock_strength().
      
  | 
  static | 
Definition at line 1923 of file rv60dec.c.
Referenced by deblock_cu_r().
      
  | 
  static | 
Definition at line 1940 of file rv60dec.c.
Referenced by derive_deblock_strength().
      
  | 
  static | 
Definition at line 1945 of file rv60dec.c.
Referenced by derive_deblock_strength().
      
  | 
  static | 
Definition at line 1950 of file rv60dec.c.
Referenced by derive_deblock_strength().
      
  | 
  static | 
Definition at line 1955 of file rv60dec.c.
Referenced by derive_deblock_strength().
      
  | 
  static | 
Definition at line 1960 of file rv60dec.c.
Referenced by deblock_cu_r().
      
  | 
  static | 
Definition at line 1977 of file rv60dec.c.
Referenced by deblock_edge_hor(), and deblock_edge_ver().
      
  | 
  static | 
Definition at line 2033 of file rv60dec.c.
Referenced by deblock_edge_hor(), and deblock_edge_ver().
      
  | 
  static | 
Definition at line 2071 of file rv60dec.c.
Referenced by deblock8x8().
      
  | 
  static | 
Definition at line 2090 of file rv60dec.c.
Referenced by deblock8x8().
      
  | 
  static | 
      
  | 
  static | 
Definition at line 2153 of file rv60dec.c.
Referenced by ctu_nz_tl_init(), deblock_cu_r(), generate(), and X264_init().
      
  | 
  static | 
Definition at line 2162 of file rv60dec.c.
Referenced by decode_slice().
      
  | 
  static | 
Definition at line 2209 of file rv60dec.c.
Referenced by decode_slice().
      
  | 
  static | 
Definition at line 2230 of file rv60dec.c.
Referenced by decode_slice().
      
  | 
  static | 
Definition at line 2245 of file rv60dec.c.
Referenced by rv60_decode_frame().
      
  | 
  static | 
      
  | 
  static | 
      
  | 
  static | 
      
  | 
  static | 
Definition at line 38 of file rv60dec.c.
Referenced by read_frame_header(), and xvid_ff_2pass_after().
      
  | 
  static | 
Definition at line 77 of file rv60dec.c.
Referenced by decode_cu_r().
      
  | 
  static | 
Definition at line 86 of file rv60dec.c.
Referenced by decode_cbp8(), and rv60_init_static_data().
      
  | 
  static | 
Definition at line 87 of file rv60dec.c.
Referenced by decode_cbp16(), and rv60_init_static_data().
      
  | 
  static | 
Definition at line 96 of file rv60dec.c.
Referenced by decode_cu_16x16(), decode_cu_4x4in16x16(), decode_cu_8x8(), and rv60_init_static_data().
      
  | 
  static | 
Definition at line 97 of file rv60dec.c.
Referenced by decode_cu_16x16(), decode_cu_4x4in16x16(), decode_cu_8x8(), and rv60_init_static_data().
      
  | 
  static | 
Definition at line 100 of file rv60dec.c.
Referenced by rv60_init_static_data().
| const FFCodec ff_rv60_decoder | 
 1.8.17