simultaneous app access to iphone microphone
Asked on 08/03/2024
1 search
To enable simultaneous app access to the iPhone microphone, you can use the new features provided by ScreenCaptureKit. Specifically, the session titled "Capture HDR content with ScreenCaptureKit" covers how to capture microphone audio along with screen and system audio.
Here are the relevant steps and properties you need to use:
- Capture Microphone Audio: Use the
captureMicrophone
property to turn on microphone capture. - Select Microphone Device: Use the
microphoneCaptureDeviceID
property to choose which microphone device to capture. - Receive Microphone Samples: Use the
SCStreamOutput
to receive microphone samples in your app.
For a detailed walkthrough, you can refer to the chapter "Add microphone output" in the session Capture HDR content with ScreenCaptureKit (07:14).
Relevant Sessions
If you need more specific code examples or further details, you might want to watch the session or refer to the official documentation provided by Apple.

Customize spatial Persona templates in SharePlay
Learn how to use custom spatial Persona templates in your visionOS SharePlay experience to fine-tune the placement of Personas relative to your app. We’ll show you how to adopt custom spatial Persona templates in a sample app with SharePlay, move participants between seats, and test your changes in Simulator. We’ll also share best practices for designing custom spatial templates that will make your experience shine.

Capture HDR content with ScreenCaptureKit
Learn how to capture high dynamic colors using ScreenCaptureKit, and explore new features like HDR support, microphone capture, and straight-to-file recording.

Meet AccessorySetupKit
Elevate your accessory setup experience with AccessorySetupKit. Display a beautiful pairing dialog with an image of your Bluetooth or Wi-Fi accessory — no trip to the Settings app required. Discover how to improve privacy by pairing only your app with an accessory. And learn how you can migrate existing accessories so they can be managed by AccessorySetupKit.