jellyfin / jellyfin-androidtv

Android TV Client for Jellyfin
https://jellyfin.org
GNU General Public License v2.0
2.9k stars 493 forks source link

Play Movie encode in AV1 with DV not detect DV #3578

Open llutic opened 6 months ago

llutic commented 6 months ago

Describe the bug

Hello ,

I don't know if this is the right place to post this bug.

Please note that all playback is done live without transcoding (transcoding disabled on the server side). I also tested with MP4 and MKV files, knowing that I own MKVs in 99% of cases.

I have AV1 files with DoVi layer (Profile 10 and not profile 5, 7 and 8 as for HEVC files).

I'm able to play these files with the DoVi profile 10 layer via the Android TV app on a TCL 65C845X2 TV (Google TV 12) which has a Mediatek Pentonic 700 chip with AV1 decoder and Dolby Vision (codec check via the Codec Info app). the Dolby Vision hardware decoder is referenced as c2.mtk.dvav1.10.decoder with profile level DolbyVisionProfileDvav110 (0x400): DolbyVisionLevelUhd60 (0x100) (supported since API level 30, i.e. Android TV 11). So far, so good

Now with my TV, which is a TCL 55C825 (Google TV 11) with Mediatek MT9615 chip and AV1 and DoVi decoders as well (check codecs via the Codec Info app). Here I have 2 Dolby Vision hardware decoders referenced: OMX.MS.AV1.DOLBY_VISION.Decoder with profile level DolbyVisionProfileDvav110 (0x400): DolbyVisionLevelUhd60 (0x100) (supported since API level 30 so Android TV 11) as well as OMX.MS.DOLBY_VISION.DVAV1.Decoder with exactly the same profile level supported. But to my great surprise, the most I get is the HDR10 layer.

The most surprising thing is that I tried with Jellyfin Android TV version 0.16.10 as well as version 0.160 Just (Video) Player and in both cases I only had HDR10 and not Dolby Vision. But with Kodi version 21.0 and the same files, I have the DoVi layer detected and displayed correctly on my TV.

According to this source (Google Developers), the correct profile is supported: https://developer.android.com/reference/android/media/MediaCodecInfo.CodecProfileLevel#DolbyVisionProfileDvav110

Here are the source files I converted myself using SVT-AV1-PSY version 2.0.0, which supports Dolby Vision encoding:

https://drive.google.com/drive/folders/1HQmWPa5D6s288-GeWU1l8z2GV-CZ9sZ5

Correspondence of DV Profiles in accordance with Dolby documentation:

https://professionalsupport.dolby.com/s/article/What-is-Dolby-Vision-Profile

HEVC --> AV1 :

P5(.0) -> P10(.0) P8.1 -> P10.1 P8.2 -> P10.2 P8.4 -> P10.4 P7.6 -> P10.6 (Not documented but possible)

Logs

