Diff
Modified: trunk/LayoutTests/imported/w3c/ChangeLog (271935 => 271936)
--- trunk/LayoutTests/imported/w3c/ChangeLog 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/LayoutTests/imported/w3c/ChangeLog 2021-01-27 08:36:19 UTC (rev 271936)
@@ -1,3 +1,17 @@
+2021-01-27 Youenn Fablet <[email protected]>
+
+ Add support for RTCRtpParameters.rtcp
+ https://bugs.webkit.org/show_bug.cgi?id=220912
+
+ Reviewed by Eric Carlson.
+
+ * web-platform-tests/webrtc/RTCRtpParameters-codecs-expected.txt:
+ * web-platform-tests/webrtc/RTCRtpParameters-encodings-expected.txt:
+ * web-platform-tests/webrtc/RTCRtpParameters-headerExtensions-expected.txt:
+ * web-platform-tests/webrtc/RTCRtpParameters-rtcp-expected.txt:
+ * web-platform-tests/webrtc/RTCRtpParameters-transactionId-expected.txt:
+ * web-platform-tests/webrtc/RTCRtpReceiver-getParameters-expected.txt:
+
2021-01-26 Alex Christensen <[email protected]>
Forbid '|' in URL hosts
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpParameters-codecs-expected.txt (271935 => 271936)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpParameters-codecs-expected.txt 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpParameters-codecs-expected.txt 2021-01-27 08:36:19 UTC (rev 271936)
@@ -1,8 +1,8 @@
-FAIL setParameters() with codec.payloadType modified should reject with InvalidModificationError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with codec.mimeType modified should reject with InvalidModificationError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with codec.clockRate modified should reject with InvalidModificationError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with codec.channels modified should reject with InvalidModificationError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with codec.sdpFmtpLine modified should reject with InvalidModificationError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with new codecs inserted should reject with InvalidModificationError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
+FAIL setParameters() with codec.payloadType modified should reject with InvalidModificationError assert_unreached: Should have rejected: undefined Reached unreachable code
+FAIL setParameters() with codec.mimeType modified should reject with InvalidModificationError assert_unreached: Should have rejected: undefined Reached unreachable code
+FAIL setParameters() with codec.clockRate modified should reject with InvalidModificationError assert_unreached: Should have rejected: undefined Reached unreachable code
+FAIL setParameters() with codec.channels modified should reject with InvalidModificationError assert_unreached: Should have rejected: undefined Reached unreachable code
+FAIL setParameters() with codec.sdpFmtpLine modified should reject with InvalidModificationError assert_unreached: Should have rejected: undefined Reached unreachable code
+FAIL setParameters() with new codecs inserted should reject with InvalidModificationError assert_unreached: Should have rejected: undefined Reached unreachable code
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpParameters-encodings-expected.txt (271935 => 271936)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpParameters-encodings-expected.txt 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpParameters-encodings-expected.txt 2021-01-27 08:36:19 UTC (rev 271936)
@@ -1,16 +1,18 @@
-FAIL addTransceiver() with undefined sendEncodings should have default encoding parameter with active set to true assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL addTransceiver() with empty list sendEncodings should have default encoding parameter with active set to true assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL sender.getParameters() should return sendEncodings set by addTransceiver() assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL sender.setParameters() with mismatch number of encodings should reject with InvalidModificationError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL sender.setParameters() with encodings unset should reject with TypeError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with modified encoding.rid field should reject with InvalidModificationError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with encoding.scaleResolutionDownBy field set to less than 1.0 should reject with RangeError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with encoding.scaleResolutionDownBy field set to greater than 1.0 should succeed assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with modified encoding.active should succeed with RTCRtpTransceiverInit assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with modified encoding.active should succeed without RTCRtpTransceiverInit assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with modified encoding.maxBitrate should succeed with RTCRtpTransceiverInit assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with modified encoding.maxBitrate should succeed without RTCRtpTransceiverInit assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with modified encoding.scaleResolutionDownBy should succeed with RTCRtpTransceiverInit assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with modified encoding.scaleResolutionDownBy should succeed without RTCRtpTransceiverInit assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
+PASS addTransceiver() with undefined sendEncodings should have default encoding parameter with active set to true
+PASS addTransceiver() with empty list sendEncodings should have default encoding parameter with active set to true
+FAIL sender.getParameters() should return sendEncodings set by addTransceiver() assert_not_own_property: rid should be removed with a single encoding unexpected property "rid" is found on object
+FAIL sender.setParameters() with mismatch number of encodings should reject with InvalidModificationError promise_rejects_dom: function "function () { throw e }" threw object "InvalidStateError: Attempted to set RtpParameters with different encoding count" that is not a DOMException InvalidModificationError: property "code" is equal to 11, expected 13
+PASS sender.setParameters() with encodings unset should reject with TypeError
+FAIL setParameters() with modified encoding.rid field should reject with InvalidModificationError assert_not_equals: Expect sender param.rtcp.cname to be set got disallowed value undefined
+FAIL setParameters() with encoding.scaleResolutionDownBy field set to less than 1.0 should reject with RangeError promise_rejects_js: function "function () { throw e }" threw object "InvalidStateError: Attempted to set RtpParameters scale_resolution_down_by to an invalid value. scale_resolution_down_by must be >= 1.0" ("InvalidStateError") expected instance of function "function RangeError() {
+ [native code]
+}" ("RangeError")
+PASS setParameters() with encoding.scaleResolutionDownBy field set to greater than 1.0 should succeed
+PASS setParameters() with modified encoding.active should succeed with RTCRtpTransceiverInit
+PASS setParameters() with modified encoding.active should succeed without RTCRtpTransceiverInit
+PASS setParameters() with modified encoding.maxBitrate should succeed with RTCRtpTransceiverInit
+PASS setParameters() with modified encoding.maxBitrate should succeed without RTCRtpTransceiverInit
+PASS setParameters() with modified encoding.scaleResolutionDownBy should succeed with RTCRtpTransceiverInit
+PASS setParameters() with modified encoding.scaleResolutionDownBy should succeed without RTCRtpTransceiverInit
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpParameters-headerExtensions-expected.txt (271935 => 271936)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpParameters-headerExtensions-expected.txt 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpParameters-headerExtensions-expected.txt 2021-01-27 08:36:19 UTC (rev 271936)
@@ -1,3 +1,3 @@
-FAIL setParameters() with modified headerExtensions should reject with InvalidModificationError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
+FAIL setParameters() with modified headerExtensions should reject with InvalidModificationError assert_not_equals: Expect sender param.rtcp.cname to be set got disallowed value undefined
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpParameters-rtcp-expected.txt (271935 => 271936)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpParameters-rtcp-expected.txt 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpParameters-rtcp-expected.txt 2021-01-27 08:36:19 UTC (rev 271936)
@@ -1,4 +1,4 @@
-FAIL setParameters() with modified rtcp.cname should reject with InvalidModificationError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with modified rtcp.reducedSize should reject with InvalidModificationError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
+FAIL setParameters() with modified rtcp.cname should reject with InvalidModificationError assert_not_equals: Expect sender param.rtcp.cname to be set got disallowed value undefined
+FAIL setParameters() with modified rtcp.reducedSize should reject with InvalidModificationError assert_not_equals: Expect sender param.rtcp.cname to be set got disallowed value undefined
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpParameters-transactionId-expected.txt (271935 => 271936)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpParameters-transactionId-expected.txt 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpParameters-transactionId-expected.txt 2021-01-27 08:36:19 UTC (rev 271936)
@@ -1,7 +1,7 @@
-FAIL sender.getParameters() should return different transaction IDs for each call assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL sender.setParameters() with transaction ID different from last getParameters() should reject with InvalidModificationError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL sender.setParameters() with transaction ID unset should reject with TypeError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() twice with the same parameters should reject with InvalidStateError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL setParameters() with parameters older than last getParameters() should reject with InvalidModificationError assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
+PASS sender.getParameters() should return different transaction IDs for each call
+FAIL sender.setParameters() with transaction ID different from last getParameters() should reject with InvalidModificationError promise_rejects_dom: function "function () { throw e }" threw object "InvalidStateError: Failed to set parameters since the transaction_id doesn't match the last value returned from getParameters()" that is not a DOMException InvalidModificationError: property "code" is equal to 11, expected 13
+PASS sender.setParameters() with transaction ID unset should reject with TypeError
+PASS setParameters() twice with the same parameters should reject with InvalidStateError
+FAIL setParameters() with parameters older than last getParameters() should reject with InvalidModificationError promise_rejects_dom: function "function () { throw e }" threw object "InvalidStateError: Failed to set parameters since the transaction_id doesn't match the last value returned from getParameters()" that is not a DOMException InvalidModificationError: property "code" is equal to 11, expected 13
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpReceiver-getParameters-expected.txt (271935 => 271936)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpReceiver-getParameters-expected.txt 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/webrtc/RTCRtpReceiver-getParameters-expected.txt 2021-01-27 08:36:19 UTC (rev 271936)
@@ -1,5 +1,5 @@
-FAIL getParameters() with audio receiver assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL getParameters() with video receiver assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
-FAIL getParameters() with simulcast video receiver assert_equals: Expect dictionary.rtcp to be plain object expected "object" but got "undefined"
+PASS getParameters() with audio receiver
+PASS getParameters() with video receiver
+FAIL getParameters() with simulcast video receiver assert_greater_than: expected a number greater than 0 but got 0
Modified: trunk/Source/WebCore/CMakeLists.txt (271935 => 271936)
--- trunk/Source/WebCore/CMakeLists.txt 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/Source/WebCore/CMakeLists.txt 2021-01-27 08:36:19 UTC (rev 271936)
@@ -390,6 +390,7 @@
Modules/mediastream/RTCPeerConnectionIceEvent.idl
Modules/mediastream/RTCPeerConnectionState.idl
Modules/mediastream/RTCPriorityType.idl
+ Modules/mediastream/RTCRtcpParameters.idl
Modules/mediastream/RTCRtpCapabilities.idl
Modules/mediastream/RTCRtpCodecCapability.idl
Modules/mediastream/RTCRtpCodecParameters.idl
Modified: trunk/Source/WebCore/ChangeLog (271935 => 271936)
--- trunk/Source/WebCore/ChangeLog 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/Source/WebCore/ChangeLog 2021-01-27 08:36:19 UTC (rev 271936)
@@ -1,3 +1,27 @@
+2021-01-27 Youenn Fablet <[email protected]>
+
+ Add support for RTCRtpParameters.rtcp
+ https://bugs.webkit.org/show_bug.cgi?id=220912
+
+ Reviewed by Eric Carlson.
+
+ Introduce corresponding WebIDL and binding to webrtc backend.
+ Covered by rebased tests.
+
+ * CMakeLists.txt:
+ * DerivedSources-input.xcfilelist:
+ * DerivedSources-output.xcfilelist:
+ * DerivedSources.make:
+ * Modules/mediastream/RTCRtcpParameters.h: Copied from Source/WebCore/Modules/mediastream/RTCRtpParameters.h.
+ * Modules/mediastream/RTCRtcpParameters.idl: Copied from Source/WebCore/Modules/mediastream/RTCRtpParameters.idl.
+ * Modules/mediastream/RTCRtpParameters.h:
+ * Modules/mediastream/RTCRtpParameters.idl:
+ * Modules/mediastream/libwebrtc/LibWebRTCUtils.cpp:
+ (WebCore::toRTCRtpParameters):
+ (WebCore::updateRTCRtpSendParameters):
+ * Sources.txt:
+ * WebCore.xcodeproj/project.pbxproj:
+
2021-01-26 Sihui Liu <[email protected]>
Mute audio capture for speech recognition based on shouldInterruptAudioOnPageVisibilityChange when page is invisible
Modified: trunk/Source/WebCore/DerivedSources-input.xcfilelist (271935 => 271936)
--- trunk/Source/WebCore/DerivedSources-input.xcfilelist 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/Source/WebCore/DerivedSources-input.xcfilelist 2021-01-27 08:36:19 UTC (rev 271936)
@@ -227,6 +227,7 @@
$(PROJECT_DIR)/Modules/mediastream/RTCPeerConnectionInternals.js
$(PROJECT_DIR)/Modules/mediastream/RTCPeerConnectionState.idl
$(PROJECT_DIR)/Modules/mediastream/RTCPriorityType.idl
+$(PROJECT_DIR)/Modules/mediastream/RTCRtcpParameters.idl
$(PROJECT_DIR)/Modules/mediastream/RTCRtpCapabilities.idl
$(PROJECT_DIR)/Modules/mediastream/RTCRtpCodecCapability.idl
$(PROJECT_DIR)/Modules/mediastream/RTCRtpCodecParameters.idl
Modified: trunk/Source/WebCore/DerivedSources-output.xcfilelist (271935 => 271936)
--- trunk/Source/WebCore/DerivedSources-output.xcfilelist 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/Source/WebCore/DerivedSources-output.xcfilelist 2021-01-27 08:36:19 UTC (rev 271936)
@@ -1687,6 +1687,8 @@
$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCPeerConnectionState.h
$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCPriorityType.cpp
$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCPriorityType.h
+$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtcpParameters.cpp
+$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtcpParameters.h
$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpCapabilities.cpp
$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpCapabilities.h
$(BUILT_PRODUCTS_DIR)/DerivedSources/WebCore/JSRTCRtpCodecCapability.cpp
Modified: trunk/Source/WebCore/DerivedSources.make (271935 => 271936)
--- trunk/Source/WebCore/DerivedSources.make 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/Source/WebCore/DerivedSources.make 2021-01-27 08:36:19 UTC (rev 271936)
@@ -251,6 +251,7 @@
$(WebCore)/Modules/mediastream/RTCPeerConnectionIceErrorEvent.idl \
$(WebCore)/Modules/mediastream/RTCPeerConnectionState.idl \
$(WebCore)/Modules/mediastream/RTCPriorityType.idl \
+ $(WebCore)/Modules/mediastream/RTCRtcpParameters.idl \
$(WebCore)/Modules/mediastream/RTCRtpCapabilities.idl \
$(WebCore)/Modules/mediastream/RTCRtpCodecCapability.idl \
$(WebCore)/Modules/mediastream/RTCRtpCodecParameters.idl \
Copied: trunk/Source/WebCore/Modules/mediastream/RTCRtcpParameters.h (from rev 271935, trunk/Source/WebCore/Modules/mediastream/RTCRtpParameters.h) (0 => 271936)
--- trunk/Source/WebCore/Modules/mediastream/RTCRtcpParameters.h (rev 0)
+++ trunk/Source/WebCore/Modules/mediastream/RTCRtcpParameters.h 2021-01-27 08:36:19 UTC (rev 271936)
@@ -0,0 +1,43 @@
+/*
+ * Copyright (C) 2021 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#pragma once
+
+#if ENABLE(WEB_RTC)
+
+#include <wtf/Optional.h>
+#include <wtf/text/WTFString.h>
+
+namespace WebCore {
+
+struct RTCRtcpParameters {
+ String cname;
+ Optional<bool> reducedSize;
+};
+
+
+} // namespace WebCore
+
+#endif // ENABLE(WEB_RTC)
Copied: trunk/Source/WebCore/Modules/mediastream/RTCRtcpParameters.idl (from rev 271935, trunk/Source/WebCore/Modules/mediastream/RTCRtpParameters.idl) (0 => 271936)
--- trunk/Source/WebCore/Modules/mediastream/RTCRtcpParameters.idl (rev 0)
+++ trunk/Source/WebCore/Modules/mediastream/RTCRtcpParameters.idl 2021-01-27 08:36:19 UTC (rev 271936)
@@ -0,0 +1,33 @@
+/*
+* Copyright (C) 2021 Apple Inc. All rights reserved.
+*
+* Redistribution and use in source and binary forms, with or without
+* modification, are permitted provided that the following conditions
+* are met:
+* 1. Redistributions of source code must retain the above copyright
+* notice, this list of conditions and the following disclaimer.
+* 2. Redistributions in binary form must reproduce the above copyright
+* notice, this list of conditions and the following disclaimer in the
+* documentation and/or other materials provided with the distribution.
+*
+* THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+* THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+* BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+* THE POSSIBILITY OF SUCH DAMAGE.
+*/
+
+[
+ Conditional=WEB_RTC,
+ EnabledAtRuntime=PeerConnection,
+ JSGenerateToJSObject,
+] dictionary RTCRtcpParameters {
+ DOMString cname;
+ boolean reducedSize;
+};
Modified: trunk/Source/WebCore/Modules/mediastream/RTCRtpParameters.h (271935 => 271936)
--- trunk/Source/WebCore/Modules/mediastream/RTCRtpParameters.h 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/Source/WebCore/Modules/mediastream/RTCRtpParameters.h 2021-01-27 08:36:19 UTC (rev 271936)
@@ -27,6 +27,7 @@
#if ENABLE(WEB_RTC)
+#include "RTCRtcpParameters.h"
#include "RTCRtpCodecParameters.h"
#include "RTCRtpHeaderExtensionParameters.h"
#include <wtf/Vector.h>
@@ -35,6 +36,7 @@
struct RTCRtpParameters {
Vector<RTCRtpHeaderExtensionParameters> headerExtensions;
+ RTCRtcpParameters rtcp;
Vector<RTCRtpCodecParameters> codecs;
};
Modified: trunk/Source/WebCore/Modules/mediastream/RTCRtpParameters.idl (271935 => 271936)
--- trunk/Source/WebCore/Modules/mediastream/RTCRtpParameters.idl 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/Source/WebCore/Modules/mediastream/RTCRtpParameters.idl 2021-01-27 08:36:19 UTC (rev 271936)
@@ -28,7 +28,7 @@
EnabledAtRuntime=PeerConnection,
JSGenerateToJSObject,
] dictionary RTCRtpParameters {
- sequence<RTCRtpHeaderExtensionParameters> headerExtensions;
- // FIXME: Add RTCRtcpParameters rtcp;
- sequence<RTCRtpCodecParameters> codecs;
+ required sequence<RTCRtpHeaderExtensionParameters> headerExtensions;
+ required RTCRtcpParameters rtcp;
+ required sequence<RTCRtpCodecParameters> codecs;
};
Modified: trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCUtils.cpp (271935 => 271936)
--- trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCUtils.cpp 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCUtils.cpp 2021-01-27 08:36:19 UTC (rev 271936)
@@ -139,6 +139,10 @@
for (auto& codec : rtcParameters.codecs)
parameters.codecs.append(toRTCCodecParameters(codec));
+ parameters.rtcp.reducedSize = rtcParameters.rtcp.reduced_size;
+ if (rtcParameters.rtcp.cname.length())
+ parameters.rtcp.cname = fromStdString(rtcParameters.rtcp.cname);
+
return parameters;
}
@@ -205,6 +209,11 @@
rtcParameters.degradation_preference = webrtc::DegradationPreference::BALANCED;
break;
}
+
+ if (parameters.rtcp.reducedSize)
+ rtcParameters.rtcp.reduced_size = *parameters.rtcp.reducedSize;
+ if (!parameters.rtcp.cname.isNull())
+ rtcParameters.rtcp.cname = parameters.rtcp.cname.utf8().data();
}
RTCRtpTransceiverDirection toRTCRtpTransceiverDirection(webrtc::RtpTransceiverDirection rtcDirection)
Modified: trunk/Source/WebCore/Sources.txt (271935 => 271936)
--- trunk/Source/WebCore/Sources.txt 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/Source/WebCore/Sources.txt 2021-01-27 08:36:19 UTC (rev 271936)
@@ -3347,6 +3347,7 @@
JSRTCPeerConnectionIceErrorEvent.cpp
JSRTCPeerConnectionState.cpp
JSRTCPriorityType.cpp
+JSRTCRtcpParameters.cpp
JSRTCRtpCapabilities.cpp
JSRTCRtpCodecCapability.cpp
JSRTCRtpCodecParameters.cpp
Modified: trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj (271935 => 271936)
--- trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj 2021-01-27 06:31:06 UTC (rev 271935)
+++ trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj 2021-01-27 08:36:19 UTC (rev 271936)
@@ -1029,6 +1029,7 @@
41103AAD1E39791000769F03 /* RealtimeIncomingAudioSource.h in Headers */ = {isa = PBXBuildFile; fileRef = 41103AA91E39790A00769F03 /* RealtimeIncomingAudioSource.h */; };
41103AAD1E39791000769F14 /* RealtimeIncomingAudioSourceCocoa.h in Headers */ = {isa = PBXBuildFile; fileRef = 41103AA91E39790A00769F14 /* RealtimeIncomingAudioSourceCocoa.h */; };
4112B5431F9F9CA000E67875 /* ServiceWorkerThreadProxy.h in Headers */ = {isa = PBXBuildFile; fileRef = 4112B53F1F9F9C9B00E67875 /* ServiceWorkerThreadProxy.h */; settings = {ATTRIBUTES = (Private, ); }; };
+ 4114FE3225BEBD19009D9F20 /* RTCRtcpParameters.h in Headers */ = {isa = PBXBuildFile; fileRef = 4114FE2F25BEBD18009D9F20 /* RTCRtcpParameters.h */; };
4123081B138C429700BCCFCA /* WebCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 93F19B1A08245E5A001E9ABC /* WebCore.framework */; };
41230913138C42FF00BCCFCA /* _javascript_Core.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = F8216299029F4FB501000131 /* _javascript_Core.framework */; };
4129C9971F59B963009D7403 /* FetchBodySource.h in Headers */ = {isa = PBXBuildFile; fileRef = 413015D61C7B570400091C6F /* FetchBodySource.h */; settings = {ATTRIBUTES = (Private, ); }; };
@@ -7610,6 +7611,8 @@
41114A7C2317B39E00B56007 /* WorkerMessagePortChannelProvider.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = WorkerMessagePortChannelProvider.cpp; sourceTree = "<group>"; };
4112B53F1F9F9C9B00E67875 /* ServiceWorkerThreadProxy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ServiceWorkerThreadProxy.h; sourceTree = "<group>"; };
4112B5411F9F9C9C00E67875 /* ServiceWorkerThreadProxy.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ServiceWorkerThreadProxy.cpp; sourceTree = "<group>"; };
+ 4114FE2F25BEBD18009D9F20 /* RTCRtcpParameters.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RTCRtcpParameters.h; sourceTree = "<group>"; };
+ 4114FE3125BEBD18009D9F20 /* RTCRtcpParameters.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = RTCRtcpParameters.idl; sourceTree = "<group>"; };
41189EF71AD8232800B90A0D /* ReadableStreamDefaultController.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = ReadableStreamDefaultController.idl; sourceTree = "<group>"; };
41189EF71AD8232800B93F64 /* ReadableByteStreamController.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = ReadableByteStreamController.idl; sourceTree = "<group>"; };
41189EF71AD8232800B95672 /* ReadableStreamBYOBRequest.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = ReadableStreamBYOBRequest.idl; sourceTree = "<group>"; };
@@ -17244,6 +17247,8 @@
41A48A9C1E83129100D2AC2D /* RTCPeerConnectionState.idl */,
41FCB75C214866FE0038ADC6 /* RTCPriorityType.h */,
41E593FD214865A900D3CB61 /* RTCPriorityType.idl */,
+ 4114FE2F25BEBD18009D9F20 /* RTCRtcpParameters.h */,
+ 4114FE3125BEBD18009D9F20 /* RTCRtcpParameters.idl */,
41369E55218C76E300792E29 /* RTCRtpCapabilities.idl */,
41E0A7D923BB590100561060 /* RTCRtpCodecCapability.idl */,
41FCB75F214866FF0038ADC6 /* RTCRtpCodecParameters.h */,
@@ -34326,6 +34331,7 @@
436708D512D9CA4B00044234 /* RenderSVGResourceFilterPrimitive.h in Headers */,
436708D712D9CA4B00044234 /* RenderSVGResourceGradient.h in Headers */,
436708D912D9CA4B00044234 /* RenderSVGResourceLinearGradient.h in Headers */,
+ 4114FE3225BEBD19009D9F20 /* RTCRtcpParameters.h in Headers */,
436708DB12D9CA4B00044234 /* RenderSVGResourceMarker.h in Headers */,
436708DD12D9CA4B00044234 /* RenderSVGResourceMasker.h in Headers */,
436708DF12D9CA4B00044234 /* RenderSVGResourcePattern.h in Headers */,