Title: [264930] trunk
- Revision
- 264930
- Author
- you...@apple.com
- Date
- 2020-07-27 10:31:00 -0700 (Mon, 27 Jul 2020)
Log Message
scaleResolutionDownBy has no effect on RTCRtpSender
https://bugs.webkit.org/show_bug.cgi?id=214783
<rdar://problem/66108346>
Reviewed by Eric Carlson.
Source/WebCore:
Covered by updated test.
* Modules/mediastream/libwebrtc/LibWebRTCUtils.cpp:
(WebCore::updateRTCRtpSendParameters):
Allow to change scaleResolutionDownBy.
LayoutTests:
* webrtc/video-expected.txt:
* webrtc/video.html:
Modified Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (264929 => 264930)
--- trunk/LayoutTests/ChangeLog 2020-07-27 17:26:11 UTC (rev 264929)
+++ trunk/LayoutTests/ChangeLog 2020-07-27 17:31:00 UTC (rev 264930)
@@ -1,3 +1,14 @@
+2020-07-27 Youenn Fablet <you...@apple.com>
+
+ scaleResolutionDownBy has no effect on RTCRtpSender
+ https://bugs.webkit.org/show_bug.cgi?id=214783
+ <rdar://problem/66108346>
+
+ Reviewed by Eric Carlson.
+
+ * webrtc/video-expected.txt:
+ * webrtc/video.html:
+
2020-07-27 Hector Lopez <hector_i_lo...@apple.com>
[ iOS ] css3/font-variant-small-caps-synthesis-coverage.html is passing and needs expectations removed
Modified: trunk/LayoutTests/webrtc/video-expected.txt (264929 => 264930)
--- trunk/LayoutTests/webrtc/video-expected.txt 2020-07-27 17:26:11 UTC (rev 264929)
+++ trunk/LayoutTests/webrtc/video-expected.txt 2020-07-27 17:31:00 UTC (rev 264930)
@@ -3,4 +3,5 @@
PASS Basic video exchange
PASS Call setParameters to disable sending a given encoding
PASS Call setParameters to reenable sending a given encoding
+PASS Call setParameters to reduce size by two
Modified: trunk/LayoutTests/webrtc/video.html (264929 => 264930)
--- trunk/LayoutTests/webrtc/video.html 2020-07-27 17:26:11 UTC (rev 264929)
+++ trunk/LayoutTests/webrtc/video.html 2020-07-27 17:31:00 UTC (rev 264930)
@@ -121,6 +121,24 @@
await checkVideoIsUpdated(true);
}, "Call setParameters to reenable sending a given encoding");
+
+promise_test(async (test) => {
+ const sender = pc1.getSenders()[0];
+ let p = sender.getParameters();
+ p.encodings[0].scaleResolutionDownBy = 2;
+ await sender.setParameters(p);
+
+ assert_equals(sender.getParameters().encodings[0].scaleResolutionDownBy, 2, "encodings[0].scaleResolutionDownBy should be 2");
+ assert_equals(video.videoWidth, 640);
+ assert_equals(video.videoHeight, 480);
+
+ let counter = 0;
+ while (++counter < 20 && video.videoWidth == 640)
+ await waitFor(200);
+
+ assert_equals(video.videoWidth, 320);
+ assert_equals(video.videoHeight, 240);
+}, "Call setParameters to reduce size by two");
</script>
</body>
</html>
Modified: trunk/Source/WebCore/ChangeLog (264929 => 264930)
--- trunk/Source/WebCore/ChangeLog 2020-07-27 17:26:11 UTC (rev 264929)
+++ trunk/Source/WebCore/ChangeLog 2020-07-27 17:31:00 UTC (rev 264930)
@@ -1,3 +1,17 @@
+2020-07-27 Youenn Fablet <you...@apple.com>
+
+ scaleResolutionDownBy has no effect on RTCRtpSender
+ https://bugs.webkit.org/show_bug.cgi?id=214783
+ <rdar://problem/66108346>
+
+ Reviewed by Eric Carlson.
+
+ Covered by updated test.
+
+ * Modules/mediastream/libwebrtc/LibWebRTCUtils.cpp:
+ (WebCore::updateRTCRtpSendParameters):
+ Allow to change scaleResolutionDownBy.
+
2020-07-25 Simon Fraser <simon.fra...@apple.com>
Scroll Snap broken when using RTL layout
Modified: trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCUtils.cpp (264929 => 264930)
--- trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCUtils.cpp 2020-07-27 17:26:11 UTC (rev 264929)
+++ trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCUtils.cpp 2020-07-27 17:31:00 UTC (rev 264930)
@@ -162,6 +162,8 @@
rtcParameters.encodings[i].max_bitrate_bps = parameters.encodings[i].maxBitrate;
if (parameters.encodings[i].maxFramerate)
rtcParameters.encodings[i].max_framerate = parameters.encodings[i].maxFramerate;
+ if (parameters.encodings[i].scaleResolutionDownBy)
+ rtcParameters.encodings[i].scale_resolution_down_by = parameters.encodings[i].scaleResolutionDownBy;
}
rtcParameters.header_extensions.clear();
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes