Skip to content
/ camd Public

Stream camera frames from a device to a virtual video device on Linux.

Notifications You must be signed in to change notification settings

zenoxygen/camd

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

camd

pipeline

Stream camera frames from a device to a virtual video device on Linux.

About

camd is a command-line utility for Linux that streams camera frames from a device to a virtual video device. Using FFmpeg, the application converts the camera frames into a suitable format for the virtual video device.

Installation

Requirements

  • A virtual video device available
  • FFmpeg (already installed in most of Linux distributions)

Build

Clone this repository:

git clone https://github.com/zenoxygen/camd.git

Build the binary with optimizations:

cargo build --release

Install the binary on your system:

sudo install -m 0755 -o root -g root -t /usr/local/bin ./target/release/camd

Usage

camd 0.1.0

USAGE:
    camd [OPTIONS]

OPTIONS:
        --host_camera <host_camera>          the host of the camera server [default: 0.0.0.0:4321]
        --host_video <host_video>            the host of the video server [default: 0.0.0.0:1234]
        --virtual_device <virtual_device>    the name of the virtual device [default: /dev/video2]

Debug

Run with the environment variable set:

RUST_LOG=trace camd

Setup a virtual video device on Linux

  1. Install v4l2loopback:
sudo apt-get install v4l2loopback-dkms v4l-utils
  1. Load the v4l2loopback module into the kernel:
sudo modprobe v4l2loopback
  1. List available video devices using v4l2-ctl:
v4l2-ctl --list-devices

About

Stream camera frames from a device to a virtual video device on Linux.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages