[gtk/offscreen-fixes: 2/5] gsk: Add another test




commit 1668c7b125a4b5564deb3a72594569559339cec9
Author: Matthias Clasen <mclasen redhat com>
Date:   Wed Mar 31 07:49:58 2021 -0400

    gsk: Add another test
    
    Compare clipped repeat nodes. Must skip cairo here
    since it blurred the child by scaling after rendering.
    
    This currently fails in the gl renderers. since they
    don't correctly handle preexiting offsets in offscreen
    rendering.

 testsuite/gsk/compare/clipped-repeat-3d.node |  32 +++++++++++++++++++++++++++
 testsuite/gsk/compare/clipped-repeat-3d.png  | Bin 0 -> 1760 bytes
 testsuite/gsk/meson.build                    |   1 +
 3 files changed, 33 insertions(+)
---
diff --git a/testsuite/gsk/compare/clipped-repeat-3d.node b/testsuite/gsk/compare/clipped-repeat-3d.node
new file mode 100644
index 0000000000..288560c89d
--- /dev/null
+++ b/testsuite/gsk/compare/clipped-repeat-3d.node
@@ -0,0 +1,32 @@
+transform {
+ child: transform {
+  child: rounded-clip {
+    child: container {
+      repeat {
+        bounds: 0 0 159 34;
+        child: container {
+          color {
+            bounds: 0 0 10 10;
+            color: rgb(168,168,168);
+          }
+          color {
+            bounds: 10 0 10 10;
+            color: rgb(84,84,84);
+          }
+          color {
+            bounds: 0 10 10 10;
+            color: rgb(84,84,84);
+          }
+          color {
+            bounds: 10 10 10 10;
+            color: rgb(168,168,168);
+          }
+        }
+      }
+    }
+    clip: 0 0 159 34 / 6;
+  }
+  transform: scale(4, 4);
+ }
+ transform: translate(6, 20);
+}
diff --git a/testsuite/gsk/compare/clipped-repeat-3d.png b/testsuite/gsk/compare/clipped-repeat-3d.png
new file mode 100644
index 0000000000..b9a847d7c1
Binary files /dev/null and b/testsuite/gsk/compare/clipped-repeat-3d.png differ
diff --git a/testsuite/gsk/meson.build b/testsuite/gsk/meson.build
index 439f5a7c2e..dc716881a7 100644
--- a/testsuite/gsk/meson.build
+++ b/testsuite/gsk/meson.build
@@ -76,6 +76,7 @@ compare_render_tests = [
   'clip-in-rounded-clip2',
   'clip-in-rounded-clip3',
   'rounded-clip-in-clip-3d', # not really 3d, but cairo fails it
+  'clipped-repeat-3d',
   'issue-3615'
 ]
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]