Subject - Problems with SDL_mixer 1.2.6 on WinXP

Hi folks,

The problem seems to be the Mix_OpenAudio() function call, which just
hangs the application for no apparent reason.

I’ve enclosed some source code which faitfully reproduces the problem on
my system, and some information about my environment.

If anyone has encountered similar problems, I would be most gratefull
for their assistance.

Thanks in advance–
Alan McFarlane

[CODE filename=“main.c”]

/*

  • Compile with:
  • gcc -W -Wall -Werror
  • -I/usr/local/include/SDL
    
  • -L/usr/local/lib
    
  • -Dmain=SDL_main
    
  • -o sample.exe
    
  • main.c
    
  • -lmingw32 -lSDLmain -lSDL_mixer -lSDL
    
  • -mwindows
    

*/

#include <stdlib.h>
#include “SDL.h”
#include “SDL_mixer.h”

int main( int argc, char* argv[] )
{
(void)argc;
(void)argv;

if (SDL_Init(SDL_INIT_VIDEO | SDL_INIT_TIMER) < 0)
{
	fprintf(stderr, "SDL_Init() failed -- %s\n", SDL_GetError());

	exit(EXIT_FAILURE);
}

atexit(SDL_Quit);

if (SDL_InitSubSystem(SDL_INIT_AUDIO) < 0)
	fprintf(stdout, "SDL_InitSubSystem() failed -- %s\n", SDL_GetError());
else if (Mix_OpenAudio(MIX_DEFAULT_FREQUENCY, MIX_DEFAULT_FORMAT, 

MIX_DEFAULT_CHANNELS, 4096) < 0)
fprintf(stdout, “Mix_OpenAudio() failed – %s\n”, Mix_GetError());

atexit(Mix_CloseAudio);

/* Main Program ... */

return 0;

}

[/CODE]

I’m running MSys/MinGW on top of Windows XP Professional.
The output of msysinfo is as follows:

MSYS 1.0.10(0.46/3/2) 2004-03-15 07:17 i686 unknown; targ=MINGW32
GNU bash, version 2.04.0(1)-release (i686-pc-msys); ENV=.profile
GNU Make version 3.79.1,Built for i686-pc-msys; MAKE_MODE=unix
gcc.exe (GCC) 3.4.2 (mingw-special); targ=MINGW32
GNU ld version 2.15.91 20040904
789320 Tue Mar 16 12:32:49 2004 /bin/msys-1.0.dll
135680 Tue Mar 16 12:32:48 2004 /bin/make.exe
88064 Tue Sep 21 09:15:22 2004 /mingw/bin/gcc.exe
642048 Sun Sep 05 00:45:43 2004 /mingw/bin/ld.exe
HOME=/home/Alan
Sysname=MINGW32_NT-5.1 OSTYPE=msys TERM=msys
PATH=.:/usr/local/bin:/mingw/bin:/bin:/c/WINDOWS/system32:/c/WIN
DOWS:/c/WINDOWS/System32/Wbem:/c/Program Files/Support Tools/

I’m using SDL-1.2.9 configured with --prefix=/usr/local
and SDL_mixer-1.2.6 configured with --prefix=/usr/local

BTW, I’ve tried the ‘loopwave’ test from the SDL test folder, which
works correctly, which is why I suspect a problem with SDL_mixer.

BTW, I’ve tried the ‘loopwave’ test from the SDL test folder, which
works correctly, which is why I suspect a problem with SDL_mixer.

How about playwave.c in the SDL_mixer package? Does that work?

–ryan.

Hello !

BTW, I’ve tried the ‘loopwave’ test from the SDL test folder, which
works correctly, which is why I suspect a problem with SDL_mixer.

How about playwave.c in the SDL_mixer package? Does that work?

I have also a problem with SDL_mixer but on Mac OSX,
under Win XP it works great.

I am using OSX Tiger with all the latest Updates
and all the latest SDL CVS versions. loopwave from
SDL works perfect, but using the playmus that comes
with SDL_mixer works not. I tried to play an IT module,
but don `t get any sound output.

On WinXP exactly the same IT module works without any problems.

CU

Ryan C. Gordon wrote:

BTW, I’ve tried the ‘loopwave’ test from the SDL test folder, which
works correctly, which is why I suspect a problem with SDL_mixer.

How about playwave.c in the SDL_mixer package? Does that work?

–ryan.

It does indeed work. It appears that my original compilation of
SDL_mixer had a problem which (after re-compilation) has vanished.

Thanks folks