Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Fetching latest commit…

Cannot retrieve the latest commit at this time

..
Failed to load latest commit information.
README
langref_parser
play-youtube.sh
pygil
urldecode.sh
youtube-args-dumper.sh
youtube-get-player.sh

README

HOW TO USE THESE SCRIPTS

EXECUTION:

This demo aims at rendering, the runtime generated UI of the new YouTube player. Recently YouTube switched 
to Flash 10 and AS3 to serve some HD content, while maintaining the old AS2 based player for lower quality content.

-) First of all download the YouTube player SWF. The URL changes from time to time as YouTube deploys new player versions
   so it needs to be scraped from the HTML page:
	wget `./scripts/youtube-get-player.sh http://www.youtube.com/watch?v=4N2YWRJ-ppo` -O player.swf
-) The player works by gathering the parameters from the Javascript in the page. Lightspark support loading parameters from a text file
   using the --parameters-file command line. Create a suitable parameters file using the following commands
	cd scripts
	./youtube-args-dumper.sh http://www.youtube.com/watch?v=4N2YWRJ-ppo > ../yt-args
	cd ..
-) Execute the file, this will render the usual UI of the YouTube player and decoded video, no sound is played yet
	lightspark --parameters-file yt-args player.swf

A command that automates the above steps:

	./scripts/play-youtube.sh http://www.youtube.com/watch?v=4N2YWRJ-ppo

Press 'Q' on Lightspark window to close the application
Something went wrong with that request. Please try again.