CInstrument


Purpose:
Keeps information of a specific high level DLS 1.0/2.0 instrument
Remark: The returns values are based on the DirectX9 constants except DM_FAILED
The functions raise a CDMusicException exception type with the error data.
Member functions:

Properties:

 

Function: SetPatch
Declaration: HRESULT CInstrument::SetPatch(DWORD dwdstPatchMidi)
Purpose:  Sets the destination midi program (patch) of the instrument in a wave-table synthesizer  
Parameters:    

Returns:  

S_OK

Succeeds

Throws:

DMUS_E_NOT_INIT A required object is not initialized or failed to initialize
DM_FAILED Error, see DirectMidi causes
DMUS_E_INVALIDPATCH No instrument in the collection matches the patch number

Function: SetNoteRange
Declaration: HRESULT CInstrument::SetNoteRange(DWORD dwLowNote,DWORD dwHighNote)
Purpose:  Sets the MIDI note range where the instrument must respond
Parameters:    

Returns:  void

Throws: none

Top    Index

Function: GetNoteRange
Declaration: HRESULT CInstrument::GetNoteRange(LPDWORD pdwLowNote, LPDWORD pdwHighNote)
Purpose:  Gets the MIDI note range where the instrument is respondonding
Parameters:    

Returns:  void

Throws: none

Top    Index