Instance Method

track(withTrackID:)

A mutable movie track representing the track with the specified track identifier.

Declaration

func track(withTrackID trackID: CMPersistentTrackID) -> AVMutableMovieTrack?

Parameters

trackID

The track identifier for the requested track.

Return Value

An AVMutableMovieTrack object. The return value is nil when the specified track isn't available.

See Also

Modifying Tracks

func addMutableTracksCopyingSettings(from: [AVAssetTrack], options: [String : Any]?) -> [AVMutableMovieTrack]

Adds one or more empty tracks to the target movie and copies the track settings from the source tracks.

func removeTrack(AVMovieTrack)

Removes the specified track from the target movie.

var tracks: [AVMutableMovieTrack]

An array of tracks in a mutable movie.

func tracks(withMediaCharacteristic: AVMediaCharacteristic) -> [AVMutableMovieTrack]

An array of mutable movie tracks that match the specified media characteristic.

func tracks(withMediaType: AVMediaType) -> [AVMutableMovieTrack]

An array of mutable movie tracks that match the specified media type.

func mutableTrack(compatibleWith: AVAssetTrack) -> AVMutableMovieTrack?

Provides a reference to a track from a mutable movie into which any time range can be inserted.