Update to Video Embed & Thumbnail Generator Compatible With WordPress 3.5 and All Kinds of New Stuff

I’ve been working on this one for way too long. I was all set to release a big update to my Video Embed & Thumbnail Generator WordPress plugin when I found out in November that WordPress version 3.5 messed with the media windows enough that I’d have to do a lot of tweaking to even maintain the functionality I had before. I think I’ve finally sorted everything out, and I apologize to anyone who updated to 3.5 right away and hasn’t been able to make thumbnails for a month. I think the wait was worth it.

For me, the coolest new thing about this version of the plugin is the video gallery. It’s pretty and it was actually one of the easier things to do. I designed the basic functionality last summer in order to display rough cuts of the 50 short monologues I edited for CenterStage’s 50th anniversary. (For the finished product they designed their own site using Vimeo for playback.) Here’s a sample gallery of my short-lived animated series:

The most important new feature is probably the addition of Video.js as an alternative to the old Strobe Media Playback Flash player. Video.js solves the problem I used to have with native HTML5 players, which is that they were ugly and all look different. It’s also lighter and more flexible, and I highly recommend switching to it. I managed to add Google Analytics tracking too, if that sort of thing interests you.

I wasn’t keeping up with FFMPEG’s development and totally missed the fork to LIBAV. I know most of you haven’t updated FFMPEG in ages so it didn’t seem to cause much trouble, but I now support calling LIBAV directly.

MP4 files encoded by FFMPEG save the moov atom at the end of the file and that was causing problems with streaming playback. I knew the way to fix this was to implement a queue system for encoding videos and run qt-faststart or MP4Box once the file is encoded, but I also knew to do it right would stretch my meager programming skills to the limit. I spent a long time on it, but it seems pretty good now. One of the most difficult things was interpreting the output from FFMPEG because it’s not really designed to interface with other programs like I’m doing. And then I had to make everything look pretty and work with AJAX because what’s the point of making something ugly that forces you to refresh all the time?