aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/huffyuvdec.c
diff options
context:
space:
mode:
authorChristophe Gisquet <christophe.gisquet@gmail.com>2014-08-20 23:19:48 +0000
committerMichael Niedermayer <michaelni@gmx.at>2014-08-21 02:19:55 +0200
commit331b1f7d813a0815ba0d57c3d4dccbed16c7a075 (patch)
tree75d6e61f55faa3b8f3ce3d65efc1c78bfc7d4bb9 /libavcodec/huffyuvdec.c
parente298b2f5d6db29f7fec60e6656d65e6c76ed4ebe (diff)
downloadffmpeg-331b1f7d813a0815ba0d57c3d4dccbed16c7a075.tar.gz
huffyuvdec: fix old (v1) rgba
Commit deadcf5e misplaced a hunk. Fixes ticket #3877. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/huffyuvdec.c')
-rw-r--r--libavcodec/huffyuvdec.c17
1 files changed, 8 insertions, 9 deletions
diff --git a/libavcodec/huffyuvdec.c b/libavcodec/huffyuvdec.c
index e4e5ea04bc..bc5ad151fb 100644
--- a/libavcodec/huffyuvdec.c
+++ b/libavcodec/huffyuvdec.c
@@ -729,7 +729,7 @@ static av_always_inline void decode_bgr_1(HYuvContext *s, int count,
for (i = 0; i < count && BITS_LEFT(re, &s->gb) > 0; i++) {
unsigned int index;
- int code, n;
+ int code, n, nb_bits;
UPDATE_CACHE(re, &s->gb);
index = SHOW_UBITS(re, &s->gb, VLC_BITS);
@@ -740,7 +740,6 @@ static av_always_inline void decode_bgr_1(HYuvContext *s, int count,
*(uint32_t *) &s->temp[0][4 * i] = s->pix_bgr_map[code];
LAST_SKIP_BITS(re, &s->gb, n);
} else {
- int nb_bits;
if (decorrelate) {
VLC_INTERN(s->temp[0][4 * i + G], s->vlc[1].table,
&s->gb, re, VLC_BITS, 3);
@@ -768,14 +767,14 @@ static av_always_inline void decode_bgr_1(HYuvContext *s, int count,
VLC_INTERN(s->temp[0][4 * i + R], s->vlc[2].table,
&s->gb, re, VLC_BITS, 3);
}
- if (alpha) {
- UPDATE_CACHE(re, &s->gb);
- index = SHOW_UBITS(re, &s->gb, VLC_BITS);
- VLC_INTERN(s->temp[0][4 * i + A], s->vlc[2].table,
- &s->gb, re, VLC_BITS, 3);
- } else
- s->temp[0][4 * i + A] = 0;
}
+ if (alpha) {
+ UPDATE_CACHE(re, &s->gb);
+ index = SHOW_UBITS(re, &s->gb, VLC_BITS);
+ VLC_INTERN(s->temp[0][4 * i + A], s->vlc[2].table,
+ &s->gb, re, VLC_BITS, 3);
+ } else
+ s->temp[0][4 * i + A] = 0;
}
CLOSE_READER(re, &s->gb);
}