Mercurial > hg > svcore
comparison system/System.cpp @ 1039:b14064bd1f97 cxx11
This code now compiles. Main problem: sample rate types
author | Chris Cannam |
---|---|
date | Tue, 03 Mar 2015 17:09:19 +0000 |
parents | cc27f35aa75c |
children | 9cdb4206aceb |
comparison
equal
deleted
inserted
replaced
1038:cc27f35aa75c | 1039:b14064bd1f97 |
---|---|
321 | 321 |
322 double mod(double x, double y) { return x - (y * floor(x / y)); } | 322 double mod(double x, double y) { return x - (y * floor(x / y)); } |
323 float modf(float x, float y) { return x - (y * floorf(x / y)); } | 323 float modf(float x, float y) { return x - (y * floorf(x / y)); } |
324 | 324 |
325 double princarg(double a) { return mod(a + M_PI, -2 * M_PI) + M_PI; } | 325 double princarg(double a) { return mod(a + M_PI, -2 * M_PI) + M_PI; } |
326 float princargf(float a) { return modf(a + M_PI, -2 * M_PI) + M_PI; } | 326 float princargf(float a) { return float(princarg(a)); } |
327 | 327 |