def start_camera(self, source_name): try: source = int(source_name) except ValueError: IkaUtils.dprint('%s: Looking up device name %s' % (self, source_name)) source = None if IkaUtils.isWindows(): from ikalog.inputs.win.videoinput_wrapper import VideoInputWrapper devices_list = VideoInputWrapper().get_device_list() try: source = devices_list.index(source_name) except ValueError: pass if source is None: IkaUtils.dprint("%s: Input '%s' not found" % (self, source_name)) return None IkaUtils.dprint('%s: initalizing capture device %s' % (self, source)) self.realtime = True if IkaUtils.isWindows(): self.init_capture(700 + source) else: self.init_capture(0 + source)
def enumerate_devices(self): if IkaUtils.isWindows(): from ikalog.inputs.win.videoinput_wrapper import VideoInputWrapper return VideoInputWrapper().get_device_list() else: return [ 'IkaLog does not support camera enumeration on this platform.', 'IkaLog does not support camera enumeration on this platform.', 'IkaLog does not support camera enumeration on this platform.', ]
def enumerate_devices(self): if IkaUtils.isWindows(): from ikalog.inputs.win.videoinput_wrapper import VideoInputWrapper cameras = VideoInputWrapper().get_device_list() else: cameras = [ 'IkaLog does not support camera enumeration on this platform.', 'IkaLog does not support camera enumeration on this platform.', 'IkaLog does not support camera enumeration on this platform.', ] if len(cameras) == 0: cameras = [ _('No input devices found!') ] return cameras
def __init__(self): self.video_capture = None if IkaUtils.isWindows(): self._videoinput_wrapper = VideoInputWrapper() super(CVCapture, self).__init__()
def __init__(self): self._device_id = None self.last_t = 0 self._warned_resolution = False self._videoinput_wrapper = VideoInputWrapper()
def __init__(self): self.strict_check = False self._device_id = None self._warned_resolution = False self._videoinput_wrapper = VideoInputWrapper() super(DirectShow, self).__init__()