Skip to navigation

Enable full-screen mode

Learn how to add smooth inline-to-full-screen transitions in the FastPix iOS Player.

The FastPix iOS Player provides a built-in full-screen manager for smooth transitions between inline and full-screen playback.

Set up full-screen

Initialize the full-screen manager with the parent view controller and the player’s container view:

playerViewController.setupFullscreen(
parent: self,
container: playerView
)

Toggle full-screen

Switch between inline and full-screen modes:

playerViewController.toggleFullscreen()

Observe full-screen state changes

Listen for full-screen state transitions using a notification:

NotificationCenter.default.addObserver(
self,
selector: #selector(fullscreenStateChanged),
name: Notification.Name("FastPixFullscreenStateChangedNotification"),
object: nil
)