diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 09:22:09 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 09:22:09 +0000 |
commit | 43a97878ce14b72f0981164f87f2e35e14151312 (patch) | |
tree | 620249daf56c0258faa40cbdcf9cfba06de2a846 /gfx/wr/wrench/reftests/tiles | |
parent | Initial commit. (diff) | |
download | firefox-upstream.tar.xz firefox-upstream.zip |
Adding upstream version 110.0.1.upstream/110.0.1upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | gfx/wr/wrench/reftests/tiles/complex-shared-clip-root-ref.yaml | 13 | ||||
-rw-r--r-- | gfx/wr/wrench/reftests/tiles/complex-shared-clip-root.yaml | 25 | ||||
-rw-r--r-- | gfx/wr/wrench/reftests/tiles/mix-blend-clip-ref.yaml | 14 | ||||
-rw-r--r-- | gfx/wr/wrench/reftests/tiles/mix-blend-clip.yaml | 31 | ||||
-rw-r--r-- | gfx/wr/wrench/reftests/tiles/prim-suite.yaml | 45 | ||||
-rw-r--r-- | gfx/wr/wrench/reftests/tiles/rect.yaml | 6 | ||||
-rw-r--r-- | gfx/wr/wrench/reftests/tiles/reftest.list | 7 | ||||
-rw-r--r-- | gfx/wr/wrench/reftests/tiles/simple-gradient.yaml | 9 | ||||
-rw-r--r-- | gfx/wr/wrench/reftests/tiles/tile-cache-raster-root.png | bin | 0 -> 11246 bytes | |||
-rw-r--r-- | gfx/wr/wrench/reftests/tiles/tile-cache-raster-root.yaml | 43 |
10 files changed, 193 insertions, 0 deletions
diff --git a/gfx/wr/wrench/reftests/tiles/complex-shared-clip-root-ref.yaml b/gfx/wr/wrench/reftests/tiles/complex-shared-clip-root-ref.yaml new file mode 100644 index 0000000000..6a76d67f33 --- /dev/null +++ b/gfx/wr/wrench/reftests/tiles/complex-shared-clip-root-ref.yaml @@ -0,0 +1,13 @@ +--- +root: + items: + - + type: clip + id: 2 + complex: + - rect: [50, 50, 200, 200] + radius: 16 + - type: rect + bounds: [50, 50, 200, 200] + color: red + clip-chain: [2] diff --git a/gfx/wr/wrench/reftests/tiles/complex-shared-clip-root.yaml b/gfx/wr/wrench/reftests/tiles/complex-shared-clip-root.yaml new file mode 100644 index 0000000000..3d32a7f006 --- /dev/null +++ b/gfx/wr/wrench/reftests/tiles/complex-shared-clip-root.yaml @@ -0,0 +1,25 @@ +# verify that we don't select a shared clip root for a tile cache that has an ancestor complex clip +--- +root: + items: + - + type: clip + id: 2 + complex: + - rect: [50, 50, 200, 200] + radius: 16 + - + type: clip + id: 3 + bounds: [50, 50, 200, 200] + + - type: scroll-frame + bounds: 50 50 200 200 + scroll-offset: [0, 0] + id: 10 + items: + - type: rect + bounds: [50, 50, 200, 200] + color: red + spatial-id: 10 + clip-chain: [3, 2] diff --git a/gfx/wr/wrench/reftests/tiles/mix-blend-clip-ref.yaml b/gfx/wr/wrench/reftests/tiles/mix-blend-clip-ref.yaml new file mode 100644 index 0000000000..e31ead5b87 --- /dev/null +++ b/gfx/wr/wrench/reftests/tiles/mix-blend-clip-ref.yaml @@ -0,0 +1,14 @@ +--- +root: + items: + - type: stacking-context + blend-container: true + items: + - type: rect + bounds: [0, 0, 128, 128] + color: magenta + - type: stacking-context + mix-blend-mode: lighten + items: + - image: checkerboard(0, 16, 16, 8, 8) + bounds: [0, 0, 128, 128] diff --git a/gfx/wr/wrench/reftests/tiles/mix-blend-clip.yaml b/gfx/wr/wrench/reftests/tiles/mix-blend-clip.yaml new file mode 100644 index 0000000000..43b68f1787 --- /dev/null +++ b/gfx/wr/wrench/reftests/tiles/mix-blend-clip.yaml @@ -0,0 +1,31 @@ +# Test that a backdrop which has both a shared clip (on the tile cache) and is also scrolled +# correctly calculates the available backdrop rect for a mix-blend on a child. +--- +root: + items: + - + bounds: [0, 0, 128, 128] + type: clip + id: 2 + - type: clip-chain + id: 12 + clips: [2] + - type: stacking-context + blend-container: true + items: + - type: scroll-frame + bounds: 0 0 128 512 + scroll-offset: [0, 128] + id: 3 + items: + - type: rect + bounds: [0, 0, 128, 512] + color: magenta + spatial-id: 3 + clip-chain: 12 + - type: stacking-context + mix-blend-mode: lighten + clip-chain: 12 + items: + - image: checkerboard(0, 16, 16, 8, 16) + bounds: [0, 0, 128, 256] diff --git a/gfx/wr/wrench/reftests/tiles/prim-suite.yaml b/gfx/wr/wrench/reftests/tiles/prim-suite.yaml new file mode 100644 index 0000000000..2a170f8fc9 --- /dev/null +++ b/gfx/wr/wrench/reftests/tiles/prim-suite.yaml @@ -0,0 +1,45 @@ +--- +root: + items: + - type: stacking-context + bounds: [50, 50, 100, 100] + transform: rotate(30) + items: + - type: rect + bounds: [ 10, 10, 80, 80 ] + color: [0, 255, 0] + - type: box-shadow + bounds: [ 10, 10, 80, 80 ] + blur-radius: 25 + clip-mode: inset + + - type: rect + bounds: [ 140, 10, 80, 80 ] + color: [0, 255, 0] + - type: box-shadow + bounds: [ 140, 10, 80, 80 ] + blur-radius: 25 + clip-mode: outset + + - type: border + bounds: [ 250, 10, 100, 100 ] + width: [ 10, 10, 10, 10 ] + border-type: normal + style: solid + color: [ red, green, blue, black ] + radius: { + top-left: [20, 20], + top-right: [10, 10], + bottom-left: [25, 25], + bottom-right: [0, 0], + } + + - bounds: [150, 150, 128, 128] + image: checkerboard(4, 15, 8) + stretch-size: 128 128 + + - type: radial-gradient + bounds: 300 150 100 100 + center: 50 50 + radius: 50 50 + stops: [0, red, 1, blue] diff --git a/gfx/wr/wrench/reftests/tiles/rect.yaml b/gfx/wr/wrench/reftests/tiles/rect.yaml new file mode 100644 index 0000000000..e3f71ac9dd --- /dev/null +++ b/gfx/wr/wrench/reftests/tiles/rect.yaml @@ -0,0 +1,6 @@ +--- +root: + items: + - type: rect + bounds: 50 50 200 200 + color: red diff --git a/gfx/wr/wrench/reftests/tiles/reftest.list b/gfx/wr/wrench/reftests/tiles/reftest.list new file mode 100644 index 0000000000..800563b87c --- /dev/null +++ b/gfx/wr/wrench/reftests/tiles/reftest.list @@ -0,0 +1,7 @@ +** rect.yaml +fuzzy(1,2000) ** simple-gradient.yaml +# TODO: Fix rasterizer inaccuracies so this is the same regardless of tile size! +!* prim-suite.yaml +== mix-blend-clip.yaml mix-blend-clip-ref.yaml +platform(linux) == tile-cache-raster-root.yaml tile-cache-raster-root.png +== complex-shared-clip-root.yaml complex-shared-clip-root-ref.yaml diff --git a/gfx/wr/wrench/reftests/tiles/simple-gradient.yaml b/gfx/wr/wrench/reftests/tiles/simple-gradient.yaml new file mode 100644 index 0000000000..0879b2442f --- /dev/null +++ b/gfx/wr/wrench/reftests/tiles/simple-gradient.yaml @@ -0,0 +1,9 @@ +--- +root: + items: + - type: gradient + bounds: [ 0, 0, 1980, 1080] + start: [ 0, -2000 ] + end: [ 0, 4000 ] + stops: [ 0.0, red, 1.0, green ] + repeat: false diff --git a/gfx/wr/wrench/reftests/tiles/tile-cache-raster-root.png b/gfx/wr/wrench/reftests/tiles/tile-cache-raster-root.png Binary files differnew file mode 100644 index 0000000000..2615b4c9cd --- /dev/null +++ b/gfx/wr/wrench/reftests/tiles/tile-cache-raster-root.png diff --git a/gfx/wr/wrench/reftests/tiles/tile-cache-raster-root.yaml b/gfx/wr/wrench/reftests/tiles/tile-cache-raster-root.yaml new file mode 100644 index 0000000000..9fc06b7bd5 --- /dev/null +++ b/gfx/wr/wrench/reftests/tiles/tile-cache-raster-root.yaml @@ -0,0 +1,43 @@ +# Based on a reduced case from blend-clipped.yaml, ensure that if tile caches don't create +# raster roots (which messes with the special case handling and positioning of them). +--- +root: + items: + - + type: "stacking-context" + items: + - + bounds: [0, 111, 1887, 1971] + type: iframe + id: [1, 3] + id: [1, 1] +pipelines: + - + id: [1, 3] + items: + - + type: "scroll-frame" + id: 2 + bounds: [0, 0, 1887, 1971] + clip-to-frame: true + - + spatial-id: 2 + type: "stacking-context" + items: + - + bounds: [0, -186, 1887, 239] + spatial-id: 2 + type: clip + id: 4 + - + bounds: [-660.45, -186, 0, 0] + spatial-id: 2 + clip-chain: [4] + type: "stacking-context" + transform: [1, 0, 0, 0, -0.57735026, 1, 0, 0, 0, 0, 1, 0, 68.849, 0, 0, 1] + items: + - + bounds: [0, 0, 1887, 239] + type: rect + color: blue + clip-chain: [2, 4] |