[fixed] 4k HEVC DXVA2 not playing correctly in MP2 (1 Viewer)

Owlsroost

Retired Team Member
  • Premium Supporter
  • October 28, 2008
    5,540
    5,038
    Cambridge
    Home Country
    United Kingdom United Kingdom
    I've now done a fair amount of testing using 8 & 10 bit HEVC and H.264 files (generated at several different resolutions using Handbrake from the same 4k source file).

    Results match what JSchuricht found - all the files play OK in MP2 except for 10-bit 4k HEVC using DXVA.

    Lower resolution 10-bit HEVC e.g. 2560 x 1440p play OK using DXVA, and all files play OK using software decoding.

    Sometimes 10-bit 4k HEVC using DXVA will play for a short time then freeze, or will play with very major stutters.

    Bitrate does not seem to make a difference - I've tried 25/50/100 Mbps.

    8-bit HEVC and 10-bit H.264 4k both play OK using DXVA.

    So it *feels like* the basic DXVA connection/negotiation is working OK, but that there is a performance issue somewhere in the way MP2 is feeding data into/handling the graph when DXVA is in use.

    MPC-HC and MP1 can play 4k 10-bit HEVC using DXVA with no problems.

    Tested on a very fast PC using an i7-8750H ('Coffee Lake' generation), with the latest Intel GPU drivers.
     

    Owlsroost

    Retired Team Member
  • Premium Supporter
  • October 28, 2008
    5,540
    5,038
    Cambridge
    Home Country
    United Kingdom United Kingdom
    Attached is a collection of some of the test files I used - mostly 10-bit HEVC at different resolutions, but a few 8-bit HEVC and 10-bit H264 for comparison.

    For me, the 10-bit HEVC files up to '1792p' resolution play OK with DXVA, anything larger (1904p and 2160p) don't, tested with MP2 release 2.2

    (The test files are 'soft' looking - that is not a playback problem, the source video was also 'soft'...)
     
    Last edited:

    henso

    Development Group
  • Team MediaPortal
  • February 16, 2012
    2,341
    829
    Home Country
    Denmark Denmark
    @morpheus_xx
    I tested all the test files and had the same problem. The playback fails by IMediaControl.Run() with D3DERR_OUTOFVIDEOMEMORY (0x8876017c).
    If I bypass the DotNetStreamSource and use the default source filter instead, the playback of all test files work.
     

    morpheus_xx

    Retired Team Member
  • Team MediaPortal
  • March 24, 2007
    12,073
    7,459
    Home Country
    Germany Germany
    Thanks @henso, I didn't thought about a relation to this issue yet. I tested it here and can confirm that files are played now (at least so good or bad as GraphEdit).

    I have pushed a change to WIP_2.2.1 and provide a test installer later in evening.
     

    henso

    Development Group
  • Team MediaPortal
  • February 16, 2012
    2,341
    829
    Home Country
    Denmark Denmark
    I have pushed a change to WIP_2.2.1
    I also pushed some changes that seem to fix the NetStreamSourceFilter memory leaks. I can now play all test files.
    Please check if you think the reasons (read commits) I found are plausible.
    Remember to uncomment the NetStreamSourceFilter bypass if you want to test it. ;)
     

    JSchuricht

    MP Donator
  • Premium Supporter
  • January 13, 2009
    239
    45
    Arizona
    Home Country
    United States of America United States of America
    WIP_2.2.1 didn't work out too well. I tried two movies. The one I was previously testing with had audio and a blank screen even after restarting. The second file I tried starts playing but goes back and forth between good video to bad pixelation before Mediaportal crashes to the desktop. Screenshot below shows the pixelation when the movie stopped just before Mediaportal crashed.

    upload_2018-11-17_17-7-27.png
     

    Attachments

    • upload_2018-11-17_17-6-39.png
      upload_2018-11-17_17-6-39.png
      944 KB
    • MediaPortal2-Logs-2018-11-17-17.06.31.zip
      926.4 KB

    JSchuricht

    MP Donator
  • Premium Supporter
  • January 13, 2009
    239
    45
    Arizona
    Home Country
    United States of America United States of America
    I tried the sample files, some work.

    HEVC_4k_2160p_CQ16_8bit_10s is blank then plays fine after 5 seconds

    HEVC_4k_2160p_CQ16_10bit_10s and HEVC_1904p_CQ16_10bit_10s don't play with a ? in the right corner

    HEVC_1712p_CQ16_10bit_10s and HEVC_1792p_CQ16_10bit_10s start off looking scrambled then are fine after 5 seconds

    Logs will show the file under Stuck (2014), I was replacing the file to avoid a doing an import.

    The 5 second mark is where the play/pause/stop menu goes away.

    The main file I am testing with is 43.5GB with some other files hitting 80GB. I will work on cutting out a small chunk and uploading it somewhere after checking that the small chunk still has the same issue.
     

    Attachments

    • MediaPortal2-Logs-2018-11-17-20.57.40.zip
      1 MB
    Last edited:

    JSchuricht

    MP Donator
  • Premium Supporter
  • January 13, 2009
    239
    45
    Arizona
    Home Country
    United States of America United States of America
    Alright, test file uploaded. Warning... its 5 minutes of 44Mb/s and 1.6GB. Let me know when you have it so I can pull the file in case it upsets the wrong person. The file behaves the same in Mediaportal as the fill length version, giving me a blank screen and audio with WIP_2.2.1.
     

    Users who are viewing this thread

    Top Bottom