wait_video
The `wait_video` directive in the NGINX RTMP module controls the duration clients must wait before accessing a video stream.
Description
The wait_video directive is part of the NGINX RTMP module, which is designed for media streaming. This directive allows server administrators to specify a waiting period that clients must endure before they can access a video stream. The purpose of this functionality is to ensure that viewers have a synchronized starting point, enhancing the overall experience by providing them an opportunity to begin watching the stream from the start or a designated point in time.
This directive takes a single argument, which is the waiting duration specified in seconds. For instance, if you set wait_video 30;, clients will have to wait for 30 seconds when they attempt to access the stream. Once the set duration passes, users will be able to seamlessly access the video content. This can be particularly useful in live streaming scenarios where you want to avoid a staggered viewing experience among multiple viewers connecting at different times.
Furthermore, careful consideration should be given to the value of this parameter, as setting it too high may frustrate users, while setting it too low might not achieve the intended synchronization effect. It's essential to tailor this directive based on the nature of the content being streamed and the expected audience behavior.
Config Example
rtmp {
server {
listen 1935;
application live {
live on;
wait_video 30;
}
}
}Ensure the wait time does not negatively impact user experience.
Setting a value of zero may result in immediate access, which could negate the directive's purpose.
Check if related streaming setups (like low-latency) are affected by this directive's functionality.