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

Again "An unexpected problem" on Roku 2

Hello!
Here (http://eulive.eu/try.zip) is very simple Big-buck-bunny playing program.
And it doesn't work on Roku 2. It doesn't play with the message:
Request Failed: -3: An unexpected problem (but not server timeout or HTTP error) has been detected.

It will play if at the next code:
    bm1 = createObject("roBitmap",{width:1280,height:720,AlphaEnable:true})
bm2 = createObject("roBitmap",{width:1024,height:512,AlphaEnable:true})
'bm3 = createObject("roBitmap",{width:1280,height:720,AlphaEnable:true})

make bm2 bitmap less (e.g. 512x512). Also after many runs it can doesn't work even with very small images (I have tried one time 1x1 the second image and it wasn't work).

But at Roku 1 it will play even with third bitmap and uncommented drawing code:
	'screen.drawObject(0,0,bm1)
'screen.drawObject(0,0,bm2)
'screen.drawObject(0,0,bm3)


What I do wrong? Why Roku 2 doesn't allow me create image buffers so much as I need?
0 Kudos
3 REPLIES 3
RokuChris
Roku Employee
Roku Employee

Re: Again "An unexpected problem" on Roku 2

Those are large bitmaps. You may be running up against memory limitations. One thing you can try is calling SetMaxVideoDecodeResolution() on your roVideoPlayer.

http://sdkdocs.roku.com/display/sdkdoc/ ... egerasVoid

This API enables applications that want to use both the 2D APIs and video playback with a lower resolution than 1080p. Without this call, these applications are likely to not have enough memory for either video playback or roScreen rendering
0 Kudos
shantyman
Visitor

Re: Again "An unexpected problem" on Roku 2

strange your try.zip work fine on original Roku and ROKU3 but will not work on Roku 2
Roku Channel: Eulive
0 Kudos
unDEFER
Streaming Star

Re: Again "An unexpected problem" on Roku 2

"RokuChris" wrote:
Those are large bitmaps. You may be running up against memory limitations. One thing you can try is calling SetMaxVideoDecodeResolution() on your roVideoPlayer.

Oh, you are right. The call with 1080x720 values is making it working even for more count of bitmaps.
But why error messages of player still leaves so confusing? I have spent very much time to find the reason of error in my ready application tested on Roku 1.
And please, pay attention: seems, there is memory leaking. The working application turns to not workng (with the same error) after many runs.
0 Kudos