Skip to content

Instantly share code, notes, and snippets.

@tmaybe
Created June 16, 2014 21:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tmaybe/7aa0e9cbd4bb8fa3387b to your computer and use it in GitHub Desktop.
Save tmaybe/7aa0e9cbd4bb8fa3387b to your computer and use it in GitHub Desktop.
rotate & shrink videos with moviepy
import glob
from moviepy.editor import *
for filename in glob.glob("./*.mov"):
output_filename = './' + filename.split('/')[-1].split('.')[0] + '-resized.mov'
VideoFileClip(filename).fx(vfx.rotation, 180).resize(0.3).to_videofile(output_filename, audio=False)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment