Roku Developer Program

Developers and content creators—a complete solution for growing an audience directly.
cancel
Showing results for 
Search instead for 
Did you mean: 
derekctv
Level 7

Video Last Position

Here is my scenario, I want to store individual user video positions so that in the event of an interruption (video stop) I can deliver the last position played.

User account "Derek" is watching Video2.
Every 10 seconds (or so) can I get Roku to report Derek's play position via a variable string: "https://ourServer.com?user=fred&video=Video2&possition=180" (but using bright script via an API request)?
0 Kudos
4 Replies
RokuMarkn
Level 7

Re: Video Last Position

You would listen for roVideoPlayerEvent.isPlaybackPosition during playback to keep track of the position, and use roUrlTransfer to send the result to your server. If you don't care about being able to stop on one player and resume on another, you can just store the result in the registry rather than on your server.

--Mark
0 Kudos
derekctv
Level 7

Re: Video Last Position

Tkank you Mark. My only concern is whether there is sufficient space in the registry, even if I limit it to x videos per user and purge the data after x days. As the user base grows, so will the demands on the registry so I am considering storing the data externally and making a call to retrieve the last position. I would welcome comments from anyone who has tried this as 'I dont want re-invent the wheel'.
0 Kudos
Komag
Level 9

Re: Video Last Position

It's stored in the registry on their roku, not yours
0 Kudos
derekctv
Level 7

Re: Video Last Position

doh! many thanks
0 Kudos