Instance Property

externalPlaybackVideoGravity

The video gravity of the player for external playback mode only.

Declaration

var externalPlaybackVideoGravity: AVLayerVideoGravity { get set }

Discussion

Valid values are resize, resizeAspectFill, or resizeAspect.

See Also

Managing External Playback

var allowsExternalPlayback: Bool

A Boolean value that indicates whether the player allows switching to external playback mode.

var isExternalPlaybackActive: Bool

A Boolean value that indicates whether the player is currently playing video in external playback mode.

var usesExternalPlaybackWhileExternalScreenIsActive: Bool

A Boolean value that indicates whether the player should automatically switch to external playback mode while the external screen mode is active.

struct AVLayerVideoGravity

A value that defines how the video is displayed within a layer’s bounds rectangle.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software