音频的播放
首先,需要导入AudioToolbox.framework库,然后在实现文件中引入进来:
?
?当按钮按下时进行调用:?- (IBAction) btnPressed{[self performSelector:@selector(playSound) withObject:nil afterDelay:.5];}
当按钮按下时进行调用:
- (IBAction) btnPressed{[self performSelector:@selector(playSound) withObject:nil afterDelay:.5];}