Project

General

Profile

tvh_encode: simple scripts to encode recordings from tvheadend to h264 using ffmpeg and mkfifo

Added by Tobias Göbel almost 6 years ago

Hi,

i just wanted to share some scripts i stole together (most stuff is found on google and combined to these scripts).

The repository is on my gitlab server:
https://gitlab.arvenenaske.de/kubax/tvh_encode

The Systemd files basically create a named_pipe (fifo) in /tmp/systemd-ffmpeg-que and calls tvh_encode to encode the file passed to the named_pipe.
I used named_pipes because this way there is only one recording encoded at a time. Did this because i caught my system encoding multiple recordings at the same time and skyrocketing the load of my system.

You only have to set

/usr/local/bin/pass_to_fifo \"%f\" \"%b\"

as your command to run after recording in tvheadend and enable the tvh-ffmpeg-que.socket.