@audio/effect-exciter 1.1.3 → 1.1.4

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.
Files changed (3) hide show
  1. package/README.md +33 -0
  2. package/exciter.d.ts +17 -0
  3. package/package.json +6 -3
package/README.md ADDED
@@ -0,0 +1,33 @@
1
+ # @audio/effect-exciter [![npm](https://img.shields.io/npm/v/@audio/effect-exciter)](https://www.npmjs.com/package/@audio/effect-exciter) [![MIT](https://img.shields.io/badge/MIT-%E0%A5%90-white)](https://github.com/krishnized/license)
2
+
3
+ Exciter — psychoacoustic harmonic synthesis for presence/air
4
+
5
+ ```
6
+ npm install @audio/effect-exciter
7
+ ```
8
+
9
+ ```js
10
+ import exciter from '@audio/effect-exciter'
11
+ ```
12
+
13
+ Aphex-style aural exciter. Extracts the high band via SVF highpass, runs it through tanh saturation to synthesize harmonics, then mixes the harmonic residue back into the dry signal. Adds perceived "air" and "presence" without EQ boost.
14
+
15
+ **`freq`** highpass cutoff Hz (default 3000) · **`drive`** saturation amount 0–1 (default 0.5, maps to 1–10× gain) · **`amount`** mix-in level 0–1 (default 0.5) · **`fs`** sample rate
16
+
17
+ ```js
18
+ import { exciter } from '@audio/effect'
19
+
20
+ let p = { freq: 4000, drive: 0.6, amount: 0.4, fs: 44100 }
21
+ for (let buf of stream) exciter(buf, p)
22
+ ```
23
+
24
+ **Use when**: dull vocals, lifeless cymbals, mastering polish, restoring high-end after compression<br>
25
+ **Not for**: spectral shaping (use a shelf/EQ from `@audio/filter`) — exciter *adds* harmonics, not gain
26
+
27
+ <!-- ![Exciter](plot/exciter.svg) -->
28
+
29
+ ---
30
+
31
+ Part of [@audio/effect](https://github.com/audiojs/effect) — the effect family umbrella. This README is generated from the umbrella docs.
32
+
33
+ MIT © [audiojs](https://github.com/audiojs)
package/exciter.d.ts ADDED
@@ -0,0 +1,17 @@
1
+ /** Exciter — Aphex-style aural exciter; SVF highpass extracts the high band, tanh saturation synthesizes harmonics, mixed back into dry. */
2
+ export interface ExciterOptions {
3
+ /** highpass cutoff, Hz, default 3000 */
4
+ freq?: number
5
+ /** saturation amount, 0–1, maps to 1×–10× gain, default 0.5 */
6
+ drive?: number
7
+ /** mix-in level, 0–1, default 0.5 */
8
+ amount?: number
9
+ /** sample rate, default 44100 */
10
+ fs?: number
11
+ }
12
+
13
+ /**
14
+ * Mutates `data` in place and returns the same reference. Pass the same params
15
+ * object across calls — the SVF integrator state persists on it (`_lp`, `_bp`).
16
+ */
17
+ export default function exciter(data: Float32Array, params?: ExciterOptions): Float32Array
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@audio/effect-exciter",
3
- "version": "1.1.3",
3
+ "version": "1.1.4",
4
4
  "description": "Exciter — psychoacoustic harmonic synthesis for presence/air",
5
5
  "type": "module",
6
6
  "sideEffects": false,
@@ -16,7 +16,8 @@
16
16
  "files": [
17
17
  "exciter.js",
18
18
  "audio.js",
19
- "audio.d.ts"
19
+ "audio.d.ts",
20
+ "exciter.d.ts"
20
21
  ],
21
22
  "keywords": [
22
23
  "audio",
@@ -41,5 +42,7 @@
41
42
  "publishConfig": {
42
43
  "access": "public"
43
44
  },
44
- "audio": "./audio.js"
45
+ "types": "exciter.d.ts",
46
+ "audio": "./audio.js",
47
+ "funding": "https://github.com/sponsors/audiojs"
45
48
  }