#807 ✓ staged

Instances using frameAnimation are missing instance.data.timeUpdateFunction

Reported by Rick | November 1st, 2011 @ 01:29 PM | in 1.0 Release (closed)

When the frameAnimation branch is used, the function instance.data.timeUpdateFunction is never defined. Instances objects should always have the same shape.


if ( that.options.frameAnimation ) {
  //  if Popcorn is created with frameAnimation option set to true,
  //  requestAnimFrame is used instead of "timeupdate" media event.
  //  This is for greater frame time accuracy, theoretically up to
  //  60 frames per second as opposed to ~4 ( ~every 15-250ms)
  animate = function () {

    Popcorn.timeUpdate( that, {} );

    that.trigger( "timeupdate" );

    !that.isDestroyed && requestAnimFrame( animate );

  !that.isDestroyed && requestAnimFrame( animate );

} else {

  that.data.timeUpdateFunction = function( event ) {
    Popcorn.timeUpdate( that, event );

  if ( !that.isDestroyed ) {
    that.media.addEventListener( "timeupdate", that.data.timeUpdateFunction, false );

Comments and changes to this ticket

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

Popcorn.js is an HTML5 video framework that lets you bring elements of the web into your videos.

Popcorn.js is a project of Web Made Movies, Mozilla's Open Video Lab.

Shared Ticket Bins