removed shitty spatial
This commit is contained in:
parent
2873efcd62
commit
07f2b3f1a3
2 changed files with 123 additions and 155 deletions
|
@ -50,7 +50,7 @@ const CiderAudio = {
|
|||
},
|
||||
connectContext: function (mediaElem) {
|
||||
if (!CiderAudio.context) {
|
||||
CiderAudio.context = new window.AudioContext({sampleRate: 96000}); // Don't ever remove the sample rate arg. Ask Maikiwi.
|
||||
CiderAudio.context = new window.AudioContext({ sampleRate: 96000 }); // Don't ever remove the sample rate arg. Ask Maikiwi.
|
||||
}
|
||||
if (!CiderAudio.source) {
|
||||
CiderAudio.source = CiderAudio.context.createMediaElementSource(mediaElem);
|
||||
|
@ -62,7 +62,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.normalization) {
|
||||
CiderAudio.normalizerOn()
|
||||
}
|
||||
if (app.cfg.audio.spatial) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial) {
|
||||
CiderAudio.spatialOn()
|
||||
}
|
||||
CiderAudio.hierarchical_loading();
|
||||
|
@ -127,57 +127,35 @@ const CiderAudio = {
|
|||
],
|
||||
spatialOn: function () {
|
||||
CiderAudio.audioNodes.spatialNode = null;
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
CiderAudio.audioNodes.spatialNode = CiderAudio.context.createConvolver();
|
||||
CiderAudio.audioNodes.spatialNode.normalize = false;
|
||||
CiderAudio.audioNodes.spatialNode = CiderAudio.context.createConvolver();
|
||||
CiderAudio.audioNodes.spatialNode.normalize = false;
|
||||
|
||||
let spatialProfile = CiderAudio.spatialProfiles.find(function (profile) {
|
||||
return profile.id === app.cfg.audio.maikiwiAudio.spatialProfile;
|
||||
});
|
||||
|
||||
if (spatialProfile === undefined) {
|
||||
spatialProfile = CiderAudio.spatialProfiles[0];
|
||||
}
|
||||
fetch(spatialProfile.file).then(async (impulseData) => {
|
||||
let bufferedImpulse = await impulseData.arrayBuffer();
|
||||
CiderAudio.audioNodes.spatialNode.buffer = await CiderAudio.context.decodeAudioData(bufferedImpulse);
|
||||
});
|
||||
let spatialProfile = CiderAudio.spatialProfiles.find(function (profile) {
|
||||
return profile.id === app.cfg.audio.maikiwiAudio.spatialProfile;
|
||||
});
|
||||
|
||||
if (spatialProfile === undefined) {
|
||||
spatialProfile = CiderAudio.spatialProfiles[0];
|
||||
}
|
||||
else {
|
||||
CiderAudio.audioNodes.spatialNode = new ResonanceAudio(CiderAudio.context);
|
||||
let roomDimensions = {
|
||||
width: 32,
|
||||
height: 12,
|
||||
depth: 32,
|
||||
};
|
||||
let roomMaterials = {
|
||||
// Room wall materials
|
||||
left: 'metal',
|
||||
right: 'metal',
|
||||
front: 'brick-bare',
|
||||
back: 'brick-bare',
|
||||
down: 'acoustic-ceiling-tiles',
|
||||
up: 'acoustic-ceiling-tiles',
|
||||
};
|
||||
CiderAudio.audioNodes.spatialNode.setRoomProperties(roomDimensions, roomMaterials);
|
||||
CiderAudio.audioNodes.spatialInput = CiderAudio.audioNodes.spatialNode.createSource();
|
||||
}
|
||||
fetch(spatialProfile.file).then(async (impulseData) => {
|
||||
let bufferedImpulse = await impulseData.arrayBuffer();
|
||||
CiderAudio.audioNodes.spatialNode.buffer = await CiderAudio.context.decodeAudioData(bufferedImpulse);
|
||||
});
|
||||
},
|
||||
spatialOff: function () {
|
||||
CiderAudio.hierarchical_loading();
|
||||
},
|
||||
intelliGainComp_h0_0: function () {
|
||||
let filters = []; const precisionHz = 12;
|
||||
if (CiderAudio.audioNodes.audioBands !== null) {filters = filters.concat(CiderAudio.audioNodes.audioBands)}
|
||||
if (CiderAudio.audioNodes.vibrantbassNode !== null) {filters = filters.concat(CiderAudio.audioNodes.vibrantbassNode)}
|
||||
if (CiderAudio.audioNodes.llpw !== null && CiderAudio.audioNodes.llpw.length > 1) {filters = filters.concat(CiderAudio.audioNodes.llpw);}
|
||||
if (CiderAudio.audioNodes.analogWarmth !== null) {filters = filters.concat(CiderAudio.audioNodes.analogWarmth)}
|
||||
if (CiderAudio.audioNodes.audioBands !== null) { filters = filters.concat(CiderAudio.audioNodes.audioBands) }
|
||||
if (CiderAudio.audioNodes.vibrantbassNode !== null) { filters = filters.concat(CiderAudio.audioNodes.vibrantbassNode) }
|
||||
if (CiderAudio.audioNodes.llpw !== null && CiderAudio.audioNodes.llpw.length > 1) { filters = filters.concat(CiderAudio.audioNodes.llpw); }
|
||||
if (CiderAudio.audioNodes.analogWarmth !== null) { filters = filters.concat(CiderAudio.audioNodes.analogWarmth) }
|
||||
|
||||
if (!filters || filters.length === 0) {
|
||||
let filterlessGain = 1;
|
||||
if (CiderAudio.audioNodes.llpw !== null && CiderAudio.audioNodes.llpw.length == 1) {filterlessGain = filterlessGain * 1.109174815262401}
|
||||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer == true) {filterlessGain = filterlessGain * 1.096478196143185}
|
||||
if (CiderAudio.audioNodes.llpw !== null && CiderAudio.audioNodes.llpw.length == 1) { filterlessGain = filterlessGain * 1.109174815262401 }
|
||||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer == true) { filterlessGain = filterlessGain * 1.096478196143185 }
|
||||
if (app.cfg.audio.maikiwiAudio.spatial == true) {
|
||||
let spatialProfile = CiderAudio.spatialProfiles.find(function (profile) {
|
||||
return profile.id === app.cfg.audio.maikiwiAudio.spatialProfile;
|
||||
|
@ -185,9 +163,10 @@ const CiderAudio = {
|
|||
if (spatialProfile === undefined) {
|
||||
spatialProfile = CiderAudio.spatialProfiles[0];
|
||||
}
|
||||
filterlessGain = filterlessGain * spatialProfile.gainComp}
|
||||
filterlessGain = Math.pow(10, (-1 * (20 * Math.log10(filterlessGain))) / 20).toFixed(4);
|
||||
filterlessGain > 1.0 ? CiderAudio.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(1.0, CiderAudio.context.currentTime + 0.3) : CiderAudio.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(filterlessGain, CiderAudio.context.currentTime + 0.3);
|
||||
filterlessGain = filterlessGain * spatialProfile.gainComp
|
||||
}
|
||||
filterlessGain = Math.pow(10, (-1 * (20 * Math.log10(filterlessGain))) / 20).toFixed(4);
|
||||
filterlessGain > 1.0 ? CiderAudio.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(1.0, CiderAudio.context.currentTime + 0.3) : CiderAudio.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(filterlessGain, CiderAudio.context.currentTime + 0.3);
|
||||
console.debug(`[Cider][Audio] IntelliGainComp: ${filterlessGain > 1.0 ? 0 : (20 * Math.log10(filterlessGain)).toFixed(2)} dB (${filterlessGain > 1.0 ? 1 : filterlessGain})`)
|
||||
return;
|
||||
}
|
||||
|
@ -221,8 +200,8 @@ const CiderAudio = {
|
|||
if (gain > maxGain)
|
||||
maxGain = gain;
|
||||
}
|
||||
if (CiderAudio.audioNodes.llpw !== null && CiderAudio.audioNodes.llpw.length == 1) {maxGain = maxGain * 1.109174815262401}
|
||||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer == true) {maxGain = maxGain * 1.096478196143185}
|
||||
if (CiderAudio.audioNodes.llpw !== null && CiderAudio.audioNodes.llpw.length == 1) { maxGain = maxGain * 1.109174815262401 }
|
||||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer == true) { maxGain = maxGain * 1.096478196143185 }
|
||||
if (app.cfg.audio.maikiwiAudio.spatial == true) {
|
||||
let spatialProfile = CiderAudio.spatialProfiles.find(function (profile) {
|
||||
return profile.id === app.cfg.audio.maikiwiAudio.spatialProfile;
|
||||
|
@ -230,7 +209,8 @@ const CiderAudio = {
|
|||
if (spatialProfile === undefined) {
|
||||
spatialProfile = CiderAudio.spatialProfiles[0];
|
||||
}
|
||||
maxGain = maxGain * spatialProfile.gainComp}
|
||||
maxGain = maxGain * spatialProfile.gainComp
|
||||
}
|
||||
maxGain = Math.pow(10, (-1 * (20 * Math.log10(maxGain))) / 20).toFixed(4);
|
||||
maxGain > 1.0 ? CiderAudio.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(1.0, CiderAudio.context.currentTime + 0.3) : CiderAudio.audioNodes.intelliGainComp.gain.exponentialRampToValueAtTime(maxGain, CiderAudio.context.currentTime + 0.3);
|
||||
console.debug(`[Cider][Audio] IntelliGainComp: ${maxGain > 1.0 ? 0 : (20 * Math.log10(maxGain)).toFixed(2)} dB (${maxGain > 1.0 ? 1 : maxGain})`);
|
||||
|
@ -376,7 +356,7 @@ const CiderAudio = {
|
|||
}
|
||||
}
|
||||
CiderAudio.audioNodes.recorderNode.parameters.get('isRecording').setValueAtTime(1, CiderAudio.context.currentTime);
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.recorderNode);
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.recorderNode);
|
||||
|
||||
});
|
||||
clearInterval(searchInt);
|
||||
|
@ -455,9 +435,9 @@ const CiderAudio = {
|
|||
|
||||
switch (hierarchy) {
|
||||
case 4:
|
||||
try{
|
||||
CiderAudio.audioNodes.atmosphereRealizer.connect(CiderAudio.audioNodes.analogWarmth[0]);
|
||||
} catch (e) {}
|
||||
try {
|
||||
CiderAudio.audioNodes.atmosphereRealizer.connect(CiderAudio.audioNodes.analogWarmth[0]);
|
||||
} catch (e) { }
|
||||
break;
|
||||
case 3:
|
||||
try {
|
||||
|
@ -494,7 +474,7 @@ const CiderAudio = {
|
|||
for (let i = 0; i < WARMTH_FREQUENCIES.length; i++) {
|
||||
CiderAudio.audioNodes.analogWarmth[i] = CiderAudio.context.createBiquadFilter();
|
||||
CiderAudio.audioNodes.analogWarmth[i].type = 'peaking'; // 'peaking';
|
||||
CiderAudio.audioNodes.analogWarmth[i].frequency.value = WARMTH_FREQUENCIES[i] ;
|
||||
CiderAudio.audioNodes.analogWarmth[i].frequency.value = WARMTH_FREQUENCIES[i];
|
||||
CiderAudio.audioNodes.analogWarmth[i].Q.value = WARMTH_Q[i];
|
||||
CiderAudio.audioNodes.analogWarmth[i].gain.value = WARMTH_GAIN[i] * 1.25;
|
||||
}
|
||||
|
@ -504,7 +484,7 @@ const CiderAudio = {
|
|||
for (let i = 0; i < WARMTH_FREQUENCIES.length; i++) {
|
||||
CiderAudio.audioNodes.analogWarmth[i] = CiderAudio.context.createBiquadFilter();
|
||||
CiderAudio.audioNodes.analogWarmth[i].type = 'peaking'; // 'peaking';
|
||||
CiderAudio.audioNodes.analogWarmth[i].frequency.value = WARMTH_FREQUENCIES[i] ;
|
||||
CiderAudio.audioNodes.analogWarmth[i].frequency.value = WARMTH_FREQUENCIES[i];
|
||||
CiderAudio.audioNodes.analogWarmth[i].Q.value = WARMTH_Q[i];
|
||||
CiderAudio.audioNodes.analogWarmth[i].gain.value = WARMTH_GAIN[i] * 1.75;
|
||||
}
|
||||
|
@ -514,7 +494,7 @@ const CiderAudio = {
|
|||
for (let i = 0; i < WARMTH_FREQUENCIES.length; i++) {
|
||||
CiderAudio.audioNodes.analogWarmth[i] = CiderAudio.context.createBiquadFilter();
|
||||
CiderAudio.audioNodes.analogWarmth[i].type = 'peaking'; // 'peaking';
|
||||
CiderAudio.audioNodes.analogWarmth[i].frequency.value = WARMTH_FREQUENCIES[i] ;
|
||||
CiderAudio.audioNodes.analogWarmth[i].frequency.value = WARMTH_FREQUENCIES[i];
|
||||
CiderAudio.audioNodes.analogWarmth[i].Q.value = WARMTH_Q[i];
|
||||
CiderAudio.audioNodes.analogWarmth[i].gain.value = WARMTH_GAIN[i] * 1.25;
|
||||
}
|
||||
|
@ -614,7 +594,7 @@ const CiderAudio = {
|
|||
for (let i = 0; i < c_LLPW_FREQUENCIES.length; i++) {
|
||||
CiderAudio.audioNodes.llpw[i] = CiderAudio.context.createBiquadFilter();
|
||||
CiderAudio.audioNodes.llpw[i].type = 'peaking'; // 'peaking';
|
||||
CiderAudio.audioNodes.llpw[i].frequency.value = c_LLPW_FREQUENCIES[i] ;
|
||||
CiderAudio.audioNodes.llpw[i].frequency.value = c_LLPW_FREQUENCIES[i];
|
||||
CiderAudio.audioNodes.llpw[i].Q.value = c_LLPW_Q[i];
|
||||
CiderAudio.audioNodes.llpw[i].gain.value = c_LLPW_GAIN[i];
|
||||
}
|
||||
|
@ -675,7 +655,7 @@ const CiderAudio = {
|
|||
for (let i = 0; i < VIBRANTBASSBANDS.length; i++) {
|
||||
CiderAudio.audioNodes.vibrantbassNode[i] = CiderAudio.context.createBiquadFilter();
|
||||
CiderAudio.audioNodes.vibrantbassNode[i].type = 'peaking'; // 'peaking';
|
||||
CiderAudio.audioNodes.vibrantbassNode[i].frequency.value = VIBRANTBASSBANDS[i] ;
|
||||
CiderAudio.audioNodes.vibrantbassNode[i].frequency.value = VIBRANTBASSBANDS[i];
|
||||
CiderAudio.audioNodes.vibrantbassNode[i].Q.value = VIBRANTBASSQ[i];
|
||||
CiderAudio.audioNodes.vibrantbassNode[i].gain.value = VIBRANTBASSGAIN[i] * (app.cfg.audio.equalizer.vibrantBass / 10);
|
||||
}
|
||||
|
@ -728,7 +708,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 4);
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) { // Vibrant Bass, CAP, Analog Warmth, Maikiwi Spatial
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -750,7 +730,7 @@ const CiderAudio = {
|
|||
}
|
||||
|
||||
else {
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) { // Vibrant Bass, CAP, Analog Warmth, Maikiwi Spatial
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -775,7 +755,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 3)
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -796,7 +776,7 @@ const CiderAudio = {
|
|||
}
|
||||
}
|
||||
else {
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -825,7 +805,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 4)
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -847,7 +827,7 @@ const CiderAudio = {
|
|||
}
|
||||
|
||||
else {
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -871,7 +851,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 2)
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -893,7 +873,7 @@ const CiderAudio = {
|
|||
}
|
||||
|
||||
else {
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -927,7 +907,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 4);
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -950,7 +930,7 @@ const CiderAudio = {
|
|||
|
||||
else {
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -975,7 +955,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 3);
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -997,7 +977,7 @@ const CiderAudio = {
|
|||
}
|
||||
|
||||
else {
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1026,7 +1006,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 4);
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1048,7 +1028,7 @@ const CiderAudio = {
|
|||
}
|
||||
|
||||
else {
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1072,7 +1052,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 1);
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1094,7 +1074,7 @@ const CiderAudio = {
|
|||
}
|
||||
|
||||
else {
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1130,7 +1110,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 4);
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) { // Vibrant Bass, CAP, Analog Warmth, Maikiwi Spatial
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1152,7 +1132,7 @@ const CiderAudio = {
|
|||
|
||||
}
|
||||
else {
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) { // Vibrant Bass, CAP, Analog Warmth, Maikiwi Spatial
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1177,7 +1157,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 3);
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1199,7 +1179,7 @@ const CiderAudio = {
|
|||
}
|
||||
|
||||
else {
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1218,7 +1198,7 @@ const CiderAudio = {
|
|||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.llpw[0]);
|
||||
console.debug('[Cider][Audio] Vibrant Bass, CAP')
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
@ -1228,7 +1208,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 4);
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true;
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1250,7 +1230,7 @@ const CiderAudio = {
|
|||
}
|
||||
|
||||
else {
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true;
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1276,7 +1256,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 2);
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true;
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1298,7 +1278,7 @@ const CiderAudio = {
|
|||
}
|
||||
|
||||
else {
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true;
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1331,7 +1311,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 4);
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true;
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1353,7 +1333,7 @@ const CiderAudio = {
|
|||
}
|
||||
|
||||
else {
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true;
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1378,7 +1358,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 3);
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true;
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1400,7 +1380,7 @@ const CiderAudio = {
|
|||
}
|
||||
|
||||
else {
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true;
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1429,7 +1409,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 4);
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true;
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1451,7 +1431,7 @@ const CiderAudio = {
|
|||
}
|
||||
|
||||
else {
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true;
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1476,7 +1456,7 @@ const CiderAudio = {
|
|||
if (app.cfg.audio.maikiwiAudio.atmosphereRealizer === true) {
|
||||
CiderAudio.atmosphereRealizer_h2_4(true, 0);
|
||||
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true;
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
@ -1497,7 +1477,7 @@ const CiderAudio = {
|
|||
}
|
||||
}
|
||||
else {
|
||||
if (app.cfg.audio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial === true) {
|
||||
app.cfg.audio.normalization = true;
|
||||
CiderAudio.audioNodes.gainNode.connect(CiderAudio.audioNodes.spatialNode);
|
||||
|
|
|
@ -104,18 +104,6 @@
|
|||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="md-option-line" v-show="app.cfg.advanced.AudioContext === true">
|
||||
<div class="md-option-segment">
|
||||
{{$root.getLz('settings.option.audio.enableAdvancedFunctionality.audioSpatialization')}}
|
||||
<br>
|
||||
<small>{{$root.getLz('settings.option.audio.enableAdvancedFunctionality.audioSpatialization.description')}}</small>
|
||||
</div>
|
||||
<div class="md-option-segment md-option-segment_auto">
|
||||
<input type="checkbox" v-model="app.cfg.audio.spatial"
|
||||
:disabled="app.cfg.audio.maikiwiAudio.spatial === true" v-on:change="toggleSpatial"
|
||||
switch/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="md-option-line" v-show="app.cfg.advanced.AudioContext === true">
|
||||
<div class="md-option-segment">
|
||||
{{$root.getLz('settings.option.audio.enableAdvancedFunctionality.tunedAudioSpatialization')}}
|
||||
|
@ -124,11 +112,11 @@
|
|||
</div>
|
||||
<div class="md-option-segment md-option-segment_auto">
|
||||
<input type="checkbox" v-model="app.cfg.audio.maikiwiAudio.spatial"
|
||||
:disabled="app.cfg.audio.spatial === false" v-on:change="toggleMaikiwiSpatial" switch/>
|
||||
v-on:change="toggleMaikiwiSpatial" switch/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="md-option-line"
|
||||
v-show="app.cfg.audio.maikiwiAudio.spatial === true && app.cfg.audio.spatial === true">
|
||||
v-show="app.cfg.audio.maikiwiAudio.spatial === true">
|
||||
<div class="md-option-segment">
|
||||
{{$root.getLz('settings.option.audio.enableAdvancedFunctionality.tunedAudioSpatialization.profile')}}
|
||||
<br>
|
||||
|
@ -142,7 +130,7 @@
|
|||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="spprofile-line" v-show="app.cfg.audio.maikiwiAudio.spatial === true && app.cfg.audio.spatial === true">
|
||||
<div class="spprofile-line" v-show="app.cfg.audio.maikiwiAudio.spatial === true">
|
||||
<div class="spprofile-viewport">
|
||||
<button class="spprev" @click="profilePrev"></button>
|
||||
<button class="nextprev" @click="profileNext"></button>
|
||||
|
@ -240,7 +228,7 @@
|
|||
this.toggleMaikiwiSpatial()
|
||||
},
|
||||
toggleSpatial: function () {
|
||||
if (app.cfg.audio.spatial) {
|
||||
if (app.cfg.audio.maikiwiAudio.spatial) {
|
||||
CiderAudio.spatialOn()
|
||||
CiderAudio.hierarchical_loading();
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue