910 |
} |
} |
911 |
|
|
912 |
// reverse the sample frames for backward playback |
// reverse the sample frames for backward playback |
913 |
SwapMemoryArea(&pDst[swapareastart * this->FrameSize], (totalreadsamples - swapareastart) * this->FrameSize, this->FrameSize); |
if (totalreadsamples > swapareastart) //FIXME: this if() is just a crash workaround for now (#102), but totalreadsamples <= swapareastart should never be the case, so there's probably still a bug above! |
914 |
|
SwapMemoryArea(&pDst[swapareastart * this->FrameSize], (totalreadsamples - swapareastart) * this->FrameSize, this->FrameSize); |
915 |
} |
} |
916 |
} while (samplestoread && readsamples); |
} while (samplestoread && readsamples); |
917 |
break; |
break; |
3036 |
} |
} |
3037 |
|
|
3038 |
Instrument::~Instrument() { |
Instrument::~Instrument() { |
3039 |
|
for (int i = 0 ; pMidiRules[i] ; i++) { |
3040 |
|
delete pMidiRules[i]; |
3041 |
|
} |
3042 |
delete[] pMidiRules; |
delete[] pMidiRules; |
3043 |
} |
} |
3044 |
|
|