lundi 22 juin 2009

Sound on the Iphone

Having lot's of trouble gettting a good sound for my game on the iPhone, due to the special sound format. The Iphone explanation didn't help much, the code is clear, no it was the formatting.
I got a sound ending in a terrible noise, when played on the Iphone.

Finally i found the right links, explaining and suggesting the solution:
http://www.wooji-juice.com/blog/iphone-openal-ima4-adpcm.html

here something is told about the IMA4 format, and alos how to get it using the terminal window:

afconvert -f caff -d ima4 audiofile.wav

usinf this command i got a sound working normally in my game.

You have to know how to use the terminal in Mac OS (personally i am a Windows user :-)

here is a link explaining how to get in the right directory:

http://macapper.com/2007/03/08/the-terminal-an-introduction/

this amounts to:
opening the terminal using spotlight...
cd Desk*
cd FileWithSoundOnDeskTop
and then the command above afconvert

So in the end, all was already on my MACBOOK (with the double booth) only I had to find it...

have fun!