Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Native mode with Jellyfin Server 10.10 #937

Open
FredHaa opened this issue Nov 11, 2024 · 7 comments · May be fixed by #926 or #925
Open

Native mode with Jellyfin Server 10.10 #937

FredHaa opened this issue Nov 11, 2024 · 7 comments · May be fixed by #926 or #925
Labels
duplicate This issue or pull request already exists Native Mode Issue is related to Native playback mode support Not a bug or feature request, but a request for support.

Comments

@FredHaa
Copy link

FredHaa commented Nov 11, 2024

Hi

Now when the current implementation of native mode is no longer supported by Jellyfin, is there a plan for supporting the future another way? My experience with the plugin has been significantly degraded after having to use add-on mode instead of native.

  1. Starting a video went from instant to taking a significant amount of time
  2. Skipping also takes a long time
  3. Subtitles regularly go out of sync
@mcarlton00
Copy link
Member

"Native mode" is no longer an option in it's current form. The server does not provide the data required to implement it. It is possible to reimplement it entirely client side, which is what #926 attempts to do, but in a very limited scope and isn't mergeable in it's current state.

None of the developers have ever used native mode outside of very infrequent tests. There's frankly no reason for it in the vast majority of use cases. The only truly valid reason for native mode is if you keep raw disk images instead of muxing them into video files like the majority of people, and even then addon mode functions exactly the same as every other Jellyfin client now.

As for your stated issues, I have multiple devices I test from, everything from a Ryzen 5800x to a Raspberry Pi 3b.

  1. Starting a video takes under 2 seconds. If it takes significantly longer than this, you're likely transcoding or remuxing for some reason (see: raw disk images), or have a very underpowered device somewhere in your stack.
  2. Near instant on all of the devices I test against. Again, if taking any significant amount of time, it's likely because you're forcing a transcode for some reason and the server has to restart the stream.
  3. In 5+ years of using this addon (and many other Kodi addons), I've never experienced this issue. In my experience, if subs are out of sync, they're out of sync on all devices and media players. We just hand Kodi the video/audio/subtitle streams and it handles playback itself, we have no input there.

@fcr
Copy link

fcr commented Nov 11, 2024

@mcarlton00, I have a use case for native library access:
I want to use Jellyfin to manage my video library and to use Kodi as my Media Center. But I also need dual subtitles that neither Kodi or Jellyfin provide. This is where the Kodi addon helps. When chosen in the subtitle popup menu if finds and lists all subtitles that are in the same folder as the video and allows selecting up to two. But this only works if it sees the native library file paths. #926 solves this problem for me and probably for others.

@FredHaa
Copy link
Author

FredHaa commented Nov 12, 2024

1. Starting a video takes under 2 seconds.  If it takes significantly longer than this, you're likely transcoding or remuxing for some reason (see: raw disk images), or have a _very_ underpowered device somewhere in your stack.

My server runs on on a i5-10500 which should be plenty fast to run a single 4K stream. I have it set up with the LinuxServer.io opencl mod, and it uses VAAPI for transcoding. My client device is an Odroid-N2+ which, again, should be plenty powerful. I have noticed that, with add-on mode, EAC-3 audio with Atmos gets transcoded to AAC, thereby removing the Atmos information. This should not happen, so I guess there is a setting I need to tweak to specify that my device is Atmos capable? My audio settings currently specify that my setup handles AC3, EAC3 and TrueHD, but not DTS/DTS-X.

However, even when transcoding the audio, I wouldn't think I would get such a big delay starting the videos (sometimes 10-15 seconds), since audio transcoding is way faster than video transcoding.

2. Near instant on all of the devices I test against.  Again, if taking any significant amount of time, it's likely because you're forcing a transcode for some reason and the server has to restart the stream.

So even if audio is fast to transcode, the act of restarting the stream is what's causes the delay?

3. In 5+ years of using this addon (and many other Kodi addons), I've never experienced this issue.  In my experience, if subs are out of sync, they're out of sync on all devices and media players.  We just hand Kodi the video/audio/subtitle streams and it handles playback itself, we have no input there.

When the sync issue occurs (which is frequently), stopping the video and starting it again fixes it, indicating that it is the stream and not the file which goes out of sync. But maybe it is related to the other issue causing poor stream performance. I might need to check my network cabling to see if a cable has come loose making the connection unstable.

@kandykarter
Copy link

I'd agree with @fcr in regards to subtitle handling. I recently made the move to add-on mode from being a long-time native mode user, and the only real issue I'm facing is how much worse subtitle handling is. Is there anything being done to improve subtitles in J4K? I used to be able to select any of several subtitles in the movie folder, now I'm stuck with whichever one Jellyfin defaults to.

@it5c0z1mG
Copy link

@mcarlton00 Native mode from user perspective,

i have multiple xboxs both local and remote and 1 centralised server,

i use native mode with a backing of smb on the kodi xbox app:

-it allows a single load of the library metadata when opening the app instead of loading on the fly as addon mode is at best sluggish and at worst crashes or hangs the app. (Normal xbox stock os has a limit of 2gb ram for apps and library permission limitations, i imagine this has something to do with it as xbox dev mode is slightly better but not much)

-native mode allows kodi to retime or replace out of sync subtitle or audio instantly using normal kodi settings,

-allows kodi to download new subtitles straight from kodi into the smb folder ready for jellyfin, working hand in hand,

-if the external web interface goes down, nginx goes wrong, outside internet line goes down, jellyfin updates automatically or even corrupts, everything still keeps playing whilst i fix or revert the jellyfin instance and as its running on direct smb, no video interuptions, no playback pausing, just works.

  • for my use case, I have a library of 3D mp4 30gb-60gb each, all with metadata written in to make kodi auto flick between 2d and 3d mode at start of playback,
    addon mode fails to play these on every device ive tried, trancoding these ruins them or fails, nothing but kodi can play these directly,

Jellyfin+kodi+xbox together give you the best library, the best playback, and all on a 4k xbox you proberley already own,

Im sure there are many others with different usecases but for me theyre a make or break im stuck on j9 until some form of workaround can be implemented sucessfully.

Do you know whats stopping the #926 implementation and is there anyway i can help to speed it up?

@Robert904
Copy link

To advocate for restoring a native mode capacity, here's my use case:

  • One central Jellyfin
  • I have several locations, each of them with a libreelec installed
  • Internet connection is not very stable in all of the locations, not well suited for streaming
  • I permanently synchronize the medias in the background on a local storage to have it ready when I want to play it. I want to benefit from the Jellyfin features (playback position, ...), while consuming the local files to avoid troubles during playback

Many thanks for for your work!
I second @mcarlton00, what would be needed to allow this PR to be merged, and how could I help ?

@oddstr13
Copy link
Member

Read my comments on the PR, I've outlined what I think is needed. ask for clarification if something is unclear.

@oddstr13 oddstr13 added duplicate This issue or pull request already exists Native Mode Issue is related to Native playback mode support Not a bug or feature request, but a request for support. labels Nov 13, 2024
This was linked to pull requests Nov 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists Native Mode Issue is related to Native playback mode support Not a bug or feature request, but a request for support.
Projects
None yet
7 participants