Title: [230687] trunk/Source/ThirdParty/libwebrtc
Revision
230687
Author
you...@apple.com
Date
2018-04-16 15:59:04 -0700 (Mon, 16 Apr 2018)

Log Message

Set H264 VT encoder usage to 1
https://bugs.webkit.org/show_bug.cgi?id=184668

Reviewed by Eric Carlson.

* Source/webrtc/sdk/objc/Framework/Classes/VideoToolbox/RTCVideoEncoderH264.mm:
(-[RTCVideoEncoderH264 configureCompressionSession]):

Modified Paths

Diff

Modified: trunk/Source/ThirdParty/libwebrtc/ChangeLog (230686 => 230687)


--- trunk/Source/ThirdParty/libwebrtc/ChangeLog	2018-04-16 22:46:47 UTC (rev 230686)
+++ trunk/Source/ThirdParty/libwebrtc/ChangeLog	2018-04-16 22:59:04 UTC (rev 230687)
@@ -1,3 +1,13 @@
+2018-04-16  Youenn Fablet  <you...@apple.com>
+
+        Set H264 VT encoder usage to 1
+        https://bugs.webkit.org/show_bug.cgi?id=184668
+
+        Reviewed by Eric Carlson.
+
+        * Source/webrtc/sdk/objc/Framework/Classes/VideoToolbox/RTCVideoEncoderH264.mm:
+        (-[RTCVideoEncoderH264 configureCompressionSession]):
+
 2018-04-10  Youenn Fablet  <you...@apple.com>
 
         webrtc/datachannel/basic-tcp.html will crash with an invalid crash

Modified: trunk/Source/ThirdParty/libwebrtc/Source/webrtc/sdk/objc/Framework/Classes/VideoToolbox/RTCVideoEncoderH264.mm (230686 => 230687)


--- trunk/Source/ThirdParty/libwebrtc/Source/webrtc/sdk/objc/Framework/Classes/VideoToolbox/RTCVideoEncoderH264.mm	2018-04-16 22:46:47 UTC (rev 230686)
+++ trunk/Source/ThirdParty/libwebrtc/Source/webrtc/sdk/objc/Framework/Classes/VideoToolbox/RTCVideoEncoderH264.mm	2018-04-16 22:59:04 UTC (rev 230687)
@@ -38,7 +38,6 @@
 #include "sdk/WebKit/EncoderUtilities.h"
 #include "sdk/WebKit/WebKitUtilities.h"
 
-#if !ENABLE_VCP_ENCODER && !defined(WEBRTC_IOS)
 #import <dlfcn.h>
 #import <objc/runtime.h>
 
@@ -45,6 +44,7 @@
 SOFT_LINK_FRAMEWORK_OPTIONAL(VideoToolBox)
 SOFT_LINK_POINTER_OPTIONAL(VideoToolBox, kVTVideoEncoderSpecification_Usage, NSString *)
 
+#if !ENABLE_VCP_ENCODER && !defined(WEBRTC_IOS)
 static inline bool isStandardFrameSize(int32_t width, int32_t height)
 {
     // FIXME: Envision relaxing this rule, something like width and height dividable by 4 or 8 should be good enough.
@@ -733,6 +733,9 @@
   SetVTSessionProperty(_compressionSession, kVTCompressionPropertyKey_RealTime, true);
   SetVTSessionProperty(_compressionSession, kVTCompressionPropertyKey_ProfileLevel, _profile);
   SetVTSessionProperty(_compressionSession, kVTCompressionPropertyKey_AllowFrameReordering, false);
+#if ENABLE_VCP_ENCODER
+  SetVTSessionProperty(_compressionSession, (__bridge CFStringRef)getkVTVideoEncoderSpecification_Usage(), 1);
+#endif
   [self setEncoderBitrateBps:_targetBitrateBps];
   // TODO(tkchin): Look at entropy mode and colorspace matrices.
   // TODO(tkchin): Investigate to see if there's any way to make this work.
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to