You are not logged in.

#1 2009-12-13 14:13:05

mnta
Member

[RESOLVED] Soundfiles

I know this might not be related to GRRLIB but couldn't resist asking (it is on this forum all the real experts are wink)..

I've used the sound example from the CodeMii tutorials and it works perfectly. No problems there (actually I dont have a problem - more a simple request).

I have found a nice website that allows free download of music saved in mod files (http://modarchive.org/). BUT!! Instead of using music in my wii application I want sound effects.

Do you guys know any websites where i can find free sound effects saved in mod? Or can i somehow play other files in my wii application like wav? (if the latter, do you have any guides or links i can read)

I've tried creating my own mod files in a audiotracker (or whatever it is called) but this is not an options since im not the new Mozart kind of guy..

Offline

 

#2 2009-12-13 15:02:45

mnta
Member

Re: [RESOLVED] Soundfiles

Just found the following links.

http://arikadosblog.blogspot.com/2009/0 … -with.html
http://forum.wiibrew.org/read.php?11,35472,page=1
http://forum.wiibrew.org/read.php?11,12616

Next time i will search before asking..  unless you have something else to add?

Offline

 

#3 2009-12-13 16:33:19

mnta
Member

Re: [RESOLVED] Soundfiles

I've got it to work by doing the following:

In your makefile - make sure you have the following LIBS 

Code:

LIBS := -lmodplay -lmad -lbte -lasnd // (and -lgrrlib  ofc ;-) + what ever else you need)

and you can add the following to autogenerate the .h files at compile time

Code:

#---------------------------------------------------------------------------------
%.mp3.o : %.mp3
#---------------------------------------------------------------------------------
    @echo $(notdir $<)
    @$(bin2o)

-include $(DEPENDS)

In your main.c or whatever class you are using include the following

Code:

#include <gcmodplay.h>
#include <asndlib.h>
#include <mp3player.h>
#include "giggle_mp3.h"

And int your code:

Code:

// INIT Functions
ASND_Init(NULL); 
MP3Player_Init();



// PLAY THE MP3
if(MP3Player_IsPlaying()) {
  MP3Player_Stop();
}
MP3Player_PlayBuffer(giggle_mp3,giggle_mp3_size,NULL);

Throw the Mp3s in the Data folder and compile. This does the trick for me and plays all the mp3s from the ram.

Last edited by mnta (2009-12-13 16:36:10)

Offline

 

Board footer

Powered by FluxBB