Kodi Community Forum

Full Version: [Win][v19+] Intel HTPCs/NUCs & Kodi-native 3D MVC Playback
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29
@udobroemme
My audio issues mostly resolved by following jogal recommendation - using real fullscreen mode and adding delay on refresh rate change. Now, i can finalize and test the upscaling patch.

Currently its working 90% of the time on sbs/htab and when it doesn't, it just require enterprise ng the stereoscopic setting (glasses icon) during play and reselecting hardware based stereoscopic mode.
I was so stupid to update my Xgimi horizon beamer to the latest firmware. This screwed up mvc input (one eye view is shifted vertically, cross-checked with a 3D blu-ray player) but over/under input works still fine. So I decided to update my Kodi box again to Win10 21H2 because Kodi mvc output isn't important to me at the moment. So I'm still happy with or without your latest changes and the test samples from Kod1user1138 worked before and still do. Anyway, thanks for your hints. But someone else with a working mvc chain might be of more use for you to test your latest changes. Smile
(2022-02-02, 18:23)damagedspline Wrote: [ -> ]@udobroemme
My audio issues mostly resolved by following jogal recommendation - using real fullscreen mode and adding delay on refresh rate change. Now, i can finalize and test the upscaling patch.

Currently its working 90% of the time on sbs/htab and when it doesn't, it just require enterprise ng the stereoscopic setting (glasses icon) during play and reselecting hardware based stereoscopic mode.
Thanks for sharing this; switching to full screen (I was using window) and adding a refresh change delay changed the behaviour for my setup. Rather than stutter and fail to get any audio it now just quits Kodi when stopping a 1080P MVC source. The behaviour is better IMHO but still not ideal.
(2022-02-06, 13:45)Krobar Wrote: [ -> ]Thanks for sharing this; switching to full screen (I was using window) and adding a refresh change delay changed the behaviour for my setup. Rather than stutter and fail to get any audio it now just quits Kodi when stopping a 1080P MVC source. The behaviour is better IMHO but still not ideal.
I have been investigating this crash for the past 3 nights and it is what blocking a new release. There is a resource leak which cause a crash when releasing the swap chain. I am still looking for the source of the leak. But it is specific to the MVC patch and the v19 code jump. When i skip the swap chain release, it does not crash anymore, audio works and even my new addition of upscaling works - but sadly there is slight degradation in 2D video performance which is apparent by a very subtle frame drop in 4k videos on my test GeminiLake machine.
Anyway WIP.
(2022-02-06, 13:45)Krobar Wrote: [ -> ]Thanks for sharing this; switching to full screen (I was using window) and adding a refresh change delay changed the behaviour for my setup. Rather than stutter and fail to get any audio it now just quits Kodi when stopping a 1080P MVC source. The behaviour is better IMHO but still not ideal.

I found the resource leak origin and fixed it locally - but now the new 3D code flow breaks the new SBS/TAB upscaling feature, so additional investigation is required :/
v19.3 test build for the crash fix when running in fullscreen & the new upscale of htab/hsbs to frame packed (full resolution 3d) download: https://app.box.com/s/czyqrf2m32yzj3l3dsaae4cdnk75mem6

my tests found that enabling the full resolution 3d upscaling of sbs & htab may cause audio issues randmoly on some desktops - fix might be the one in the kodi upstream code - i did not test yet.

to enable htab/sbs auto upscaling -> enable auto 3d display flag and preferred mode set to "hardware based".

Update: forgot to mention, when auto 3d display is enabled, exit the settings and re-enter back to set hw based as preferred mode. Hw based option will always be available when auto 3d display flag is on. In case hw does not support, it will fallback to use either same as video or htab as default.

Additional testings found that while real fullscreen works ok now, there might be a state mismatch between kodi and the windows' 3d display states - if kodi starts when windows already has 3d display enabled kodi ui will be washed out while kodi is fullscreen, clicking '/' will show the ui again. I have the solution already in mind and will upload a new build tomorrow.
(2022-02-09, 18:27)damagedspline Wrote: [ -> ]v19.3 test build for the crash fix when running in fullscreen & the new upscale of htab/hsbs to frame packed (full resolution 3d) download: https://app.box.com/s/czyqrf2m32yzj3l3dsaae4cdnk75mem6

my tests found that enabling the full resolution 3d upscaling of sbs & htab may cause audio issues randmoly on some desktops - fix might be the one in the kodi upstream code - i did not test yet.

to enable htab/sbs auto upscaling -> enable auto 3d display flag and preferred mode set to "hardware based".

Update: forgot to mention, when auto 3d display is enabled, exit the settings and re-enter back to set hw based as preferred mode. Hw based option will always be available when auto 3d display flag is on. In case hw does not support, it will fallback to use either same as video or htab as default.

Additional testings found that while real fullscreen works ok now, there might be a state mismatch between kodi and the windows' 3d display states - if kodi starts when windows already has 3d display enabled kodi ui will be washed out while kodi is fullscreen, clicking '/' will show the ui again. I have the solution already in mind and will upload a new build tomorrow.

Thanks for this. It has fixed the quit when stopping 3D playback for me and I swear it seems faster to change resolution back on stop too.

