开发者

How to play 2 sounds simultaneously

I have to play 2 sounds in my app...one for background and one for when user clicks any button.....Not i have only one sound for background and too many sounds for that button click.....all sounds are in mp3 format....

I am using AVAudioPlayer to play 开发者_C百科these sounds...

My questions are

1- Can i play these 2 mp3 sounds at same time Or should i convert that background sound to any other format....

2- I am using AVAudioPlayer to play these sounds.....so can i use 2 instances of AVAudioPlayer in same class......

Please Note that i want that background music continuously playing.....

Please help....


1., Yes, you can even more..

2., Yes you can use AVAudioPlayer to play these, each sound source have to be allocated separately.

If you have short sounds that does not need to be stereo, you can use system sound framework to make them play.


Have a look to below look, will helpful for you.

2 mp3 sounds at the same time in iphone?

and blog tutorial

http://brainwashinc.wordpress.com/2009/08/14/iphone-playing-2-sounds-at-once/

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