TechnologiesVideo, Photos & Camera

ScreenCaptureKit

iOSmacOStvOSwatchOSvisionOS

ScreenCaptureKit provides high-performance capture of screen, window, and audio content, along with screenshots and recording. You discover the displays, windows, and applications available for capture with SCShareableContent, SCDisplay, SCWindow, and SCRunningApplication, then narrow what is captured using an SCContentFilter and SCStreamConfiguration. An SCStream delivers frames to your SCStreamOutput and reports state through an SCStreamDelegate, while SCScreenshotManager produces still images and SCRecordingOutput writes recordings to disk. For user-driven selection, SCContentSharingPicker presents a system content-sharing picker that reports its choices to an SCContentSharingPickerObserver.

Discovering Shareable Content 6

Enumerate the displays, windows, and applications that are available to capture.

  • Cl
    SCShareableContentmacOS 12.3+
    An object that lists the displays, windows, and applications available to capture.
  • Cl
    SCShareableContentInfomacOS 14.0+
    @abstract SCShareableContentInfo
  • Cl
    SCDisplaymacOS 12.3+
    An object that represents a display available for capture.
  • Cl
    SCWindowmacOS 12.3+
    An object that represents an on-screen window available for capture.
  • Cl
    SCRunningApplicationmacOS 12.3+
    An object that represents an application available for capture.
  • En
    SCShareableContentStylemacOS 12.3+
    @typedef SCShareableContentStyle

Configuring What to Capture 5

Narrow capture to specific content and tune the resulting stream's output.

  • Cl
    SCContentFiltermacOS 12.3+
    @abstract SCContentFilter
  • Cl
    SCStreamConfigurationmacOS 12.3+
    @abstract SCStreamConfiguration
  • En
    SCCaptureResolutionTypemacOS 12.3+
    Constants that specify whether capture uses the best or a nominal resolution.
  • En
    SCCaptureDynamicRangemacOS 15.0+
    @typedef SCCaptureDynamicRange
  • En
    SCPresenterOverlayAlertSettingmacOS 14.0+
    @typedef SCPresenterOverlayAlertSetting

Capturing a Stream 8

Start a live capture stream and receive frames and state callbacks.

  • Cl
    SCStreammacOS 12.3+
    An object that captures screen and audio content and delivers frames to its outputs.
  • Pr
    SCStreamOutputmacOS 12.3+
    A protocol you implement to receive captured sample buffers from a stream.
  • Pr
    SCStreamDelegatemacOS 12.3+
    @abstract SCStreamDelegate
  • En
    SCStreamOutputTypemacOS 12.3+
    @typedef SCStreamOutputType
  • En
    SCStreamType
    @typedef SCStreamType
  • St
    SCStreamFrameInfomacOS 12.3+
    Keys that identify metadata attached to each captured frame.
  • En
    SCFrameStatusmacOS 12.3+
    @typedef SCFrameStatus
  • St
    SCStreamErrormacOS 12.3+
    An error type that describes failures that occur while capturing a stream.

Recording to Disk 7

Write captured content to a movie file and edit recordings.

  • Cl
    SCRecordingOutputmacOS 15.0+
    A stream output that writes captured screen and audio content to a movie file on disk.
  • Cl
    SCRecordingOutputConfigurationmacOS 15.0+
    @abstract SCRecordingOutputConfiguration
  • Pr
    SCRecordingOutputDelegatemacOS 15.0+
    @protocol SCRecordingOutputDelegate
  • Cl
    SCRecordingEditormacOS 27.0+
    @class SCRecordingEditor
  • Pr
    SCRecordingEditorDelegatemacOS 27.0+
    A protocol you implement to respond to events from a recording editor.
  • Cl
    SCClipBufferingOutputmacOS 27.0+
    @abstract SCClipBufferingOutput
  • Pr
    SCClipBufferingOutputDelegatemacOS 27.0+
    @protocol SCClipBufferingOutputDelegate

Taking Screenshots 3

Produce still images from displays, windows, or a content filter.

  • Cl
    SCScreenshotManagermacOS 14.0+
    An object that captures still images of displays, windows, or filtered content.
  • Cl
    SCScreenshotConfigurationmacOS 26.0+
    @abstract SCScreenshotConfiguration
  • Cl
    SCScreenshotOutputmacOS 26.0+
    @abstract SCScreenshotOutput

Presenting the Content-Sharing Picker 4

Let the user choose what to share through the system content-sharing picker.

  • Cl
    SCContentSharingPickermacOS 14.0+
    @abstract SCContentSharingPicker
  • Pr
    SCContentSharingPickerObservermacOS 14.0+
    @abstract SCContentSharingPickerObserver
  • St
    SCContentSharingPickerConfigurationiOS 27.0+
    A configuration that specifies the allowed selection styles and options for the content-sharing picker.
  • St
    SCContentSharingPickerModemacOS 14.0+
    @typedef SCContentSharingPickerMode
← Video, Photos & Camera