Fix Shift+M mono mode for radio station panning

This commit is contained in:
Jage9
2026-02-21 17:23:54 -05:00
parent 3027ea04b9
commit 5ea3d633b1

View File

@@ -215,7 +215,7 @@ export class RadioStationRuntime {
}
output.gain.gain.linearRampToValueAtTime(gainValue * normalizedVolume, audioCtx.currentTime + 0.1);
if (output.panner) {
const resolvedPan = Math.max(-1, Math.min(1, panValue));
const resolvedPan = this.audio.getOutputMode() === 'mono' ? 0 : Math.max(-1, Math.min(1, panValue));
output.panner.pan.linearRampToValueAtTime(resolvedPan, audioCtx.currentTime + 0.1);
}
}