jellyfin / Swiftfin

Native Jellyfin Client for iOS and tvOS
Mozilla Public License 2.0
2.5k stars 272 forks source link

Flickering black screen every two seconds #916

Open eliluong opened 10 months ago

eliluong commented 10 months ago

Describe the bug

I have a movie file with the following information (from MediaInfo). It is direct playing to AppleTV. The issue I am having is the TV is going to a black screen approximately every two seconds. There is a scene where it's just a bit of white text on a black background, and there is no flickering there. But then when it switches to a full image video it starts again. It's not a black image, because there is a visual difference in the black when it's a black image versus a screen that is completely off. But in any case, I am able to watch other files fine, and it is this one that is giving trouble. Also, it plays fine in the browser (which requires transcoding). I do not see any logs in Jellyfin server to show. Any thoughts on how to troubleshoot? Thanks.

Video
ID                                       : 1
Format                                   : HEVC
Format/Info                              : High Efficiency Video Coding
Format profile                           : Main 10@L5@Main
Codec ID                                 : V_MPEGH/ISO/HEVC
Duration                                 : 2h 15mn
Bit rate                                 : 14.2 Mbps
Width                                    : 3 840 pixels
Height                                   : 2 160 pixels
Display aspect ratio                     : 16:9
Frame rate mode                          : Constant
Frame rate                               : 24.000 fps
Color space                              : YUV
Chroma subsampling                       : 4:2:0
Bit depth                                : 10 bits
Bits/(Pixel*Frame)                       : 0.071
Stream size                              : 13.5 GiB (94%)
Default                                  : Yes
Forced                                   : No
Color range                              : Limited
Color primaries                          : BT.2020
Matrix coefficients                      : BT.2020 non-constant

Application version

1.0.1(70)

Where did you install the app from?

App Store

Device information

A2843

OS version

tvOS 17.1

Jellyfin server version

10.8.10

maxjohn0 commented 7 months ago

I am experiencing exactly the same issue with two MKV files. This only happens when trying to play the files with Swiftfin (both on tvOS as well as iOS), they play fine with the official Jellyfin Media Player on Mac (using direct play).

Interestingly, after just remuxing the files with ffmpeg:

ffmpeg -i Movie_original.mkv -map 0 -c copy Movie.mkv

the flickering in Swiftfin is gone.

MediaInfo before remuxing:

General
Complete name                            : Movie_original.mkv
Format                                   : Matroska
Format version                           : Version 4
File size                                : 10.8 GiB
Duration                                 : 1 h 39 min
Overall bit rate                         : 15.4 Mb/s
Frame rate                               : 25.000 FPS
Writing application                      : mkvmerge v70.0.0 ('Caught A Lite Sneeze') 64-bit
Writing library                          : libebml v1.4.2 + libmatroska v1.6.4

Video
ID                                       : 1
Format                                   : HEVC
Format/Info                              : High Efficiency Video Coding
Format profile                           : Main 10@L5@Main
HDR format                               : SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible
Codec ID                                 : V_MPEGH/ISO/HEVC
Duration                                 : 1 h 39 min
Bit rate                                 : 14.8 Mb/s
Width                                    : 3 840 pixels
Height                                   : 2 160 pixels
Display aspect ratio                     : 16:9
Frame rate mode                          : Constant
Frame rate                               : 25.000 FPS
Color space                              : YUV
Chroma subsampling                       : 4:2:0
Bit depth                                : 10 bits
Bits/(Pixel*Frame)                       : 0.071
Stream size                              : 10.3 GiB (96%)
Language                                 : English (US)
Default                                  : Yes
Forced                                   : No
Color range                              : Limited
Color primaries                          : BT.2020
Transfer characteristics                 : PQ
Matrix coefficients                      : BT.2020 non-constant
Mastering display color primaries        : Display P3
Mastering display luminance              : min: 0.0001 cd/m2, max: 1000 cd/m2
Maximum Content Light Level              : 999 cd/m2
Maximum Frame-Average Light Level        : 745 cd/m2

Audio
ID                                       : 2
Format                                   : E-AC-3
Format/Info                              : Enhanced AC-3
Commercial name                          : Dolby Digital Plus
Codec ID                                 : A_EAC3
Duration                                 : 1 h 39 min
Bit rate mode                            : Constant
Bit rate                                 : 640 kb/s
Channel(s)                               : 6 channels
Channel layout                           : L R C LFE Ls Rs
Sampling rate                            : 48.0 kHz
Frame rate                               : 31.250 FPS (1536 SPF)
Compression mode                         : Lossy
Stream size                              : 457 MiB (4%)
Title                                    : British
Language                                 : English (GB)
Service kind                             : Complete Main
Default                                  : Yes
Forced                                   : No

MediaInfo after remuxing:

Complete name                            : Movie.mkv
Format                                   : Matroska
Format version                           : Version 4
File size                                : 10.8 GiB
Duration                                 : 1 h 39 min
Overall bit rate                         : 15.4 Mb/s
Frame rate                               : 25.000 FPS
Writing application                      : Lavf60.20.100
Writing library                          : Lavf60.20.100
ErrorDetectionType                       : Per level 1

Video
ID                                       : 1
Format                                   : HEVC
Format/Info                              : High Efficiency Video Coding
Format profile                           : Main 10@L5@Main
HDR format                               : SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible
Codec ID                                 : V_MPEGH/ISO/HEVC
Duration                                 : 1 h 39 min
Bit rate                                 : 14.8 Mb/s
Width                                    : 3 840 pixels
Height                                   : 2 160 pixels
Display aspect ratio                     : 16:9
Frame rate mode                          : Constant
Frame rate                               : 25.000 FPS
Color space                              : YUV
Chroma subsampling                       : 4:2:0
Bit depth                                : 10 bits
Bits/(Pixel*Frame)                       : 0.071
Stream size                              : 10.3 GiB (96%)
Language                                 : English
Default                                  : Yes
Forced                                   : No
Color range                              : Limited
Color primaries                          : BT.2020
Transfer characteristics                 : PQ
Matrix coefficients                      : BT.2020 non-constant
Mastering display color primaries        : Display P3
Mastering display luminance              : min: 0.0001 cd/m2, max: 1000 cd/m2
Maximum Content Light Level              : 999 cd/m2
Maximum Frame-Average Light Level        : 745 cd/m2

Audio
ID                                       : 2
Format                                   : E-AC-3
Format/Info                              : Enhanced AC-3
Commercial name                          : Dolby Digital Plus
Codec ID                                 : A_EAC3
Duration                                 : 1 h 39 min
Bit rate mode                            : Constant
Bit rate                                 : 640 kb/s
Channel(s)                               : 6 channels
Channel layout                           : L R C LFE Ls Rs
Sampling rate                            : 48.0 kHz
Frame rate                               : 31.250 FPS (1536 SPF)
Bit depth                                : 32 bits
Compression mode                         : Lossy
Stream size                              : 457 MiB (4%)
Title                                    : British
Language                                 : English
Service kind                             : Complete Main
Default                                  : Yes
Forced                                   : No

Application version

Where did you install the app from?

App Store

Device information

OS version

Jellyfin server version

10.8.13

sschmith commented 3 weeks ago

This also happens to me with 4k videos on tvOS.

arvet333 commented 2 weeks ago

It also happens to me, not only on tvOS but on iOS.