From: Cristy Date: Sat, 28 Jul 2018 14:24:35 +0000 (-0400) Subject: ... X-Git-Tag: 7.0.8-9~26 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=8ab9cb094dce51913e7574cadad149bcafd78f0e;p=imagemagick ... --- 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