[gtk/modern-testsuite: 6/11] testuite: Add opacity-overdraw test




commit a5a6adef703d00179943492a349aa2b6eb82a8ef
Author: Benjamin Otte <otte redhat com>
Date:   Wed Sep 15 07:37:57 2021 +0200

    testuite: Add opacity-overdraw test
    
    Tests that overdrawing of content inside an opacity node happens before
    the opacity is applied.
    
    This is broken in the GL renderer and causes the opacity.ui reftest to
    fail.

 testsuite/gsk/compare/opacity-overdraw.node |  15 +++++++++++++++
 testsuite/gsk/compare/opacity-overdraw.png  | Bin 0 -> 127 bytes
 testsuite/gsk/meson.build                   |   1 +
 3 files changed, 16 insertions(+)
---
diff --git a/testsuite/gsk/compare/opacity-overdraw.node b/testsuite/gsk/compare/opacity-overdraw.node
new file mode 100644
index 0000000000..78057f43a8
--- /dev/null
+++ b/testsuite/gsk/compare/opacity-overdraw.node
@@ -0,0 +1,15 @@
+opacity {
+  child: transform {
+    transform: translate(15, 15);
+    child: container {
+      color {
+        bounds: -15 -15 30 30;
+        color: rgb(0,0,255);
+      }
+      color {
+        bounds: -10 -10 20 20;
+        color: rgb(255,0,0);
+      }
+    }
+  }
+}
diff --git a/testsuite/gsk/compare/opacity-overdraw.png b/testsuite/gsk/compare/opacity-overdraw.png
new file mode 100644
index 0000000000..4499664e58
Binary files /dev/null and b/testsuite/gsk/compare/opacity-overdraw.png differ
diff --git a/testsuite/gsk/meson.build b/testsuite/gsk/meson.build
index d225653491..5ba5f73520 100644
--- a/testsuite/gsk/meson.build
+++ b/testsuite/gsk/meson.build
@@ -62,6 +62,7 @@ compare_render_tests = [
   'issue-3615',
   'nested-rounded-clips',
   'opacity_clip',
+  'opacity-overdraw',
   'opacity-overlapping-children',
   'outset_shadow_offset_both',
   'outset_shadow_offset_x',


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