samer@0: ;;; Example of how to use Stacker2, which buffers several samer@0: ;;; vectors into one big vector. samer@0: samer@0: (load "audio.scm") samer@0: (load "functions.scm") samer@0: (load "models.scm") samer@0: samer@0: samer@0: ;;; Buffers the last n vectors from x. Adds the appropriate samer@0: ;;; task and returns the big composite vector. samer@0: (define (stack n x) samer@0: (define stacker (node (.getNode x) (Stacker2. x n))) samer@0: (addtasks stacker) samer@0: (.output stacker)) samer@0: samer@0: samer@0: (stack 16 samer@0: (diffscale samer@0: (ft-mag (ft-vec (norm (linein (linesrc (mono 11025)) 512 256)))) samer@0: cauchy-spec)) samer@0: samer@0: (expose) samer@0: samer@0: (put "image.width" 256) samer@0: (put "image.height" 16) samer@0: (put "image.map.log" true)