isight

CoreMediaIO, incorrectly updated properties kCMIODevicePropertyDeviceIsRunningSomewhere

南笙酒味 提交于 2021-02-10 07:38:11
问题 I need to receive an event when some process starts using the camera. I did this through CMIOObjectGetPropertyData. But it does not work correctly, the correct value is only the first time it is accessed. I also tried to use the CMIOObjectAddPropertyListenerBlock but he did not work it from me. Tell me please, what am I doing wrong? I will be very grateful. while (1) { UInt32 value = 0; UInt32 valuePropertySize = sizeof(flag); CMIOObjectPropertyAddress opa =

OpenCV wont' capture from MacBook Pro iSight

蓝咒 提交于 2019-12-18 05:06:06
问题 Since a couple of days I can't open my iSight camera from inside an opencv application any more. cap = cv2.VideoCapture(0) returns, and cap.isOpened() returns true . However, cap.grab() just returns false . Any ideas? Example Code: import cv2 cv2.namedWindow("preview") vc = cv2.VideoCapture(0) rval = True while rval: rval, frame = vc.read() cv2.imshow("preview", frame) key = cv2.waitKey(20) if key == 27: # exit on ESC break Mac OS 10.8.5 Python 2.7.5 (but also not working from inside a C++

How can I capture iSight frames with Python in Snow Leopard?

空扰寡人 提交于 2019-12-12 08:09:11
问题 I have the following PyObjC script: from Foundation import NSObject import QTKit error = None capture_session = QTKit.QTCaptureSession.alloc().init() print 'capture_session', capture_session device = QTKit.QTCaptureDevice.defaultInputDeviceWithMediaType_(QTKit.QTMediaTypeVideo) print 'device', device, type(device) success = device.open_(error) print 'device open success', success, error if not success: raise Exception(error) capture_device_input = QTKit.QTCaptureDeviceInput.alloc()

OpenCV capture from USB not iSight (OSX)

南楼画角 提交于 2019-12-04 02:40:52
问题 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 a Warning: 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

OpenCV capture from USB not iSight (OSX)

懵懂的女人 提交于 2019-12-01 14:52:16
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 a Warning: 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

record a video with isight using ffmpeg

纵饮孤独 提交于 2019-11-29 22:39:02
So to record webcam video with ffmpeg on linux you may use something like... ffmpeg -f video4linux2 -s 640x480 -i /dev/video0 out.avi But on a mac this doesn't work, so i was wondering how do you record with the isight with ffmpeg on a mac? I've researched and a lot of people said it can't be done, but most of these posts are really old so i'm wondering if it's changed since then. Updated: current (Aug 2014) version of ffmpeg supports QTKit and AVKit frameworks: ffmpeg -f qtkit -video_device_index 0 -i "" out.mpg or ffmpeg -f qtkit -i "default" out.mpg also you can obtain list of available

Get webcam stream on Mac Os X in Java [closed]

删除回忆录丶 提交于 2019-11-29 19:55:07
问题 I would like to get the webcam stream of my Macbook (the integrated iSight webcam). I use Java, and I don't know anything about Objective-C so I'm looking for a "full-java" solution. I found some class example, but they were made in 2005 and they don't work on my system. 回答1: I come across the same thing myself now. I am using VLCJ for my project and it works perfect on Windows, Linux Mint, Linux Ubuntu and Mac OSX Lion. As you probably read, VLCJ is a java wrapper around libvlc which VLC

OpenCV wont' capture from MacBook Pro iSight

这一生的挚爱 提交于 2019-11-29 07:59:27
Since a couple of days I can't open my iSight camera from inside an opencv application any more. cap = cv2.VideoCapture(0) returns, and cap.isOpened() returns true . However, cap.grab() just returns false . Any ideas? Example Code: import cv2 cv2.namedWindow("preview") vc = cv2.VideoCapture(0) rval = True while rval: rval, frame = vc.read() cv2.imshow("preview", frame) key = cv2.waitKey(20) if key == 27: # exit on ESC break Mac OS 10.8.5 Python 2.7.5 (but also not working from inside a C++ app) OpenCV 2.4.6.1 qidaas This is how I got the camera working for your code (on OSX 10.6): import cv2

record a video with isight using ffmpeg

孤人 提交于 2019-11-28 19:20:11
问题 So to record webcam video with ffmpeg on linux you may use something like... ffmpeg -f video4linux2 -s 640x480 -i /dev/video0 out.avi But on a mac this doesn't work, so i was wondering how do you record with the isight with ffmpeg on a mac? I've researched and a lot of people said it can't be done, but most of these posts are really old so i'm wondering if it's changed since then. 回答1: Updated: current (Aug 2014) version of ffmpeg supports QTKit and AVKit frameworks: ffmpeg -f qtkit -video