Old 09-13-2009, 02:57 AM   #1
mabian
Human being with feelings
 
mabian's Avatar
 
Join Date: Aug 2007
Location: Italy
Posts: 3,613
Default New JS MIDI effect for realtime quantize with swing - 1.1 update

Hello all,

[EDIT: Updated to v1.1 on 2009-10-08!!!]

Here is a first stable - quite usable for me - version of a JS effect that allows quantizing in realtime while playing and it's also able to apply swing.
In other words, with this JS you get note and poly aftertouch events quantized, non destructively and on the fly.
Very interesting - for me at least - to experiment with different settings without having to perform actual note quantize on item events.

Some notes:

- The plugin doesn't use pdc, and needs MIDI data to be sent earlier (you have to shift the MIDI items by beats): a slider is used to tell the plugin how much earlier data is sent (in beats) but items have to be moved manually. There are some quirks on looping due to this fact, but I find it very usable anyway. I hope Reaper soon implements an integrated track delay control, so that using this plugin can become much easier. The lookahead is needed to be able to move events forward and backward in time.
If your events are already quantized and you just want to apply swing, you can zero the delay parameter and you just get true realtime swing (works only for positive swing parameters).

- Only works for data in items, no live/recording quantize, and only when playing/recording.

- Quantize strength and swing are configurable with 0-100% (strength) and -100% to 100% (swing) values

- Can move (offset) the quantize grid, to allow putting events slightly earlier or later.

- Can quantize data from any MIDI channel or a single MIDI channel, multiple channel events on same instance are correctly supported from v1.1.

- Quantize intervals are expressed in fractions of beat; so if you have a 4/4 song, 1/4 beat actually means 1/16th notes, 1/8 means 1/32th and so on.
To help you in this, every option also shows the real note values supposing that 1 beat = 1/4 notes.

- The behavior is not predictable when notes with same pitch overlap

- The swing option works the same as REAPER native swing for values 0-100%, while it moves notes earlier than the conventional swing for negative swing values.

- NEW in v1.1: humanize parameter

- NEW in v1.1: window parameter to allow affecting events based on their distance from the quantize grid

- NEW in v1.1: short PDF guide

Any feedback on problems, enhancements and whatever else is welcome.

https://stash.reaper.fm/4070/MB_Note_Quantize_1.1.zip

Thanks,
Mario
__________________
My DAW: Intel i7700k @4.2GHz / 16GB RAM / RME Fireface UC / 250GB SSD / 2x2TB HD / Win10x64
My Music: http://www.reverbnation.com/errepici - http://www.errepici.it/web/contents.asp?sec=4

Last edited by mabian; 10-30-2009 at 03:35 PM. Reason: Updated to v1.1
mabian is offline   Reply With Quote
Old 09-13-2009, 03:01 AM   #2
nicholas
Moderator
 
nicholas's Avatar
 
Join Date: Jan 2007
Location: Van Diemen's Land
Posts: 9,334
Default

Well done and thank you!
__________________
Learning Manuals and Reaper Books
REAPER Unleashed - ReaMix - REAPER User Guide
http://www.lulu.com/spotlight/glazfolk
nicholas is offline   Reply With Quote
Old 09-13-2009, 03:26 AM   #3
stratman
Human being with feelings
 
stratman's Avatar
 
Join Date: Oct 2007
Location: Woking, England
Posts: 2,685
Default

Just downloaded it and I'm looking forward to trying it.

I'll add this to my long list of distractions from doing the music I'm supposed to be doing

Pete
stratman is offline   Reply With Quote
Old 09-13-2009, 08:17 AM   #4
Finnish
Human being with feelings
 
Finnish's Avatar
 
Join Date: Jun 2006
Location: Finland, Kuopio
Posts: 886
Default

Hmm, I'm about to do some midi-work with e-drums (Millenium MPS-400). I know my timing is shit, I'm not a drummer. I hope this will speed up my workflow, I know I have to quantize my stuff after playing but I haven't done that actually at all. I'll sure try this!
__________________
REGISTERED USER
My music, studio and bands
Finnish is offline   Reply With Quote
Old 09-13-2009, 08:47 AM   #5
sinkmusic
Human being with feelings
 
