[librsvg/librsvg-2.44] tests: Tolerate greater rendering differences on all non-x86_64



commit 4b014f6100ffccaebe7ce9ac2bf18f01f830dd3f
Author: Simon McVittie <smcv debian org>
Date:   Fri Oct 12 11:09:31 2018 +0100

    tests: Tolerate greater rendering differences on all non-x86_64
    
    Previously, this used 32-bit vs. 64-bit to discriminate, with
    32-bit architectures allowed to deviate more from the reference
    rendering (mainly because the i387 FPU used on baseline i386
    builds has excess precision in its FP registers). However, one
    test also produces a colour channel difference of 3 on
    mips64el, a 64-bit architecture; tolerate this too.
    
    Signed-off-by: Simon McVittie <smcv debian org>

 tests/rsvg-test.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
---
diff --git a/tests/rsvg-test.c b/tests/rsvg-test.c
index d27de7b9..c6c0e2ab 100644
--- a/tests/rsvg-test.c
+++ b/tests/rsvg-test.c
@@ -350,8 +350,12 @@ rsvg_cairo_check (gconstpointer data)
                         width_a, height_a, width_b, height_b); 
     }
     else {
+#ifdef __x86_64__
+       const unsigned int MAX_DIFF = 2;
+#else
         /* https://gitlab.gnome.org/GNOME/librsvg/issues/178 */
-       const unsigned int MAX_DIFF = sizeof (long) == 8 ? 2 : 10;
+       const unsigned int MAX_DIFF = 10;
+#endif
 
        surface_diff = cairo_image_surface_create (CAIRO_FORMAT_ARGB32,
                                                   dimensions.width, dimensions.height);


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