diff --git a/samples/list_midi_devices/list_midi_devices.cpp b/samples/list_midi_devices/list_midi_devices.cpp index 48b9e23..34e2e64 100644 --- a/samples/list_midi_devices/list_midi_devices.cpp +++ b/samples/list_midi_devices/list_midi_devices.cpp @@ -4,11 +4,23 @@ int main() { int count = 0; - const MidiOutDevice *devices = ZMusic_GetMidiDevices(&count); + const ZMusicMidiOutDevice *devices = ZMusic_GetMidiDevices(&count); for (int i = 0; i < count; ++i) { - printf("[%i] %s\n", i, devices[i].Name); + const ZMusicMidiOutDevice &d = devices[i]; + const char *tech = ""; + switch (d.Technology) + { + case MIDIDEV_MIDIPORT: tech = "MIDIPORT"; break; + case MIDIDEV_SYNTH: tech = "SYNTH"; break; + case MIDIDEV_SQSYNTH: tech = "SQSYNTH"; break; + case MIDIDEV_FMSYNTH: tech = "FMSYNTH"; break; + case MIDIDEV_MAPPER: tech = "MAPPER"; break; + case MIDIDEV_WAVETABLE: tech = "WAVETABLE"; break; + case MIDIDEV_SWSYNTH: tech = "SWSYNTH"; break; + } + printf("[%i] %i. %s: %s\n", i, d.ID, d.Name, tech); } return 0;