From 8ab9cb094dce51913e7574cadad149bcafd78f0e Mon Sep 17 00:00:00 2001 From: Cristy Date: Sat, 28 Jul 2018 10:24:35 -0400 Subject: [PATCH] ... --- coders/svg.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/coders/svg.c b/coders/svg.c index 93f6fa969..67ec9ba78 100644 --- a/coders/svg.c +++ b/coders/svg.c @@ -2164,13 +2164,17 @@ static void SVGStartElement(void *context,const xmlChar *name, GetNextToken(p,&p,MagickPathExtent,token); if (*token == ',') GetNextToken(p,&p,MagickPathExtent,token); - x=StringToDouble(token,&next_token)-svg_info->bounds.x; + x=StringToDouble(token,&next_token); GetNextToken(p,&p,MagickPathExtent,token); if (*token == ',') GetNextToken(p,&p,MagickPathExtent,token); - y=StringToDouble(token,&next_token)-svg_info->bounds.y; - affine.tx=svg_info->bounds.x+x*cos(angle)-y*sin(angle); - affine.ty=svg_info->bounds.y+x*sin(angle)+y*cos(angle); + y=StringToDouble(token,&next_token); + affine.tx=svg_info->bounds.x+x* + cos(DegreesToRadians(fmod(angle,360.0)))+y* + sin(DegreesToRadians(fmod(angle,360.0))); + affine.ty=svg_info->bounds.y+x* + sin(DegreesToRadians(fmod(angle,360.0)))-y* + cos(DegreesToRadians(fmod(angle,360.0))); break; } break; @@ -3025,7 +3029,6 @@ static void SVGExternalSubset(void *context,const xmlChar *name, static char SVGDensityGeometry[] = "72.0x72.0"; - static Image *ReadSVGImage(const ImageInfo *image_info,ExceptionInfo *exception) { char -- 2.40.0