diff options
author | Chris Robinson <[email protected]> | 2023-02-06 17:46:32 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2023-02-06 17:46:32 -0800 |
commit | da845ddd9c35a1e1fcff03ea342636ae4bb8018b (patch) | |
tree | 8fe219826036410c655b7c732e94f04b442c3261 /core/cubic_tables.h | |
parent | 0de7ea42fa197833bff70b4c370ed29f9859889d (diff) |
Use an interpolated FIR filter for cubic resampling
Similar to how the bsinc filters work, but optimized for 4-point filtering. At
least the SSE version is notably faster than calculating the coefficients in
real time.
Diffstat (limited to 'core/cubic_tables.h')
-rw-r--r-- | core/cubic_tables.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/core/cubic_tables.h b/core/cubic_tables.h new file mode 100644 index 00000000..297aa89e --- /dev/null +++ b/core/cubic_tables.h @@ -0,0 +1,16 @@ +#ifndef CORE_CUBIC_TABLES_H +#define CORE_CUBIC_TABLES_H + +#include "cubic_defs.h" + + +struct CubicTable { + const CubicCoefficients *Tab; +}; + +/* A Catmull-Rom spline. The spline passes through the center two samples, + * ensuring no discontinuity while moving through a series of samples. + */ +extern const CubicTable gCubicSpline; + +#endif /* CORE_CUBIC_TABLES_H */ |