[cairo-commit] Branch '1.14' - src/cairo-path-stroke-traps.c

Uli Schlachter psychon at kemper.freedesktop.org
Wed Dec 3 07:39:44 PST 2014


 src/cairo-path-stroke-traps.c |   10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

New commits:
commit b2333fd70c6b6f16eb52a0d8723cd7025caa1164
Author: Hans Breuer <hans at breuer.org>
Date:   Thu Oct 16 20:51:07 2014 +0200

    win32: Fix compilation of 'cairo-path-stroke-traps.c' with MSVC8
    
    "The issue here is that Visual Studio 2005+ is quite strict on type
    conversions (so it wants code to be clear enough on conversions)."
    
    Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=84908
    (Cherry-pick of 56da7adc3c85be0325481ecd23746dc49e60d239 from master)

diff --git a/src/cairo-path-stroke-traps.c b/src/cairo-path-stroke-traps.c
index 520a3e5..da54e5a 100644
--- a/src/cairo-path-stroke-traps.c
+++ b/src/cairo-path-stroke-traps.c
@@ -299,8 +299,9 @@ join (struct stroker *stroker,
 	    _cairo_traps_tessellate_triangle_with_edges (stroker->traps,
 							 tri, edges);
 	} else {
-	    cairo_point_t t[] = { in->point, *inpt, *outpt };
-	    cairo_point_t e[] = { in->cw, in->ccw, out->cw, out->ccw };
+	    cairo_point_t t[] = { { in->point.x, in->point.y}, { inpt->x, inpt->y }, { outpt->x, outpt->y } };
+	    cairo_point_t e[] = { { in->cw.x, in->cw.y}, { in->ccw.x, in->ccw.y },
+				  { out->cw.x, out->cw.y}, { out->ccw.x, out->ccw.y } };
 	    _cairo_traps_tessellate_triangle_with_edges (stroker->traps, t, e);
 	}
 	break;
@@ -461,8 +462,9 @@ join (struct stroker *stroker,
     }
 
     case CAIRO_LINE_JOIN_BEVEL: {
-	cairo_point_t t[] = { in->point, *inpt, *outpt };
-	cairo_point_t e[] = { in->cw, in->ccw, out->cw, out->ccw };
+	cairo_point_t t[] = { { in->point.x, in->point.y }, { inpt->x, inpt->y }, { outpt->x, outpt->y } };
+	cairo_point_t e[] = { { in->cw.x, in->cw.y }, { in->ccw.x, in->ccw.y },
+			      { out->cw.x, out->cw.y }, { out->ccw.x, out->ccw.y } };
 	_cairo_traps_tessellate_triangle_with_edges (stroker->traps, t, e);
 	break;
     }


More information about the cairo-commit mailing list