Declare Plan B DEPRECATED
Bug: webrtc:11121 Change-Id: Id9b933a71a9bfd1d20ddd137f43459cdc8ed1896 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/238780 Reviewed-by: Henrik Boström <hbos@webrtc.org> Commit-Queue: Harald Alvestrand <hta@webrtc.org> Cr-Commit-Position: refs/heads/main@{#35504}
This commit is contained in:
committed by
WebRTC LUCI CQ
parent
7c1461fcb7
commit
fa67aef93f
@ -168,7 +168,11 @@ class StatsObserver : public rtc::RefCountInterface {
|
||||
~StatsObserver() override = default;
|
||||
};
|
||||
|
||||
enum class SdpSemantics { kPlanB, kUnifiedPlan };
|
||||
enum class SdpSemantics {
|
||||
kPlanB_DEPRECATED,
|
||||
kPlanB [[deprecated]] = kPlanB_DEPRECATED,
|
||||
kUnifiedPlan
|
||||
};
|
||||
|
||||
class RTC_EXPORT PeerConnectionInterface : public rtc::RefCountInterface {
|
||||
public:
|
||||
@ -622,24 +626,23 @@ class RTC_EXPORT PeerConnectionInterface : public rtc::RefCountInterface {
|
||||
// WebRTC 1.0 specification requires kUnifiedPlan semantics. The
|
||||
// RtpTransceiver API is only available with kUnifiedPlan semantics.
|
||||
//
|
||||
// kPlanB will cause PeerConnection to create offers and answers with at
|
||||
// most one audio and one video m= section with multiple RtpSenders and
|
||||
// RtpReceivers specified as multiple a=ssrc lines within the section. This
|
||||
// will also cause PeerConnection to ignore all but the first m= section of
|
||||
// the same media type.
|
||||
//
|
||||
// kUnifiedPlan will cause PeerConnection to create offers and answers with
|
||||
// multiple m= sections where each m= section maps to one RtpSender and one
|
||||
// RtpReceiver (an RtpTransceiver), either both audio or both video. This
|
||||
// will also cause PeerConnection to ignore all but the first a=ssrc lines
|
||||
// that form a Plan B stream.
|
||||
//
|
||||
// For users who wish to send multiple audio/video streams and need to stay
|
||||
// interoperable with legacy WebRTC implementations or use legacy APIs,
|
||||
// specify kPlanB.
|
||||
// kPlanB will cause PeerConnection to create offers and answers with at
|
||||
// most one audio and one video m= section with multiple RtpSenders and
|
||||
// RtpReceivers specified as multiple a=ssrc lines within the section. This
|
||||
// will also cause PeerConnection to ignore all but the first m= section of
|
||||
// the same media type.
|
||||
//
|
||||
// For users who have to interwork with legacy WebRTC implementations,
|
||||
// it is possible to specify kPlanB until the code is finally removed.
|
||||
//
|
||||
// For all other users, specify kUnifiedPlan.
|
||||
SdpSemantics sdp_semantics = SdpSemantics::kPlanB;
|
||||
SdpSemantics sdp_semantics = SdpSemantics::kPlanB_DEPRECATED;
|
||||
|
||||
// TODO(bugs.webrtc.org/9891) - Move to crypto_options or remove.
|
||||
// Actively reset the SRTP parameters whenever the DTLS transports
|
||||
|
||||
@ -2540,7 +2540,7 @@ void PeerConnection::ReportSdpBundleUsage(
|
||||
} else {
|
||||
usage = kBundleUsageEmpty;
|
||||
}
|
||||
} else if (configuration_.sdp_semantics == SdpSemantics::kPlanB) {
|
||||
} else if (configuration_.sdp_semantics == SdpSemantics::kPlanB_DEPRECATED) {
|
||||
// In plan-b, simple/complex usage will not show up in the number of
|
||||
// m-lines or BUNDLE.
|
||||
usage = using_bundle ? kBundleUsageBundlePlanB : kBundleUsageNoBundlePlanB;
|
||||
|
||||
@ -112,13 +112,13 @@ SdpSemantics JavaToNativeSdpSemantics(JNIEnv* jni,
|
||||
std::string enum_name = GetJavaEnumName(jni, j_sdp_semantics);
|
||||
|
||||
if (enum_name == "PLAN_B")
|
||||
return SdpSemantics::kPlanB;
|
||||
return SdpSemantics::kPlanB_DEPRECATED;
|
||||
|
||||
if (enum_name == "UNIFIED_PLAN")
|
||||
return SdpSemantics::kUnifiedPlan;
|
||||
|
||||
RTC_DCHECK_NOTREACHED();
|
||||
return SdpSemantics::kPlanB;
|
||||
return SdpSemantics::kPlanB_DEPRECATED;
|
||||
}
|
||||
|
||||
ScopedJavaLocalRef<jobject> NativeToJavaCandidatePairChange(
|
||||
|
||||
@ -520,7 +520,7 @@
|
||||
+ (webrtc::SdpSemantics)nativeSdpSemanticsForSdpSemantics:(RTCSdpSemantics)sdpSemantics {
|
||||
switch (sdpSemantics) {
|
||||
case RTCSdpSemanticsPlanB:
|
||||
return webrtc::SdpSemantics::kPlanB;
|
||||
return webrtc::SdpSemantics::kPlanB_DEPRECATED;
|
||||
case RTCSdpSemanticsUnifiedPlan:
|
||||
return webrtc::SdpSemantics::kUnifiedPlan;
|
||||
}
|
||||
@ -528,7 +528,7 @@
|
||||
|
||||
+ (RTCSdpSemantics)sdpSemanticsForNativeSdpSemantics:(webrtc::SdpSemantics)sdpSemantics {
|
||||
switch (sdpSemantics) {
|
||||
case webrtc::SdpSemantics::kPlanB:
|
||||
case webrtc::SdpSemantics::kPlanB_DEPRECATED:
|
||||
return RTCSdpSemanticsPlanB;
|
||||
case webrtc::SdpSemantics::kUnifiedPlan:
|
||||
return RTCSdpSemanticsUnifiedPlan;
|
||||
|
||||
Reference in New Issue
Block a user