From f52d166ca511ee77c73ce3e1825cd580a43375fe Mon Sep 17 00:00:00 2001 From: JonDeen Date: Tue, 9 Jun 2015 13:30:36 +0200 Subject: [PATCH] casting --- libvips/colour/sRGB2HSV.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/libvips/colour/sRGB2HSV.c b/libvips/colour/sRGB2HSV.c index 28c1874d..f3028dde 100644 --- a/libvips/colour/sRGB2HSV.c +++ b/libvips/colour/sRGB2HSV.c @@ -87,12 +87,10 @@ vips_sRGB2HSV_line( VipsColour *colour, VipsPel *out, VipsPel **in, int width ) q[0] = (unsigned char) (((int)(p[0] - p[1]) / delta) + 171); } - q[1]= (unsigned char) (int) (delta/c_max); + q[1]= (unsigned char) ((int) delta/c_max); } - q[2]=(int) (c_max * 256.0); - p += 3; q += 3; }