theclosh
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-22-2011
11:36 AM
Multiple channel types in one channel
Hello. I created a channel by manipulating the monitorsetup example to give me a fairly nice beginner channel with a couple slideshow presentations. However, now I am attempting to use the AudioApp example to integrate another Category into my current channel to provide a sublist of audio I have on the internet. I know I will be able to figure out inputting the needed code to get my audio but I'm having troubles getting the two formats to work together. I have a poster display for the category but if I click on it I get nothing or it returns to the main menu.
Any help available? Is this possible?
Thanks,
Chris
Any help available? Is this possible?
Thanks,
Chris
2 REPLIES 2
jbrave
Channel Surfer
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-22-2011
09:38 PM
Re: Multiple channel types in one channel
Sure, this is pretty easy to do.
lets say you have a set of poster items:
if the audio item is selected, then:
so:
Of course this is a very rough example, but hopefully you get the idea. You essentially create an audio player, then hand it an roAssociativeArray, in this example called song. You could do it like this:
lets say you have a set of poster items:
posterlist=[{shortdescriptionline1:"slideshow",action:"slideshow"},{shortdescriptionline1:"slideshow2",action="slideshow"},{shortdescriptionline1:"audio item",action:"music",song:{url:"http://www.musicwebsite.com/my.mp3",streamformat:"mp3"}}]
if the audio item is selected, then:
so:
while true
msg=wait(0,port)
if type(msg)="roPosterScreenEvent" then
ndx=msg.getindex()
if posterlist[ndx].action="music" then
audioplayer.stop()
audioplayer.clearcontent()
audioplayer.addcontent(posterlist[ndx].song)
audioplayer.play()
else
...do slide show
end if
Of course this is a very rough example, but hopefully you get the idea. You essentially create an audio player, then hand it an roAssociativeArray, in this example called song. You could do it like this:
audioplayer.addcontent({url:"http://my.com/m.mp3",streamformat:"mp3"})
Screenshades: The first Screensaver for Roku2!
Musiclouds: The best free internet music, on your Roku!
Ouroborialis: Psychedelic Screensaver for Roku!
Musiclouds: The best free internet music, on your Roku!
Ouroborialis: Psychedelic Screensaver for Roku!
theclosh
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-23-2011
05:10 AM
Re: Multiple channel types in one channel
Awesome! I was afraid it wasn't possible. It appears I was digging too far down into the code to make it happen.
Thanks a lot!
Chris
Thanks a lot!
Chris