Determine Core Audio Parameter Type

I'm trying to figure out how to set the volume of a CoreAudio AudioUnit. I found the parameter kHALOutputParam_Volume, but I can't find anything about it.

I called AudioUnitGetPropertyInfo and that told me that the parameter is 4 bytes long and writeable. How can I find out whether that is an Int32, UInt32, Float32 or some other type and what acceptable values are and mean?

I used AudioUnitGetProperty and read it as either Int32 (512) or Float32 (7.17e-43).

Is there any documentation on this and other parameters?

Answered by ssmith_c in 708777022

from AudioToolbox/AudioUnitParameters.h,

CF_ENUM(AudioUnitParameterID) {
		// Global, LinearGain, 0->1, 1
	kHALOutputParam_Volume 		= 14 
};

AudioUnitSetParameter is declared in AudioToolbox/AUComponent.h, here you will also find:

typedef	Float32							AudioUnitParameterValue;
Accepted Answer

from AudioToolbox/AudioUnitParameters.h,

CF_ENUM(AudioUnitParameterID) {
		// Global, LinearGain, 0->1, 1
	kHALOutputParam_Volume 		= 14 
};

AudioUnitSetParameter is declared in AudioToolbox/AUComponent.h, here you will also find:

typedef	Float32							AudioUnitParameterValue;
Determine Core Audio Parameter Type
 
 
Q