Source Stream Element

Source elements bring in data and push it into the pipeline, they contain three mandatory fields and two optional fields: address, rate and type and timeout and enable_proxy respectively.

{
    "address" : "string",
    "rate" : "integer",
    "type" : "string",
    "timeout" :"integer",
    "proxy": "bool"
}
  • address is a url to a camera or video stream or a zmq publisher.

  • rate is the desired input data rate for the source, sources that provide data faster than the rate will drop packets appropriately.

  • type is the source type, there are 5 different options:
    • video : https or rtsp video stream.

    • file : stream from a video file.

    • youtube : stream from a youtube video.

    • zmqinternal : for connecting nimble containers together, must be connected to a nimble zmqinternal sink.

    • zmqstream from an external zmq publisher.
      • inf : infinite source of random data.

  • timeout if source is disconnected try to reconnect for the specified many minutes, -1 is try indefinitely.

  • proxy: if false this will disable the MP4 Proxy Server for trans-encoding the input stream to streaming MP4 for consumption by a GUI.

Adding your own camera feeds

Using your own cameras involves modifying the config.json, a sample is provided in samples/c1_camera_person-detection.json. Setup steps are as follows:
  • First make sure the camera is accessible by the host machine.

  • Copy samples/c1_camera_person-detection.json to config.json: cp samples/c1_camera_person-detection.json config.json

  • Modify config.json, replace <CAMERA_FEED_HERE> with your rstp/http address. Leave rate as 30 and type as video

  • Run the demo: docker-compose up

Known Issues

  • There is a rare GStreamer issue that prevents the source from starting, the fix is currently to restart Nimble.