Search code examples
midixaudio2directmusic

Play a single note with DirectMusic


I'm using DirectMusic for MIDI playback in an application I'm developing. Does anyone know if it's possible to use DirectMusic to play individual notes? Currently, I'm converting an in-memory data structure that represents entire 'songs' into a MIDI buffer and playing it back through DirectMusic. I'd like to be able to play individual notes without having to generate a MIDI buffer for it, loading it and playing it. Is this type of thing even possible with DirectMusic?

This is my first excursion into the world of DirectMusic so hopefully I'm not too uninformed of it's capabilities...


Solution

  • I believe that stuffing your note messages into a DirectMusicBuffer8 and then playing that is indeed the simplest way to do it.

    I assume you're aware that DirectMusic is deprecated, not recommended for new development etc. etc.