Open YouTube Activity project launched by Keyes Labs Print E-mail

Since posting a simple blog article in the fall of 2009 about how to render YouTube videos in an Android application, I've gotten a steady stream of developers downloading and using the Activity.  Since I don't have time to support the component myself, I've recently created a Google Code project as well as a Google Group for discussions.  My hope is that this will allow those that are interested to fix bugs and continue to evolve the software as a community.

There is decent support in Android for media, including video. If you're looking for an Activity that does the following, then the OpenYouTubePlayerActivity may be right for you:


  • Stream media. You don't want to include the video as a resource in your project, for obvious reasons. Furthermore, you want the flexibility to be able to potentially make changes to the video after deployment of the application.
  • Support low- and high-bandwidth scenarios. You don't want the display of the video to require WiFi or 3G connectivity. If your users don't have 3G locally, it can be a huge pain to try and stream HD video.
  • Embedded workflow. You don't want to lose control of your user when displaying a video. For example, registering an Intent that fires up the YouTube application can leave the user in the YouTube app. This is an effort to support YouTube's viral features. You want the user to return immediately to your application after the video completes.
  • Support for video updates. If you discovered after deployment that your fly was unzipped in the video and wanted to update content, you need to be able to upload a zipped-up version.
  • No backend server work. You don't want to write a new server backend to do any of this.

If you answered yes to these questions, then YouTube is a likely candidate for hosting your videos, and the OpenYouTubePlayerActivity could very well be the mechanism that you're looking for to render those videos in your app.

Feel free to use the component however you wish (it's licensed under Apache 2.0).  Please send patches or updates so that everyone can benefit!  If you want to be a contributor, just let me know...