testsuite: Adapt color-matrix testcase
authorBenjamin Otte <otte@redhat.com>
Sun, 21 May 2023 02:48:46 +0000 (04:48 +0200)
committerBenjamin Otte <otte@redhat.com>
Mon, 5 Jun 2023 03:33:07 +0000 (05:33 +0200)
Make it use an alpha value that is well defined, ie 0.4 instead of 0.5.

0.4 * 255 = 102
0.5 * 255 = 127.5

This avoids rounding issues where some math may cause the resulting
alpha value to be 127, and some other math ends up with 128.

testsuite/gsk/compare/color-matrix-identity.node
testsuite/gsk/compare/color-matrix-identity.png

index a81a474ad00ba85252cbe09ab02e56ddffb01748..9498d08ba2cfde5b111e4b321e9280778f8a3517 100644 (file)
@@ -1,7 +1,7 @@
 color-matrix {
   child: color {
     bounds: 0 0 50 50;
-    color: rgba(255, 0, 0, 0.5);
+    color: rgba(255, 0, 0, 0.4);
   }
   matrix: none;
   offset: 0 0 0 0;
index f88dc6ac79dd429676eca7c10aa9b0e37bff66d5..7fcb5001c7f0847b370c10d3f0b84529c8c5b962 100644 (file)
Binary files a/testsuite/gsk/compare/color-matrix-identity.png and b/testsuite/gsk/compare/color-matrix-identity.png differ