diff options
author | Jonas Smedegaard <dr@jones.dk> | 2017-05-07 00:50:19 +0200 |
---|---|---|
committer | Jonas Smedegaard <dr@jones.dk> | 2017-05-07 00:50:19 +0200 |
commit | 0d01c144a85c59fdf2cd0fe7bd93c346b0c6f438 (patch) | |
tree | be3e40eca5ddc50e859556114f7ee0117f7161a8 /bin | |
parent | 4f0a8d550a013f57886cc15543b01fa0185a7d81 (diff) |
Tidy functions: Move generic ones together.
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/stream | 15 |
1 files changed, 7 insertions, 8 deletions
@@ -86,6 +86,13 @@ VBITRATE=256000 echo_n() { printf "$*" } +# shellcheck disable=SC2048,SC2059 +printf_each() { + skel=$1; shift + for string in $*; do + printf "$skel" "$string" + done +} HEIGHTS=$(echo "$HEIGHTS_WEBM $HEIGHTS_MPEG" | tr ' ' '\012' | sort -u) HEIGHTCOUNT=$(echo "$HEIGHTS" | wc --words) @@ -100,14 +107,6 @@ VCODECCOUNT= [ -z "${SAVEDIR:-}" ] || SAVESTEM="${SAVEDIR:-}/$(date +%Y%m%d-%H%M%S)" [ -z "${SAVEDIR:-}" ] || export FFREPORT=file="$SAVESTEM.log" -# shellcheck disable=SC2048,SC2059 -printf_each() { - skel=$1; shift - for string in $*; do - printf "$skel" "$string" - done -} - tee_rtp() { stream=$1; pt=$2; port=$3; echo_n "[select=\'$stream\':f=rtp:payload_type=$pt]rtp://$IP:$port?pkt_size=1200" } |