---
title: AVPlayerView
framework: avkit
role: symbol
role_heading: Class
path: avkit/avplayerview
---

# AVPlayerView

A view that displays content from a player and presents a native user interface to control playback.

## Declaration

```swift
class AVPlayerView
```

## Mentioned in

Implementing Trimming in a macOS Player

## Overview

Overview The player view supports several controls styles, ranging from no controls to controls matching the look of QuickTime Player. This makes it easy for you to tailor the presentation to best match your use of the player view. Regardless of the selected controls style, the player view always supports the following standard set of keyboard shortcuts to control playback: The Space bar plays and pauses playback. The right and left arrow keys step frame-by-frame through the video. JKL navigation: The J key rewinds. Press it multiple times to cycle through rewind speeds. The K key stops playback. The L key fast-forwards. Press it multiple times to cycle through fast-forward speeds. The player view also makes it simple to add trimming capabilities to your player. Call the view’s beginTrimming(completionHandler:) method to present a trimming UI that matches the QuickTime Player interface.

## Topics

### Customizing the user interface

- [controlsStyle](avkit/avplayerview/controlsstyle.md)
- [AVPlayerViewControlsStyle](avkit/avplayerviewcontrolsstyle.md)
- [showsFrameSteppingButtons](avkit/avplayerview/showsframesteppingbuttons.md)
- [showsSharingServiceButton](avkit/avplayerview/showssharingservicebutton.md)
- [showsFullScreenToggleButton](avkit/avplayerview/showsfullscreentogglebutton.md)
- [showsTimecodes](avkit/avplayerview/showstimecodes.md)
- [contentOverlayView](avkit/avplayerview/contentoverlayview.md)
- [actionPopUpButtonMenu](avkit/avplayerview/actionpopupbuttonmenu.md)
- [updatesNowPlayingInfoCenter](avkit/avplayerview/updatesnowplayinginfocenter.md)

### Customizing the video presentation

- [isReadyForDisplay](avkit/avplayerview/isreadyfordisplay.md)
- [videoBounds](avkit/avplayerview/videobounds.md)
- [videoGravity](avkit/avplayerview/videogravity.md)

### Configuring frame analysis

- [allowsVideoFrameAnalysis](avkit/avplayerview/allowsvideoframeanalysis.md)
- [videoFrameAnalysisTypes](avkit/avplayerview/videoframeanalysistypes.md)
- [AVVideoFrameAnalysisType](avkit/avvideoframeanalysistype.md)

### Configuring the playback speed

- [speeds](avkit/avplayerview/speeds.md)
- [selectedSpeed](avkit/avplayerview/selectedspeed.md)
- [selectSpeed(_:)](avkit/avplayerview/selectspeed(_:).md)
- [AVPlaybackSpeed](avkit/avplaybackspeed.md)

### Configuring picture in picture

- [allowsPictureInPicturePlayback](avkit/avplayerview/allowspictureinpictureplayback.md)
- [pictureInPictureDelegate](avkit/avplayerview/pictureinpicturedelegate.md)
- [AVPlayerViewPictureInPictureDelegate](avkit/avplayerviewpictureinpicturedelegate.md)

### Magnifying video

- [allowsMagnification](avkit/avplayerview/allowsmagnification.md)
- [magnification](avkit/avplayerview/magnification.md)
- [setMagnification(_:centeredAt:)](avkit/avplayerview/setmagnification(_:centeredat:).md)

### Displaying the chapter and title

- [flashChapterNumber(_:chapterTitle:)](avkit/avplayerview/flashchapternumber(_:chaptertitle:).md)

### Trimming media

- [canBeginTrimming](avkit/avplayerview/canbegintrimming.md)
- [beginTrimming(completionHandler:)](avkit/avplayerview/begintrimming(completionhandler:).md)
- [AVPlayerViewTrimResult](avkit/avplayerviewtrimresult.md)

### Setting the player object

- [player](avkit/avplayerview/player.md)

### Setting the delegate object

- [delegate](avkit/avplayerview/delegate.md)
- [AVPlayerViewDelegate](avkit/avplayerviewdelegate.md)

### High dynamic range

- [preferredDisplayDynamicRange](avkit/avplayerview/preferreddisplaydynamicrange.md)
- [AVDisplayDynamicRange](avkit/avdisplaydynamicrange.md)

## Relationships

### Inherits From

- [NSView](appkit/nsview.md)

### Conforms To

- [CVarArg](swift/cvararg.md)
- [CustomDebugStringConvertible](swift/customdebugstringconvertible.md)
- [CustomStringConvertible](swift/customstringconvertible.md)
- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [NSAccessibilityElementProtocol](appkit/nsaccessibilityelementprotocol.md)
- [NSAccessibilityProtocol](appkit/nsaccessibilityprotocol.md)
- [NSAnimatablePropertyContainer](appkit/nsanimatablepropertycontainer.md)
- [NSAppearanceCustomization](appkit/nsappearancecustomization.md)
- [NSCoding](foundation/nscoding.md)
- [NSDraggingDestination](appkit/nsdraggingdestination.md)
- [NSObjectProtocol](objectivec/nsobjectprotocol.md)
- [NSStandardKeyBindingResponding](appkit/nsstandardkeybindingresponding.md)
- [NSTouchBarProvider](appkit/nstouchbarprovider.md)
- [NSUserActivityRestoring](appkit/nsuseractivityrestoring.md)
- [NSUserInterfaceItemIdentification](appkit/nsuserinterfaceitemidentification.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)

## See Also

### macOS playback and capture

- [Implementing Trimming in a macOS Player](avkit/implementing-trimming-in-a-macos-player.md)
- [AVCaptureView](avkit/avcaptureview.md)
