Changeset 270117 in webkit


Ignore:
Timestamp:
Nov 20, 2020 8:09:56 AM (3 years ago)
Author:
youenn@apple.com
Message:

Make webrtc/captureCanvas-webrtc-software-h264-*.html tests use codecs in WebProcess
https://bugs.webkit.org/show_bug.cgi?id=219147

Reviewed by Eric Carlson.

Source/WebCore:

Expose internals setting to disable WebRTC codecs in GPU process.
Covered by existing tests.

  • testing/InternalSettings.cpp:

(WebCore::InternalSettings::setWebRTCPlatformCodecsInGPUProcessEnabled):

  • testing/InternalSettings.h:
  • testing/InternalSettings.idl:

LayoutTests:

  • webrtc/captureCanvas-webrtc-software-h264-baseline.html:
  • webrtc/captureCanvas-webrtc-software-h264-high.html:
Location:
trunk
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r270108 r270117  
     12020-11-20  Youenn Fablet  <youenn@apple.com>
     2
     3        Make webrtc/captureCanvas-webrtc-software-h264-*.html tests use codecs in WebProcess
     4        https://bugs.webkit.org/show_bug.cgi?id=219147
     5
     6        Reviewed by Eric Carlson.
     7
     8        * webrtc/captureCanvas-webrtc-software-h264-baseline.html:
     9        * webrtc/captureCanvas-webrtc-software-h264-high.html:
     10
    1112020-11-20  Alan Bujtas  <zalan@apple.com>
    212
  • trunk/LayoutTests/webrtc/captureCanvas-webrtc-software-h264-baseline.html

    r266832 r270117  
    1111        <script src="captureCanvas-webrtc-software-h264.js"></script>
    1212        <script>
     13if (window.internals) {
     14    internals.setH264HardwareEncoderAllowed(false);
     15    internals.settings.setWebRTCPlatformCodecsInGPUProcessEnabled(false);
     16}
     17
    1318promise_test((test) => {
    14     if (window.internals)
    15         internals.setH264HardwareEncoderAllowed(false);
    1619    return doTest(test, (sdp) => setH264BaselineCodec(sdp));
    1720}, "captureStream with webrtc - h264 baseline");
  • trunk/LayoutTests/webrtc/captureCanvas-webrtc-software-h264-high.html

    r266832 r270117  
    1111        <script src="captureCanvas-webrtc-software-h264.js"></script>
    1212        <script>
     13if (window.internals) {
     14    internals.setH264HardwareEncoderAllowed(false);
     15    internals.settings.setWebRTCPlatformCodecsInGPUProcessEnabled(false);
     16}
     17
    1318promise_test((test) => {
    14     if (window.internals)
    15         internals.setH264HardwareEncoderAllowed(false);
    1619    return doTest(test, (sdp) => setH264HighCodec(sdp));
    1720}, "captureStream with webrtc - h264 high profile");
  • trunk/Source/WebCore/ChangeLog

    r270116 r270117  
     12020-11-20  Youenn Fablet  <youenn@apple.com>
     2
     3        Make webrtc/captureCanvas-webrtc-software-h264-*.html tests use codecs in WebProcess
     4        https://bugs.webkit.org/show_bug.cgi?id=219147
     5
     6        Reviewed by Eric Carlson.
     7
     8        Expose internals setting to disable WebRTC codecs in GPU process.
     9        Covered by existing tests.
     10
     11        * testing/InternalSettings.cpp:
     12        (WebCore::InternalSettings::setWebRTCPlatformCodecsInGPUProcessEnabled):
     13        * testing/InternalSettings.h:
     14        * testing/InternalSettings.idl:
     15
    1162020-11-20  Sergio Villar Senin  <svillar@igalia.com>
    217
  • trunk/Source/WebCore/testing/InternalSettings.cpp

    r269888 r270117  
    448448}
    449449
     450ExceptionOr<void> InternalSettings::setWebRTCPlatformCodecsInGPUProcessEnabled(bool enabled)
     451{
     452    if (!m_page)
     453        return Exception { InvalidAccessError };
     454#if ENABLE(WEB_RTC)
     455    RuntimeEnabledFeatures::sharedFeatures().setWebRTCPlatformCodecsInGPUProcessEnabled(enabled);
     456#else
     457    UNUSED_PARAM(enabled);
     458#endif
     459    return { };
     460}
     461
    450462ExceptionOr<void> InternalSettings::setCustomPasteboardDataEnabled(bool enabled)
    451463{
  • trunk/Source/WebCore/testing/InternalSettings.h

    r269888 r270117  
    9393    ExceptionOr<void> setFetchAPIKeepAliveEnabled(bool);
    9494    ExceptionOr<void> setCustomPasteboardDataEnabled(bool);
     95    ExceptionOr<void> setWebRTCPlatformCodecsInGPUProcessEnabled(bool);
    9596
    9697    // DeprecatedGlobalSettings.
  • trunk/Source/WebCore/testing/InternalSettings.idl

    r269888 r270117  
    6969    [MayThrowException] undefined setFetchAPIKeepAliveEnabled(boolean enabled);
    7070    [MayThrowException] undefined setCustomPasteboardDataEnabled(boolean enabled);
     71    [MayThrowException] undefined setWebRTCPlatformCodecsInGPUProcessEnabled(boolean enabled);
    7172
    7273    // DeprecatedGlobalSettings.
Note: See TracChangeset for help on using the changeset viewer.