Hey I'm building an Piano App. Now I've got 12 Buttons and 12 different Tones.
Every tone is 2-3 seconds and if I play faster, every tone is played till it is on the end. So you have 2 Tone playing at the same time and that sounds very shitty.
So here is an example Code for 1 Button:
Code:
- (IBAction)H {
NSString *path = [[NSBundle mainBundle] pathForResource:@"h" ofType:@"wav"];
SystemSoundID soundID;
AudioServicesCreateSystemSoundID((CFURLRef) [NSURL fileURLWithPath:path], &soundID);
AudioServicesPlaySystemSound (soundID);
}
I hope you can help me.