Apple TV 4K Experimental Player causes video/audio to stutter horribly with .ASS subtitles

Server Version#: 1.19.1.2645
Player Version#: 2.15

When the experimental video player is enabled, video/audio stutters horribly when there are a lot of .ass subtitles displayed on the screen at once. I tested it with the player off and it played fine. I notice this with a lot of anime shows since they tend to use .ass subtitles. Is this a known issue?

Nope, not known :flushed:

Can you share a sample file with which you can reproduce the issue?

Instructions: Generating Sample Files from Media | Plex Support

Sample Download

Above is a link to a file that has this issue when played on Apple TV 4K with the experimental video player enabled. For this specific sample, audio seem unaffected. Play the file through Plex with no subtitles on and it will play smoothly. Then play it again with the .ass subtitles enabled and the video should stutter. It seems to be more of an issue when there are many .ass subtitles on the screen at once. Also, according to the technical details, this file is “direct playing”. No transcoding.

And worth mentioning again, this file plays fine with no stuttering with the experimental player disabled. I really hope this helps understand the bug and leads to a fix.

Well that is crazy :neutral_face: I can reproduce the issue but only on Apple TV, not on iPhone/iPad, which is very surprising because it’s exactly the same video player :neutral_face:

I’ll investigate further next week and try to keep you posted.

Thanks for your help!!

2 Likes

Yes, I should have mentioned that it works fine on iOS. It’s been driving me crazy for months and I’m relieved that someone was able to reproduce this. Thank you so much for looking into this!

Any updates?

Not yet, sorry. As I told you I can reproduce it but I haven’t found yet what exactly makes the difference. I need some help from other teammate, with more expertise on video/subtitle rendering, so I will have to borrow their time :sweat_smile:

I’ll let you know when we learn more about it.

@X_8P_X I think we found the reason. Basically the library we use to render ASS subtitles (libass) is not optimized for ARM CPUs (like the ones used by Apple TV, iPhones/iPads, Raspberry Pi and many other devices), only for x86 CPUs: libass/libass/x86 at master · libass/libass · GitHub

The lack of these optimizations makes it extremely slow in some circumstances. Until we have these optimizations in place (no ETA, it’s not an easy task :sweat_smile:), you can make playback smoother on Apple TV 4K by just going to tvOS Settings → Video and Audio and changing the resolution from 4K to 1080p. If you don’t watch 4K content, this shouldn’t be a problem to you.

This helps because subtitle rendering performance depends on the screen resolution (not the video resolution), which is why it seems to work better on iOS (but devices with more resolution will show the same problem).

I hope that helps for now!

That makes a lot of sense. Unfortunately, I do watch a lot of 4K content. But for the shows with .ass subtitles I guess I’ll just temporarily disable the experimental player.

Regardless, I’m happy that you guys were able to figure out the potential issue and add it to the list. I hope it can be fixed soon!

Thanks for keeping me updated! If you wouldn’t mind/if you remember, could you let me know if this is something that gets fixed? (If it doesn’t get explicitly stated in the patch notes)

It will be explicitly mentioned when that happens, don’t worry :smiley: But if I remember, I’ll reply to this thread. I’ll make a note :slight_smile:

Will fixing this perhaps also have a positive effect on the android player? .ass support is pretty garbage there as well. :expressionless:

If the problem in the Android player is performance too, then yeah, it will help there :smiley:

It’s not just that… Android can’t even play styled subs without transcode. Better performance in general probably wouldn’t hurt though. :slight_smile:

Speaking of performance. The Windows player doesn’t perform all that well with these kinds of subtitles either, at least not when comparing to how Kodi handles it. I’ve had a few files that more of less chokes Plex to death, while Kodi at least are able to stutter along. :sweat_smile:

Transcoding is a whole different issue :sweat_smile:

Which one is the Windows player? Plex Desktop? That one uses the same player as iOS and tvOS, but on Windows we’re talking about x86 so libass should be optimized and work at least as bad as Kodi, but not worse :thinking:

Totally, I’m just sad a transcode is still needed on the Android platform, even when users have been nagging about it for some time. There’s this rather lengthy thread, for example. Nvidia SHIELD/Android app SSA/ASS format anime subtitles + transcoding problems

I’m not really knowlegdeable about the code of Kodi vs Plex, but from my experience it seems like Kodi somehow makes sure that everything progresses, even though it means “skipping” a bit.

From the end user perspective it seems like Plex will just slow down untill it either crashes or are somehow able to catch up, the video freezes and so on until the subtitle animation is over. While Kodi seem to “skip ahead” in the video at certain points, I think it’s like twice a second, to make sure it doesn’t lag too much behind the actual time in the video. I don’t know if that made sense. It’s probably not related directly to libass performance, but they seem to have figured out some clever way of making sure playback doesn’t slow down too much, even in the case of excessively animated subs.

It’s a very extreme case though. I rarely experience these kinds of ridiculus sub animations these days, but they do happen from time to time with anime. :sweat_smile:

I’m usually using PMP on my HTPC, so that’s what I’m usually comparing with. :slight_smile:

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.