How to convert an S5 presentation to images
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"
end
def advance
IO.popen("xmacroplay '#{ENV['DISPLAY']}'", 'w') do |macro|
macro.puts "KeyStrPress space"
macro.puts "KeyStrRelease space"
end
end
i = 0
loop do
i += 1
grab i
advance
sleep 1
end
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.
2008-12-06 17:45 UTC. Comments: 3.

James Adam
Wrote at 2008-12-06 23:45 UTC using Firefox 3.0 on Mac OS X:
I ought to say that Paul did this for my benefit (I’m putting together the video of his presentation at the moment), and it’s saved me a hell of a lot of work.S5 makes the presentation trivial to host online, and this little script has made it trivial (well, certain aspects anyway!) for me to integrate his slides against the video we shot on the day. Sweet!
Xiangdian
Wrote at 2008-12-12 11:22 UTC using Firefox 3.1b1 on Windows XP:
Very impressive, you hacker!Programmers’ language is another foreign language for me, but i was curious to see how your slides look like. I could still sense that meticulous logic and humor between the lines. Great indeed!
btw, glad that i don’t need to prove i am human before leaving comments here.
Good day!
Marty Brandon
Wrote at 2009-07-19 15:42 UTC using Safari 530.19 on Mac OS X:
Thanks Paul! Am just getting started with S5 and wanted to make sure I could easily convert my presentations to Quicktime. This is just what I needed.