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
4fa24840
Commit
4fa24840
authored
Oct 02, 2013
by
Maxim Poliakovski
Committed by
Michael Niedermayer
Oct 02, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
atrac3/decode_gain_control: cosmetics
Signed-off-by:
Michael Niedermayer
<
michaelni@gmx.at
>
parent
4978be2b
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
13 deletions
+12
-13
atrac3.c
libavcodec/atrac3.c
+12
-13
No files found.
libavcodec/atrac3.c
View file @
4fa24840
...
...
@@ -418,28 +418,27 @@ static int decode_tonal_components(GetBitContext *gb,
static
int
decode_gain_control
(
GetBitContext
*
gb
,
GainBlock
*
block
,
int
num_bands
)
{
int
i
,
cf
,
num_data
;
int
i
,
b
;
int
*
level
,
*
loc
;
AtracGainInfo
*
gain
=
block
->
g_block
;
for
(
i
=
0
;
i
<=
num_bands
;
i
++
)
{
num_data
=
get_bits
(
gb
,
3
);
gain
[
i
].
num_points
=
num_data
;
level
=
gain
[
i
].
lev_code
;
loc
=
gain
[
i
].
loc_code
;
for
(
b
=
0
;
b
<=
num_bands
;
b
++
)
{
gain
[
b
].
num_points
=
get_bits
(
gb
,
3
);
level
=
gain
[
b
].
levcode
;
loc
=
gain
[
b
].
loccode
;
for
(
cf
=
0
;
cf
<
gain
[
i
].
num_points
;
cf
++
)
{
level
[
cf
]
=
get_bits
(
gb
,
4
);
loc
[
cf
]
=
get_bits
(
gb
,
5
);
if
(
cf
&&
loc
[
cf
]
<=
loc
[
cf
-
1
])
for
(
i
=
0
;
i
<
gain
[
b
].
num_points
;
i
++
)
{
level
[
i
]
=
get_bits
(
gb
,
4
);
loc
[
i
]
=
get_bits
(
gb
,
5
);
if
(
i
&&
loc
[
i
]
<=
loc
[
i
-
1
])
return
AVERROR_INVALIDDATA
;
}
}
/* Clear
the
unused blocks. */
for
(;
i
<
4
;
i
++
)
gain
[
i
].
num_points
=
0
;
/* Clear unused blocks. */
for
(;
b
<
4
;
b
++
)
gain
[
b
].
num_points
=
0
;
return
0
;
}
...
...
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