Instance Method
register(adContainer:)
Registers the container for displaying ads.
@objc(registerAdContainer:) func register(adContainer: UIView)
Parameters
- adContainer
The container view which should contain the rendered ads.
Discussion
Calling this method again replaces the previously registered container for subsequent ad presentations.
Pause ads use the container that is registered when presentation starts. PlayerView registers its default ad container above video and below the player UI. A custom container can be used for layouts such as displaying the video and pause ad side by side.
Register a custom container after setting up PlayerView. Reattaching the player or creating another PlayerView can register its default container again, in which case the custom container must be registered again.
Important
For pause ads, the SDK adds and removes only its own overlay. The integrator remains responsible for the custom container’s hierarchy, layout, visibility, and styling.