...
The settings file flash_handler_publish.sdp describes SDP for streams published from a Flash an RTMP client. By default, the file contains the following SDP configuration:
Code Block | ||
---|---|---|
| ||
v=0 o=- 1988962254 1988962254 IN IP4 0.0.0.0 c=IN IP4 0.0.0.0 t=0 0 a=sdplang:en m=video 0 RTP/AVP 119 127 a=rtpmap:119 H264/90000 a=fmtp:119 profile-level-id=42e01f;packetization-mode=1 a=rtpmap:127 FLV/90000 a=sendonly m=audio 0 RTP/AVP 97 8 0 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 a=rtpmap:97 SPEEX/16000 a=rtpmap:8 PCMA/8000 a=rtpmap:0 PCMU/8000 a=rtpmap:102 mpeg4-generic/48000/1 a=rtpmap:103 mpeg4-generic/44100/1 a=rtpmap:104 mpeg4-generic/32000/1 a=rtpmap:105 mpeg4-generic/24000/1 a=rtpmap:106 mpeg4-generic/22050/1 a=rtpmap:107 mpeg4-generic/16000/1 a=rtpmap:108 mpeg4-generic/12000/1 a=rtpmap:109 mpeg4-generic/11025/1 a=rtpmap:110 mpeg4-generic/8000/1 a=rtpmap:111 mpeg4-generic/48000/2 a=rtpmap:112 mpeg4-generic/44100/2 a=rtpmap:113 mpeg4-generic/32000/2 a=rtpmap:114 mpeg4-generic/24000/2 a=rtpmap:115 mpeg4-generic/22050/2 a=rtpmap:116 mpeg4-generic/16000/2 a=rtpmap:117 mpeg4-generic/12000/2 a=rtpmap:118 mpeg4-generic/11025/2 a=rtpmap:119 mpeg4-generic/8000/2 a=sendonly |
Note that changing this file allows to add or remove audio and video streams support only, but not to change codec used by publisher.
For example, if audio description is removed from flash_handler_publish.sdp
file
Code Block | ||
---|---|---|
| ||
v=0
o=- 1988962254 1988962254 IN IP4 0.0.0.0
c=IN IP4 0.0.0.0
t=0 0
a=sdplang:en
m=video 0 RTP/AVP 119 127
a=rtpmap:119 H264/90000
a=fmtp:119 profile-level-id=42e01f;packetization-mode=1
a=rtpmap:127 FLV/90000
a=sendonly
|
then a stream from RTMP encoder will be video only stream on WCS even if it si published as video+audio stream by a client.
flash_handler_play.sdp
The settings file flash_handler_play.sdp describes SDP for streams played on a Flash client. By default, the file contains the following SDP configuration:
...
Note that audio sample rates lower than 32000 Hz are not sypported yet
mse.sdp
Since build 5.2.758 the file mse.sdp describes SDP settings for MSE stream playback. By default, the following settings are used:
Code Block | ||
---|---|---|
| ||
v=0
o=- 1988962254 1988962254 IN IP4 0.0.0.0
c=IN IP4 0.0.0.0
t=0 0
a=sdplang:en
m=video 0 RTP/AVP 112
a=rtpmap:112 H264/90000
a=fmtp:112 packetization-mode=1; profile-level-id=420020
a=recvonly
m=audio 0 RTP/AVP 108 96 97 98 99 100 102 103 104
a=rtpmap:108 mpeg4-generic/48000/1
a=rtpmap:96 mpeg4-generic/8000/1
a=rtpmap:97 mpeg4-generic/11025/1
a=rtpmap:98 mpeg4-generic/12000/1
a=rtpmap:99 mpeg4-generic/16000/1
a=rtpmap:100 mpeg4-generic/22050/1
a=rtpmap:104 mpeg4-generic/24000/1
a=rtpmap:102 mpeg4-generic/32000/1
a=rtpmap:103 mpeg4-generic/44100/1
a=recvonly |
mpegts_agent.sdp
Since build 5.2.1214 the file mpegts_agent.sdp describes SDP settings for MPEG-TS stream publishing. By default, the following settings are used:
Code Block | ||
---|---|---|
| ||
v=0
o=- 1988962254 1988962254 IN IP4 0.0.0.0
c=IN IP4 0.0.0.0
t=0 0
a=sdplang:en
m=audio 1 RTP/AVP 102
a=rtpmap:102 mpeg4-generic/44100/2
a=sendonly
m=video 1 RTP/AVP 119
a=rtpmap:119 H264/90000
a=sendonly |
Audio stream channels number configuration
According to RFC 4566, audio stream channels number can be omitted if one channel is used (mono). Since build 5.2.859, audio stream channels number can be omitted while describing custom SDP, in this case mono audio will be published or played
Code Block | ||
---|---|---|
| ||
a=rtpmap:102 mpeg4-generic/48000
a=rtpmap:103 mpeg4-generic/44100 |
When it is not known if mono or stereo will be published, it is recommended to describe all the possible channel numbers setting an unique payload type to each
Code Block | ||
---|---|---|
| ||
a=rtpmap:102 mpeg4-generic/44100/1
a=rtpmap:103 mpeg4-generic/44100/2
a=rtpmap:104 mpeg4-generic/48000/1
a=rtpmap:105 mpeg4-generic/48000/2 |
Publishing codecs negotiation
If a stream is published with a codec which is not in SDP settings (for example, SDP contains AAC stereo only, but AAC mono is published), the publishing will fail with No common codecs
error.