68 |
Pitch = 0; |
Pitch = 0; |
69 |
SustainPedal = false; |
SustainPedal = false; |
70 |
GlobalVolume = 1.0; |
GlobalVolume = 1.0; |
71 |
|
GlobalPanLeft = 1.0f; |
72 |
|
GlobalPanRight = 1.0f; |
73 |
CurrentKeyDimension = 0; |
CurrentKeyDimension = 0; |
74 |
|
|
75 |
// set all MIDI controller values to zero |
// set all MIDI controller values to zero |
236 |
if (pEngine) { // if clause to prevent disconnect loops |
if (pEngine) { // if clause to prevent disconnect loops |
237 |
ResetInternal(); |
ResetInternal(); |
238 |
for (uint i = 0; i < 128; i++) { |
for (uint i = 0; i < 128; i++) { |
239 |
if (pMIDIKeyInfo[i].pActiveVoices) delete pMIDIKeyInfo[i].pActiveVoices; |
if (pMIDIKeyInfo[i].pActiveVoices) { |
240 |
if (pMIDIKeyInfo[i].pEvents) delete pMIDIKeyInfo[i].pEvents; |
delete pMIDIKeyInfo[i].pActiveVoices; |
241 |
|
pMIDIKeyInfo[i].pActiveVoices = NULL; |
242 |
|
} |
243 |
|
if (pMIDIKeyInfo[i].pEvents) { |
244 |
|
delete pMIDIKeyInfo[i].pEvents; |
245 |
|
pMIDIKeyInfo[i].pEvents = NULL; |
246 |
|
} |
247 |
} |
} |
248 |
Engine* oldEngine = pEngine; |
Engine* oldEngine = pEngine; |
249 |
AudioOutputDevice* oldAudioDevice = pEngine->pAudioOutputDevice; |
AudioOutputDevice* oldAudioDevice = pEngine->pAudioOutputDevice; |