]> git.sesse.net Git - c64tapwav/blobdiff - interpolate.cpp
Fix some compatibility issues in level.cpp, and possibly also a tiny accuracy improve...
[c64tapwav] / interpolate.cpp
index cd250c151851619bb0fd128e5120dbc18e049ec1..78b2dae1e43e59cdb8923d90e6fd9a8e5645f0dd 100644 (file)
@@ -1,11 +1,11 @@
 #include "interpolate.h"
 
-double lanczos_table[(LANCZOS_RADIUS * 2) * LANCZOS_RESOLUTION];
+double lanczos_table[LANCZOS_RADIUS * LANCZOS_RESOLUTION];
 
 void make_lanczos_weight_table()
 {
-       for (int i = 0; i < (LANCZOS_RADIUS * 2) * LANCZOS_RESOLUTION; ++i) {
-               float x = double(i) / LANCZOS_RESOLUTION - LANCZOS_RADIUS;
+       for (int i = 0; i < LANCZOS_RADIUS * LANCZOS_RESOLUTION; ++i) {
+               float x = double(i) / LANCZOS_RESOLUTION;
                lanczos_table[i] = lanczos_weight(x);
        }
 }