summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin Haberkorn <robin.haberkorn@googlemail.com>2012-09-08 05:22:43 +0200
committerRobin Haberkorn <robin.haberkorn@googlemail.com>2012-09-08 05:22:43 +0200
commit143f701925167628150cbf4614ee5bd6803e539c (patch)
tree48065bef8de67722a8bdb88089d69c43a5552031
parent90ae9d514fe2a69323e47ebc29f1596feccd3231 (diff)
downloaddigitale-debutanten-143f701925167628150cbf4614ee5bd6803e539c.tar.gz
show progress on stdout when reading files (stock samples) into the sampler
also now stereo files may be read in
-rw-r--r--live_sampler.ck11
1 files changed, 10 insertions, 1 deletions
diff --git a/live_sampler.ck b/live_sampler.ck
index 5e8a9bd..a62941a 100644
--- a/live_sampler.ck
+++ b/live_sampler.ck
@@ -7,8 +7,17 @@ LiSaX lisa[7];
Gain amp => Bus.out_left;
amp => Bus.out_right;
+fun void
+read(int i, string file)
+{
+ chout <= "Loading \"" <= file <= "\" into sample bank " <= i <= "... ";
+ chout.flush();
+ file => lisa[i].read;
+ chout <= "Done!" <= IO.newline();
+}
+
/* stock samples */
-"samples/stier_loop.wav" => lisa[0].read;
+read(0, "samples/stier_loop_stereo.wav");
for (0 => int i; i < lisa.cap(); i++) {
if (lisa[i].duration() == 0::samp) {