sinkmusic's Avatar
 
Join Date: Feb 2006
Location: decepticon mothership in a hidden place inside a mountain
Posts: 3,413
Default

thank you, mario
sinkmusic is offline   Reply With Quote
Old 09-14-2009, 05:03 AM   #6
whatsup
Human being with feelings
 
whatsup's Avatar
 
Join Date: Aug 2008
Posts: 1,144
Default

Quote:
I hope Reaper soon implements an integrated track delay control, so that using this plugin can become much easier.
i don't know how delay can help, but this is a simple delay, may it can help.
__________________
you can contack me on
whatsup@inn.co.il
whatsup is offline   Reply With Quote
Old 09-14-2009, 05:09 AM   #7
mabian
Human being with feelings
 
mabian's Avatar
 
Join Date: Aug 2007
Location: Italy
Posts: 3,613
Default

Quote:
Originally Posted by whatsup View Post
i don't know how delay can help, but this is a simple delay, may it can help.
Unless it's able to move data earlier instead of later, I fear not

The quantize plugin needs data earlier to be able to move data freely back and forth in time, and cannot use delay compensation because a little delay in MIDI is a big delay in samples, so likely to hog the system.

Thx anyway,
Mario
__________________
My DAW: Intel i7700k @4.2GHz / 16GB RAM / RME Fireface UC / 250GB SSD / 2x2TB HD / Win10x64
My Music: http://www.reverbnation.com/errepici - http://www.errepici.it/web/contents.asp?sec=4
mabian is offline   Reply With Quote
Old 09-14-2009, 06:22 AM   #8
BenK-msx
Human being with feelings
 
BenK-msx's Avatar
 
Join Date: Jun 2008
Location: Whales, UK
Posts: 5,742
Default

the JS: time adjustment does that i believe

move earlier or later... and introduces its own latency.

thought worthy of a mention

Last edited by BenK-msx; 09-14-2009 at 06:24 AM.
BenK-msx is offline   Reply With Quote
Old 09-14-2009, 06:25 AM   #9
mabian
Human being with feelings
 
mabian's Avatar
 
Join Date: Aug 2007
Location: Italy
Posts: 3,613
Default

Quote:
Originally Posted by BenK-msx View Post
the JS: time adjustment does that i believe.

move earlier or later...

thought worthy of a mention
Then you can try it instead of moving the data for real.

I've been warned from schwa though that using such a high delay compensation value (and time adjustment does use delay compensation IIRC) could be very heavy load for CPU... and would introduce a huge delay when recording live.

The quantize plugin needs delay in order of beats, which is *many* samples.

Anyway, I could give it a check

Thanks,
Mario
__________________
My DAW: Intel i7700k @4.2GHz / 16GB RAM / RME Fireface UC / 250GB SSD / 2x2TB HD / Win10x64
My Music: http://www.reverbnation.com/errepici - http://www.errepici.it/web/contents.asp?sec=4
mabian is offline   Reply With Quote
Old 09-14-2009, 06:54 AM   #10
BenK-msx
Human being with feelings
 
BenK-msx's Avatar
 
Join Date: Jun 2008
Location: Whales, UK
Posts: 5,742
Default

yeh just playing with it now -

wuth Js time adjust at the *end* of the fx chain - with your plug at the start and e.g a vsti -

and with the tempo at 120 (& lappy audio at 44.1) i set the time adjust to -1000 ms and all seems to line up. works well - good for auditioning quantise and swing quickly, then can apply as new take etc.
as you say not a live input kind of thing but saves the step of manually moving.

cpu on one track goes from e.g 0.3 to 1.3 with the -ve time delay on as a rough guide.

is there an easier way to figure out the delay required as the js only has ms or samples input. or could that be displayed on your plug? not a huge problem just wondering.

thanks for your efforts btw.
BenK-msx is offline   Reply With Quote
Old 09-14-2009, 07:15 AM   #11
mabian
Human being with feelings
 
mabian's Avatar
 
Join Date: Aug 2007
Location: Italy
Posts: 3,613
Default

You should try putting the time adjustment plugin first, then quantize, then VSTi. I can surely print the ms adjustment needed to compensate beats, it's a quick calculation.

1 beat = (60000 / BPM) milliseconds

Example: BPM = 120 -> 1 beat = 60000 / 120 = 500 milliseconds

You can try setting BPM = 120, time adjustment = 500 milliseconds earlier,
quantize delay = 1 beat, quantize interval = 1/2 beat (=1/8th note)

If CPU doesn't scream you should be okay without ever moving data around...

- Mario
__________________
My DAW: Intel i7700k @4.2GHz / 16GB RAM / RME Fireface UC / 250GB SSD / 2x2TB HD / Win10x64
My Music: http://www.reverbnation.com/errepici - http://www.errepici.it/web/contents.asp?sec=4
mabian is offline   Reply With Quote
Old 09-14-2009, 12:29 PM   #12
whatsup
Human being with feelings
 
whatsup's Avatar
 
Join Date: Aug 2008
Posts: 1,144
Default

Quote:
Originally Posted by mabian View Post
Unless it's able to move data earlier instead of later, I fear not
now it does that too.<-click

EDIT: can delay by seconds, samples, beats.
__________________
you can contack me on
whatsup@inn.co.il
whatsup is offline   Reply With Quote
Old 09-14-2009, 04:03 PM   #13
whatsup
Human being with feelings
 
whatsup's Avatar
 
Join Date: Aug 2008
Posts: 1,144
Default

Quote:
Originally Posted by mabian View Post
You should try putting the time adjustment plugin first, then quantize, then VSTi.
if i don't miss something, i think you assume the adjustment fx delay MIDI.

but no, it delay only AUDIO.

so after little thinking, i concluded that what needed is to put
quantize FX first, then VSTi then time adjustment with predelay (minus).

that way all other tracks will start play after you quantized the midi data.

so my FX do that also with MIDI beats.
__________________
you can contack me on
whatsup@inn.co.il

Last edited by whatsup; 09-14-2009 at 04:12 PM.
whatsup is offline   Reply With Quote
Old 10-30-2009, 03:28 PM   #14
mabian
Human being with feelings
 
mabian's Avatar
 
Join Date: Aug 2007
Location: Italy
Posts: 3,613
Default

Plugin updated - and released as stable - with new controls and refined behaviour.

See first post for new link.

Enjoy!

- Mario
__________________
My DAW: Intel i7700k @4.2GHz / 16GB RAM / RME Fireface UC / 250GB SSD / 2x2TB HD / Win10x64
My Music: http://www.reverbnation.com/errepici - http://www.errepici.it/web/contents.asp?sec=4
mabian is offline   Reply With Quote
Old 11-18-2009, 04:11 PM   #15
Alxi
Human being with feelings
 
Alxi's Avatar
 
Join Date: Jan 2009
Posts: 421
Default

Thanks, i will give this a try soon

-Alxi
Alxi is offline   Reply With Quote
Old 03-29-2011, 07:05 AM   #16
rune_kg
Human being with feelings
 
Join Date: Mar 2011
Posts: 1
Default Some notes lost

Some notes get lost (when "new_mpos" and "mpos" is negative). Adding this in line 155 solved the problem for me:

(mpos < 0) ? (
mpos += samples_per_beat * quantize_mult;
);
rune_kg is offline   Reply With Quote
Old 04-03-2011, 02:36 PM   #17
mabian
Human being with feelings
 
mabian's Avatar
 
Join Date: Aug 2007
Location: Italy
Posts: 3,613
Default

Thank you very much, I will check the code to be sure the change doesn't have side effects!

- Mario
__________________
My DAW: Intel i7700k @4.2GHz / 16GB RAM / RME Fireface UC / 250GB SSD / 2x2TB HD / Win10x64
My Music: http://www.reverbnation.com/errepici - http://www.errepici.it/web/contents.asp?sec=4
mabian is offline   Reply With Quote
Old 07-12-2011, 08:20 AM   #18
Shatva
Human being with feelings
 
Join Date: Jul 2011
Posts: 2
Default A True realtime method quantizer idea

Quote:
Originally Posted by mabian View Post
Thank you very much, I will check the code to be sure the change doesn't have side effects!
- Mario
Hello! Maybe you guys taping in a wrong direction. That type of quantizing will be allways have issues because of timing.

Try to something else radicaly. If you have timing clock, and a divide in 1/8 etc. why let the fingers to play out of that grid? You need a shadow back grid like my EMU E5000 Ultra- arpeggio have.There is an option to not retrigger the emus seq- arpeggio clock when play a note. So that have a clock that moves on back, and the arpeggio only plays when the next clock is came. So it wont let any notes to go forward or backward from the grid, it always play on a clocks divide beat. It can happen in a a live quantizer too. Its a simple idea. But, many times a simple can be more.
Shatva is offline   Reply With Quote
Old 11-09-2011, 06:19 AM   #19
bangfruit
Human being with feelings
 
Join Date: Apr 2011
Posts: 2
Default Installation

I have downloaded this and would like to use with reaper 4. Anyone have instructions on installing.
bangfruit is offline   Reply With Quote
Old 11-09-2011, 08:01 AM   #20
DarkStar
Human being with feelings
 
DarkStar's Avatar
 
Join Date: May 2006
Location: Surrey, UK
Posts: 18,146
Default

Unzip it

If the file has a (.txt ?) extension, remove it.

Start Reaper, select [Options] >> "Show Reaper resource path ..." (that folder may be hidden, so you might need to unhide it in Explorer / Folder options or Finder / ...)

Open the Effects folder, create a sub-folder if you want and move the JS Fx into there.

Restart Reaper and it should show up in the FX browser.
__________________
DarkStar ... interesting, if true. . . . Inspired by ...
DarkStar is online now   Reply With Quote
Old 11-09-2011, 08:24 AM   #21
mabian
Human being with feelings
 
mabian's Avatar
 
Join Date: Aug 2007
Location: Italy
Posts: 3,613
Default

Thanks Darkstar for this.

- Mario
__________________
My DAW: Intel i7700k @4.2GHz / 16GB RAM / RME Fireface UC / 250GB SSD / 2x2TB HD / Win10x64
My Music: http://www.reverbnation.com/errepici - http://www.errepici.it/web/contents.asp?sec=4
mabian is offline   Reply With Quote
Old 11-09-2011, 09:00 AM   #22
politcat
Human being with feelings
 
politcat's Avatar
 
Join Date: Jul 2006
Location: stuck in transition
Posts: 1,857
Default

hey mabian (or anyone else who can help)

i do all my composing in Live. do you know how to make this work as a midi effect using ReaJS in Live? (as opposed to ReaJS audio effect)

iow, how to make Live recognize ReaJS as a midi effect so i can use your JS plugin in Live

thx!
politcat is offline   Reply With Quote
Old 11-09-2011, 09:09 AM   #23
mabian
Human being with feelings
 
mabian's Avatar
 
Join Date: Aug 2007
Location: Italy
Posts: 3,613
Default

Hi politcat, honestly I never used this plugin in ReaJS; I guess you should copy/paste the content of the plugin file (which is a text file) in a ReaJS instance in Live.

I thought Live had powerful realtime quantize features per track, no?

- Mario
__________________
My DAW: Intel i7700k @4.2GHz / 16GB RAM / RME Fireface UC / 250GB SSD / 2x2TB HD / Win10x64
My Music: http://www.reverbnation.com/errepici - http://www.errepici.it/web/contents.asp?sec=4
mabian is offline   Reply With Quote
Old 11-09-2011, 09:33 AM   #24
whoobs
Human being with feelings
 
Join Date: Dec 2009
Posts: 188
Default

Hey forums,

SO i got this plugin installed, but i'm not exactly sure the best way to go about using it. I understand it uses a delay to compensate for its ability to quantize on the fly. But when i play my midi keyboard it is difficult to play correctly due to the delay before the sound arrives. Also the midi notes don't seem to be exactly quantized after i stop recording. What am i missing?
whoobs is offline   Reply With Quote
Old 11-09-2011, 09:40 AM   #25
mabian
Human being with feelings
 
mabian's Avatar
 
Join Date: Aug 2007
Location: Italy
Posts: 3,613
Default

