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
394a73ca
Commit
394a73ca
authored
Sep 18, 2013
by
Paul B Mahol
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avfilter/vf_pullup: make sure metric_plane is available
Signed-off-by:
Paul B Mahol
<
onemda@gmail.com
>
parent
8302abf8
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
2 deletions
+8
-2
vf_pullup.c
libavfilter/vf_pullup.c
+8
-2
No files found.
libavfilter/vf_pullup.c
View file @
394a73ca
...
...
@@ -161,13 +161,19 @@ static int config_input(AVFilterLink *inlink)
AVFilterContext
*
ctx
=
inlink
->
dst
;
PullupContext
*
s
=
ctx
->
priv
;
const
AVPixFmtDescriptor
*
desc
=
av_pix_fmt_desc_get
(
inlink
->
format
);
const
int
mp
=
s
->
metric_plane
;
int
mp
=
s
->
metric_plane
;
s
->
nb_planes
=
av_pix_fmt_count_planes
(
inlink
->
format
);
if
(
mp
+
1
>
s
->
nb_planes
)
{
av_log
(
ctx
,
AV_LOG_WARNING
,
"input format does not have such plane
\n
"
);
return
AVERROR
(
EINVAL
);
}
s
->
planeheight
[
1
]
=
s
->
planeheight
[
2
]
=
FF_CEIL_RSHIFT
(
inlink
->
h
,
desc
->
log2_chroma_h
);
s
->
planeheight
[
0
]
=
s
->
planeheight
[
3
]
=
inlink
->
h
;
s
->
planewidth
[
1
]
=
s
->
planewidth
[
2
]
=
FF_CEIL_RSHIFT
(
inlink
->
w
,
desc
->
log2_chroma_w
);
s
->
planewidth
[
0
]
=
s
->
planewidth
[
3
]
=
inlink
->
w
;
s
->
nb_planes
=
av_pix_fmt_count_planes
(
inlink
->
format
);
s
->
metric_w
=
(
s
->
planewidth
[
mp
]
-
((
s
->
junk_left
+
s
->
junk_right
)
<<
3
))
>>
3
;
s
->
metric_h
=
(
s
->
planeheight
[
mp
]
-
((
s
->
junk_top
+
s
->
junk_bottom
)
<<
1
))
>>
3
;
...
...
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