SDL update

The current CVS version of SDL now updates the internal event state
before calling the filter function. This was needed by Myth2.

I also fixed the Voodoo cursor bug, finally.

Something to be aware of, SDL_Init(SDL_INIT_AUDIO) will fail if it can’t
open a soundcard. This is changed from the old behavior of always
succeeding.–
-Sam Lantinga, Lead Programmer, Loki Entertainment Software

Just wondering, how is SDL used on a 3d accelerated game like Myth2? Isn’t
SDL mostly just 2D blitting and stuff?

-Garrett, WPI student majoring in Computer Science
"The fastest way to succeed is to look as if you’re playing by somebody
else’s rules, while quietly playing by your own." -Michael KondaOn Wed, 01 Mar 2000, you wrote:

The current CVS version of SDL now updates the internal event state
before calling the filter function. This was needed by Myth2.

In article <00030120292000.06211 at mongoose>,
Garrett writes:> On Wed, 01 Mar 2000, you wrote:

The current CVS version of SDL now updates the internal event state
before calling the filter function. This was needed by Myth2.

Just wondering, how is SDL used on a 3d accelerated game like Myth2? Isn’t
SDL mostly just 2D blitting and stuff?

-Garrett, WPI student majoring in Computer Science
"The fastest way to succeed is to look as if you’re playing by somebody
else’s rules, while quietly playing by your own." -Michael Konda

SDL is not only 2D since OpenGL support has been introduced in 1.1 :wink:

Well actually for Myth II, Glide is used for accelerated 3D, and we mostly
don’t use the SDL surface for any 2D output (since there really isn’t any).
Yet SDL still is useful because it still does all the event processing
(mouse and keyboard), and also sounds, etc …


Stephane Peter
Programmer
Loki Entertainment Software

“Microsoft has done to computers what McDonald’s has done to gastronomy”

Garrett wrote:

The current CVS version of SDL now updates the internal event state
before calling the filter function. This was needed by Myth2.

Just wondering, how is SDL used on a 3d accelerated game like Myth2? Isn’t
SDL mostly just 2D blitting and stuff?

Input/ Sound/ Threads/ Window management (fullscreen …)> On Wed, 01 Mar 2000, you wrote:


Daniel Vogel My opinions may have changed,
666 @ http://grafzahl.de but not the fact that I am right

On Wed, 01 Mar 2000, Sam Lantinga wrote :

Something to be aware of, SDL_Init(SDL_INIT_AUDIO) will fail if it can’t
open a soundcard. This is changed from the old behavior of always
succeeding.

So if we are init’ing both video and audio, we should test like this:
if ( SDL_Init ( SDL_INIT_VIDEO | SDL_INIT_AUDIO ) != 0 ) {
/* Unable to init either sound or video, try doing just video /
if ( SDL_Init ( SDL_INIT_VIDEO ) {
/
Darn, neither audio or video could be initialized. /
exit ( 1 );
} else {
/
We can continue, just without audio /
audio_flag = FALSE;
}
} else {
/
Goody, we get both audio/video */
audio_flag = TRUE;
}

Is the logic correct? If we can’t init either video or audio, SDL_Init will
return a non-zero? Pretty cool. Or, I was just thinking (dangerous, I
know), perhaps there is a “global” error variable we could check (kinda like
errno)?

cheers,
Dave “PenguinDude” Archbold
@Dave_Archbold

So if we are init’ing both video and audio, we should test like this:
if ( SDL_Init ( SDL_INIT_VIDEO | SDL_INIT_AUDIO ) != 0 ) {
/* Unable to init either sound or video, try doing just video /
if ( SDL_Init ( SDL_INIT_VIDEO ) {
/
Darn, neither audio or video could be initialized. /
exit ( 1 );
} else {
/
We can continue, just without audio /
audio_flag = FALSE;
}
} else {
/
Goody, we get both audio/video */
audio_flag = TRUE;
}

Oops. The second ‘if’ statement should read
if ( SDL_Init ( SDL_INIT_VIDEO ) != 0 )

Like the first ‘if’ but without the ‘SDL_INIT_AUDIO’ flag. Sorry y’all.

cheers,
Dave “PenguinDude” Archbold
@Dave_ArchboldOn Wed, 01 Mar 2000, Dave Archbold wrote: