Bug or not?

Previous topic - Next topic

mr_x

Sorry if this is not a bug, but I've got the following problem: when I play my game on PocketPC too long, it begin to not load different resources, images and animations in particular. I mean that instead of background image, there is a black screen or something like that. I think it happens because, when I try to free memory (load non existed data or load another data in the same image ID), the previous data not fully erased, and thus my PPC start to have very low amount of RAM and can't load nothing any more. Or maybe there is something wrong with my device.
Here is small example. Left button - load background, right button-free memory. I've got very weak PPC and thus it stops load image after abut six times of loading/freeing data. And forgive me for my english.

[attachment deleted by admin]

Kitty Hello

That image is really big. Does it happen with smaller images, too?
Would be bad :s

mr_x

#2
I'm afraid - yes. With two images with resolution 240x320 it takes me 100 times of loading data to get this bug appear again. But there is a possibility, that there is something wrong with my PPC, because it fell in the water few days ago =D So it would be nice, if someone else will confirm this bug.

Kitty Hello

try the pocketpc emulator.

mr_x

I can't run GlBasic programm in emulator, when I try to run it, emulator freeze. This is the first time when I try to use emulator, so maybe I did something wrong. But the Pocket Fallout works in the emulator, but very-very slow. I use Microsoft Windows Mobile 5.0 MSFP.

Kitty Hello

I use a PocketPC2003 emulator (MS, yes). Might be your computer is too weak.

mr_x

#6
I install Windows Mobile 6 Emulator, and in this emulator all GLBaic programms works, so there is some incompatibility with WM 5 emulator. And another bad news is that this bug appear in the emulator too.

EDIT Schranz0r (your double-post):

I don't know why, but now GlBasic programs works in the WM 5 emulator too.

Kitty Hello

#7
Code (glbasic) Select

LOCAL i%

main:
IF MOD(i,2)=0
LOADBMP "back.bmp"
ELSE
BLACKSCREEN
ENDIF

PRINT i, 0,0
INC i, 1
SHOWSCREEN

MOUSESTATE mx, my, b1, b2
IF b1 OR KEY(01) THEN END
GOTO main

SHOWSCREEN
MOUSEWAIT


Yes, I can confirm that bug now.
:S
I'll see why it happens.


[edit]
ONLY happens on PocketPC after >1000 iterations for me. WIZ e.g. works. It seems that the PocketPC memory management fragments quickly and yields this error. Does that happen to your application really? Maybe you should use LOADSPRITE once instead of LOADBMP, and keep that image in memory instead of realoading. It's very strange, since it's the same code on both machines, and the WIZ has 12000 iterations already.

mr_x

Sorry for troubling you so much, i thought that this was memory leaking somewhere in the glbasic, but if this is because of PocketPC, then I will try to do like you said.