[cairo-commit] 2 commits - build/configure.ac.warnings src/cairo-analysis-surface.c

Chris Wilson ickle at kemper.freedesktop.org
Mon Apr 9 04:52:28 PDT 2012


 build/configure.ac.warnings  |    5 +++++
 src/cairo-analysis-surface.c |    8 ++++++++
 2 files changed, 13 insertions(+)

New commits:
commit 7cb5053c0694992320b5f7ea3b91ea497431813b
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date:   Mon Apr 9 12:49:20 2012 +0100

    analysis: Apply the integer translation to the bbox as well
    
    The bbox is used to compute the ink extents (and so the pattern extents
    of a recording surface) and if given an integer translation we failed to
    transform the bbox into the target space.
    
    Fixes mask (pdf).
    
    Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>

diff --git a/src/cairo-analysis-surface.c b/src/cairo-analysis-surface.c
index b8abe02..8878f62 100644
--- a/src/cairo-analysis-surface.c
+++ b/src/cairo-analysis-surface.c
@@ -220,6 +220,14 @@ _add_operation (cairo_analysis_surface_t *surface,
 	if (_cairo_matrix_is_integer_translation (&surface->ctm, &tx, &ty)) {
 	    rect->x += tx;
 	    rect->y += ty;
+
+	    tx = _cairo_fixed_from_int (tx);
+	    bbox.p1.x += tx;
+	    bbox.p2.x += tx;
+
+	    ty = _cairo_fixed_from_int (ty);
+	    bbox.p1.y += ty;
+	    bbox.p2.y += ty;
 	} else {
 	    _cairo_matrix_transform_bounding_box_fixed (&surface->ctm,
 							&bbox, NULL);
commit de61681574eb7d6e0e497ea7f25797e3d9b20ac4
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date:   Mon Apr 9 12:47:34 2012 +0100

    build: Disable -Wset-but-unused-variable
    
    This is too noisy in the current build, and masking more important
    warnings.
    
    Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>

diff --git a/build/configure.ac.warnings b/build/configure.ac.warnings
index 3eb0104..f1b17f4 100644
--- a/build/configure.ac.warnings
+++ b/build/configure.ac.warnings
@@ -21,6 +21,9 @@ MAYBE_WARN="-Wall -Wextra \
 -Wno-missing-field-initializers -Wno-unused-parameter \
 -Wno-attributes -Wno-long-long -Winline"
 
+# -Wunused-but-set-variable is too noisy at present
+NO_WARN="-Wno-unused-but-set-variable"
+
 dnl Sun Studio 12 likes to rag at us for abusing enums like
 dnl having cairo_status_t variables hold cairo_int_status_t
 dnl values.  It's bad, we know.  Now please be quiet.
@@ -34,6 +37,8 @@ MAYBE_WARN="$MAYBE_WARN -fno-strict-aliasing -fno-common -flto"
 dnl Also to turn various gcc/glibc-specific preprocessor checks
 MAYBE_WARN="$MAYBE_WARN -Wp,-D_FORTIFY_SOURCE=2"
 
+MAYBE_WARN="$MAYBE_WARN $NO_WARN"
+
 # invalidate cached value if MAYBE_WARN has changed
 if test "x$cairo_cv_warn_maybe" != "x$MAYBE_WARN"; then
 	unset cairo_cv_warn_cflags


More information about the cairo-commit mailing list