Old 05-31-2014, 12:21 PM   #1
ferro4prez
Human being with feelings
 
Join Date: Mar 2011
Posts: 48
Default Velocity Expansion

Hi all! I'm just looking for a quick dirty fix for my midi controller's limited velocity output. Literally, if someone can help me write a little JS snippet that maps velocity from (20-110) to (10-127), I'll be the happiest of campers.

I did the math, and the function f(x) = (13x - 160) / 10 will linearly accomplish this.

Could someone tell me what JS code would take the input velocity value, and times-it-by-13-subtract-160-all-over-10, then spit it back out at this remapped velocity ?


The ultimate version of this would let you type in your controller's lowest and highest possible velocities, and let it remap it to (0-127) or whatever you choose, automatically. I'll be happy to just get mine working in the meantime though

THANKS!
Ferro

Last edited by ferro4prez; 05-31-2014 at 12:24 PM. Reason: punctuation
ferro4prez is offline   Reply With Quote
Old 06-02-2014, 11:56 AM   #2
mwe
Human being with feelings
 
mwe's Avatar
 
Join Date: Mar 2012
Location: Kentucky, USA
Posts: 254
Default

Try this.

EDIT: If you have time, try the second one and see what you think.
Attached Files
File Type: zip MIDI Velocity Expander.zip (811 Bytes, 287 views)
File Type: zip MIDI Velocity Range Tool.zip (831 Bytes, 352 views)

Last edited by mwe; 06-02-2014 at 03:30 PM.
mwe is offline   Reply With Quote
Old 06-10-2014, 12:48 PM   #3
ferro4prez
Human being with feelings
 
Join Date: Mar 2011
Posts: 48
Default

My god man, THANK YOU! This does precisely what I need!!! I really appreciate your help with this, my controller feels as close to a real piano as I think possible. I'm positive that many people would get so much use out of these scripts, in particular the one that allows you to input ranges.


All the best!
Ferro
ferro4prez is offline   Reply With Quote
Old 05-19-2019, 03:18 PM   #4
CEART
Human being with feelings
 
CEART's Avatar
 
Join Date: Jul 2018
Location: LAITW
Posts: 176
Default update

Quote:
Originally Posted by mwe View Post
Try this.

EDIT: If you have time, try the second one and see what you think.
Sorry for un-dust this old thread. Is there some updated or new midi tool(s) for replace this dated 2014 or it is still fine to use? I can't found velocity input transformation in ReaControlMIDI.

Thanks in advance.

Last edited by CEART; 05-19-2019 at 04:01 PM.
CEART 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 04:20 PM.


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