Roku Developer Program

Join our online forum to talk to Roku developers and fellow channel creators. Ask questions, share tips with the community, and find helpful resources.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
hugetv
Visitor

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 3
hugetv
Visitor

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
Visitor

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
Visitor

Re: how to create a loading for movie

closed caption/audio not work with roImageCanvas
Our system http://www.rokumanager.com
0 Kudos
Need Assistance?
Welcome to the Roku Community! Feel free to search our Community for answers or post your question to get help.

Become a Roku Streaming Expert!

Share your expertise, help fellow streamers, and unlock exclusive rewards as part of the Roku Community. Learn more.