Open ajusa opened 2 years ago
Further update - I tried install SDL_mixer directly from the official website and I was able to get the C example working. The nim example however gives me
libSDL_mixer.so: cannot open shared object file: No such file or directory
could not load: libSDL_mixer.so
libSDL_mixer.so is inside my /usr/lib
directory, so I'm not sure why it can't find it...
I'm not 100% sure this is related to the binding, but I'm also not really sure why I can't get this to work.
When I use https://github.com/nim-lang/sdl2/blob/master/src/sdl2/mixer.nim, I am able to play an mp3 file. With the exact same code, but using the sdl_mixer in this repository, I get
Unrecognized music format
printed out. I believe this means I have all of the dynamic libraries properly installed and configured, otherwise I wouldn't be able to get SDL2 to work.EDIT: I tried reproducing a similar example in C, and noticed the
Mix_Init
function (which this wrapper omits, but the SDL2 wrapper has this function). After running that and checking for errors, I getMix_Init: Mixer not built with MP3 support
. Not sure if this is solvable on the end of this wrapper, but I'm also not sure if theMix_Init
function needs to be wrapped.