Forum Discussion

anilk1797's avatar
anilk1797
Visitor
9 years ago

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 = m.top.createChild("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?

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


    It's working properly