
How To Replace a $600 Piece of Software with 100 Lines of Ruby - batasrki
http://blog.wekeroad.com/building-things/video-encoding-rack-attack?utm_source=feedburner&utm_medium=feed&utm_campaign=Feed%3A+wekeroad%2FEeKc+%28Rob+Conery%29&utm_content=Google+Reader
======
vgurgov
been there, after tens of experiments like that and using stuff like
pandastream I ended up using zencoder.com. reasons?

1) its FAST(are you seriously explect someone will wait 5-40 mins on your site
while vid is encoding?). 2) ffmpeg doesnt support some weird non-open source
codecs that users keep sending to our site. 3)it just works. always. and takes
much less than 100 lines to hook.

So, i didn't get what exactly $600 piece author referring to. i dont know any
sw that costs $600 and can be replaced by these 100 lines.

~~~
jamesbritt
"So, i didn't get what exactly $600 piece author referring to. i dont know any
sw that costs $600 and can be replaced by these 100 lines."

Sorenson Squeeze. It's right in the article.

Now, whether this Ruby code replaces all of what Sorenson Squeeze does is
another matter. (I'm betting the answer is "No."
<http://www.sorensonmedia.com/quality-video-encoding/details/>)

ffmpeg is pretty sweet, but I've run into problems converting one or another
video (swf, for example) so as you've noted it won't solve everyone's
conversion issues.

~~~
robconery
No - it doesn't replace all of it. Just the parts that I need. As I mention
Squeeze is a fine tool but I don't need integration with Sorenson's hosting
platform, and you can pretty much write whatever workflow you need in Ruby.

So I take it back - I do think this replaces Sorenson pretty handily :)

------
ilya_b
It's just like "Replacing the blog software with HTML file I created myself
with Notepad". Sometimes it will work, sometimes it wont.

If you will need two or more encoding jobs running in parallel, or to push
video properties for each file to the site, you will get into trouble very
soon, and 100 lines will grow to 10000.

------
burgerbrain
The short version: guy wraps FFMPEG with a little script and suddenly thinks
himself to be gods gift to man.

He didn't produce high value software ,the guys who wrote the software he used
did.

~~~
JoeAltmaier
Not fair. Takes all kinds of software. The packages he ref'd were supposed to
manage the process, but didn't deliver for $600. His script Did do what he
needed.

Its an argument for homebrew over bloated packages, at least when dealing with
process. And it was a great tutorial on Ruby for managing that.

~~~
burgerbrain
I was refering to FFMPEG, not the various ruby packages he used. All he really
did was wrap FFMPEG with a script that called it with predefined arguments and
kick it off to S3. He could have seen the same dramatic improvement with a
handful of lines of bash.

Probably worth noteing that he doesn't even seem to know how his own script
works. He was puzzled that it was burning all of his CPUs without him having
to make it do that, when that is _exactly_ the behavior you would expect.

~~~
JoeAltmaier
True, it was at a low level. I guess I'm just a sap for enthusiasm, which
(s)he has in spades.

