CoreMediaIO camera extension not available immediately after activation

We activate our camera extension from host application and wait for user to allow access it in System Settings. Once our host application receives notification camera extension is ready to be used we want to communicate with the extension.

When we enumerate AVCaptureDevices or try to find newly added device using CMIOObjectGetPropertyData for property kCMIOHardwarePropertyDevices, our camera extension is not shown. Once we stop and restart host application camera extension is shown as expected, issue only happens once right after activating the extension.

Looks like capture devices are not refreshed for host application after camera extension is activated and approved. Is there a way to force system to refresh cameras? Or any other ideas to make extension immediately visible for host application without relaunching it?

are you saying if you run a AVCaptureDevice.DiscoverySession, you don't see your extension becoming available as a new AVCaptureDevice? That has not been my experience. Once the AVCaptureDevice has appeared, I can find and talk to its corresponding CMIO object.

Hi, have you got a solution? I meet the same problem

Hi, I have encountered the same issue. My host application has added the following listeners:

[[NSNotificationCenter defaultCenter] addObserver:self

                                         selector:@selector(updateCameraStatus:)
                                             name:AVCaptureDeviceWasConnectedNotification
                                           object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self
                                         selector:@selector(updateCameraStatus:)
                                             name:AVCaptureDeviceWasDisconnectedNotification
                                           object:nil];

When my camera extension version is upgraded from 1.0.0 to 1.0.1, I first receive a deviceDisconnect notification. Through the OSSystemExtensionRequestDelegate method:

- (void)request:(OSSystemExtensionRequest *)request didFinishWithResult:(OSSystemExtensionRequestResult)result

I can confirm that result == OSSystemExtensionRequestCompleted.

However, at this point, I do not receive the deviceConnect notification, and the devices retrieved through AVCaptureDeviceDiscoverySession do not include my camera extension. My current macOS version is 14.5.

I also verified this through Photo Booth and confirmed that Photo Booth cannot automatically refresh the device list when the camera extension is updated. The app must be restarted to recognize the updated camera extension.

I would like to understand if this issue, which has persisted since July last year, has been resolved. Also, how have you been handling this issue? Thank you for your response!

If you need any further assistance or modifications, feel free to ask!

CoreMediaIO camera extension not available immediately after activation
 
 
Q