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
09d84e00
Commit
09d84e00
authored
Dec 15, 2015
by
Paul B Mahol
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avfilter/af_ladspa: unbreak Mch -> Nch plugins, where M < N
Signed-off-by:
Paul B Mahol
<
onemda@gmail.com
>
parent
0bdf84b6
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
3 deletions
+9
-3
af_ladspa.c
libavfilter/af_ladspa.c
+9
-3
No files found.
libavfilter/af_ladspa.c
View file @
09d84e00
...
...
@@ -26,6 +26,7 @@
#include <dlfcn.h>
#include <ladspa.h>
#include "libavutil/avassert.h"
#include "libavutil/avstring.h"
#include "libavutil/channel_layout.h"
#include "libavutil/opt.h"
...
...
@@ -144,6 +145,8 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *in)
AVFrame
*
out
;
int
i
,
h
,
p
;
av_assert0
(
in
->
channels
==
s
->
nb_inputs
);
if
(
!
s
->
nb_outputs
||
(
av_frame_is_writable
(
in
)
&&
s
->
nb_inputs
==
s
->
nb_outputs
&&
!
(
s
->
desc
->
Properties
&
LADSPA_PROPERTY_INPLACE_BROKEN
)))
{
...
...
@@ -157,6 +160,8 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *in)
av_frame_copy_props
(
out
,
in
);
}
av_assert0
(
!
s
->
nb_outputs
||
out
->
channels
==
s
->
nb_outputs
);
for
(
h
=
0
;
h
<
s
->
nb_handles
;
h
++
)
{
for
(
i
=
0
;
i
<
s
->
nb_inputs
;
i
++
)
{
p
=
s
->
nb_handles
>
1
?
h
:
i
;
...
...
@@ -298,6 +303,7 @@ static int config_input(AVFilterLink *inlink)
static
int
config_output
(
AVFilterLink
*
outlink
)
{
AVFilterContext
*
ctx
=
outlink
->
src
;
LADSPAContext
*
s
=
ctx
->
priv
;
int
ret
;
if
(
ctx
->
nb_inputs
)
{
...
...
@@ -305,7 +311,7 @@ static int config_output(AVFilterLink *outlink)
outlink
->
format
=
inlink
->
format
;
outlink
->
sample_rate
=
inlink
->
sample_rate
;
if
(
ctx
->
nb_inputs
==
ctx
->
nb_outputs
)
{
if
(
s
->
nb_inputs
==
s
->
nb_outputs
)
{
outlink
->
channel_layout
=
inlink
->
channel_layout
;
outlink
->
channels
=
inlink
->
channels
;
}
...
...
@@ -644,7 +650,7 @@ static int query_formats(AVFilterContext *ctx)
if
(
s
->
nb_inputs
>=
1
)
{
AVFilterLink
*
inlink
=
ctx
->
inputs
[
0
];
int64_t
inlayout
=
FF_COUNT2LAYOUT
(
s
->
nb_inputs
);
u
int64_t
inlayout
=
FF_COUNT2LAYOUT
(
s
->
nb_inputs
);
layouts
=
NULL
;
ret
=
ff_add_channel_layout
(
&
layouts
,
inlayout
);
...
...
@@ -662,7 +668,7 @@ static int query_formats(AVFilterContext *ctx)
}
if
(
s
->
nb_outputs
>=
1
)
{
int64_t
outlayout
=
FF_COUNT2LAYOUT
(
s
->
nb_outputs
);
u
int64_t
outlayout
=
FF_COUNT2LAYOUT
(
s
->
nb_outputs
);
layouts
=
NULL
;
ret
=
ff_add_channel_layout
(
&
layouts
,
outlayout
);
...
...
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