aboutsummaryrefslogtreecommitdiff
path: root/externals/grill/xsample/source
diff options
context:
space:
mode:
authorThomas Grill <xovo@users.sourceforge.net>2005-01-26 05:13:21 +0000
committerThomas Grill <xovo@users.sourceforge.net>2005-01-26 05:13:21 +0000
commit22e2955b51ce16f5a550ef845f54241f7ec4d585 (patch)
tree6119c4670c93caef14b6f2df061c98792cde0135 /externals/grill/xsample/source
parentdcbc90c265de6782a1dc6f2e5e7e9fa3c4743f87 (diff)
minor updates
svn path=/trunk/; revision=2541
Diffstat (limited to 'externals/grill/xsample/source')
-rw-r--r--externals/grill/xsample/source/groove.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/externals/grill/xsample/source/groove.cpp b/externals/grill/xsample/source/groove.cpp
index 507cf349..408ee164 100644
--- a/externals/grill/xsample/source/groove.cpp
+++ b/externals/grill/xsample/source/groove.cpp
@@ -6,6 +6,10 @@ For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
*/
+#ifdef _MSC_VER
+#define _USE_MATH_DEFINES
+#endif
+
#include "main.h"
#include <math.h>
#include <stdio.h>
@@ -143,10 +147,6 @@ t_sample xgroove::fade_lin[XZONE_TABLE+1];
t_sample xgroove::fade_qsine[XZONE_TABLE+1];
t_sample xgroove::fade_hsine[XZONE_TABLE+1];
-#ifndef PI
-#define PI 3.14159265358979f
-#endif
-
void xgroove::setup(t_classid c)
{
DefineHelp(c,"xgroove~");
@@ -173,10 +173,10 @@ void xgroove::setup(t_classid c)
fade_lin[i] = x;
// quarter sine wave
- fade_qsine[i] = sin(x*(PI/2));
+ fade_qsine[i] = sin(x*(M_PI/2));
// half sine wave
- fade_hsine[i] = (sin(x*PI-PI/2)+1.f)*0.5f;
+ fade_hsine[i] = (sin(x*M_PI-M_PI/2)+1.f)*0.5f;
}
}