|
Allocating and Preparing MIDI Data Blocks
The midiOutLongMsg, midiInAddBuffer, and midiStreamOut functions require that applications to allocate data blocks to pass to the
device drivers for playback or recording purposes. Each of these functions uses a MIDIHDR structure to describe its data block.
Before you use one of these functions to pass a data block to a device driver,
you must allocate memory for the buffer and the header structure that
describes the data block.
Windows provides the following functions for preparing and cleaning up MIDI
data blocks:
Before you pass a MIDI data block to a device driver, you must prepare the
buffer by passing it to the midiInPrepareHeader or midiOutPrepareHeader function. When the device driver is finished with the buffer and returns it,
you must clean up this preparation by passing the buffer to the midiInUnprepareHeader or midiOutUnprepareHeader function before any allocated memory can be freed.
Related Links
Software for Delphi and C++ Builder developers
Software for Visual Studio .NET developers
Software for Visual Basic 6 developers
Delphi Tips&Tricks
MegaDetailed.NET
TMS Scripter Studio Pro components for Delphi/C++Builder
More Online Helps
Win32 Programmer's Reference (win32.hlp)
OLE Programmer's Reference (ole.hlp)
Microsoft Windows Pen API Programmer's Reference (penapi.hlp)
Microsoft Windows Sockets 2 Reference (sock2.hlp)
Microsoft Windows Telephony API (TAPI) Programmer's Reference (tapi.hlp)
Unix Manual Pages
|