how to rotate a movie?

VirginSnow at vfemail.net VirginSnow at vfemail.net
Thu Aug 30 12:56:51 EDT 2007


> From: kevin_d_clark at comcast.net (Kevin D. Clark)
> Date: 30 Aug 2007 10:14:37 -0400

> This is possibly a silly question.

Sillier than "can trained monkeys insall Linux?" ?

> A family member has given me a small movie that they shot with their
> digital camera.  The movie was shot with the camera turned sideways
> (it made things fit better).

Some cams have a gravity sensor which detects and automatically
corrects for this.  I want one!

> Can anybody recommend FOSS tools that could help me rotate all of the
> frames that comprise this movie by 90 degrees?

You could do:

 $ mencoder silly.mov -vf rotate=2 -oac copy \
   -ovc lavc -lavcopts  vcodec=mjpeg -o straight.avi

You should use either rotate=1 or rotate=2, depending on which way the
camera was held.  Note that this *won't* work with "-ovc copy" because
the video stream would be copied verbatim--without rotation.

If you don't want to transcode the movie, but leave it alone, and just rotate
what what mplayer shows you:

 $ mplayer silly.mov -vf rotate=1 # or rotate=2, depending on gravity

Alternatively, you could:

 # ln -s /usr/bin/X11/Xvfb /usr/bin/X11/X
 ...restart X... and
 $ xrandr -o left # or s/left/right/

to rotate everything you see on your X display 90 degrees one way or
the other. :)


More information about the gnhlug-discuss mailing list