Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
ffmpeg
Project
Project
Details
Activity
Releases
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Stefan Westerfeld
ffmpeg
Commits
9d1f9ba5
Commit
9d1f9ba5
authored
Apr 23, 2017
by
Paul B Mahol
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avfilter/vf_maskedclamp: fix bug when copying >8bit plane(s)
Signed-off-by:
Paul B Mahol
<
onemda@gmail.com
>
parent
16c88465
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
vf_maskedclamp.c
libavfilter/vf_maskedclamp.c
+6
-2
No files found.
libavfilter/vf_maskedclamp.c
View file @
9d1f9ba5
...
...
@@ -37,6 +37,7 @@ typedef struct MaskedClampContext {
int
undershoot
;
int
overshoot
;
int
linesize
[
4
];
int
width
[
4
],
height
[
4
];
int
nb_planes
;
int
depth
;
...
...
@@ -112,7 +113,7 @@ static int process_frame(FFFrameSync *fs)
for
(
p
=
0
;
p
<
s
->
nb_planes
;
p
++
)
{
if
(
!
((
1
<<
p
)
&
s
->
planes
))
{
av_image_copy_plane
(
out
->
data
[
p
],
out
->
linesize
[
p
],
base
->
data
[
p
],
base
->
linesize
[
p
],
s
->
width
[
p
],
s
->
height
[
p
]);
s
->
linesize
[
p
],
s
->
height
[
p
]);
continue
;
}
...
...
@@ -195,10 +196,13 @@ static int config_input(AVFilterLink *inlink)
AVFilterContext
*
ctx
=
inlink
->
dst
;
MaskedClampContext
*
s
=
ctx
->
priv
;
const
AVPixFmtDescriptor
*
desc
=
av_pix_fmt_desc_get
(
inlink
->
format
);
int
vsub
,
hsub
;
int
vsub
,
hsub
,
ret
;
s
->
nb_planes
=
av_pix_fmt_count_planes
(
inlink
->
format
);
if
((
ret
=
av_image_fill_linesizes
(
s
->
linesize
,
inlink
->
format
,
inlink
->
w
))
<
0
)
return
ret
;
hsub
=
desc
->
log2_chroma_w
;
vsub
=
desc
->
log2_chroma_h
;
s
->
height
[
1
]
=
s
->
height
[
2
]
=
AV_CEIL_RSHIFT
(
inlink
->
h
,
vsub
);
...
...
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