Title: [90847] trunk/Source/WebCore
Revision
90847
Author
[email protected]
Date
2011-07-12 14:08:27 -0700 (Tue, 12 Jul 2011)

Log Message

Unreviewed, rolling out r90831.
http://trac.webkit.org/changeset/90831
https://bugs.webkit.org/show_bug.cgi?id=64389

Likely caused fast/canvas/DrawImageSinglePixelStretch.html to
start timing out on the chromium GPU bots (Requested by ojan
on #webkit).

Patch by Sheriff Bot <[email protected]> on 2011-07-12

* platform/graphics/skia/ImageBufferSkia.cpp:
(WebCore::getImageData):
(WebCore::putImageData):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (90846 => 90847)


--- trunk/Source/WebCore/ChangeLog	2011-07-12 20:58:03 UTC (rev 90846)
+++ trunk/Source/WebCore/ChangeLog	2011-07-12 21:08:27 UTC (rev 90847)
@@ -1,3 +1,17 @@
+2011-07-12  Sheriff Bot  <[email protected]>
+
+        Unreviewed, rolling out r90831.
+        http://trac.webkit.org/changeset/90831
+        https://bugs.webkit.org/show_bug.cgi?id=64389
+
+        Likely caused fast/canvas/DrawImageSinglePixelStretch.html to
+        start timing out on the chromium GPU bots (Requested by ojan
+        on #webkit).
+
+        * platform/graphics/skia/ImageBufferSkia.cpp:
+        (WebCore::getImageData):
+        (WebCore::putImageData):
+
 2011-07-12  James Robinson  <[email protected]>
 
         Reviewed by Kenneth Russell.

Modified: trunk/Source/WebCore/platform/graphics/skia/ImageBufferSkia.cpp (90846 => 90847)


--- trunk/Source/WebCore/platform/graphics/skia/ImageBufferSkia.cpp	2011-07-12 20:58:03 UTC (rev 90846)
+++ trunk/Source/WebCore/platform/graphics/skia/ImageBufferSkia.cpp	2011-07-12 21:08:27 UTC (rev 90847)
@@ -223,10 +223,7 @@
     unsigned destBytesPerRow = 4 * rect.width();
 
     SkBitmap srcBitmap;
-    SkIRect srcRect = SkIRect::MakeXYWH(originX, originY, numColumns, numRows);
-    if (!srcDevice.accessBitmap(false).extractSubset(&srcBitmap, srcRect))
-        return result.release();
-    SkAutoLockPixels alp(srcBitmap);
+    srcDevice.readPixels(SkIRect::MakeXYWH(originX, originY, numColumns, numRows), &srcBitmap);
 
     unsigned char* destRow = data + destY * destBytesPerRow + destX * 4;
 
@@ -301,8 +298,10 @@
 
     unsigned srcBytesPerRow = 4 * sourceSize.width();
 
-    const SkBitmap& deviceBitmap = dstDevice->accessBitmap(true);
-    bool temporaryBitmap = !deviceBitmap.lockPixelsAreWritable();
+    SkBitmap deviceBitmap = dstDevice->accessBitmap(true);
+
+    // If the device's bitmap doesn't have pixels we will make a temp and call writePixels on the device.
+    bool temporaryBitmap = !!deviceBitmap.getTexture();
     SkBitmap destBitmap;
 
     if (temporaryBitmap) {
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to