diff options
author | Mason Carter <void.main.argc.argv@gmail.com> | 2013-12-21 17:27:18 -0800 |
---|---|---|
committer | Luca Barbato <lu_zero@gentoo.org> | 2013-12-22 18:31:44 +0100 |
commit | 61ae993957f8ff7e12c5983a1b21d5ec1965b328 (patch) | |
tree | e06188d84566f5f5fc58bef05259a036142acc81 /libavcodec/vc1.c | |
parent | 7398e0516f7fdf98e74e5ce8966ac02c28aba754 (diff) | |
download | ffmpeg-61ae993957f8ff7e12c5983a1b21d5ec1965b328.tar.gz |
vc1: Fix intensity compensation performance regression
Introduced by 28243b0d35b47bbf9abbd454fc444a6e0a9e7b71
Intensity compensation is always used once it was encountered, because
v->next_use_ic is never set back to zero.
Reset v->next_use_ic, when resetting v->next_luty/uv.
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Diffstat (limited to 'libavcodec/vc1.c')
-rw-r--r-- | libavcodec/vc1.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libavcodec/vc1.c b/libavcodec/vc1.c index 6d89e713a0..319230a3bb 100644 --- a/libavcodec/vc1.c +++ b/libavcodec/vc1.c @@ -614,6 +614,10 @@ static void rotate_luts(VC1Context *v) INIT_LUT(32, 0, v->curr_luty[0], v->curr_lutuv[0], 0); INIT_LUT(32, 0, v->curr_luty[1], v->curr_lutuv[1], 0); v->curr_use_ic = 0; + if (v->curr_luty == v->next_luty) { + // If we just initialized next_lut, clear next_use_ic to match. + v->next_use_ic = 0; + } } int ff_vc1_parse_frame_header(VC1Context *v, GetBitContext* gb) |