static void drft_init(ref drft_lookup l, int n) { l.n = n; l.trigcache = (float *)_ogg_calloc(3 * n, sizeof(float)); l.splitcache = (int *)_ogg_calloc(32, sizeof(int)); fdrffti(n, l.trigcache, l.splitcache); }
static void drft_backward(ref drft_lookup l, float *data) { if (l.n == 1) { return; } else { drftb1(l.n, data, l.trigcache, l.trigcache + l.n, l.splitcache); } }
static void drft_clear(ref drft_lookup l) { if (l.trigcache != null) { _ogg_free(l.trigcache); } if (l.splitcache != null) { _ogg_free(l.splitcache); } l = default(drft_lookup); }