MidiDevices.EventReadRaw method |
|
Remarks
Obtains data of a raw MIDI event reported by the MidiDevicesEventReceived event. The size of the buffer containing raw data of the MIDI event, the unique identifier of the input MIDI device which generated the event and the related time stamp can be obtained through a call to the MidiDevices.EventReadRawInfoGet method.
For further details about the use of MIDI devices see the MidiDevices object section and the How to manage MIDI devices tutorial.
Syntax
[Visual Basic] control.MidiDevices.EventReadRaw ( nEventUniqueId as Integer, pBuffer as Variant, nBufferLen as Long ) as enumDjcErrorCodes |
[C++] short control.MidiDevices.EventReadRaw ( short nEventUniqueId, const VARIANT FAR& pBuffer, long nBufferLen ); |
Parameter |
Description |
|
|
nEventUniqueId |
The unique identifier of the MIDI event reported by the MidiDevicesEventReceived event. After calling this method the event is internally deleted from the queue of MIDI events so this unique identifier becomes automatically invalid. |
pBuffer |
Variant parameter containing the pointer to the buffer that, on return from the method call, will contain raw data of the MIDI event. |
nBufferLen |
The size in bytes of the buffer to fill . The size of the buffer can be obtained through a call to the MidiDevices.EventReadRawInfoGet method. |
Return value
Value |
Meaning |
|
|
Negative value |
An error occurred, check the LastError property value in order to get the error code |
enumErrorCodes.ERR_NOERROR (0) |
The method call was successful |