ios 音量调节的问题

ocwind 2012-08-23 02:54:29
if (!m_reqfloorSoundID) {
NSString *floorSoundPath = [[NSBundle mainBundle] pathForResource:@"req_floor" ofType:@"wav"];
NSURL *floorSoundURL = [NSURL fileURLWithPath:floorSoundPath];
AVAudioPlayer *floorSoundPlayer = [[AVAudioPlayer alloc] initWithContentsOfURL:floorSoundURL error:nil];
[floorSoundPlayer prepareToPlay];
AudioServicesCreateSystemSoundID((CFURLRef)floorSoundURL, &m_reqfloorSoundID);
[floorSoundPlayer release];
}
//播放提示音
AudioServicesPlaySystemSound(m_reqfloorSoundID);

我是用上面的方法播放提示音,但是为什么不能用iphone自带的调节音量来调节声音大小呢????
...全文
360 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
ocwind 2012-08-23
  • 打赏
  • 举报
回复
[Quote=引用 1 楼 的回复:]
怎么会?你把手机的声音关了,难道你播放的声音还在?
[/Quote]
恩,是的!
Proteas 2012-08-23
  • 打赏
  • 举报
回复
怎么会?你把手机的声音关了,难道你播放的声音还在?

29,027

社区成员

发帖
与我相关
我的任务
社区描述
主要讨论与iOS相关的软件和技术
社区管理员
  • iOS
  • 大熊猫侯佩
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