How does one use the roTuner API with ifVideoPlayer? I’ve tried to copy the way Content-Metadata is configured in the Scene Graph (SimpleTuner) example but I get a “failed to create media player” error every time. Are there any constraints when using Broadcast video vs streaming? I might have triggered this error by also using SetDestinationRect.
Figured out the issue. I can literally just pass the content_metadata value from channel info to ifvideoplayer. Trying to create an AA that looks like the example doesn’t work.
“retrotom” wrote:
Figured out the issue. I can literally just pass the content_metadata value from channel info to ifvideoplayer. Trying to create an AA that looks like the example doesn’t work.
Have you got an example of what you did? I was playing about with the roTuner stuff last week and could only get the Screne Graph stuff to work, and I’ve yet to dive down that path.
I want to guess that you’ve done something like this, but I’m away from the kit to test
tuner = CreateObject("roTuner")
if (tuner <> invalid)
channels = tuner.GetChannelList()
channelInfo = tuner.GetChannelInfo(channels[0])
if channelInfo <> invalid
port = CreateObject("roMessagePort")
canvas = CreateObject("roImageCanvas")
canvas.SetMessagePort(port)
canvas.SetLayer(0, { color: "#00000000", CompositionMode: "Source" })
canvas.Show()
player = CreateObject("roVideoPlayer")
player.SetMessagePort(port)
player.SetDestinationRect(canvas.GetCanvasRect())
player.SetContentList(channelInfo.content_metadata)
player.Play()
while true
msg = Wait(0, port)
if msg.isRemoteKeyPressed()
index = msg.GetIndex()
if index = 0 ' <BACK>
print "Closing video screen"
player.Stop()
exit while
end if
end if
end while
end if
end if
Thanks retrotom, remote testing appears to work, although I’m not actually in front of the TV to check.
Also wondering if GetNowNextPrograms is actually supported, or a typo is involved in the OS/docs.
I’m hoping it’s just a typo. I’ve had to settle for just calling GetPrograms on each channel from the list. While it mostly works for my needs, I’m not confident this is the best route.
“renojim” wrote:
Where did that come from?!
Yours truly.
[spoiler=Nobody tells me nothin:2hbk5z78][youtube:2hbk5z78]bVEshFviM0g[/youtube:2hbk5z78][/spoiler:2hbk5z78] … but being around Roku for five years has given me a certain… je ne sais quoi in solving mysteries. :twisted:
Well I don’t get “Member function not found”, but I do get roInvalid for every channel. I don’t think this whole roTuner/roProgramGuide has finished baking.
“renojim” wrote:
Well I don’t get “Member function not found”, but I do get roInvalid for every channel. I don’t think this whole roTuner/roProgramGuide has finished baking.
That on a RokuTV ?
And you have let it discover the aerial channels at some point?
And can get list of channels via the API?
And have switched to antenna channel recently?
Yes x4. I get the info about the current program at the bottom of the screen when I change channels, but nothing from roProgramGuide except roInvalid for the two dozen or so channels I can receive.
Huh!
For me the info appears only after i have been switched to that channel - ditto for the info in http://rokuTV:8060/query/tv-active-channel - initially only shows the channel name but after been tuned to it gets the rest.