supersonic-scsynth 0.1.0 → 0.1.1

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 CHANGED
@@ -16,7 +16,7 @@ Note: SuperSonic uses a SharedBuffer to send and receive OSC messages from scsyn
16
16
  ### Option 1: npm Package (Recommended)
17
17
 
18
18
  ```bash
19
- # Core engine only (~2MB)
19
+ # Core engine only (~450KB)
20
20
  npm install supersonic-scsynth
21
21
 
22
22
  # Or install everything (engine + synthdefs + samples)
@@ -30,7 +30,7 @@ npm install supersonic-scsynth-bundle
30
30
  import { SuperSonic } from 'https://unpkg.com/supersonic-scsynth@0.1.0';
31
31
 
32
32
  const sonic = new SuperSonic({
33
- audioBaseURL: 'https://unpkg.com/supersonic-scsynth-samples-bd@0.1.0/samples/'
33
+ audioBaseURL: 'https://unpkg.com/supersonic-scsynth-samples@0.1.0/samples/'
34
34
  });
35
35
 
36
36
  await sonic.init();
@@ -49,34 +49,29 @@ The 'nightly' (i.e. for every new commit) pre-built distribution files are publi
49
49
 
50
50
  https://samaaron.github.io/supersonic/supersonic-dist.zip
51
51
 
52
+ This includes:
53
+ - Core engine (WASM + JS)
54
+ - All 120 synthdefs
55
+ - All 206 samples
56
+ - Size: ~35MB
57
+
52
58
  ## Package Structure
53
59
 
54
60
  SuperSonic is published as multiple npm packages to keep the core engine small:
55
61
 
56
62
  ### Core Package
57
- - **`supersonic-scsynth`** (~2MB) - The WebAssembly scsynth engine
63
+ - **`supersonic-scsynth`** (~450KB) - The WebAssembly scsynth engine
58
64
  - GPL-3.0-or-later license
59
65
 
60
66
  ### Resource Packages
61
- - **`supersonic-scsynth-synthdefs`** (~7MB) - All 120 Sonic Pi synthdefs
67
+ - **`supersonic-scsynth-synthdefs`** (~67KB) - All 120 Sonic Pi synthdefs
62
68
  - MIT license
63
69
  - From [Sonic Pi](https://github.com/sonic-pi-net/sonic-pi)
64
70
 
65
- - **`supersonic-scsynth-samples`** - Meta-package for all Sonic Pi samples
71
+ - **`supersonic-scsynth-samples`** (~34MB) - All 206 Sonic Pi samples
66
72
  - CC0-1.0 license (public domain)
67
- - Includes 18 category packages (install individually to save space):
68
- - `supersonic-scsynth-samples-bd` - Bass drums
69
- - `supersonic-scsynth-samples-sn` - Snares
70
- - `supersonic-scsynth-samples-hat` - Hi-hats
71
- - `supersonic-scsynth-samples-loop` - Drum loops
72
- - `supersonic-scsynth-samples-ambi` - Ambient sounds
73
- - `supersonic-scsynth-samples-bass` - Bass sounds
74
- - `supersonic-scsynth-samples-elec` - Electronic sounds
75
- - `supersonic-scsynth-samples-glitch` - Glitch sounds
76
- - `supersonic-scsynth-samples-guit` - Guitar sounds
77
- - `supersonic-scsynth-samples-perc` - Percussion
78
- - `supersonic-scsynth-samples-misc` - Miscellaneous
79
- - Plus: arovane, drum, mehackit, ride, tabla, tbd, vinyl
73
+ - Categories: ambient, bass, drums, electronic, glitch, guitar, hi-hats, loops, percussion, snares, tabla, vinyl, and more
74
+ - From [Sonic Pi](https://github.com/sonic-pi-net/sonic-pi)
80
75
 
81
76
  ### Convenience Package
82
77
  - **`supersonic-scsynth-bundle`** - Includes core + synthdefs + all samples
@@ -107,7 +102,7 @@ source ~/path/to/emsdk_env.sh
107
102
  ./build.sh
108
103
  ```
109
104
 
110
- Outputs to `dist/` directory (~1.5MB WASM + ~80KB JS).
105
+ Outputs to `dist/` directory (~1.5MB WASM + ~76KB JS + symlinks to synthdefs/samples).
111
106
 
112
107
  ### 2. Serve Demo
113
108
 
@@ -163,7 +158,7 @@ import { SuperSonic } from 'https://unpkg.com/supersonic-scsynth@0.1.0';
163
158
 
