Created
May 25, 2021 13:20
-
-
Save elbruno/6a228086d5840570f68c7eaa4c1a3568 to your computer and use it in GitHub Desktop.
moviepysppedx4creategif.py
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
from moviepy.editor import VideoFileClip, clips_array, vfx | |
# open video and resize to 460 | |
clip1 = VideoFileClip("cat1.mp4").subclip(1,5).resize(width=460) | |
# open video, resize to 460 and speeed to x4 | |
clip2 = VideoFileClip("cat1.mp4").subclip(1,5).resize(width=460).speedx(4) | |
# final | |
final_clip = clips_array([[clip1, clip2]]) | |
final_clip.write_gif("speeddemo.gif") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment