aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/rangecoder.h
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2014-09-05 19:24:49 +0200
committerMichael Niedermayer <michaelni@gmx.at>2014-09-05 19:24:49 +0200
commit1e4e760f767b597f88442b75e90d726ae626b230 (patch)
treebbf016203da738a1f429becdc9e8568dd1b39aa1 /libavcodec/rangecoder.h
parent73aeb27cfe4ec51c2577097c980fe126dcd1908b (diff)
parent213e606752d16f51337e94431962fb5d7749c07e (diff)
downloadffmpeg-1e4e760f767b597f88442b75e90d726ae626b230.tar.gz
Merge commit '213e606752d16f51337e94431962fb5d7749c07e'
* commit '213e606752d16f51337e94431962fb5d7749c07e': Replace av_unused attributes by block structures Conflicts: libavcodec/h264_loopfilter.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/rangecoder.h')
-rw-r--r--libavcodec/rangecoder.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/libavcodec/rangecoder.h b/libavcodec/rangecoder.h
index 88e555f417..d36fbd7c54 100644
--- a/libavcodec/rangecoder.h
+++ b/libavcodec/rangecoder.h
@@ -115,7 +115,6 @@ static inline void refill(RangeCoder *c)
static inline int get_rac(RangeCoder *c, uint8_t *const state)
{
int range1 = (c->range * (*state)) >> 8;
- int av_unused one_mask;
c->range -= range1;
#if 1
@@ -131,13 +130,14 @@ static inline int get_rac(RangeCoder *c, uint8_t *const state)
return 1;
}
#else
- one_mask = (c->range - c->low - 1) >> 31;
+ {
+ int one_mask one_mask = (c->range - c->low - 1) >> 31;
- c->low -= c->range & one_mask;
- c->range += (range1 - c->range) & one_mask;
-
- *state = c->zero_state[(*state) + (256 & one_mask)];
+ c->low -= c->range & one_mask;
+ c->range += (range1 - c->range) & one_mask;
+ *state = c->zero_state[(*state) + (256 & one_mask)];
+ }
refill(c);
return one_mask & 1;