Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc
Commits
de537274
Commit
de537274
authored
Aug 24, 2013
by
Rafaël Carré
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mp4a packetizer: simplify loop
parent
d98042dd
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
20 deletions
+19
-20
modules/packetizer/mpeg4audio.c
modules/packetizer/mpeg4audio.c
+19
-20
No files found.
modules/packetizer/mpeg4audio.c
View file @
de537274
...
...
@@ -733,8 +733,7 @@ static int LOASParse(decoder_t *p_dec, uint8_t *p_buffer, int i_buffer)
bs_init
(
&
s
,
p_buffer
,
i_buffer
);
/* Read the stream mux configuration if present */
if
(
!
bs_read1
(
&
s
))
{
if
(
!
LatmReadStreamMuxConfiguration
(
&
p_sys
->
latm
,
&
s
)
&&
if
(
!
bs_read1
(
&
s
)
&&
!
LatmReadStreamMuxConfiguration
(
&
p_sys
->
latm
,
&
s
)
&&
p_sys
->
latm
.
i_streams
>
0
)
{
const
latm_stream_t
*
st
=
&
p_sys
->
latm
.
stream
[
0
];
...
...
@@ -742,9 +741,8 @@ static int LOASParse(decoder_t *p_dec, uint8_t *p_buffer, int i_buffer)
p_sys
->
i_rate
=
st
->
cfg
.
i_samplerate
;
p_sys
->
i_frame_length
=
st
->
cfg
.
i_frame_length
;
if
(
p_sys
->
i_channels
>
0
&&
p_sys
->
i_rate
>
0
&&
p_sys
->
i_frame_length
>
0
)
{
/* FIXME And if it changes ? */
if
(
p_sys
->
i_channels
&&
p_sys
->
i_rate
&&
p_sys
->
i_frame_length
>
0
)
{
if
(
!
p_dec
->
fmt_out
.
i_extra
&&
st
->
i_extra
>
0
)
{
p_dec
->
fmt_out
.
i_extra
=
st
->
i_extra
;
p_dec
->
fmt_out
.
p_extra
=
malloc
(
st
->
i_extra
);
...
...
@@ -757,7 +755,7 @@ static int LOASParse(decoder_t *p_dec, uint8_t *p_buffer, int i_buffer)
p_sys
->
b_latm_cfg
=
true
;
}
}
}
/* Wait for the configuration */
if
(
!
p_sys
->
b_latm_cfg
)
return
0
;
...
...
@@ -794,6 +792,7 @@ static int LOASParse(decoder_t *p_dec, uint8_t *p_buffer, int i_buffer)
}
}
}
/* Payload Data */
for
(
int
i_program
=
0
;
i_program
<
p_sys
->
latm
.
i_programs
;
i_program
++
)
{
for
(
int
i_layer
=
0
;
i_layer
<
p_sys
->
latm
.
pi_layers
[
i_program
];
i_layer
++
)
{
...
...
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