Yay for Jacob Seidelin to join me in accessihacking YouTube

Jacob Seidelin took his JavaScript kung-foo skills off Super Mario for a short while and wrote a proof of concept how to get the annotations out of a YouTube video to display it outside the movie.

I’ve blogged about this idea here and his solution is an example to use timeout to poll for annotations being displayed.

One little change with a massive impact would be to display the annotations in a form field - thus automatically updating screen reader buffers that there was a change.

This has the same issues as my idea to display timed comments as subtitles below the movie - polling is just not safe (imagine buffering in between), so it seems a simple method in the YouTube player to fire events at certain times would be great. Something like this:


var events = {
  times:[12312,12312314,14234234,234234234,23423425],
  callback:onTimedEvent,
  obj:{something:3}
}
ytplayer.timedEvents(events);
function onTimedEvent(o){
  // o would be {time:12312,obj:{something:3}};
}

The object would be a nice to have, for example to keep scope.

Check out Jacob’s annotation scraping example here

Tags: , , ,

3 Responses to “Yay for Jacob Seidelin to join me in accessihacking YouTube”

  1. Jacob Seidelin Says:

    As long as you get the current time from the ytplayer itself, what’s the problem with polling? (other than it being a bit ugly..) If the video pauses for whatever reason, so does the time reported by ytplayer.getCurrentTime(), no?

  2. Chris Says:

    Well, as you say it is ugly, and a hack. There is also quite a memory and processing overhead in intercepting the player constantly and calling the getCurrentTime() method. Of course it is a good solution for now, but I’d rather see this in the player API itself, natively than having that extra overhead.

  3. Jacob Seidelin Says:

    Of course, I agree. And I imagine it’s just a matter of time before there’s a real API available.

Leave a Reply

@mediaAjax
Scripting Enabled - hacking the web to be more accessible - London, England 19th and 20th of September 2008
Wait till I come! is the blog of , a developer evangelist living and working in London, England. Download vcard.

Feed me, Seymour: Entries (RSS) and Comments (RSS).