hq9000 / cython-vst-loader

a cython-based loader for VST audio plugins proving a clean python object-oriented interface
MIT License
39 stars 2 forks source link

MIDI Note Duration #18

Open nyckmaia opened 2 years ago

nyckmaia commented 2 years ago

Hi, I would like to write and play a simple melody from Python through my VST plugin and get back the rendered output audio as a float array.

So, how can I create an VstNoteOnMidiEvent array where each element have a time duration? Exemple:

event1 = VstNoteOnMidiEvent(3, 60, 100, 1)
event2 = ...

melody = [event1, event2, event3, ...]

# Where each 'event' have a time duration
"C4": 60 - 1.0 seconds
"D4": 62 - 0.5 seconds
...

Thanks,