Maniac Technical Instructions

Nick Winter originally did this with Telepath Logger. Bethany managed to get that working for her maniac week and helped Danny get it working on his computer but it involved hacking on the actual code and we wanted to experiment with a setup that anyone could use. Also, we wanted to do things like tail our TagTime log files in the dashboard area (aka HUD). So, with ideas from Lawrence Evalyn, here’s how we did it:

Collecting the screenshots

Here are things we’ve tried:

  1. Set up InstantShot (Mac OSX) to take a screenshot every minute and store them to a specified directory.
  2. Similar thing by Aaron Parecki that stores screenshots every 30 seconds, for up to 2 monitors, in ~/Pictures/Maniac: https://github.com/aaronpk/Maniac-Clock/releases

Collecting the webcam footage

Instead of trying to capture a separate video from your webcam and splice it together, just leave a small window with a live-updating image from your webcam at the bottom of the screen and let the screenshots capture it. You could do that by just opening some app that shows a live preview like Photobooth (except it won’t resize small enough) or Quicktime recorder (but the control buttons cover up the bottom of your face) or Gawker, but probably you’ll want something better. Here are things we’ve tried:

Turning the directory full of images into a video

Lawrence Evalyn says he got the images turned into a video using iMovie. For later timelapses, iMovie has been less able to deal with the huge number of images in a timely manner, so he just searched “time lapse” in the Mac app store and picked a free one, Zeitraffer, which also worked. That might or might not be easier than Bethany’s uebernerd hackery with ffmpeg below…

  1. In your images directory, crop all the images and write them to numbered imgXXXXX.jpg files in a subdirectory called tmp:
    x=1; for i in *.jpg; do counter=$(printf %05d $x); convert -crop 5120x3200+0+0 $i tmp/img"$counter".jpg; x=$(($x+1)); done

  2. Or if you just need to name them to have consecutive numbers in the filename:
    mkdir tmp
    x=1; for i in *.jpg; do counter=$(printf %05d $x); cp $i tmp/img"$counter".jpg; x=$(($x+1)); done

  3. Make a movie out of the images in tmp/ with 30 frames per second. Write it to maniac.mp4:
    ffmpeg -r 30 -f image2 -i tmp/img%05d.jpg -y -s 2560x1600 -r 30 -vcodec libx264 -preset slower -tune stillimage -crf 18 maniac.mp4

  4. Find a soundtrack as an m4a file and add it to the video:
    ./ffmpeg -i maniac.mp4 -i somesong.m4a -c:v copy -c:a copy -map 0:0 -map 1:0 -map 1:0 maniac_with_soundtrack.mp4
    If the sound file is longer then add “-shortest” before maniac_with_soundtrack.mp4 to have the soundtrack cut out when the timelapse ends.

(Bethany had issues with this that turned out to have to do with the encoding of the music. When she edited together a soundtrack in audacity and exported with an ffmpeg compatible filetype it worked fine.)

Maniacal Tips

  1. Turn off your screensaver. Your screen will be fine.
  2. Lawrence has an awesome segment in his timelapse where he pointed his webcam out the window and you can watch the clouds rolling by.

List of maniac weeks

  1. Bethany’s original maniac week
  2. Danny’s maniac weekend
  3. Danny and Bee’s joint maniac workweek
  4. Bethany’s maniac weekend with Aaron and Lily
  5. Nick’s collection of other people’s maniac weeks
  6. https://joshvarty.wordpress.com/2014/07/17/the-95-hour-work-week-and-why-it-should-have-been-more/

Maniac Checklist

  1. Turn off screen saver

Other Goodies

Bethany also made this for showing the time and day:

http://time.glitch.me

The idea is to put it in browser window shrunk down so it fits in your dashboard area. It’s worth having something dynamic like this in your dashboard otherwise there’s nothing interesting to see in the timelapse when you’re asleep. If you don’t want to count on an internet connection just grab the page source and put it an html file and open it that way. Safari seems to work