NetworkInputVideoStream

Description

Read a video stream from a network socket (ZeroMQ socket); the video must be streamed by the PPluginOutputVideoStreamNetwork

  • Product name: NetworkInputVideoStream
  • Version: 1.1

Images are read asynchronously and put in a queue. Keep up to 10 images by default (this value can be changed using the MAX_PENDING_IMAGE property). The oldest image is dropped when the queue is full and a there is a new incoming image.

How to read a video streamed by PPluginOutputVideoStreamNetwork?

PResult ret = PInputVideoStream::Open("tcp://127.0.0.1:12345", ivs); // tcp://host:port
if (ret.Failed()) ...
...
PFrame frame;
while (ivs.GetFrame(frame).Ok()) ...

Expected format of URI is: According to your operating system and your network configuration, the following protocols are available:

  • tcp://host:port (unicast transport using TCP)
  • ipc://host:port (local inter-process communication transport, only available for Linux)
  • inproc://host:port (local in-process (inter-thread) communication transport)
  • pgm://host:port (reliable multicast transport using PGM)
  • epgm://host:port (reliable multicast transport using PGM)

Options on query string

None

Get properties

  • MAX_PENDING_IMAGES: int = maximum number of pending images

Set properties

  • MAX_PENDING_IMAGES: set the maximum size of the image queue