diff options
author | Hans Baier <hansfbaier@googlemail.com> | 2008-04-03 21:47:47 +0000 |
---|---|---|
committer | Hans Baier <hansfbaier@googlemail.com> | 2008-04-03 21:47:47 +0000 |
commit | fbfe9a798313fcb98b2d25df8d23c5c90c76a7ef (patch) | |
tree | 4d99a55cb00c85b67c2936cddce46ae411f44fe8 /gtk2_ardour/midi_util.h | |
parent | 6554200e66cc243e92818e6e74d4647d1c34ae9c (diff) |
* implemented editing velocities (http://tracker.ardour.org/view.php?id=2148)
* added MIDI panic button (http://tracker.ardour.org/view.php?id=2118)
* bugfix: moving notes above midi 127 or below 0 does not wrap around anymore
* bugfix: deadlock on editing notes after playback (http://tracker.ardour.org/view.php?id=2140) due to unbalanced lock acquire/release
* bugfix: First note off lost in playback (http://tracker.ardour.org/view.php?id=2132)
* bugfix: Last note off lost in saving MIDI files (http://tracker.ardour.org/view.php?id=2132)
* bandaid fix for http://tracker.ardour.org/view.php?id=1985 (Cannot reopen session because jack ports are not unregistered on session close)
* bandaid fix: replaced conf.CheckPKGExists ('\"slv2 >= 0.6.0\"') by conf.CheckPKGExists ('slv2') in SConstruct, because the former would fail,
even if SLV 0.6.0 was installed
* added/enabled debugging output for debugging MIDI model (might be removed later)
git-svn-id: svn://localhost/ardour2/branches/3.0@3211 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/midi_util.h')
-rw-r--r-- | gtk2_ardour/midi_util.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/gtk2_ardour/midi_util.h b/gtk2_ardour/midi_util.h index 451fc55ea1..d56f1680e0 100644 --- a/gtk2_ardour/midi_util.h +++ b/gtk2_ardour/midi_util.h @@ -54,5 +54,14 @@ inline static uint32_t note_fill_color(uint8_t vel) } } +inline static void clamp_0_to_127(uint8_t &val) +{ + if( (127 < val) && (val < 192) ) { + val = 127; + } else if( (192 <= val) && (val < 255) ) { + val = 0; + } +} + #endif /* __gtk_ardour_midi_util_h__ */ |