The instant loading feature aims at minimizing the time that elapses from the time when the playback starts to the time when the first frame appears. This topic describes how to implement instant loading on various clients.
Compared with the Real-Time Messaging Protocol (RTMP), HTTP-FLV uses a more stable protocol structure. In addition, HTTP-FLV is widely used. We recommend that apps use HTTP-FLV to play streams.
- PC browsers
PC browsers generally use Flash players as plug-ins to play streams. However, Flash players require buffering before playback, which makes it difficult to implement instant loading.
- Mobile browsers
Safari works well with the HTTP Live Streaming (HLS) protocol. Streams can be played based on the URLs in .m3u8 files.
- The hardware decoding chips of iOS mobile phones can help with stream playback. Instant loading can be achieved if the DNS records of streaming URLs are cached.
- For Android mobile phones, the effect of instant loading varies depending on the mobile phone models and operating system versions.