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
# Goal: video frames are duplicated and reversed (creating effect like Instagram's boomerang) and combined in animated webp | |
# Requires: ffmpeg, tested on ffmpeg 2021-11-10-git-44c65c6cc0-full_build-www.gyan.dev with Python 3.9.2 on Windows 10 | |
# Args: mode input_file output_file [start_time] [end_time] | |
# Example: python boomerang.py v test.mp4 out.webp -s 00:00:02 -e 00:00:10 | |
import argparse | |
import os | |
import shutil | |
from signal import signal, SIGINT | |
import subprocess |