GLBasic forum

Main forum => Bug Reports => Topic started by: Alex_R on 2013-Mar-30

Title: CREATESCREEN doesn't seem to work on iPhone
Post by: Alex_R on 2013-Mar-30
I have FOUR textures 512x512 and I want to create a big one of 1024x1024 with these four. I think I have to use CREATESCREEN to put all together (because GRABSPRITE only captures the screen).
I have this code which works properly on Windows but doesn't on the iPhone:
Code (glbasic) Select

SETCURRENTDIR("Media")

LOADSPRITE "iso_texture1.png",1
LOADSPRITE "iso_texture2.png",2
LOADSPRITE "iso_texture3.png",3
LOADSPRITE "iso_texture3.png",4

CREATESCREEN 0,5,1000,1500
USESCREEN 0
DRAWSPRITE 1,0,0
DRAWSPRITE 2,512,0
DRAWSPRITE 3,0,512
DRAWSPRITE 4,512,512
PRINT ".",0,0 //If I don't put this print (odd behavior) I can't see the last DRAWSPRITE
USESCREEN -1

CLEARSCREEN RGB(64, 64, 0)

STARTPOLY 5
  POLYVECTOR  0,   0,  0,  0
  POLYVECTOR   0, 300,  0, 1000
  POLYVECTOR 300, 300, 1000, 1000
  POLYVECTOR 300,  0, 1000,  0
ENDPOLY

PRINT PLATFORMINFO$("GLEX:glBindFramebufferEXT"),100,100
PRINT "Click to end",100,200
SHOWSCREEN
MOUSEWAIT


I think this is a bug because in the documentation there is no mention of iPhone problems.

Many thanks!!
Title: Re: CREATESCREEN doesn't seem to work on iPhone
Post by: Alex_R on 2013-Mar-30
Oh! Never mind! I've solved the problem.  :whistle:
It turns out that in older iPhones/iPods the screen size must not be more than 1024x1024, and I was setting 1000x1500.
Well... Now you know too. :)
Title: Re: CREATESCREEN doesn't seem to work on iPhone
Post by: spacefractal on 2013-Mar-31
Older phones don't support more than those texture size. But would been nice could detect the limit size.