Title: [211189] branches/safari-603-branch/Source
- Revision
- 211189
- Author
- matthew_han...@apple.com
- Date
- 2017-01-25 17:41:07 -0800 (Wed, 25 Jan 2017)
Log Message
Merge r211126. rdar://problem/30174873
Modified Paths
Diff
Modified: branches/safari-603-branch/Source/WebCore/ChangeLog (211188 => 211189)
--- branches/safari-603-branch/Source/WebCore/ChangeLog 2017-01-26 01:41:04 UTC (rev 211188)
+++ branches/safari-603-branch/Source/WebCore/ChangeLog 2017-01-26 01:41:07 UTC (rev 211189)
@@ -1,5 +1,21 @@
2017-01-25 Matthew Hanson <matthew_han...@apple.com>
+ Merge r211126. rdar://problem/30174873
+
+ 2017-01-24 Simon Fraser <simon.fra...@apple.com>
+
+ [iOS WK2] Avoid IOSurface readback for snapshot creation
+ https://bugs.webkit.org/show_bug.cgi?id=167397
+ rdar://problem/30174873
+
+ Reviewed by Tim Horton.
+
+ Export sinkIntoImage().
+
+ * platform/graphics/cocoa/IOSurface.h:
+
+2017-01-25 Matthew Hanson <matthew_han...@apple.com>
+
Merge r211120. rdar://problem/30151767
2017-01-24 Andreas Kling <akl...@apple.com>
Modified: branches/safari-603-branch/Source/WebCore/platform/graphics/cocoa/IOSurface.h (211188 => 211189)
--- branches/safari-603-branch/Source/WebCore/platform/graphics/cocoa/IOSurface.h 2017-01-26 01:41:04 UTC (rev 211188)
+++ branches/safari-603-branch/Source/WebCore/platform/graphics/cocoa/IOSurface.h 2017-01-26 01:41:07 UTC (rev 211189)
@@ -62,7 +62,7 @@
// Any images created from a surface need to be released before releasing
// the surface, or an expensive GPU readback can result.
WEBCORE_EXPORT RetainPtr<CGImageRef> createImage();
- static RetainPtr<CGImageRef> sinkIntoImage(std::unique_ptr<IOSurface>);
+ WEBCORE_EXPORT static RetainPtr<CGImageRef> sinkIntoImage(std::unique_ptr<IOSurface>);
id asLayerContents() const { return (id)(CFTypeRef)m_surface.get(); }
IOSurfaceRef surface() const { return m_surface.get(); }
Modified: branches/safari-603-branch/Source/WebKit2/ChangeLog (211188 => 211189)
--- branches/safari-603-branch/Source/WebKit2/ChangeLog 2017-01-26 01:41:04 UTC (rev 211188)
+++ branches/safari-603-branch/Source/WebKit2/ChangeLog 2017-01-26 01:41:07 UTC (rev 211189)
@@ -1,5 +1,22 @@
2017-01-25 Matthew Hanson <matthew_han...@apple.com>
+ Merge r211126. rdar://problem/30174873
+
+ 2017-01-24 Simon Fraser <simon.fra...@apple.com>
+
+ [iOS WK2] Avoid IOSurface readback for snapshot creation
+ https://bugs.webkit.org/show_bug.cgi?id=167397
+ rdar://problem/30174873
+
+ Reviewed by Tim Horton.
+
+ Use IOSurface::sinkIntoImage() for snapshots, to avoid GPU readback.
+
+ * UIProcess/API/Cocoa/WKWebView.mm:
+ (-[WKWebView _snapshotRect:intoImageOfWidth:completionHandler:]):
+
+2017-01-25 Matthew Hanson <matthew_han...@apple.com>
+
Merge r211121. rdar://problem/22938927
2017-01-24 Tim Horton <timothy_hor...@apple.com>
Modified: branches/safari-603-branch/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm (211188 => 211189)
--- branches/safari-603-branch/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm 2017-01-26 01:41:04 UTC (rev 211188)
+++ branches/safari-603-branch/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm 2017-01-26 01:41:07 UTC (rev 211189)
@@ -4407,7 +4407,7 @@
CATransform3D transform = CATransform3DMakeScale(imageScaleInViewCoordinates, imageScaleInViewCoordinates, 1);
transform = CATransform3DTranslate(transform, -rectInViewCoordinates.origin.x, -rectInViewCoordinates.origin.y, 0);
CARenderServerRenderDisplayLayerWithTransformAndTimeOffset(MACH_PORT_NULL, (CFStringRef)display.name, self.layer.context.contextId, reinterpret_cast<uint64_t>(self.layer), surface->surface(), 0, 0, &transform, 0);
- completionHandler(surface->createImage().get());
+ completionHandler(WebCore::IOSurface::sinkIntoImage(WTFMove(surface)).get());
return;
}
#endif
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes