BASIC

Author Topic: Palm WebOS - Bug in USESCREEN  (Read 1478 times)

Offline Kitty Hello

  • code monkey
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 10708
  • here on my island the sea says 'hello'
    • View Profile
    • http://www.glbasic.com
Palm WebOS - Bug in USESCREEN
« on: 2011-Jul-18 »
Hi,

there's a driver bug in the WebOS platforms, that does not allow you to draw to an off-screen, paste that screen and draw again on it.
When you do SHOWSCREEN, the contents of the off-screen are pasted to the back buffer with the last state it has, no matter at what position you draw it. Like:

Code: GLBasic [Select]
CREATESCREEN 0,0, 100,100
DRAWSPRITE 0,0,0 // draw the "still empty" screen
USESCREEN 0
    PRINT "TEST",0,0
USESCREEN -1
SHOWSCREEN
 

This will print "TEST" to your screen. The DRAWSPRITE is buffered and executed only after the showscreen. So, if you need to reuse an offscreen, create a 2nd one, instead.
I think they buffer all GL calls for even more graphics power and flush on swapping the buffers.