From: cristy Date: Mon, 6 May 2013 17:04:29 +0000 (+0000) Subject: (no commit message) X-Git-Tag: 7.0.1-0~3720 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=89106f86b28a27c7b7d9b07e13db58516ab8d01f;p=imagemagick --- diff --git a/MagickCore/gem.c b/MagickCore/gem.c index 37cb75a9c..55b8e4a4c 100644 --- a/MagickCore/gem.c +++ b/MagickCore/gem.c @@ -1341,10 +1341,10 @@ static inline void ConvertXYZToLCHab(const double X,const double Y, ConvertXYZToLab(X,Y,Z,luma,&a,&b); *chroma=hypot(255.0*(a-0.5),255.0*(b-0.5)); *hue=180.0*atan2(255.0*(b-0.5),255.0*(a-0.5))/MagickPI; - if (*hue < 0.0) - *hue+=360.0; *chroma=(*chroma)/255.0+0.5; *hue=(*hue)/255.0+0.5; + if (*hue < 0.0) + *hue+=1.0; } MagickPrivate void ConvertRGBToLCHab(const double red,const double green,