diff options
author | Jonas Smedegaard <dr@jones.dk> | 2017-04-06 18:59:02 +0200 |
---|---|---|
committer | Jonas Smedegaard <dr@jones.dk> | 2017-04-12 09:47:47 +0200 |
commit | 53cce70d95bf093e3ae0d4843ad3a9089945a9cd (patch) | |
tree | 67ab8744dc51b2654775fe3cc68cc5359d789f49 /bin/decode+edit+encode+stream | |
parent | 2a8f240d0a881686b87e4c3a6c0541bcf14061b3 (diff) |
Let looping be configurable.
Diffstat (limited to 'bin/decode+edit+encode+stream')
-rwxr-xr-x | bin/decode+edit+encode+stream | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/bin/decode+edit+encode+stream b/bin/decode+edit+encode+stream index 7b8a635..58144e1 100755 --- a/bin/decode+edit+encode+stream +++ b/bin/decode+edit+encode+stream @@ -11,6 +11,8 @@ fi PORT=${2:-5004} +ITERATIONS=${3-0} # endless by default + SIZE=640x360 BITRATE=500000 @@ -22,7 +24,7 @@ LOGO=../../content/icon_small.png # example "Real-time CBR Encoding and Streaming" # + Drop frames, aggressively treat as static, and use fastest cpu ffmpeg -threads auto -re \ - -f lavfi -i "movie=filename=$MOVIE:loop=0, setpts=N/(FRAME_RATE*TB), scale=$SIZE" \ + -f lavfi -i "movie=filename=$MOVIE:loop=$ITERATIONS, setpts=N/(FRAME_RATE*TB), scale=$SIZE" \ -i "$LOGO" -filter_complex 'overlay=main_w-overlay_w-20:main_h-overlay_h-20' \ -codec:v vp8 -quality realtime -deadline realtime -cpu-used 15 \ -b:v "$BITRATE" -minrate "$BITRATE" -maxrate "$BITRATE" \ |