Last active
January 30, 2023 20:40
-
-
Save nerdegem/67b04bfe25e8bc46bf712649bfde951a to your computer and use it in GitHub Desktop.
Code for TVHEadend to perform VAAPI conversion/streaming via external FFMPEG thread
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| In TVHeadend, create a new Stream Profile using the MPEG-TS SPAWN (Built-in) profile | |
| This one semms to work better: | |
| /usr/local/bin/ffmpeg -loglevel info -hide_banner -nostats -strict experimental -nostdin -err_detect ignore_err -skip_frame -nokey -ignore_unknown -threads 2 -extra_hw_frames 3 -rtbufsize 8096k -hwaccel vaapi -hwaccel_output_format vaapi -hwaccel_device /dev/dri/renderD128 -i pipe:0 -c:v hevc_vaapi -maxrate 5M -b:v 2M -vf 'deinterlace_vaapi=rate=field:auto=1,hwupload' -g 100 -c:a aac -b:a 128k -profile:a aac_main -c:s copy -f matroska pipe:1 | |
| This was the old one: | |
| /usr/local/bin/ffmpeg -loglevel info -hide_banner -nostats -strict experimental -nostdin -err_detect ignore_err -skip_frame -nokey -ignore_unknown -threads 1 -extra_hw_frames 3 -rtbufsize 4096k -hwaccel vaapi -hwaccel_device /dev/dri/renderD129 -hwaccel_output_format vaapi -i pipe:0 -c:v hevc_vaapi -maxrate 5M -b:v 2M -vf 'deinterlace_vaapi=rate=field:auto=1,hwupload' -c:a aac -b:a 128k -profile:a aac_main -c:s copy -force_key_frames expr:gte(t,n_forced*3) -f matroska pipe:1 | |
| Set the following Mime Type: | |
| video/x-matroska | |
| Recommend once its all working properly, changel the loglevel to quiet, fatal or error to avoid clogging up the log files. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment