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
76f126ba
Commit
76f126ba
authored
Dec 23, 2012
by
Piotr Bandurski
Committed by
Michael Niedermayer
Dec 23, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rmdec: set bit rate for ra3
Signed-off-by:
Michael Niedermayer
<
michaelni@gmx.at
>
parent
8e09e183
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
1 deletion
+6
-1
rmdec.c
libavformat/rmdec.c
+6
-1
No files found.
libavformat/rmdec.c
View file @
76f126ba
...
...
@@ -127,9 +127,12 @@ static int rm_read_audio_stream_info(AVFormatContext *s, AVIOContext *pb,
/* ra type header */
version
=
avio_rb16
(
pb
);
/* version */
if
(
version
==
3
)
{
unsigned
bytes_per_minute
;
int
header_size
=
avio_rb16
(
pb
);
int64_t
startpos
=
avio_tell
(
pb
);
avio_skip
(
pb
,
14
);
avio_skip
(
pb
,
8
);
bytes_per_minute
=
avio_rb16
(
pb
);
avio_skip
(
pb
,
4
);
rm_read_metadata
(
s
,
0
);
if
((
startpos
+
header_size
)
>=
avio_tell
(
pb
)
+
2
)
{
// fourcc (should always be "lpcJ")
...
...
@@ -139,6 +142,8 @@ static int rm_read_audio_stream_info(AVFormatContext *s, AVIOContext *pb,
// Skip extra header crap (this should never happen)
if
((
startpos
+
header_size
)
>
avio_tell
(
pb
))
avio_skip
(
pb
,
header_size
+
startpos
-
avio_tell
(
pb
));
if
(
bytes_per_minute
)
st
->
codec
->
bit_rate
=
8LL
*
bytes_per_minute
/
60
;
st
->
codec
->
sample_rate
=
8000
;
st
->
codec
->
channels
=
1
;
st
->
codec
->
channel_layout
=
AV_CH_LAYOUT_MONO
;
...
...
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