AudioUnit
extension AudioUnit
-
Obtain a property description from an AudioUnit
Throws
throws exception if the property is invalidDeclaration
Swift
public func getPropertyInfo(_ pid: AudioUnitPropertyID) throws -> (size: UInt32, writable: Bool)Parameters
pidthe key of the property to get
Return Value
a 2-tuple containing the size of the property value and a flag if it can be updated
-
Obtain the current value of a property
Throws
throws exception if the property is invalid or the size is wrongDeclaration
Swift
public func getPropertyValue<T>(_ pid: AudioUnitPropertyID) throws -> TParameters
pidthe key of the property to get
Return Value
the current value
-
Obtain the current value of a property
Throws
throws exception if the property is invalid or the size is wrongDeclaration
Swift
public func getPropertyValue<T>(_ pid: AudioUnitPropertyID, size: UInt32) throws -> TParameters
pidthe key of the property to get
sizethe size of the property value type
Return Value
the current value
-
Change a property value.
Throws
throws exception if the property is invalid or the property is read-onlyDeclaration
Swift
public func setPropertyValue<T>(_ pid: AudioUnitPropertyID, value: T) throwsParameters
pidthe key of the property to set
valuethe new value to use
-
Change a property value.
Throws
throws exception if the property is invalid or the property is read-onlyDeclaration
Swift
public func setPropertyValue<T>(_ pid: AudioUnitPropertyID, size: UInt32, value: T) throwsParameters
pidthe key of the property to set
sizethe size of the value type
valuethe new value to use
View on GitHub
AudioUnit Extension Reference