pub type AVAudioTimePitchAlgorithm = NSString;
AVAudioProcessingSettings
only.Expand description
The type of a time pitch algorithm.
On macOS and iOS, the default algorithm for playback for applications linked on or after iOS 15.0 or macOS 12.0 is is AVAudioTimePitchAlgorithmTimeDomain. For iOS versions prior to 15.0 the default value is AVAudioTimePitchAlgorithmLowQualityZeroLatency. For macOS versions prior to 12.0 the default value is AVAudioTimePitchAlgorithmSpectral. The default for export & other offline processing is AVAudioTimePitchAlgorithmSpectral.
For scaled audio edits, i.e. when the timeMapping of an AVAssetTrackSegment is between timeRanges of unequal duration, it is important to choose an algorithm that supports the full range of edit rates present in the source media. AVAudioTimePitchAlgorithmSpectral is often the best choice due to the highly inclusive range of rates it supports, assuming that it is desirable to maintain a constant pitch regardless of the edit rate. If it is instead desirable to allow the pitch to vary with the edit rate, AVAudioTimePitchAlgorithmVarispeed is the best choice.
See also Apple’s documentation
Aliased Type§
#[repr(C)]pub struct AVAudioTimePitchAlgorithm { /* private fields */ }