BirdWatch 0.1

Copyright (C) 2021 - Hammer Data Systems, LLC

BirdWatch uses FLTK 1.3.4 (C) 1996-2021 - Bill Spitzak and others.

Please take no undeserved credit and assign me absolutely no blame. Otherwise, this a free program, download, redistribute, and use at your own risk.

BirdWatch dynamically links to OpenCV and FFMPeg and through them, to many other dynamic libraries. Getting this program running is a bit of a chore. Sorry about that, but I would rather spend my time working on the program itself than figuring out ways to install all these libraries without tears. I am afraid that I have to let that be someone else's problem. I have supplied the output of ldd at the bottom of this page. Most of these libraries should already be installed on most linux desktop systems or will be installed automatically as you install others. Almost all are readily available in most distribution's repositories.



Birdwatch is a audio/video program for recording from video cameras and microphones and encoding the result into a compressed video file. It can record from USB cameras and IP cameras using rstp.

The .zip file contains an excutable for Linux,

In the center of the screen, the live image from the default or selected camera appears. Along the left edge, live thumbnail images from all active cameras appear. Selecting a camera from the active thumbnail causes that camera's signal to become the center, recorded, signal. Next to the active camera thumbnails is a menu of all available audio signals, usually connected microphones. This menu appears whenever the system is not actively recording.

If the mouse is moved near the right edge of the screen, a menu appears that allows the user to turn on record, recoding via motion detection, turn on and off a visible timestamp, show various kinds of motion detection diagnostics, review and edit recorded footage, snap a still image, zoom, set areas of interest for motion detection, reset the raw recording (if you have no intention of encoding it into a video file), split the screen between the active cameras, select new video sources, resize the capture area (for follow motion mode), change video settings, flip the screen, and load and save interest areas for motion detection.

The video previewer / editor is a standalone window that allows simple selection of segments the user wishes to retain in the encoded video. Both audio and video are edited. Selecting the red button causes the raw audio and video files to be encoded using the selected segments. There is a scrubber that allows the user to scroll to particular portions of the video, as well as speed control for playback and encoding. There is a play button that ignores edits and another that plays only the selected portions. If no portions are selected, the entire raw file is encoded.

Here the standalone previewer / editor is seen on the desktop with the main window minimized.

The main screen can be split and the user can monitor and select each of the active cameras.

Hovering the mouse over any the active camera thumbnails causes a larger preview window to appear showing the live image from that camera.

By clicking on segments of the divided main screen, the user can select areas of interest for the motion detector. It only triggers recording if there is motion detected in the selected areas.

If the system is running in "main" mode, follow motion is available. Only the selected portion of the screen is recorded. The user can move the hightlighted box to follow the action by hand or can turn on automatic follow motion to have the system attempt to keep the recorded segment on the area with the largest motion.

The video settings allow the user to change the usual contrast, brightness, etc., as well as the encoding frames per second for fast and slow motion, and the largeness of motion necessary to trigger the motion detector.

Birdwatch creates large ".bin" files containing the raw audio and video data. The raw audio is stored in mono, 16 bit, 22100 hz. The raw data is preceeded by a single 32 bit integer containing the frequency. The raw video file is collection of timestamped uncompressed RGB frames, with a small header containing the FPS, width, height, and depth. If the output is edited before being encoded, additional raw files are created contain the included frames and audio segments. Be warned, the raw video files, being uncompressed, can use a lot of disk space very quickly.

The encoded files default to a ".mov" container and are named using the date and time.

Command line arguments:

birdwatch [--source=[N|URL]][--width=n][--height=n][--help] (etc...)

# Use the default USB webcam

# Use an IP camera at a RTSP URL with login and password
webcam --source=rtsp://

# Use USB camera number 4
webcam --source=4

# Set preferred video width to 640
webcam --width=640

# Set preferred video height to 480
webcam --height=480

# Set the FPS to a specific value, avoiding testing
webcam --fps=18

# Split the main screen between all the video sources
webcam --split

# Start recording with the main screen
webcam --main

# Do not buffer frames and audio for later encoding.
video is recorded to MJPEG in MKV.
webcam --unbuffered

# Send frames directly to Theora for live recording.
webcam --direct_theora

# Record audio and video and "mux" the result to a MPEG file
webcam --muxing

