Roku channel stream has 1 too many clicks

also, do the channel icons have to be in png? jpg is smaller sizes. plus do we need all those brs files? my channel is too big in size for Roku 1’s so I would like to delete the extra ones or do they make it compatible with the older roku’s?

You’re still talking about 2mb size limit? It doesn’t apply any more, at all. Old Rokus are no longer supported by the company - new channels aren’t available for them at all, regardless of size, so you can completely ignore them.

yeah, the size is 2.5 mb now. Not sure why zipping it makes it bigger because the size of the raw files are only 1.2 mb

I’ve never seen that happen, I’m skeptical

is it easy to have the channel look at a pastbin file/playlist instead of having the direct streams (m3u8) in the code so that if I need to change a stream link right away I don’t have to package an update and wait for Roku to publish the update to the channel, I can just change the link in my pastbin file on the fly and be done with it?

“matrixebiz” wrote:
is it easy?
Obviously not, or you would have done it already. If you can be more specific about why it’s not working, it will be easier to help you.

Unfortunately I have no idea on what to change in the code to have the channel pull my channels from a pastbin link instead of the current XML file.
So what I mean is, is it easy for you :slightly_smiling_face: to guide me how to do it and what to change or is it hard and I will need to re-write the whole channel instead of just changing a few pointers in the current Main.brs file. So for me, it is currently Hard since I would not know where to start but if is just a matter of showing me where to change a few pointers, then it will be easy for me from then on :slightly_smiling_face:

Change “pkg:/blahblahblah” to “http://pastebin/raw/blahblahblah” or whatever the url is for your xml files, images, etc.

In my Main.brs I have;
’ Parse the top-level Xml file, passing the resultant hierarchical content list to the UI display function
uiDisplay (parseXmlDocument (“pkg:/xml/links.xml”))

So when I change it to;

’ Parse the top-level Xml file, passing the resultant hierarchical content list to the UI display function
uiDisplay (parseXmlDocument (“http://pastebin.com/raw/Wg5r2766”))

Says unable to to parse xml because the pastbin site/file is not an xml it is a playlist of m3u8 links

Does it work when you use: uiDisplay (parseXmlDocument (“pkg:/xml/links.xml”)) ?

Oh, crap, I see what you are saying now. Post a copy of the xml file to pastbin because currently the pastbin raw file is a playlist of m3u links not an xml.

I’ll try that now.

… and change any references in the xml file and other files it includes to use either http:// or pkg:// depending on where your resources are located.

Ok, now that was easy :slightly_smiling_face:
I didn’t need to change anything in the xml file either because the resources are the same so when it parses the xml where ever it is, the roku still knows to grab the image from my images location item : sdImg=“pkg:/images/C214x144Sd.png”

So I didn’t actually need to change anything else except the link to where my xml is in Main.brs

Thx again

“belltown” wrote:

If instead you were to use the NewVideoPlayer (http://forums.roku.com/viewtopic.php?f=34&t=91672&p=516080), which you can get from https://github.com/belltown/Roku-NewVideoPlayer
Hi belltown, is there a reason why you removed the “showFeed.brs” file from your SDK?

I read that if I want to help users who have lower internet speeds to read hls streams properly to help loading issues, I should add the below code to my XML file to adjust the quality of the stream on the fly?;


<switchingStrategy>full-adaptation</switchingStrategy>

but for this to work properly, I also need to add the below to the showFeed.brs file;


if item.StreamFormat = "" then  'set default streamFormat to mp4 if doesn't exist in xml
            item.StreamFormat = "HLS"
        endif
      If item.StreamFormat="hls" then
                 item.SwitchingStrategy="full-adaptation"
              End If

but this file doesn’t exist anymore in your updated SDK package. Is this not needed anymore?

According to the documentation, the default HLS SwitchingStrategy is “full-adaptation”, so it shouldn’t be necessary to specify this in the content meta-data. However, I’ve updated NewVideoPlayer on GitHub to allow you to specify full-adaptation in a Roku Feed (or any other allowable value for switching strategy), if the streamFormat is “hls” (see categories.xml)

The file that handles the change is RokuFeed.brs

Ok, thanks I’ll check it out.
On the thread I was reading (Can’t find it now and I think it was from last year) the ‘default HLS SwitchingStrategy’ code was broken or something so hence the reason why users had to manually add the code I mentioned above to force it but maybe that is fixed already ??

Will this help with the users Roku’s who have slower internet speeds constantly pause and do the Loading … thing every few minutes?
or is there something else I can code in for this detection? a drop in quality is less annoying than that Loading screen all the time.
(I have no control over the stream source/feed so I can’t lower the HD video quality at the source)

If the stream is encoded at a bitrate that’s higher than the users’ internet connections can handle, then there’s nothing you can do about that.

Hi belltown, as the channel reads my feed XML file and if I wanted to add something to the end of the streamUrl, like an authentication code for streams that contain ‘HD’ in the title, EG;


	 <item sdImg="pkg:/images/Tsc214x144Sd.png" hdImg="pkg:/images/Tsc290x218Hd.png">
            <title>Stream HD</title>
            <description></description>
            <streamFormat>hls</streamFormat>
			<media>
                <streamQuality>HD</streamQuality>
                <streamBitrate>0</streamBitrate>
                <streamUrl>http://stream.m3u8?id=</streamUrl>
            </media>
            <synopsis></synopsis>
            <genres></genres>
            <live>True</live>
        </item>

Where and which file can I modify to add this code in? The ‘authentication code’ is generated elsewhere so I cannot add it directly to the feed XMl file beforehand. Like for example, the XML is read and if the title has HD in it, then streamUrl = streamUrl + authentication code

Thank you

“matrixebiz” wrote:
Where and which file can I modify to add this code in? The ‘authentication code’ is generated elsewhere so I cannot add it directly to the feed XMl file beforehand. Like for example, the XML is read and if the title has HD in it, then streamUrl = streamUrl + authentication code
RokuFeed.brs in parseRokuItem() right after line 345, e.g:


        stream.url          = _getXmlString (media, "streamUrl")
        stream.url          = stream.url + authenticationCode

Hello, that is great for all the streams but like I mentioned I only want it to add the ‘authenticationcode’ to only the streams that have ‘HD’ in the Stream HD. Thx