Page 1 of 2

ffmpeg does NOT understand "-maxrate 999000k"

Posted: Wed Apr 09, 2025 2:58 pm
by Heiler
It isn't transcoding ANYTHING here because it tries to use this unknown option, at least with "-c:v hevc_nvenc"

[hevc_nvenc @ 00000000028036c0] supports NVENC
[hevc_nvenc @ 00000000028036c0] InitializeEncoder failed: invalid param (8):
[hevc_nvenc @ 00000000028036c0] Nvenc unloaded

Re: ffmpeg does NOT understand "-maxrate 999000k"

Posted: Wed Apr 09, 2025 3:19 pm
by Heiler
Even when I use libx265 it says:
[libx265 @ 00000000026d3300] Loaded libx265 does not support alpha layer encoding.

so transcoding is totally broken for me

Re: ffmpeg does NOT understand "-maxrate 999000k"

Posted: Wed Apr 09, 2025 4:15 pm
by mik_s
Could you post your logs so I can see some context? See the section in red above.

Re: ffmpeg does NOT understand "-maxrate 999000k"

Posted: Thu Apr 10, 2025 5:37 am
by Heiler
First I tried with tsmuxer enabled and TV said "This file type is not supported", then I've disabled tsmuxer and it tried to transcode the video: "This file cannot be recognized"

Re: ffmpeg does NOT understand "-maxrate 999000k"

Posted: Thu Apr 10, 2025 2:14 pm
by mik_s
You have made custom confs that are not complete that are overriding the selection of the appropriate conf for this TV as I mentioned here
  • [LG]webOSTVOLED55B7P-bb5d3ee2-3d63-e0be-6851-49ef643b046b.conf
  • [LG]webOSTVOLED55B7P-f933b0cb-8f66-d0f1-2a4c-550e28193830.conf
Delete these 2 files from "C:\ProgramData\UMS\renderers" and copy this conf to that folder.
LG-OLED-2016.conf
(2.87 KiB) Downloaded 107 times
I can't remember if this is the one I made for you before but it will match this TV.

Also try turning on "Use automatic maximum bandwidth" so it will use the max allowed by your network bandwidth to the TV.

Re: ffmpeg does NOT understand "-maxrate 999000k"

Posted: Thu Apr 10, 2025 2:44 pm
by Heiler
same thing

Re: ffmpeg does NOT understand "-maxrate 999000k"

Posted: Thu Apr 10, 2025 2:51 pm
by Heiler
this command line is simply WRONG:
DEBUG 2025-04-09 23:25:32.928 [ffmpeg.exe-2] net.pms.io.ProcessWrapperImpl Starting "C:\Program Files\Universal Media Server\bin\ffmpeg.exe" -y -loglevel info -hwaccel auto -threads 1 -i e:\t\The.Last.Of.Us.S01E01.2160p.UHD.BluRay.x265-BROADCAST.mkv -filter_complex [0:v][0:s:0]overlay -bufsize 1000000k -maxrate 999000k -crf 16 -ac 6 -ab 448k -c:a copy -c:v h264_nvenc -preset llhp -strict unofficial -f mpegts \\.\pipe\ffmpegvideo_103_1744251932625

you can't use "-maxrate 999000k" with nvenc

Re: ffmpeg does NOT understand "-maxrate 999000k"

Posted: Thu Apr 10, 2025 2:56 pm
by Heiler
anyway it shouldn't even transcode the video because my TV accepts it, the problem is the audio

Re: ffmpeg does NOT understand "-maxrate 999000k"

Posted: Thu Apr 10, 2025 6:58 pm
by mik_s
It is using that value because of your settings

Code: Select all

Reading maximum_bitrate: 0 (default: 90)
Using video bitrate limit from the general configuration (1000 Mb/s)
Reading H264LevelLimit: 5.1 (default: 4.1)
Adjusting the video bitrate limit to 999000 kb/s to make room for audio
Set this back to the default 90 and turn on "Use automatic maximum bandwidth" so UMS will run a speed test to use the best value for your network to the TV.
Screenshot 2025-04-10 072809.png
Screenshot 2025-04-10 072809.png (11.24 KiB) Viewed 1366 times
Even if you have Gigabit ethernet your TVs LAN port will be limited to 100mb/s as it does not need anything faster and these are cheaper for the manufactures to use.


There are also a couple of other options that could be causing it to fail. Set "Transcoding quality (MPEG-2):" and "Transcoding quality (H.264):" to Automatic (Wired)
Screenshot 2025-04-10 071810.png
Screenshot 2025-04-10 071810.png (12.72 KiB) Viewed 1366 times
You will have to change these before turning on use automatic maximum bandwidth as it disables this selector.
I'm not sure if it also ignores the settings here but best to do it anyway.
I was going to test this but I am using the v15 alpha and this box is broken in the redesign. I'll have to report this as a bug.

Since that video is 4K then h264 is not really suitable for that so it might be better to change the transcoding profile to "MPEGTS-H265-AC3"
I only recently read somewhere that h265 is needed for 4K as h264 has limited max bitrate. I think it was in some TV manual. That will be why this was used originally.

The reason that video is being transcoded is the same reason why Avatar was needed to be transcoded, it had forced PGS subtitles that TVs cannot display.

Code: Select all

Internal subtitles format "PGS" failed to match support line f:mkv       v:av1|h264|h265|mp4|mpeg2|vp8|vp9   a:aac-lc|he-aac|aac-main|ac3|dts|dtshd|truehd|mp3|mpa|eac3|lpcm|opus          m:video/x-matroska  si:ASS|SUBRIP
This is why the video stream cannot be remuxed as the subs need to be burnt in.

Code: Select all

Not muxing the video stream with FFmpeg because we need to burn subtitles.
I cannot remember but I think this is for the foreign language part in the intro of that episode. If you download some external subtitles then UMS would use those instead as the default is to force external subtitles, then the subs will be offered to the TV as a stream instead of transcoding. Assuming the audio track is supported too.
You can test if your TV can play that video by playing from the #--TRANSCODE--# folder and select "no transcoding"

Re: ffmpeg does NOT understand "-maxrate 999000k"

Posted: Fri Apr 11, 2025 4:15 am
by Heiler
My TV connects to wireless network at 780mbit/s, idk why devs found out that 30mbit would be the wireless ideal, maybe they're still in 2010?

Anyway changing max bitrates wouldn't fix that command line. It will still try to limit hardware encoders' bandwidth with -maxrate and ffmpeg doesn't allow that. It's not me, nor my computer, nor my TV, it's UMS's built-in ffmpeg that's complaining.

I've tried that "No transcoding" and it plays the video without audio (truehd seems to be supported in Netflix but not via DLNA) or subtitles.

I've changed all you mentioned and now it says:

"This file type cannot be played on this TV"