summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWim Taymans <wtaymans@redhat.com>2015-06-17 15:09:46 (GMT)
committerWim Taymans <wtaymans@redhat.com>2015-06-17 15:09:46 (GMT)
commitc0b0fd52f33031af49db79251cdbb6409c20fdf8 (patch)
tree85ab1d5d2f08d9fc1a73625be652ba145e991460
parentf4a5277340073f29f1de8600581fca6e77ef184d (diff)
downloadgst-plugins-base-master.tar.gz
gst-plugins-base-master.tar.xz
video-converter: make sure we draw enough border for YUY2 formatsHEADmaster
Round width up to 2 so that we draw all border pixels for YUY2 formats
-rw-r--r--gst-libs/gst/video/video-converter.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/gst-libs/gst/video/video-converter.c b/gst-libs/gst/video/video-converter.c
index 55f001f..2fd5c64 100644
--- a/gst-libs/gst/video/video-converter.c
+++ b/gst-libs/gst/video/video-converter.c
@@ -3627,12 +3627,6 @@ convert_fill_border (GstVideoConverter * convert, GstVideoFrame * dest)
GST_VIDEO_FORMAT_INFO_SCALE_HEIGHT (out_finfo, k,
convert->out_maxheight);
- r_border = out_x + out_width;
- rb_width = out_maxwidth - r_border;
- lb_width = out_x;
-
- borders = &convert->borders[k];
-
pstride = GST_VIDEO_FORMAT_INFO_PSTRIDE (out_finfo, k);
switch (GST_VIDEO_FORMAT_INFO_FORMAT (out_finfo)) {
@@ -3640,12 +3634,19 @@ convert_fill_border (GstVideoConverter * convert, GstVideoFrame * dest)
case GST_VIDEO_FORMAT_YVYU:
case GST_VIDEO_FORMAT_UYVY:
pgroup = 42;
+ out_maxwidth = GST_ROUND_UP_2 (out_maxwidth);
break;
default:
pgroup = pstride;
break;
}
+ r_border = out_x + out_width;
+ rb_width = out_maxwidth - r_border;
+ lb_width = out_x;
+
+ borders = &convert->borders[k];
+
switch (pgroup) {
case 1:
{