---
title: "loadTracks(withMediaCharacteristic:completionHandler:)"
framework: avfoundation
role: symbol
role_heading: Instance Method
path: "avfoundation/avmutablemovie/loadtracks(withmediacharacteristic:completionhandler:)"
---

# loadTracks(withMediaCharacteristic:completionHandler:)

Loads tracks that contain media of a specified characteristic.

## Declaration

```swift
func loadTracks(withMediaCharacteristic mediaCharacteristic: AVMediaCharacteristic, completionHandler: @escaping @Sendable ([AVMutableMovieTrack]?, (any Error)?) -> Void)
```

```swift
func loadTracks(withMediaCharacteristic mediaCharacteristic: AVMediaCharacteristic) async throws -> [AVMutableMovieTrack]
```

## Parameters

- `mediaCharacteristic`: The media characteristic of the tracks to load.
- `completionHandler`: A callback that the system invokes after it finishes the loading request. It passes the completion handler the following parameters:

## See Also

### Loading tracks

- [tracks](avfoundation/avpartialasyncproperty/tracks-2lj40.md)
- [loadTrack(withTrackID:completionHandler:)](avfoundation/avmutablemovie/loadtrack(withtrackid:completionhandler:).md)
- [loadTracks(withMediaType:completionHandler:)](avfoundation/avmutablemovie/loadtracks(withmediatype:completionhandler:).md)
