Video Generator

Usage

videogen.exe [settings_file]
videogen.exe --help
ArgumentDescription
settings_filePath to settings.txt (default: settings.txt)

Description

The video generator waits for motion triggers, then merges camera feeds into composite output frames, encodes them to H.264 video, and optionally launches an upload script.

Feed Merging

Output frames are composited from two camera feeds:

Display TypeTop Half (540 lines)Bottom Half (540 lines)
Type 0/1Feed 1 (middle camera)Feed 0 (top of hill camera)
Type 2Feed 1 (middle camera)Feed 2 (bottom of hill camera)

The display type is determined by the motion detection trigger — which feed detected the jumper determines which composite view is used.

Encoding

Frames are piped to FFmpeg via stdin as raw YUV420:

FFmpeg must be available at C:\ffmpeg\bin\ffmpeg.exe or in the same directory as videogen.exe.

Double Buffering

Output uses two feed slots (0 and 1). While one is being written by the encoder, the other is available for the viewer to read. The active slot flips after each movie is complete.

Movie Boundaries

min_frames=60       # Minimum clip length (1 second at 60fps)
max_frames=520      # Maximum clip length (buffer size)
movie_pad=30        # Extra frames before/after motion event

Upload

After encoding completes, videogen can launch an upload script via CreateProcess. Configure the upload command in settings.

See Also