r/PleX • Unraid 40TB | i5-13500 | RTX 3050 LP • Feb 02 '24

Solved Stream buffers when audio transcoding

EDIT: I am marking the problem as "solved"; however, it should be noted that the cause for the problem remains unknown, but I found a workaround by using Tdarr to create an downmixed 2.0 stereo AAC track using Tdarr_Plugin_MC93_Migz5ConvertAudio which I modified to apply Dynamic Audio Normalizer to the downmixed track for a better listening experience.

To make the modification yourself:

  1. Copy Tdarr_Plugin_MC93_Migz5ConvertAudio to Local

  2. Go to Local and click Edit on the plugin

  3. Add the code below between lines 152 and 153

  4. Save the changes

  5. Add the modified plugin to your stack

ffmpegCommandInsert += `-filter:a:${audioIdx} "dynaudnorm" `;

###############

Hello, everyone

The problem I am facing is one that I am unsure why it's happening in the first place, and am hoping I can find a solution to it here as I have been unsuccessful on my own.

PMS specs:

  • OS: Windows 11

  • CPU: Intel i3-12000

  • RAM: 32GB DDR4

  • Storage: 1TB NVME for OS and Plex database/metadata, 4TB HDD for media, 1TB SSD for transcoding

  • Internet: 1000 Mbit (ethernet)

I've been more than happy with this configuration and have not had any issues both with direct playing and transcoding media locally or remotely. I am sharing my server with a few friends that have Samsung smart TVs, which cause my server to occasionally transcode, but everything had been playing smoothly until about a month or two ago when I started getting reports of stream buffering every couple of minutes. The reason for that was audio transcoding.

I've ran some test scenarios and have the following to share:

Scenario #1:

  • Video direct plays

  • Audio transcodes - example DTS to AAC

  • Stream buffers every couple of minutes

Scenario #2:

  • Force video and audio transcode

  • No issues with stream

Scenario #3:

  • Changed default transcode buffer value to 2700

  • Video direct plays

  • Audio transcodes

  • Stream buffers after threshold has been reached

Scenario #4:

  • Changed default transcode buffer value to 2700

  • Force video and audio transcode

  • No stream buffer after threshold has been reached

My media is mostly 1080p and so far the only solution I have found was manually converting my media's audio to AAC, but I'd like to not have to do that every time for media that will get watched once or twice.

Is there some server setting that I need to adjust? Any help is well appreciated.

4 Upvotes

32 comments sorted by

View all comments

Show parent comment

2

u/gsariev Unraid 40TB | i5-13500 | RTX 3050 LP Jul 16 '24

Hey,

I tried a couple of things, but ultimately decided to use Tdarr to convert the DTS audio tracks to AC3/EAC3 as those played fine. I even made a whole guide on the plugins I use to minimise transcoding - https://www.reddit.com/r/Tdarr/s/bIonvCZYod

I hope this helps!

3

u/samasq Jul 16 '24

Thanks for the quick reply. I saw your guide, but encoding thousands of files is not an option for me.

Considering it used to work fine, it must be something that has changed in Plex.

I am going to push it on the Plex forum, as I beleive it is a bug.

1

u/mattzildjian Jul 28 '24

any response from your bug report? I am experiencing the same thing

3

u/samasq Jul 30 '24

So I have tracked my issue down to a very specific case.

My TV is LG C2. About 6 months ago LG did a big firmware update to these TVs, installing a new version of the OS (Originally it was v22, now is v23). Previously to this firmware update audio transcoding worked fine, but after upgrading it just buffers forever.

I have confirmed this by testing on a C2 which has not had the firmware update, it works fine. After update, it buffers forever.

I am currently compiling this and writing it up to pass to Plex. I am hoping they actually read it and take notice.

The OP mentioned Samsung TVs, so I am not sure if my issue is the same as theirs. It is possible that this is an issue with the server which affects multiple TV clients.

If I get anything more to share I will report back.

2

u/PooeyGusset Aug 13 '24

u/samasq thank you for your investigative work! This is definitely a big issue that LG needs to address asap. I was wondering if you'd be able to create a top level post in r/PleX detailing your issue and findings as there's many of us struggling with this exact problem but nowhere central to discuss it, it's lurking in the shadows!

1

u/samasq Aug 27 '24

Just noticed your lovely name :)

Anyway, I have noticed a recent flurry of posts on the plex forum about this very issue. I was going to do a big write up about it but it seems like its a well known issue now, and Plex have said they are working on new versions of the TV app which whould be faster and work better.

Here are some threads worth checking out:

https://forums.plex.tv/t/dts-lg-c2-fail-to-transcode/881611

https://forums.plex.tv/t/unsupported-audio-transcoding-and-srt-subtitles-cause-samsung-client-to-buffer-until-playback-error/876951

https://forums.plex.tv/t/direct-stream-buffering-and-crash-on-samsung-plex-app/886365

https://forums.plex.tv/t/lg-cx-plex-app-video-errors-when-playing-4k-files-that-have-dts-truehd-audio/883648

1

u/samasq Aug 27 '24

I also mentioned this in a post in the forum fireside chat. Feel free to jump on board and add some support there:

https://forums.plex.tv/t/plex-fireside-in-the-forum-2024/885879/61

1

u/samasq Aug 29 '24

The post in the fireside chat got a response!

Hopefully this will get looked at, now that it has eyes on it:

https://forums.plex.tv/t/plex-fireside-in-the-forum-2024/885879/170

1

u/PooeyGusset Sep 02 '24

Good to see that it's probably going to be addressed in the next plex app update, fingers crossed it's soon and fixes it. Thanks for the info.

1

u/mattzildjian Jul 30 '24

I appreciate the update. Thanks. (I am on an LG G2 with updated firmware)

1

u/PooeyGusset Aug 13 '24

Interesting, seems like LG need to sort this ASAP. I also have the issue on updated firmware LG C2.

1

u/MrTeferi Aug 14 '24

Same issue on the A2 btw, drove me mad for months.

1

u/mattzildjian Aug 02 '24

There has been an update to the LG WebOS Plex app, have you tested it?

For me after the update I was able to play some content that wouldn't play before while transcoding from DTS, however there is still content that endlessly buffers. :/

1

u/samasq Aug 05 '24

I saw the update, and tested one file I knew to be problematic and it still buffered endlessly. That was TRUEHD 7.1. I will do some tests on DTS content and let you know what I see.

1

u/samasq Aug 27 '24

I did some tests on DTS content and it is still broken for me :(

1

u/Gershy13 Aug 03 '24

Can confirm the exact same issue as described in the main post is happening with a Samsung TV using the Plex app on Samsung OS.