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.
SoundComponentInitOutputDevice
A sound output device component must implement theSoundComponentInitOutputDevice
function. The Sound Manager calls this function to allow a sound output device component to configure any associated hardware devices.
pascal ComponentResult SoundComponentInitOutputDevice (ComponentInstance ti, long actions);
ti
- A component instance that identifies your sound component.
actions
- A set of flags. This parameter is currently unused.
DESCRIPTION
YourSoundComponentInitOutputDevice
function is called by the Sound Manager at noninterrupt time to allow your sound output device component to perform any hardware-specific initialization. You should perform any necessary initialization that was not already performed in yourOpenComponent
function. Note that yourOpenComponent
function cannot assume that the appropriate hardware is available. As a result, the Sound Manager calls yourSoundComponentInitOutputDevice
function when it is safe to communicate with your audio hardware. You can call theOpenMixerSoundComponent
function to create a single sound component chain.SPECIAL CONSIDERATIONS
YourSoundComponentInitOutputDevice
function is always called at noninterrupt time. All other component-defined routines might be called at interrupt time. Accordingly, yourSoundComponentInitOutputDevice
function should handle any remaining memory allocation needed by your component and it should lock down any relocatable blocks your component will access.RESULT CODES
YourSoundComponentInitOutputDevice
function should returnnoErr
if successful or an appropriate result code otherwise.SEE ALSO
See Listing 5-4 on page 5-17 for a sampleSoundComponentInitOutputDevice
function.