summaryrefslogtreecommitdiffstats
path: root/libavcodec/ac3dec.c
diff options
context:
space:
mode:
authorJustin Ruggles <justin.ruggles@gmail.com>2008-05-31 22:12:01 +0000
committerJustin Ruggles <justin.ruggles@gmail.com>2008-05-31 22:12:01 +0000
commit9b57545934647539364140dc57719e4b25591172 (patch)
treedbcbda536bc2ce60c4ae1041ffc73c76f08caaa6 /libavcodec/ac3dec.c
parent6e74513a48bec5ccb99db1f8888b7b0669b9cae4 (diff)
downloadffmpeg-streaming-9b57545934647539364140dc57719e4b25591172.zip
ffmpeg-streaming-9b57545934647539364140dc57719e4b25591172.tar.gz
simplify
Originally committed as revision 13589 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/ac3dec.c')
-rw-r--r--libavcodec/ac3dec.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/libavcodec/ac3dec.c b/libavcodec/ac3dec.c
index a7c5fa4..7052fab 100644
--- a/libavcodec/ac3dec.c
+++ b/libavcodec/ac3dec.c
@@ -903,10 +903,7 @@ static int ac3_parse_audio_block(AC3DecodeContext *s, int blk)
s->exp_strategy[CPL_CH] = EXP_REUSE;
s->exp_strategy[s->lfe_ch] = EXP_REUSE;
for (ch = !s->cpl_in_use; ch <= s->channels; ch++) {
- if(ch == s->lfe_ch)
- s->exp_strategy[ch] = get_bits(gbc, 1);
- else
- s->exp_strategy[ch] = get_bits(gbc, 2);
+ s->exp_strategy[ch] = get_bits(gbc, 2 - (ch == s->lfe_ch));
if(s->exp_strategy[ch] != EXP_REUSE)
bit_alloc_stages[ch] = 3;
}
OpenPOWER on IntegriCloud