Randomized scaler held notes ~Rozeta scaler +Rozeta lfo

Hello @brambos

I am attempting to use Rozeta scaler in conjunction with Rozeta LFO to create a midi filter that makes the incoming note pitches jump up and down

My workflow is this
Rozeta scaler 1(initial transposition and scaling)
Rozeta scaler 2 (scaler 1 is routed to 2, pre transposition is controlled by Rozeta LFO)
Rozeta LFO (output fed to Rozeta scaler 2)

I have tried many configurations including only using a single instance of scaler (better for my purposes to use two as it allows for more transposition control) ~ have tried randomizing the post transposition , pre transposition, tempo syncing the LFO etc~ no matter what I do it seems if I am playing a slew of fast notes I get infinitely held notes with the LFO modulating the scaler. This does not happen if I am not modulating the scaler. I am using TC data to send control signals so there are many rapidly firing notes as I drag my finger across the screen

Is there any way that I can configure the interaction of the LFO and the scaler such that I will not get infinitely held/stuck notes or would something need to be tweaked within the backend of the scaler plugin itself?

Thanks so much again!!

Comments

  • You get held notes because the note-on may transpose to a different note than the note off if the transpose changed while the note is held.

    I already handled such problems in some of my mozaic scripts. Upon note-on, the transposition result for the current note has to be stored and when the current note‘s note-off arrives, the stored result has to be send as note-off since the transposition may have meanwhile changed.

    I can post a short script taking a fixed CC as transpose input (val 64 is center) and also handles the note-on/ooff problem for all incoming channels.

  • @_ki said:
    You get held notes because the note-on may transpose to a different note than the note off if the transpose changed while the note is held.

    I already handled such problems in some of my mozaic scripts. Upon note-on, the transposition result for the current note has to be stored and when the current note‘s note-off arrives, the stored result has to be send as note-off since the transposition may have meanwhile changed.

    I can post a short script taking a fixed CC as transpose input (val 64 is center) and also handles the note-on/ooff problem for all incoming channels.

    Amazing thank you so so much

    If you wouldn’t mind reposting that code I’d love that thank you!

  • _ki_ki
    edited June 18

    @annahahn The initial working version was:

    @OnLoad
      ccCmd = 0xB0   // Midi-CC-Cmd on channel 0   
      ccId  = 13
      transpose =  0    
    
      LabelKnobs {Midi-CC Automatable Transposer 0.1}
      ResetNoteStates -1  
    @End
    
    @OnMidiInput
      if MIDICommand = 0x90
        note = MIDINote + transpose
        if note >= 0 and note <= 127
          SendMIDINoteOn MIDIChannel, note, MIDIVelocity 
          SetNoteState MIDIChannel, MIDINote , note
        endif
    
      elseif MIDICommand = 0x80
        note = GetNoteState MIDIChannel, MIDINote 
        if note >= 0
          SendMIDINoteOff MIDIChannel, note, MIDIVelocity 
          SetNoteState MIDIChannel, MIDINote , -1
        endif
    
      elseif MIDICommand = ccCmd and MIDIByte2 = ccId
        transpose = MIDIByte3 -64
    
      else
        SendMIDIThru
      endif
    @End
    

    But it didn‘t take that long to add support for knobs to specify CC channel, CC ID and transposition.

    Because Mozaic includes scale support (which i didn’t play around with yet) and i was already into it, i added optional scale and root-note support and two more CCs (which also got their knobs) and now you can find the full featured script on patchstorage :)

  • @_ki said:
    @annahahn The initial working version was:

    @OnLoad
      ccCmd = 0xB0   // Midi-CC-Cmd on channel 0   
      ccId  = 13
      transpose =  0    
      
      LabelKnobs {Midi-CC Automatable Transposer 0.1}
      ResetNoteStates -1  
    @End
    
    @OnMidiInput
      if MIDICommand = 0x90
        note = MIDINote + transpose
        if note >= 0 and note <= 127
          SendMIDINoteOn MIDIChannel, note, MIDIVelocity 
          SetNoteState MIDIChannel, MIDINote , note
        endif
        
      elseif MIDICommand = 0x80
        note = GetNoteState MIDIChannel, MIDINote 
        if note >= 0
          SendMIDINoteOff MIDIChannel, note, MIDIVelocity 
          SetNoteState MIDIChannel, MIDINote , -1
        endif
        
      elseif MIDICommand = ccCmd and MIDIByte2 = ccId
        transpose = MIDIByte3 -64
    
      else
        SendMIDIThru
      endif
    @End
    

    But it didn‘t take that long to add support for knobs to specify CC channel, CC ID and transposition.

    Because Mozaic includes scale support (which i didn’t play around with yet) and i was already into it, i added optional scale and root-note support and two more CCs (which also got their knobs) and now you can find the full featured script on patchstorage :)

    Hi @_ki !

    Thank you so much for this! The full fledged version of your patch works very very well

    One question, when your patch receives a rapid slew of notes from rapidly dragging 2 or 3 of my fingers across the TC data screen your patch still produces some stuck/held notes

    Are there any easy tweaks/parameter changes I can make to your code that will eliminate this problem or do you have any other suggestions?

    Thanks so much!

  • wimwim
    edited June 23

    Some synths are more prone to stuck notes than others. Sometimes, even if the upstream app is sending all the right note-ons and offs, apps just don’t process them 100%, particularly if there are a lot of notes and, especially polyphony.

    Can you flood the app you’re playing with TC-Data and no intervening apps without getting stuck notes? If so then it’s the plugins, if not then it’s the app.

    It seems that no matter how hard I try to eliminate stuck notes, there are always a few that get away. Could be lack of programming skill on my part, but in that I’m not alone. Lots of apps get or cause stuck notes.

  • edited June 23

    @wim said:
    Some synths are more prone to stuck notes than others. Sometimes, even if the upstream app is sending all the right note-ons and offs, apps just don’t process them 100%, particularly if there are a lot of notes and, especially polyphony.

    Can you flood the app you’re playing with TC-Data and no intervening apps without getting stuck notes? If so then it’s the plugins, if not then it’s the app.

    It seems that no matter how hard I try to eliminate stuck notes, there are always a few that get away. Could be lack of programming skill on my part, but in that I’m not alone. Lots of apps get or cause stuck notes.

    Hi @wim !

    Thanks for this~ yes in this instance I can successfully flood the app with notes from TC-data without a stuck note UNTIL I introduce the note transposer that @_constructed in mozaic

  • Ahh. Well, yes, I’ve had the same challenges. When I look at the code of one of my scripts, that I worked very hard to assure had no stuck notes, I can’t find any cause, yet occasionally they are there. It’s a tough problem. @_ki is a much better programmer than I am, so I guess I don’t feel quite as bad about my issues if stuck notes can escape his net too.

  • I’ll also have another look at Scaler itself when I find the time. But it should already have precautions for stuck notes built in :)

  • @annahahn said:
    Thanks for this~ yes in this instance I can successfully flood the app with notes from TC-data without a stuck note UNTIL I introduce the note transposer that @_constructed in mozaic

    Are there still stuck notes, if the transposer script is not automated ?

    If not then i have an idea what‘s happening. In my midi matrix script i checked both the input and output notes for double note-on/off, in this script i only checked the input. If for instance one input note is transposed to C3, there might be a second, different input note that is also transposed to C3 since the transpose might have changed. This double C3 will produce problems in the synth, even if there are 2 note-offs for it.

    So i‘ll add a second ‚test-for-double-notes‘ to the script, sorry that i missed that possibility in the first run :)

    .

    Since Mozaic only offers one NoteState array, i‘ll need to trick arround by mapping both stages into a single array - i already have code for that :)

  • _ki_ki
    edited June 24

    You‘ll have to wait for an updated script, as on my iPad there is a ‚save‘ problem in the just updated 1.0.7 Mozaic version.

    I had everything ready and tested and even coded a unit-testing script that generated all corner cases, like double-note on/off, or double notes after transposing etc . I probably need to recode and re-debug everything after a Mozaic bugfix is released.

    Since i‘ll be offline for a week, a new script will not be available until thursday next week :/

    .

    Of course i‘ve written a Mozaic bug report.

  • @_ki said:
    You‘ll have to wait for an updated script, as on my iPad there is a ‚save‘ problem in the just updated 1.0.7 Mozaic version.
    Of course i‘ve written a Mozaic bug report.

    Yeah, expect a fast fix asap. I'm on it.

  • @_ki said:
    You‘ll have to wait for an updated script, as on my iPad there is a ‚save‘ problem in the just updated 1.0.7 Mozaic version.

    I had everything ready and tested and even coded a unit-testing script that generated all corner cases, like double-note on/off, or double notes after transposing etc . I probably need to recode and re-debug everything after a Mozaic bugfix is released.

    Since i‘ll be offline for a week, a new script will not be available until thursday next week :/

    .

    Of course i‘ve written a Mozaic bug report.

    Amazing thank you so much @_ki ~really appreciate you helping us out with an updated version🙌🙌🙌

  • _ki_ki
    edited July 4

    @annahahn
    I Just updated the patchstorage version to v1.1 that includes an updated note-on/off handling and hopefully got rid of stuck notes.

Sign In or Register to comment.