summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Dröge <sebastian@centricular.com>2014-10-01 17:24:59 +0300
committerSebastian Dröge <sebastian@centricular.com>2014-10-01 17:24:59 +0300
commitc1a96113db31b3b4cc739bc532f77583cbb7b238 (patch)
treecee56e7bab021f4484e622711a72aec86a9ecbf1
parentaf7916ca4a906c09187e1e9f3aa7359ab8910ae3 (diff)
videomixer: Revert the last commit and handle resolutions differences properly
This is about converting the format, not about converting any widths and heights. Subclasses are expected to handler different resolutions themselves, like the videomixers already do properly.
-rw-r--r--gst/videomixer/videomixer2.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/gst/videomixer/videomixer2.c b/gst/videomixer/videomixer2.c
index a96637812..b2f3c08ee 100644
--- a/gst/videomixer/videomixer2.c
+++ b/gst/videomixer/videomixer2.c
@@ -444,15 +444,15 @@ gst_videomixer2_update_converters (GstVideoMixer2 * mix)
if (best_format != GST_VIDEO_INFO_FORMAT (&pad->info) ||
g_strcmp0 (colorimetry, best_colorimetry) ||
g_strcmp0 (chroma, best_chroma)) {
+ GstVideoInfo tmp_info = pad->info;
+ tmp_info.finfo = best_info.finfo;
+ tmp_info.chroma_site = best_info.chroma_site;
+ tmp_info.colorimetry = best_info.colorimetry;
+
GST_DEBUG_OBJECT (pad, "This pad will be converted from %d to %d",
GST_VIDEO_INFO_FORMAT (&pad->info),
GST_VIDEO_INFO_FORMAT (&best_info));
- /* TODO: GstVideoConverter currently can't rescale! */
- if (pad->info.width == best_info.width &&
- pad->info.height == best_info.height &&
- pad->info.par_n == best_info.par_n &&
- pad->info.par_d == best_info.par_d)
- pad->convert = gst_video_converter_new (&pad->info, &best_info, NULL);
+ pad->convert = gst_video_converter_new (&pad->info, &best_info, NULL);
pad->need_conversion_update = TRUE;
if (!pad->convert) {
g_free (colorimetry);