{ "$schema": "https://raw.githubusercontent.com/guitaripod/wwdc-sessions/master/schema/session.schema.json", "schemaVersion": 1, "id": "wwdc2026-341", "event": "wwdc2026", "eventName": "WWDC26", "year": 2026, "eventContentId": 341, "title": "Support the Center Stage front camera in your iOS app", "description": "Supercharge your iOS camera app with Center Stage using AVCapture APIs with the front camera on iPhone 17, iPhone 17 Pro and iPhone Air. Explore how APIs enable zoom and rotate options, for more flexible ways to frame selfies and videos and to automatically get everyone in a group shot. Integrate Center Stage for video calls to automatically adjust the framing, so you’re front and center for virtual meetings and FaceTime calls. And learn how to stabilize your video for real-time video conferencing.", "url": "https://developer.apple.com/videos/play/wwdc2026/341", "sosumiURL": "https://sosumi.ai/videos/play/wwdc2026/341", "type": "Video", "publishedAt": "2026-06-08T14:00:00-07:00", "platforms": [ "iOS" ], "keywords": [], "topics": [ "Photos & Camera" ], "primaryTopic": "Photos & Camera", "duration": 1064, "hasTranscript": true, "transcriptWordCount": 1938, "availableLanguages": [ "eng", "fra", "jpn", "kor", "por", "spa", "zho" ], "media": { "hls": "https://devstreaming-cdn.apple.com/videos/wwdc/2026/341/4/fa1380a3-e2ab-4442-9302-817be212e991/cmaf.m3u8", "downloadHLS": "https://devstreaming-cdn.apple.com/videos/wwdc/2026/341/4/fa1380a3-e2ab-4442-9302-817be212e991/cmaf-download.m3u8", "downloadSD": "https://devstreaming-cdn.apple.com/videos/wwdc/2026/341/4/fa1380a3-e2ab-4442-9302-817be212e991/downloads/wwdc2026-341_sd.mp4", "downloadHD": "https://devstreaming-cdn.apple.com/videos/wwdc/2026/341/4/fa1380a3-e2ab-4442-9302-817be212e991/downloads/wwdc2026-341_hd.mp4", "duration": 1064 }, "codeSnippets": [ { "title": "Support dynamic aspect ratio", "language": "swift", "startTimeSeconds": 329, "code": "// Select the Center Stage front camera\n\nimport AVFoundation\n\nlet deviceDiscoverySession = AVCaptureDevice.DiscoverySession(deviceTypes: [.builtInUltraWideCamera], mediaType: .video, position: .front)\n\nguard let camera = deviceDiscoverySession.devices.first else {\n print(\"Failed to find the capture device\")\n return\n}\n\n// Find a format that supports the 4x3 aspect ratio\n\nfor format in camera.formats {\n if format.supportedDynamicAspectRatios.contains(.ratio4x3) {\n try! camera.lockForConfiguration()\n camera.activeFormat = format\n camera.unlockForConfiguration()\n break\n }\n}\n\n// Set dynamic aspect ratio\n\ntry! camera.lockForConfiguration()\n\nlet timestamp = try! await camera.setDynamicAspectRatio(.ratio4x3)\nprint(\"Applied dynamic aspect ratio at timestamp: \\(timestamp)\")\n\ncamera.unlockForConfiguration()" }, { "title": "Support smart framing monitor", "language": "swift", "startTimeSeconds": 459, "code": "// Find a format that supports smart framing\n\nimport AVFoundation\n\nfor format in camera.formats {\n if format.isSmartFramingSupported {\n try! camera.lockForConfiguration()\n camera.activeFormat = format\n camera.unlockForConfiguration()\n break\n }\n}\n\n// Configure the smart framing monitor\n\nlet monitor = camera.smartFramingMonitor!\n\ntry! camera.lockForConfiguration()\nmonitor.enabledFramings = monitor.supportedFramings\ncamera.unlockForConfiguration()\n\n// Monitor framing recommendations\n\nobservation = monitor.observe(\\.recommendedFraming, options: [.new,]) { monitor, change in\n if let framing = monitor.recommendedFraming {\n\n Task {\n try! camera.lockForConfiguration()\n try! await camera.setDynamicAspectRatio(framing.aspectRatio)\n camera.videoZoomFactor = CGFloat(framing.zoomFactor)\n camera.unlockForConfiguration()\n }\n\n }\n}\n\n// Start the smart framing monitor\n\ntry! monitor.startMonitoring()\n\n// Stop the smart framing monitor\n\nobservation?.invalidate()\nobservation = nil\n\nmonitor.stopMonitoring()" }, { "title": "Support Center Stage for video calls", "language": "swift", "startTimeSeconds": 884, "code": "// Find a format that supports Center Stage\n\nimport AVFoundation\n\nfor format in camera.formats {\n if format.isCenterStageSupported {\n try! camera.lockForConfiguration()\n camera.activeFormat = format\n camera.unlockForConfiguration()\n break\n }\n}\n\n// Turn on Center Stage\n\nAVCaptureDevice.centerStageControlMode = .cooperative\nAVCaptureDevice.isCenterStageEnabled = true" } ], "resources": [ { "title": "Supporting Center Stage front camera in your iOS app", "url": "https://developer.apple.com/documentation/AVFoundation/supporting-center-stage-front-camera-in-your-ios-app", "type": "samplecode", "description": "Enable Center Stage for photos and videos on the iPhone front camera.", "sosumiURL": "https://sosumi.ai/documentation/AVFoundation/supporting-center-stage-front-camera-in-your-ios-app", "doccJSON": "https://developer.apple.com/tutorials/data/documentation/AVFoundation/supporting-center-stage-front-camera-in-your-ios-app.json" }, { "title": "AVCam: Building a camera app", "url": "https://developer.apple.com/documentation/AVFoundation/avcam-building-a-camera-app", "type": "samplecode", "description": "Capture photos and record video using the front and rear iPhone and iPad cameras.", "sosumiURL": "https://sosumi.ai/documentation/AVFoundation/avcam-building-a-camera-app", "doccJSON": "https://developer.apple.com/tutorials/data/documentation/AVFoundation/avcam-building-a-camera-app.json" }, { "title": "AVFoundation", "url": "https://developer.apple.com/documentation/AVFoundation", "type": "documentation", "description": "Work with audiovisual assets, control device cameras, process audio, and configure system audio interactions.", "sosumiURL": "https://sosumi.ai/documentation/AVFoundation", "doccJSON": "https://developer.apple.com/tutorials/data/documentation/AVFoundation.json" }, { "title": "Capture setup", "url": "https://developer.apple.com/documentation/AVFoundation/capture-setup", "type": "documentation", "description": "Configure built-in cameras and microphones, and external capture devices, for media capture.", "sosumiURL": "https://sosumi.ai/documentation/AVFoundation/capture-setup", "doccJSON": "https://developer.apple.com/tutorials/data/documentation/AVFoundation/capture-setup.json" } ], "path": "sessions/wwdc2026/341-support-the-center-stage-front-camera-in-your-ios-app/", "files": { "metadata": "sessions/wwdc2026/341-support-the-center-stage-front-camera-in-your-ios-app/metadata.json", "readme": "sessions/wwdc2026/341-support-the-center-stage-front-camera-in-your-ios-app/README.md", "transcript": "sessions/wwdc2026/341-support-the-center-stage-front-camera-in-your-ios-app/transcript.md", "transcriptJSON": "sessions/wwdc2026/341-support-the-center-stage-front-camera-in-your-ios-app/transcript.json" } }