An object that defines an interface for reading audio samples that result from mixing the audio from one or more tracks.


class AVAssetReaderAudioMixOutput : AVAssetReaderOutput


AVAssetReaderAudioMixOutput is a concrete subclass of AVAssetReaderOutput.

You can read the audio data mixed from one or more asset tracks by adding an instance of AVAssetReaderAudioMixOutput to an asset reader using add(_:). You can read the samples in a default format or you can convert them to a different format.


Creating an Audio Mix Output

init(audioTracks: [AVAssetTrack], audioSettings: [String : Any]?)

Initializes an audio mix output instance for reading mixed audio from the specified audio tracks, with optional audio settings.

Configuring Audio Properties

var audioMix: AVAudioMix?

The output’s audio mix.

var audioSettings: [String : Any]?

The audio settings used for audio output.

var audioTracks: [AVAssetTrack]

The tracks from which the receiver reads mixed audio.

var audioTimePitchAlgorithm: AVAudioTimePitchAlgorithm

The processing algorithm used to manage audio pitch for scaled audio edits.


Inherits From

Conforms To

See Also

File Import

class AVAssetReader

A reader object used to obtain the media data of an asset, either file-based or consisting of an assemblage of media data from multiple sources.

class AVAssetReaderTrackOutput

An object that defines an interface for reading media data from a single track of an asset reader's asset.

class AVAssetReaderSampleReferenceOutput

An object that defines an interface for reading sample references from a single asset track.

class AVAssetReaderVideoCompositionOutput

An object that reads video frames composited from the frames in one or more tracks of a reader's assets.

class AVAssetReaderOutput

An abstract class that defines an interface for reading a single collection of samples of a common media type from an asset reader object.

class AVAssetReaderOutputMetadataAdaptor

An object that defines an interface for reading metadata.

class AVAssetImageGenerator

An object that provides thumbnail or preview images of assets independently of playback.