¡@

Home 

2014/10/15 ¤U¤È 10:04:02

iphone Programming Glossary: asound

Sound stop playing [duplicate]

http://stackoverflow.com/questions/8094557/sound-stop-playing

one the sounds overlap. How can I fix that so the first sound stops when another one is pressed void playOnce NSString aSound NSString path NSBundle mainBundle pathForResource aSound ofType @ caf AVAudioPlayer theAudio AVAudioPlayer alloc initWithContentsOfURL.. stops when another one is pressed void playOnce NSString aSound NSString path NSBundle mainBundle pathForResource aSound ofType @ caf AVAudioPlayer theAudio AVAudioPlayer alloc initWithContentsOfURL NSURL fileURLWithPath path error NULL theAudio.. theAudio setDelegate self theAudio setNumberOfLoops 0 theAudio setVolume 1.0 theAudio play void playLooped NSString aSound NSString path NSBundle mainBundle pathForResource aSound ofType @ caf AVAudioPlayer theAudio AVAudioPlayer alloc initWithContentsOfURL..

iPhone - Sound overlapping with multiple button presses

http://stackoverflow.com/questions/8101870/iphone-sound-overlapping-with-multiple-button-presses

one the sounds overlap. How can I fix that so the first sound stops when another one is pressed void playOnce NSString aSound NSString path NSBundle mainBundle pathForResource aSound ofType @ caf AVAudioPlayer theAudio AVAudioPlayer alloc initWithContentsOfURL.. stops when another one is pressed void playOnce NSString aSound NSString path NSBundle mainBundle pathForResource aSound ofType @ caf AVAudioPlayer theAudio AVAudioPlayer alloc initWithContentsOfURL NSURL fileURLWithPath path error NULL theAudio.. theAudio setDelegate self theAudio setNumberOfLoops 0 theAudio setVolume 1.0 theAudio play void playLooped NSString aSound NSString path NSBundle mainBundle pathForResource aSound ofType @ caf AVAudioPlayer theAudio AVAudioPlayer alloc initWithContentsOfURL..