From 13db5e923112b6c639dbbb011e8f30b1b9e94ee0 Mon Sep 17 00:00:00 2001 From: Lunar Journal Date: Tue, 7 Jan 2025 17:27:43 +0200 Subject: Update emu8910.js --- emu8910.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/emu8910.js b/emu8910.js index 005fd11..878289d 100644 --- a/emu8910.js +++ b/emu8910.js @@ -50,6 +50,7 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ const YM_CLOCK_ZX = 1750000; +const CUBIC_INTERPOL = 0.5; const FIR_CUTOFF = 2000; // Hz const FIR_TAPS = 200; // N taps var FIR = []; // coeff @@ -587,8 +588,8 @@ class PSG49 { interpolate[0].step(output[0]); interpolate[1].step(output[1]); } - sample_left[i] = interpolate[0].cubic(0.5); - sample_right[i] = interpolate[1].cubic(0.5); + sample_left[i] = interpolate[0].cubic(CUBIC_INTERPOL); + sample_right[i] = interpolate[1].cubic(CUBIC_INTERPOL); } output[0] = fir[0].step(sample_left); output[1] = fir[1].step(sample_right); -- cgit v1.2.3-70-g09d2