Jellyfin Forum
SOLVED: Transcoding: When it's triggered and when it's not - Printable Version

+- Jellyfin Forum (https://forum.jellyfin.org)
+-- Forum: Support (https://forum.jellyfin.org/f-support)
+--- Forum: Troubleshooting (https://forum.jellyfin.org/f-troubleshooting)
+--- Thread: SOLVED: Transcoding: When it's triggered and when it's not (/t-solved-transcoding-when-it-s-triggered-and-when-it-s-not)



Transcoding: When it's triggered and when it's not - pguidi - 2023-08-27

Hi Jellyfin users and developers.
I'm having a problem with the Jellyfin media server.
I installed the application as a docker container on a low power x86_64 machine.
It accesses the media library through a CIFS mount point, and everything works fine.
As i said, the server is a low power cpu board that does not perform perfectly with transcoding. It has VAAPI and i configured jellyfin to use it but it's still too slow, and the TV consumes more frames that ffmpeg can produce.
I was aware of this, and so i wrote a bash script that i launch every now and again on my laptop (with nvidia card) to convert all the new elements of the library to an h264 stream, 1920x1080, SAR 1:1 and DAR 16:9 and blablabla, (i will attach the logs). This should prevent Jellyfin from invoking ffmpeg for a transcoding, instead it should invoke it to remap, transcode audio (ac3->aac, light task) and create the .m3u8 file

So all the media files contained in the library are of the same type, for video and audio. However, when i start playing the media A, the transcoding does not kick in (as i expect) and the video is smooth on the TV, because the stream mapping is a v:copy, but when i play media B, the transcoding kicks in and the ffmpeg process goes at 0.3x speed, making the TV lagging and interrupting continuosly.

It uses transcoding with some media and not with others, i'm trying to understand the difference, and i would like to know the criteria used by Jellyfin when deciding it.

ffprobe Media A (working):
Code:
ffprobe Jerry\ \&\ Marge\ Go\ Large\ \(2022\)\ WEBDL-1080p.mkv
ffprobe version n6.0 Copyright (c) 2007-2023 the FFmpeg developers
  built with gcc 13.1.1 (GCC) 20230429
  configuration: --prefix=/usr --disable-debug --disable-static --disable-stripping --enable-amf --enable-avisynth --enable-cuda-llvm --enable-lto --enable-fontconfig --enable-gmp --enable-gnutls --enable-gpl --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libbs2b --enable-libdav1d --enable-libdrm --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-libiec61883 --enable-libjack --enable-libjxl --enable-libmfx --enable-libmodplug --enable-libmp3lame --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librav1e --enable-librsvg --enable-libsoxr --enable-libspeex --enable-libsrt --enable-libssh --enable-libsvtav1 --enable-libtheora --enable-libv4l2 --enable-libvidstab --enable-libvmaf --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxcb --enable-libxml2 --enable-libxvid --enable-libzimg --enable-nvdec --enable-nvenc --enable-opencl --enable-opengl --enable-shared --enable-version3 --enable-vulkan
  libavutil      58.  2.100 / 58.  2.100
  libavcodec    60.  3.100 / 60.  3.100
  libavformat    60.  3.100 / 60.  3.100
  libavdevice    60.  1.100 / 60.  1.100
  libavfilter    9.  3.100 /  9.  3.100
  libswscale      7.  1.100 /  7.  1.100
  libswresample  4. 10.100 /  4. 10.100
  libpostproc    57.  1.100 / 57.  1.100
Input #0, matroska,webm, from 'Jerry & Marge Go Large (2022) WEBDL-1080p.mkv':
  Metadata:
    ENCODER        : Lavf60.3.100
  Duration: 01:36:12.51, start: -0.005000, bitrate: 2828 kb/s
  Stream #0:0(eng): Video: h264 (Main), yuv420p(tv, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9], 23.98 fps, 23.98 tbr, 1k tbn (default)
    Metadata:
      title          : 1080p
      BPS            : 9998478
      NUMBER_OF_FRAMES: 138401
      NUMBER_OF_BYTES : 7214495779
      _STATISTICS_WRITING_APP: mkvmerge v70.0.0 ('Caught A Lite Sneeze') 64-bit
      _STATISTICS_WRITING_DATE_UTC: 2022-09-21 18:02:00
      _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
      ENCODER        : Lavc60.3.100 h264_nvenc
      DURATION        : 01:36:12.475000000
  Stream #0:1(ita): Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s (default)
    Metadata:
      title          : E-AC3
      BPS            : 224000
      NUMBER_OF_FRAMES: 180391
      NUMBER_OF_BYTES : 161630336
      _STATISTICS_WRITING_APP: mkvmerge v70.0.0 ('Caught A Lite Sneeze') 64-bit
      _STATISTICS_WRITING_DATE_UTC: 2022-09-21 18:02:00
      _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
      ENCODER        : Lavc60.3.100 ac3
      DURATION        : 01:36:12.512000000
  Stream #0:2(ita): Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s (default)
    Metadata:
      title          : AC3
      BPS            : 224000
      NUMBER_OF_FRAMES: 180391
      NUMBER_OF_BYTES : 161630336
      _STATISTICS_WRITING_APP: mkvmerge v70.0.0 ('Caught A Lite Sneeze') 64-bit
      _STATISTICS_WRITING_DATE_UTC: 2022-09-21 18:02:00
      _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
      ENCODER        : Lavc60.3.100 ac3
      DURATION        : 01:36:12.512000000
  Stream #0:3(eng): Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s (default)
    Metadata:
      title          : E-AC3
      BPS            : 640000
      NUMBER_OF_FRAMES: 180391
      NUMBER_OF_BYTES : 461800960
      _STATISTICS_WRITING_APP: mkvmerge v70.0.0 ('Caught A Lite Sneeze') 64-bit
      _STATISTICS_WRITING_DATE_UTC: 2022-09-21 18:02:00
      _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
      ENCODER        : Lavc60.3.100 ac3
      DURATION        : 01:36:12.512000000
  Stream #0:4(eng): Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s (default)
    Metadata:
      title          : AC3
      BPS            : 640000
      NUMBER_OF_FRAMES: 180391
      NUMBER_OF_BYTES : 461800960
      _STATISTICS_WRITING_APP: mkvmerge v70.0.0 ('Caught A Lite Sneeze') 64-bit
      _STATISTICS_WRITING_DATE_UTC: 2022-09-21 18:02:00
      _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
      ENCODER        : Lavc60.3.100 ac3
      DURATION        : 01:36:12.512000000
  Stream #0:5(eng): Subtitle: ass
    Metadata:
      title          : Non Udenti
      BPS            : 77
      NUMBER_OF_FRAMES: 1610
      NUMBER_OF_BYTES : 52375
      _STATISTICS_WRITING_APP: mkvmerge v70.0.0 ('Caught A Lite Sneeze') 64-bit
      _STATISTICS_WRITING_DATE_UTC: 2022-09-21 18:02:00
      _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
      ENCODER        : Lavc60.3.100 ssa
      DURATION        : 01:31:09.469000000

ffprobe Media B (lagging, conversion kicks in):
Code:
ffprobe Guardians\ of\ the\ Galaxy\ Vol.\ 3\ \(2023\)\ Bluray-1080p.mkv
ffprobe version n6.0 Copyright (c) 2007-2023 the FFmpeg developers
  built with gcc 13.1.1 (GCC) 20230429
  configuration: --prefix=/usr --disable-debug --disable-static --disable-stripping --enable-amf --enable-avisynth --enable-cuda-llvm --enable-lto --enable-fontconfig --enable-gmp --enable-gnutls --enable-gpl --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libbs2b --enable-libdav1d --enable-libdrm --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-libiec61883 --enable-libjack --enable-libjxl --enable-libmfx --enable-libmodplug --enable-libmp3lame --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librav1e --enable-librsvg --enable-libsoxr --enable-libspeex --enable-libsrt --enable-libssh --enable-libsvtav1 --enable-libtheora --enable-libv4l2 --enable-libvidstab --enable-libvmaf --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxcb --enable-libxml2 --enable-libxvid --enable-libzimg --enable-nvdec --enable-nvenc --enable-opencl --enable-opengl --enable-shared --enable-version3 --enable-vulkan
  libavutil      58.  2.100 / 58.  2.100
  libavcodec    60.  3.100 / 60.  3.100
  libavformat    60.  3.100 / 60.  3.100
  libavdevice    60.  1.100 / 60.  1.100
  libavfilter    9.  3.100 /  9.  3.100
  libswscale      7.  1.100 /  7.  1.100
  libswresample  4. 10.100 /  4. 10.100
  libpostproc    57.  1.100 / 57.  1.100
[matroska,webm @ 0x55d48259f700] Could not find codec parameters for stream 4 (Subtitle: hdmv_pgs_subtitle (pgssub)): unspecified size
Consider increasing the value for the 'analyzeduration' (0) and 'probesize' (5000000) options
[matroska,webm @ 0x55d48259f700] Could not find codec parameters for stream 5 (Subtitle: hdmv_pgs_subtitle (pgssub)): unspecified size
Consider increasing the value for the 'analyzeduration' (0) and 'probesize' (5000000) options
[matroska,webm @ 0x55d48259f700] Could not find codec parameters for stream 6 (Subtitle: hdmv_pgs_subtitle (pgssub)): unspecified size
Consider increasing the value for the 'analyzeduration' (0) and 'probesize' (5000000) options
Input #0, matroska,webm, from 'Guardians of the Galaxy Vol. 3 (2023) Bluray-1080p.mkv':
  Metadata:
    title          : Guardiani.Della.Galassia.Vol.3.2023.IMAX.iTA.ENG.AC3.SUB.iTA.ENG.BluRay.HEVC.1080p.x265.jeddak-MIRCrew
    ENCODER        : Lavf60.3.100
  Duration: 02:30:02.34, start: 0.000000, bitrate: 2515 kb/s
  Stream #0:0: Video: h264 (Main), yuv420p(tv, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9], 23.98 fps, 23.98 tbr, 1k tbn (default)
    Metadata:
      title          : ...::: jeddak MIRCrew :::...
      ENCODER        : Lavc60.3.100 h264_nvenc
      DURATION        : 02:30:02.331000000
  Stream #0:1(ita): Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s (default)
    Metadata:
      title          : iTA AC3 5.1
      ENCODER        : Lavc60.3.100 ac3
      DURATION        : 02:30:02.341000000
  Stream #0:2(eng): Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s
    Metadata:
      title          : ENG AC3 5.1
      ENCODER        : Lavc60.3.100 ac3
      DURATION        : 02:30:02.341000000
  Stream #0:3(ita): Subtitle: subrip (forced)
    Metadata:
      title          : iTA FORCED - SRT
      DURATION        : 02:29:50.370000000
  Stream #0:4(ita): Subtitle: hdmv_pgs_subtitle (default) (forced)
    Metadata:
      title          : iTA FORCED - PGS
      DURATION        : 02:29:50.371000000
  Stream #0:5(ita): Subtitle: hdmv_pgs_subtitle
    Metadata:
      title          : iTA REGULAR - PGS
      DURATION        : 02:29:50.371000000
  Stream #0:6(eng): Subtitle: hdmv_pgs_subtitle
    Metadata:
      title          : ENG NON UDENTI - PGS
      DURATION        : 02:30:00.381000000

Jellyfin ffmpeg log for media A:
Code:
/videos/365b2a2e-efc0-b4a9-f9a6-46cdbfdd1758/hls1/main/0.ts

{"Protocol":0,"Id":"365b2a2eefc0b4a9f9a646cdbfdd1758","Path":"/media/Movies/Jerry \u0026 Marge Go Large (2022)/Jerry \u0026 Marge Go Large (2022) WEBDL-1080p.mkv","EncoderPath":null,"EncoderProtocol":null,"Type":0,"Container":"mkv,webm","Size":2040646272,"Name":"Jerry \u0026 Marge Go Large (2022) WEBDL-1080p","IsRemote":false,"ETag":"3d9c1f7aad834167719913610d815557","RunTimeTicks":57725120512,"ReadAtNativeFramerate":false,"IgnoreDts":false,"IgnoreIndex":false,"GenPtsInput":false,"SupportsTranscoding":true,"SupportsDirectStream":true,"SupportsDirectPlay":true,"IsInfiniteStream":false,"RequiresOpening":false,"OpenToken":null,"RequiresClosing":false,"LiveStreamId":null,"BufferMs":null,"RequiresLooping":false,"SupportsProbing":true,"VideoType":0,"IsoType":null,"Video3DFormat":null,"MediaStreams":[{"Codec":"h264","CodecTag":null,"Language":"eng","ColorRange":null,"ColorSpace":"bt709","ColorTransfer":"bt709","ColorPrimaries":"bt709","DvVersionMajor":null,"DvVersionMinor":null,"DvProfile":null,"DvLevel":null,"RpuPresentFlag":null,"ElPresentFlag":null,"BlPresentFlag":null,"DvBlSignalCompatibilityId":null,"Comment":null,"TimeBase":"1/1000","CodecTimeBase":null,"Title":"1080p","VideoRange":"SDR","VideoRangeType":"SDR","VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"1080p - H264 - SDR","NalLengthSize":"4","IsInterlaced":false,"IsAVC":true,"ChannelLayout":null,"BitRate":2828087,"BitDepth":8,"RefFrames":1,"PacketLength":null,"Channels":null,"SampleRate":null,"IsDefault":true,"IsForced":false,"Height":1080,"Width":1920,"AverageFrameRate":23.976025,"RealFrameRate":23.976025,"Profile":"Main","Type":1,"AspectRatio":"16:9","Index":0,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":"yuv420p","Level":40,"IsAnamorphic":null},{"Codec":"ac3","CodecTag":null,"Language":"ita","ColorRange":null,"ColorSpace":null,"ColorTransfer":null,"ColorPrimaries":null,"DvVersionMajor":null,"DvVersionMinor":null,"DvProfile":null,"DvLevel":null,"RpuPresentFlag":null,"ElPresentFlag":null,"BlPresentFlag":null,"DvBlSignalCompatibilityId":null,"Comment":null,"TimeBase":"1/1000","CodecTimeBase":null,"Title":"E-AC3","VideoRange":null,"VideoRangeType":null,"VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"E-AC3 - Italian - Dolby Digital - Stereo - Default","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":"stereo","BitRate":192000,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":2,"SampleRate":48000,"IsDefault":true,"IsForced":false,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":0,"AspectRatio":null,"Index":1,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null},{"Codec":"ac3","CodecTag":null,"Language":"ita","ColorRange":null,"ColorSpace":null,"ColorTransfer":null,"ColorPrimaries":null,"DvVersionMajor":null,"DvVersionMinor":null,"DvProfile":null,"DvLevel":null,"RpuPresentFlag":null,"ElPresentFlag":null,"BlPresentFlag":null,"DvBlSignalCompatibilityId":null,"Comment":null,"TimeBase":"1/1000","CodecTimeBase":null,"Title":"AC3","VideoRange":null,"VideoRangeType":null,"VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"AC3 - Italian - Dolby Digital - Stereo - Default","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":"stereo","BitRate":192000,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":2,"SampleRate":48000,"IsDefault":true,"IsForced":false,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":0,"AspectRatio":null,"Index":2,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null},{"Codec":"ac3","CodecTag":null,"Language":"eng","ColorRange":null,"ColorSpace":null,"ColorTransfer":null,"ColorPrimaries":null,"DvVersionMajor":null,"DvVersionMinor":null,"DvProfile":null,"DvLevel":null,"RpuPresentFlag":null,"ElPresentFlag":null,"BlPresentFlag":null,"DvBlSignalCompatibilityId":null,"Comment":null,"TimeBase":"1/1000","CodecTimeBase":null,"Title":"E-AC3","VideoRange":null,"VideoRangeType":null,"VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"E-AC3 - English - Dolby Digital - Stereo - Default","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":"stereo","BitRate":192000,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":2,"SampleRate":48000,"IsDefault":true,"IsForced":false,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":0,"AspectRatio":null,"Index":3,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null},{"Codec":"ac3","CodecTag":null,"Language":"eng","ColorRange":null,"ColorSpace":null,"ColorTransfer":null,"ColorPrimaries":null,"DvVersionMajor":null,"DvVersionMinor":null,"DvProfile":null,"DvLevel":null,"RpuPresentFlag":null,"ElPresentFlag":null,"BlPresentFlag":null,"DvBlSignalCompatibilityId":null,"Comment":null,"TimeBase":"1/1000","CodecTimeBase":null,"Title":"AC3","VideoRange":null,"VideoRangeType":null,"VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"AC3 - English - Dolby Digital - Stereo - Default","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":"stereo","BitRate":192000,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":2,"SampleRate":48000,"IsDefault":true,"IsForced":false,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":0,"AspectRatio":null,"Index":4,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null},{"Codec":"ass","CodecTag":null,"Language":"eng","ColorRange":null,"ColorSpace":null,"ColorTransfer":null,"ColorPrimaries":null,"DvVersionMajor":null,"DvVersionMinor":null,"DvProfile":null,"DvLevel":null,"RpuPresentFlag":null,"ElPresentFlag":null,"BlPresentFlag":null,"DvBlSignalCompatibilityId":null,"Comment":null,"TimeBase":"1/1000","CodecTimeBase":null,"Title":"Non Udenti","VideoRange":null,"VideoRangeType":null,"VideoDoViTitle":null,"LocalizedUndefined":"Undefined","LocalizedDefault":"Default","LocalizedForced":"Forced","LocalizedExternal":"External","DisplayTitle":"Non Udenti - English - ASS","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":null,"BitRate":null,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":null,"SampleRate":null,"IsDefault":false,"IsForced":false,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":2,"AspectRatio":null,"Index":5,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":true,"SupportsExternalStream":true,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null}],"MediaAttachments":[],"Formats":[],"Bitrate":3596087,"Timestamp":null,"RequiredHttpHeaders":{},"TranscodingUrl":null,"TranscodingSubProtocol":null,"TranscodingContainer":null,"AnalyzeDurationMs":null,"DefaultAudioStreamIndex":null,"DefaultSubtitleStreamIndex":null}

/usr/lib/jellyfin-ffmpeg/ffmpeg -analyzeduration 200M -fflags +genpts  -i file:"/media/Movies/Jerry & Marge Go Large (2022)/Jerry & Marge Go Large (2022) WEBDL-1080p.mkv" -map_metadata -1 -map_chapters -1 -threads 0 -map 0:0 -map 0:1 -map -0:s -codec:v:0 copy -bsf:v h264_mp4toannexb -start_at_zero -codec:a:0 libfdk_aac -ac 2 -ab 256000 -copyts -avoid_negative_ts disabled -max_muxing_queue_size 2048 -f hls -max_delay 5000000 -hls_time 6 -hls_segment_type mpegts -start_number 0 -hls_segment_filename "/config/data/transcodes/94fadfe5fe6ccd63702de2702e69749e%d.ts" -hls_playlist_type vod -hls_list_size 0 -y "/config/data/transcodes/94fadfe5fe6ccd63702de2702e69749e.m3u8"


ffmpeg version 5.1.3-Jellyfin Copyright (c) 2000-2022 the FFmpeg developers
  built with gcc 11 (Ubuntu 11.4.0-1ubuntu1~22.04)
  configuration: --prefix=/usr/lib/jellyfin-ffmpeg --target-os=linux --extra-libs=-lfftw3f --extra-version=Jellyfin --disable-doc --disable-ffplay --disable-ptx-compression --disable-static --disable-libxcb --disable-sdl2 --disable-xlib --enable-lto --enable-gpl --enable-version3 --enable-shared --enable-gmp --enable-gnutls --enable-chromaprint --enable-libdrm --enable-libass --enable-libfreetype --enable-libfribidi --enable-libfontconfig --enable-libbluray --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libopenmpt --enable-libdav1d --enable-libwebp --enable-libvpx --enable-libx264 --enable-libx265 --enable-libzvbi --enable-libzimg --enable-libfdk-aac --arch=amd64 --enable-libsvtav1 --enable-libshaderc --enable-libplacebo --enable-vulkan --enable-opencl --enable-vaapi --enable-amf --enable-libmfx --enable-ffnvcodec --enable-cuda --enable-cuda-llvm --enable-cuvid --enable-nvdec --enable-nvenc
  libavutil      57. 28.100 / 57. 28.100
  libavcodec    59. 37.100 / 59. 37.100
  libavformat    59. 27.100 / 59. 27.100
  libavdevice    59.  7.100 / 59.  7.100
  libavfilter    8. 44.100 /  8. 44.100
  libswscale      6.  7.100 /  6.  7.100
  libswresample  4.  7.100 /  4.  7.100
  libpostproc    56.  6.100 / 56.  6.100
Input #0, matroska,webm, from 'file:/media/Movies/Jerry & Marge Go Large (2022)/Jerry & Marge Go Large (2022) WEBDL-1080p.mkv':
  Metadata:
    ENCODER        : Lavf60.3.100
  Duration: 01:36:12.51, start: -0.005000, bitrate: 2828 kb/s
  Stream #0:0(eng): Video: h264 (Main), yuv420p(tv, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9], 23.98 fps, 23.98 tbr, 1k tbn (default)
    Metadata:
      title          : 1080p
      BPS            : 9998478
      NUMBER_OF_FRAMES: 138401
      NUMBER_OF_BYTES : 7214495779
      _STATISTICS_WRITING_APP: mkvmerge v70.0.0 ('Caught A Lite Sneeze') 64-bit
      _STATISTICS_WRITING_DATE_UTC: 2022-09-21 18:02:00
      _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
      ENCODER        : Lavc60.3.100 h264_nvenc
      DURATION        : 01:36:12.475000000
  Stream #0:1(ita): Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s (default)
    Metadata:
      title          : E-AC3
      BPS            : 224000
      NUMBER_OF_FRAMES: 180391
      NUMBER_OF_BYTES : 161630336
      _STATISTICS_WRITING_APP: mkvmerge v70.0.0 ('Caught A Lite Sneeze') 64-bit
      _STATISTICS_WRITING_DATE_UTC: 2022-09-21 18:02:00
      _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
      ENCODER        : Lavc60.3.100 ac3
      DURATION        : 01:36:12.512000000
  Stream #0:2(ita): Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s (default)
    Metadata:
      title          : AC3
      BPS            : 224000
      NUMBER_OF_FRAMES: 180391
      NUMBER_OF_BYTES : 161630336
      _STATISTICS_WRITING_APP: mkvmerge v70.0.0 ('Caught A Lite Sneeze') 64-bit
      _STATISTICS_WRITING_DATE_UTC: 2022-09-21 18:02:00
      _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
      ENCODER        : Lavc60.3.100 ac3
      DURATION        : 01:36:12.512000000
  Stream #0:3(eng): Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s (default)
    Metadata:
      title          : E-AC3
      BPS            : 640000
      NUMBER_OF_FRAMES: 180391
      NUMBER_OF_BYTES : 461800960
      _STATISTICS_WRITING_APP: mkvmerge v70.0.0 ('Caught A Lite Sneeze') 64-bit
      _STATISTICS_WRITING_DATE_UTC: 2022-09-21 18:02:00
      _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
      ENCODER        : Lavc60.3.100 ac3
      DURATION        : 01:36:12.512000000
  Stream #0:4(eng): Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s (default)
    Metadata:
      title          : AC3
      BPS            : 640000
      NUMBER_OF_FRAMES: 180391
      NUMBER_OF_BYTES : 461800960
      _STATISTICS_WRITING_APP: mkvmerge v70.0.0 ('Caught A Lite Sneeze') 64-bit
      _STATISTICS_WRITING_DATE_UTC: 2022-09-21 18:02:00
      _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
      ENCODER        : Lavc60.3.100 ac3
      DURATION        : 01:36:12.512000000
  Stream #0:5(eng): Subtitle: ass
    Metadata:
      title          : Non Udenti
      BPS            : 77
      NUMBER_OF_FRAMES: 1610
      NUMBER_OF_BYTES : 52375
      _STATISTICS_WRITING_APP: mkvmerge v70.0.0 ('Caught A Lite Sneeze') 64-bit
      _STATISTICS_WRITING_DATE_UTC: 2022-09-21 18:02:00
      _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
      ENCODER        : Lavc60.3.100 ssa
      DURATION        : 01:31:09.469000000
Stream mapping:
  Stream #0:0 -> #0:0 (copy)
  Stream #0:1 -> #0:1 (ac3 (native) -> aac (libfdk_aac))
Press [q] to stop, [?] for help
Output #0, hls, to '/config/data/transcodes/94fadfe5fe6ccd63702de2702e69749e.m3u8':
  Metadata:
    encoder        : Lavf59.27.100
  Stream #0:0: Video: h264 (Main), yuv420p(tv, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9], q=2-31, 23.98 fps, 23.98 tbr, 90k tbn (default)
  Stream #0:1: Audio: aac, 48000 Hz, stereo, s16, 256 kb/s (default)
    Metadata:
      encoder        : Lavc59.37.100 libfdk_aac
frame=    1 fps=0.0 q=-1.0 size=N/A time=-00:00:00.00 bitrate=N/A speed=N/A   
frame=  178 fps=0.0 q=-1.0 size=N/A time=00:00:07.37 bitrate=N/A speed=14.7x   
[hls @ 0x55a367c95a40] Opening '/config/data/transcodes/94fadfe5fe6ccd63702de2702e69749e0.ts' for writing
frame=  354 fps=354 q=-1.0 size=N/A time=00:00:14.71 bitrate=N/A speed=14.7x   
[hls @ 0x55a367c95a40] Opening '/config/data/transcodes/94fadfe5fe6ccd63702de2702e69749e1.ts' for writing
frame=  527 fps=351 q=-1.0 size=N/A time=00:00:21.93 bitrate=N/A speed=14.6x   
frame=  712 fps=355 q=-1.0 size=N/A time=00:00:29.65 bitrate=N/A speed=14.8x   
[hls @ 0x55a367c95a40] Opening '/config/data/transcodes/94fadfe5fe6ccd63702de2702e69749e2.ts' for writing
frame=  891 fps=356 q=-1.0 size=N/A time=00:00:37.11 bitrate=N/A speed=14.8x   

[q] command received. Exiting.

[hls @ 0x55a367c95a40] Opening '/config/data/transcodes/94fadfe5fe6ccd63702de2702e69749e3.ts' for writing
frame=  906 fps=355 q=-1.0 Lsize=N/A time=00:00:37.77 bitrate=N/A speed=14.8x   
video:8202kB audio:1182kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown

Jellyfin ffmpeg log for media B:
Code:
/videos/98d1fb02-5235-0f6a-acba-b5f9a80d57d1/hls1/main/0.ts

{"Protocol":0,"Id":"98d1fb0252350f6aacbab5f9a80d57d1","Path":"/media/Movies/Guardians of the Galaxy Vol. 3 (2023)/Guardians of the Galaxy Vol. 3 (2023) Bluray-1080p.mkv","EncoderPath":null,"EncoderProtocol":null,"Type":0,"Container":"mkv,webm","Size":2831031909,"Name":"Guardians of the Galaxy Vol. 3 (2023) Bluray-1080p","IsRemote":false,"ETag":"b0e04836847a5e82260440ecefcfed51","RunTimeTicks":90023410000,"ReadAtNativeFramerate":false,"IgnoreDts":false,"IgnoreIndex":false,"GenPtsInput":false,"SupportsTranscoding":true,"SupportsDirectStream":true,"SupportsDirectPlay":true,"IsInfiniteStream":false,"RequiresOpening":false,"OpenToken":null,"RequiresClosing":false,"LiveStreamId":null,"BufferMs":null,"RequiresLooping":false,"SupportsProbing":true,"VideoType":0,"IsoType":null,"Video3DFormat":null,"MediaStreams":[{"Codec":"h264","CodecTag":null,"Language":null,"ColorRange":null,"ColorSpace":"bt709","ColorTransfer":"bt709","ColorPrimaries":"bt709","DvVersionMajor":null,"DvVersionMinor":null,"DvProfile":null,"DvLevel":null,"RpuPresentFlag":null,"ElPresentFlag":null,"BlPresentFlag":null,"DvBlSignalCompatibilityId":null,"Comment":null,"TimeBase":"1/1000","CodecTimeBase":null,"Title":"...::: jeddak MIRCrew :::...","VideoRange":"SDR","VideoRangeType":"SDR","VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"...::: jeddak MIRCrew :::... - 1080p - H264 - SDR","NalLengthSize":"4","IsInterlaced":false,"IsAVC":true,"ChannelLayout":null,"BitRate":2515818,"BitDepth":8,"RefFrames":1,"PacketLength":null,"Channels":null,"SampleRate":null,"IsDefault":true,"IsForced":false,"Height":1080,"Width":1920,"AverageFrameRate":23.976025,"RealFrameRate":23.976025,"Profile":"Main","Type":1,"AspectRatio":"16:9","Index":0,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":"yuv420p","Level":40,"IsAnamorphic":null},{"Codec":"ac3","CodecTag":null,"Language":"ita","ColorRange":null,"ColorSpace":null,"ColorTransfer":null,"ColorPrimaries":null,"DvVersionMajor":null,"DvVersionMinor":null,"DvProfile":null,"DvLevel":null,"RpuPresentFlag":null,"ElPresentFlag":null,"BlPresentFlag":null,"DvBlSignalCompatibilityId":null,"Comment":null,"TimeBase":"1/1000","CodecTimeBase":null,"Title":"iTA AC3 5.1","VideoRange":null,"VideoRangeType":null,"VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"iTA AC3 5.1 - Italian - Dolby Digital - Stereo - Default","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":"stereo","BitRate":192000,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":2,"SampleRate":48000,"IsDefault":true,"IsForced":false,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":0,"AspectRatio":null,"Index":1,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null},{"Codec":"ac3","CodecTag":null,"Language":"eng","ColorRange":null,"ColorSpace":null,"ColorTransfer":null,"ColorPrimaries":null,"DvVersionMajor":null,"DvVersionMinor":null,"DvProfile":null,"DvLevel":null,"RpuPresentFlag":null,"ElPresentFlag":null,"BlPresentFlag":null,"DvBlSignalCompatibilityId":null,"Comment":null,"TimeBase":"1/1000","CodecTimeBase":null,"Title":"ENG AC3 5.1","VideoRange":null,"VideoRangeType":null,"VideoDoViTitle":null,"LocalizedUndefined":null,"LocalizedDefault":null,"LocalizedForced":null,"LocalizedExternal":null,"DisplayTitle":"ENG AC3 5.1 - English - Dolby Digital - Stereo","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":"stereo","BitRate":192000,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":2,"SampleRate":48000,"IsDefault":false,"IsForced":false,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":0,"AspectRatio":null,"Index":2,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null},{"Codec":"subrip","CodecTag":null,"Language":"ita","ColorRange":null,"ColorSpace":null,"ColorTransfer":null,"ColorPrimaries":null,"DvVersionMajor":null,"DvVersionMinor":null,"DvProfile":null,"DvLevel":null,"RpuPresentFlag":null,"ElPresentFlag":null,"BlPresentFlag":null,"DvBlSignalCompatibilityId":null,"Comment":null,"TimeBase":"1/1000","CodecTimeBase":null,"Title":"iTA FORCED - SRT","VideoRange":null,"VideoRangeType":null,"VideoDoViTitle":null,"LocalizedUndefined":"Undefined","LocalizedDefault":"Default","LocalizedForced":"Forced","LocalizedExternal":"External","DisplayTitle":"iTA FORCED - SRT - Italian - SUBRIP","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":null,"BitRate":null,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":null,"SampleRate":null,"IsDefault":false,"IsForced":true,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":2,"AspectRatio":null,"Index":3,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":true,"SupportsExternalStream":true,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null},{"Codec":"PGSSUB","CodecTag":null,"Language":"ita","ColorRange":null,"ColorSpace":null,"ColorTransfer":null,"ColorPrimaries":null,"DvVersionMajor":null,"DvVersionMinor":null,"DvProfile":null,"DvLevel":null,"RpuPresentFlag":null,"ElPresentFlag":null,"BlPresentFlag":null,"DvBlSignalCompatibilityId":null,"Comment":null,"TimeBase":"1/1000","CodecTimeBase":null,"Title":"iTA FORCED - PGS","VideoRange":null,"VideoRangeType":null,"VideoDoViTitle":null,"LocalizedUndefined":"Undefined","LocalizedDefault":"Default","LocalizedForced":"Forced","LocalizedExternal":"External","DisplayTitle":"iTA FORCED - PGS - Italian - Default - PGSSUB","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":null,"BitRate":null,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":null,"SampleRate":null,"IsDefault":true,"IsForced":true,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":2,"AspectRatio":null,"Index":4,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null},{"Codec":"PGSSUB","CodecTag":null,"Language":"ita","ColorRange":null,"ColorSpace":null,"ColorTransfer":null,"ColorPrimaries":null,"DvVersionMajor":null,"DvVersionMinor":null,"DvProfile":null,"DvLevel":null,"RpuPresentFlag":null,"ElPresentFlag":null,"BlPresentFlag":null,"DvBlSignalCompatibilityId":null,"Comment":null,"TimeBase":"1/1000","CodecTimeBase":null,"Title":"iTA REGULAR - PGS","VideoRange":null,"VideoRangeType":null,"VideoDoViTitle":null,"LocalizedUndefined":"Undefined","LocalizedDefault":"Default","LocalizedForced":"Forced","LocalizedExternal":"External","DisplayTitle":"iTA REGULAR - PGS - Italian - PGSSUB","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":null,"BitRate":null,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":null,"SampleRate":null,"IsDefault":false,"IsForced":false,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":2,"AspectRatio":null,"Index":5,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null},{"Codec":"PGSSUB","CodecTag":null,"Language":"eng","ColorRange":null,"ColorSpace":null,"ColorTransfer":null,"ColorPrimaries":null,"DvVersionMajor":null,"DvVersionMinor":null,"DvProfile":null,"DvLevel":null,"RpuPresentFlag":null,"ElPresentFlag":null,"BlPresentFlag":null,"DvBlSignalCompatibilityId":null,"Comment":null,"TimeBase":"1/1000","CodecTimeBase":null,"Title":"ENG NON UDENTI - PGS","VideoRange":null,"VideoRangeType":null,"VideoDoViTitle":null,"LocalizedUndefined":"Undefined","LocalizedDefault":"Default","LocalizedForced":"Forced","LocalizedExternal":"External","DisplayTitle":"ENG NON UDENTI - PGS - English - PGSSUB","NalLengthSize":null,"IsInterlaced":false,"IsAVC":null,"ChannelLayout":null,"BitRate":null,"BitDepth":null,"RefFrames":null,"PacketLength":null,"Channels":null,"SampleRate":null,"IsDefault":false,"IsForced":false,"Height":null,"Width":null,"AverageFrameRate":null,"RealFrameRate":null,"Profile":null,"Type":2,"AspectRatio":null,"Index":6,"Score":null,"IsExternal":false,"DeliveryMethod":null,"DeliveryUrl":null,"IsExternalUrl":null,"IsTextSubtitleStream":false,"SupportsExternalStream":false,"Path":null,"PixelFormat":null,"Level":0,"IsAnamorphic":null}],"MediaAttachments":[],"Formats":[],"Bitrate":2899818,"Timestamp":null,"RequiredHttpHeaders":{},"TranscodingUrl":null,"TranscodingSubProtocol":null,"TranscodingContainer":null,"AnalyzeDurationMs":null,"DefaultAudioStreamIndex":null,"DefaultSubtitleStreamIndex":null}

/usr/lib/jellyfin-ffmpeg/ffmpeg -analyzeduration 200M -init_hw_device vaapi=va:,driver=i965 -filter_hw_device va -hwaccel vaapi -hwaccel_output_format vaapi -autorotate 0 -canvas_size 1920x1080 -i file:"/media/Movies/Guardians of the Galaxy Vol. 3 (2023)/Guardians of the Galaxy Vol. 3 (2023) Bluray-1080p.mkv" -autoscale 0 -map_metadata -1 -map_chapters -1 -threads 0 -map 0:0 -map 0:1 -map -0:0 -codec:v:0 h264_vaapi -rc_mode CBR -b:v 5031636 -maxrate 5031636 -bufsize 10063272 -profile:v:0 main -force_key_frames:0 "expr:gte(t,0+n_forced*3)" -filter_complex "[0:4]scale=s=1920x1080:flags=fast_bilinear[sub];[0:0]setparams=color_primaries=bt709:color_trc=bt709:colorspace=bt709,scale_vaapi=format=nv12:extra_hw_frames=24,hwdownload,format=nv12[main];[main][sub]overlay=eof_action=pass:shortest=1:repeatlast=0,hwupload_vaapi" -start_at_zero -codec:a:0 libfdk_aac -ac 2 -ab 256000 -copyts -avoid_negative_ts disabled -max_muxing_queue_size 2048 -f hls -max_delay 5000000 -hls_time 3 -hls_segment_type mpegts -start_number 0 -hls_segment_filename "/config/data/transcodes/c7f4ad0c8fc585172fc67eaffd07f3e8%d.ts" -hls_playlist_type vod -hls_list_size 0 -y "/config/data/transcodes/c7f4ad0c8fc585172fc67eaffd07f3e8.m3u8"


ffmpeg version 5.1.3-Jellyfin Copyright (c) 2000-2022 the FFmpeg developers
  built with gcc 11 (Ubuntu 11.4.0-1ubuntu1~22.04)
  configuration: --prefix=/usr/lib/jellyfin-ffmpeg --target-os=linux --extra-libs=-lfftw3f --extra-version=Jellyfin --disable-doc --disable-ffplay --disable-ptx-compression --disable-static --disable-libxcb --disable-sdl2 --disable-xlib --enable-lto --enable-gpl --enable-version3 --enable-shared --enable-gmp --enable-gnutls --enable-chromaprint --enable-libdrm --enable-libass --enable-libfreetype --enable-libfribidi --enable-libfontconfig --enable-libbluray --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libopenmpt --enable-libdav1d --enable-libwebp --enable-libvpx --enable-libx264 --enable-libx265 --enable-libzvbi --enable-libzimg --enable-libfdk-aac --arch=amd64 --enable-libsvtav1 --enable-libshaderc --enable-libplacebo --enable-vulkan --enable-opencl --enable-vaapi --enable-amf --enable-libmfx --enable-ffnvcodec --enable-cuda --enable-cuda-llvm --enable-cuvid --enable-nvdec --enable-nvenc
  libavutil      57. 28.100 / 57. 28.100
  libavcodec    59. 37.100 / 59. 37.100
  libavformat    59. 27.100 / 59. 27.100
  libavdevice    59.  7.100 / 59.  7.100
  libavfilter    8. 44.100 /  8. 44.100
  libswscale      6.  7.100 /  6.  7.100
  libswresample  4.  7.100 /  4.  7.100
  libpostproc    56.  6.100 / 56.  6.100
[matroska,webm @ 0x5570a7e39b80] Could not find codec parameters for stream 4 (Subtitle: hdmv_pgs_subtitle (pgssub)): unspecified size
Consider increasing the value for the 'analyzeduration' (200000000) and 'probesize' (5000000) options
[matroska,webm @ 0x5570a7e39b80] Could not find codec parameters for stream 5 (Subtitle: hdmv_pgs_subtitle (pgssub)): unspecified size
Consider increasing the value for the 'analyzeduration' (200000000) and 'probesize' (5000000) options
Input #0, matroska,webm, from 'file:/media/Movies/Guardians of the Galaxy Vol. 3 (2023)/Guardians of the Galaxy Vol. 3 (2023) Bluray-1080p.mkv':
  Metadata:
    title          : Guardiani.Della.Galassia.Vol.3.2023.IMAX.iTA.ENG.AC3.SUB.iTA.ENG.BluRay.HEVC.1080p.x265.jeddak-MIRCrew
    ENCODER        : Lavf60.3.100
  Duration: 02:30:02.34, start: 0.000000, bitrate: 2515 kb/s
  Stream #0:0: Video: h264 (Main), yuv420p(tv, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9], 23.98 fps, 23.98 tbr, 1k tbn (default)
    Metadata:
      title          : ...::: jeddak MIRCrew :::...
      ENCODER        : Lavc60.3.100 h264_nvenc
      DURATION        : 02:30:02.331000000
  Stream #0:1(ita): Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s (default)
    Metadata:
      title          : iTA AC3 5.1
      ENCODER        : Lavc60.3.100 ac3
      DURATION        : 02:30:02.341000000
  Stream #0:2(eng): Audio: ac3, 48000 Hz, stereo, fltp, 192 kb/s
    Metadata:
      title          : ENG AC3 5.1
      ENCODER        : Lavc60.3.100 ac3
      DURATION        : 02:30:02.341000000
  Stream #0:3(ita): Subtitle: subrip, 1920x1080 (forced)
    Metadata:
      title          : iTA FORCED - SRT
      DURATION        : 02:29:50.370000000
  Stream #0:4(ita): Subtitle: hdmv_pgs_subtitle, 1920x1080 (default) (forced)
    Metadata:
      title          : iTA FORCED - PGS
      DURATION        : 02:29:50.371000000
  Stream #0:5(ita): Subtitle: hdmv_pgs_subtitle, 1920x1080
    Metadata:
      title          : iTA REGULAR - PGS
      DURATION        : 02:29:50.371000000
  Stream #0:6(eng): Subtitle: hdmv_pgs_subtitle, 1920x1080
    Metadata:
      title          : ENG NON UDENTI - PGS
      DURATION        : 02:30:00.381000000
Stream mapping:
  Stream #0:0 (h264) -> setparams:default (graph 0)
  Stream #0:4 (pgssub) -> scale:default (graph 0)
  hwupload_vaapi:default (graph 0) -> Stream #0:0 (h264_vaapi)
  Stream #0:1 -> #0:1 (ac3 (native) -> aac (libfdk_aac))
Press [q] to stop, [?] for help
[matroska,webm @ 0x5570a7e39b80] sub2video: using 1920x1080 canvas
Output #0, hls, to '/config/data/transcodes/c7f4ad0c8fc585172fc67eaffd07f3e8.m3u8':
  Metadata:
    encoder        : Lavf59.27.100
  Stream #0:0: Video: h264 (Main), vaapi(tv, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9], q=2-31, 5031 kb/s, 23.98 fps, 90k tbn
    Metadata:
      encoder        : Lavc59.37.100 h264_vaapi
  Stream #0:1: Audio: aac, 48000 Hz, stereo, s16, 256 kb/s (default)
    Metadata:
      encoder        : Lavc59.37.100 libfdk_aac
frame=    1 fps=0.0 q=0.0 size=N/A time=00:00:00.00 bitrate=N/A speed=  0x   
frame=    7 fps=0.0 q=-0.0 size=N/A time=00:00:00.25 bitrate=N/A speed=0.327x   
frame=  13 fps=9.0 q=-0.0 size=N/A time=00:00:00.46 bitrate=N/A speed=0.325x   
Unrepairable overflow!
frame=  18 fps=9.1 q=-0.0 size=N/A time=00:00:00.70 bitrate=N/A speed=0.356x   
frame=  22 fps=8.7 q=-0.0 size=N/A time=00:00:00.85 bitrate=N/A speed=0.336x   
frame=  27 fps=8.8 q=-0.0 size=N/A time=00:00:01.08 bitrate=N/A speed=0.355x   
frame=  31 fps=8.4 q=-0.0 size=N/A time=00:00:01.23 bitrate=N/A speed=0.336x   
frame=  36 fps=8.6 q=-0.0 size=N/A time=00:00:01.42 bitrate=N/A speed=0.34x   
frame=  40 fps=8.3 q=-0.0 size=N/A time=00:00:01.62 bitrate=N/A speed=0.336x   
frame=  45 fps=8.4 q=-0.0 size=N/A time=00:00:01.81 bitrate=N/A speed=0.337x   
frame=  49 fps=8.2 q=-0.0 size=N/A time=00:00:01.98 bitrate=N/A speed=0.333x   
frame=  55 fps=8.3 q=-0.0 size=N/A time=00:00:02.24 bitrate=N/A speed=0.339x   
frame=  61 fps=8.4 q=-0.0 size=N/A time=00:00:02.49 bitrate=N/A speed=0.343x   
frame=  66 fps=8.5 q=-0.0 size=N/A time=00:00:02.70 bitrate=N/A speed=0.348x   
frame=  70 fps=8.4 q=-0.0 size=N/A time=00:00:02.88 bitrate=N/A speed=0.344x   
[hls @ 0x5570a7e602c0] Opening '/config/data/transcodes/c7f4ad0c8fc585172fc67eaffd07f3e80.ts' for writing
frame=  75 fps=8.5 q=-0.0 size=N/A time=00:00:03.07 bitrate=N/A speed=0.346x   
frame=  79 fps=8.4 q=-0.0 size=N/A time=00:00:03.26 bitrate=N/A speed=0.346x   
frame=  84 fps=8.4 q=-0.0 size=N/A time=00:00:03.45 bitrate=N/A speed=0.347x   
frame=  88 fps=8.3 q=-0.0 size=N/A time=00:00:03.60 bitrate=N/A speed=0.341x   
frame=  94 fps=8.4 q=-0.0 size=N/A time=00:00:03.86 bitrate=N/A speed=0.343x   
frame=  99 fps=8.4 q=-0.0 size=N/A time=00:00:04.09 bitrate=N/A speed=0.348x   
frame=  103 fps=8.4 q=-0.0 size=N/A time=00:00:04.24 bitrate=N/A speed=0.346x   
frame=  108 fps=8.4 q=-0.0 size=N/A time=00:00:04.43 bitrate=N/A speed=0.347x   
frame=  112 fps=8.4 q=-0.0 size=N/A time=00:00:04.62 bitrate=N/A speed=0.346x   
frame=  117 fps=8.4 q=-0.0 size=N/A time=00:00:04.82 bitrate=N/A speed=0.346x   
frame=  121 fps=8.3 q=-0.0 size=N/A time=00:00:04.99 bitrate=N/A speed=0.344x   
frame=  126 fps=8.4 q=-0.0 size=N/A time=00:00:05.20 bitrate=N/A speed=0.346x   
frame=  130 fps=8.3 q=-0.0 size=N/A time=00:00:05.37 bitrate=N/A speed=0.345x   
frame=  136 fps=8.3 q=-0.0 size=N/A time=00:00:05.63 bitrate=N/A speed=0.346x   
frame=  141 fps=8.4 q=-0.0 size=N/A time=00:00:05.82 bitrate=N/A speed=0.346x   
frame=  145 fps=8.3 q=-0.0 size=N/A time=00:00:06.01 bitrate=N/A speed=0.345x   
[hls @ 0x5570a7e602c0] Opening '/config/data/transcodes/c7f4ad0c8fc585172fc67eaffd07f3e81.ts' for writing
frame=  151 fps=8.3 q=-0.0 size=N/A time=00:00:06.22 bitrate=N/A speed=0.344x   
frame=  156 fps=8.4 q=-0.0 size=N/A time=00:00:06.46 bitrate=N/A speed=0.346x   
frame=  160 fps=8.3 q=-0.0 size=N/A time=00:00:06.61 bitrate=N/A speed=0.343x   
frame=  165 fps=8.3 q=-0.0 size=N/A time=00:00:06.84 bitrate=N/A speed=0.346x   
frame=  169 fps=8.3 q=-0.0 size=N/A time=00:00:06.99 bitrate=N/A speed=0.343x   
frame=  175 fps=8.3 q=-0.0 size=N/A time=00:00:07.25 bitrate=N/A speed=0.344x   
frame=  180 fps=8.3 q=-0.0 size=N/A time=00:00:07.44 bitrate=N/A speed=0.344x   
frame=  184 fps=8.3 q=-0.0 size=N/A time=00:00:07.61 bitrate=N/A speed=0.343x   
frame=  189 fps=8.3 q=-0.0 size=N/A time=00:00:07.82 bitrate=N/A speed=0.344x   
frame=  193 fps=8.3 q=-0.0 size=N/A time=00:00:08.00 bitrate=N/A speed=0.343x   
frame=  198 fps=8.3 q=-0.0 size=N/A time=00:00:08.21 bitrate=N/A speed=0.345x   
frame=  202 fps=8.3 q=-0.0 size=N/A time=00:00:08.38 bitrate=N/A speed=0.343x   
frame=  207 fps=8.3 q=-0.0 size=N/A time=00:00:08.57 bitrate=N/A speed=0.344x   
frame=  211 fps=8.3 q=-0.0 size=N/A time=00:00:08.76 bitrate=N/A speed=0.344x   
frame=  217 fps=8.3 q=-0.0 size=N/A time=00:00:08.98 bitrate=N/A speed=0.345x   
[hls @ 0x5570a7e602c0] Opening '/config/data/transcodes/c7f4ad0c8fc585172fc67eaffd07f3e82.ts' for writing
frame=  220 fps=8.3 q=-0.0 size=N/A time=00:00:09.15 bitrate=N/A speed=0.345x   
frame=  225 fps=8.3 q=-0.0 size=N/A time=00:00:09.34 bitrate=N/A speed=0.345x   
frame=  229 fps=8.3 q=-0.0 size=N/A time=00:00:09.49 bitrate=N/A speed=0.343x   
frame=  235 fps=8.3 q=-0.0 size=N/A time=00:00:09.74 bitrate=N/A speed=0.344x   
frame=  240 fps=8.3 q=-0.0 size=N/A time=00:00:09.94 bitrate=N/A speed=0.344x   
frame=  244 fps=8.3 q=-0.0 size=N/A time=00:00:10.13 bitrate=N/A speed=0.344x   
frame=  249 fps=8.3 q=-0.0 size=N/A time=00:00:10.32 bitrate=N/A speed=0.344x   
frame=  253 fps=8.2 q=-0.0 size=N/A time=00:00:10.49 bitrate=N/A speed=0.342x   
frame=  258 fps=8.3 q=-0.0 size=N/A time=00:00:10.70 bitrate=N/A speed=0.343x   
frame=  262 fps=8.2 q=-0.0 size=N/A time=00:00:10.88 bitrate=N/A speed=0.342x   
frame=  267 fps=8.3 q=-0.0 size=N/A time=00:00:11.09 bitrate=N/A speed=0.343x   
frame=  271 fps=8.2 q=-0.0 size=N/A time=00:00:11.26 bitrate=N/A speed=0.342x   
frame=  277 fps=8.3 q=-0.0 size=N/A time=00:00:11.52 bitrate=N/A speed=0.345x   
frame=  280 fps=8.2 q=-0.0 size=N/A time=00:00:11.60 bitrate=N/A speed=0.341x   
frame=  285 fps=8.3 q=-0.0 size=N/A time=00:00:11.84 bitrate=N/A speed=0.343x   
frame=  289 fps=8.2 q=-0.0 size=N/A time=00:00:11.98 bitrate=N/A speed=0.341x   
[hls @ 0x5570a7e602c0] Opening '/config/data/transcodes/c7f4ad0c8fc585172fc67eaffd07f3e83.ts' for writing
frame=  294 fps=8.2 q=-0.0 size=N/A time=00:00:12.22 bitrate=N/A speed=0.342x   
frame=  298 fps=8.2 q=-0.0 size=N/A time=00:00:12.37 bitrate=N/A speed=0.342x   
frame=  303 fps=8.2 q=-0.0 size=N/A time=00:00:12.56 bitrate=N/A speed=0.342x   
frame=  307 fps=8.2 q=-0.0 size=N/A time=00:00:12.75 bitrate=N/A speed=0.342x   
frame=  312 fps=8.2 q=-0.0 size=N/A time=00:00:12.94 bitrate=N/A speed=0.342x   
frame=  316 fps=8.2 q=-0.0 size=N/A time=00:00:13.12 bitrate=N/A speed=0.341x   
frame=  321 fps=8.2 q=-0.0 size=N/A time=00:00:13.33 bitrate=N/A speed=0.342x   
frame=  325 fps=8.2 q=-0.0 size=N/A time=00:00:13.50 bitrate=N/A speed=0.341x   
frame=  330 fps=8.2 q=-0.0 size=N/A time=00:00:13.71 bitrate=N/A speed=0.342x   
frame=  334 fps=8.2 q=-0.0 size=N/A time=00:00:13.88 bitrate=N/A speed=0.341x   
frame=  339 fps=8.2 q=-0.0 size=N/A time=00:00:14.08 bitrate=N/A speed=0.341x   
frame=  343 fps=8.2 q=-0.0 size=N/A time=00:00:14.27 bitrate=N/A speed=0.341x   
frame=  348 fps=8.2 q=-0.0 size=N/A time=00:00:14.46 bitrate=N/A speed=0.341x   
frame=  352 fps=8.2 q=-0.0 size=N/A time=00:00:14.61 bitrate=N/A speed=0.34x   
frame=  358 fps=8.2 q=-0.0 size=N/A time=00:00:14.86 bitrate=N/A speed=0.341x   
[hls @ 0x5570a7e602c0] Opening '/config/data/transcodes/c7f4ad0c8fc585172fc67eaffd07f3e84.ts' for writing
frame=  363 fps=8.2 q=-0.0 size=N/A time=00:00:15.10 bitrate=N/A speed=0.342x   
frame=  367 fps=8.2 q=-0.0 size=N/A time=00:00:15.25 bitrate=N/A speed=0.341x   
frame=  372 fps=8.2 q=-0.0 size=N/A time=00:00:15.44 bitrate=N/A speed=0.341x   
frame=  376 fps=8.2 q=-0.0 size=N/A time=00:00:15.63 bitrate=N/A speed=0.341x   
frame=  382 fps=8.2 q=-0.0 size=N/A time=00:00:15.87 bitrate=N/A speed=0.341x   
frame=  387 fps=8.2 q=-0.0 size=N/A time=00:00:16.08 bitrate=N/A speed=0.341x   
frame=  391 fps=8.2 q=-0.0 size=N/A time=00:00:16.25 bitrate=N/A speed=0.341x   
frame=  397 fps=8.2 q=-0.0 size=N/A time=00:00:16.51 bitrate=N/A speed=0.342x   
frame=  400 fps=8.2 q=-0.0 size=N/A time=00:00:16.64 bitrate=N/A speed=0.341x   

[q] command received. Exiting.

[hls @ 0x5570a7e602c0] Opening '/config/data/transcodes/c7f4ad0c8fc585172fc67eaffd07f3e85.ts' for writing
frame=  403 fps=8.2 q=-0.0 Lsize=N/A time=00:00:16.76 bitrate=N/A speed=0.34x   
video:7560kB audio:530kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown

I'll keep looking for the difference between these two media,
in the meantime I await your help

Thanks Upside-down-face


RE: Transcoding: When it's triggered and when it's not - TheDreadPirate - 2023-08-27

Quote:Stream #0:3(ita): Subtitle: subrip (forced)
Metadata:
title : iTA FORCED - SRT
DURATION : 02:29:50.370000000

These subs are being forced in file B. In the jellyfin log, not ffmpeg log, look for "TranscodeReason" and does it say "subtitlecodecnotsupported"? I am betting it is burning in the subtitles.


RE: Transcoding: When it's triggered and when it's not - pguidi - 2023-08-27

(2023-08-27, 06:29 PM)TheDreadPirate Wrote:
Quote:Stream #0:3(ita): Subtitle: subrip (forced)
    Metadata:
      title          : iTA FORCED - SRT
      DURATION        : 02:29:50.370000000

These subs are being forced in file B.  In the jellyfin log, not ffmpeg log, look for "TranscodeReason" and does it say "subtitlecodecnotsupported"?  I am betting it is burning in the subtitles.

When i play media B, the following lines in the Jellyfin log appears:

Code:
[2023-08-27 20:35:32.831 +02:00] [INF] [15] Emby.Server.Implementations.HttpServer.WebSocketManager: WS "192.168.1.239" request
[2023-08-27 20:35:40.837 +02:00] [INF] [26] Jellyfin.Api.Helpers.MediaInfoHelper: User policy for "benchy". EnablePlaybackRemuxing: True EnableVideoPlaybackTranscoding: True EnableAudioPlaybackTranscoding: True
[2023-08-27 20:35:40.839 +02:00] [INF] [26] Jellyfin.Api.Helpers.MediaInfoHelper: StreamBuilder.BuildVideoItem( Profile="Anonymous Profile", Path="/media/Movies/Guardians of the Galaxy Vol. 3 (2023)/Guardians of the Galaxy Vol. 3 (2023) Bluray-1080p.mkv", AudioStreamIndex=null, SubtitleStreamIndex=null ) => ( PlayMethod=Transcode, TranscodeReason=VideoCodecNotSupported, AudioCodecNotSupported, SubtitleCodecNotSupported ) "media:/videos/98d1fb02-5235-0f6a-acba-b5f9a80d57d1/master.m3u8?MediaSourceId=98d1fb0252350f6aacbab5f9a80d57d1&VideoCodec=h264,h264&AudioCodec=aac,mp3&AudioStreamIndex=1&SubtitleStreamIndex=4&VideoBitrate=139616000&AudioBitrate=384000&MaxFramerate=23.976025&MaxWidth=1920&api_key=<token>&SubtitleMethod=Encode&TranscodingMaxAudioChannels=2&RequireAvc=false&Tag=b0e04836847a5e82260440ecefcfed51&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=False&h264-level=40&h264-videobitdepth=8&h264-profile=main&TranscodeReasons=VideoCodecNotSupported,%20AudioCodecNotSupported,%20SubtitleCodecNotSupported"
[2023-08-27 20:35:44.714 +02:00] [INF] [38] Jellyfin.Api.Helpers.TranscodingJobHelper: "/usr/lib/jellyfin-ffmpeg/ffmpeg" "-analyzeduration 200M -init_hw_device vaapi=va:,driver=i965 -filter_hw_device va -hwaccel vaapi -hwaccel_output_format vaapi -autorotate 0 -canvas_size 1920x1080 -i file:\"/media/Movies/Guardians of the Galaxy Vol. 3 (2023)/Guardians of the Galaxy Vol. 3 (2023) Bluray-1080p.mkv\" -autoscale 0 -map_metadata -1 -map_chapters -1 -threads 0 -map 0:0 -map 0:1 -map -0:0 -codec:v:0 h264_vaapi -rc_mode CBR -b:v 5031636 -maxrate 5031636 -bufsize 10063272 -profile:v:0 main -force_key_frames:0 \"expr:gte(t,0+n_forced*3)\" -filter_complex \"[0:4]scale=s=1920x1080:flags=fast_bilinear[sub];[0:0]setparams=color_primaries=bt709:color_trc=bt709:colorspace=bt709,scale_vaapi=format=nv12:extra_hw_frames=24,hwdownload,format=nv12[main];[main][sub]overlay=eof_action=pass:shortest=1:repeatlast=0,hwupload_vaapi\" -start_at_zero -codec:a:0 libfdk_aac -ac 2 -ab 256000 -copyts -avoid_negative_ts disabled -max_muxing_queue_size 2048 -f hls -max_delay 5000000 -hls_time 3 -hls_segment_type mpegts -start_number 0 -hls_segment_filename \"/config/data/transcodes/c255e80a0e81ea550af51e197c0eb7bd%d.ts\" -hls_playlist_type vod -hls_list_size 0 -y \"/config/data/transcodes/c255e80a0e81ea550af51e197c0eb7bd.m3u8\""
[2023-08-27 20:36:02.898 +02:00] [WRN] [38] Jellyfin.Server.Middleware.ResponseTimeMiddleware: Slow HTTP Response from "http://192.168.1.94:8096/videos/98d1fb02-5235-0f6a-acba-b5f9a80d57d1/hls1/main/0.ts?DeviceId=222f6742848c2e3c&MediaSourceId=98d1fb0252350f6aacbab5f9a80d57d1&VideoCodec=h264,h264&AudioCodec=aac,mp3&AudioStreamIndex=1&SubtitleStreamIndex=4&VideoBitrate=139616000&AudioBitrate=384000&MaxFramerate=23.976025&MaxWidth=1920&PlaySessionId=c9186b24125143bc9e20db11fefeea9a&api_key=0fcd8a6425bc417ea14e8189f74c9273&SubtitleMethod=Encode&TranscodingMaxAudioChannels=2&RequireAvc=false&Tag=b0e04836847a5e82260440ecefcfed51&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=False&h264-level=40&h264-videobitdepth=8&h264-profile=main&TranscodeReasons=VideoCodecNotSupported,%20AudioCodecNotSupported,%20SubtitleCodecNotSupported&runtimeTicks=0&actualSegmentLengthTicks=30000000" to "192.168.1.239" in 0:00:18.2006166 with Status Code 200
[2023-08-27 20:36:11.793 +02:00] [WRN] [38] Jellyfin.Server.Middleware.ResponseTimeMiddleware: Slow HTTP Response from "http://192.168.1.94:8096/videos/98d1fb02-5235-0f6a-acba-b5f9a80d57d1/hls1/main/1.ts?DeviceId=222f6742848c2e3c&MediaSourceId=98d1fb0252350f6aacbab5f9a80d57d1&VideoCodec=h264,h264&AudioCodec=aac,mp3&AudioStreamIndex=1&SubtitleStreamIndex=4&VideoBitrate=139616000&AudioBitrate=384000&MaxFramerate=23.976025&MaxWidth=1920&PlaySessionId=c9186b24125143bc9e20db11fefeea9a&api_key=0fcd8a6425bc417ea14e8189f74c9273&SubtitleMethod=Encode&TranscodingMaxAudioChannels=2&RequireAvc=false&Tag=b0e04836847a5e82260440ecefcfed51&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=False&h264-level=40&h264-videobitdepth=8&h264-profile=main&TranscodeReasons=VideoCodecNotSupported,%20AudioCodecNotSupported,%20SubtitleCodecNotSupported&runtimeTicks=30000000&actualSegmentLengthTicks=30000000" to "192.168.1.239" in 0:00:08.3578556 with Status Code 200
[2023-08-27 20:36:20.686 +02:00] [WRN] [68] Jellyfin.Server.Middleware.ResponseTimeMiddleware: Slow HTTP Response from "http://192.168.1.94:8096/videos/98d1fb02-5235-0f6a-acba-b5f9a80d57d1/hls1/main/2.ts?DeviceId=222f6742848c2e3c&MediaSourceId=98d1fb0252350f6aacbab5f9a80d57d1&VideoCodec=h264,h264&AudioCodec=aac,mp3&AudioStreamIndex=1&SubtitleStreamIndex=4&VideoBitrate=139616000&AudioBitrate=384000&MaxFramerate=23.976025&MaxWidth=1920&PlaySessionId=c9186b24125143bc9e20db11fefeea9a&api_key=0fcd8a6425bc417ea14e8189f74c9273&SubtitleMethod=Encode&TranscodingMaxAudioChannels=2&RequireAvc=false&Tag=b0e04836847a5e82260440ecefcfed51&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=False&h264-level=40&h264-videobitdepth=8&h264-profile=main&TranscodeReasons=VideoCodecNotSupported,%20AudioCodecNotSupported,%20SubtitleCodecNotSupported&runtimeTicks=60000000&actualSegmentLengthTicks=30000000" to "192.168.1.239" in 0:00:08.3579888 with Status Code 200
[2023-08-27 20:36:29.463 +02:00] [WRN] [62] Jellyfin.Server.Middleware.ResponseTimeMiddleware: Slow HTTP Response from "http://192.168.1.94:8096/videos/98d1fb02-5235-0f6a-acba-b5f9a80d57d1/hls1/main/3.ts?DeviceId=222f6742848c2e3c&MediaSourceId=98d1fb0252350f6aacbab5f9a80d57d1&VideoCodec=h264,h264&AudioCodec=aac,mp3&AudioStreamIndex=1&SubtitleStreamIndex=4&VideoBitrate=139616000&AudioBitrate=384000&MaxFramerate=23.976025&MaxWidth=1920&PlaySessionId=c9186b24125143bc9e20db11fefeea9a&api_key=0fcd8a6425bc417ea14e8189f74c9273&SubtitleMethod=Encode&TranscodingMaxAudioChannels=2&RequireAvc=false&Tag=b0e04836847a5e82260440ecefcfed51&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=False&h264-level=40&h264-videobitdepth=8&h264-profile=main&TranscodeReasons=VideoCodecNotSupported,%20AudioCodecNotSupported,%20SubtitleCodecNotSupported&runtimeTicks=90000000&actualSegmentLengthTicks=30000000" to "192.168.1.239" in 0:00:04.3684977 with Status Code 200
[2023-08-27 20:36:36.429 +02:00] [WRN] [55] Jellyfin.Server.Middleware.ResponseTimeMiddleware: Slow HTTP Response from "http://192.168.1.94:8096/videos/98d1fb02-5235-0f6a-acba-b5f9a80d57d1/hls1/main/4.ts?DeviceId=222f6742848c2e3c&MediaSourceId=98d1fb0252350f6aacbab5f9a80d57d1&VideoCodec=h264,h264&AudioCodec=aac,mp3&AudioStreamIndex=1&SubtitleStreamIndex=4&VideoBitrate=139616000&AudioBitrate=384000&MaxFramerate=23.976025&MaxWidth=1920&PlaySessionId=c9186b24125143bc9e20db11fefeea9a&api_key=0fcd8a6425bc417ea14e8189f74c9273&SubtitleMethod=Encode&TranscodingMaxAudioChannels=2&RequireAvc=false&Tag=b0e04836847a5e82260440ecefcfed51&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=False&h264-level=40&h264-videobitdepth=8&h264-profile=main&TranscodeReasons=VideoCodecNotSupported,%20AudioCodecNotSupported,%20SubtitleCodecNotSupported&runtimeTicks=120000000&actualSegmentLengthTicks=30000000" to "192.168.1.239" in 0:00:00.9291445 with Status Code 200
[2023-08-27 20:36:41.470 +02:00] [WRN] [34] Jellyfin.Server.Middleware.ResponseTimeMiddleware: Slow HTTP Response from "http://192.168.1.94:8096/videos/98d1fb02-5235-0f6a-acba-b5f9a80d57d1/hls1/main/5.ts?DeviceId=222f6742848c2e3c&MediaSourceId=98d1fb0252350f6aacbab5f9a80d57d1&VideoCodec=h264,h264&AudioCodec=aac,mp3&AudioStreamIndex=1&SubtitleStreamIndex=4&VideoBitrate=139616000&AudioBitrate=384000&MaxFramerate=23.976025&MaxWidth=1920&PlaySessionId=c9186b24125143bc9e20db11fefeea9a&api_key=0fcd8a6425bc417ea14e8189f74c9273&SubtitleMethod=Encode&TranscodingMaxAudioChannels=2&RequireAvc=false&Tag=b0e04836847a5e82260440ecefcfed51&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=False&h264-level=40&h264-videobitdepth=8&h264-profile=main&TranscodeReasons=VideoCodecNotSupported,%20AudioCodecNotSupported,%20SubtitleCodecNotSupported&runtimeTicks=150000000&actualSegmentLengthTicks=30000000" to "192.168.1.239" in 0:00:01.8466323 with Status Code 200
[2023-08-27 20:36:46.705 +02:00] [WRN] [75] Jellyfin.Server.Middleware.ResponseTimeMiddleware: Slow HTTP Response from "http://192.168.1.94:8096/videos/98d1fb02-5235-0f6a-acba-b5f9a80d57d1/hls1/main/6.ts?DeviceId=222f6742848c2e3c&MediaSourceId=98d1fb0252350f6aacbab5f9a80d57d1&VideoCodec=h264,h264&AudioCodec=aac,mp3&AudioStreamIndex=1&SubtitleStreamIndex=4&VideoBitrate=139616000&AudioBitrate=384000&MaxFramerate=23.976025&MaxWidth=1920&PlaySessionId=c9186b24125143bc9e20db11fefeea9a&api_key=0fcd8a6425bc417ea14e8189f74c9273&SubtitleMethod=Encode&TranscodingMaxAudioChannels=2&RequireAvc=false&Tag=b0e04836847a5e82260440ecefcfed51&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=False&h264-level=40&h264-videobitdepth=8&h264-profile=main&TranscodeReasons=VideoCodecNotSupported,%20AudioCodecNotSupported,%20SubtitleCodecNotSupported&runtimeTicks=180000000&actualSegmentLengthTicks=30000000" to "192.168.1.239" in 0:00:02.0444853 with Status Code 200
[2023-08-27 20:36:51.723 +02:00] [WRN] [22] Jellyfin.Server.Middleware.ResponseTimeMiddleware: Slow HTTP Response from "http://192.168.1.94:8096/videos/98d1fb02-5235-0f6a-acba-b5f9a80d57d1/hls1/main/7.ts?DeviceId=222f6742848c2e3c&MediaSourceId=98d1fb0252350f6aacbab5f9a80d57d1&VideoCodec=h264,h264&AudioCodec=aac,mp3&AudioStreamIndex=1&SubtitleStreamIndex=4&VideoBitrate=139616000&AudioBitrate=384000&MaxFramerate=23.976025&MaxWidth=1920&PlaySessionId=c9186b24125143bc9e20db11fefeea9a&api_key=0fcd8a6425bc417ea14e8189f74c9273&SubtitleMethod=Encode&TranscodingMaxAudioChannels=2&RequireAvc=false&Tag=b0e04836847a5e82260440ecefcfed51&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=False&h264-level=40&h264-videobitdepth=8&h264-profile=main&TranscodeReasons=VideoCodecNotSupported,%20AudioCodecNotSupported,%20SubtitleCodecNotSupported&runtimeTicks=210000000&actualSegmentLengthTicks=30000000" to "192.168.1.239" in 0:00:00.6305067 with Status Code 200
[2023-08-27 20:36:53.713 +02:00] [INF] [38] Jellyfin.Api.Helpers.TranscodingJobHelper: Stopping ffmpeg process with q command for "/config/data/transcodes/c255e80a0e81ea550af51e197c0eb7bd.m3u8"
[2023-08-27 20:36:54.007 +02:00] [INF] [38] Jellyfin.Api.Helpers.TranscodingJobHelper: FFmpeg exited with code 0
[2023-08-27 20:36:54.008 +02:00] [INF] [38] Jellyfin.Api.Helpers.TranscodingJobHelper: Deleting partial stream file(s) "/config/data/transcodes/c255e80a0e81ea550af51e197c0eb7bd.m3u8"
[2023-08-27 20:36:55.539 +02:00] [INF] [68] Emby.Server.Implementations.Session.SessionManager: Playback stopped reported by app "Jellyfin Android" "2.5.2" playing "Guardiani della Galassia Vol. 3". Stopped at "17060" ms
[2023-08-27 20:36:55.635 +02:00] [WRN] [68] Jellyfin.Server.Middleware.ResponseTimeMiddleware: Slow HTTP Response from "http://192.168.1.94:8096/Sessions/Playing/Stopped" to "192.168.1.239" in 0:00:01.9266997 with Status Code 204
[2023-08-27 20:36:57.052 +02:00] [WRN] [38] Emby.Server.Implementations.HttpServer.WebSocketConnection: WS "192.168.1.239" error receiving data: "The remote party closed the WebSocket connection without completing the close handshake."
[2023-08-27 20:36:57.066 +02:00] [INF] [38] Emby.Server.Implementations.HttpServer.WebSocketManager: WS "192.168.1.239" closed


Same thing for media A:
Code:
[2023-08-27 20:40:22.061 +02:00] [INF] [74] Jellyfin.Api.Helpers.MediaInfoHelper: User policy for "benchy". EnablePlaybackRemuxing: True EnableVideoPlaybackTranscoding: True EnableAudioPlaybackTranscoding: True
[2023-08-27 20:40:22.062 +02:00] [INF] [74] Jellyfin.Api.Helpers.MediaInfoHelper: StreamBuilder.BuildVideoItem( Profile="Anonymous Profile", Path="/media/Movies/Jerry & Marge Go Large (2022)/Jerry & Marge Go Large (2022) WEBDL-1080p.mkv", AudioStreamIndex=null, SubtitleStreamIndex=null ) => ( PlayMethod=Transcode, TranscodeReason=VideoCodecNotSupported, AudioCodecNotSupported ) "media:/videos/365b2a2e-efc0-b4a9-f9a6-46cdbfdd1758/master.m3u8?MediaSourceId=365b2a2eefc0b4a9f9a646cdbfdd1758&VideoCodec=h264,h264&AudioCodec=aac,mp3&AudioStreamIndex=1&VideoBitrate=139616000&AudioBitrate=384000&MaxFramerate=23.976025&MaxWidth=1920&api_key=<token>&SubtitleMethod=Encode&TranscodingMaxAudioChannels=2&RequireAvc=false&Tag=3d9c1f7aad834167719913610d815557&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=False&h264-level=40&h264-videobitdepth=8&h264-profile=main&TranscodeReasons=VideoCodecNotSupported,%20AudioCodecNotSupported"
[2023-08-27 20:40:23.862 +02:00] [INF] [74] Jellyfin.Api.Helpers.TranscodingJobHelper: "/usr/lib/jellyfin-ffmpeg/ffmpeg" "-analyzeduration 200M -fflags +genpts  -i file:\"/media/Movies/Jerry & Marge Go Large (2022)/Jerry & Marge Go Large (2022) WEBDL-1080p.mkv\" -map_metadata -1 -map_chapters -1 -threads 0 -map 0:0 -map 0:1 -map -0:s -codec:v:0 copy -bsf:v h264_mp4toannexb -start_at_zero -codec:a:0 libfdk_aac -ac 2 -ab 256000 -copyts -avoid_negative_ts disabled -max_muxing_queue_size 2048 -f hls -max_delay 5000000 -hls_time 6 -hls_segment_type mpegts -start_number 0 -hls_segment_filename \"/config/data/transcodes/040e2a279f8fc115faafef615b63cbb9%d.ts\" -hls_playlist_type vod -hls_list_size 0 -y \"/config/data/transcodes/040e2a279f8fc115faafef615b63cbb9.m3u8\""
[2023-08-27 20:40:25.460 +02:00] [WRN] [33] Jellyfin.Server.Middleware.ResponseTimeMiddleware: Slow HTTP Response from "http://192.168.1.94:8096/videos/365b2a2e-efc0-b4a9-f9a6-46cdbfdd1758/hls1/main/0.ts?DeviceId=222f6742848c2e3c&MediaSourceId=365b2a2eefc0b4a9f9a646cdbfdd1758&VideoCodec=h264,h264&AudioCodec=aac,mp3&AudioStreamIndex=1&VideoBitrate=139616000&AudioBitrate=384000&MaxFramerate=23.976025&MaxWidth=1920&PlaySessionId=76ad7812037a4049b5ba1156ea1ad278&api_key=0fcd8a6425bc417ea14e8189f74c9273&SubtitleMethod=Encode&TranscodingMaxAudioChannels=2&RequireAvc=false&Tag=3d9c1f7aad834167719913610d815557&SegmentContainer=ts&MinSegments=1&BreakOnNonKeyFrames=False&h264-level=40&h264-videobitdepth=8&h264-profile=main&TranscodeReasons=VideoCodecNotSupported,%20AudioCodecNotSupported&runtimeTicks=0&actualSegmentLengthTicks=104270000" to "192.168.1.239" in 0:00:01.6167174 with Status Code 200



RE: Transcoding: When it's triggered and when it's not - TheDreadPirate - 2023-08-27

Media B
Quote:TranscodeReason=VideoCodecNotSupported, AudioCodecNotSupported, SubtitleCodecNotSupported

Media A
Quote:VideoCodecNotSupported, AudioCodecNotSupported

Since your client doesn't support the subtitle format (common on Android TV) it is burning in the subtitles.  Burning in subtitles requires transcoding.  If it did not have forced subtitles on B it would probably copy the video stream like with A.

If you need the subtitles, you can use ffmpeg and other tools to extract the subs into a separate file and convert them to a format that your client supports.


RE: Transcoding: When it's triggered and when it's not - pguidi - 2023-08-27

(2023-08-27, 06:50 PM)TheDreadPirate Wrote: Media B
Quote:TranscodeReason=VideoCodecNotSupported, AudioCodecNotSupported, SubtitleCodecNotSupported

Media A
Quote:VideoCodecNotSupported, AudioCodecNotSupported

Since your client doesn't support the subtitle format (common on Android TV) it is burning in the subtitles.  Burning in subtitles requires transcoding.  If did not have forced subtitles on B it would probably copy the video stream like with A.

If you need the subtitles, you can use ffmpeg and other tools to extract the subs into a separate file and convert them to a format that your client supports.

Removing all the subtitles streams worked like a charm.
It seems that this issue pops up only for PGS subtitles, with srt it doesn't slow down the playback
I will think up a way to solve this..

Many thanks


RE: Transcoding: When it's triggered and when it's not - bitmap - 2023-08-27

PGS, VOB_SUB, HDMV, DVD_SUBS etc... are all image-based subtitles that will (generally) require transcoding. The best way to get around this is to use SRT files. You can use the OpenSubtitles plugin to find SRT files for most media files. There are other programs out there that help you find SRT files for your media as well. The in-between files are ASS/SSA, which sometimes will require transcoding and other times not. It all depends on the client and the complexity of the subtitles.