All of my remaining issue seem to be audio related and not related to the MVC code:
1) Audio still fails to lock and have to restart Kodi - Kodi 19 regression (Jogal recommendation helped but has not solved this)
2) Universal HDDVD DD+ cannot be bit streamed - Kodi 17 regression - I managed a slightly positive change with this but nowhere near fixed and beyond my basic skills
3) DD+ - EAC3 with EAC3 extension frame does not work - Have this working for bitstream disabled but fixing for bitstream seems way more complex
4) DTS CD / 14bit DTS stream does not bitstream (Code for this seems to have been copied from Kodi V16 and not appropriate).
5) Bitstream TrueHD with Atmos still occasionally interrupted (Much better since 19.3 fix)

All of the above work fine on the same Windows machine in VLC so pretty sure they are bugs. Do you get affected by quite a few audio bit stream bugs?
New release build v19.3.3 in first post.

After additional set of fixes to the HTAB/HSBS upscale, I did a lot of tests and they all passed. I still have audio issues after playing more than 10 clips in a row, but its an issue that comes from the Kodi upstream codebase.

Works flawlessly for me with the exception of the audio issue that pops every once in a while - all detailed in the release notes in the first post.

Sorry @Krobar , nothing I can do with the issue you encounterd - as the issue might come from Kodi audio engine. Please try with my latest build, i made a small change which might have impact.
BTW, when you play in VLC, does it use DirectSound or WASAPI for audio? Also, when using VLC do you see in your receiver info if the audio arrives as intended (especially for DD+/ATMOS/DTS:X). For me ATMOS & DTS:X work flawlessly using WASAPI.
I update the TODO list in the first post.

My next goal is keeping this fork's code up to date - I already have an MVC build based on the current Nexus code.
@Krobar would you like to test it and see if its solving your issue?

My next goal is to update the libbluray to a higher version - which is going to be quite challenging.
@damagedspline thanks, would like to give it a go.

To be honest I doubt issues 2-4 will ever be resolved as they are considered legacy and it seems there are not many devs who work in that area of the code (This is why I tried to have a go at resolving them myself). Hopefully 1 will be solved though; for 5 I think I may need to re-rip the discs with a newer MakeMKV because it may be down to older versions of MakeMNKV mishandling seamless branching TrueHD.
(2022-02-13, 18:32)Krobar Wrote: [ -> ]@damagedspline thanks, would like to give it a go.

To be honest I doubt issues 2-4 will ever be resolved as they are considered legacy and it seems there are not many devs who work in that area of the code (This is why I tried to have a go at resolving them myself). Hopefully 1 will be solved though; for 5 I think I may need to re-rip the discs with a newer MakeMKV because it may be down to older versions of MakeMNKV mishandling seamless branching TrueHD.

There you go

Please note:
1) Backup your %AppData%\Kodi - once you run this release it might make your settings incompatible with v19.3 if you switch it back
2) Jogal's patch is not merged yet so it is not included in this build - but there are numerous other patches in terms of display support, newer ffmpeg, and only 2 wasapi fixes which I dont think willl help you case
(2022-02-13, 22:33)damagedspline Wrote: [ -> ]
(2022-02-13, 18:32)Krobar Wrote: [ -> ]@damagedspline thanks, would like to give it a go.

To be honest I doubt issues 2-4 will ever be resolved as they are considered legacy and it seems there are not many devs who work in that area of the code (This is why I tried to have a go at resolving them myself). Hopefully 1 will be solved though; for 5 I think I may need to re-rip the discs with a newer MakeMKV because it may be down to older versions of MakeMNKV mishandling seamless branching TrueHD.

There you go

Please note:
1) Backup your %AppData%\Kodi - once you run this release it might make your settings incompatible with v19.3 if you switch it back
2) Jogal's patch is not merged yet so it is not included in this build - but there are numerous other patches in terms of display support, newer ffmpeg, and only 2 wasapi fixes which I dont think willl help you case

Finally got round to trying it today.

It has not fixed the issue but is different. Surprisingly it seems preferable to the V19 build in my setup.

I have not had any audio related crashes that require restarting Kodi yet however sometimes when I start a 3D movie it plays maybe a few seconds of video without sound and then stops. The difference is the GUI/Kodi does not crash I can just press stop and try again and it usually works second time (Often it works the first time). I wonder if the commits from thexai have fixed the crash but not the root of the problem(?)

As expected none of the legacy bitstream issues I list have been fixed but nice to have @BlackEagle's PCM mapping fix and so far it seems an improvement over the 19.3 build.
Current status: i have a build with updated libbluray and libudfread, non-encrypted 2d & 3d isos are working flawlessly. Encrypted 2d blurays are working flawlessly using makemkv. Encrypted 3d blurays title play are broken.
3d bluray menu mode never worked for me with kodi.
Just wanted to say the 19th Feb Kodi 20 build seems to have fixed the crashes on res/refresh change in my setup, big thanks for posting this in the other thread. I've been using it for a week now without a single crash; the earlier Kodi 20 build did fail with live TV eventually but this newest build seems to have properly fixed it even when using full screen window.
(2022-02-27, 20:23)damagedspline Wrote: [ -> ]Current status: i have a build with updated libbluray and libudfread, non-encrypted 2d & 3d isos are working flawlessly. Encrypted 2d blurays are working flawlessly using makemkv. Encrypted 3d blurays title play are broken.
3d bluray menu mode never worked for me with kodi.
You're a hero. Everything works like you described. Thank you very much!
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29