Qbasicnews.com

Full Version: glSDL test..
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Okay, it's not a project, anyways..

Here is the glSDL test, run the demo using -gl later to see the speed hit when using the SDL alpha blending routines instead of the OpenGL ones - 670 FPS here using GL and 92 using SDL: http://www.freebasic.net/temp/glsdl_test.zip

Too bad the glSDL project seems to be abandoned, if someone could continue his work.. scaled+rotated+alpha-blended sprites at 600+ FPS would be great - BlitzMax will have a GL2D module, we need one too :P.
Some months ago I was also playing with that lib (In C Not FB) and really the speed differences ara abysmal. I believe It would be nice if you can include the glSDL.c and glSDL.h you use on the package because the version I found on the Net doesn't have references to glSDL_IMG_Load function (I found 0.7 but read the last one is 0.7.1)

TioBit

Edit : No way,... The 0.7 have the IMG function and probably is the one you use.
isn't the offical SDL group look at building a OpenGl backend ?
That's what the glSDL site says.. but i couldn't find anything in the SDL CVS, dunno..
hmm be cool if somone did take up the challenge of completing glSDL. maybe somone like rel could do it Smile
Considering this lib will be mainly used for 2D games , I remember that also there was an issue with the collision system ( I believe glSDL cannot read screen surfaces - but not sure of this)
GL lets you read textures from VRAM, but it does a full copy, what can be very slow.. reading a pixel at time would be painful slow, course.
you could keep the a bitmasks in system memorey to do pixel perfect collistion.
I just discovered an alternative: AllegroGL.

It's still in active development (unlike glSDL), and judging from the documentation it seems a little more mature too.

And it appears lillo is/was an AllegroGL developer! I can't believe he didn't mention AllegroGL when we were talking about glSDL.
Yes, I coded the MacOS X port of AllegroGL.

Anyway the development is somewhat stalled, don't think it's advancing much. And let me also clarify a thing: AllegroGL tries to emulate all Allegro 2d functionalities via OpenGL. Well, this is a bad hack IMO: Allegro was meant for software 2d many years ago, and trying to fit OpenGL inside it is like trying to fit a square into a circle.
Currently Allegro is striving to change its own API in order to be more modern and also properly support OpenGL...
AllegroGL was never really integrated as part of the core Allegro because it was never really finished and completely bug free.

IMO what we'd need would be a thin layer that'd provide sprites handling and little more using OpenGL. Not worth to link all Allegro+AllegroGL just for this...
Pages: 1 2