BASS.NET API for the Un4seen BASS Audio Library

BassVstBASS_VST_ProcessEventRaw Method (Int32, MidiSysExMessage)

BASS.NET API for the Un4seen BASS Audio Library
Sends a MIDI system exclusive message to the VSTi plugin.

Namespace:  Un4seen.Bass.AddOn.Vst
Assembly:  Bass.Net (in Bass.Net.dll) Version: 2.4.17.5
Syntax

public static bool BASS_VST_ProcessEventRaw(
	int vstHandle,
	MidiSysExMessage msg
)

Parameters

vstHandle
Type: SystemInt32
The VSTi channel to send a MIDI message to (as created by BASS_VST_ChannelCreate(Int32, Int32, String, BASSFlag)).
msg
Type: radio42.Multimedia.MidiMidiSysExMessage
The already constructed MIDI system exclusive message to send.

Return Value

Type: Boolean
If successful, is returned, else is returned. Use BASS_ErrorGetCode to get the error code.
Remarks

Do NOT prepare the message with Prepare!
Examples

using Un4seen.Bass.AddOn.Vst;
using Un4seen.Bass.AddOn.Midi;

int vstHandle = BassVst.BASS_VST_ChannelCreate(44100, 2, "yourVSTi.dll", BASSFlag.BASS_DEFAULT);
Bass.BASS_ChannelPlay(vstHandle);

// create a new system-exclusive message
MidiSysExMessage sysex = new MidiSysExMessage(false, IntPtr.Zero);
// message will be 8 byte (incl. SoX and EoX)
sysex.CreateBuffer(8);
// write start-of-system-exclusive
sysex.MessageWriteSoX();
int offset = 1;
// write 6 more bytes...
sysex.MessageWrite8(ref offset, 65);
sysex.MessageWrite16(ref offset, 1023);
sysex.MessageWrite16(ref offset, 13);
sysex.MessageWrite8(ref offset, 1);
// write end-of-system-exusive
sysex.MessageWriteEoX();

BassVst.BASS_VST_ProcessEvent(vstHandle, sysex);
See Also

Reference