melhorando a leitura de projetos no mmpCreator
Deploy / Deploy (push) Successful in 2m8s
Details
Deploy / Deploy (push) Successful in 2m8s
Details
This commit is contained in:
parent
acfebc8f8b
commit
73a61a96f4
|
|
@ -250,8 +250,27 @@ function _animationLoop() {
|
|||
const loopDuration = loopEndTimeSec - loopStartTimeSec;
|
||||
newLogicalTime =
|
||||
loopStartTimeSec + ((newLogicalTime - loopStartTimeSec) % loopDuration);
|
||||
|
||||
startTime = now;
|
||||
appState.audio.audioEditorSeekTime = newLogicalTime;
|
||||
|
||||
// ✅ 1) manter o Tone.Transport em sincronia
|
||||
try { Tone.Transport.seconds = newLogicalTime; } catch {}
|
||||
|
||||
// ✅ 2) permitir reagendamento de clips/patterns
|
||||
runtimeClipState.clear();
|
||||
scheduledNodes.forEach(({ player }) => {
|
||||
try { player.unsync(); } catch {}
|
||||
try { player.stop(); } catch {}
|
||||
try { player.dispose(); } catch {}
|
||||
});
|
||||
scheduledNodes.clear();
|
||||
|
||||
// ✅ 3) reinicia patterns no Transport (se houver scheduleOnce para notes)
|
||||
try {
|
||||
stopSongPatternPlaybackOnTransport();
|
||||
startSongPatternPlaybackOnTransport();
|
||||
} catch {}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue