GNOME Bugzilla – Bug 696737
videoconvert: non-ideal conversion for interlaced video
Last modified: 2018-05-04 08:44:07 UTC
Created attachment 239996 [details] [review] patch Videoconvert allows changes to vertical subsampling for interlaced video. Although the resampling kernels have improved recently, they are not ideal if the next element is a deinterlacer or ivtc. Patch adds a flag to disable this conversion if trying to construct a high-quality pipeline.
I would make that a GFlags property that also could later have things like disabling colorspace conversion or depth conversion or ...
That's what Wim suggested, too. That seems like a lot of work (and bugs!), but I think it's the right way to go in general.
Are you working on that David? Or Wim?
I think this mostly fixed it: commit 33a54ba4f3b679952d1be7afa9ed3863d0f4fcd5 Author: Wim Taymans <wim.taymans@collabora.co.uk> Date: Thu Mar 28 18:13:10 2013 +0100 videoconvert: be smarter when selecting a conversion Try to select the conversion that would result in the minimal amount of quality loss. Quality loss is calculated rather arbitrarily but it avoids doing something really stupid in most cases.
Hi, Can this be closed if it is fixed?
The operative word was 'mostly' :) However, this may be fixed now after all the videoconvert/scale rework. Wim, anything left to to here? ---- commit e2a693656b1a8513adab5e8f7698758c583c8eed Author: Wim Taymans <wtaymans@redhat.com> Date: Wed Dec 3 10:15:18 2014 +0100 video-converter: fix chroma resampling check Decide if we need chroma resampling by checking if we have a progressive or interlaced chroma resampler. commit b9bee1af8c6721902de15410caa4dc382baaf180 Author: Wim Taymans <wtaymans@redhat.com> Date: Fri Nov 21 16:06:54 2014 +0100 video-converter: handle mixed interlaced When dealing with mixed interlaced, setup a scaler and chroma-resampler for both interlaced and progressive frames and switch between them depending on the interlace mode of the input frame. commit f6683b8f145a8f774b642df37e26c979a938d025 Author: Wim Taymans <wtaymans@redhat.com> Date: Wed Nov 19 12:41:21 2014 +0100 video-info: add a note about subsampled formats Add a note about gst_video_info_set_format() and interlaced formats. commit 24989b53fc5ec1f4d95eecdde507e455b19d0a14 Author: Wim Taymans <wtaymans@redhat.com> Date: Wed Nov 19 12:05:02 2014 +0100 video-info: handle interlaced size correctly Refactor GstVideoInfo init, make function to set default colorimetry. Call fill_planes after we configure the GstVideoInfo with parameters from the caps. The size of the chroma planes for interlaced vertically subsampled formats needs to be rounded up to 2, we have 2 fields with each the same anount of chroma lines. commit 5c043f3d50436d5c5a38e94ca7f3066a7a9cfdc0 Author: Wim Taymans <wtaymans@redhat.com> Date: Wed Nov 19 09:40:05 2014 +0100 video-format: handle unpack interlaced subsampled formats For interlaced vertically subsampled formats the check for even lines needs to take into account the two fields. commit 588fdeb8349cf5fbb37e63f403c5559071283c07 Author: Wim Taymans <wtaymans@redhat.com> Date: Wed Nov 19 09:39:32 2014 +0100 video-scaler: fix interlaced shift commit ac756ba0d9f947ea24f94ffeef61bbf71c91f82f Author: Wim Taymans <wtaymans@redhat.com> Date: Wed Nov 19 09:30:14 2014 +0100 video-converter: keep a small backlog of lines Allow lines to jump backwards slightly, usefull for interlaced content. commit b9114347164684137dc0ca11ee12cd099794cadf Author: Wim Taymans <wtaymans@redhat.com> Date: Wed Nov 19 09:28:52 2014 +0100 video-chroma: Fix interlaced chroma resampling Use the interlaced flag to select the right resampler. commit 7d0cef3bcbb1f2ad913903c44575c6f472a9b48e Author: Wim Taymans <wtaymans@redhat.com> Date: Tue Nov 18 16:35:13 2014 +0100 video-scaler: fix interlacing some more Use the right phase. Take the right lines from interlaced content. commit d03bad77618a122305e87049daeba3e4eea7645a Author: Wim Taymans <wtaymans@redhat.com> Date: Tue Nov 18 11:06:20 2014 +0100 video-scaler: fix interlaced taps setup commit 67a4702b194c899e65fbabe11825759057538f74 Author: Wim Taymans <wtaymans@redhat.com> Date: Tue Nov 4 11:02:49 2014 +0100 video-scaler: fix taps in interlaced mode commit 562416bb943cee713de57c8c3c4e98cded5e114b Author: Wim Taymans <wtaymans@redhat.com> Date: Tue Nov 4 11:01:52 2014 +0100 video-scaler: fix phases in interlaced mode commit 45462d2ea4a5bbbdec02cd0c4c3a35eb2f0f48c8 Author: Wim Taymans <wtaymans@redhat.com> Date: Sat Nov 1 12:58:01 2014 +0100 video-scaler: handle 4tap interlaced commit 199fab4b067d12157cc37fc84ebded71b778239f Author: Wim Taymans <wtaymans@redhat.com> Date: Fri Oct 24 15:25:33 2014 +0200 video-scaler: add video scaler helper object Add a video scaler object build on top of the resampler. It has implementation to deal with interlaced video as well as horizontal and vertical scaling functions. commit 549bdd4ece277289e50b658f3b1833fed26f389f Author: Wim Taymans <wtaymans@redhat.com> Date: Fri Oct 24 12:11:43 2014 +0200 video-converter: rework the generic converter function Use a LineCache object to track and process lines between unpack, upsample, convert, downsample and pack stages. This simplifies the main core processing function a lot and allows for future additions easily. Add support for interlaced formats in chroma up and downsampling.
this has not received any response in 3 years. Closing. If the issue can be confirmed on master please re-open.