2020-03-21 11:31:27 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
set -euo pipefail
|
|
|
|
IFS=$'\n\t'
|
|
|
|
|
|
|
|
ffmpeg \
|
|
|
|
-y \
|
|
|
|
-hide_banner \
|
|
|
|
-nostdin \
|
|
|
|
-re \
|
|
|
|
-loglevel warning \
|
|
|
|
-timeout 5 \
|
|
|
|
-i ${url} \
|
|
|
|
-filter_complex "[0:v] scale=w=640:h=360, fps=25 [scaled];
|
|
|
|
[0:a] ebur128=video=1:target=-16:gauge=shortterm:scale=relative:size=640x480[ebur][a1];
|
|
|
|
[ebur] fps=25 [v1];
|
|
|
|
[v1][scaled] vstack=inputs=2 [out];
|
|
|
|
[a1] anullsink" \
|
|
|
|
-map "[out]" \
|
2020-05-09 08:23:50 +00:00
|
|
|
-c:v libx264 \
|
2020-03-21 11:31:27 +00:00
|
|
|
-pix_fmt yuv420p \
|
|
|
|
-q:v 2 \
|
|
|
|
-keyint_min 0 \
|
|
|
|
-an \
|
|
|
|
-f rtp rtp://127.0.0.1:${port}
|