From 3b939ba06b33591c87e80568b7627f4931f704d8 Mon Sep 17 00:00:00 2001 From: James Jackson-South Date: Mon, 18 Jul 2016 11:17:12 +1000 Subject: [PATCH] Bicubic comment Former-commit-id: ec9b6c9a7f64ff089245421b95215ea3eec621be Former-commit-id: 9c0bf865af4b584eb7386ae85a75e7937efbd43d Former-commit-id: 69ca3cdf66e446ee9d72766f910eddda4fd1387d --- src/ImageProcessorCore/Samplers/Resamplers/BicubicResampler.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/ImageProcessorCore/Samplers/Resamplers/BicubicResampler.cs b/src/ImageProcessorCore/Samplers/Resamplers/BicubicResampler.cs index 33120b0663..752c12d6d6 100644 --- a/src/ImageProcessorCore/Samplers/Resamplers/BicubicResampler.cs +++ b/src/ImageProcessorCore/Samplers/Resamplers/BicubicResampler.cs @@ -30,10 +30,12 @@ namespace ImageProcessorCore if (x <= 1F) { + // Below simplified result = ((a + 2F) * (x * x * x)) - ((a + 3F) * (x * x)) + 1; result = (((1.5F * x) - 2.5F) * x * x) + 1; } else if (x < 2F) { + // Below simplified result = (a * (x * x * x)) - ((5F * a) * (x * x)) + ((8F * a) * x) - (4F * a); result = (((((a * x) + 2.5F) * x) - 4) * x) + 2; }