# ChunkExtractor.TrackOutputProvider

Artifact: [androidx.media3:media3-exoplayer](https://developer.android.com/jetpack/androidx/releases/media3) [View Source](https://cs.android.com/search?q=file:androidx/media3/exoplayer/source/chunk/ChunkExtractor.java+class:androidx.media3.exoplayer.source.chunk.ChunkExtractor.TrackOutputProvider)

*** ** * ** ***


```
public interface ChunkExtractor.TrackOutputProvider
```

<br />

Known direct subclasses [BaseMediaChunkOutput](https://developer.android.com/reference/androidx/media3/exoplayer/source/chunk/BaseMediaChunkOutput)

|---|---|
| `https://developer.android.com/reference/androidx/media3/exoplayer/source/chunk/BaseMediaChunkOutput` | A `https://developer.android.com/reference/androidx/media3/exoplayer/source/chunk/ChunkExtractor.TrackOutputProvider` that provides `https://developer.android.com/reference/androidx/media3/extractor/TrackOutput` based on a predefined mapping from track type to output. |

*** ** * ** ***

Provides `https://developer.android.com/reference/androidx/media3/extractor/TrackOutput` instances to be written to during extraction.

## Summary

| ### Public methods |
|---|---|
| `abstract https://developer.android.com/reference/androidx/media3/extractor/TrackOutput` | `https://developer.android.com/reference/androidx/media3/exoplayer/source/chunk/ChunkExtractor.TrackOutputProvider#track(int,int)(int id, @https://developer.android.com/reference/androidx/media3/common/C.TrackType int type)` Called to get the `https://developer.android.com/reference/androidx/media3/extractor/TrackOutput` for a specific track. |

## Public methods

### track

```
abstract TrackOutput track(int id, @C.TrackType int type)
```

Called to get the `https://developer.android.com/reference/androidx/media3/extractor/TrackOutput` for a specific track.

The same `https://developer.android.com/reference/androidx/media3/extractor/TrackOutput` is returned if multiple calls are made with the same `
id`.

| Parameters |
|---|---|
| `int id` | A track identifier. |
| `@https://developer.android.com/reference/androidx/media3/common/C.TrackType int type` | The `https://developer.android.com/reference/androidx/media3/common/C.TrackType` of the track. |

| Returns |
|---|---|
| `https://developer.android.com/reference/androidx/media3/extractor/TrackOutput` | The `https://developer.android.com/reference/androidx/media3/extractor/TrackOutput` for the given track identifier. |