sarxos / webcam-capture

The goal of this project is to allow integrated or USB-connected webcams to be accessed directly from Java. Using provided libraries users are able to read camera images and detect motion. Main project consist of several sub projects - the root one, which contains required classes, build-in webcam driver compatible with Windows, Linux and Mac OS, which can stream images as fast as your camera can serve them (up to 50 FPS). Main project can be used standalone, but user is able to replace build-in driver with different one - such as OpenIMAJ, GStreamer, V4L4j, JMF, LTI-CIVIL, FMJ, etc.
http://webcam-capture.sarxos.pl
MIT License
2.25k stars 1.11k forks source link

not getting access to Camera in Mac-Latest versions using Webcam.getWebcams(), or Webcam.getDefaultCam() #851

Open svcsrao opened 2 years ago

svcsrao commented 2 years ago

Tried many ways using saros 0.3.12 jar and not able to access webcam (both internal and external) in latest MAC OS versions.

Erhannis commented 2 years ago

Same here. Here's some other similar tickets; seems like Mac has been difficult to maintain. https://github.com/sarxos/webcam-capture/issues/808 https://github.com/sarxos/webcam-capture/issues/766 https://github.com/sarxos/webcam-capture/issues/757 https://github.com/sarxos/webcam-capture/issues/723

Though actually, it looks like the final post in #757 ( https://github.com/sarxos/webcam-capture/issues/757#issuecomment-849632328 ) works - I don't know which components are strictly necessary, but after swapping out my dependencies for the ones that look relevant, and adding the repositories, my test code compiled and ran, apparently correctly fetching a default webcam (which was where I was stuck before).

Erhannis commented 2 years ago

I removed the dependency on webcam-capture-driver-openimaj, and it still fetched a webcam correctly, but both the repositories seem necessary, and presumably both webcam-capture and bridj are necessary.

eduramiba commented 1 year ago

Hi, please try this driver, it should work with recent MacOS versions https://github.com/eduramiba/webcam-capture-driver-native