Low latency streaming with Axis cameras

From SpinetiX Support Wiki

Jump to: navigation, search

Applies to: HMP350 devices.


Axis and SpinetiX have teamed up to create a powerful and smart streaming solution. By combining the Axis network cameras with SpinetiX HMP players the screen at shop entrance turns into a Welcome Screen. This smart streaming solution allows retailers to include security as part of their aesthetically pleasing instore-communications.

The HMP player gets the live stream directly from the door-facing Axis network camera and displays it on the Welcome Screen. Furthermore, to make it relevant and targeted to the shopper, HMP players handle event triggering from the Axis network camera, allowing screen content to change based on predefined shop scenarios. For example, every 10th visitors can be rewarded with a coupon triggered by the connected people counter.

Axis and SpinetiX help to create an engaging smart shopping experience with instore-communication that matters to customers making them more loyal.

For more details about this integration, see the official Axis Solution Note communication.

Configure low latency streaming

This tutorial shows how to configure the HMP350 for low latency streaming.

  • Difficulty: Medium.
  • Total duration: 15 - 20 minutes.
  • Requirements:
    • Axis network camera;
    • HMP350 with firmware 4.0.2 or later (the latest firmware is recommended);
    • Elementi 2015 Update 2 or later (the latest Elementi version is recommended).

Getting started

When doing real-time streaming from an Axis camera it is important to reduce as much as possible the streaming latency of the overall system, which is computed as following:

Latency = Camera latency + Network latency + HMP stream decoding latency + HMP rendering latency + Screen latency

Camera latency highly depends on the camera model used and how it is set up (capture rate, image enhancement, compression, buffering, audio). A very good white paper explaining how to reduce the camera latency can be found on Axis website.

Network latency depends on three major factors: the infrastructure (determines the bandwidth), the amount of data produced by the camera (determines the bitrate), and the choice of transmission protocol. As a general rule, network latency is proportional to bitrate and inversely proportional to bandwidth. In a local area network (LAN), the network latency is usually insignificantly low (only a few ms) and can be ignored.

The latency on the HMP side is mainly generated by two processes: the stream decoding and the content rendering. By default, the HMP is conservatively configured with high values for these two for stability and smooth output purposes: 750 milliseconds for stream buffering and 1.5 seconds for render buffering. Both of them can be reduced to lower values for low latency streaming, as detailed below.

Screen latency is induced by the refresh frequency of the screen and shouldn't be more than 30-40 ms. In some cases, image processing options might contribute to the the screen latency - disabling them would help in such cases.

Reduce stream decoding latency

By default, the HMP is conservatively configured to 750 milliseconds of stream buffering for decoding stability purposes.

Reduce stream buffering latency

For reliable RTP streams so much buffering may not be required, in which case it is possible to reduce the stream decoding latency by modifying the project in Elementi - for that follow these steps:

  1. Find the streaming layer within the Edit panel and click its Elementi Icons Layer Properties.png button
  2. Within the "Layer Properties" dialog that opens, select the "Advanced" tab.
  3. Add the "spx:buffering" attribute and set it to a negative duration:
    1. Click on "Name" column to add a new property.
    2. From the drop-down box, select "spx:buffering".
    3. Click on "Value" column.
    4. Enter a negative duration; this will be deducted from the default 750 milliseconds.
      • If no time unit is specified, then seconds is assumed.
      • The value should not be larger than -600ms, to avoid buffer underflows when the latency is too low to handle network delay variations.
    5. Press "Enter" to apply the attribute value.
  4. Add the "spx:packetization" and set it to "compliant". Firmware 4.1.0 or later is required for this.
    • This will further reduce the stream decoding latency by one frame - 25ms or 33ms depending on the streaming frame rate.
  5. Click the OK button to apply the changes.

Reduce HMP rendering latency

By default, the HMP is conservatively configured to 1.5 seconds of render buffering to ensure smooth output at the configured frame rate. The rendering latency can be easily reduced down to 250 milliseconds from the Advanced Applications > Interactivity page of HMP Control Center. For more details, see how to reduce the rendering latency.

If required, it is possible to further reduce the HMP rendering latency, to ultra-low values: 200ms, 100ms, or 50ms - for that follow these steps:

  1. Download the "Ultra-low latency configuration" archive on the right side.
    • It contains three configuration backup files for setting the HMP rendering latency to 50ms (config_50ms.xml), 100ms (config_100ms.xml), or 200ms (config_200ms.xml).
  2. Extract the desired configuration file.
  3. Open HMP Control Center home page and find the "Quick Links" section.
  4. Click on "Restore Config".
  5. Browse and select the configuration file extracted above. Click "Open".
  6. Click on the "Restart now" button to apply the new configuration.

Note Note:
In firmware 4.0.2, a bug prevents the ultra-low latency to be correctly displayed in the Interactivity page - the "Maximum rendering latency" drop-down box shows 250ms, regardless of the uploaded configuration file, even though the configuration is successfully applied. To avoid this, update to a newer firmware.

See also

This page was last modified on 28 March 2019, at 11:18.