Previous Book Contents Book Index Next

Inside Macintosh: Sound /
Chapter 4 - Speech Manager / Speech Manager Reference
Speech Manager Routines / Obtaining Information About Speech


Legacy Documentclose button

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.

SpeechBusySystemWide

You can use the SpeechBusySystemWide function to determine if any speech is currently being synthesized in your application or elsewhere on the computer.

FUNCTION SpeechBusySystemWide: Integer;
DESCRIPTION
The SpeechBusySystemWide function returns the total number of speech channels currently synthesizing speech on the computer, whether they were initiated by your application or process's code or by some other process executing concurrently. Note that paused speech channels are counted among those channels that are synthesizing speech.

This function is useful when you want to ensure that no speech is currently being produced anywhere on the Macintosh computer before initiating speech. Although the Speech Manager allows different applications to produce speech simultaneously, this can be confusing to the user. As a result, it is often a good idea for your application to check that no other process is producing speech before producing speech itself. If the difference between the values returned by SpeechBusySystemWide and the SpeechBusy function is 0, no other process is producing speech.

SPECIAL CONSIDERATIONS
You can call the SpeechBusySystemWide function at interrupt time.

ASSEMBLY-LANGUAGE INFORMATION
The trap macro and routine selector for the SpeechBusySystemWide function are
Trap macroSelector
_SoundDispatch$0040000C


Previous Book Contents Book Index Next

© Apple Computer, Inc.
2 JUL 1996