Help Center/ Video On Demand/ Troubleshooting/ Video Freezes While Being Played
Updated on 2023-10-10 GMT+08:00

Video Freezes While Being Played

Symptom

A media file freezes when being played on the console or using a player. It is possible that:

  • The input file is corrupt.
  • The network bandwidth is insufficient. As a result, audio and video are not downloaded completely.
  • The decoding performance of the playback device is poor. As a result, audio and video cannot be decoded or rendered promptly.
  • The media file has not been pre-loaded so the user needs to obtain the file from the VOD origin server upon the first access.

You can play the input file on your local PC. If the input file can be played, perform the following operations to rectify the fault.

Pre-loading Media Files

Pre-load the media file on the VOD console or by calling APIs to distribute the media file to CDN nodes. In this way, the cache can be directly hit upon the first access, which prevents frame freezing during the first playback.

Change Hardware Configurations of the Playback Device

If the playback device has too low hardware configurations, the encoding and decoding speeds will become slow. As a result, freeze occurs. You can change hardware configurations of the playback device and play it again.

Change the Network Environment

If the network environment on the player side is poor, data may fail to be downloaded promptly. As a result, freeze occurs.

Perform an online bandwidth test. If the downlink bandwidth is insufficient, you are advised to switch the network environment. In the mean time, check whether downloading occupies high bandwidth. It is recommended that you do not perform any operations (such as downloading) that will occupy a large amount of bandwidth while playing.

Select Hard Decoding

Decoding HD videos requires higher decoding performance. If the decoding performance of the playback device is not good enough, the decoding speed may be slower than the video playback speed. In this case, use hard decoding to avoid video freezes.

Set the Buffer Size

To stop the video from freezing, you can enable the player to buffer some data before decoding and playback. However, if the player buffers too much audio and video data, the time to first frame (TTFF) will increase. Increase the buffer size of the player so that the player can download sufficient data each time before playing the content. However, this will also prolong the TTFF. Therefore, when setting the buffer size, you need to consider freeze and TTFF based on your needs to achieve a balance.

Select a Suitable Resolution

Playback of UHD, 2K, or 4K videos has high requirements on the downlink network and playback devices. If too high resolution videos are played on mobile devices, you cannot even notice the difference with other lower resolution videos. Therefore, when the video freezes, switch to a lower resolution so that content can load faster. In this way, video freezes can be avoided.