SDL without video

Hi all,

Subject says it all really… it looks as though it’s possible to
just use SDL for audio - is this the case ?

Would it be as simple as:

if ( SDL_Init(SDL_INIT_AUDIO) < 0 )
{
fprintf(stderr, “Couldn’t initialize SDL: %s\n”, SDL_GetError());
exit(1);
}

ATB,
Simon.

Hi all,

Subject says it all really… it looks as though it’s possible to
just use SDL for audio - is this the case ?

Yup.

if ( SDL_Init(SDL_INIT_AUDIO) < 0 )
{
fprintf(stderr, “Couldn’t initialize SDL: %s\n”, SDL_GetError());
exit(1);
}

That’s right. :slight_smile:

-Sam Lantinga, Lead Programmer, Loki Entertainment Software