Hi Whoobs, this plugin should definitely be bypassed while recording (REAPER has native input quantize when recording btw).

It should be used only to process data which has already been recorded.

Also, data should be moved earlier due to plugin induced latency, and the corresponding amount of anticipation - in beats - must be specified in the "delay" parameter if I remember well the parameter name).

- Mario
__________________
My DAW: Intel i7700k @4.2GHz / 16GB RAM / RME Fireface UC / 250GB SSD / 2x2TB HD / Win10x64
My Music: http://www.reverbnation.com/errepici - http://www.errepici.it/web/contents.asp?sec=4
mabian is offline   Reply With Quote
Old 11-09-2011, 10:40 AM   #26
whoobs
Human being with feelings
 
Join Date: Dec 2009
Posts: 188
Default

Hey M --- thanks for the heads up. I get it now, if the delay is 2 beats, move my whole midi item forward (after recording) by two beats and enable the plug in.

Whats the conceptual difference between this and Reaper's native input quantize then? The IN [track recording settings (input quantize format)].

Thanks again,
whoobs
whoobs is offline   Reply With Quote
Old 11-09-2011, 10:51 AM   #27
mabian
Human being with feelings
 
mabian's Avatar
 
Join Date: Aug 2007
Location: Italy
Posts: 3,613
Default

Quote:
Originally Posted by whoobs View Post
Hey M --- thanks for the heads up. I get it now, if the delay is 2 beats, move my whole midi item forward (after recording) by two beats and enable the plug in.

Whats the conceptual difference between this and Reaper's native input quantize then? The IN [track recording settings (input quantize format)].

Thanks again,
whoobs
You're welcome!

I think there are some very interesting benefits; the main one is that you can keep your data recorded as it was played and have the plugin correct it non destructively on the fly while playing back. If you like the timing you can "freeze it" by rendering as new take in a new track and keep the original track muted.

Also, you can change values when you want, for example you can decide you want to increase the swing or change other settings, you can always revert to the original values or tweak them at your leisure without altering the real data. Only the timing on playback changes.

And, you can automate the various parameters, for example altering strength and swing in various parts of the song.

Finally, it supports "negative swing", that is notes that play reverse swing. Reverse swing was added recently in regular native quantize, I don't think it's supported in native input quantize.

Hope it helps,
Mario
__________________
My DAW: Intel i7700k @4.2GHz / 16GB RAM / RME Fireface UC / 250GB SSD / 2x2TB HD / Win10x64
My Music: http://www.reverbnation.com/errepici - http://www.errepici.it/web/contents.asp?sec=4
mabian is offline   Reply With Quote
Old 12-07-2019, 04:27 AM   #28
n997
Human being with feelings
 
Join Date: Dec 2018
Posts: 83
Default

Thanks for this! It gives non-destructive swing like in FL Studio and Ableton Live, and is actually better than either of those because parameters can be adjusted and automated.

As far as I have tested, when Delay is set to 0, this works like what Live and FL Studio users might expect.


(I know it's an old thread but it's worth bumping - I remember people asking for this functionality in past months)
n997 is offline   Reply With Quote
Old 12-07-2019, 02:09 PM   #29
Regisfofo
Human being with feelings
 
Regisfofo's Avatar
 
Join Date: Mar 2017
Location: France
Posts: 285
Default

Ah thanks for bumping, I'll take a look to that one!
Regisfofo is online now   Reply With Quote
Old 12-08-2019, 01:54 AM   #30
mabian
Human being with feelings
 
mabian's Avatar
 
Join Date: Aug 2007
Location: Italy
Posts: 3,613
Default

Thanks all for the kind words, I guess I'll have to check and revisit this plug to see if it still works well with V6.
Also, I'd like a lot to get rid of the necessity to put data earlier to make it work properly. Will check it.

- Mario
__________________
My DAW: Intel i7700k @4.2GHz / 16GB RAM / RME Fireface UC / 250GB SSD / 2x2TB HD / Win10x64
My Music: http://www.reverbnation.com/errepici - http://www.errepici.it/web/contents.asp?sec=4
mabian is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 11:38 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.