[SDL] 2D API evolution (SDL 1.3/2.0)

Asmodehn Shade asmodehn at gmail.com
Tue Aug 15 15:18:22 PDT 2006


Hi everyone,

I find this discussion going on very instructive ;) And to add more mess, I thought I ll share my thoughts :-p

I am developing myself an application using SDL 1.2, and I started to wrap it and I expect to provides more "abstract" functionnalities with 2 libraries later on : one for 2D features, and one for 3D. Those libraries will be aimed at developing games.
So I had the same problem than this one, to be able to draw a line between 2D and 3D feature, from a computer game point of view, and deal with the feature, available or not in SDL 1.2.

To draw the line, I didnt make any optimisation consideration, as I think those are endless... and I didnt make any portability consideration either, as on the 2D side I rely in SDL ;) thanks to you guys, and on the other, I rely on OpenGL only ( just an simplicity choice here, forgetting all non graphic stuff )

Instead I just thought a bit theoritically to what a user might think when you say 2D or 3D game... and what I - as a game developer - would expect from a library.

So I thought I d tell you where I draw the line.
Anyway here we go, with an importance indicator, everything from my own opinion.

2D Expected Features    Important ? 1 mandatory -> 5 doesnt care
Pixel Upload 		2
Bitmap Upload		1
ColorKey		1
Alpha			2
Color space Mgmt	3
Copy Blit		1
Zoom			2 (uniform scale)
Mirror			3
90° Rotation		3
Free Rotation		4
Stretch			4 (non uniform scale)
Filtering		5


I will also provides hooks to GUIs lib, and some other stuff, but for what SDL is concerned, I decided to forget about stuff noted >= 4 (add on libs or custom devs needed)
The rest of the feature will be run on top of SDL ( portability ) or on top of OpenGL if somebody wants performance with a 'global' dynamic switch available.

I know that for SDL the problem is a bit different, and I dont think this is worth anything, but I thought you might find that interesting.
Actually, I think I 'kind of' match what Sam decided for SDL 1.3.  :D lucky me. I still have to have a look at the 1.3 API tho...

IMHO, A "Media" library like SDL is not a "drawing" library, and optimisation capabilities should prevail on features that are not use heavily in multimedia development.

Regards, thanks and good luck for SDL 1.3 ;)

--
Asmodehn

On Tue, 15 Aug 2006 19:37:21 +0200
David Olofson <david at olofson.net> wrote:

> On Tuesday 15 August 2006 17:41, Bob Pendleton wrote:
> [...]
> 
> Question is still, how far is the new SDL 2D API supposed to reach, 
> before it's time to switch to a 3D API? And what 3D API do we switch 
> too? (Obviously, OpenGL and/or Direct3D, if you really need the 
> latest stuff.) Do we even need two different APIs for 2D and 3D? What 
> is to be part of SDL, and what's better implemented as add-on 
> libraries?
> 
> 
> //David Olofson - Programmer, Composer, Open Source Advocate
> 
> .-------  http://olofson.net - Games, SDL examples  -------.
> |        http://zeespace.net - 2.5D rendering engine       |
> |       http://audiality.org - Music/audio engine          |
> |     http://eel.olofson.net - Real time scripting         |
> '--  http://www.reologica.se - Rheology instrumentation  --'
> 
> _______________________________________________
> SDL mailing list
> SDL at libsdl.org
> http://www.libsdl.org/mailman/listinfo/sdl




More information about the SDL mailing list