I play like this:
#import <AudioToolbox/AudioToolbox.h> #import <AVFoundation/AVFoundation.h> .. .. SystemSoundID soundID; NSString *path = [[NSBundle mainBundle] pathForResource:@"ClickSound" ofType:@"wav"]; AudioServicesCreateSystemSoundID((CFURLRef)[NSURL fileURLWithPath:path],&soundID); AudioServicesPlaySystemSound (soundID);
This seems to be the volume from the βRingerβ, but when I use the physical volume button, it controls the βVolumeβ (so I can βMuteβ the volume, but I still hear the sound).
I want to control the correct volume, and I do not want it to play when it was turned off (BTW - when I use mute toggle, it works, and I can not hear the sound).
How can i fix this?
Dizzy source share