Hi again everybody.  This:
(define (ghosts)
  (process repeat 12
           for here = (now)
           for ahead = (* (+ here .5) 2)
           for main = (pick-range 53 77)
           for high? = (>= main 65)
           for amp = (if high? .6 .4)
           for rhy = (pick-list '(1/16 1/8 3/16))
           do
           (mp:midi :time here :key main :dur (rhythm->seconds rhy 60)
                    :amp amp)
           (when high?
           sprout (hitone main ahead)
           and sprout (riff main rhy) at (* ahead 2))
           (when (= rhy 3/16)
           sprout (thump main (+ here .5)))
           (wait (rhythm->seconds rhy 60))))
(sprout (ghosts))

This works fine to define (ghosts).  (ghosts) produces no sound just #<lambda 
({time}-2239)> in the listener window.  Running (sprout (ghosts)) gives me the 
hitone sound, but no advancement to the next pitch and it generates this in the 
listener window (I see that “at” is the unbound variable, but I can’t figure 
out how to fix it):

#<unspecified>
>>> Error: at: unbound variable
ghosts: (lambda ({time}-1860) (let* (({wait}-1... ; args: ("~A: unbound 
variable" at)
ghosts: ((* ahead 2))                             ; ahead: 1275579.145172206
ghosts: ((when (= rhy 3/16) sprout (thump main... ; rhy: 3/16, main: 75
                                                   ; here: 637789.072586103
ghosts: (call-with-exit (lambda (return) (if (... ; high?: #t
                                                   ; amp: 0.6000000000000001
ghosts: (sprout (ghosts)) 

Thanks again for your help and your patience.
Rob

------------------------------------------------------
Dr. Rob Howiler
Academic Computing Services Coordinator
Assistant Professor of Music
[email protected]
(864) 833-8324
------------------------------------------------------


-- 

------------------------------
<http://www.presby.edu>

_______________________________________________
Cmdist mailing list
[email protected]
https://cm-mail.stanford.edu/mailman/listinfo/cmdist

Reply via email to