diff options
Diffstat (limited to 'bin/stream')
-rwxr-xr-x | bin/stream | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -64,6 +64,7 @@ fi [ -z "$XINPUT" ] || [ $XINPUT -eq 1 ] || exit1 "Too many arguments: Max. 1 multimedia source" [ -n "$NOAUDIO" ] || [ -z "$AINPUT$XINPUT" ] || MAYBEAUDIO=1 [ -n "$NOVIDEO" ] || [ -z "$VINPUT$XINPUT" ] || MAYBEVIDEO=1 +[ "$AINPUT$VINPUT$XINPUT" = "1" ] || TWOSOURCES=1 VSTREAMINDEX=1 [ -n "$AINPUT" ] || VSTREAMINDEX=0 @@ -91,7 +92,7 @@ ffmpeg -hide_banner -threads auto -re \ ${MAYBEVIDEO:+-filter_complex \ "[$VSTREAMINDEX:v]scale=-1:$HEIGHT${WATERMARK:-[v]}${WATERMARK:+[bg]${LOGO:+; [bg][$((VSTREAMINDEX+1)):v]overlay=main_w-overlay_w-20:main_h-overlay_h-20[v]}}"} \ - ${SAVEDIR:+-map ':a?' -map ':v?' \ + ${SAVEDIR:+-map '0:' ${TWOSOURCES:+-map '1:'} \ -codec copy \ -f matroska "file:$SAVEDIR/$(date +%Y%m%d-%H%M%S).mkv"} \ ${MAYBEAUDIO:+-map '0:a' \ |