variable velocity output based on timing / controlled randomization

  • I have an idea for creating variable velocity based on the delta time between note offs/ons. my goal is a midi instrument (for live or whatever) that allows for the following:

    subtle shifts in velocity to "humanize" the output based on how fast you hit a pad (e.g. tapping c hats every 16th, and having every other 16th hit a little weaker).

    borax seems like the best object for this, given it records delta time, and i can reset it with say, every 6 events or whatever.

    I gotta run to work, but i'd love some suggestions. I was looking into how to scale delta time to a MIDI output from 0-127. a subtle randomization would be dope too - with basic settings to turn it off, on, and adjust the amount with key presses.

    This seems like a dope way to overcome the lack of velocity sensitivity on a monome that outputs either a 0 or a 1.

    your thoughts? I'd love to make this into an abstraction for further use/improvement.

    cheers!

  • if the monome was on a soft surface like a t-shirt or something maybe u could use the accelerometer's z-axis to detect velocity?

  • Yeah I'm thinking like - you shake a shaker and the offbeat is a slightly different timbre. Another thing I'm playing with when I've got this figured out is a sort of controllable strumming midi effect when you hold down a pad/note.

    Acellorometer idea is DOPE tho! At work but when I get home I'm gonna keep fooling with it!

  • Have you looked at the DIY forums on madrona labs? That might offer a way forward._

  • @chrisbob12 I haven't even considered madrona labs. I'll check it now! thanks!

    the real goal here is to overcome the perception that velocity sensitivity on a grid is'nt possible, when it is, it just requires some tricks ;)

  • perhaps something like the Lemur - every interface element has at least two variables. usually 3.

    x,y,z. x would be say, the current setting of a fader, and z is essentially if it's being touched or not - and you can define the delta time for that variable. there's gotta be a way to do something similar with a grid.

    not like an ipad is velocity sensitive natively. if anyone has any clues on the math (even just any ideas for expr) i'd be greatly appreciative. as it stands now, i've determined that the duration of a note being held, as well as the delta times between note-offs.

    been experimenting with scale, and clip to determine the best way these two values interrelate mathematically so they can be smoothly scaled to generate a velocity of 0-127. fyi - with borax i'm using ms to determine delta time. i've experimented with values of 256, 512, and 1024 but nothing seems right.

    if anyone has any algorithm design ideas for relating note duration and delta time - i could use the math :)

  • @raja good reads, and took me down quite the cnmat rabbit hole! I was considering the added latency with measuring delta time for *every* button press. perhaps the best way to do it would be to just have a "humanize" slider. say the far right column and 7,7 for 'off' and 0,7 for 'fully random'.

    it'd be simpler, and wouldn't add excess latency. Utilizing drunk and multiplying the output by the button state would be interesting. still playing with it.

    Yes, I suppose this is all in the name of expressiveness, and perhaps that's not minimal enough - but considering you have an interface that responds (or is perceived to respond) more expressively with the inclusion of subtle velocity changes, without the need for the operator of said interface to *do* anything extra besides just play is arguably, the quintessential minimalist addition to any musical interface, given 'it does what it says on the tin'.

    get the tech out of the way so the user can just do what they do, and develop their own technique with the existing interface, i say.

  • Okay, reading through the thread a bit deeper, that's not quite what we're after. Hang on a sec...

  • Randomization is not implemented here.

    You'll want to hook the matrixctrl to a grid somehow, probably as a page in some other app.


    ----------begin_max5_patcher----------
    2528.3oc6bszjiihD9rqeErJ5C6FQ08JPu2S6beOuW5YhNv1T1ZZYgWD1UU8
    Dy+8kGRxR1BY7TRxp5nNzkaiP3juLII4KA9iGV3rj9BovA7u.eErXwe7vhEp
    hjErn76Kb1geYUFtPUMmUzc6H4bmG0OiSdgqJ+HIitJk+Jnf7+NPxWQX+Z9u
    lu7UvufYzbv+gbLk+CveeCif4DFeKN+GDF8eT0NYo4jUzC4pFyurv8LRg32B
    ySo4eqUM7JqQ9gczC7LBWIbtkk9DayR02+RcIzbdNdGQIp+BKEm4z0uAirhq
    AC+Hw6Bfg9xO77ikeHKC7aMZwhzenZQHp9GZOluZaZ9llMUr5sCgpVLvU8E2
    FMUSQP0bkkmtVItzk+9mgAINm5xo4U8Xnrr+7gGj+4w2nFTTozcG1ApzjNiM
    Fiz.SThBXbUHNx8uDFGFoTTn.iskUfbz3Cxo42EPF54NbnL5sgxgCFJmSdVz
    jW.x6AEOi2+eIYEUORis7W2Sz8DGmZQtMxCuJNeCC78zi3CTV4vK.qVfhemf
    BpYqSXkPQIVHjkzLxQBqnMZuvAueeihWz3Uj.3uSUMT3i0EklqKBVWDS3ut5
    88pKEyD8QtnCdfoQlWhCczOTnzdn5Uq..sutDkQSnu5K9wMP.g5ciXXv2Iqa
    XzKTV6I4o4maJU+30jmvGx3eqaEQ6m+DdEw3K2o9cgyFV5ZZtTHZ8lxhq949
    pPqp0sM6LpZji22wKWH5GGJVhYRTcYFogtUX2RoYseTshTX9iENLDSYxS0BK
    xstQS2smkpmOrtLRNVzFaKVwnYYsZJ8SN1wSVKz0qHOmtluskyF4SDUOcekJ
    voFiVmtgTvaWFGuoncIsBtnoQXyw0sJuWunsGjmS4DfHxhcjhBrPZ.awGI.9
    VRJq16JfQ1mILAV2rEZEHApwC5zGb29g62GQO9IL4q.EqFk.KcspG4340v75
    bOF9gNsk8ybktnxcZ4nyQSE7zSmzAanBM.idXyVvyo7sB3DfyDw6oGEaRI3M
    STBZTuRG3COOnuK0A9ShNnDd6TG7ITyhMOOm445FdaYesyQcDudnuDH9RrYX
    LHvHJhFPTrUvBmEv.d02mgvHThbBG9JXL773Gt.F8mDXreiQvmfyNfDl.aXO
    pGV2m8nex81dT3AkS1KpHvsez7w9QTzHinZOkQdWyzzO5CSSC.Y4xxbszzbZ
    FiqZ0AArL2m0qG.ET8WiSxF.M1mahtUApnh.88BVfBhk93sGKP2UrP2wbrJb
    MytMPwV2c8LGe0MzcOsDMYXmFVQhRdkOuabnfdfspRiWE0BnsnKVtDOMudEq
    e8z7xmUwsoqW2dEh5EUUHWhldwvVo0tYY12RYVg7yDgVNc76OgVLiG.Zi0Qv
    7RlsAn6Pib2jYasn6nycujYkWb6cc.mIBMzVjdn72A9sGZxrnSA9HY82D+Dh
    IT9FlyYoKEgIWbNonuU9+tN+h2.oXcJD87ia5GcSFcINqjF352sCt2d3DHdi
    jo+8hrz0DlQJykTM9n9CCjmWwV8N55lzX1eN1JC5MITmoslISvDk5gleEKx+
    fWbcJSvLARxIruoIGsYpWtL15AJCP7soE.Qqujv.qnLg.umlut.vkTmQpdB8
    I.i9bA3yfzm.uROHpZ9QBiqpyNrv1+kUbVF.ujJY8jBvhHoBeDnZ8hszCYqA
    KIBYfHIotyrrFLXodx9Th3Iz4QRRM7P5kjqhDLx2PVQ7hF+TEI.1BNCKLqKF
    .S+g.jBh0QFmfNkdTiINBF9Qhi9HwQej3Hq4VqbaNz6J56X79TxtFR6bT6iL
    7prqAgt2aBKK2VCyXPMTTC+jj33ZfMH4p.q6cmIXNHEjNmsUcCZPfoNWO8Co
    wSRJydGCoAt2HhFMIH5nxCZvsQIL7mXJgKGQYOV7tlR3FtkQpgFV0k8GDZgu
    Wrfqmd+F5tAyWVvUle1wNqzy+bgANHzZodFwanLNO6jZ37gUYUPTVJ09yHoN
    1RB70ZE3LRpsytNYFI0QVag3NirPrMEOcMB3CFweGvHtYNCkjO0KagSv1KG4
    l7EjbwAwHMAY8xSnqam7D59tlmPULxtevR3GrDNzjDrZKNu8NIqyMemcLE3M
    tLEDqxil9K8wTPR7ce2J6N61AdkvFzyt8pbRz8lQvLJdsDhAvYJVVxbUD5p1
    ivIwdjS2rIibUB+dqjWUxpL55CCaMHnmbPe+XHkgyK1SYbaYIU7wSB6RC+mt
    pUevcx3ZdVt6APQWSQEGduGqqxUOgAZy.jIMQSrtG30ezRaUbYt8isaWgGXd
    9nfIJsUDNiJrHxA+a7Jd5QxUbptTDTvcYahWBsUGMID7ZX6zX59lYBU2s7fw
    1QEZRx7kIzDaodIY9vnXhsDuHGpB7lGxrsT2lLe3JJwVhakS4LSj4NDEC377
    gW+v2evb3sLBblbJBr1S2G7d9SEum3dH8bBuPMfFNPrshcOvYn1HuFPihU3L
    hv5NR7OwhItq.CJJVuUnUKAMA0Kxz8MMR3vgL+sOCht2ji6ACzjiqWU9kail
    VPBbvLVxDKh3Kx8vsnVks4Q7ogoUWLEh2wrAS85juxdM1zM9SfpKqyJfdTRS
    hj6bWXnWxFJz36b88UeraeaqdXm6i6Vtyq8i2iG8i3rCD5SWlzgS+lhIx9tD
    uaupflUfluoGERq5Vrkx3WV4z7tpbkNzsimklmxEFxWhHcUqpUGEcZpyFU5f
    nRE7WKoJ5glyU9Wxauslr0c5QyjE54c61rduAa1nj201rcaFdOsYawHwHZyZ
    XlmC48FixzdLNJiVQOareumhi.2w9btHupdD8yqbcyMX8ZDR8QPuW5Y9wc1q
    8F1dcOtsZyfcOlEdCO.o7W42aLr9itUwJZVFnfS1Wfj44uu6KuF7KaBk7GgH
    Z04kKo281fW21QvaawhjcKat.zepV3TIZhZFSnQzLZrW4zrxKcEzTdCrzqaZ
    O3XOfTcw+TmDhqbg+L9nBTege1+VKBEOXFLs25.Mt7d7.eBBpupytqChJua9
    BhN+t5oElLbChNcXeM16yRKTCYTedEqCZN4eJb6eXWt0mPasWixiacXX+gkW
    hRgAMt0Ya+NVDV9Me.sqZDcOSWT41OyQdNpkED2.7URS6r+n0EmyEZoF4R1w
    asAqMdgjzZCMeI4mWR74EFGVKP9VKPvoQffVHPdQSm73ZC.ION0Sj.EkXs.M
    MlPQVHOnnISbBrQg4GOsxCzF4YZre7sxf1a5.Hea.Hs.MMHzY8cC4Bb57Q6Y
    yHrITgIim8pJry7iO5xiUSYLMxCxF6GuoCePV4gd5reNO9FCYt1c5DH6FwGL
    wBDzFAZZbIdd7D83SzaBEHnMBj+zHPttioWZ8JON67yHkkyN2LmclYt77xX5
    rxH9c9yG9+j6udQN
    -----------end_max5_patcher-----------

  • Here, randomization *is* implemented. It's a bit messier and harder to follow.


    ----------begin_max5_patcher----------
    3304.3oc6cszkihaEdcU+JT7oWjIo5JHg3UVkYeVjUYyLyoOx1prYZL3.xU0
    cOm4+dzCfBLfPtKCnpOdQa2k.ju5SWc0UW8oK+w82sZc1WnEq.+Svu.t6t+3
    96tSVjnf6J+66Vcf7kMIjB4ssZS1gCzT1pGTWiQ+BSVdd1KEUEld5P1IVBkI
    eDmxReJe2Z4e+XcIYorTxAprB947XRRUMbLmVv+UHr3rzOkS2vThHJB8n2C.
    Xfu7KG4eg3UH32ZTkEweSVkPT8uzQBay93zcMpKuPO9k40EV7E1U7YqppoLH
    qtxxi2Jk2r0+9G4xSi1bbZUSFJJ6Ou+dwGO7VAVR51rCweSJG.BGYe8llZf1
    MThytvNfi43bni6iAh5BJgXnmy2GR6b0P5T5K7prCPeDTA0zpqo.W1WORUsk
    Uqpk41PObTf1b.CEDJPHWbj3qffNvUSXILrWXwsY0SyKAiRzfKLwIzmo4Esw
    66VQNdrQw203QDP3umIqH+GpKJNUUDrtnb5ywUOuacojbdijwagmxUPyWB8W
    otHua69pGsBAjZHxO7wxuvgMZ+7t2cIYa9LcaCkdde0QZZb54pR0WdK8IxoD
    1m5uen80ehrgN3C2a26cq1kGuMKUHDsdRQwU+b+BW4WMDnYiQdGoji87vE71
    woh0jbAltNQVInpKxxxRZeo5tQt5OIM9.gQYwJgE4TWowGNlGmxZ8CQSI75X
    ewl7rjjVUk5JO2yU1x6o2PeIdKaeKiMhqvu83iUcAqpwnsw6nEr1kwH6JZWR
    qojZpB1bbcqx0ZIseqozBvoi.VFHKkB3kAHf8jjm.hdCPwQtBPA3krb1dP1S
    fmob8sX1WAOSRNQKZVwIwozMRSxMU3Gxzb+lm0a4Pi0iAsffBTyO5nT2jZc3
    fFZccLi3tpsrelE16prxVNj86rmokk21cLLvSfmZdkN1deJIiv6Tq9OsZKsQ
    azDgqPWWIthj3paGuO5.q9QKMr92.eD9nAvpFzDNwnIV5.laGGv5hlgChln4
    AMK1PRn.GwHK9vW.7QOsP6hfpvfGQMF763MNtFLHt5OO35GAPs.ob9p4GKib
    jPIx0yzw6vkVCcSR7QgpYviVmloGVgl9R+Z8FWuzyePzzctlTJFrdTMS9TRq
    Io6VhYjTKlBBkVRMPAEFtzSH824Zm147QU5mXjgi1gAyxn80mXLtmz5vrwT+
    f5a49MmHF4L5.SHdo0hTtwKljyFm2nDOCjl3BF2PGDYSN17Q7i.r8M8gBTQN
    XkaMi6tHDNKt0Hq0qBZMn8cUPPPdUeN7x3FdfYSzsZAxxkc+dAJJcFybrv6G
    WrnxIeyAC+EELTsrUFEdjgmYtLhnlzbGdlY3EzbeMHchv7LPLojxq358iCEY
    mx2T0kW2W.ZK6aoEr3z5fV9KMVX1Y2493saaGkPUf0JDgoSEPTi52tbo1yXo
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Wev7P0v1gLncevGPVGW3PkKxS4wqZQyMCiv4vnm2RSvvijMe1BgQXyX
    O3OFkB8vyBLpWY70HXYQG5jHXC8Q0vZc5i3nkVejaAkQOxuQfdFDKi09RbTy
    JQTkkxfQY6JN3lp4..oSicqv.Uy4YL9zROznKh1vPO3OtTkE4IygAliEn2yL
    kszrAJz3lqq8xTVOSobpm8vEHOSIUiD4sDgFG8dTnCLjpX8nFsnxrI.M1dXs
    I1TMZr8viPoUbyMc.sDg1TRhguV16twQrYkiXetHIdKMW6VtaFavNjss09xp
    cO1Jc5MRQCC7Hj7wswVo02iXv9O3FpaujclXRMbDrIKsfkS33XwU.quFaTQY
    xFSjVsp2OtA2oBn+scp31NUbamJLNXNk6qtIIpgQNQ3SV3bPJ5V5J+xezv4.
    gNKcDxJ2GcKFT842ANJJLrFX8hFEXcV7POJRpHw1rtpJkAAcLLKWAcBW9jGl
    cCodNWHhFLKHpEk5BfvefiAY4HJywh20wfrgYYjbngQMY7UINjKUXWUSueAM
    WO6MrqPiOhcRK+1RHeL9H1IstZMRsioRMzdBiozIJCkZrEI0ld3hU8JPKRpM
    SuNxhj5.i0PbrHMDS2Sg9FAbKDrueOltGAaDAeZoOLTHmHUNHTchTUGJhAiS
    nS+mOLma498aQI7VTB6DjfM6IosotTur8xrHE3NsQJHTtwMdilJNiBWb5w5X
    eIZXErodeiLN4XiBV5HBljQ1JfX.zRwxxHWEfFUeDNK5irrc6RnWqT+5vMaW
    jYYD2nVCBzromKWDRyIoEGyxYlFkzG57BWn4+ou6RGbGMspmkaWMJXrNJM4A
    y4JAsKNRFzb.zyjdhlXsF3EOYaaUn5nk6FZFMj8Fd9HuYZaqnr7LtFQJ3eQ1
    vhelNhQ0KI0YOEPa0YgAAGCamGU22bjPCKeaeEZVnPihr2HgFYZnWhrmHJFY
    ZfWDCUsjzYYjogtMxdhUTjoAtMzdR4eFm4girm356+9Cl8ujQfVBs0M1R2s3
    d9CUbOIZB54LlAGfCbBLa46t2TmNrpdKXDHdSXfBrh2BnpSxSDRKxzepsv+5
    gL+kOBBV7LElixkRWz3YJrvYKQgUkHDDIIpIKUgoRVikooRixUi9pUrg7G7Y
    FmG2guKSIXc6PzjTvpu43zKMsfEmFy35wcQj9tqpEGE75LmCkAwbd6YPLSUY
    qazSlJKT8Zc7xzYceC5rAQuq0Y6WMbI0YaEPhITmcfIdNkp0Ek48TbT5rhZx
    Xr1Cwg2j+5JWjZX3syQRuYWsVMBI+xSaR1BOvai7qaqViYq1AvViZg60Gfj1
    qvZcgEO4ZEaxRR.EL5wBjXa90ke1ZDd4gPI7D3PqZa4hzRsA290ifW1ZEoGV
    2b8m+PstoRzD0zmvAQyfodgSVkU5JnoLien0LsKbpGPJSzLZRyx5F9MAnRYx
    aWOyhPgSdt39CtfO.A0oVqEcPTYtfyaj7++0CSHbKVeYCKOYvVeRbgbHi76Q
    zNxRo+CtY+SGRM9DAqrZTd7dgBPRme4kvT4lrpRyo99Wne4W7IBtpRTMMUQk
    zOSlI2UEz.9khS6s+Q0abdvPK6S5Fd7VLrdvTfQKFM2M5mci7YG0CiEHrwBD
    bdDHnABjav7IONl.PhyS8LIPAQFKPyiJTfAxCJX1DGOS5vvgyq7.MQdlG8Gr
    QJztyG.gMAfTBz7fPm01G5Mw27gPtlLDaF6wDtzNZO1YFxmb4wn4LlG44bci
    A.H7LJPlfPAyr7LlFj7sSyrIQlnBMepzx2EX1zXd4KUqw6xBmOyzlJQPaCiB
    7sNIxw1jnYcnlioVqQyj.Yj+GyG.46XWydXz78mMEyjJPPGi8XbdTgNODBCv
    Nr4aXOzHmpOK7HSu.AMQflGknyWxtFyPtyn.AMQfvyi.43Lk9DoBt2YmQUgr
    b1YS8rykZ2yj5PmGU9uyed++GZDWhiA
    -----------end_max5_patcher-----------

  • So... That was completely off-base and y'all are too polite to say so?