问题
I am having trouble accessing the external USB camera instead of the built-in iSight when using OpenCV with a MacBook Pro under Mac OSX.
When passing an argument to the cvCaptureFromCAM(index)
function other than 0 or -1 I will always get aWarning: Max Camera Num is 0; Using camera 0
The camera is a Sony PS3 EYE working perfectly with the macam driver and quicktime component.
Yet I am unable to access it using OpenCV which will always default to the built-in iSight (even when trying to "occupy" the iSight with a different program).
Any ideas?
Thank you very much in advance, your help is very much appreciated!
回答1:
I was just messing with the same problem, macam drivers are 32 bit, if your opencv install is compiled as 64 bit it won't work. I end up installing opencv twice 64 bit with mac ports and 32 bit with howebrew whenever I am using ps3eye I switch to 32 bit version.
来源:https://stackoverflow.com/questions/5041752/opencv-capture-from-usb-not-isight-osx