Package com.castlabs.sdk.debug
Class OverlayControllerComponent
java.lang.Object
com.castlabs.sdk.debug.OverlayControllerComponent
- All Implemented Interfaces:
PlayerControllerPlugin.Component,PlayerControllerPlugin.ComponentViewListener,PlayerControllerPlugin.VisualComponent
public final class OverlayControllerComponent
extends Object
implements PlayerControllerPlugin.VisualComponent
A PlayerControllerPlugin.VisualComponent that displays debug information as an overlay on top of
the player.
It shows player state, bandwidth estimation, buffer levels, and ABR quality information.
The position of the overlay can be configured with setDebugOverlayPosition(DebugPlugin.DebugOverlayPosition)
and can be enabled or disabled with enableDebugOverlay() and disableDebugOverlay().
In order to interact with the component you need to get an instance of it through
DebugPlugin.getOverlayController(PlayerController).
-
Constructor Summary
ConstructorsConstructorDescriptionOverlayControllerComponent(DebugPlugin.DebugOverlayPosition debugOverlayPosition) Constructor for OverlayControllerComponent. -
Method Summary
Modifier and TypeMethodDescriptionvoidDisables the debug overlay, making it invisible and disconnecting it from the player controller.voidEnables the debug overlay, making it visible and connecting it to the player controller.id()voidonComponentViewsChanged(PlayerController playerController) voidonDestroy(PlayerController playerController) voidonOpenBundle(PlayerController playerController, Bundle bundle) voidonOpenState(PlayerController playerController, PlayerConfig playerConfig) scanComponentViews(ViewGroup container) voidsetDebugOverlayPosition(DebugPlugin.DebugOverlayPosition debugOverlayPosition) Sets the position of the debug overlay.
-
Constructor Details
-
OverlayControllerComponent
Constructor for OverlayControllerComponent.- Parameters:
debugOverlayPosition- The initial position of the debug overlay.
-
-
Method Details
-
onComponentViewsChanged
- Specified by:
onComponentViewsChangedin interfacePlayerControllerPlugin.ComponentViewListener
-
scanComponentViews
- Specified by:
scanComponentViewsin interfacePlayerControllerPlugin.ComponentViewListener
-
setDebugOverlayPosition
Sets the position of the debug overlay.- Parameters:
debugOverlayPosition- The new position for the debug overlay.
-
enableDebugOverlay
public void enableDebugOverlay()Enables the debug overlay, making it visible and connecting it to the player controller. -
disableDebugOverlay
public void disableDebugOverlay()Disables the debug overlay, making it invisible and disconnecting it from the player controller. -
id
- Specified by:
idin interfacePlayerControllerPlugin.Component
-
onDestroy
- Specified by:
onDestroyin interfacePlayerControllerPlugin.Component
-
onOpenBundle
- Specified by:
onOpenBundlein interfacePlayerControllerPlugin.Component
-
onOpenState
public void onOpenState(@NonNull PlayerController playerController, @NonNull PlayerConfig playerConfig) - Specified by:
onOpenStatein interfacePlayerControllerPlugin.Component
-