From 39419239b28c54c3f747c6500caaaa88d8b17144 Mon Sep 17 00:00:00 2001 From: Nicola Fontana Date: Thu, 1 Oct 2009 20:17:44 +0200 Subject: [PATCH] [CpmlArc] Reverse vector on inverted arc When the arc is inverted, that is when its start angle is greater than its end angle, also the vector must be reverted. --- cpml/cpml-arc.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cpml/cpml-arc.c b/cpml/cpml-arc.c index 0b9036b8..e4f4d084 100644 --- a/cpml/cpml-arc.c +++ b/cpml/cpml-arc.c @@ -243,6 +243,9 @@ cpml_arc_vector_at(const CpmlPrimitive *arc, CpmlVector *vector, double pos) angle = (end-start)*pos + start; cpml_vector_from_angle(vector, angle); cpml_vector_normal(vector); + + if (start > end) + cpml_pair_negate(vector); } /** -- 2.11.4.GIT