[SDL] "Mix_LoadMUS" for Android
Jonathan Dearborn
grimfang4 at gmail.com
Wed Nov 23 18:59:42 PST 2011
There is Mix_LoadMUS_RW(). I haven't ever used it, so I'm not sure if it
automatically supports the variety of formats that Mix_LoadMUS() does.
Here's an old GPwiki article for WAV using Mix_LoadWav_RW():
http://content.gpwiki.org/index.php/SDL_mixer:Tutorials:Playing_a_WAV_Sound_from_a_Custom_Resource_File_using_SDL_RWops
Jonny D
On Wed, Nov 23, 2011 at 7:16 PM, Jeremy Jurksztowicz <jurksztowicz at gmail.com
> wrote:
> Not sure what you mean, here is the example from the SDL_mixer docs:
>
> // load the MP3 file "music.mp3" to play as music
> Mix_Music *music;
> music=Mix_LoadMUS("music.mp3");
> if(!music) {
> printf("Mix_LoadMUS(\"music.mp3\"): %s\n", Mix_GetError());
> // this might be a critical error...
> }
>
>
> If you're having trouble loading a file, perhaps the coded is not built
> into SDL_Mixer? I just had to jump through hoops to get OGG support under
> Mingw (couldn't get SMPEG to compile), so you might want to take a look at
> the build logs to see exactly what support is in your version of SDL_mixer.
>
> Cheers.
>
> On Tue, Nov 22, 2011 at 11:06 PM, wilbefast <wilbefast at gmail.com> wrote:
>
>> **
>> As discussed previously <http://forums.libsdl.org/viewtopic.php?t=7692>,
>> IMG_Load can access files in **/assets/ via RWops. I also hacked
>> together a system for loading XML files and passing them to TinyXML. Now
>> I'm working on music, but Mix_LoadMUS doesn't seem to work the way IMG_Load
>> does. I think I'll need to load the files manually using RWops, as with XML
>> - trouble is music is not like text: I'm not sure quite how to handle it.
>> Any advice?
>>
>> Thanks,
>>
>> William
>>
>> _______________________________________________
>> SDL mailing list
>> SDL at lists.libsdl.org
>> http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
>>
>>
>
> _______________________________________________
> SDL mailing list
> SDL at lists.libsdl.org
> http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20111123/7a68de31/attachment.htm>
More information about the SDL
mailing list