-- /home/pln/Work/Art/GLITCHWAVE/outputs/digital_flow.gif
-- L'Été a MauerPark <3
do
setcps (120/60/4)
-- resetCycles
let gF =  (# djfbus 1 (range 0.05 0.95 "^49"))
let gF2 = (# djfbus 2 (range 0.05 0.95 "^50"))
let gF3 = (# djfbus 3 (range 0.05 0.95 "^51"))
let gMask = (midiOn "^41" (mask "t . <f t f <f t>> <t f f <t f>>"))
let gMute = (midiOn "^73" (mask "f*16"))
let gMute2 = (midiOn "^74" (mask "f*16"))
let gMute3 = (midiOn "^75" (mask "f*16"))
let gM = gMask . gMute
let gM2 = gMask . gMute2
let gM3 = gMask . gMute3
let gLPF = whenmod     64 48 (# lpfbus 4 (slow 16 $ range 20000 200  saw))
let gLPFSoft = whenmod 64 48 (# lpfbus 5 (slow 16 $ range 20000 2000 saw))
let chorus = pF "chorus"
let lagamount = pF "lagamount"
let dec = pF "dec"
let sus = pF "sus"
let cutoff = pF "cutoff"
d1 $ gF $ gMute2
  $ fix (|* gain 0.9)"kick:4"
  $ midiOn  "^42" (struct "t t t t") -- Le Run
  $ midiOff "^42" (struct "~ <t!3 ~>") -- L'attente
  $ "[techno:0,808bd:2,909,kick:4]"
  # rel 0.5
  # att 0.015
  # lpf 4000
  # gain 1.5
d2 $ gF $ gMute -- Clap timer
  $ midiOn "^43" ((|* gain "0 1 0.8 1") . (<| "~ c <~!3 [~ c]> c"))
  $ midiOff "^43" ((|* gain "1 0.8") . (<| "c . ~ ~ ~ <~!3 c>"))
  $ drumFrom "[sakatadpm48,rolandr8]" "cp"
  # lpf 2000
  # gain 1.6
d7 $ gF3 $ gM3 -- High Cello Dauphin
  $ midiOn "^91" (ply 2)
  $ midiOn (1 - "^35") (struct "t . f")
  $ struct "t@2 t*<1 2 1 <4 1>> t*<1 2 4 8>"
  $ midiOn "^59" (|- note 12)
  $ note (
    "<[g4 c ef@14] [<c g> ef g@14] <[g4 c ef@14] [c5 bf5 g5@14]> [c ef d@13 ~]>"
    )
  # "[cbow:3]"
  # cut 7
  # room 0.2
  # pan 0.9
  # crushbus 71 (range 16 2.5 "^55")
  -- # midiG' "^83" 0 1.2
  # gain 1.2
d3 $ gF $ gMute
  $ midiOff "^44" (mask "t([8 4 <4 <8 16>>],16)")
  $ midiOn "^76" (struct "t*[8 <8 16> <16 8 8 16> <16 [32 <64 128>]>]")
  $ fix ((|* gain (slow 32 $ range 0.3 1.3 saw))) "oh"
  $ "~ h ~ h ~ h*<1!3 2 1 1 2 2> ~ h*<1!7 2>" # drumFrom "sakatadpm48" "[hh,oh]"
  # n "0!3 <0!3 1>"
  -- # midiG' "^80" 0 1.6
  # gain 1.1
d4 $ gF2 $ gM3 $ slow 2 -- Basse Germanique
  $ midiOn "^57" (rev)
  $ midiOn "^89" (struct "t*<16 32>") -- Basse folle
  $ (0.125 <~) -- Calage :)
  $ someCyclesBy ("^33") ( -- Pattern complet
    (mask "<t!2 f t f f t t> f t@14") . (|* room 1.2)
    ) --
  $ fix ((midiOff "^57" (# silence)) . (|* gain 0.65) . (|+ note 24) . (|* gain "<0.93!3 [0.92 0.85]>") . (# cut 5))
  "bass2"
  $ note (
    "<[g4 c ef@14] [<c g> ef g@14] <[g4 c ef@14] [c5 bf5 g5@14]> [c ef d@13 ~]>"
    - 24
    )
  # "[bass2:1,bassWarsaw]"  
  # room 0.2
  # pan 0.4
  # crushbus 41 (range 16 2.5 "^53")
  # octersubbus 42 (range 0 5 "^33")
  # gain 1.6
  # cut 4
d5 $ gF3 $ gMute3 -- Leads reponse TODO moins carre?
  $ midiOn "^90" (struct "t*<16 32>") -- Basse folle
  $ midiOn "^58" (|+ note 12)
  -- $ sometimesBy "^18" (bite 4 "[0, [~ 2]]")
  -- $ someCyclesBy "<f!3 t>" (mask "t f!15". (# legato 2))
  -- $ someCyclesBy "^17" (
    -- (mask "<t!2 f t f f t t> f t@14") . (|* room 1.2)
    -- ) --
  -- $ whenmod 32 24 (ply "2 <2!4 4!4>")
  $ arp "<up!6 down downup>"
  $ note (
    "<ef4 g4 <ef g> d>" + "c'maj'4"
    - 12
    )
  # "FMRhodes1"
  # legato 2
  # room 0.2
  # pan 0.33
  # modIndex (range 0.1 16 "^34")
  # crushbus 51 (range 16 3.5 "^54")
  -- # midiG' "^82" 0 1.5
d8 $ gM $ gF -- Breaks divins
  $ midiOn "^92" (off "e" id)
  $ midiOff "^60" (("e" ~>) . mask "t(<4 [4!3 8]>,16)")
  $ chop 16
  $ someCyclesBy "^36" (loopAt 1 . (# n 34))
  $ someCyclesBy "^56" (chop 8 . loopAt 1 . (# "fbreak120:3"))
  $ loopAt 2
  $ "jungle_breaks:1"
  # cut 8
  # pan "[<0.35!3 0.65> <0.65!3 0.35>]*4"
  # gain 1.3
d9 $ gF3 -- Nano-angels chorus of machines
  $ sometimesBy "^19" (superimpose (
    (# cut 101)
    . (arp "up")
    . (|+ note (
      "<[0,0] [0,7] [0,9] [0,7,9,12]>"
      ))
    . (|+ pan 0.1)
  ))
  $ midiOff "^58" (mask "t([0 2],4)")
  $ note (
    slow 2 "<bf4 d5 <bf4 ef> [bf4 a4@3]>"
    + "[0,[0*<1 1 2 <2 1>> .  0 12*<1 2>]]"
    )
  # "moogBass"
  # dec 0.2
  # sus 1
  # att (range 0.001 2 "^16")
  # rel (range 0.2  10 "^17")
  # room 0.2
  # lesliebus 102 (range 0 2 "^18")
  # chorus (range 0 2 "^19")
  # sz 0.6 # dry 2
  # legato 2
  # pan 0.64
  # cut 10
  # gain 1.5




bf g bf <bf a>
