@newgameplusinc/odyssey-audio-video-sdk-dev 1.0.21 → 1.0.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -8
- package/dist/SpatialAudioManager.js +16 -16
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -91,20 +91,20 @@ These layers run entirely in Web Audio, so you can ship “AirPods-style” back
|
|
|
91
91
|
```ts
|
|
92
92
|
const sdk = new OdysseySpatialComms(serverUrl, {
|
|
93
93
|
denoiser: {
|
|
94
|
-
threshold: 0.
|
|
95
|
-
maxReduction: 0.
|
|
96
|
-
hissCut: 0.
|
|
97
|
-
holdMs:
|
|
94
|
+
threshold: 0.0082,
|
|
95
|
+
maxReduction: 0.85,
|
|
96
|
+
hissCut: 0.5,
|
|
97
|
+
holdMs: 190,
|
|
98
98
|
voiceBoost: 0.7,
|
|
99
99
|
voiceSensitivity: 0.3,
|
|
100
100
|
voiceEnhancement: true,
|
|
101
|
-
silenceFloor: 0.
|
|
102
|
-
silenceHoldMs:
|
|
103
|
-
silenceReleaseMs:
|
|
101
|
+
silenceFloor: 0.0006,
|
|
102
|
+
silenceHoldMs: 420,
|
|
103
|
+
silenceReleaseMs: 260,
|
|
104
104
|
},
|
|
105
105
|
});
|
|
106
106
|
```
|
|
107
|
-
Voice enhancement (autocorrelation-based speech detection) is **off by default** to keep the gate extra quiet; enable it when you want brighter close-talk voicing.
|
|
107
|
+
Voice enhancement (autocorrelation-based speech detection) is **off by default** to keep the gate extra quiet; enable it when you want brighter close-talk voicing. Pair this with the new, gentler proximity curve to keep far-away participants airy instead of “all in one room.”
|
|
108
108
|
|
|
109
109
|
#### How Spatial Audio Is Built
|
|
110
110
|
1. **Telemetry ingestion** – each LSD packet is passed through `setListenerFromLSD(listenerPos, cameraPos, lookAtPos)` so the Web Audio listener matches the player’s real head/camera pose.
|
|
@@ -510,8 +510,8 @@ class SpatialAudioManager extends EventManager_1.EventManager {
|
|
|
510
510
|
return;
|
|
511
511
|
}
|
|
512
512
|
const clarityScore = this.calculateClarityScore(distance, vectorToSource);
|
|
513
|
-
const targetGain = 0.
|
|
514
|
-
const targetLowpass =
|
|
513
|
+
const targetGain = 0.48 + clarityScore * 0.72; // 0.48 → 1.20
|
|
514
|
+
const targetLowpass = 3600 + clarityScore * 4600; // 3.6kHz → ~8.2kHz
|
|
515
515
|
nodes.proximityGain.gain.setTargetAtTime(targetGain, this.audioContext.currentTime, 0.08);
|
|
516
516
|
nodes.dynamicLowpass.frequency.setTargetAtTime(targetLowpass, this.audioContext.currentTime, 0.12);
|
|
517
517
|
if (Math.random() < 0.005) {
|
|
@@ -530,8 +530,8 @@ class SpatialAudioManager extends EventManager_1.EventManager {
|
|
|
530
530
|
return this.clamp(0.2 + proximityWeight * 0.6 + focusWeight * 0.2, 0, 1);
|
|
531
531
|
}
|
|
532
532
|
calculateProximityWeight(distance) {
|
|
533
|
-
const closeRange =
|
|
534
|
-
const fadeRange =
|
|
533
|
+
const closeRange = 0.85;
|
|
534
|
+
const fadeRange = 18;
|
|
535
535
|
if (distance <= closeRange) {
|
|
536
536
|
return 1;
|
|
537
537
|
}
|
|
@@ -845,21 +845,21 @@ registerProcessor('odyssey-denoise', OdysseyDenoiseProcessor);
|
|
|
845
845
|
};
|
|
846
846
|
const denoiserDefaults = {
|
|
847
847
|
enabled: true,
|
|
848
|
-
threshold: 0.
|
|
849
|
-
noiseFloor: 0.
|
|
850
|
-
release: 0.
|
|
851
|
-
attack: 0.
|
|
852
|
-
holdMs:
|
|
853
|
-
maxReduction: 0.
|
|
854
|
-
hissCut: 0.
|
|
855
|
-
expansionRatio: 2.
|
|
856
|
-
learnRate: 0.
|
|
848
|
+
threshold: 0.0082,
|
|
849
|
+
noiseFloor: 0.0022,
|
|
850
|
+
release: 0.28,
|
|
851
|
+
attack: 0.32,
|
|
852
|
+
holdMs: 190,
|
|
853
|
+
maxReduction: 0.85,
|
|
854
|
+
hissCut: 0.5,
|
|
855
|
+
expansionRatio: 2.1,
|
|
856
|
+
learnRate: 0.05,
|
|
857
857
|
voiceBoost: 0.6,
|
|
858
858
|
voiceSensitivity: 0.35,
|
|
859
859
|
voiceEnhancement: false,
|
|
860
|
-
silenceFloor: 0.
|
|
861
|
-
silenceHoldMs:
|
|
862
|
-
silenceReleaseMs:
|
|
860
|
+
silenceFloor: 0.0006,
|
|
861
|
+
silenceHoldMs: 420,
|
|
862
|
+
silenceReleaseMs: 260,
|
|
863
863
|
};
|
|
864
864
|
return {
|
|
865
865
|
distance: {
|
package/package.json
CHANGED