It seems both vdpau and nvdec are broken for Mpeg2 video. Particularly video that is 1080i, deinterlaced or not. I see blocking artifacts that are not present with VA-API or software decoding. This is reproducible in mpv and mythtv, but essentially anything that uses ffmpeg. I have generated a VDPAU trace but the partner sftp site doesn’t seem to work with blank credentials like this forums claims it does.
More info:
opened 02:27AM - 11 Sep 22 UTC
<!--
Thank you for reporting an issue in MythTV.
This issue tracker is for b… ugs and issues found within MythTV.
If you require more general support please see the support section
of our website: https://www.mythtv.org/support
Please fill in as much of the template below as you're able to.
Platform: Distro and output of `uname -a` (Linux/UNIX), or version and 32/64-bit (Windows)
MythTV version: the version of MythTV you are running (master, fixes/31, etc)
Package version: if using a packaged version of MythTV, please provide repository/version
Component: if known, please specify the affected component (e.g. frontend/backend)
-->
* **Platform**: ```Linux mythtvbox 5.17.5-gentoo #1 SMP PREEMPT Sun May 1 02:28:31 EDT 2022 x86_64 Intel(R) Core(TM)2 Quad CPU Q9650 @ 3.00GHz GenuineIntel GNU/Linux```
* **MythTV version**: fixes/32
* **Package version**:
* **Component**: mythfrontend / mythavcodec
### What steps will reproduce the bug?
Playback 1080i video from OTA MPEG-TS with nvdec or VDPAU decoding.
<!--
Please enter details about your bug, preferably including simple navigation
instructions to reproduce the bug in mythfrontend, or the startup options you
are using for any MythTV command line applications.
-->
### How often does it reproduce? Is there a required condition?
Somewhat random but most often occurs during sharp scene transitions or high motion
### What is the expected behaviour?
No blocking artifacts
<!--
If possible, please provide textual (e.g. logging) output. Screenshots may be more
appropriate for graphical bugs in mythfrontend.
-->
Here's the "debug" playback output when this issue occurs:
https://pastebin.com/m6cfem9q
Here's a screenshot:

### What do you see instead?
Blocking artifacts
### Additional information
This issue I believe to be inherited during a resync to ffmpeg 4.4 but it's hard to say for certain. I _only_ exhibit this with VDPAU or nvdec decoding and the issue seems to disappear when the video is pulled from the transport stream into a regular mpeg2 container. I was able to see this same buggy behavior with nvdec on a different machine with mpv for a while, but now that I've updated ffmpeg and mpv over the past year or so, I cannot observe it anymore. The issue cropped up right around the v32 update and I seem to not be the only one exhibiting this issue, as this mailing list user also seems to have the symptoms: https://lists.archive.carbon60.com/mythtv/dev/638570
I'm attaching a minimally sized ts that exhibits the issue. Hopefully it's not too large.
[problem.zip](https://github.com/MythTV/mythtv/files/9541664/problem.zip)
I've mentioned this issue in issue #428. The machine using nvdec with mpv is leveraging ffmpeg 4.4.2, so it's at least fixed in that verison.
Let me know if there's anything more I can provide.