164
159
  // Configure sample path (required for buffer loading)
165
160
  const sonic = new SuperSonic({
166
- audioBaseURL: 'https://unpkg.com/supersonic-scsynth-samples-bd@0.1.0/samples/'
161
+ audioBaseURL: 'https://unpkg.com/supersonic-scsynth-samples@0.1.0/samples/'
167
162
  });
168
163
 
169
164
  await sonic.init();
@@ -230,9 +225,8 @@ npm install supersonic-scsynth
230
225
  # Synthdefs (optional)
231
226
  npm install supersonic-scsynth-synthdefs
232
227
 
233
- # Individual sample categories (optional)
234
- npm install supersonic-scsynth-samples-bd
235
- npm install supersonic-scsynth-samples-loop
228
+ # Samples (optional)
229
+ npm install supersonic-scsynth-samples
236
230
 
237
231
  # Or everything at once
238
232
  npm install supersonic-scsynth-bundle
@@ -245,7 +239,7 @@ Then use via CDN in your HTML:
245
239
  import { SuperSonic } from 'https://unpkg.com/supersonic-scsynth@0.1.0';
246
240
 
247
241
  const sonic = new SuperSonic({
248
- audioBaseURL: 'https://unpkg.com/supersonic-scsynth-samples-bd@0.1.0/samples/'
242
+ audioBaseURL: 'https://unpkg.com/supersonic-scsynth-samples@0.1.0/samples/'
249
243
  });
250
244
 
251
245
  await sonic.init();
@@ -282,7 +276,7 @@ Sample and synthdef paths must be explicitly configured:
282
276
 
283
277
  ```javascript
284
278
  const sonic = new SuperSonic({
285
- audioBaseURL: 'https://unpkg.com/supersonic-scsynth-samples-bd@0.1.0/samples/'
279
+ audioBaseURL: 'https://unpkg.com/supersonic-scsynth-samples@0.1.0/samples/'
286
280
  });
287
281
 
288
282
  await sonic.loadSynthDefs(
@@ -291,23 +285,14 @@ await sonic.loadSynthDefs(
291
285
  );
292
286
  ```
293
287
 
294
- **Engine Paths (Default):**
288
+ **Engine Paths:**
295
289
 
296
290
  The core engine expects these files relative to your HTML:
297
291
  - WASM: `./dist/wasm/scsynth-nrt.wasm`
298
292
  - AudioWorklet: `./dist/workers/scsynth_audio_worklet.js`
299
293
  - Workers: `./dist/workers/osc_out_worker.js`, `osc_in_worker.js`, `debug_worker.js`
300
294
 
301
- **Custom Engine Paths:**
302
-
303
- ```javascript
304
- const sonic = new SuperSonic();
305
- sonic.config.wasmUrl = '/custom/path/scsynth-nrt.wasm';
306
- sonic.config.workletUrl = '/custom/path/scsynth_audio_worklet.js';
307
- await sonic.init();
308
- ```
309
-
310
- **Note:** Worker paths are currently hardcoded to `./dist/workers/` and cannot be configured.
295
+ These paths are currently not configurable.
311
296
 
312
297
 
313
298
  ## License
@@ -1,8 +1,6 @@
1
1
  {
2
- "wasmFile": "scsynth-nrt.ca1dd592.wasm",
3
- "wasmFileStable": "scsynth-nrt.wasm",
4
- "hash": "ca1dd592",
5
- "buildId": "20251102-111057",
6
- "buildTime": "2025-11-02T11:10:57Z",
7
- "gitHash": "cc71875"
2
+ "wasmFile": "scsynth-nrt.wasm",
3
+ "buildId": "20251103-162833",
4
+ "buildTime": "2025-11-03T16:28:33Z",
5
+ "gitHash": "501ed1e"
8
6
  }
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "supersonic-scsynth",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "SuperCollider scsynth WebAssembly port for AudioWorklet - Run SuperCollider synthesis in the browser",
5
5
  "main": "dist/supersonic.js",
6
6
  "unpkg": "dist/supersonic.js",
@@ -8,8 +8,10 @@
8
8
  "type": "module",
9
9
  "scripts": {
10
10
  "build": "./build.sh",
11
+ "build:release": "./build.sh --release",
11
12
  "clean": "./clean.sh",
12
- "dev": "cd example && ruby server.rb"
13
+ "dev": "cd example && ruby server.rb",
14
+ "prepublishOnly": "./build.sh --release"
13
15
  },
14
16
  "repository": {
15
17
  "type": "git",