Important: Inside Macintosh: Sound is deprecated as of Mac OS X v10.5. For new audio development in Mac OS X, use Core Audio. See the Audio page in the ADC Reference Library.
Application-Defined Routines
The Speech Manager allows you to define callback procedures that execute
- when text input processing is complete (but not necessarily after speech has stopped)
- when text has been completely processed and spoken
- whenever the Speech Manager encounters an embedded synchronization command
- whenever the Speech Manager encounters an error in processing embedded speech commands
- whenever a phoneme is about to be spoken
- whenever a word is about to be spoken
- WARNING
- When the Speech Manager executes a callback procedure, the Speech Manager sets the A5 register to the value specified by the most recent call to the
SetSpeechInfo
function with thesoCurrentA5
selector. However, if the most recent value specified with thesoCurrentA5
selector isNIL
or if your application has not yet specified a value, then the Speech Manager leaves the A5 register unchanged. In this case, the callback procedure cannot access application global variables because it executes at interrupt time. For code showing how to use thesoCurrentA5
selector to ensure that the A5 register is set to your application's A5, see Listing 4-6 on page 4-21.
Subtopics
- Text-Done Callback Procedure
- Speech-Done Callback Procedure
- Synchronization Callback Procedure
- Error Callback Procedure
- Phoneme Callback Procedure
- Word Callback Procedure