-
-
Save DASPRiD/b702749fda0858569613 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# First we will create the splash video part in a lossless format | |
SPLASH_TEMP=$(mktemp --suffix=.mp4) | |
$FFMPEG -loop 1 -i "$INPUT_SPLASH" -t $SPLASH_LENGTH -c:v libx264 -pix_fmt yuv420p -preset ultrafast -qp 0 -y "$SPLASH_TEMP" | |
# Then create the final timelapse | |
$FFMPEG \ | |
-i "$SPLASH_TEMP" \ | |
-i "$INPUT_VIDEO" \ | |
-i "$INPUT_AUDIO" \ | |
-filter_complex "[1:v]setpts=$PTS*PTS [tl]; [0:v] [tl] concat=n=2:v=1:a=0 [v]" \ | |
-map '[v]' -map 2:0 \ | |
-codec:v libx264 -pix_fmt yuv420p -profile:v high -preset slow -b:v 4m -maxrate 4m -bufsize 8m -threads 0 \ | |
-codec:a libvo_aacenc -b:a 192k -ac 2 -ar 48000 \ | |
-shortest \ | |
-y \ | |
"$OUTPUT_FILE" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment