@coderline/alphatab 1.3.0-alpha.194 → 1.3.0-alpha.200
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/dist/alphaTab.d.ts +26 -0
- package/dist/alphaTab.js +42 -4
- package/dist/alphaTab.min.js +2 -2
- package/dist/alphaTab.min.mjs +2 -2
- package/dist/alphaTab.mjs +42 -4
- package/package.json +1 -1
package/dist/alphaTab.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* alphaTab v1.3.0-alpha.
|
|
2
|
+
* alphaTab v1.3.0-alpha.200 (develop, build 200)
|
|
3
3
|
*
|
|
4
4
|
* Copyright © 2022, Daniel Kuschny and Contributors, All rights reserved.
|
|
5
5
|
*
|
|
@@ -17284,6 +17284,19 @@ class MidiEventsPlayedEventArgs {
|
|
|
17284
17284
|
}
|
|
17285
17285
|
}
|
|
17286
17286
|
|
|
17287
|
+
/**
|
|
17288
|
+
* Represents the info when the playback range changed.
|
|
17289
|
+
*/
|
|
17290
|
+
class PlaybackRangeChangedEventArgs {
|
|
17291
|
+
/**
|
|
17292
|
+
* Initializes a new instance of the {@link PlaybackRangeChangedEventArgs} class.
|
|
17293
|
+
* @param range The range.
|
|
17294
|
+
*/
|
|
17295
|
+
constructor(playbackRange) {
|
|
17296
|
+
this.playbackRange = playbackRange;
|
|
17297
|
+
}
|
|
17298
|
+
}
|
|
17299
|
+
|
|
17287
17300
|
/**
|
|
17288
17301
|
* This is the main synthesizer component which can be used to
|
|
17289
17302
|
* play a {@link MidiFile} via a {@link ISynthOutput}.
|
|
@@ -17314,6 +17327,7 @@ class AlphaSynth {
|
|
|
17314
17327
|
this.stateChanged = new EventEmitterOfT();
|
|
17315
17328
|
this.positionChanged = new EventEmitterOfT();
|
|
17316
17329
|
this.midiEventsPlayed = new EventEmitterOfT();
|
|
17330
|
+
this.playbackRangeChanged = new EventEmitterOfT();
|
|
17317
17331
|
Logger.debug('AlphaSynth', 'Initializing player');
|
|
17318
17332
|
this.state = PlayerState.Paused;
|
|
17319
17333
|
Logger.debug('AlphaSynth', 'Creating output');
|
|
@@ -17430,6 +17444,7 @@ class AlphaSynth {
|
|
|
17430
17444
|
if (value) {
|
|
17431
17445
|
this.tickPosition = value.startTick;
|
|
17432
17446
|
}
|
|
17447
|
+
this.playbackRangeChanged.trigger(new PlaybackRangeChangedEventArgs(value));
|
|
17433
17448
|
}
|
|
17434
17449
|
get isLooping() {
|
|
17435
17450
|
return this._sequencer.isLooping;
|
|
@@ -20707,6 +20722,7 @@ class AlphaSynthWebWorker {
|
|
|
20707
20722
|
this._player.midiLoadFailed.on(this.onMidiLoadFailed.bind(this));
|
|
20708
20723
|
this._player.readyForPlayback.on(this.onReadyForPlayback.bind(this));
|
|
20709
20724
|
this._player.midiEventsPlayed.on(this.onMidiEventsPlayed.bind(this));
|
|
20725
|
+
this._player.playbackRangeChanged.on(this.onPlaybackRangeChanged.bind(this));
|
|
20710
20726
|
this._main.postMessage({
|
|
20711
20727
|
cmd: 'alphaSynth.ready'
|
|
20712
20728
|
});
|
|
@@ -20876,6 +20892,12 @@ class AlphaSynthWebWorker {
|
|
|
20876
20892
|
events: args.events.map(JsonConverter.midiEventToJsObject)
|
|
20877
20893
|
});
|
|
20878
20894
|
}
|
|
20895
|
+
onPlaybackRangeChanged(args) {
|
|
20896
|
+
this._main.postMessage({
|
|
20897
|
+
cmd: 'alphaSynth.playbackRangeChanged',
|
|
20898
|
+
playbackRange: args.playbackRange
|
|
20899
|
+
});
|
|
20900
|
+
}
|
|
20879
20901
|
}
|
|
20880
20902
|
|
|
20881
20903
|
/**
|
|
@@ -24070,6 +24092,7 @@ class AlphaTabApiBase {
|
|
|
24070
24092
|
this.playerStateChanged = new EventEmitterOfT();
|
|
24071
24093
|
this.playerPositionChanged = new EventEmitterOfT();
|
|
24072
24094
|
this.midiEventsPlayed = new EventEmitterOfT();
|
|
24095
|
+
this.playbackRangeChanged = new EventEmitterOfT();
|
|
24073
24096
|
this.uiFacade = uiFacade;
|
|
24074
24097
|
this.container = uiFacade.rootContainer;
|
|
24075
24098
|
uiFacade.initialize(this, settings);
|
|
@@ -24493,6 +24516,7 @@ class AlphaTabApiBase {
|
|
|
24493
24516
|
this.player.stateChanged.on(this.onPlayerStateChanged.bind(this));
|
|
24494
24517
|
this.player.positionChanged.on(this.onPlayerPositionChanged.bind(this));
|
|
24495
24518
|
this.player.midiEventsPlayed.on(this.onMidiEventsPlayed.bind(this));
|
|
24519
|
+
this.player.playbackRangeChanged.on(this.onPlaybackRangeChanged.bind(this));
|
|
24496
24520
|
this.player.finished.on(this.onPlayerFinished.bind(this));
|
|
24497
24521
|
if (this.settings.player.enableCursor) {
|
|
24498
24522
|
this.setupCursors();
|
|
@@ -24654,6 +24678,7 @@ class AlphaTabApiBase {
|
|
|
24654
24678
|
this._playerState = PlayerState.Paused;
|
|
24655
24679
|
// we need to update our position caches if we render a tablature
|
|
24656
24680
|
this.renderer.postRenderFinished.on(() => {
|
|
24681
|
+
debugger;
|
|
24657
24682
|
this.cursorUpdateTick(this._previousTick, false, this._previousTick > 10);
|
|
24658
24683
|
});
|
|
24659
24684
|
if (this.player) {
|
|
@@ -24889,7 +24914,7 @@ class AlphaTabApiBase {
|
|
|
24889
24914
|
// for the selection ensure start < end
|
|
24890
24915
|
if (this._selectionEnd) {
|
|
24891
24916
|
let startTick = this._selectionStart.beat.absolutePlaybackStart;
|
|
24892
|
-
let endTick = this.
|
|
24917
|
+
let endTick = this._selectionEnd.beat.absolutePlaybackStart;
|
|
24893
24918
|
if (endTick < startTick) {
|
|
24894
24919
|
let t = this._selectionStart;
|
|
24895
24920
|
this._selectionStart = this._selectionEnd;
|
|
@@ -25162,6 +25187,13 @@ class AlphaTabApiBase {
|
|
|
25162
25187
|
this.midiEventsPlayed.trigger(e);
|
|
25163
25188
|
this.uiFacade.triggerEvent(this.container, 'midiEventsPlayed', e);
|
|
25164
25189
|
}
|
|
25190
|
+
onPlaybackRangeChanged(e) {
|
|
25191
|
+
if (this._isDestroyed) {
|
|
25192
|
+
return;
|
|
25193
|
+
}
|
|
25194
|
+
this.playbackRangeChanged.trigger(e);
|
|
25195
|
+
this.uiFacade.triggerEvent(this.container, 'playbackRangeChanged', e);
|
|
25196
|
+
}
|
|
25165
25197
|
}
|
|
25166
25198
|
|
|
25167
25199
|
/**
|
|
@@ -25804,6 +25836,7 @@ class AlphaSynthWebWorkerApi {
|
|
|
25804
25836
|
this.stateChanged = new EventEmitterOfT();
|
|
25805
25837
|
this.positionChanged = new EventEmitterOfT();
|
|
25806
25838
|
this.midiEventsPlayed = new EventEmitterOfT();
|
|
25839
|
+
this.playbackRangeChanged = new EventEmitterOfT();
|
|
25807
25840
|
this._workerIsReadyForPlayback = false;
|
|
25808
25841
|
this._workerIsReady = false;
|
|
25809
25842
|
this._outputIsReady = false;
|
|
@@ -26097,6 +26130,10 @@ class AlphaSynthWebWorkerApi {
|
|
|
26097
26130
|
this._state = data.state;
|
|
26098
26131
|
this.stateChanged.trigger(new PlayerStateChangedEventArgs(data.state, data.stopped));
|
|
26099
26132
|
break;
|
|
26133
|
+
case 'alphaSynth.playbackRangeChanged':
|
|
26134
|
+
this._playbackRange = data.playbackRange;
|
|
26135
|
+
this.playbackRangeChanged.trigger(new PlaybackRangeChangedEventArgs(this._playbackRange));
|
|
26136
|
+
break;
|
|
26100
26137
|
case 'alphaSynth.finished':
|
|
26101
26138
|
this.finished.trigger();
|
|
26102
26139
|
break;
|
|
@@ -40641,8 +40678,8 @@ class CoreSettings {
|
|
|
40641
40678
|
// </auto-generated>
|
|
40642
40679
|
class VersionInfo {
|
|
40643
40680
|
}
|
|
40644
|
-
VersionInfo.version = '1.3.0-alpha.
|
|
40645
|
-
VersionInfo.date = '2022-03-
|
|
40681
|
+
VersionInfo.version = '1.3.0-alpha.200';
|
|
40682
|
+
VersionInfo.date = '2022-03-08T00:34:45.791Z';
|
|
40646
40683
|
|
|
40647
40684
|
var index$5 = /*#__PURE__*/Object.freeze({
|
|
40648
40685
|
__proto__: null,
|
|
@@ -43709,6 +43746,7 @@ var index = /*#__PURE__*/Object.freeze({
|
|
|
43709
43746
|
PlaybackRange: PlaybackRange,
|
|
43710
43747
|
get PlayerState () { return PlayerState; },
|
|
43711
43748
|
PlayerStateChangedEventArgs: PlayerStateChangedEventArgs,
|
|
43749
|
+
PlaybackRangeChangedEventArgs: PlaybackRangeChangedEventArgs,
|
|
43712
43750
|
PositionChangedEventArgs: PositionChangedEventArgs,
|
|
43713
43751
|
AlphaSynthWebWorkerApi: AlphaSynthWebWorkerApi
|
|
43714
43752
|
});
|