GP2X Using Sdl_mixer


Hi,

SDL_mixer work fine *.MOD and *.S3M but it is buggy with *.XM. I didnt tested with *.IT but i think it's like XM :(

Another thing, I never success to play a module directly from one header with SDL_mixer (I think it's another bug too)

Perhaps I will use another sound library ...
 
Sorry to keep banging on about this, but does anyone have a working SDL_mixer yet?

Thanks for any help that anyone can offer!
 
Hi guys,

Any update on how best to use SDL_mixer? (wich version, wich params...)

Mine keeps blackscreening immediately... I'm compiling on MacOSX, original version part of the pack or the version woogal posted right above.
All I'm doing is playing a mod... and then a few WAV on top with the code below... Any idea?
#include "SDL.h"
#include "SDL_mixer.h"
Mix_OpenAudio (22050, AUDIO_S16, 2, 4096);
...
Mix_PlayMusic( music , -1); //(a 4 channels mod)
...
Mix_PlayChannel(-1, soundfx, 0); //( a normal wav)

I must precise all the above works fine on Pc or Mac (or MorphOS) SDL...
Cheers!
JBB
 
jbb posted on Dec 30 2005 at 04:22 PM said:
Hi guys,

Any update on how best to use SDL_mixer? (wich version, wich params...)

Mine keeps blackscreening immediately... I'm compiling on MacOSX, original version part of the pack or the version woogal posted right above.
All I'm doing is playing a mod... and then a few WAV on top with the code below... Any idea?
#include "SDL.h"
#include "SDL_mixer.h"
Mix_OpenAudio (22050, AUDIO_S16, 2, 4096);
...
Mix_PlayMusic( music , -1); //(a 4 channels mod)
...
Mix_PlayChannel(-1, soundfx, 0); //( a normal wav)

I must precise all the above works fine on Pc or Mac (or MorphOS) SDL...
Cheers!
JBB

All of my games open the audio like this:
Code:
if(Mix_OpenAudio(MIX_DEFAULT_FREQUENCY, AUDIO_S16, MIX_DEFAULT_CHANNELS, 128) < 0) {
        printf("Unable to open audio!\n");
        exit(1);
  }
This works fine for oggs and wavs, but I've not tried any other format.

Then I do this:

Code:
  Mix_Chunk *pong = NULL;
  pong = Mix_LoadWAV("pong.wav");   // hit wall

And later on I do this:
Code:
  Mix_PlayChannel(-1, pong, 0);

Edited: Sorry, I meant to add that I was using theoddbot's version of SDL_mixer and the open2x compiler set.

Andrew
 
Last edited by a moderator:
Im sorry to revive an old dead thread.
But i cant get SDL_mixer to work, i get the "Could not create mixer lock" error.
I have tried the solutions in this thread, I have also searched the wiki and the rest of the dev forums for more information, but I cant find any solution to this problem.

Does anyone know the solution to this problem?

Info:
gcc ver 4.0.2
latest SDL & SDL_mixer libaries
SDL libaries installed on the gp2x (maybe this is the problem?)
compileing on WinXP pro.

Thanks!
 
For anybody with the same kind of problem as me, i found some kind of solution!

after some sens was smacked back into my head(thanks sjp!) i downloaded theoddbot's precomplied sdl libaries from the gp2x file archive and used those instead.
And whoala! i passed the init of sdl mixer!

also, thanks theoddbot for those libaries!
 
Back
Top