---
title: "associatedTracks(ofType:)"
framework: avfoundation
role: symbol
role_heading: Instance Method
path: "avfoundation/avmutablemovietrack/associatedtracks(oftype:)"
---

# associatedTracks(ofType:)

Returns an array of associated tracks that have the specified association type.

## Declaration

```swift
func associatedTracks(ofType trackAssociationType: AVAssetTrack.AssociationType) -> [AVAssetTrack]
```

## Parameters

- `trackAssociationType`: The requested track association type.

## Return Value

Return Value An array of tracks matching the specified track association type, or an empty array if none are found.

## Discussion

Discussion Apple discourages using this method in iOS 15, tvOS 15, macOS 12, and watchOS 8 or later. Load associated tracks asynchronously using loadAssociatedTracks(ofType:completionHandler:) instead. You can call this method without blocking the current thread after you’ve loaded the availableTrackAssociationTypes property.

## See Also

### Managing track associations

- [availableTrackAssociationTypes](avfoundation/avmutablemovietrack/availabletrackassociationtypes.md)
- [addTrackAssociation(to:type:)](avfoundation/avmutablemovietrack/addtrackassociation(to:type:).md)
- [removeTrackAssociation(to:type:)](avfoundation/avmutablemovietrack/removetrackassociation(to:type:).md)
