diff options
author | Maxim Poliakovski <max_pole@gmx.de> | 2010-06-08 09:20:12 +0000 |
---|---|---|
committer | Maxim Poliakovski <max_pole@gmx.de> | 2010-06-08 09:20:12 +0000 |
commit | 0933f55829f63485ae967a08c8f7b2c2a77ee1af (patch) | |
tree | d12eb419dd7d72f71e74995647647990f2dff0fe /libavcodec/ivi_common.c | |
parent | 00ce2cbed55d2bfb67ed7c2abb734f452a7b9267 (diff) | |
download | ffmpeg-0933f55829f63485ae967a08c8f7b2c2a77ee1af.tar.gz |
Prepare Indeo4 (step 1): upscale indeo5 base tables by 2 and convert those into uint16_t.
Originally committed as revision 23523 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/ivi_common.c')
-rw-r--r-- | libavcodec/ivi_common.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libavcodec/ivi_common.c b/libavcodec/ivi_common.c index 5fcaca2c3e..6a493661d3 100644 --- a/libavcodec/ivi_common.c +++ b/libavcodec/ivi_common.c @@ -338,7 +338,8 @@ int ff_ivi_decode_blocks(GetBitContext *gb, IVIBandDesc *band, IVITile *tile) RVMapDesc *rvmap = band->rv_map; void (*mc_with_delta_func)(int16_t *buf, const int16_t *ref_buf, uint32_t pitch, int mc_type); void (*mc_no_delta_func) (int16_t *buf, const int16_t *ref_buf, uint32_t pitch, int mc_type); - const uint8_t *base_tab, *scale_tab; + const uint16_t *base_tab; + const uint8_t *scale_tab; prev_dc = 0; /* init intra prediction for the DC coefficient */ @@ -414,7 +415,7 @@ int ff_ivi_decode_blocks(GetBitContext *gb, IVIBandDesc *band, IVITile *tile) if (IVI_DEBUG && !val) av_log(NULL, AV_LOG_ERROR, "Val = 0 encountered!\n"); - q = (base_tab[pos] * scale_tab[quant]) >> 8; + q = (base_tab[pos] * scale_tab[quant]) >> 9; if (q > 1) val = val * q + FFSIGN(val) * (((q ^ 1) - 1) >> 1); trvec[pos] = val; |