Instance Method

updateMeters()

Refreshes the average and peak power values for all channels of an audio player.

Declaration

func updateMeters()

Discussion

To obtain current audio power values, you must call this method before calling averagePower(forChannel:) or peakPower(forChannel:).

See Also

Using Audio Level Metering

var isMeteringEnabled: Bool

A Boolean value that specifies the audio-level metering on/off state for the audio player.

func averagePower(forChannel: Int) -> Float

Returns the average power for a given channel, in decibels, for the sound being played.

func peakPower(forChannel: Int) -> Float

Returns the peak power for a given channel, in decibels, for the sound being played.