Instance Method

insertDebugCaptureBoundary()

Informs Xcode about when GPU Frame Capture starts and stops.

Required.

Declaration

func insertDebugCaptureBoundary()

Discussion

When GPU Frame Capture is enabled, a frame can be defined as the code executed between calls to the insertDebugCaptureBoundary() method, where each call is a frame boundary. If your app does not call this method, a frame boundary is instead defined by a call to the present(_:) or present(_:atTime:) method. If both methods are called, Xcode captures only the frame between insertDebugCaptureBoundary() calls.

The insertDebugCaptureBoundary() method is useful for defining your own frame boundaries. For example, an app with a single drawable and implicit frame boundaries may not need this method; however, an app with multiple drawables may benefit from explicit frame boundaries.

Figure 1

Implicit frame boundaries defined by a drawable's present method

A single drawable is presented four times. Implicit frame boundaries are defined by the drawable's present method.

Figure 2

Explicit frame boundaries defined by the insertDebugCaptureBoundary method

Multiple drawables are presented at different times. Explicit frame boundaries are defined by the insertDebugCaptureBoundary method, thus overriding the implicit frame boundaries of each drawable.

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