If I understand correctly, you are just taking an existing variable representing a bitmap and using it in a new CreateObject statement without invalidating it and then releasing it first, I think you need to invalidate it and call release before you reuse the variable for a new bitmap object. This may be some kind of bug in our system, since the reference should go away when you invalidate it. Which firmware version are you using?
A region is just a reference to a bitmap or a subset of a bitmap. The screen itself is essentially just another bitmap and behaves as such, for example, screen.getwidth() works just like bitmap.getwidth(). You should be able to create a bitmap and then use drawobject or any other calls, to the bitmap just as you would to the screen. You can even point a compositor at a bitmap instead of the screen and have it do all its work on that bitmap, and then draw it to the screen.
If a bitmap was 1000 x 1000 px, you could create a region from that bitmap:
region=createobject("roRegion",bitmap,100,100,100,100)
and you could draw to that region:
region.drawobject(10,10,another_bitmap)
region.finish()
whatever you draw should appear at 110,110 on the 1000x1000 bitmap
In your example with thispic0, you should first make thispic0 invalid before assigning it a new bitmap. You might even want to wait until you've called finish or swapbuffers and then unload the old bitmap and assign the new one, you might try both ways and see if one works better than the other.
RunGarbageCollector is not an asynchronous command, it usually (but not always) runs fast enough to be used within graphical applications. It really shouldn't be necessary to use it in the context you are working in.
- Joel
That