More efficient traversal of on notes.
[orgux.git] / constants.h
blob15199813f724254f8194d713eb60ab2772a73de8
1 /* constants needed by core and precompute */
3 #define PI 3.141592653589
4 #define PI2 PI*2
6 #define HARMONIC_COUNT 8
8 #define BASE_CONFIG 8
9 #define FM_CONFIG 9
10 #define FM_FREQ_CONFIG 10
11 #define LP_CONFIG 11
12 #define HP_CONFIG 12
14 #define COMPONENT_MAX 255
17 #define SINE_BASE 128
18 #define SQUARE_BASE 129
19 #define TRIANGLE_BASE 130
20 #define SAW_BASE 131
21 #define NOISE_BASE 132
23 #define FM_OFF 133
27 #define SAMPLE_LENGTH (1<<16)
28 #define SAMPLE_COUNT 16
29 #define SAMPLE_NOTE_ZERO 60
31 #define ANTIPOP_LENGTH 512
32 #define WAVEFORM_LENGTH (1<<10)
34 #define MAX_COMMANDS 256
35 #define MAX_NOTES 128
37 #define RANDF() (((float)rand())/RAND_MAX)
38 #define RAND_SIGNAL() (RANDF()*2 - 1)