From daf20d5e09dbad6fd1ae3541b4cb80c8ecb3dd8b Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Wed, 29 Oct 2014 17:38:33 +0100 Subject: [PATCH] video-scaler: remove color range argument We just need to clip to the format limits, if there is extra headroom in the range we can use that without problems. --- gst-libs/gst/video/video-converter.c | 5 ++--- gst-libs/gst/video/video-scaler.c | 6 ++---- gst-libs/gst/video/video-scaler.h | 2 -- 3 files changed, 4 insertions(+), 9 deletions(-) diff --git a/gst-libs/gst/video/video-converter.c b/gst-libs/gst/video/video-converter.c index b0a3360..4eb72d9 100644 --- a/gst-libs/gst/video/video-converter.c +++ b/gst-libs/gst/video/video-converter.c @@ -1154,7 +1154,7 @@ do_hscale_lines (GstLineCache * cache, gint line, GstVideoConverter * convert) GST_DEBUG ("hresample line %d", line); gst_video_scaler_horizontal (convert->h_scaler, GST_VIDEO_FORMAT_AYUV, - GST_VIDEO_COLOR_RANGE_0_255, lines[0], destline, 0, convert->out_width); + lines[0], destline, 0, convert->out_width); gst_line_cache_add_line (cache, line, destline); @@ -1174,8 +1174,7 @@ do_vscale_lines (GstLineCache * cache, gint line, GstVideoConverter * convert) GST_DEBUG ("vresample line %d %d-%d", line, sline, sline + n_lines - 1); gst_video_scaler_vertical (convert->v_scaler, GST_VIDEO_FORMAT_AYUV, - GST_VIDEO_COLOR_RANGE_0_255, lines, destline, line, - convert->v_scale_width); + lines, destline, line, convert->v_scale_width); gst_line_cache_add_line (cache, line, destline); diff --git a/gst-libs/gst/video/video-scaler.c b/gst-libs/gst/video/video-scaler.c index e599f43..fcfdba4 100644 --- a/gst-libs/gst/video/video-scaler.c +++ b/gst-libs/gst/video/video-scaler.c @@ -494,8 +494,7 @@ video_scale_v_ntap_8888 (GstVideoScaler * scale, */ void gst_video_scaler_horizontal (GstVideoScaler * scale, GstVideoFormat format, - GstVideoColorRange range, gpointer src, gpointer dest, guint dest_offset, - guint width) + gpointer src, gpointer dest, guint dest_offset, guint width) { GstVideoScalerHFunc func; @@ -534,8 +533,7 @@ gst_video_scaler_horizontal (GstVideoScaler * scale, GstVideoFormat format, */ void gst_video_scaler_vertical (GstVideoScaler * scale, GstVideoFormat format, - GstVideoColorRange range, gpointer srcs[], gpointer dest, guint dest_offset, - guint width) + gpointer srcs[], gpointer dest, guint dest_offset, guint width) { GstVideoScalerVFunc func; diff --git a/gst-libs/gst/video/video-scaler.h b/gst-libs/gst/video/video-scaler.h index ae6b1c1..595a9a1 100644 --- a/gst-libs/gst/video/video-scaler.h +++ b/gst-libs/gst/video/video-scaler.h @@ -64,12 +64,10 @@ const gdouble * gst_video_scaler_get_coeff (GstVideoScaler *scale, void gst_video_scaler_horizontal (GstVideoScaler *scale, GstVideoFormat format, - GstVideoColorRange range, gpointer src, gpointer dest, guint dest_offset, guint width); void gst_video_scaler_vertical (GstVideoScaler *scale, GstVideoFormat format, - GstVideoColorRange range, gpointer src_lines[], gpointer dest, guint out_offset, guint width); -- 2.7.4