/* * Resampler.h * ----------- * Purpose: Holds the tables for all available resamplers. * Notes : (currently none) * Authors: OpenMPT Devs * The OpenMPT source code is released under the BSD license. Read LICENSE for more details. */ #pragma once #include "BuildSettings.h" #include "WindowedFIR.h" #include "Mixer.h" #include "MixerSettings.h" OPENMPT_NAMESPACE_BEGIN #ifdef LIBOPENMPT_BUILD // All these optimizations are not applicable to the tracker // because cutoff and firtype are configurable there. // Cache resampler tables across resampler object creation. // A C++11-style function-static singleton is holding the cached values. #define MPT_RESAMPLER_TABLES_CACHED // Prime the tables cache when the library is loaded. // Caching gets triggered via a global object that primes the cache during // construction. // This is only really useful with MPT_RESAMPLER_TABLES_CACHED. #define MPT_RESAMPLER_TABLES_CACHED_ONSTARTUP #endif // LIBOPENMPT_BUILD #define SINC_WIDTH 8 #define SINC_PHASES_BITS 12 #define SINC_PHASES (1<