Contents

centerStageRectOfInterest

The effective region within the output pixel buffer to perform Center Stage framing.

Declaration

var centerStageRectOfInterest: CGRect { get set }

Discussion

Apps that require cropping the output from Center Stage can use this property to guide how it performs its framing. The rectangle’s origin is top-left and is relative to the coordinate space of the output pixel buffer. The default value of this property is a rectangle with a normalized (0-1) coordinate space, where (0,0) represents the top left of the picture area, and (1,1) represents the bottom-right of the unrotated picture. The system applies the rectangle of interest prior to rotation, mirroring, or scaling.

Attempting to set a rectangle of interest in the following cases results in the system throwing an illegal argument exception:

  • If none of the capture device’s supported formats support Center Stage.

  • If the capture device’s isCenterStageEnabled property value is false.

  • If you specify a value that’s outside the normalized (0-1) coordinate space.

See Also

Configuring Center Stage