# Flip horizontally or vertically or both
webcam --flip=horizontal --flip=vertical

# Record and encode audio (turned on automatically if muxing)
webcam --audio

# Reopen old .bin (temporary files) to encode. Record is turned off.
webcam --old

# Do not scan for USB cameras.
webcam --no_scan

Output from ldd (list of libraries): (0x00007ffe625f5000) => /lib/x86_64-linux-gnu/ (0x00007f2e1e2cc000) => /usr/local/lib/ (0x00007f2e1c75b000) => /usr/local/lib/ (0x00007f2e1c6b8000) => /usr/local/lib/ (0x00007f2e1b433000) => /usr/local/lib/ (0x00007f2e1b3d2000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1b382000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1b373000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1b345000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1b29a000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1b28f000) => /usr/local/lib/ (0x00007f2e1b27e000) => /usr/local/lib/ (0x00007f2e1b24b000) => /lib/x86_64-linux-gnu/ (0x00007f2e1b226000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1b0fd000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1ae85000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e198c4000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e198a2000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1980d000) => /lib/x86_64-linux-gnu/ (0x00007f2e19802000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e19620000) => /lib/x86_64-linux-gnu/ (0x00007f2e194d1000) => /lib/x86_64-linux-gnu/ (0x00007f2e194b6000) => /lib/x86_64-linux-gnu/ (0x00007f2e192c4000)
	/lib64/ (0x00007f2e1e339000) => /lib/x86_64-linux-gnu/ (0x00007f2e19298000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1921e000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e191a0000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e19059000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18ff9000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18ed0000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18ebe000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18eab000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18e6d000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18dbc000) => /lib/x86_64-linux-gnu/ (0x00007f2e18db1000) => /lib/x86_64-linux-gnu/ (0x00007f2e18d95000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18d0e000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18ca4000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18c6c000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18beb000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18b95000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e188b6000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18791000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18696000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1864a000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18645000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1861c000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18612000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1860c000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e184cf000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e184bb000) => /usr/local/cuda-11.2/lib64/ (0x00007f2e182b4000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e180fa000) => /lib/x86_64-linux-gnu/ (0x00007f2e180e5000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e18098000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e17eab000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e17e95000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e17e44000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e17c6e000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e17be0000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e179a8000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1799c000) => /lib/x86_64-linux-gnu/ (0x00007f2e17973000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e17761000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1774b000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e16e1e000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e16d8f000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e16d84000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e168e6000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e15b02000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e15af3000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e15a79000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e15a4e000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e159ef000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e157e4000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e157c6000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e15789000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e15767000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e15741000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e15725000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e156f9000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1543b000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e144cd000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e143b8000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1434d000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1413e000) => /lib/x86_64-linux-gnu/ (0x00007f2e14122000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1411c000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1410e000) => /lib/x86_64-linux-gnu/ (0x00007f2e1409b000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1401e000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13fe0000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13f5d000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13eb2000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13ca4000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13c5f000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13c3e000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13c34000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13b8b000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13b44000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13a85000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13a80000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13a56000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13a47000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1383d000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13826000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1381e000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13638000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e135d8000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e134a0000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1347f000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e132fd000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e132e7000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e132ad000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13276000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e131f0000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e130d2000) => /lib/x86_64-linux-gnu/ (0x00007f2e130af000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13062000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e13056000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1302c000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e12e4b000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e12e39000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e12dea000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e12ddd000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e12d99000) => /lib/x86_64-linux-gnu/ (0x00007f2e12d6c000) => /lib/x86_64-linux-gnu/ (0x00007f2e12d3e000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e12d38000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e12d30000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1126d000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e11190000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1115f000) => /lib/x86_64-linux-gnu/ (0x00007f2e11158000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e11149000) => /lib/x86_64-linux-gnu/ (0x00007f2e110e7000) => /lib/x86_64-linux-gnu/ (0x00007f2e110bc000) => /lib/x86_64-linux-gnu/ (0x00007f2e110a0000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e11087000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1106a000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e1105f000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e10f58000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e10f3e000) => /lib/x86_64-linux-gnu/ (0x00007f2e10f37000) => /lib/x86_64-linux-gnu/ (0x00007f2e10ee0000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e10e50000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e10e44000) => /usr/lib/x86_64-linux-gnu/ (0x00007f2e10e17000)

The Cow