Gapless playback, crossfade and volume levelling

- Two-deck player keeps the next song loaded and buffered, and blends it in 20 ms
  before the current one ends, so albums and playlists play without gaps
- Skipping to the next song uses the preloaded deck, so it starts instantly
- Optional crossfade (up to 12 s); songs from the same album stay gapless
- Optional volume levelling: uses ReplayGain tags or measures each song once
  (-14 LUFS, capped so boosts never clip); files are never changed
- Playback section at the top of Settings
This commit is contained in:
Christian
2026-11-18 22:25:12 -05:00
parent f6db780bca
commit 93db117243
9 changed files with 371 additions and 31 deletions
+1 -1
View File
@@ -99,7 +99,7 @@ function bindConnect() {
window.addEventListener("player", (e) => {
if (e.detail.type !== "time") apiPublishSoon();
});
Player.audio.addEventListener("seeked", apiPublishSoon);
Player.on("seeked", apiPublishSoon);
Connect.beat = setInterval(() => {
if (!Player.audio.paused) apiPublishSoon();
}, 10000);