PlaybackProfile

A playback preset as data: one named intent compiled into the two places configuration actually goes, the PlayerConfig this player reads and the decoder option strings a backend passes to its decoders.

The engine stays backend-agnostic, so decoderOptions are plain av_opt_set strings here; the FFmpeg backend accepts them at construction (KiteFFmpegMediaBackend(decoderOptions)) and applies them through its typed layer. A profile is a VALUE: toString prints exactly what it compiles to, which is what the diagnostics dump carries (law 4).

@OptIn(KitePlayerLowLevelApi::class) // decoderOptions is low-level API
fun scrubbingPlayer(): KitePlayer {
val profile = PlaybackProfile.Scrubbing
return KitePlayer.create(
profile.applyTo(PlayerConfig(backends = Backends(
backend = KiteFFmpegMediaBackend(decoderOptions = profile.decoderOptions),
output = mobileBackends().output,
))),
)
}

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

Decoder configuration as av_opt_set strings, for the backend's constructor.

Link copied to clipboard

True when the backend should open its decoders in low-delay shape.

Link copied to clipboard

Functions

Link copied to clipboard

Returns config with this profile's player-side choices applied.

Link copied to clipboard
open override fun toString(): String