jellyfin / jellyfin-media-player

Jellyfin Desktop Client
GNU General Public License v2.0
3.09k stars 309 forks source link

HEVC Media Not Playing Back Correctly #594

Open HikariNoKitsune opened 5 months ago

HikariNoKitsune commented 5 months ago

Describe the bug HEVC Content appears to not be hardware accelerated within the Jellyfin Media Player. Or, if it is, the player is seemingly incapable of playing back the content at an appropriate frame rate (ei appears to be between 5 to 20fps randomly).

To Reproduce Steps to reproduce the behavior:

  1. Open any HEVC video to play
  2. Try to watch the video
  3. Observe frame rate stutter (can be a different amount of stutter at any given attempt of playback. As in, the amount of stutter is not consistent and varies each time you open the media).

Expected behavior The video to be played back at the appropriate frame rate...

Desktop (please complete the following information):

Additional context Had noticed this issue occur several months ago. Didn't think much of it and just thought that the win11 NUC might have just not been powerful enough to playback the content. However, recently while in a Watch Group with several friends, I asked people if anyone else was getting a stutter... every single person said 'yes'.. That's when I tried to play the video back on the web browser, and the stuttering was gone. It still said it was Direct Playing just like the Media Player was. . . Figured that today i would try swapping out the NUC with my old gaming PC to see if that made any difference (i7-4700, gtx 1070ti, 32GB RAM), and it didn't... the stuttering is exactly as it was with the nuc. Of which, the NUC isn't any real slouch either running an i7-1070 i think? can't exactly check at this very moment as its unplugged...

But anyway! I thought this was even more odd, as I couldn't remember having this issue with my current PC (i9-9900k, 2080ti, 64GB RAM)... but then I went back and tried, and it is because for some reason its just transcoding everything... saying that the 'bitrate is too high' even though i'm on the internal network...... it refuses to see it as being 'internal for some reason, but that's a 'whatever' issue atm...

Now... here's the REALLY weird aspect of this.... If I use my Tablet (Galaxy Tab S9), it shows 'Direct Streaming' instead of 'direct playing', and the video looks PERFECTLY FINE... Oh, but that's not the weirdness!!! If I play the video on the tablet, THEN play the same video on any of the other devices... and the stutter is GONE. I stop the playing the video on the tablet and the PC, and try to play the video on the PC by itself, and the stutter is immediately back....

However, if I play the movies in Chrome, there is no stuttering at all... but then that is just because its transcoding everything as "the playback codec isn't supported" or whatever, cause I guess Chrome can't play back HEVC files directly???

Sorry that this has gotten kinda, derailed and rambly... But trying to provide all the info that I can. Although sadly, looking at the github history... it doesn't appear as if the media player is getting any love at all... So I'm not too optimistic that a fix for this is going to come any time soon. Specially since looking around at the current issues, there were one or two people mentioning something similar but with Linux FlatPaks, and someone else mentioned a codec issue which sounds almost simlar.. but that issue was submitted back in 2022, and is still open...

Hopefully some of this rambling makes sense to someone, and hopefully something can be done to fix it... Jellyfin had one really good thing going for it for me: "It just worked". Plex and Emby both had deal breaking issues for me... and if this never gets fixed, then it becomes a Deal Breaker for me.. as Direct Playing my media is key for me...

HikariNoKitsune commented 5 months ago

Welp, this might be moot now... After discovering the 'triage board' and looking through it some, I stumbled across someone who is saying that the hardware accel settings in the client UI is broken. Appears this might be exactly what's going on... as when i follow their discovery of 'enabled means disabled', and disabled hardware accel, suddenly my GPU is being used and all the stutters go away... However I haven't tested on many movies atm... just three... and while it IS better, it doesn't seem 'correct' still. if the framerate is supposed to be 24fps, it miiiight be at 22fps. Good enough to not be noticed if you're not paying attention, but not good enough that if you are focusing on it, you can def tell it isn't as smooth.

But at least I can def see the GPU Decode being used and CPU is barely touched at all. So Woot! Need to test with the NUC to see if its fixable... as I'd really much rather use a lower power consuming device, than a big gaming desktop lol..