Skip to content

Commit f35c4cb

Browse files
committed
Bundle libfluidsynth-2.3.0 and drop 2.1.9
1 parent 2dd90b8 commit f35c4cb

File tree

5 files changed

+16
-6510
lines changed

5 files changed

+16
-6510
lines changed

README.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,15 @@ npm install --save js-synthesizer
1919

2020
### From main thread
2121

22-
Copies `dist/js-synthesizer.js` (or `dist/js-synthesizer.min.js`) and `externals/libfluidsynth-2.2.1.js` (libfluidsynth JS file) to your project, and writes `<script>` tags as following order:
22+
Copies `dist/js-synthesizer.js` (or `dist/js-synthesizer.min.js`) and `externals/libfluidsynth-2.3.0.js` (libfluidsynth JS file) to your project, and writes `<script>` tags as following order:
2323

2424
```html
25-
<script src="libfluidsynth-2.2.1.js"></script>
25+
<script src="libfluidsynth-2.3.0.js"></script>
2626
<script src="js-synthesizer.js"></script>
2727
```
2828

29+
> If you want to use Soundfont version 3 (.sf3) files, use `externals/libfluidsynth-2.3.0-with-libsndfile.js` instead of `externals/libfluidsynth-2.3.0.js`.
30+
2931
When scripts are available, please check whether `waitForReady` resolves.
3032

3133
```js
@@ -87,7 +89,7 @@ js-synthesizer supports AudioWorklet process via `dist/js-synthesizer.worklet.js
8789

8890
```js
8991
var context = new AudioContext();
90-
context.audioWorklet.addModule('libfluidsynth-2.2.1.js')
92+
context.audioWorklet.addModule('libfluidsynth-2.3.0.js')
9193
.then(function () {
9294
return context.audioWorklet.addModule('js-synthesizer.worklet.js');
9395
})
@@ -118,7 +120,7 @@ js-synthesizer and libfluidsynth can be executed on a Web Worker. Executing on a
118120
To use js-synthesizer on a Web Worker, simply call `importScripts` as followings:
119121

120122
```js
121-
self.importScripts('libfluidsynth-2.2.1.js');
123+
self.importScripts('libfluidsynth-2.3.0.js');
122124
self.importScripts('js-synthesizer.js');
123125
```
124126

externals/README.md

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1-
# External files
2-
3-
This directory contains the files that are not part of fluid-js, especially libfluidsynth library from [fluidsynth-emscripten](https://github.com/jet2jet/fluidsynth-emscripten) project.
4-
fluidsynth-emscripten and FluidSynth, the base of fluidsynth-emscripten, are licensed under [GNU Lesser General Public License (v2.1)](./LICENSE.fluidsynth.txt).
1+
# External files
2+
3+
This directory contains the files that are not part of js-synthesizer, especially libfluidsynth library from [fluidsynth-emscripten](https://github.com/jet2jet/fluidsynth-emscripten) project.
4+
fluidsynth-emscripten and FluidSynth, the base of fluidsynth-emscripten, are licensed under [GNU Lesser General Public License (v2.1)](./LICENSE.fluidsynth.txt).
5+
6+
## libfluidsynth-x.x.x.js and libfluidsynth-x.x.x-with-libsndfile.js
7+
8+
There are two JS files for the same version (>= 2.3.0). The `-libsndfile` file is built with `libsndfile` library, which enables to load Soundfile version 3 (.sf3) files. If you want to use SF3 files, use `libfluidsynth-x.x.x-with-libsndfile.js` instead of `libfluidsynth-x.x.x.js`.

0 commit comments

Comments
 (0)