• 1
  • 3
  • 4
  • 5(current)
  • 6
  • 7
  • 13
Release TrueHD passthrough - New MAT Packer implementation (merged in master and Omega)
#61
Hello,

I'm experiencing the same "TrueHD Atmos Dropouts/Cutouts" problem (sometimes even DD+), great to hear you working on it, here is the log with your test-build:
iyitayinuz.kodi (paste)

The problem occurs whatever the file format is, such as .mkv, .ts, .m2ts.
In this case, audio dropouts about 6 times when playing this 1mins4sec file.

Devices: UGOOS AM8, Samsung HW-Q700C/XZ, Xiaomi SPRO 65mini led

Thanks a lot. Blush
Reply
#62
@xitwid

Seems you have a different issue:

dropouts are caused by ActiveAE::SyncStream

xml:
2024-05-14 00:09:00.882 T:10582   debug <general>: CXBMCApp::onReceive - Got intent. Action: android.intent.action.BATTERY_CHANGED
2024-05-14 00:09:10.354 T:10629    info <general>: Skipped 1 duplicate messages..
2024-05-14 00:09:10.354 T:10629   debug <general>: ActiveAE::SyncStream - average error 101.307417 above threshold of 100.000000
2024-05-14 00:09:10.354 T:10629   debug <general>: ActiveAE::SyncStream - average error 21.307417 below threshold of 30.000000
2024-05-14 00:09:11.714 T:10629   debug <general>: ActiveAE::SyncStream - average error -150.847934 above threshold of 100.000000
2024-05-14 00:09:11.719 T:10629   debug <general>: ActiveAE::SyncStream - average error -10.847934 below threshold of 30.000000
2024-05-14 00:09:11.732 T:10630 warning <general>: CPackerMAT::WritePadding: a large padding block of 216800 bytes is required due to unusual timestamps
2024-05-14 00:09:11.738 T:10630 warning <general>: CPackerMAT::PackTrueHD: detected a stream discontinuity -> output timing expected: 56736, found: 60096
2024-05-14 00:09:13.170 T:10582   debug <general>: CXBMCApp::onReceive - Got intent. Action: android.intent.action.BATTERY_CHANGED
2024-05-14 00:09:17.171 T:10629    info <general>: Skipped 1 duplicate messages..

CXBMCApp::onReceive - Got intent. Action: android.intent.action.BATTERY_CHANGED  ??

Maybe some background process and/or high CPU usage...

As you are using internal storage FileCache is not used with default settings. Try change this in Settings > Services > Caching

Buffer Mode : Buffer all filesystems
Memory Size: 64 MB
Read Factor: Adaptive


@Draconix
Can you also try these settings?

Seems current problems are due high CPU load and not directly related to TrueHD
Reply
#63
@Draconix

As you are using only USB storage... Are you aware of Shield USB performance setting?

Shield Settings > System > USB mode

With default settings Shield USB is limited at 250 mbps, only with "performance mode" has full 500 mbps

https://www.reddit.com/r/ShieldAndroidTV...usb_modes/
Reply
#64
(2024-05-13, 19:34)jogal Wrote: As you are using only USB storage... Are you aware of Shield USB performance setting?
Yeah, I've had it set to "Max performance" for a very long time now.

I tested both mkv and m2ts samples of Cars, and I heard several dropouts on both. It seems like @RedTwenty50 was correct and this has something to do with Seamless branching and Disney movies.
Now I'm going to try applying your caching settings and I will update this post with debug logs.

EDIT: Here are the logs
Cars .mkv Sample: https://paste.kodi.tv/ubokubiwak.kodi
Cars .m2ts Sample: https://paste.kodi.tv/bigogulemu.kodi

Unfortunately the caching setting didn't seem to help, I still heard several dropouts on both files. Hopefully these logs provide some more helpful information though.
Should I keep the caching setting or put it back to the default?

EDIT 2: I made a debug log for the Avatar sample with your caching settings, it still had dropouts in the usual spots: https://paste.kodi.tv/iwakuyapit.kodi

EDIT 3: I'm not sure if this might be helpful, but I tried my copy of Avatar using the AC3 compatibility track, and there were no dropouts: https://paste.kodi.tv/ocapagivav.kodi
Reply
#65
I have very good news. I able to reproduce these dropouts with these exact conditions:

1- advancedsettings  <maxpassthroughoffsyncduration>96</maxpassthroughoffsyncduration>
2- Play file from USB drive
3- Debug log enabled (with OSD)

Seems the most relevant condition is maxpassthroughoffsyncduration high value because overlaps with 100 threshold in:

ActiveAE::SyncStream - average error 101.307417 above threshold of 100.000000

Probably the fix will be increase this threshold and lower maxpassthroughoffsyncduration max value a bit.

This is very good because means these dropouts not has any relation with the new TrueHD MAT packer (nor the old one).

