jellyfin / jellyfin-roku

The Official Roku Client for Jellyfin
https://jellyfin.org
GNU General Public License v2.0
438 stars 133 forks source link

Secondary Audio streams do not transcode like on the web (mp4 h264 acc) #923

Open rangeroob opened 1 year ago

rangeroob commented 1 year ago

Software Versions Jellyfin Server Version: 10.8.8 Roku Client Version: 1.6.2

Describe the bug I have noticed that mp4 files that have a secondary audio stream do not play. Looking at the logs of both the web player and the roku separately indicate that the roku does not attempt to transcode / remux with the secondary audio instead it direct plays and because of that it does not play the secondary audio stream.

I am using mp4 encoded media with h264 and acc

This affects mkvs with h264 and acc as well.

How To Reproduce

  1. Go to TV series episode
  2. Click on * to bring audio select menu
  3. Select Secondary audio
  4. Attempt to play media
  5. Media plays with default audio stream

Expected behavior

The media should play the selected secondary audio stream.

I believe if I could force the transcoding/remux of the media this would not be an issue

Logs

https://gist.github.com/rangeroob/92128578dee27f108716c3f294e062ad

https://gist.githubusercontent.com/rangeroob/92128578dee27f108716c3f294e062ad/raw/b1410ad4d9e7cee144ba45babb371c0064bd8b26/gistfile1.txt

a snippet of the difference between roku and web

roku:

StreamBuilder.BuildVideoItem( Profile="Anonymous Profile", Path="/media/backupSGHD1/Anime/Made in Abyss/Season One/Made In Abyss - 1x01 - The City of the Great Pit.mp4", AudioStreamIndex=3, SubtitleStreamIndex=-1 ) => ( PlayMethod=DirectPlay, TranscodeReason=0 )

web:

StreamBuilder.BuildVideoItem( Profile="Anonymous Profile", Path="/media/backupSGHD1/Anime/Made in Abyss/Season One/Made In Abyss - 1x01 - The City of the Great Pit.mp4", AudioStreamIndex=3, SubtitleStreamIndex=0 ) => ( PlayMethod=Transcode, TranscodeReason=SecondaryAudioNotSupported )

Connection Information Is server local or remote?

local

Is server connection http or https?

https via nginx reverse proxy

Additional context This could be a similar issue to #657

And I would agree with #904 that maybe we'd need a force transcode option

rangeroob commented 1 year ago

The original author of bug: jellyfin/jellyfin#7896 (which #657 was pointed too) comment on a workaround solution which I have confirmed to work is to use another codec for the secondary audio that your roku supports ( like ac3). I have confirmed that to be solution due to the server direct streaming/ transcoding the audio back into acc and playing the correct audio stream.

I am hopeful that #927 may get merged in so that the users affected by this can play all there media without re-encoding their whole library

sevenrats commented 1 year ago

@rangeroob does 927 have the desired effect? have you tested it?