The most reliable and widely available implementation for pitch tracking right now is inside Aubio, which includes a number of algorithms (monophonic only - no chords!). (Rakarrack also does it, for the record.)
Right now aubio can automatically convert guitar signals to MIDI Note On messages via
Code: Select all
This can be optimized both in terms of latency and precision (a bit of a trade-off, isn't it ) by filtering the input signal and picking the right tracking algorithm.
But notes generated by aubionotes are discrete. The guitar is not a discrete instrument, you can bend notes. So, it would be better to use something different than other than aubionotes.
Thankfully, aubio provides aubiopitch, a proper pitch tracker which outputs the frequency in Hz. The problem I've found with this one is that it doesn't send any data on the MIDI out channel (I connected it to QMidiRoute to verify), when it would be enough to send this frequency as a SysEx message and let some other program do the conversion to a Note On (nearest pitch) + Pitch bend event (MIDI also has a way to do microtonality, which would be a better solution, but many synths don't support it, while pitch bend is pretty much universal. And OSC would make it even easier, but not many synth support it, sadly).
Another useful thing to do would be map the amplitude of guitar signals to MIDI velocities, to have more dynamics.
Someone wants to come in and share their experiences, or give some suggestions as to how to make this straightforward? I've thought about using Pure Data to make a program which does all but the pd-aubio packages sadly segfaults on my system.