striateAt, chopAt (Custom functions for loop sampling)

Hello! The artist FKA Ritchse here. Going by a new name now as you might've seen (search my new Discord and Instagram if you had me in the old ones btw), geikha.

I thought I'd share some of my most used custom functions in some posts since I've been developing a very specific livecoding style:

The functions

let striateAt  str at f = slow   at $ striate (fast at $ str) f
    chopAt     str at f = slow   at $ chop    (fast at $ str) f
    sloopAt    str at f = loopAt at $ striate (fast at $ str) f
    striateAt' str at f = striateAt (str |* at) (fmap toRational at) f
    chopAt'    str at f = chopAt    (str |* at) (fmap toRational at) f
    sloopAt'   str at f = sloopAt   (str |* at) (fmap toRational at) f
    strat  = striateAt
    chat   = chopAt
    slat   = sloopAt
    strat' = striateAt'
    chat'  = chopAt'
    slat'  = sloopAt'



striateAt (shorthand strat) takes two numbers and a pattern. The first number is the amount of bits into which to cut the sample into (as regular striate), the second one is the amount of cycles it will gather the bits along. And then the pattern of which to take the sound.

See striate on the docs.

d1 $ strat 64 4 "bev" # cut 1

Prime variants

The prime variant (striateAt' and strat') makes it more intuitive, as you can simply tell it how many bits you want per cycle. So it's easier to think about using quarter notes or eigth notes, regardless of how long the sample will take to loop.

d1 $ strat' "16 8" 8 "bev" # cut 1 # rel 0.1

Also, remember you can specify begin and ends times by separating the pattern to be striated with a $:

d1 $ strat' 16 2 $ "bev" # cut 1 # rel 0.2 # begin (1/2) # end (3/4)


Like striateAt, but uses and acts like chop.

d1 $ strat' 8 2 $ "breaks125*2" # bpf 4000 # coarse 2

d1 $ chat' 8 2 $ "breaks125*2" # bpf 4000 # coarse 2


sloopAt (or slat), uses the loopAt function to define the length of the loop in cycles. It's very useful for when you want to use a long loopAt but you don't want those super long samples playing forever when you hush them:

d1 $ slat' 16 2 "breaks125:1" # gain "[1 0 0 1]*4"

That's it for now, I'll keep posting groups of custom funcs every now and then :slight_smile:


Thank you so much @geikha for sharing your custom functions. They are awesome!!!

I am experimenting for a while with longer drum and synth loops, to chop them up, which seems to be very interesting to me, but for example your strat seems to be the next level to me. This is real fun to chop loops with your custom functions. This is what I was always dreaming of, especially for chopping drum loops.

Just two annotations for the moment.

It is even more fun to create a folder with lets says some variants of your drumloop and then play with irand.

d1 $ strat' "8 16" 8 "drum_loop" # cut 1 # rel 0.5 # gain 0.8 # irand 8

And I like to create exact timed breaks in experimenting with begin and end.

d1 $ fast 2 $ strat' 16 "<2>" $ "drum_loop" # cut 1 # rel 0.1
    # begin (1/"<2 2 2 4>") # end ("<3 3 3 3 3 3 1 3>"/4)

Here en example: