Skip to content

Multiple cameras with same vendor/product id aren't disambiguated #59

@jazzychad

Description

@jazzychad

Describe the bug
If you have two or more cameras with the same product and vendor id plugged into the USB host/bus, changing the slider values after choosing a camera may instead change the value for the other camera with the same vendor/product id.

To Reproduce
Steps to reproduce the behavior:

  1. Plug in multiple cameras with the same USB product and vendor ids2.
  2. See them in the dropdown picker of the app
  3. Select one
  4. Change a slider value in the basic settings
  5. You might see an update in the preview window, this means that the value is changed for the currently selected camera6.
  6. Select the other camera from the drop down
  7. Change the same setting. You might not see any change in the preview window, but if you look back at the other camera, you will see that it has changed instead

Expected behavior
Changing the slider values for a selected camera should update the values for that camera (and not another one)

Desktop (please complete the following information):

  • Version 1.3.1
  • Camera: n/a .. just as long as multiple have the same product/vendor id

Additional context
the usbDevice() extension method on AVCaptureDevice doesn't use enough information to disambiguate the interfaceRef returned by the dictionary passed into IOServiceGetMatchingService (in AVCaptureDevice+USB.swift), so the usb interface that is returned for each different AVCaptureDevice is actually pointing at the same end device (which causes settings changes in the UI to be routed to the same end camera).

I am actively looking into a solution for this issue by using more keys in the lookup dictionary for IOServiceGetMatchingService

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions