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
c7bd556d
Commit
c7bd556d
authored
May 30, 2012
by
Justin Ruggles
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lavfi: amix: check active input count before calling request_samples
fixes use of the amix filter with only 1 input
parent
6163d880
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
7 deletions
+12
-7
af_amix.c
libavfilter/af_amix.c
+12
-7
No files found.
libavfilter/af_amix.c
View file @
c7bd556d
...
...
@@ -389,6 +389,10 @@ static int request_frame(AVFilterLink *outlink)
int
ret
;
int
wanted_samples
,
available_samples
;
ret
=
calc_active_inputs
(
s
);
if
(
ret
<
0
)
return
ret
;
if
(
s
->
input_state
[
0
]
==
INPUT_OFF
)
{
ret
=
request_samples
(
ctx
,
1
);
if
(
ret
<
0
)
...
...
@@ -419,15 +423,16 @@ static int request_frame(AVFilterLink *outlink)
av_assert0
(
s
->
frame_list
->
nb_frames
>
0
);
wanted_samples
=
frame_list_next_frame_size
(
s
->
frame_list
);
ret
=
request_samples
(
ctx
,
wanted_samples
);
if
(
ret
<
0
)
return
ret
;
ret
=
calc_active_inputs
(
s
);
if
(
ret
<
0
)
return
ret
;
if
(
s
->
active_inputs
>
1
)
{
ret
=
request_samples
(
ctx
,
wanted_samples
);
if
(
ret
<
0
)
return
ret
;
ret
=
calc_active_inputs
(
s
);
if
(
ret
<
0
)
return
ret
;
available_samples
=
get_available_samples
(
s
);
if
(
!
available_samples
)
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