Contents

canAddTrackAssociation(withTrackOf:type:)

Determines whether it’s valid to associate another input’s track with this input’s track.

Declaration

func canAddTrackAssociation(withTrackOf input: AVAssetWriterInput, type trackAssociationType: String) -> Bool

Parameters

  • input:

    An asset writer input that contains the track to associate.

  • trackAssociationType:

    The type of track association to test.

Return Value

true if the system can make the association between tracks; otherwise, false.

Discussion

This method returns false if the association type requires tracks of a media type that doesn’t match the input’s type, or if the output file type doesn’t support track associations.

See Also

Configuring track associations