13
0

Fix MIDI metering to not "clip" on many notes.

git-svn-id: svn://localhost/ardour2/trunk@1951 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
David Robillard 2007-06-04 03:24:14 +00:00
parent 10a282777a
commit e9de0dec8a

View File

@ -53,7 +53,7 @@ PeakMeter::run (BufferSet& bufs, nframes_t nframes, nframes_t offset)
if ((ev.buffer[0] & 0xF0) == MIDI_CMD_NOTE_ON) {
const float normal_vel = ev.buffer[2] / 127.0;
if (normal_vel > val)
val += normal_vel;
val = normal_vel;
} else {
val += 1.0 / bufs.get_midi(n).capacity();
}