Pregunta

I'm looking for a solution that allows a user to pause a video and resume playback on different device. Plex Media Server does a fairly good job of this with it's ''On Deck" feature.

On Deck displays movies that were started, but not finished, so they're "in progress" http://wiki.plexapp.com/index.php/Frequently_Asked_Questions#What_are_the_On_Deck_and_Shelf_features_in_the_client.3F

In Plex, when you select a video that is "On Deck", you have the option to continue from where you left off, or start from the beginning. Applications like Pause For Later also acheive this.

I'm currently using HLS for content delivery. For HLS streaming, one possible solution I have is to store the URL of the client's last requested media segment. This means playback progress could be determined server-side and saved regardless of whether the user paused, closed or lost connection. To resume, the application could generate a m3u8 playlist which starts from that last requested segment URL. However, there are a number of problems with this solution:

  1. You cannot rewind/backtrack.
  2. The video is resumed from the start of the last requested segment, not the exact point you left off.
  3. Specific to HLS.

So, how is this achieved in applications like Plex? Although I can't think of any concrete examples, I imagine that saving playback progress can be (and probably has been) done on downloaded videos? What design options are there for pausing and resuming an 'in-progress' video?

¿Fue útil?

Solución

You'll need to store the bookmark out of band. When they click pause, make the client record a bookmark on a separate service tied to their account. Then when playing from another client, lookup the bookmark and start from that offset in the asset.

This problem isn't really one you can solve in the media delivery layer, because what is delivered isn't a 1:1 match with what is played, and only the media player knows that. So it's always going to be done with media player integration.

To cover scenarios of the client losing connectivity, the client can periodically re-set the bookmark (e.g. every 10 seconds). Then if they start to play later from a different device, the last set bookmark can be used as the resume position.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top