testsuite: Add a test for large scale nodes
authorBenjamin Otte <otte@redhat.com>
Mon, 13 Feb 2023 00:44:18 +0000 (01:44 +0100)
committerMatthias Clasen <mclasen@redhat.com>
Fri, 3 Mar 2023 17:33:57 +0000 (11:33 -0600)
This test fails if we naively create fullscale
intermediate offscreens. This was fixed in the
previous commits.

This tests the fixes in 22ba6b1f33dcbcab8d (for
cairo) and 3a0152b65fd75f631b76 (for GL).

testsuite/gsk/compare/texture-scale-magnify-10000x.node [new file with mode: 0644]
testsuite/gsk/compare/texture-scale-magnify-10000x.png [new file with mode: 0644]
testsuite/gsk/meson.build

diff --git a/testsuite/gsk/compare/texture-scale-magnify-10000x.node b/testsuite/gsk/compare/texture-scale-magnify-10000x.node
new file mode 100644 (file)
index 0000000..de74a00
--- /dev/null
@@ -0,0 +1,8 @@
+clip {
+  clip: 24995 24995 10 10;
+  child: texture-scale {
+    texture: url("data:;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAYAAACNMs+9AAAAKElEQVQYlWNkYGD4z4AG/v/HEGJgwhDBAQZQIQs2hzMyMtLBauorBACQUgcSISWLRgAAAABJRU5ErkJggg==");
+    bounds: 0 0 50000 50000;
+    filter: nearest;
+  }
+}
diff --git a/testsuite/gsk/compare/texture-scale-magnify-10000x.png b/testsuite/gsk/compare/texture-scale-magnify-10000x.png
new file mode 100644 (file)
index 0000000..2cb8412
Binary files /dev/null and b/testsuite/gsk/compare/texture-scale-magnify-10000x.png differ
index d5343da62e21428eb613f6b0319f24b43fabab82..ce007e667b2e6c3f882fd69f91b8c3b82c746b2e 100644 (file)
@@ -66,19 +66,20 @@ compare_render_tests = [
   'outset_shadow_offset_y',
   'outset_shadow_rounded_top',
   'outset_shadow_simple',
-  'scaled-cairo',
-  'scale-textures-negative-ngl',
-  'scale-up-down',
-  'shadow-in-opacity',
-  'texture-url',
   'repeat',
   'repeat-no-repeat',
   'repeat-negative-coords',
   'repeat-texture',
-  'transform-in-transform',
-  'transform-in-transform-in-transform',
   'rounded-clip-in-clip-3d', # not really 3d, but cairo fails it
+  'scale-textures-negative-ngl',
+  'scale-up-down',
+  'scaled-cairo',
   'scaled-texture',
+  'shadow-in-opacity',
+  'texture-scale-magnify-10000x',
+  'texture-url',
+  'transform-in-transform',
+  'transform-in-transform-in-transform',
 ]
 
 # these are too sensitive to differences in the renderers