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
abcf8610
Commit
abcf8610
authored
Jan 28, 2015
by
Paul B Mahol
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avfitler/vf_il: use the name 's' for the pointer to the private context
Signed-off-by:
Paul B Mahol
<
onemda@gmail.com
>
parent
231bf4d1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
15 deletions
+15
-15
vf_il.c
libavfilter/vf_il.c
+15
-15
No files found.
libavfilter/vf_il.c
View file @
abcf8610
...
...
@@ -98,17 +98,17 @@ static int query_formats(AVFilterContext *ctx)
static
int
config_input
(
AVFilterLink
*
inlink
)
{
IlContext
*
il
=
inlink
->
dst
->
priv
;
IlContext
*
s
=
inlink
->
dst
->
priv
;
const
AVPixFmtDescriptor
*
desc
=
av_pix_fmt_desc_get
(
inlink
->
format
);
int
ret
;
il
->
nb_planes
=
av_pix_fmt_count_planes
(
inlink
->
format
);
s
->
nb_planes
=
av_pix_fmt_count_planes
(
inlink
->
format
);
il
->
has_alpha
=
!!
(
desc
->
flags
&
AV_PIX_FMT_FLAG_ALPHA
);
if
((
ret
=
av_image_fill_linesizes
(
il
->
linesize
,
inlink
->
format
,
inlink
->
w
))
<
0
)
s
->
has_alpha
=
!!
(
desc
->
flags
&
AV_PIX_FMT_FLAG_ALPHA
);
if
((
ret
=
av_image_fill_linesizes
(
s
->
linesize
,
inlink
->
format
,
inlink
->
w
))
<
0
)
return
ret
;
il
->
chroma_height
=
FF_CEIL_RSHIFT
(
inlink
->
h
,
desc
->
log2_chroma_h
);
s
->
chroma_height
=
FF_CEIL_RSHIFT
(
inlink
->
h
,
desc
->
log2_chroma_h
);
return
0
;
}
...
...
@@ -146,7 +146,7 @@ static void interleave(uint8_t *dst, uint8_t *src, int w, int h,
static
int
filter_frame
(
AVFilterLink
*
inlink
,
AVFrame
*
inpicref
)
{
IlContext
*
il
=
inlink
->
dst
->
priv
;
IlContext
*
s
=
inlink
->
dst
->
priv
;
AVFilterLink
*
outlink
=
inlink
->
dst
->
outputs
[
0
];
AVFrame
*
out
;
int
comp
;
...
...
@@ -159,23 +159,23 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *inpicref)
av_frame_copy_props
(
out
,
inpicref
);
interleave
(
out
->
data
[
0
],
inpicref
->
data
[
0
],
il
->
linesize
[
0
],
inlink
->
h
,
s
->
linesize
[
0
],
inlink
->
h
,
out
->
linesize
[
0
],
inpicref
->
linesize
[
0
],
il
->
luma_mode
,
il
->
luma_swap
);
s
->
luma_mode
,
s
->
luma_swap
);
for
(
comp
=
1
;
comp
<
(
il
->
nb_planes
-
il
->
has_alpha
);
comp
++
)
{
for
(
comp
=
1
;
comp
<
(
s
->
nb_planes
-
s
->
has_alpha
);
comp
++
)
{
interleave
(
out
->
data
[
comp
],
inpicref
->
data
[
comp
],
il
->
linesize
[
comp
],
il
->
chroma_height
,
s
->
linesize
[
comp
],
s
->
chroma_height
,
out
->
linesize
[
comp
],
inpicref
->
linesize
[
comp
],
il
->
chroma_mode
,
il
->
chroma_swap
);
s
->
chroma_mode
,
s
->
chroma_swap
);
}
if
(
il
->
has_alpha
)
{
comp
=
il
->
nb_planes
-
1
;
if
(
s
->
has_alpha
)
{
comp
=
s
->
nb_planes
-
1
;
interleave
(
out
->
data
[
comp
],
inpicref
->
data
[
comp
],
il
->
linesize
[
comp
],
inlink
->
h
,
s
->
linesize
[
comp
],
inlink
->
h
,
out
->
linesize
[
comp
],
inpicref
->
linesize
[
comp
],
il
->
alpha_mode
,
il
->
alpha_swap
);
s
->
alpha_mode
,
s
->
alpha_swap
);
}
av_frame_free
(
&
inpicref
);
...
...
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