⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 276166 in webkit


Ignore:
Timestamp:
Apr 16, 2021, 1:55:48 PM (5 years ago)
Author:
Said Abou-Hallawa
Message:

[BigSur wk1] svg/canvas/canvas-global-alpha-svg.html is flakey failing
https://bugs.webkit.org/show_bug.cgi?id=221559
<rdar://problem/74104075>

Reviewed by Daniel Bates.

By default, aliasing is applied when drawing the SVGImage to the canvas
through CanvasRenderingContext2D::drawImage() and when drawing the canvas
itself to DOM container through ImageBuffer::draw(). Because the test
includes only rectangles, we need to make sure the edges of the SVG image
and the canvas in this test get pixelated. This will match the expected
page which uses DOM objects to mimic the SVG and canvas drawing

Make sure the test is ended only after the SVG image is fully loaded.

  • platform/ios/TestExpectations:
  • platform/mac-wk1/TestExpectations:
  • svg/canvas/canvas-global-alpha-svg.html:
Location:
trunk/LayoutTests
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r276165 r276166  
     12021-04-16  Said Abou-Hallawa  <said@apple.com>
     2
     3        [BigSur wk1] svg/canvas/canvas-global-alpha-svg.html is flakey failing
     4        https://bugs.webkit.org/show_bug.cgi?id=221559
     5        <rdar://problem/74104075>
     6
     7        Reviewed by Daniel Bates.
     8
     9        By default, aliasing is applied when drawing the SVGImage to the canvas
     10        through CanvasRenderingContext2D::drawImage() and when drawing the canvas
     11        itself to DOM container through ImageBuffer::draw(). Because the test
     12        includes only rectangles, we need to make sure the edges of the SVG image
     13        and the canvas in this test get pixelated. This will match the expected
     14        page which uses DOM objects to mimic the SVG and canvas drawing
     15
     16        Make sure the test is ended only after the SVG image is fully loaded.
     17
     18        * platform/ios/TestExpectations:
     19        * platform/mac-wk1/TestExpectations:
     20        * svg/canvas/canvas-global-alpha-svg.html:
     21
    1222021-04-16  Robert Jenner  <jenner@apple.com>
    223
  • trunk/LayoutTests/platform/ios/TestExpectations

    r276127 r276166  
    11341134# Difference of less 0.03% between images.
    11351135svg/as-image/svg-image-with-data-uri-from-canvas.html [ ImageOnlyFailure ]
    1136 svg/canvas/canvas-global-alpha-svg.html [ ImageOnlyFailure ]
    11371136svg/clip-path/clip-path-line-use-before-defined.svg [ ImageOnlyFailure ]
    11381137
  • trunk/LayoutTests/platform/mac-wk1/TestExpectations

    r275917 r276166  
    12571257webkit.org/b/221506 [ BigSur ] svg/clip-path/resource-clipper-multiple-repaints.html [ Pass ImageOnlyFailure ]
    12581258
    1259 webkit.org/b/221559 [ BigSur ] svg/canvas/canvas-global-alpha-svg.html [ Pass ImageOnlyFailure ]
    1260 
    12611259webkit.org/b/222493 [ BigSur ] platform/mac-bigsur/media/media-source/media-source-webm-vp8-malformed-header.html [ Skip ]
    12621260
  • trunk/LayoutTests/svg/canvas/canvas-global-alpha-svg.html

    r180511 r276166  
    11<!DOCTYPE html>
    22<html>
     3<style>
     4  canvas, svg {
     5    image-rendering: pixelated;
     6  }
     7</style>
    38<body>
    49  <canvas id="canvas"></canvas>
    5   <script>
     10  <script> 
     11    if (window.testRunner)
     12      testRunner.waitUntilDone();
     13
    614    var canvas = document.getElementById("canvas");
    715    canvas.width  = 150;
     
    1624    svgImage.onload = function() {
    1725      context.globalAlpha = 0.2;
    18           context.drawImage(svgImage, 25, 25);
     26      context.drawImage(svgImage, 25, 25);
     27      if (window.testRunner)
     28        testRunner.notifyDone();
    1929    };
    2030   
Note: See TracChangeset for help on using the changeset viewer.