# SSRC Value

**URL:** <https://mediasoup.discourse.group/t/ssrc-value/1006>\
**Category:** mediasoup libraries\
**Created:** [May 13, 2020, 12:33pm UTC](https://mediasoup.discourse.group/t/ssrc-value/1006 "2020-05-13T12:33:10Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![OG-RTC](https://avatars.discourse-cdn.com/v4/letter/o/f475e1/32.png) [@OG-RTC](https://mediasoup.discourse.group/u/OG-RTC)\
**Post date:** [May 13, 2020, 12:33pm UTC](https://mediasoup.discourse.group/t/ssrc-value/1006/1 "2020-05-13T12:33:10Z")

</div>

Hi,  
Is it normal to see a always changing SSRC in the consumer.getStats?

[http://paste.ubuntu.com/p/9TCfSVpBZc/](http://paste.ubuntu.com/p/9TCfSVpBZc/)

If I want to output the RTPPlain to FFMEPG OR GST, is the SSRC value mandatory? Which one should I load?

---

<div class="post-metadata">

**Author:** ![ibc](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/ibc/32/1540_2.png) [@ibc](https://mediasoup.discourse.group/u/ibc)\
**Post date:** [May 13, 2020, 3:27pm UTC](https://mediasoup.discourse.group/t/ssrc-value/1006/2 "2020-05-13T15:27:02Z")

</div>

This is documented. I understand that what to put in `RtpParameters` is hard, but this is documented:

- [https://mediasoup.org/documentation/v3/mediasoup/api/#PlainTransportOptions](https://mediasoup.org/documentation/v3/mediasoup/api/#PlainTransportOptions)
- [https://mediasoup.org/documentation/v3/mediasoup/rtp-parameters-and-capabilities/#RtpSendParameters](https://mediasoup.org/documentation/v3/mediasoup/rtp-parameters-and-capabilities/#RtpSendParameters)

---

<div class="post-metadata">

**Author:** ![OG-RTC](https://avatars.discourse-cdn.com/v4/letter/o/f475e1/32.png) [@OG-RTC](https://mediasoup.discourse.group/u/OG-RTC)\
**Post date:** [May 13, 2020, 3:29pm UTC](https://mediasoup.discourse.group/t/ssrc-value/1006/3 "2020-05-13T15:29:07Z")

</div>

Thanks IBC, so mainly I should provide the same listtype of RTPParams for an ffmpeg inputing into mediasoup ?  
“[select=a:f=rtp:ssrc={AUDIO\_SSRC}:payload\_type={AUDIO\_PT}]rtp://{audioTransportIp}:{audioTransportPort}?rtcpport={audioTransportRtcpPort}|[select=v:f=rtp:ssrc={VIDEO\_SSRC}:payload\_type={VIDEO\_PT}]rtp://{videoTransportIp}:{videoTransportPort}?rtcpport={videoTransportRtcpPort}”

\<— those are used for rtpIN, I should use the same type for an rtp out right? no additional stuff

---

<div class="post-metadata">

**Author:** ![ibc](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/ibc/32/1540_2.png) [@ibc](https://mediasoup.discourse.group/u/ibc)\
**Post date:** [May 13, 2020, 3:34pm UTC](https://mediasoup.discourse.group/t/ssrc-value/1006/4 "2020-05-13T15:34:56Z")

</div>

For RTP in… I don’t know much about ffmpeg but something like that.

For RTP out: no, you must read the server side generated `Consumer`: [https://mediasoup.org/documentation/v3/communication-between-client-and-server/#consuming-media-in-an-external-endpoint](https://mediasoup.org/documentation/v3/communication-between-client-and-server/#consuming-media-in-an-external-endpoint)

---

<div class="post-metadata">

**Author:** ![OG-RTC](https://avatars.discourse-cdn.com/v4/letter/o/f475e1/32.png) [@OG-RTC](https://mediasoup.discourse.group/u/OG-RTC)\
**Post date:** [May 13, 2020, 3:56pm UTC](https://mediasoup.discourse.group/t/ssrc-value/1006/5 "2020-05-13T15:56:21Z")

</div>

I have been on this for days now, I am in close contact with the gstreamer community and no-one is really finding an answer for this, they tell me check with the mediasoup guys how they send their RTP.

And I am stuck in the middle here is the pipeline I came up with :to read from mediasoup consumer plain rtp.

The data is being sent correctly from mediasoup to RTP as I capured the packets audio and video and their payload types from the pcap files.

Here is my command:  
GST\_DEBUG=4 gst-launch-1.0 rtpbin name=rtpbin latency=50 buffer-mode=0 sdes=“application/x-rtp-source-sdes” udpsrc port=5557 caps=“application/x-rtp,media=(string)video,clock-rate=(int)90000,payload=(int)101,encoding-name=(string)VP8,ssrc=696790109” ! rtpbin.recv\_rtp\_sink\_0 rtpbin. ! queue ! rtpvp8depay ! webmmux name=mux ! filesink location=123.web

This is for testing video only, I took the SSRC value from the consumer.getStats generated in realtime and executed this command afterwards. I get these errors:

[https://pastebin.com/wbfiv9Ls](https://pastebin.com/wbfiv9Ls)

---

<div class="post-metadata">

**Author:** ![ibc](https://yyz2.discourse-cdn.com/free1/user_avatar/mediasoup.discourse.group/ibc/32/1540_2.png) [@ibc](https://mediasoup.discourse.group/u/ibc)\
**Post date:** [May 13, 2020, 6:35pm UTC](https://mediasoup.discourse.group/t/ssrc-value/1006/6 "2020-05-13T18:35:59Z")

</div>

I don’t know what that is related to the doc I referenced:

> **[mediasoup :: Communication Between Client and Server](https://mediasoup.org/documentation/v3/communication-between-client-and-server/#consuming-media-in-an-external-endpoint)**
>
> Cutting Edge WebRTC Video Conferencing

You asked about the SSRC in RTP-out (Consumer side). Such a link explains that you must read the SSRC and codec payload type, etc etc from the server side `consumer.rtpParameters`. And you must transmit that info to the receiving GStreamer and tell it to receive the corresponding SSRC, payload type, etc.

Other than that, I cannot help with Gstreamer.
