GP2X Glbasic


Racemaniac

Scorched GP programmer
Joined
Nov 3, 2003
Messages
587
Website
Visit site
i've been messing with glbasic a bit, i'll probably submit something for the contest, but i'm wondering a few things...
1. i compiled some basic things (lines getting drawn, sprites bouncing around) for the gp2x, sent it to someone with a gp2x, and all he gets is a black screen -_-. i've got the latest version of glbasic... is that normal?
2. i noticed glbasic uses floats for everything (and once you do the effort of making something an int, just about every function refuses to accept it), so can i expect any decent speed of it on the 2x?
 
The last update of GLBasic caused blackscreens if you used this -

CODE

Global info$=PLATFORMINFO$("device")



Use this instead -

CODE

GLOBAL info$
info$=PLATFORMINFO$("device")



This threw me in the last update, as it had been working properly before.

Obviously if you've not used that first bit, then I don;t know.

If you wish, you can send me your code, and I'll have a quick looksee - I own a F100, so I can easily check for problems :)

iprice AT supanet DOT com

GLBasic code is pretty nippy on GP2X, whether you use INTs or FLOATs, although I suppose it would depend on how much you're wanting to push around the screen. I've not found any problems with it (except for touchscreen support, which is now fixed).
 
i don't use that, but i just mailed you something i programmed, it would be nice if you checked it :)

i'm curious as to what glbasic will be capable of :).
 
I've just received you email - I'll check it now :)

[EDIT] Works well on pc and GP2X F100 - in fact, the GP2X version is faster than the pc version, both in the cursor movement and the explosions and is better as a result. :)
 
iprice said:
I've just received you email - I'll check it now :)

[EDIT] Works well on pc and GP2X F100 - in fact, the GP2X version is faster than the pc version, both in the cursor movement and the explosions and is better as a result. :)
hmm, the one i sent it to to test with, used open2x, maybe some incompatibility there :).
either that or i did something wrong with compiling it, but is that even possible with something like glbasic?
i'm gonna send you something else to test then :), with some more things happening on it, some more functions used :)
and why would it be faster? i made it for a framerate of 30, or will the 2x always go up to 60fps?

btw, who else is working with glbasic atm? you can always send me a pm, if you use windows live messenger, send me your e-mail, or ask for mine, and i'll add you ^^. would be nice to have some glbasic people on my msn (like i still got some fenix people on there :) )
 
Last edited by a moderator:
GP2X will go upto 60FPS quite happily.

I'm not sure why the GP2X version is faster (it's not a massive speed increase, but it is a welcome one). The cursor movement is certainly more fluid.

Achim is doing a GLBasic game (Muepp Muepp) and I believe quasist is working on something too. I'm not sure who else on here is though.
 
iprice said:
I believe quasist is working on something too

was working... it is ready and "hombrewing-fed" to gp2x.ru testers
 
Last edited by a moderator:
iprice said:
GP2X will go upto 60FPS quite happily.

I'm not sure why the GP2X version is faster (it's not a massive speed increase, but it is a welcome one). The cursor movement is certainly more fluid.

Achim is doing a GLBasic game (Muepp Muepp) and I believe quasist is working on something too. I'm not sure who else on here is though.
because i didn't know how fast the 2x would run it, i set the fps to 30, i can quite easily scale it up to 60 again if the gp2x is easily capable of what i'm trying ^^
 
Last edited by a moderator:
Hi Sven

I've just created a basic template for your explosion problems in GLBasic.

http://www.iprice.remakes.org/stuff/GLB_colour_change.rar

This code will load in a sprite image, then uses the PolyVector command multiple times to alter the colours of the sprite and grabs each image into individual sprites instantly.

This means you can now load in just one animation set for your explosions and use (a variant) of my code to create multiple colour explosion sets, without the slowdown associated with resizing the sprite.

Just a note - the loaded sprite, must be white with a masked edge of magenta RGB(255,0,128) as seen in my sprite. I've also set the screen to 320,240 - if your sprite animation is larger than 320 in length you can either make the screen larger (because the sprites are grabbed from the physical screen), or make them in rows eg.

Rather than this -


<-SCREEN->
XXXXXXXXXXXXXXX

Do this -

<-SCREEN->
XXXXX
XXXXX
XXXXX

Hope this helps with your game. :)
 
Back
Top