diff --git a/uppsrc/Draw/BiCubic.cpp b/uppsrc/Draw/BiCubic.cpp index d48d236cd..93874d542 100644 --- a/uppsrc/Draw/BiCubic.cpp +++ b/uppsrc/Draw/BiCubic.cpp @@ -16,7 +16,7 @@ double BicubicKernel(double x) r += 6 * x * x * x; if(xm1 > 0) r -= 4 * xm1 * xm1 * xm1; - return 1 / 6.0 * r; + return 0.16666666666666666 * r; } Image RescaleBicubic(const Image& img, Size sz, const Rect& sr, Gate progress) @@ -49,7 +49,7 @@ Image RescaleBicubic(const Image& img, Size sz, const Rect& sr, Gate p blue += weight * s.b; alpha += weight * s.a; } - } + } t->r = (int)fround(red); t->g = (int)fround(green); t->b = (int)fround(blue);