Skip to main content

"file" Source

Reads video data from an MP4 file (.mp4), decodes the frames, and creates a new metadata object for each one.

This source is primarily used in a debug environment for testing and demo purposes.

Along with the required source parameter type, the file source accepts the following additional properties:

  • address: The local path, relative to the current working directory, of the video file to read. If running in a Docker container, any sample video files must be volume-mounted into the container at runtime.
  • rate: The ingestion and playback rate of the video file. Optional, if omitted playback will occur at the video-defined speed.

Examples

REST API

Create Source:

{
"type": "file",
"address": "videos/sample.mp4",
"rate": 30
}

Configuration File

Sample:

sources:
- type: file
address: videos/sample.mp4
rate: 30