aboutsummaryrefslogtreecommitdiff
path: root/example-scripts/ffmpeg/source-background-loop.sh
blob: e352ecbd814534e1d4e69a0e8b05368811160459 (plain)
  1. #!/bin/sh
  2. confdir="`dirname "$0"`/../"
  3. . $confdir/default-config.sh
  4. if [ -f $confdir/config.sh ]; then
  5. . $confdir/config.sh
  6. fi
  7. wget -nc -O /tmp/bg.ts http://c3voc.mazdermind.de/testfiles/bg.ts
  8. while true; do cat /tmp/bg.ts || exit 1; done |\
  9. ffmpeg -y -nostdin -re -i - \
  10. -filter_complex "
  11. [0:v] scale=$WIDTH:$HEIGHT,fps=$FRAMERATE [v]
  12. " \
  13. -map "[v]" \
  14. -c:v rawvideo \
  15. -pix_fmt yuv420p \
  16. -f matroska \
  17. tcp://$MIXHOST:16000