vod_min_single_nalu_per_frame_segment

The `vod_min_single_nalu_per_frame_segment` directive configures the minimum number of Network Abstraction Layer Units (NALUs) required per frame when packaging video segments in NGINX-based video on demand (VOD) scenarios.

Syntaxvod_min_single_nalu_per_frame_segment number;
Defaultnone
Contexthttp, server, location
Arguments1

Description

The vod_min_single_nalu_per_frame_segment directive is particularly relevant for optimizing the packaging of video files into various streaming formats such as DASH and HLS. By specifying a minimum threshold for the number of single NALUs per frame, this directive ensures that the segmented video files adhere to specific encoding requirements and improve playback performance by ensuring that segments are not excessively small, which could hinder streaming efficiency.

This directive takes a single integer argument that defines the minimum number of NALUs that must be included in each frame segment. If a frame contains fewer NALUs than the specified number, it may be discarded or adjusted based on the packaging logic defined in the NGINX VOD module. By tuning this directive, content providers can manage the balance between segment size and encoding quality, which is crucial for providing an optimal viewing experience over variable network conditions. Fine-tuning this parameter can also aid in adaptive bitrate streaming, where having the right segment characteristics can influence which streams are served to users based on their connection and device capabilities.

Config Example

http {
    server {
        location /vod {
            vod_min_single_nalu_per_frame_segment 4;
        }
    }
}

Setting the value too low may lead to suboptimal playback performance due to excessively small segments.

Inappropriately high values can lead to increased latency and buffering if segments take too long to compile during streaming.

← Back to all directives