Posts

Post not yet marked as solved
3 Replies
Let me add that tccutil does not work (and apparently no longer manages location permissions, if it ever did). Editing /var/db/locationd/clients.plist is not permitted, even as root.
Post not yet marked as solved
9 Replies
For what it's worth, I just saw the very same exception in a Mac Catalyst app when running it on an iPad (Xcode 11.3.1). After a clean rebuild, the problem was gone.
Post not yet marked as solved
6 Replies
This is mentioned in which release notes?Edit: I see it in the release notes for macOS 10.15, but no mention of it in the release notes for macOS 10.15.1 (in which the problem persists). It's also not clear if that note refers to precisely the same issue I'm experiencing.Thanks.
Post not yet marked as solved
6 Replies
Reported via Feedback Assistant: FB7468380
Post marked as solved
4 Replies
On the Mac, it is possible for an app to choose one or more audio input and/or output devices to work with, independent of the system input/output device selection. However, I don't see any reason why a Mac Catalyst audio app couldn't or shouldn't operate the same way on Mac as it does on iPad (even if it isn't as elegant as a native Mac app's ability to work with audio devices, independent of the system selection).In any case, I did submit a formal request to Apple (FB7328546) to provide similar behavior in AVAudioSession's 'availableInputs' property.Also, although I have been using the RemoteIO audio unit to interact with the selected audio devices, I did test this issue with AVAudioEngine and got the same result for the input device name ('CADefaultDeviceAggregate-xxxx-x').
Post marked as solved
4 Replies
It turns out that a lot more is possible with the CoreAudio framework in Catalyst than in iOS. So, we can get all the info we need through CoreAudio in the Mac version of the app. We can even allow the user to choose the selected audio input and output devices through our own app.Here's a simple Swift example to get the name and UID of the current input device (accessible from our existing Objective-C code):@objc open class func getSelectedInputDeviceInfo() -> [String: Any] { let keys = FSTCAKey() var devInfo:[String: Any] = [keys.inputDeviceName: "Audio Input", keys.inputDeviceUID: "Audio Input"] var deviceId = AudioDeviceID(0); var deviceSize = UInt32(MemoryLayout.size(ofValue: deviceId)); var address = AudioObjectPropertyAddress(mSelector: kAudioHardwarePropertyDefaultInputDevice, mScope: kAudioObjectPropertyScopeGlobal, mElement: kAudioObjectPropertyElementMaster); var err = AudioObjectGetPropertyData(AudioObjectID(kAudioObjectSystemObject), &address, 0, nil, &deviceSize, &deviceId); if ( err == 0) { devInfo[keys.inputDeviceID] = deviceId address.mSelector = kAudioDevicePropertyDeviceNameCFString var deviceName = "" as CFString deviceSize = UInt32(MemoryLayout.size(ofValue: deviceName)) err = AudioObjectGetPropertyData( deviceId, &address, 0, nil, &deviceSize, &deviceName) if (err == 0) { devInfo[keys.inputDeviceName] = deviceName as String print("### current input device: \(deviceName) ") } address.mSelector = kAudioDevicePropertyDeviceUID err = AudioObjectGetPropertyData( deviceId, &address, 0, nil, &deviceSize, &deviceName) if (err == 0) { devInfo[keys.inputDeviceUID] = deviceName as String print("### current input device UID: \(deviceName) ") } } return devInfo }The name and UID returned from CoreAudio give us what we were hoping to get from AVAudioSession.