GNOME Bugzilla – Bug 730925
MADI doesn't respect hardware limits, and assumes that any surface type is acceptable as the reference surface
Last modified: 2018-11-03 15:45:08 UTC
As per https://bugs.freedesktop.org/show_bug.cgi?id=79377#c2 I'm filing this bug. When I have a YUY2 source feeding gstreamer-vaapi with the patch at https://bugzilla.gnome.org/show_bug.cgi?id=726361 applied, I get horrible colour effects from the deinterlacing. My pipeline is: gst-launch-1.0 v4l2src ! vaapipostproc deinterlace-mode=interlaced deinterlace-method=motion-adaptive ! vaapisink gstreamer-vaapi provides YUY2 surfaces to VPP for deinterlacing; SNB and IVB can only deinterlace NV12, so I get horrible artifacting.
Hmm, sorry, you are right. This is an omission from the specs. The reference surfaces must have the same format as used internally. In particular, this is NV12. Still, the driver should still accept YUY2 sources. I think we should amend the specs to report that the first PixelFormat format returned for a VPP pipeline(*) is the "native" (internal) format and shall be the one used for reference. (*) vaQuerySurfaceAttributes() with a VPP config.
That would work for today's hardware. What would you do to cope if future hardware supports other reference frame formats (e.g. YV16 to enable it to deinterlace in 4:2:2 as well as 4:2:0)? Add a new query?
Created attachment 306083 [details] [review] vaapipostproc: prevent advanced-deinterlacing of non-native video formats. This is only a temporary work-around intended for 0.6 release. Fail it in negotiation step itself for advanced-deinterlacing of non-native video input formats. A better solution could be to do the color space conversion internally(inside vaapipostproc) for reference surfaces.
Pushed, commit a1eef1c35505ae5df9d96ed98eab5c928da77e06 Author: Sreerenj Balachandran <sreerenj.balachandran@intel.com> Date: Mon Jun 29 13:20:28 2015 +0300 Keeping this bug report open to track further improvements..
Moving to Product:GStreamer, Component:gstreamer-vaapi
Comment on attachment 306083 [details] [review] vaapipostproc: prevent advanced-deinterlacing of non-native video formats. marking as committed because it was committed already :)
Complete the previous patch and close the bug seems to be easy, since all the pieces are already in place.
-- GitLab Migration Automatic Message -- This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/issues/15.