Jump to content

Stuttering/laggy 4K directplay on Theater, but not on WebOS app.


Go to solution Solved by Guest,

Recommended Posts

Posted (edited)

Hi there,

I'm experiencing weird/stuttery/laggy behaviour. When I try to directplay a 4K file above a certain bitrate.

Setup:
Intel NUC nuc7i5bnk
8gb ram
Acts both as server and client (Emby Theater)
Connected via Wifi

NAS with ethernet connection

Files tried (similar results):
The.Lord.of.the.Rings.The.Fellowship.of.the.Ring.2001.Extended.UHD.BluRay.2160p.TrueHD.Atmos.7.1.DV.HEVC.REMUX-FraMeSToR (123gb)
The Lord of the Rings The Fellowship of the Ring 2001 Extended Cut UHD BluRay 2160p DDP 7 1 DV HDR x265-BHDStudio (28gb)

Scenario's tried:

  1. Subtitles on/off/srt
  2. TrueHD7.1 or AC3


When playing on Theater it doesn't transcode, but the playback is stuttery/laggy from the start. Seeing really poor FPS and the CPU is getting absolutely hammered (100% load, hot and loud see: taskmanager-directplay.png).

However, when I play the same movie via the WebOS app, it only has to transcode the audio source from TrueHD to AC3 and it changes the container from MKV to HLS, in this case, it works perfectly fine. No issues whatsoever. (CPU has headroom, running fine see: taskmanager-transcode.png)
At first I thought it was the CPU just not being up to the huge bitrate needed (since it's also extremely laggy when I try to play the file via BSPlayer on the Windows device).

I fail to recognize/understand why it doesn't work natively, but it works without a hic-up streaming it to LG WebOs (via Wifi even). I've attached the transcode log for the stream that works fine, I can't attach log for the directplay file that's laggy since there are none ;D Could it be that the transcode throttle gives the CPU  some breathing room, whereas the directplay version is bringing the cpu to its knees?

The stuttering is the CPU/NUC just not being competent enough, it has seen better days, but you would expect transcode to make it perform worse, not directplaying 4K files.. I hope you guys can shed some light on this. Thanks.

 

laggy-stream.png

taskmanager-directplay.png

taskmanager-transcode.png

ffmpeg-remux-30a85cef-9792-4a6a-b0d7-28d75b319872_1.txt

Edited by Kwin
Posted

Hi, please attach the main emby server log as well. Thanks.

Posted

@Luke
This information was visible in the screenshot of my original post, but that would be "Emby Theater 3.0.20"

Hope that helps, if not mistaken, that should be the latest version.

Posted
On 1/8/2025 at 1:43 PM, Kwin said:

At first I thought it was the CPU just not being up to the huge bitrate needed (since it's also extremely laggy when I try to play the file via BSPlayer on the Windows device).

You've answered your own question but you're also trying to compare apples and oranges here since you're talking about 2 different scenarios using 2 different devices. This device does not have the horsepower to keep up with playback if it's laggy with all players. When you're playing on the WebOS device and the server is transcoding the audo this is a fairly lightweight CPU operation, granted this is an old low power dual core system so it looks like a lot of usage but on a more modern system with more core it's a few % CPU at most, so really all it's doing is sending the content to another system which is then responsible for playback. From what I can find the iGPU should support HEVC decode/encode but applications might not be using it and it's falling back to CPU, or CPU is still used for certain things IE scaling/filters, and doesn't have the power to keep up with that.

Just because a video is being served directly doesn't mean that it's "easy" for the playback device to play it.

Posted

Post a screenshot of the stats when the issue is happening 

Posted (edited)
15 hours ago, Lessaj said:

You've answered your own question but you're also trying to compare apples and oranges here since you're talking about 2 different scenarios using 2 different devices. This device does not have the horsepower to keep up with playback if it's laggy with all players. When you're playing on the WebOS device and the server is transcoding the audo this is a fairly lightweight CPU operation, granted this is an old low power dual core system so it looks like a lot of usage but on a more modern system with more core it's a few % CPU at most, so really all it's doing is sending the content to another system which is then responsible for playback. From what I can find the iGPU should support HEVC decode/encode but applications might not be using it and it's falling back to CPU, or CPU is still used for certain things IE scaling/filters, and doesn't have the power to keep up with that.

Just because a video is being served directly doesn't mean that it's "easy" for the playback device to play it.


That would be my suspicion as well, that it's just not up to par to both act as the server and playback device for huge 4K content at the same time. Yes it's an older CPU, but.. it's a Kaby Lake (7th gen) era CPU with a Iris Plus 640. It should be capable enough to playback 4K content. It should support 60hz 4k HDR playback.

It has no issue at all if I transcode that movie to 1080p H264 with tone mapping on 30Mbps, from 40Mbps and up it starts to experience issues.

I was thinking about upgrading the emby server to either a new minipc like the n100/n200 or upgrade my server rack with a i3-12100, which i'm probably doing anyways, but I'm trying to understand what the limiting factor on the i5-7260u is since it should be capable, specwise, to handle atleast 1 4K stream (directplay). I'm trying to understand if it is indeed the hardware not being able, or if the hardware (or drivers) are faulty/not working as intended.

Playback stats when direct playing from NUC Emby Theater on Windows 11 (displayed on TV) attached to post.

Screenshot 2025-01-15 at 09-46-04 Foto - Google Foto's.png

Edited by Kwin
Posted

You could try the latest Emby theatre in the MS store and select the energy efficient preset.

Tone mapping with DV does use a chunk of cpu.

Do SDR 4K movies work fine?

 

 

 

  • Solution
Posted
37 minutes ago, Kwin said:


That would be my suspicion as well, that it's just not up to par to both act as the server and playback device for huge 4K content at the same time. Yes it's an older CPU, but.. it's a Kaby Lake (7th gen) era CPU with a Iris Plus 640. It should be capable enough to playback 4K content. It should support 60hz 4k HDR playback.

It has no issue at all if I transcode that movie to 1080p H264 with tone mapping on 30Mbps, from 40Mbps and up it starts to experience issues.

I was thinking about upgrading the emby server to either a new minipc like the n100/n200 or upgrade my server rack with a i3-12100, which i'm probably doing anyways, but I'm trying to understand what the limiting factor on the i5-7260u is since it should be capable, specwise, to handle atleast 1 4K stream (directplay). I'm trying to understand if it is indeed the hardware not being able, or if the hardware (or drivers) are faulty/not working as intended.

Playback stats when direct playing from NUC Emby Theater on Windows 11 (displayed on TV) attached to post.

Screenshot 2025-01-15 at 09-46-04 Foto - Google Foto's.png

In the settings, switch video output to gpu-next. You're playing HDR media that is being tone-mapped by the player. If you have an HDR display, using gpu-next with hardware acceleration set to auto, should allow HDR passthrough. 

Why aren't you using the new app? Go to the Windows store and install it.

Also, in your library settings, configure the the optional shared network folder. This will allow actual direct access of your files for the player. Currently, everything is being streamed through the server.

Posted
10 minutes ago, generiq said:

In the settings, switch video output to gpu-next. You're playing HDR media that is being tone-mapped by the player. If you have an HDR display, using gpu-next with hardware acceleration set to auto, should allow HDR passthrough. 

Why aren't you using the new app? Go to the Windows store and install it.

Also, in your library settings, configure the the optional shared network folder. This will allow actual direct access of your files for the player. Currently, everything is being streamed through the server.

The last transcode example was just a test when transcoding the video to my desktop browser (emby desktop player), HDR passthrough works fine on Theater. Since you mentioned it was only transcoding the audio on my tv (light CPU load), I was testing the performance when video, auto and subs all have to be transcoded.

I didn't realize there was a difference between the Windows store and Web version of theater? I've always used https://emby.media/emby-for-windows.html assuming the store app was outdated since it states being on version 2.210.0 compared to 3.0.20 version i'm running. Does the MS version have other performance benefits over the Proton version?

I've just tested the MS app (on my pc) and It has a whole set of (video) settings i've never seen before :o that might actually be the solution to get the GPU to handle the stream properly instead of the CPU/software.

I'll get back to you when I've got the new test results from the actual device instead of my pc (have set up optional shared paths as well now).

Posted
2 minutes ago, Kwin said:

The last transcode example was just a test when transcoding the video to my desktop browser (emby desktop player), HDR passthrough works fine on Theater. Since you mentioned it was only transcoding the audio on my tv (light CPU load), I was testing the performance when video, auto and subs all have to be transcoded.

The stats screenshot you posted isn't transcoding. The player is tone-mapping which requires more processing. 

The new app has an option to automatically enable Windows HDR, turn it on. The default settings for video should be ok. If not, try 'Energy Efficient'.

Posted
15 minutes ago, Kwin said:

I've just tested the MS app (on my pc) and It has a whole set of (video) settings i've never seen before :o that might actually be the solution to get the GPU to handle the stream properly instead of the CPU/software.

That would have been solved by select gpu-next, as i suggested. The new app defaults to gpu-next. The new app will better for you.

Posted
9 minutes ago, generiq said:

The stats screenshot you posted isn't transcoding. The player is tone-mapping which requires more processing. 

The new app has an option to automatically enable Windows HDR, turn it on. The default settings for video should be ok. If not, try 'Energy Efficient'.

I completely missed the color matrix being bt.2020/sdr.. that would explain a lot. Weird that the emby dashboard and/or user reports don't show that it's tonemapping. I blindly assumed it was direct playing everything, since there was no visual indication from the server dashboard that tone-mapping was going on. Once I get access to the embyserver/theater I'll test everything again with the knowledge I know now, will get back to you asap with new results.

Posted (edited)
1 hour ago, Kwin said:

I completely missed the color matrix being bt.2020/sdr.. that would explain a lot. Weird that the emby dashboard and/or user reports don't show that it's tonemapping. I blindly assumed it was direct playing everything, since there was no visual indication from the server dashboard that tone-mapping was going on. Once I get access to the embyserver/theater I'll test everything again with the knowledge I know now, will get back to you asap with new results.

It was directly playing. That's what i was telling you. And that's why the server dashboard doesn't show any changes to the video. The player in the emby for Windows app is more capable than the server. It handles everything natively. The new app is configured better than Theater, and should work better without having to reconfigure the settings. 

Edited by generiq
Posted (edited)

Actually, it was directly streaming because you don't have your file path set in the library. The server says it's directly playing but it's a lie. It's streamed through the server. This should show the file name if it was directly playing

 

Screenshot2025-01-15at09-46-04Foto-GoogleFotos.png.75f224660409cb26956e550d120b7889.png.fd03e203420d3ad008c372801110fc2b.png

Edited by generiq
Posted

Unfortunately, the new app stats doesn't show this, but you can see it in the logs

Media Source:
{
    "Protocol": "File",
    "Id": "774884db463d2aed440e28cbfaafb6f1",
    "Path": "C:\\Users\\dingb\\Downloads\\Videos\\Movies\\Thor, Ragnarok (2017)\\Thor, Ragnarok (2017).mkv",

 

Posted (edited)

@generiq
You've cracked the issue my friend! Many thanks.
The video plays fine in the new app and finally uses D3D11VA hardware acceleration instead of the software decoder. It should also now be actually direct playing without having to stream the file.

These are the current stats:

stats-emby-ms-app.png

emby-dashboard.png

 

{"Protocol":"File","Id":"8d66896c78da77fa994cd71aa9c63492",
"Path":"\\\\Downloadstation\\HGST\\Movies\\The.Lord.of.the.Rings.The.Fellowship.of.the.Ring.2001.Extended.UHD.BluRay.2160p.TrueHD.Atmos.7.1.DV.HEVC.REMUX-FraMeSToR\\The.Lord.of.the.Rings.The.Fellowship.of.the.Ring.2001.Extended.UHD.BluRay.2160p.TrueHD.Atmos.7.1.DV.HEVC.REMUX-FraMeSToR.mkv",
"Type":"Default",
"Container":"mkv",
"Size":126023154932,
"Name":"The Lord of the Rings: The Fellowship of the Ring",
"IsRemote":false,
"HasMixedProtocols":false,"RunTimeTicks":136917580000,
"SupportsTranscoding":true,
"SupportsDirectStream":true,
"SupportsDirectPlay":true,

 

Edited by Kwin

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...