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
fbc339ff
Commit
fbc339ff
authored
Dec 02, 2012
by
Stefano Sabatini
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lavfi/super2xsai: switch to ff_filter_frame() API
parent
adfd9ca3
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
9 deletions
+11
-9
vf_super2xsai.c
libavfilter/vf_super2xsai.c
+11
-9
No files found.
libavfilter/vf_super2xsai.c
View file @
fbc339ff
...
...
@@ -30,6 +30,7 @@
#include "libavutil/intreadwrite.h"
#include "avfilter.h"
#include "formats.h"
#include "internal.h"
#include "video.h"
typedef
struct
{
...
...
@@ -302,20 +303,22 @@ static int config_output(AVFilterLink *outlink)
return
0
;
}
static
int
null_draw_slice
(
AVFilterLink
*
inlink
,
int
y
,
int
h
,
int
slice_dir
)
{
return
0
;
}
static
int
end_frame
(
AVFilterLink
*
inlink
)
static
int
filter_frame
(
AVFilterLink
*
inlink
,
AVFilterBufferRef
*
inpicref
)
{
AVFilterLink
*
outlink
=
inlink
->
dst
->
outputs
[
0
];
AVFilterBufferRef
*
inpicref
=
inlink
->
cur_buf
;
AVFilterBufferRef
*
outpicref
=
outlink
->
out_buf
;
AVFilterBufferRef
*
outpicref
=
ff_get_video_buffer
(
outlink
,
AV_PERM_WRITE
,
outlink
->
w
,
outlink
->
h
);
if
(
!
outpicref
)
{
avfilter_unref_bufferp
(
&
inpicref
);
return
AVERROR
(
ENOMEM
);
}
avfilter_copy_buffer_ref_props
(
outpicref
,
inpicref
);
super2xsai
(
inlink
->
dst
,
inpicref
->
data
[
0
],
inpicref
->
linesize
[
0
],
outpicref
->
data
[
0
],
outpicref
->
linesize
[
0
],
inlink
->
w
,
inlink
->
h
);
ff_draw_slice
(
outlink
,
0
,
outlink
->
h
,
1
);
return
ff_
end_frame
(
outlink
);
avfilter_unref_bufferp
(
&
inpicref
);
return
ff_
filter_frame
(
outlink
,
outpicref
);
}
static
const
AVFilterPad
super2xsai_inputs
[]
=
{
...
...
@@ -323,8 +326,7 @@ static const AVFilterPad super2xsai_inputs[] = {
.
name
=
"default"
,
.
type
=
AVMEDIA_TYPE_VIDEO
,
.
config_props
=
config_input
,
.
draw_slice
=
null_draw_slice
,
.
end_frame
=
end_frame
,
.
filter_frame
=
filter_frame
,
.
min_perms
=
AV_PERM_READ
,
},
{
NULL
}
...
...
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