aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Hanspeter Portner <dev@open-music-kontrollers.ch>2019-04-07 11:33:24 +0200
committerGravatar Hanspeter Portner <dev@open-music-kontrollers.ch>2019-04-07 11:33:24 +0200
commit36a2b9b94f845675756d8561f057c0cb738f0ad3 (patch)
tree0f990406dc36cf16910ca0e97692fe69d8d1347c
parentd18ff51704483d36c6228368f5b49f20940c64fc (diff)
downloadmonitors.lv2-36a2b9b94f845675756d8561f057c0cb738f0ad3.zip
monitors.lv2-36a2b9b94f845675756d8561f057c0cb738f0ad3.tar.gz
monitors.lv2-36a2b9b94f845675756d8561f057c0cb738f0ad3.tar.bz2
monitors.lv2-36a2b9b94f845675756d8561f057c0cb738f0ad3.tar.xz
increase max midi notes per key to 512.
-rw-r--r--VERSION2
-rw-r--r--monitors.ttl.in3
-rw-r--r--monitors_midi_pianoroll.c13
3 files changed, 13 insertions, 5 deletions
diff --git a/VERSION b/VERSION
index f9a70ce..86b96a4 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-0.1.235
+0.1.253
diff --git a/monitors.ttl.in b/monitors.ttl.in
index 6f617d5..e28a406 100644
--- a/monitors.ttl.in
+++ b/monitors.ttl.in
@@ -45,6 +45,9 @@ idisp:queue_draw
idisp:interface
a lv2:ExtensionData .
+ui:updateRate
+ a opts:Option .
+
# Maintainer
omk:me
a foaf:Person ;
diff --git a/monitors_midi_pianoroll.c b/monitors_midi_pianoroll.c
index 0df1f85..04cd841 100644
--- a/monitors_midi_pianoroll.c
+++ b/monitors_midi_pianoroll.c
@@ -32,7 +32,7 @@
#define MAX_GRAPH 0x20000 //FIXME actually measure this
#define MAX_NPROPS 7
#define MAX_KEYS 0x80
-#define MAX_NOTES 0x80
+#define MAX_NOTES 0x200
#define MAX_VELOCITY 0x80
#define MASK_KEYS (MAX_KEYS - 1)
#define MASK_NOTES (MAX_NOTES - 1)
@@ -434,7 +434,8 @@ instantiate(const LV2_Descriptor* descriptor, double rate,
lv2_canvas_idisp_init(&handle->idisp, queue_draw, handle->map);
#endif
- handle->midi_MidiEvent = handle->map->map(handle->map->handle, LV2_MIDI__MidiEvent);
+ handle->midi_MidiEvent = handle->map->map(handle->map->handle,
+ LV2_MIDI__MidiEvent);
const LV2_URID ui_update_rate= handle->map->map(handle->map->handle,
LV2_UI__updateRate);
@@ -446,8 +447,11 @@ instantiate(const LV2_Descriptor* descriptor, double rate,
opt && (opt->key != 0) && (opt->value != NULL);
opt++)
{
- if( (opt->key == ui_update_rate) && (opt->type == handle->notify.forge.Float) )
+ if( (opt->key == ui_update_rate)
+ && (opt->type == handle->notify.forge.Float) )
+ {
handle->update_rate = *(float*)opt->value;
+ }
}
handle->spf = handle->sample_rate / handle->update_rate;
@@ -595,7 +599,8 @@ run(LV2_Handle instance, uint32_t nsamples)
{
const LV2_Atom_Object *obj = (const LV2_Atom_Object *)atom;
- props_advance(&handle->props, &handle->notify.forge, ev->time.frames, obj, &handle->notify.ref);
+ props_advance(&handle->props, &handle->notify.forge, ev->time.frames, obj,
+ &handle->notify.ref);
}
const int64_t to = ev->time.frames;