Instance Method


This is called when you set the format on a bus.


func shouldChange(to format: AVAudioFormat, for bus: AUAudioUnitBus) -> Bool



The proposed new format.


The bus on which the format will be changed.

Return Value

  • true if the new format will be set on the bus.

  • false if the new format will not be set on the bus.


The bus has already checked that the format meets its channel constraints. The audio unit can override this method to check the format before allowing it to be set on the bus.

The default implementation returns false if the audio unit’s renderResourcesAllocated value is true.

See Also

Audio Unit Implementations

var internalRenderBlock: AUInternalRenderBlock

The block which you must provide, via a getter, in order to implement rendering.