filter_kernels: fix quadric window

3909e4cdfc seems to have replaced this 0.5 constant by 0.75, using its
presence in glumpy as justification.

0.75 is clearly a bug in glumpy, as its own source code doesn't even
match the comment immediately above it. Every other implementation of
this window I could find uses 0.5, including e.g. ImageMagick.
This commit is contained in:
Niklas Haas 2021-05-04 13:12:58 +02:00
parent b6aedaa726
commit f6f9b1e8db
1 changed files with 1 additions and 1 deletions

View File

@ -199,7 +199,7 @@ static double hamming(params *p, double x)
static double quadric(params *p, double x)
{
if (x < 0.75) {
if (x < 0.5) {
return 0.75 - x * x;
} else if (x < 1.5) {
double t = x - 1.5;