Friday, March 4, 2011

Customize YouTube® PlayBack

The Example will demonstrate customizing YouTube playback by adding some query paramateres to URL:
  • Set starting point for video by specifying offset-time in minutes and seconds from the beginning (in this example: 1 min and 20 sec, which will force the player to start the video at "Accidents Amazing"):
http://www.youtube.com/watch?v=6z8nD025BFE&t=1m20s
where "6z8nDo25BFE" is the actual video item id, the mandatory part of YouTube URL
string and the addtional parmaeters specifying the starting point of &t=1m10s.
  • Playback in a Full Screen mode: http://www.youtube.com/watch?v=6z8nD025BFE, where 6z8nDo25BFE represents the video id:

    Setting Autoplay in Full Screen mode: by default this option is set to "OFF". In order to turn it "ON" add the parameter "&autoplay=1" to the web query.
  • Playback Loop (number of video re-plays) could be specified by adding the following parameter: “&loop=2” to the query to play the video twice or “&loop=3” to replay it three times and so on.
  • Turn “OFF” the "Related Video" option to filter-off "extras" from the video port by adding “&rel=0” to web query.

No comments:

Post a Comment