-
-
Notifications
You must be signed in to change notification settings - Fork 5.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support composited bridges for 1:N protocols converting. v6.0.41 #3392
Conversation
1. Rename SrsRtcFromRtmpBridge to SrsRtmpToRtcBridge 2. Rename SrsRtmpFromRtcBridge to SrsRtcToRtmpBridge 3. Rename SrsRtmpFromSrtBridge to SrsSrtToRtmpBridge
c3b2cbe
to
368af29
Compare
The current structure may have one issue. If all bridges are closed, any protocol can push the same named stream. For example, rtmp can push live/livestream, srt can push live/livestream, rtc can push live/livestream. However, these three streams have different content. In the future, it may be possible to create an independent source that is not tied to any specific protocol, which can be used to manage streams.
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok
c056094
to
2ac9eb8
Compare
In SRS 5.0, the bridge is attached to source, used to covert from one protocol to another one. For example, when configured RTMP to RTC:
When publish stream to SRS by RTMP client, a bridge will be created and attached to source:
Then all RTMP packets will be fed to bridge and allowd to be devliered by WebRTC. Similarly, a
SrsSrtToRtmpBridge
is used to convert SRT to RTMP stream, and aSrsRtcToRtmpBridge
is for coverting RTC to RTMP.It works well for
SRT => RTMP
,RTMP => RTC
,RTC => RTMP
. But, what happends if needSRT => RTC
? Well, it actually combiles two bridges, firstSRT => RTMP
thenRTMP => RTC
, this is complex and an extra layer is introduced, this PR is to refine the bridge to allow directly and simultaneously coverting, such as:In this PR, we need to:
YyyFromXxxBridge
toXxxToYyyBridge
, which is better name, for example, renameSrsRtcFromRtmpBridge
toSrsRtmpToRtcBridge
SrsSharedPtrMessage
as message between all bridges.