Time Lapse Animation Technique

Recently I stumbled across a time lapse animation technique created by Cognitive Media in the U.K. for the Royal Society of the Arts. In their work (example, highly recommended) they use a stop motion animation technique to illustrate a lecture that was previously presented to a live audience. The result is an engaging and inspiring presentation of material that would otherwise be difficult to listen to. I was so impressed by the power and visual strength of their communication scheme that I set out to create a low budget alternative that I could easily implement for my own content.

While not nearly as professional as the RSAnimate series shown above I was able to achieve a similar result using a webcam and open source software. A cheap logitect webcam was hung above my desk. Then the two bash scripts shown below were executed at a command prompt to coordinate the capturing of images from the webcam, and the subsequent stitching of the still images into a movie file. The original inspiration for the linux commands came from a variety of sources here, here and here.

 

web cam time lapse animation setup

Web cam time lapse animation setup. The web cam is barely visible at the top of the picture. The web cam points down at the drawing surface (on the desk). A command window and preview image are shown on the computer monitor. The animator draws on the paper as the computer controls the capture of raw images.

 

#!/bin/sh
#time_lapse.sh

# collect all images in a temporary file
mkdir temp
echo press ctr+c to stop recording and make the movie

# capture images from webcam, move to temp folder
uvccapture -t2 -oimg.jpg -c/home/rdlowe/Pictures/Webcam/move_img.sh img.jpg

# after capturing images, in the tmp file folder
cd temp

# create text file with list of all images in temp folder
ls -1tr > files.txt

# convert images into AVI movie
mencoder -nosound -ovc lavc -lavcopts vcodec=mpeg4 -o test.avi -mf type=jpeg:fps=10 mf://@files.txt

# play movie
mplayer test.avi
#!/bin/sh
#move_img.sh

# move captured file to a temp directory and rename with time stamp
if [ ! $# -eq  1 ]; then
  echo "Usage: $0 FILENAME"
  exit 1
else
  FINAL="/home/rdlowe/Pictures/Webcam/temp/webcam-$(date +"%F-T%T").jpg"
  mv "$1" "$FINAL"
  echo "Moved $1 to ${FINAL}"
  exit 0
fi

After your camera is set up and pointing at the desired target, execute time_lapse.sh at a command prompt to start the recording process. When you have finished completing the capture of raw images press ctrl+c to stop recording and combine the still images into a movie, finally the script previews the movie for you automatically. To change the still image capture delay modify the uvccapture command -t[delay in seconds ]. To modify the playback frame rate modify the mencoder command fps=[frame rate (fps)]. A few things that I learned during this process that might be of interest if you are trying to make animations on your own computer are

  • All UVC webcams are supported by ubuntu natively. If you have the option, buy a UVC device.
  • Cheese is a very helpful program available from standard repositories for testing your webcam.
  • To overlay sound tracks on video, the PiTiVi program is an excellent choice.
  • To create subtitles, Gaupol is a minimalist subtitle editor that outputs srt files. Simply upload the srt along with your AVI file to add subtitles to your video.
  • On YouTube you upload the srt file by going to Edit>Captions and Subtitles.
  • This is pure speculation, but I believe that Cognitive Media records their animators using a HD digital camera mounted on a good tripod. Then the movie is exploded into its constituent still images from the raw video. Frames are added or deleted as needed to set the appropriate speed of each particular animation sequence and remove any undesired mistakes or corrections. Then I assume that the modified set of still frames is converted back into video, and the lecture audio is overlaid on the video. Lastly they have figured out a way to expertly light their white board which creates a very nice backdrop for the highly talented animators. Again this is purely conjecturer from watching a few of the RSAanimate videos.

My very first attempt at animation using this technique, or more precisely my very first attempt at animation ever can be found on another post. The post discussing time lapse photography might also be relevant.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

End of post, anything past this point is an advertisement appended by my (free) blog hosting company.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

 

Advertisements

About Ryan

Ryan is currently a National Research Council Postdoctoral Research Fellow at the Air Force Research Laboratory. His research area includes Prognostic Health Management of Electronics. For more information please visit: www.rdlowe.com
This entry was posted in Project and tagged , , , , , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s