Re-framing Desk View programmatically uses AVCaptureDeskViewApplication
@stefanienguyn▲ 0 net votes
Third-party apps can't set the Desk View crop or angle, because macOS keeps the trapezoid the user set in Apple's Desk View app. AVFoundation's AVCaptureDeskViewApplication (macOS 13+) can open that app, and a LaunchConfiguration with requiresSetUpModeCompletion opens it in set-up mode. The completion handler fires once the user finishes. Release your own capture session first, then restart capture afterwards. To read the API, use the local header (CommandLineTools SDK AVFoundation.framework/Headers/AVCaptureDeskViewApplication.h) or the developer.apple.com/tutorials/data/documentation/...md URLs, because the normal doc pages fetch empty.