MIDI Velocity Curve Calculator
Map raw MIDI note velocity (0–127) to a shaped output velocity using curve types like linear, exponential, or soft. Used by keyboardists and producers to fine-tune touch response and dynamics in DAWs and hardware.
About this calculator
MIDI velocity is a 7-bit integer (0–127) representing how hard a key is struck. A velocity curve remaps that raw input to a different output value, changing how an instrument responds to your playing dynamics. The core formula is: outputVelocity = clamp(threshold, 127, inputVelocity × (sensitivity / 100) × curveFactor), where curveFactor depends on the selected curve type. For exponential: curveFactor = (inputVelocity / 127)^1.5, emphasising harder hits. For logarithmic: curveFactor = log(inputVelocity + 1) / log(128), boosting softer touches. Soft uses √(inputVelocity / 127) for gentle response, while hard uses (inputVelocity / 127)² for a steep dynamic jump. Linear keeps curveFactor = 1, passing velocity through with only sensitivity scaling. The threshold value sets a floor so no output falls below a minimum audible level.
How to use
Suppose you play a key with inputVelocity = 80, choose an exponential curve, set sensitivity = 100%, and threshold = 10. Step 1 — compute curveFactor: (80 / 127)^1.5 = (0.6299)^1.5 ≈ 0.500. Step 2 — apply sensitivity: 80 × (100 / 100) × 0.500 = 40.0. Step 3 — clamp to threshold: max(10, min(127, 40)) = 40. Your output velocity is 40, noticeably softer than the raw 80, meaning the exponential curve makes the instrument respond more gently to medium key strikes, rewarding only the hardest playing with loud output.
Frequently asked questions
What is the difference between exponential and logarithmic MIDI velocity curves?
An exponential curve (curveFactor = (v/127)^1.5) compresses lower velocities and stretches higher ones, so you must play harder to get louder output — ideal for instruments that should feel resistant. A logarithmic curve (curveFactor = log(v+1)/log(128)) does the opposite: it amplifies quiet keystrokes disproportionately, making soft playing more expressive and loud playing relatively compressed. Choosing between them depends on whether you want to reward forceful playing or fine-tune subtle dynamics. Most DAWs let you preview both curves in real time.
How does the sensitivity percentage affect MIDI velocity output?
Sensitivity scales the entire output linearly before any threshold clamping. At 100% the curve formula runs as-is, while at 50% every output value is halved, effectively making the instrument respond at half the intended dynamic range. Values above 100% amplify output beyond the raw input, potentially clipping at 127. Adjusting sensitivity is useful when a particular keyboard naturally outputs velocities that are consistently too high or too low for a virtual instrument patch.
When should I use a velocity threshold in MIDI performance?
A velocity threshold sets a minimum output value, ensuring that even the lightest keypress triggers an audible note rather than an inaudibly quiet one. This is especially useful for live performance where accidental ghost notes at velocity 1–5 would be nearly silent and disruptive. Setting a threshold of, say, 20 guarantees every intentional keystroke is heard clearly. Be cautious with high thresholds — they reduce your effective dynamic range by compressing the floor of expression.