RTMP vs. RTSP

: Thanusri swetha J October 20, 10:47 AM Technology

RTMP and RTSP are both streaming protocols, meaning they are sets of rules that govern how data travels from one system of communication to another. If the video data you’re trying to send to your viewers is a car, then the streaming protocol is the road that the car takes to get from one place to another.

Choosing between RTMP vs. RTSP streaming protocols greatly depends on your individual business needs and how many extra steps you are willing to take to make your content playable on your website.[1]

Figure 1. The RTMP vs. RTSP

Figure 1 shows RTMP and RTSP video streaming protocols allow users to view content in any web browser and on most mobile devices.

RTMP and RTSP are both streaming protocols, meaning they are sets of rules that govern how data travels from one system of communication to another. If the video data you’re trying to send to your viewers is a car, then the streaming protocol is the road that the car takes to get from one place to another.

The two most common streaming protocols are RTMP and RTSP. [2]

5 different between RTMP and RTSP:

IP Cameras - RTSP

A vast majority of IP cameras support the RTSP protocol so it’s a pretty easy selection for that one. IP cameras were around well before the invention of RTMP, and since RTSP was (and is) a very effective solution, there was no need to change it. Thus the earlier development of RTSP encouraged the adoption of RTSP for IP cameras.

Due to the way that IP cameras work, the camera itself acts as an RTSP server. This means that in order to connect to the IP camera server and consume the stream, you have to run an RTSP client. Red5 Pro’s Restreamer plugin does exactly this by providing a way to connect to an RTSP stream as a client and restream it to other Red5 Pro supported endpoints, like a browser running WebRTC. For more details on the restreamer plugin, check out this post.

IoT Devices - RTSP or RTMP

Drones, robots and other devices benefit greatly from sending live video. The video not only allows us to see what the device sees but also assists in the control of the device. RTSP support is often built right into the drone or IoT software and is a common way to access the video feed. However, some manufacturers, such as DJI, use RTMP so this may depend upon the specific device in use.

Red5 Pro Mobile SDK – RTSP

Normally, mobile devices do not accept RTSP as they do not have native support for it. However, the Red5 Pro mobile SDK uses RTSP to deliver live streams to and from mobile devices on a native app. By creating a single connection per subscriber/publisher client, both Android and iOS devices can use RTSP as a simple way to connect a large number of broadcasters to a large number of subscribers.

YouTube, Twitch, Facebook – RTMP

Even though 2020 marks the end of life for Flash Media Player, the RTMP protocol will still be useful. For example, Red5 Pro’s implementation of RTMP is able to achieve sub-one-second latency. Though RTMP is synonymous with Flash, the protocol will outlive the player.

Older Hardware Encoder – RTMP

Some hardware encoders (especially older ones) will only accept RTMP streams. That makes it pretty obvious which one to use. However, it should be noted that many hardware encoders are switching to SRT based encoders due to the fact that it is open-source and optimizes live stream delivery through firewalls and across unreliable networks. [3]

References:
  1. https://www.dacast.com/blog/video-streaming-protocol/
  2. https://www.dacast.com/blog/rtmp-vs-rtsp/
  3. https://www.red5pro.com/blog/5-ways-to-decide-between-rtmp-vs-rtsp/
Cite this article:

Thanusri swetha J (2021), RTMP vs. RTSP, Anatechmaz, pp. 23

Recent Post

Blog Archive