Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
c60cda7c
Commit
c60cda7c
authored
Apr 13, 2016
by
Alexandra Hájková
Committed by
Diego Biurrun
Nov 24, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ra288: Convert to the new bitstream reader
parent
7d8075cf
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
ra288.c
libavcodec/ra288.c
+5
-5
No files found.
libavcodec/ra288.c
View file @
c60cda7c
...
...
@@ -25,8 +25,8 @@
#define BITSTREAM_READER_LE
#include "avcodec.h"
#include "bitstream.h"
#include "celp_filters.h"
#include "get_bits.h"
#include "internal.h"
#include "lpc.h"
#include "ra288.h"
...
...
@@ -181,7 +181,7 @@ static int ra288_decode_frame(AVCodecContext * avctx, void *data,
float
*
out
;
int
i
,
ret
;
RA288Context
*
ractx
=
avctx
->
priv_data
;
GetBitContext
gb
;
BitstreamContext
bc
;
if
(
buf_size
<
avctx
->
block_align
)
{
av_log
(
avctx
,
AV_LOG_ERROR
,
...
...
@@ -198,11 +198,11 @@ static int ra288_decode_frame(AVCodecContext * avctx, void *data,
}
out
=
(
float
*
)
frame
->
data
[
0
];
init_get_bits
(
&
gb
,
buf
,
avctx
->
block_align
*
8
);
bitstream_init
(
&
bc
,
buf
,
avctx
->
block_align
*
8
);
for
(
i
=
0
;
i
<
RA288_BLOCKS_PER_FRAME
;
i
++
)
{
float
gain
=
amptable
[
get_bits
(
&
gb
,
3
)];
int
cb_coef
=
get_bits
(
&
gb
,
6
+
(
i
&
1
));
float
gain
=
amptable
[
bitstream_read
(
&
bc
,
3
)];
int
cb_coef
=
bitstream_read
(
&
bc
,
6
+
(
i
&
1
));
decode
(
ractx
,
gain
,
cb_coef
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment