Sha256: 92941942b91169a49af486588a6050366d14f503fc3881a150396e3c83ee36bf
Contents?: true
Size: 902 Bytes
Versions: 2
Compression:
Stored size: 902 Bytes
Contents
# frozen_string_literal: true module Lolcommits class CaptureMac < Capturer def capture_device_string @capture_device.nil? ? nil : "-d \"#{@capture_device}\"" end def capture # TODO: check we have a webcam we can capture from first. See issue #219 # operating laptop in clamshell (lid closed) from 2nd desktop screen, # needs to better handle the capturer (imagesnap, videosnap # CommandCam, mplayer) return code or check with an option before # attempting capture. Alt solution is puttin in prompt mode option :( call_str = "#{executable_path} -q \"#{snapshot_location}\" -w #{capture_delay} #{capture_device_string}" debug "Capturer: making system call for #{call_str}" system(call_str) end def executable_path File.join(Configuration::LOLCOMMITS_ROOT, 'vendor', 'ext', 'imagesnap', 'imagesnap') end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
lolcommits-0.13.1 | lib/lolcommits/capturer/capture_mac.rb |
lolcommits-0.13.0 | lib/lolcommits/capturer/capture_mac.rb |