PlayerViewConfig

PlayerViewConfig

data class PlayerViewConfig(val uiConfig: UiConfig = UiConfig.WebUi(), val hideFirstFrame: Boolean = false, val scalingMode: ScalingMode = ScalingMode.Fit, val enableComposeSurfaceSyncWorkaround: Boolean = false, val surfaceType: SurfaceType = SurfaceType.SurfaceView, val playerMaxVideoQualityConstraint: PlayerViewConfig.PlayerVideoQualityConstraint = PlayerVideoQualityConstraint.None)

Configures the visual presentation and behaviour of the PlayerView.

Constructors

PlayerViewConfigconstructor(uiConfig: UiConfig = UiConfig.WebUi(), hideFirstFrame: Boolean = false, scalingMode: ScalingMode = ScalingMode.Fit, enableComposeSurfaceSyncWorkaround: Boolean = false, surfaceType: SurfaceType = SurfaceType.SurfaceView, playerMaxVideoQualityConstraint: PlayerViewConfig.PlayerVideoQualityConstraint = PlayerVideoQualityConstraint.None)

Types

NameSummary
Builderclass Builder
PlayerVideoQualityConstraintenum PlayerVideoQualityConstraint : Enum<PlayerViewConfig.PlayerVideoQualityConstraint>

Properties

NameSummary
enableComposeSurfaceSyncWorkaroundval enableComposeSurfaceSyncWorkaround: Boolean
Whether to enable a workaround for the Compose AndroidView and SurfaceView compatibility issue described in androidx/media#1237
hideFirstFrameval hideFirstFrame: Boolean
Whether the first frame of the main content will not be shown before playback starts. Default is false.
playerMaxVideoQualityConstraintval playerMaxVideoQualityConstraint: PlayerViewConfig.PlayerVideoQualityConstraint
Specifies if and how the PlayerView should constrain the Player video selection.
scalingModeval scalingMode: ScalingMode
Specifies how the video content is scaled or stretched within the parent container's bounds. Default is ScalingMode.Fit.
surfaceTypeval surfaceType: SurfaceType
Specify on which SurfaceType the video should be rendered.
uiConfigval uiConfig: UiConfig
Configures the visual presentation and behaviour of the Bitmovin Player UI.