I used S5 for my RubyManor presentation. It worked great. I didn’t have to mess around with PowerPoint or anything complex like that: instead, I wrote plain text, ran it through a script, and called up the results in a web browser.

However, S5 doesn’t work so great when someone wants to take those slides and put them into a video. But all is not lost. All I really need to do is to mash the space bar and take screenshots. I could sit there doing that—hit space, hit print screen, repeat (well, except that this keyboard doesn’t have print screen)—but that would get old fast. If I were a high street clothes retailer, I’d hire some children in Bangladesh to do it for me. But I’m not. It’s nothing ideological—I just lack the supply chain. Computers excel at mindless repetition, though, so why not take advantage of that and automate it?

I used three Ubuntu packages: the unappetisingly-named scrot to take screenshots, graphicsmagick to crop the images to 800 by 600 pixels, and xmacro to mash that space bar, then glued it all together with a little Ruby:

require 'fileutils'

puts 'Get everything in place! You have five seconds!'
sleep 5

puts 'Grabbing ... press Ctrl-C to exit.'

def grab(i)
  system "scrot tmp.png"
  system "gm convert -crop 800x600+0+0 tmp.png %03d.png" % i
  FileUtils.rm "tmp.png"

def advance
  IO.popen("xmacroplay '#{ENV['DISPLAY']}'", 'w') do |macro|
    macro.puts "KeyStrPress space"
    macro.puts "KeyStrRelease space"

i = 0
loop do
  i += 1
  grab i
  sleep 1

I employed the Web Developer Toolbar to resize the viewport of Firefox to 800 by 600 pixels, alt-dragged the window so that the viewport started at the very top left of the screen, then ran the script to produce 108 separate slide images.

It’s a bit of a niche requirement, but I hope it’s useful for someone else in a similar situation.