[FFMPEG] Fix for artifacts with ATI cards and DXVA2 decoding - Printable Version
+- XBMC Community Forum (http://forum.xbmc.org)
+-- Forum: Development (/forumdisplay.php?fid=32)
+--- Forum: Development (/forumdisplay.php?fid=93)
+--- Thread: [FFMPEG] Fix for artifacts with ATI cards and DXVA2 decoding (/showthread.php?tid=103437)
[FFMPEG] Fix for artifacts with ATI cards and DXVA2 decoding - isidrogar - 2011-06-13 21:38
I have created this patch for fixing some artifacts during playback of H264 videos with DXVA2 and ATI cards. What the patch fixes is some kind of wrong colored macroblocks.
I have seen other artifacts like a nearly whole green screen mainly with interlaced content. I am diving in ffmpeg code to find out the bug but I don't have a solution yet.
For those who want to try the patch I have compiled this patched dll. You only have to backup the one with the same name in <XBMC path>\system\players\dvdplayer and copy the new one.
Update: I have uploaded a new version that allows to activate or not the patch using the flag FF_BUG_DXVA2_ATI in workaround_bugs member of AVCodecContext structure. I don't post a new compiled dll because you will need the patched headers to use.
- 0wing - 2011-06-14 18:20
I didn't test it with every problematic movie, but this seems to solve the problems with ATI cards without UVD 2+.
Now I can finally stop using DSPlayer and get the latest builds.
- mortstar - 2011-06-14 18:47
isidrogar Wrote:Hi all,
Is that patched against HEAD?
- Zuphael - 2011-06-14 20:46
Using your DLL XBMC Log tells me:
20:43:15 T:3644 M:2438414336 ERROR: Win32DllLoader::Load: Unable to load special://xbmcbin/system/players/dvdplayer/avcodec-52.dll (126)
Downloaded it from rapidshare and filesonic... no videofile is playing...
- isidrogar - 2011-06-15 09:57
mortstar Wrote:Is that patched against HEAD?
Yes, it is patched agaist last HEAD commit, but should work with previous commits after d21c544a.
- isidrogar - 2011-06-15 09:59
Zuphael Wrote:Hi there!
Which build version are you using? The dll must be used for last git builds.
- Zuphael - 2011-06-15 10:45
Sorry my fault xD
So, maybe its me, but i can tell no diffrence between your dll and that normal one...
- isidrogar - 2011-06-16 09:49
I can see in your capture some decolored macroblocks but the are not exactly the same artifacts I have seen in my videos.
Just for reference, can you try the same video with MPC-HC and its internal DXVA H264 decoder?
If you also see the artifacts there, it could be possible you to cut a little clip of the video for testing in my system?
- topsyturvy - 2011-06-16 20:29
I'm quite glad to see someone looking in ffmpeg code. I've got a number of problematic h264/dxva videos, there's been a ticket on this for months but nothing yet.
Please see my post at http://forum.xbmc.org/showthread.php?tid=101372
A test clip is included. CAn you do me a huge favor and take a look at this? I already tried your patch hoping that it would fix it for me but no luck.
Thanks in advance.
- isidrogar - 2011-06-18 23:36
topsyturvy Wrote:Hi isidrogar,
It seems your problem is related to other bug in ffmpeg's implementation for DXVA. I'm still looking the code to find a fix for "green video screen" with interlaced content so I will also take a look at this problem. It would be great two fix at the same time!