From a5086307f34fa1ad581b511e7323e70d782e09c9 Mon Sep 17 00:00:00 2001 From: jberg Date: Tue, 16 Jun 2020 22:03:16 -0700 Subject: [PATCH] fix custom waveform additive/dots/thick --- src/equations/presetEquationRunnerWASM.js | 3 --- src/rendering/waves/customWaveform.js | 10 +++++----- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/src/equations/presetEquationRunnerWASM.js b/src/equations/presetEquationRunnerWASM.js index 8e2aed5..f0bebc3 100644 --- a/src/equations/presetEquationRunnerWASM.js +++ b/src/equations/presetEquationRunnerWASM.js @@ -177,9 +177,6 @@ export default class PresetEquationRunnerWASM { 'scaling', 'spectrum', 'smoothing', - 'usedots', - 'thick', - 'additive', 'r', 'g', 'b', diff --git a/src/rendering/waves/customWaveform.js b/src/rendering/waves/customWaveform.js index 45e3f61..950c6f0 100644 --- a/src/rendering/waves/customWaveform.js +++ b/src/rendering/waves/customWaveform.js @@ -110,13 +110,13 @@ export default class CustomWaveform { } this.samples = Math.floor(this.samples); + const baseVals = presetEquationRunner.preset.waves[this.index].baseVals; + const sep = Math.floor(mdVSWaveFrame.sep); const scaling = mdVSWaveFrame.scaling; const spectrum = mdVSWaveFrame.spectrum; const smoothing = mdVSWaveFrame.smoothing; - const additive = mdVSWaveFrame.additive; - const usedots = mdVSWaveFrame.usedots; - const thick = mdVSWaveFrame.thick; + const usedots = baseVals.usedots; const frameR = mdVSWaveFrame.r; const frameG = mdVSWaveFrame.g; @@ -203,8 +203,8 @@ export default class CustomWaveform { presetEquationRunner.mdVSFrameMapWaves[this.index] = mdVSNewFrameMapWave; } else { mdVSWaveFrame.usedots = usedots; - mdVSWaveFrame.thick = thick; - mdVSWaveFrame.additive = additive; + mdVSWaveFrame.thick = baseVals.thick; + mdVSWaveFrame.additive = baseVals.additive; } this.mdVSWaveFrame = mdVSWaveFrame;