iphone Programming Glossary: soundurl
Is it possible to play sounds without stopping iPod music? http://stackoverflow.com/questions/11036748/is-it-possible-to-play-sounds-without-stopping-ipod-music I'm using the following but it stops iPod music soundPath NSBundle mainBundle pathForResource @ mySound ofType @ mp3 soundURL NSURL fileURLWithPath soundPath mySound AVAudioPlayer alloc initWithContentsOfURL soundURL error nil mySound prepareToPlay.. @ mySound ofType @ mp3 soundURL NSURL fileURLWithPath soundPath mySound AVAudioPlayer alloc initWithContentsOfURL soundURL error nil mySound prepareToPlay and then mySound play iphone ios audio ipod share improve this question Yes you can..
AVAudioPlayer error loading file http://stackoverflow.com/questions/7290418/avaudioplayer-error-loading-file my button is pressed NSString soundPath NSBundle mainBundle pathForResource @ tick ofType @ caf NSError error NSURL soundURL NSURL fileURLWithPath soundPath AVAudioPlayer tickPlayer AVAudioPlayer alloc initWithContentsOfURL soundURL error error.. NSURL soundURL NSURL fileURLWithPath soundPath AVAudioPlayer tickPlayer AVAudioPlayer alloc initWithContentsOfURL soundURL error error tickPlayer setDelegate self tickPlayer setNumberOfLoops 0 tickPlayer prepareToPlay if tickPlayer nil NSLog @..
Sound not playing with AVAudioPlayer http://stackoverflow.com/questions/9963230/sound-not-playing-with-avaudioplayer BellViewController IBAction pushBell NSString soundPath NSBundle mainBundle pathForResource @ bell1 ofType @ caf NSURL soundURL NSURL fileURLWithPath soundPath NSError error AVAudioPlayer theAudio AVAudioPlayer alloc initWithContentsOfURL soundURL.. NSURL fileURLWithPath soundPath NSError error AVAudioPlayer theAudio AVAudioPlayer alloc initWithContentsOfURL soundURL error error theAudio setDelegate self theAudio setNumberOfLoops 0 theAudio play @end And I have a button in my .xib that.. viewDidLoad super viewDidLoad NSString soundPath NSBundle mainBundle pathForResource @ beep beep ofType @ caf NSURL soundURL NSURL fileURLWithPath soundPath NSError error nil self.theAudio AVAudioPlayer alloc initWithContentsOfURL soundURL error..
|