Professional Documents
Culture Documents
Streaming Protocols
Headend
CDN
Source
• Hardware to:
− receive and demultiplex
channels from different
sources
• Via cable or satellite
− Decode incoming streams
− Multiplex into channels for
distribution
− Encode for receiving
equipment
− transmit media
− Payload type
− Sequentie nummer
− Timestamp
Packets sent
d1 d1+y
Packets received
h h-y
Packets playout
timeline
Sender
1 2 3 4 5 6 7
(a)
(b)
1 2 3 5 7 6
Receiver
• Ffmpeg
− Ffmpeg -re -i video.mp4 –preset ultrafast –c:v libx264 -tune
zerolatency -bitrate 900k -f rtp_mpegts rtp://localhost:1234
− Ffmpeg -re -i video.mp4 –preset ultrafast –c:v libx264 -tune
zerolatency -bitrate 900k -f mpegts udp://localhost:1234
• Vlc
• FFPlay
− ffplay rtp://localhost:1234
− ffplay udp://localhost:1234
• vlc
• ffmpeg -i bbb_sunflower_1080p_30fps_normal.mp4 -
preset ultrafast -vcodec copy -tune zerolatency -b 900k
-f mpegts rtp://localhost:1234
srtp_in_suite
srtp_out_suite
− Select input and output encoding suites.
− Supported values:
• ‘AES_CM_128_HMAC_SHA1_80’
• ‘SRTP_AES128_CM_HMAC_SHA1_80’
• ‘AES_CM_128_HMAC_SHA1_32’
• ‘SRTP_AES128_CM_HMAC_SHA1_32’
srtp_in_params
srtp_out_params
− Set input and output encoding parameters, which are expressed by a base64-encoded representation of a binary block. The first 16
bytes of this binary block are used as master key, the following 14 bytes are used as master salt.
− If the connection is unsuccessful, you should move the connection to use RTMPT,
which is RTMP encapsulated over HTTP. Firewalls will not block this connection,
because it makes RTMP “hide” behind HTTP traffic on port 80.
• rtmpt://your_ip_address:80/app_name
• You should not use RTMPT at all times because there’s a performance
issue, there is an overhead on top of each packet sent.