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

David Olofson david at olofson.net
Sun Aug 27 13:18:16 PDT 2006


On Sunday 27 August 2006 21:18, Torsten Giebl wrote:
[...]
> I have not tested it but a software OpenGL impl. with Mesa only
> using Textures and only blitting small Nr. of Polygons with these
> textures maybe also fast. Especially on newer powerfull systems.

I dunno'... Ok performance in 3D games, considering the feature set 
and output quality, but unless there are shortcuts triggered by 
simpler transformations (for which I see no reason, considering it's 
really meant for 3D), I don't see how this could ever come close to
the frame rates you get with the SDL 1.2 software blitters.

Probably ok for rendering of static backgrounds on reasonably fast 
computers, but a real time software rasterizer is a different matter 
entirely. By all means, it *is* doable, but even plain blits without 
scaling is quite a bit of work if you want performance on the 
machines that really need it: the low end ones without proper video 
cards.


> Windows Vista for example has even with only D3D drivers
> an OGL emulator.

AFAIK, the "emulator" is actually a wrapper for accelerated Direct3D. 
Should be nearly as fast as "real" accelerated OpenGL, unless it's 
deliberately crippled.


[...]
> Sure. For me that is no question. SDL 1.3
> has to do the same things in Direct 3D than in OpenGL for the simple
> 2D blitting stuff and uploading of Textures and so on.

Yeah... So, I suppose some kind of well defined way of plugging 
extensions in without messing up SDL rendering would be a sensible 
way of doing it. (Unlike glSDL, where you're not really supposed to 
mess with the OpenGL state while using glSDL.)


> The Video Part of SDL 1.3 has the 2D loading and blitting functions
> using Textures and the rest the user has to implement. That would be
> my personal way for SDL 1.3 I want a lib that easysily sets up D3D
> and/or OGL for me, delievers events and so on and i code the 3d
> engine stuff.

Makes sense.


> When i need things like rotation for 2D or other things that SDL not
> has, that i can use an add. SDL helper lib.

Yes. Of course, these helper libs will have to deal with specific 
support for backends based on different APIs, but that's acceptable, 
and probably the only sensible way of doing it, as it is.


//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  --'




More information about the SDL mailing list