Title: [259514] branches/safari-610.1.8-branch/Source/ThirdParty/libwebrtc
- Revision
- 259514
- Author
- [email protected]
- Date
- 2020-04-03 14:09:16 -0700 (Fri, 03 Apr 2020)
Log Message
Cherry-pick r259397. rdar://problem/61273057
Build fix after r259385.
Reviewed by David Kilzer, Youenn Fablet.
Convert isStandardFrameSize() into a lambda function since it only has one call site.
* Source/webrtc/sdk/objc/components/video_codec/RTCVideoEncoderH264.mm:
(-[RTCVideoEncoderH264 resetCompressionSessionWithPixelFormat:]):
(isStandardFrameSize): Deleted.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@259397 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Modified Paths
Diff
Modified: branches/safari-610.1.8-branch/Source/ThirdParty/libwebrtc/ChangeLog (259513 => 259514)
--- branches/safari-610.1.8-branch/Source/ThirdParty/libwebrtc/ChangeLog 2020-04-03 21:05:19 UTC (rev 259513)
+++ branches/safari-610.1.8-branch/Source/ThirdParty/libwebrtc/ChangeLog 2020-04-03 21:09:16 UTC (rev 259514)
@@ -1,5 +1,33 @@
2020-04-03 Alan Coon <[email protected]>
+ Cherry-pick r259397. rdar://problem/61273057
+
+ Build fix after r259385.
+
+ Reviewed by David Kilzer, Youenn Fablet.
+
+ Convert isStandardFrameSize() into a lambda function since it only has one call site.
+
+ * Source/webrtc/sdk/objc/components/video_codec/RTCVideoEncoderH264.mm:
+ (-[RTCVideoEncoderH264 resetCompressionSessionWithPixelFormat:]):
+ (isStandardFrameSize): Deleted.
+
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@259397 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2020-04-02 Simon Fraser <[email protected]>
+
+ Build fix after r259385.
+
+ Reviewed by David Kilzer, Youenn Fablet.
+
+ Convert isStandardFrameSize() into a lambda function since it only has one call site.
+
+ * Source/webrtc/sdk/objc/components/video_codec/RTCVideoEncoderH264.mm:
+ (-[RTCVideoEncoderH264 resetCompressionSessionWithPixelFormat:]):
+ (isStandardFrameSize): Deleted.
+
+2020-04-03 Alan Coon <[email protected]>
+
Cherry-pick r259458. rdar://problem/61265583
Remove rtpplay.exe from the libwebrtc source folder
Modified: branches/safari-610.1.8-branch/Source/ThirdParty/libwebrtc/Source/webrtc/sdk/objc/components/video_codec/RTCVideoEncoderH264.mm (259513 => 259514)
--- branches/safari-610.1.8-branch/Source/ThirdParty/libwebrtc/Source/webrtc/sdk/objc/components/video_codec/RTCVideoEncoderH264.mm 2020-04-03 21:05:19 UTC (rev 259513)
+++ branches/safari-610.1.8-branch/Source/ThirdParty/libwebrtc/Source/webrtc/sdk/objc/components/video_codec/RTCVideoEncoderH264.mm 2020-04-03 21:09:16 UTC (rev 259514)
@@ -48,34 +48,6 @@
VT_EXPORT const CFStringRef kVTVideoEncoderSpecification_Usage;
VT_EXPORT const CFStringRef kVTCompressionPropertyKey_Usage;
-#if defined(WEBRTC_MAC) && !defined(WEBRTC_IOS) && !HAVE_VTB_REQUIREDLOWLATENCY
-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.
- if (width == 1280)
- return height == 720;
- if (width == 720)
- return height == 1280;
- if (width == 960)
- return height == 540;
- if (width == 540)
- return height == 960;
- if (width == 640)
- return height == 480;
- if (width == 480)
- return height == 640;
- if (width == 288)
- return height == 352;
- if (width == 352)
- return height == 288;
- if (width == 320)
- return height == 240;
- if (width == 240)
- return height == 320;
- return false;
-}
-#endif
-
@interface RTCVideoEncoderH264 ()
- (void)frameWasEncoded:(OSStatus)status
@@ -786,6 +758,31 @@
sourceAttributes = nullptr;
}
+ auto 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.
+ if (width == 1280)
+ return height == 720;
+ if (width == 720)
+ return height == 1280;
+ if (width == 960)
+ return height == 540;
+ if (width == 540)
+ return height == 960;
+ if (width == 640)
+ return height == 480;
+ if (width == 480)
+ return height == 640;
+ if (width == 288)
+ return height == 352;
+ if (width == 352)
+ return height == 288;
+ if (width == 320)
+ return height == 240;
+ if (width == 240)
+ return height == 320;
+ return false;
+ };
+
if (!isStandardFrameSize(_width, _height)) {
_disableEncoding = true;
RTC_LOG(LS_ERROR) << "Using H264 software encoder with non standard size is not supported";
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes