#714 ✓ staged

Plugin Meta: Alias in:start & out:end

Reported by Rick | September 11th, 2011 @ 08:26 AM | in 0.9 (closed)

I want to open up discussion here about adding "aliases" for start/end. I think this will make the API more intuitive to new comers from video production and editting backgrounds. See: http://multimedia.journalism.berkeley.edu/tutorials/finalcut/editin...

I suspect that this is super easy and may only involve adding the following line to the Popcorn.plugin inner plugin definition closure:

if ( options[ "in" ] ) {
  options.start = options[ "in" ];

if ( options[ "out" ] ) {
  options.end = options[ "out" ];

An example use case:

  in: 1, 
  out: 3, 
  text: "This is a subtitle that will appear at 1s and disappear at 3s"

... unfortunately, because in is a reserved word in JavaScript (for-in) we'll have to use a string literal property derefence. For symmetry, I've also done the same with out

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