[2024-05-15 10:53:56.901 +02:00] [INF] [122] Jellyfin.Plugin.PlaybackReporting.Data.PlaybackTracker: PlaybackTracker : Adding Stop Event : 05/15/2024 10:53:56
[2024-05-15 10:53:56.901 +02:00] [INF] [122] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: Saving playback tracking activity in DB
[2024-05-15 10:54:01.697 +02:00] [INF] [68] Jellyfin.Api.Helpers.MediaInfoHelper: User policy for "User". EnablePlaybackRemuxing: False EnableVideoPlaybackTranscoding: False EnableAudioPlaybackTranscoding: False
[2024-05-15 10:54:01.698 +02:00] [INF] [68] Jellyfin.Api.Helpers.MediaInfoHelper: RemoteClientBitrateLimit: 1000000000, RemoteIP: "Restricted", IsInLocalNetwork: True
[2024-05-15 10:54:01.781 +02:00] [INF] [144] Jellyfin.Api.Helpers.MediaInfoHelper: User policy for "User". EnablePlaybackRemuxing: False EnableVideoPlaybackTranscoding: False EnableAudioPlaybackTranscoding: False
[2024-05-15 10:54:01.781 +02:00] [INF] [144] Jellyfin.Api.Helpers.MediaInfoHelper: RemoteClientBitrateLimit: 1000000000, RemoteIP: "Restricted", IsInLocalNetwork: True
[2024-05-15 10:54:01.852 +02:00] [INF] [68] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: Adding playback tracker : ce8b2bdb6568be55132f9d985f84613be0fd30eb-7b5b968bd88d476b9ae8781992de8ece-f13cd93e7b2be7ce9fa8fe947d869eb6
[2024-05-15 10:54:01.852 +02:00] [INF] [68] Jellyfin.Plugin.PlaybackReporting.Data.PlaybackTracker: PlaybackTracker : Adding Start Event : 05/15/2024 10:54:01
[2024-05-15 10:54:01.852 +02:00] [INF] [68] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: Creating StartPlaybackTimer Task
[2024-05-15 10:54:01.852 +02:00] [INF] [151] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: StartPlaybackTimer : Entered
[2024-05-15 10:54:02.620 +02:00] [INF] [68] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: Processing playback tracker : "ce8b2bdb6568be55132f9d985f84613be0fd30eb-7b5b968bd88d476b9ae8781992de8ece-f13cd93e7b2be7ce9fa8fe947d869eb6"
[2024-05-15 10:54:21.852 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: session.RemoteEndPoint : "Restricted"
[2024-05-15 10:54:21.852 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: StartPlaybackTimer : event_playing_id     = "f13cd93e7b2be7ce9fa8fe947d869eb6"
[2024-05-15 10:54:21.852 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: StartPlaybackTimer : event_user_id        = "7b5b968bd88d476b9ae8781992de8ece"
[2024-05-15 10:54:21.852 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: StartPlaybackTimer : event_user_id_int    = 1
[2024-05-15 10:54:21.853 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: StartPlaybackTimer : session_playing_id   = "f13cd93e7b2be7ce9fa8fe947d869eb6"
[2024-05-15 10:54:21.853 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: StartPlaybackTimer : session_user_id      = "7b5b968bd88d476b9ae8781992de8ece"
[2024-05-15 10:54:21.853 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: StartPlaybackTimer : play_method          = "DirectPlay"
[2024-05-15 10:54:21.853 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: StartPlaybackTimer : e.ClientName         = "Android TV"
[2024-05-15 10:54:21.853 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: StartPlaybackTimer : e.DeviceName         = "Restricted"
[2024-05-15 10:54:21.853 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: StartPlaybackTimer : ItemName             = "dolby-vision-amaze-(dolby-vision).AV1.Profile10.0"
[2024-05-15 10:54:21.853 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: StartPlaybackTimer : ItemId               = "f13cd93e7b2be7ce9fa8fe947d869eb6"
[2024-05-15 10:54:21.853 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: StartPlaybackTimer : ItemType             = "Movie"
[2024-05-15 10:54:21.853 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: StartPlaybackTimer : All matches, playback registered
[2024-05-15 10:54:21.853 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: Playback tracker found, adding playback info : "ce8b2bdb6568be55132f9d985f84613be0fd30eb-7b5b968bd88d476b9ae8781992de8ece-f13cd93e7b2be7ce9fa8fe947d869eb6"
[2024-05-15 10:54:21.853 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: Saving playback tracking activity in DB
[2024-05-15 10:54:21.867 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: StartPlaybackTimer : Exited
[2024-05-15 10:54:30.855 +02:00] [INF] [42] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: Processing playback tracker : "ce8b2bdb6568be55132f9d985f84613be0fd30eb-7b5b968bd88d476b9ae8781992de8ece-f13cd93e7b2be7ce9fa8fe947d869eb6"
[2024-05-15 10:54:51.097 +02:00] [INF] [144] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: Processing playback tracker : "ce8b2bdb6568be55132f9d985f84613be0fd30eb-7b5b968bd88d476b9ae8781992de8ece-f13cd93e7b2be7ce9fa8fe947d869eb6"
[2024-05-15 10:55:11.105 +02:00] [INF] [151] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: Processing playback tracker : "ce8b2bdb6568be55132f9d985f84613be0fd30eb-7b5b968bd88d476b9ae8781992de8ece-f13cd93e7b2be7ce9fa8fe947d869eb6"
[2024-05-15 10:55:21.256 +02:00] [INF] [144] Emby.Server.Implementations.Session.SessionManager: Playback stopped reported by app "Android TV" "0.16.10" playing "dolby-vision-amaze-(dolby-vision).AV1.Profile10.0". Stopped at "55729" ms
[2024-05-15 10:55:21.267 +02:00] [INF] [144] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: Playback stop tracker found, processing stop : "ce8b2bdb6568be55132f9d985f84613be0fd30eb-7b5b968bd88d476b9ae8781992de8ece-f13cd93e7b2be7ce9fa8fe947d869eb6"
[2024-05-15 10:55:21.267 +02:00] [INF] [144] Jellyfin.Plugin.PlaybackReporting.Data.PlaybackTracker: PlaybackTracker : Adding Stop Event : 05/15/2024 10:55:21
[2024-05-15 10:55:21.267 +02:00] [INF] [144] Jellyfin.Plugin.PlaybackReporting.EventMonitorEntryPoint: Saving playback tracking activity in DB

Application version

0.16.10

Where did you install the app from?

Google Play

Device information

TCL 55C825 (Latest Update : V8-T615T03-LF1V999.000872 - Version Test_31)

Android version

Android TV 11 with Google TV

Jellyfin server version

10.9.1

gnattu commented 1 month ago

Are you creating those files by yourself? I'm asking because Dolby's reference implementation, the Dolby Encoding Engine has not being updated to output Profile 10 videos yet, and all current tools we have are more or less the unofficial tools and may not do everything correctly, and one of your TV "seems to work" might be a pure luck. I want to wait till at least Dolby is providing reference implementations themselves to look at this because we don't even know if the videos produced are valid or not.