mirror of
https://github.com/tildearrow/furnace.git
synced 2024-12-03 09:47:26 +00:00
parent
9e093a20c1
commit
28bbe56a44
1 changed files with 10 additions and 0 deletions
|
@ -2751,6 +2751,16 @@ bool DivEngine::loadFTM(unsigned char* file, size_t len, bool dnft, bool dnft_si
|
|||
ds.sampleLen = ds.sample.size();
|
||||
ds.waveLen = ds.wave.size();
|
||||
|
||||
// check whether virtual tempo is inside range
|
||||
for (DivSubSong* i: ds.subsong) {
|
||||
while (i->virtualTempoD>255) {
|
||||
i->virtualTempoD>>=1;
|
||||
i->virtualTempoN>>=1;
|
||||
}
|
||||
if (i->virtualTempoN<1) i->virtualTempoN=1;
|
||||
if (i->virtualTempoD<1) i->virtualTempoD=1;
|
||||
}
|
||||
|
||||
if (active) quitDispatch();
|
||||
BUSY_BEGIN_SOFT;
|
||||
saveLock.lock();
|
||||
|
|
Loading…
Reference in a new issue