SDL looks cool... can I ask a couple questions?

I’m looking at building a simple (mostly 2-d graphics,
some backround and event audio, and a few stock animations)
game and I want it to be portable from unix to microsatan.

Question 1:

I'm confused about SDL's unix implementation. Is it
on top of X, or directly on top of the hardware, or
both? (I assume that on windows it's either on the
hardware or on directx)

Question 2:

There seem to be a BUNDLE of OS-independent graphical
and support (audio/kbd/mouse) libraries out there.
Why is SDL the "right one"?

-Jeff Evarts, aspiring game writer.

I’m looking at building a simple (mostly 2-d graphics,
some backround and event audio, and a few stock animations)
game and I want it to be portable from unix to microsatan.

Question 1:

I’m confused about SDL’s unix implementation. Is it
on top of X, or directly on top of the hardware, or
both? (I assume that on windows it’s either on the
hardware or on directx)

On UNIX, it runs either X11, or in the case of XFree86 fullscreen mode,
directly on top of the hardware using the DGA extension.

On Windows, it runs on either GDI, or DirectX – your choice at runtime.

On BeOS, it runs in a BView… with support for BDirectWindow eventually.

Question 2:

There seem to be a BUNDLE of OS-independent graphical
and support (audio/kbd/mouse) libraries out there.
Why is SDL the “right one”?

As a disclaimer, it is not necessarily “the right one” – it depends on
what your needs are, and what you are comfortable with.

Having said that, I like working with SDL because:

1.  It's simple
2.  It's fast.. it's low level enough that it gets out of your way
    and lets you exploit the speed of the underlying interface.
3.  You can write games in one source file.
4.  There are lots of examples and documentation
5.  It has an active development and discussion community.

If you want to talk to people who use it, join the SDL developer’s
mailing list – send mail to sdl-subscribe at surfnetcity.com.au, and enjoy! :slight_smile:

See ya!
-Sam Lantinga (slouken at devolution.com)–
Author of Simple DirectMedia Layer -
http://www.devolution.com/~slouken/SDL/

Sam Lantinga writes:

I’m looking at building a simple (mostly 2-d graphics,
some backround and event audio, and a few stock animations)
game and I want it to be portable from unix to microsatan.

Question 1:

I'm confused about SDL's unix implementation. Is it
on top of X, or directly on top of the hardware, or
both? (I assume that on windows it's either on the
hardware or on directx)

On UNIX, it runs either X11, or in the case of XFree86 fullscreen mode,
directly on top of the hardware using the DGA extension.

On Windows, it runs on either GDI, or DirectX – your choice at runtime.

On BeOS, it runs in a BView… with support for BDirectWindow eventually.

Question 2:

There seem to be a BUNDLE of OS-independent graphical
and support (audio/kbd/mouse) libraries out there.
Why is SDL the "right one"?

As a disclaimer, it is not necessarily “the right one” – it depends on
what your needs are, and what you are comfortable with.

Having said that, I like working with SDL because:

  1. It’s simple
  2. It’s fast… it’s low level enough that it gets out of your way
    and lets you exploit the speed of the underlying interface.
  1. You can write games in one source file.

this is an ADVANTAGE? i think not…who would want a game in one
source file ? Or am I taking this wrong?

j

You’re taking that wrong. By one source file, he means one souce TREE.
e.g. you don’t need to do major source re-working to port it to a
different platform.On 19 Aug, Jeff wrote:

this is an ADVANTAGE? i think not…who would want a game in one
source file ? Or am I taking this wrong?


| |/ | | | _ | | | mailto:@Knight_Walker |
| / | / / | | http://www.aros.net/~kwalker |
| \ | ___ | | |
| |\ | | / \ | | The Kobran Imperium (801)265-1299 |
|| || || || _____________________________________/

Er, yem, yeah! That’s what I meant.

I just meant that you could write some useful code without using a
ton of support code to get it done. The FLI player is a nice testament
to that. I looked at that sentence twice before I sent it, but
I was feeling a little silly so I let it go. :slight_smile:

Of course, you can always write a ton of support code if you want to. :slight_smile:

See ya!
-Sam Lantinga (slouken at devolution.com)> On 19 Aug, Jeff wrote:

this is an ADVANTAGE? i think not…who would want a game in one
source file ? Or am I taking this wrong?

You’re taking that wrong. By one source file, he means one souce TREE.
e.g. you don’t need to do major source re-working to port it to a
different platform.


Author of Simple DirectMedia Layer -
http://www.devolution.com/~slouken/SDL/

3.  You can write games in one source file.

this is an ADVANTAGE? i think not…who would want a game in one
source file ? Or am I taking this wrong?

It’s a big advantage if you are trying to write one of those pong in < 150
bytes type competitions… :slight_smile:

I think sam really means one source tree. (without writting separate code
for each platform)

njh