summaryrefslogtreecommitdiffstats
path: root/libavcodec/opus.h
diff options
context:
space:
mode:
authorAlexandra Hájková <alexandra@khirnov.net>2016-04-12 18:28:14 +0200
committerAnton Khirnov <anton@khirnov.net>2016-11-18 10:36:11 +0100
commitb3441350fadee0703eb935262c77dfb5c6269c38 (patch)
treeb1c0c1ae86f3071a9225413a6238778dfca93565 /libavcodec/opus.h
parent6f94a64bd6ae14d592835369a954e1378b79d786 (diff)
downloadffmpeg-streaming-b3441350fadee0703eb935262c77dfb5c6269c38.zip
ffmpeg-streaming-b3441350fadee0703eb935262c77dfb5c6269c38.tar.gz
opus: Convert to the new bitstream reader
Signed-off-by: Anton Khirnov <anton@khirnov.net>
Diffstat (limited to 'libavcodec/opus.h')
-rw-r--r--libavcodec/opus.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/libavcodec/opus.h b/libavcodec/opus.h
index 55c91fa..fbf67c9 100644
--- a/libavcodec/opus.h
+++ b/libavcodec/opus.h
@@ -32,7 +32,7 @@
#include "libavresample/avresample.h"
#include "avcodec.h"
-#include "get_bits.h"
+#include "bitstream.h"
#define MAX_FRAME_SIZE 1275
#define MAX_FRAMES 48
@@ -92,7 +92,7 @@ typedef struct RawBitsContext {
} RawBitsContext;
typedef struct OpusRangeCoder {
- GetBitContext gb;
+ BitstreamContext bc;
RawBitsContext rb;
unsigned int range;
unsigned int value;
@@ -196,7 +196,7 @@ typedef struct OpusContext {
static av_always_inline void opus_rc_normalize(OpusRangeCoder *rc)
{
while (rc->range <= 1<<23) {
- rc->value = ((rc->value << 8) | (get_bits(&rc->gb, 8) ^ 0xFF)) & ((1u << 31) - 1);
+ rc->value = ((rc->value << 8) | (bitstream_read(&rc->bc, 8) ^ 0xFF)) & ((1u << 31) - 1);
rc->range <<= 8;
rc->total_read_bits += 8;
}
OpenPOWER on IntegriCloud