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
dda59d9a
Commit
dda59d9a
authored
Mar 13, 2013
by
Clément Bœsch
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lavfi/asetnsamples: raise filter_frame() error.
parent
c82bb281
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
5 deletions
+9
-5
af_asetnsamples.c
libavfilter/af_asetnsamples.c
+9
-5
No files found.
libavfilter/af_asetnsamples.c
View file @
dda59d9a
...
@@ -94,7 +94,7 @@ static int push_samples(AVFilterLink *outlink)
...
@@ -94,7 +94,7 @@ static int push_samples(AVFilterLink *outlink)
{
{
ASNSContext
*
asns
=
outlink
->
src
->
priv
;
ASNSContext
*
asns
=
outlink
->
src
->
priv
;
AVFrame
*
outsamples
=
NULL
;
AVFrame
*
outsamples
=
NULL
;
int
nb_out_samples
,
nb_pad_samples
;
int
ret
,
nb_out_samples
,
nb_pad_samples
;
if
(
asns
->
pad
)
{
if
(
asns
->
pad
)
{
nb_out_samples
=
av_audio_fifo_size
(
asns
->
fifo
)
?
asns
->
nb_out_samples
:
0
;
nb_out_samples
=
av_audio_fifo_size
(
asns
->
fifo
)
?
asns
->
nb_out_samples
:
0
;
...
@@ -125,7 +125,9 @@ static int push_samples(AVFilterLink *outlink)
...
@@ -125,7 +125,9 @@ static int push_samples(AVFilterLink *outlink)
if
(
asns
->
next_out_pts
!=
AV_NOPTS_VALUE
)
if
(
asns
->
next_out_pts
!=
AV_NOPTS_VALUE
)
asns
->
next_out_pts
+=
nb_out_samples
;
asns
->
next_out_pts
+=
nb_out_samples
;
ff_filter_frame
(
outlink
,
outsamples
);
ret
=
ff_filter_frame
(
outlink
,
outsamples
);
if
(
ret
<
0
)
return
ret
;
asns
->
req_fullfilled
=
1
;
asns
->
req_fullfilled
=
1
;
return
nb_out_samples
;
return
nb_out_samples
;
}
}
...
@@ -168,9 +170,11 @@ static int request_frame(AVFilterLink *outlink)
...
@@ -168,9 +170,11 @@ static int request_frame(AVFilterLink *outlink)
ret
=
ff_request_frame
(
inlink
);
ret
=
ff_request_frame
(
inlink
);
}
while
(
!
asns
->
req_fullfilled
&&
ret
>=
0
);
}
while
(
!
asns
->
req_fullfilled
&&
ret
>=
0
);
if
(
ret
==
AVERROR_EOF
)
if
(
ret
==
AVERROR_EOF
)
{
while
(
push_samples
(
outlink
))
do
{
;
ret
=
push_samples
(
outlink
);
}
while
(
ret
>
0
);
}
return
ret
;
return
ret
;
}
}
...
...
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