Meanwhile @Draconix test with <maxpassthroughoffsyncduration>62</maxpassthroughoffsyncduration>

I don't expect it to work perfectly, I just want to confirm if there is a trend for the better (e.g. instead of 4 dropouts, only 1) in Cars .mkv 5m sample
Reply
#66
Nice find. We should adjust the sync offset towards the advanced setting or the calibration value. By simply making sure that at least two packets (AC3: 32 ms each) fit on top without correction.

The offset is a self eliminating systematic issue, therefore it is not a problem to only correct a bit later.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#67
(2024-05-13, 19:13)jogal Wrote: CXBMCApp::onReceive - Got intent. Action: android.intent.action.BATTERY_CHANGED  ??

Maybe some background process and/or high CPU usage...

As you are using internal storage FileCache is not used with default settings. Try change this in Settings > Services > Caching

Buffer Mode : Buffer all filesystems
Memory Size: 64 MB
Read Factor: Adaptive
Sadly, the Caching Setting does help.

Actually the CPU usage always below 20%, and the dropouts occurs whatever the file system is (files over network behave the same)

I also noticed the battery change log too, but i dont know if it maters, because other audio stream format are fine except TrueHD.

I tried your advanced setting:
Code:
<maxpassthroughoffsyncduration>62</maxpassthroughoffsyncduration>
, doesn't help either Sad
Reply
#68
(2024-05-14, 18:26)xitwid Wrote: Sadly, the Caching Setting does help.

* doesn't help.
Reply
#69
(2024-05-14, 17:28)jogal Wrote: I have very good news. I able to reproduce these dropouts
That's great to hear! With this discovery I'm hopeful that a solution can be found.

Here's the log from the Cars mkv using maxpassthroughoffsyncduration 62: https://paste.kodi.tv/ovicusutet.kodi
Unfortunately I still heard 4 dropouts and even saw a couple video micro-stutters.
Reply
#70
(2024-05-13, 18:37)xitwid Wrote: I'm experiencing the same "TrueHD Atmos Dropouts/Cutouts" problem (sometimes even DD+), great to hear you working on it, here is the log with your test-build:
iyitayinuz.kodi (paste)

The problem occurs whatever the file format is, such as .mkv, .ts, .m2ts.
In this case, audio dropouts about 6 times when playing this 1mins4sec file.

Devices: UGOOS AM8, Samsung HW-Q700C/XZ, Xiaomi SPRO 65mini led
You have the Ugoos AM8, IEC-Passthrough for TrueHD is broken in their firmware; Ugoos official reply was "use Kodi 19.5" instead, and that their firmware may or may not get fixed in a future update.

All this was previously talked about in this thread if you read the previous comments.
Reply
#71
In my case dropouts number ant time stamps matches with log events:

ActiveAE::SyncStream - average error xx above threshold of 100.000000

If yours not (e.g only 1 log event and 4 dropouts)  This isn't going to solve it... it's probably not worth continuing with this.... My Shield works fine.
 
Quote:even saw a couple video micro-stutters.

Oh really?
Reply
#72
The micro-stutters were likely because maxpassthroughoffsyncduration set to 62 is too low for my Shield, causing ErrorAdjust to happen.
I'm a bit sad to hear that you don't think this is fixable or worth trying to fix. If you do change your mind and have a build for me to test, I'm more than happy to do that.
Reply
#73
(2024-05-14, 19:58)Draconix Wrote: The micro-stutters were likely because maxpassthroughoffsyncduration set to 62 is too low for my Shield, causing ErrorAdjust to happen.
I'm a bit sad to hear that you don't think this is fixable or worth trying to fix. If you do change your mind and have a build for me to test, I'm more than happy to do that.

Actually and in all fairness. It's kind of like your setup - somehow - is affected by things way more than others, we have seen this in that thread again. Also - while some effects seem to hit you explicitely, it might mean that the fix for all the effects might not existing from inside kodi.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#74
@Draconix: https://jenkins.kodi.tv/job/android-arm6...64-v8a.apk <- that one is just for you, when it's finished. Please test it - does anything improve? You can set your advancedsettings.xml back to 100 ms.

PS: It is the same code as before, but AE being a bit more friendly when it detects your specific shield.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#75
Thank you for trying to help me fix this problem @fritsch, I really appreciate it!

Here's the log: https://paste.kodi.tv/lexelolaqu.kodi
(maxpassthroughoffsyncduration = 100)

The video played perfectly smooth, but I think I heard 3 or 4 audio dropouts. Hopefully the debug log helps!
Reply
  • 1
  • 3
  • 4
  • 5(current)
  • 6
  • 7
  • 13

Logout Mark Read Team Forum Stats Members Help
TrueHD passthrough - New MAT Packer implementation (merged in master and Omega)0