Previous Book Contents Book Index Next

Inside Macintosh: Sound /
Chapter 2 - Sound Manager / Sound Manager Reference
Sound Manager Routines / Controlling Volume Levels


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.

SetDefaultOutputVolume

You can use the SetDefaultOutputVolume function to set the default volume of a sound output device.

FUNCTION SetDefaultOutputVolume (level: LongInt): OSErr;
level
The desired default volume level of a sound output device.
DESCRIPTION
The SetDefaultOutputVolume function sets the default volume of a sound output device. The values you can specify in the high and low words of the level parameter range from 0 (silence) to $0100 (full volume).

SPECIAL CONSIDERATIONS
The SetDefaultOutputVolume function is available only in versions 3.0 and later of the Sound Manager. You can call this function at interrupt time.

ASSEMBLY-LANGUAGE INFORMATION
The trap macro and routine selector for the SetDefaultOutputVolume function are
Trap macroSelector
_SoundDispatch$02300024

RESULT CODES
noErr0No error

Previous Book Contents Book Index Next

© Apple Computer, Inc.
2 JUL 1996