public
Description: Video encoding made easy with AWS
Homepage: http://pandastream.com
Clone URL: git://github.com/newbamboo/panda.git
olly (author)
Mon Sep 28 10:39:49 -0700 2009
commit  e3c44adf5f36d09cfe4c11ad5d86cdcfe7d0a6d7
tree    fc82115f80ae3b3505b3af82d02cbab3ea7baacb
parent  85e73319538d56639ef2ec20d18983ba6035f09d
panda /
name age message
file .gitignore Loading commit data...
file Capfile Mon Mar 09 11:39:38 -0700 2009 deploy to new EC2 AMI with Cap [dctanner]
file LICENSE Tue Sep 16 13:55:48 -0700 2008 more explicit license [dctanner]
file README.markdown
file README_HOW_TO_UPGRADE
file Rakefile Wed Mar 11 09:44:39 -0700 2009 tweaks deps load order and fix rake load env tw... [dctanner]
file SINATRA_MANIFEST
directory app/
directory autotest/ Mon Oct 20 11:59:12 -0700 2008 Update merb app for 0.9.8 [mloughran]
directory benchmarks/ Tue Oct 07 10:22:49 -0700 2008 Benchmark tests for RVideo capture_frame. [mloughran]
directory bin/ Wed Oct 22 05:38:51 -0700 2008 Freeze merb 0.9.10 (AKA RC2) and all required g... [mloughran]
file config.ru Mon Mar 09 11:39:38 -0700 2009 deploy to new EC2 AMI with Cap [dctanner]
directory config/
directory lib/
directory log/ Wed Sep 24 05:19:19 -0700 2008 Created log dir [makoto]
file merb.thor Mon Oct 20 11:59:12 -0700 2008 Update merb app for 0.9.8 [mloughran]
directory merb/ Wed Oct 22 04:44:32 -0700 2008 Merb RC2 (updated with merb-gen). * Left out n... [mloughran]
file panda.god Mon Mar 02 09:31:30 -0800 2009 separate encoder and notifier envs [dctanner]
file panda_core.rb
file panda_core_config.ru
file panda_nginx.conf.example Tue Sep 23 07:52:02 -0700 2008 - Changed root dir from /usr/local/www to /var/... [makoto]
directory public/ Wed Mar 11 09:31:42 -0700 2009 remove old .htaccess file [dctanner]
directory script/ Thu Jun 05 13:41:11 -0700 2008 Initial import from our internal version of the... [dctanner]
directory spec/ Fri Apr 03 12:48:37 -0700 2009 Add html-based CRUD for profiles Signed-off-by... [theaboutbox]
directory test/ Mon Oct 20 11:59:12 -0700 2008 Update merb app for 0.9.8 [mloughran]
README.markdown

Panda

Panda is an open source solution for video uploading, encoding and streaming.

Please see pandastream.com for an introduction and lots of documentation.

Information beyond this point is aimed at people who want to contribute to panda and / or understand how it works.

How does Panda work?

  1. Video is uploaded to panda
  2. Panda checks the video's metadata, uploads the raw file to S3 and adds it to the encoding queue
  3. The encoder application picks the encoding job off the queue when it's free and encodes the video to all possible formats
  4. Panda sends a callback to your web application notifying you the video has been encoded
  5. You use the appropriate S3 url of the encoding to embed the video

Installation and setup

There are two options for running Panda. You can either the use the prebuild AMI which includes all of the software required to run Panda. Or if you wish run it locally on own your own server, you can follow the local installation guide.

Example Profiles

H254 and AAC

p = Profile.new p.category = "Flash h246" p.title = "Medium" p.width = 320 p.height = 240 p.command = "ffmpeg -i $input_file$ -acodec libfaac -ar 48000 -ab 64k -ac 2 -b 256K -vcodec libx264 -rc_eq 'blurCplx^(1-qComp)' -qcomp 0.6 -qmin 10 -qmax 51 -qdiff 4 -coder 1 -flags +loop -cmp +chroma -partitions +parti4x4+partp8x8+partb8x8 -subq 5 -me_range 16 -g 250 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -threads 4 $resolution_and_padding$ -y $output_file$" p.save

For iPhones

p = Profile.new p.category = "iPhone" p.title = "Low" p.width = 320 p.height = 240 p.command = "ffmpeg -i $input_file$ -f mpegts -acodec libmp3lame -ar 48000 -ab 64k -vcodec libx264 -b 96k -flags +loop -cmp +chroma -partitions +parti4×4+partp8×8+partb8×8 -subq 5 -trellis 1 -refs 1 -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -bt 200k -maxrate 96k -bufsize 96k -rc_eq 'blurCplx^(1-qComp)' -qcomp 0.6 -qmin 10 -qmax 51 -qdiff 4 -level 30 -aspect 320:240 -g 30 -async 2 -threads 4 $resolution_and_padding$ -y $output_file$" p.save