---
url: https://docs.moqtail.dev/ts/api/player/interfaces/MediaSourceElement.md
---
# Interface: MediaSourceElement

Implemented by sources that deliver media and handle a switching set.

## Methods

### getRenditions()

> **getRenditions**(): [`Rendition`](Rendition.md)\[]

#### Returns

[`Rendition`](Rendition.md)\[]

***

### selectRenditions()

> **selectRenditions**(`renditionIds`): `Promise`<`void`>

Sets which renditions ABR may choose from.

#### Parameters

##### renditionIds

`string`\[]

#### Returns

`Promise`<`void`>

***

### setTracks()

> **setTracks**(`tracks`): `void`

Called by the catalog element when an update changes this source's switching set.

#### Parameters

##### tracks

readonly (`object` & `object` & `object`)\[]

#### Returns

`void`

***

### switch()

> **switch**(`renditionId`): `Promise`<`void`>

#### Parameters

##### renditionId

`string`

#### Returns

`Promise`<`void`>
