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.
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Why fastforward/rewind button first time working too slow

I am working on video player using video node. My issue is when i press first time fastforward/rewind button during video playing/buffering then button is not working. After pressing 4-6 times fast forward or rewind button is working after that it is working properly but for first time i have to press 4-6 time button then working. My code is...

function setVideo()
m.InnerVideo ="InnerVideo")
inner = createObject("RoSGNode", "ContentNode")
inner.url = "url..."
inner.streamformat = "hls"

m.innerVideo.visible = true
m.innerVideo.content = inner
m.innerVideo.control = "play"
end function

function onKeyEvent(key as String, press as Boolean) as Boolean
handled = false

if press
if key = "fastforward"
print "fastforward" // Working after 4-6 times pressing for first job

handled = true
end if
end if

return handled
end function

Please suggest me what should be issue? Is issue related to video file format or encoding/decoding?

0 Kudos

Re: Why fastforward/rewind button first time working too slo

Thank you
After adding code
inner.SwitchingStrategy = "full-adaptation"

It's working properly
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.