Re: Simplest way to generate audio tones?

2016-05-28 Thread Jonathan Hull
Here it is for iOS (I assume that this is low-level enough that it is almost the same cross-platform): https://developer.apple.com/library/ios/documentation/AudioVideo/Conceptual/MultimediaPG/UsingAudio/UsingAudio.html#//apple_ref/doc/uid/TP40009767-CH2-SW6 My first thought would be to either cre

Re: Simplest way to generate audio tones?

2016-05-28 Thread Graham Cox
Probably should have mentioned this is Mac, not iOS. Yes, there are Audio Units, but they’re not really what I’m after. You can’t simply create a generator audio unit and use it in an app to generate tones (as far as I’m aware) - it has to be part of the whole Core Audio signal chain. I’m looki

Re: Simplest way to generate audio tones?

2016-05-28 Thread Jonathan Hull
This is way out of my area of expertise, but it appears you want AudioUnits: http://www.cocoawithlove.com/2010/10/ios-tone-generator-introduction-to.html Thanks, Jon > On May 28, 2016, at 8:24 PM, Graham Cox wrote: > > Hi all, > > I’m looking for general pointers to the simplest/quickest way

Re: When can String.enumerateSubstringsInRange ever pass in NIL?

2016-05-28 Thread Ken Thomases
On May 28, 2016, at 8:27 PM, Daryle Walker wrote: > > The last argument to the method is a closure with four parameters. The first > argument is an optional String. I can't think of a circumstance where it'll > be NIL. (I need to know for testing.) Especially since it can be recreated in > ter

Simplest way to generate audio tones?

2016-05-28 Thread Graham Cox
Hi all, I’m looking for general pointers to the simplest/quickest way to generate an audio tone (sine wave) of a given frequency and duration. Most of the audio APIs seem concerned with playing samples rather than generating tones, so it’s not immediately obvious where to look. —Graham

When can String.enumerateSubstringsInRange ever pass in NIL?

2016-05-28 Thread Daryle Walker
The last argument to the method is a closure with four parameters. The first argument is an optional String. I can't think of a circumstance where it'll be NIL. (I need to know for testing.) Especially since it can be recreated in terms of the callback's second argument, which isn't optional. (S