]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/rv34.h
Merge remote-tracking branch 'qatar/master'
[ffmpeg] / libavcodec / rv34.h
index 24a27ce4824e17d608913ed316a795086b6c0cc7..860aa566e4bbeefa8a3e899528dcc5644795cb31 100644 (file)
@@ -32,6 +32,7 @@
 #include "mpegvideo.h"
 
 #include "h264pred.h"
+#include "rv34dsp.h"
 
 #define MB_TYPE_SEPARATE_DC 0x01000000
 #define IS_SEPARATE_DC(a)   ((a) & MB_TYPE_SEPARATE_DC)
@@ -83,6 +84,7 @@ typedef struct SliceInfo{
 /** decoder context */
 typedef struct RV34DecContext{
     MpegEncContext s;
+    RV34DSPContext rdsp;
     int8_t *intra_types_hist;///< old block types, used for prediction
     int8_t *intra_types;     ///< block types
     int    intra_types_stride;///< block types array stride
@@ -105,6 +107,7 @@ typedef struct RV34DecContext{
     int rpr;                 ///< one field size in RV30 slice header
 
     int cur_pts, last_pts, next_pts;
+    int weight1, weight2;    ///< B frame distance fractions (0.14) used in motion compensation
 
     uint16_t *cbp_luma;      ///< CBP values for luma subblocks
     uint8_t  *cbp_chroma;    ///< CBP values for chroma subblocks
@@ -113,6 +116,11 @@ typedef struct RV34DecContext{
     /** 8x8 block available flags (for MV prediction) */
     DECLARE_ALIGNED(8, uint32_t, avail_cache)[3*4];
 
+    /** temporary blocks for RV4 weighted MC */
+    uint8_t *tmp_b_block_y[2];
+    uint8_t *tmp_b_block_uv[4];
+    uint8_t *tmp_b_block_base;
+
     int (*parse_slice_header)(struct RV34DecContext *r, GetBitContext *gb, SliceInfo *si);
     int (*decode_mb_info)(struct RV34DecContext *r);
     int (*decode_intra_types)(struct RV34DecContext *r, GetBitContext *gb, int8_t *dst);