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.
You can use the
GetDefaultOutputVolumeGetDefaultOutputVolumefunction to determine the default volume of a sound output device.
FUNCTION GetDefaultOutputVolume (VAR level: LongInt): OSErr;
level- On exit, the default volume level of a sound output device.
DESCRIPTION
TheGetDefaultOutputVolumefunction returns, in thelevelparameter, the default volume of a sound output device. The values returned in the high and low words of thelevelparameter range from 0 (silence) to $0100 (full volume).SPECIAL CONSIDERATIONS
TheGetDefaultOutputVolumefunction 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 theGetDefaultOutputVolumefunction are
Trap macro Selector _SoundDispatch $022C0024 RESULT CODES
noErr 0 No error