Title: [237555] trunk/Source
Revision
237555
Author
[email protected]
Date
2018-10-29 09:26:51 -0700 (Mon, 29 Oct 2018)

Log Message

Guard H264 simulcast with a runtime flag
https://bugs.webkit.org/show_bug.cgi?id=191025

Reviewed by Eric Carlson.

Source/WebCore:

Add a runtime flag for H264 simulcast and enable libwebrtc field trial based on it.
Covered by existing test.

* Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp:
(WebCore::LibWebRTCMediaEndpoint::LibWebRTCMediaEndpoint):
* page/RuntimeEnabledFeatures.h:
(WebCore::RuntimeEnabledFeatures::webRTCH264SimulcastEnabled const):
(WebCore::RuntimeEnabledFeatures::setWebRTCH264SimulcastEnabled):

Source/WebKit:

* Shared/WebPreferences.yaml:

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (237554 => 237555)


--- trunk/Source/WebCore/ChangeLog	2018-10-29 15:48:28 UTC (rev 237554)
+++ trunk/Source/WebCore/ChangeLog	2018-10-29 16:26:51 UTC (rev 237555)
@@ -1,3 +1,19 @@
+2018-10-29  Youenn Fablet  <[email protected]>
+
+        Guard H264 simulcast with a runtime flag
+        https://bugs.webkit.org/show_bug.cgi?id=191025
+
+        Reviewed by Eric Carlson.
+
+        Add a runtime flag for H264 simulcast and enable libwebrtc field trial based on it.
+        Covered by existing test.
+
+        * Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp:
+        (WebCore::LibWebRTCMediaEndpoint::LibWebRTCMediaEndpoint):
+        * page/RuntimeEnabledFeatures.h:
+        (WebCore::RuntimeEnabledFeatures::webRTCH264SimulcastEnabled const):
+        (WebCore::RuntimeEnabledFeatures::setWebRTCH264SimulcastEnabled):
+
 2018-10-29  Zalan Bujtas  <[email protected]>
 
         [LFC][IFC] Compute estimated margin top for inline formatting root's ancestors

Modified: trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp (237554 => 237555)


--- trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp	2018-10-29 15:48:28 UTC (rev 237554)
+++ trunk/Source/WebCore/Modules/mediastream/libwebrtc/LibWebRTCMediaEndpoint.cpp	2018-10-29 16:26:51 UTC (rev 237555)
@@ -77,7 +77,8 @@
     ASSERT(isMainThread());
     ASSERT(client.factory());
 
-    webrtc::field_trial::InitFieldTrialsFromString("WebRTC-H264Simulcast/Enabled/");
+    if (RuntimeEnabledFeatures::sharedFeatures().webRTCH264SimulcastEnabled())
+        webrtc::field_trial::InitFieldTrialsFromString("WebRTC-H264Simulcast/Enabled/");
 }
 
 bool LibWebRTCMediaEndpoint::setConfiguration(LibWebRTCProvider& client, webrtc::PeerConnectionInterface::RTCConfiguration&& configuration)

Modified: trunk/Source/WebCore/page/RuntimeEnabledFeatures.h (237554 => 237555)


--- trunk/Source/WebCore/page/RuntimeEnabledFeatures.h	2018-10-29 15:48:28 UTC (rev 237554)
+++ trunk/Source/WebCore/page/RuntimeEnabledFeatures.h	2018-10-29 16:26:51 UTC (rev 237555)
@@ -216,6 +216,8 @@
     void setPeerConnectionEnabled(bool isEnabled) { m_isPeerConnectionEnabled = isEnabled; }
     bool mdnsICECandidatesEnabled() const { return m_mdnsICECandidatesEnabled; }
     void setMDNSICECandidatesEnabled(bool isEnabled) { m_mdnsICECandidatesEnabled = isEnabled; }
+    bool webRTCH264SimulcastEnabled() const { return m_isWebRTCH264SimulcastEnabled; }
+    void setWebRTCH264SimulcastEnabled(bool isEnabled) { m_isWebRTCH264SimulcastEnabled = isEnabled; }
 #endif
 
 #if ENABLE(LEGACY_CSS_VENDOR_PREFIXES)
@@ -398,6 +400,7 @@
     bool m_isWebRTCUnifiedPlanEnabled { true };
     bool m_isPeerConnectionEnabled { true };
     bool m_mdnsICECandidatesEnabled { false };
+    bool m_isWebRTCH264SimulcastEnabled { true };
 #endif
 
 #if ENABLE(LEGACY_CSS_VENDOR_PREFIXES)

Modified: trunk/Source/WebKit/ChangeLog (237554 => 237555)


--- trunk/Source/WebKit/ChangeLog	2018-10-29 15:48:28 UTC (rev 237554)
+++ trunk/Source/WebKit/ChangeLog	2018-10-29 16:26:51 UTC (rev 237555)
@@ -1,3 +1,12 @@
+2018-10-29  Youenn Fablet  <[email protected]>
+
+        Guard H264 simulcast with a runtime flag
+        https://bugs.webkit.org/show_bug.cgi?id=191025
+
+        Reviewed by Eric Carlson.
+
+        * Shared/WebPreferences.yaml:
+
 2018-10-29  Chris Dumez  <[email protected]>
 
         [PSON] When Safari restores session state after launching, going back and forward does not swap processes

Modified: trunk/Source/WebKit/Shared/WebPreferences.yaml (237554 => 237555)


--- trunk/Source/WebKit/Shared/WebPreferences.yaml	2018-10-29 15:48:28 UTC (rev 237554)
+++ trunk/Source/WebKit/Shared/WebPreferences.yaml	2018-10-29 16:26:51 UTC (rev 237555)
@@ -523,6 +523,15 @@
   humanReadableDescription: "Enable WebRTC VP8 codec"
   category: experimental
 
+WebRTCH264SimulcastEnabled:
+  type: bool
+  defaultValue: true
+  webcoreBinding: RuntimeEnabledFeatures
+  condition: ENABLE(WEB_RTC)
+  humanReadableName: "WebRTC H264 Simulcast"
+  humanReadableDescription: "Enable WebRTC H264 Simulcast"
+  category: experimental
+
 UseLegacyTextAlignPositionedElementBehavior:
   type: bool
   defaultValue: false
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to