srgAssetLoader

fun srgAssetLoader(context: Context, block: SRGAssetLoaderConfig.() -> Unit)

Configures and adds an SRGAssetLoader to the player.

Note: this function should be called only once. Subsequent calls will result in an exception.

Parameters

context

The Context required for the SRGAssetLoader.

block

A lambda to configure the SRGAssetLoader using a SRGAssetLoaderConfig instance.

Throws

If an SRGAssetLoader has already been configured.