2010-12-08 James Robinson <[email protected]>
Reviewed by Kenneth Russell.
[chromium] Text is blurry on a large composited layer with an odd center x/y coordinate
https://bugs.webkit.org/show_bug.cgi?id=50702
Tests that text rendered on a large layer is crisp even when the layer's center point
has an odd x and/or y coordinate.
* compositing/text-on-large-layer.html: Added.
* platform/chromium-gpu-linux/compositing/text-on-large-layer-expected.checksum: Added.
* platform/chromium-gpu-linux/compositing/text-on-large-layer-expected.png: Added.
* platform/chromium-gpu-linux/compositing/text-on-large-layer-expected.txt: Added.
* platform/chromium-gpu/test_expectations.txt:
* platform/mac/compositing/text-on-large-layer-expected.checksum: Added.
* platform/mac/compositing/text-on-large-layer-expected.png: Added.
* platform/mac/compositing/text-on-large-layer-expected.txt: Added.
2010-12-08 James Robinson <[email protected]>
Reviewed by Kenneth Russell.
[chromium] Text is blurry on a large composited layer with an odd center x/y coordinate
https://bugs.webkit.org/show_bug.cgi?id=50702
Compute the center of a large layer using floats instead of ints to avoid roundoff errors.
Test: compositing/text-on-large-layer.html
* platform/graphics/chromium/ContentLayerChromium.cpp:
(WebCore::ContentLayerChromium::draw):
git-svn-id: svn://svn.chromium.org/blink/trunk@73549 bbb929c8-8fbe-4397-9dbb-9b2b20218538
diff --git a/third_party/WebKit/LayoutTests/compositing/text-on-large-layer.html b/third_party/WebKit/LayoutTests/compositing/text-on-large-layer.html
new file mode 100644
index 0000000..13266d3
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/compositing/text-on-large-layer.html
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<html>
+<script>
+if (window.layoutTestController) {
+ layoutTestController.waitUntilDone();
+ // The mac port renders tiled layers asynchronously, so we have to wait a bit to get the actual rendering result.
+ window.setTimeout(function() {
+ layoutTestController.notifyDone();
+ }, 100);
+}
+</script>
+<body style="overflow:hidden">
+<div style="-webkit-transform:translateZ(0); width: 2000px; height: 10000px; top:1px; left:3px; position:absolute">
+This is some text inside a very large composited layer to test that it is rendered sharply.<br>
+The test passes if this text is crisp.
+</div>
+</body>
+</html>