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: 
hugetv
Level 7

how to create a loading for movie

I want to make a loading for the movie information to indicate how long already seeing with a bar using roImageCanvas and roVideoPlayer

this example

Our system http://www.rokumanager.com
0 Kudos
3 Replies
hugetv
Level 7

Re: how to create a loading for movie

this code

countdowntotal = m.player.getplaybackduration() - m.position
minutes = int(countdowntotal / 60)
seconds = int(countdowntotal - (minutes * 60))
if seconds < 10
seconds = "0"+seconds.tostr()
end if
countdownstr = minutes.tostr()+":"+seconds.tostr()

obtaining hour
Our system http://www.rokumanager.com
0 Kudos
hugetv
Level 7

Re: how to create a loading for movie

ok solution

countdowntotal = m.player.getplaybackduration() - m.position
hour = int(countdowntotal / 3600)
minutes = int((countdowntotal - (hour * 3600)) / 60)
'minutes = int(countdowntotal / 60)
seconds = int(countdowntotal - (minutes * 60))
if seconds < 10
seconds = "0"+seconds.tostr()
end if
countdownstr = hour.tostr()+"h "+minutes.tostr()+"m "+seconds.tostr()+"s "
Our system http://www.rokumanager.com
0 Kudos
hugetv
Level 7

Re: how to create a loading for movie

closed caption/audio not work with roImageCanvas
Our system http://www.rokumanager.com
0 Kudos