class

V4crVideoCapture

Inherits Reference < Object

V4cr-based video capture module to replace FFmpeg

Constants

Log = ::Log.for(self)
MJPEG_BOUNDARY = "--mjpegboundary"

Constructors

new(device_path : String = "/dev/video0", width : UInt32 = 640_u32, height : UInt32 = 480_u32, fps : Int32 = 30, jpeg_quality : Int32 = 100)
Source

Instance methods

actual_fps
Source
add_client(channel : Channel(Bytes))
Source
client_count
Source
device_available?

Check if current device is still available

Source
device_info
Source
device_path
Source
finalize
Source
fps=(fps : Int32)

Allow changing FPS at runtime

Source
initialize_device

Initialize and configure the V4L2 device

Source
jpeg_quality=(quality : Int32)

Allow changing JPEG quality at runtime

Source
redetect_and_switch_device

Attempt to find and switch to an available video device

Source
remove_client(channel : Channel(Bytes))
Source
running?
Source
start_streaming

Start video streaming

Source
stop_streaming

Stop video streaming

Source
stream_to_http_response(response)
Source