summaryrefslogtreecommitdiffstats
path: root/src/generator.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/generator.c')
-rw-r--r--src/generator.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/generator.c b/src/generator.c
new file mode 100644
index 0000000..4e81297
--- /dev/null
+++ b/src/generator.c
@@ -0,0 +1,16 @@
+#include "generator.h"
+
+
+
+float
+generate(generator * g, synth_t * s, int i)
+{
+ float sample = 0;
+
+ float f = get_frequency(g, s, i);'
+
+ sample = osc_saw(midi_note->wvt_index);
+ midi_note->wvt_index = osc_saw_next(f, midi_note->wvt_index);
+
+ return sample;
+}