Skip to content
Browse files

switch arpeggio to other note table, not sure if want

  • Loading branch information...
1 parent 11712de commit 4378f617a399b69fa75d5405c5c3e23b408aa726 @dop3j0e committed Jul 31, 2012
Showing with 9 additions and 6 deletions.
  1. +9 −6 win/main.cpp
View
15 win/main.cpp
@@ -14,15 +14,17 @@ int arpeggio[][4] = {
};
int arpseq[16] = { 0, 0, 1, 1, 2, 2, 4, 3, 0, 0, 1, 1, 2, 3, 4, 4 };
-static inline unsigned char voice_arp(unsigned long i)
-{
- return (((i << 1) / (notes[arpeggio[arpseq[(i >> 13) & 15]][(i >> 8) & 3]] >> 2)) & 1) << 7;
-}
-
int notes2[25] = { 134, 142, 150, 159, 169, 179, 189, 201, 213, 225, 239, 253, 268, 284, 301, 319, 338, 358, 379, 401, 425, 451, 477, 506, 536 };
int bassbeat[8] = { 0, 0, 1, 0, 0, 1, 0, 1 };
int bassline[16] = { 12, 12, 15, 10, 12, 12, 17, 10, 12, 12, 15, 7, 8, 8, 3, 7 };
+static inline unsigned char voice_arp(unsigned long i)
+{
+ int note = notes2[12 + arpeggio[arpseq[(i >> 13) & 15]][(i >> 8) & 3]];
+ return (((i * note) >> 5) & 128) - 1;
+// return (((i << 1) / (notes[arpeggio[arpseq[(i >> 13) & 15]][(i >> 8) & 3]] >> 2)) & 1) << 7;
+}
+
static inline unsigned char voice_bass(unsigned long i)
{
int note = notes2[bassline[(i >> 13) & 15]];
@@ -36,7 +38,8 @@ void fill(char *data)
for (int j = 0; j < 4096; j++)
{
- data[j] = (voice_bass(i) >> 1);// + (voice_arp(i) >> 2);
+ unsigned char sample = /*(voice_bass(i) >> 1) + */(voice_arp(i) >> 1);
+ data[j] = sample - 128;
i++;
}
}

0 comments on commit 4378f61

Please sign in to comment.
Something went wrong with that request. Please try again.