spessasynth_lib 3.24.3 → 3.24.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.
- package/package.json +1 -2
- package/sequencer/worklet_sequencer/worklet_sequencer.js +6 -0
- package/synthetizer/worklet_processor.min.js +6 -6
- package/@types/external_midi/midi_handler.d.ts +0 -39
- package/@types/external_midi/web_midi_link.d.ts +0 -12
- package/@types/externals/stbvorbis_sync/stbvorbis_sync.min.d.ts +0 -1
- package/@types/index.d.ts +0 -44
- package/@types/midi_parser/basic_midi.d.ts +0 -36
- package/@types/midi_parser/midi_builder.d.ts +0 -68
- package/@types/midi_parser/midi_data.d.ts +0 -46
- package/@types/midi_parser/midi_editor.d.ts +0 -89
- package/@types/midi_parser/midi_loader.d.ts +0 -30
- package/@types/midi_parser/midi_message.d.ts +0 -155
- package/@types/midi_parser/midi_sequence.d.ts +0 -135
- package/@types/midi_parser/midi_writer.d.ts +0 -6
- package/@types/midi_parser/rmidi_writer.d.ts +0 -85
- package/@types/midi_parser/used_keys_loaded.d.ts +0 -10
- package/@types/sequencer/sequencer.d.ts +0 -277
- package/@types/sequencer/worklet_sequencer/sequencer_message.d.ts +0 -31
- package/@types/soundfont/basic_soundfont/basic_instrument.d.ts +0 -29
- package/@types/soundfont/basic_soundfont/basic_preset.d.ts +0 -86
- package/@types/soundfont/basic_soundfont/basic_sample.d.ts +0 -88
- package/@types/soundfont/basic_soundfont/basic_soundfont.d.ts +0 -102
- package/@types/soundfont/basic_soundfont/basic_zone.d.ts +0 -58
- package/@types/soundfont/basic_soundfont/basic_zones.d.ts +0 -22
- package/@types/soundfont/basic_soundfont/generator.d.ts +0 -102
- package/@types/soundfont/basic_soundfont/modulator.d.ts +0 -92
- package/@types/soundfont/basic_soundfont/riff_chunk.d.ts +0 -45
- package/@types/soundfont/basic_soundfont/write_dls/art2.d.ts +0 -6
- package/@types/soundfont/basic_soundfont/write_dls/articulator.d.ts +0 -28
- package/@types/soundfont/basic_soundfont/write_dls/combine_zones.d.ts +0 -8
- package/@types/soundfont/basic_soundfont/write_dls/ins.d.ts +0 -7
- package/@types/soundfont/basic_soundfont/write_dls/lins.d.ts +0 -5
- package/@types/soundfont/basic_soundfont/write_dls/modulator_converter.d.ts +0 -11
- package/@types/soundfont/basic_soundfont/write_dls/rgn2.d.ts +0 -8
- package/@types/soundfont/basic_soundfont/write_dls/wave.d.ts +0 -6
- package/@types/soundfont/basic_soundfont/write_dls/write_dls.d.ts +0 -6
- package/@types/soundfont/basic_soundfont/write_dls/wsmp.d.ts +0 -12
- package/@types/soundfont/basic_soundfont/write_dls/wvpl.d.ts +0 -8
- package/@types/soundfont/basic_soundfont/write_sf2/ibag.d.ts +0 -6
- package/@types/soundfont/basic_soundfont/write_sf2/igen.d.ts +0 -6
- package/@types/soundfont/basic_soundfont/write_sf2/imod.d.ts +0 -6
- package/@types/soundfont/basic_soundfont/write_sf2/inst.d.ts +0 -6
- package/@types/soundfont/basic_soundfont/write_sf2/pbag.d.ts +0 -6
- package/@types/soundfont/basic_soundfont/write_sf2/pgen.d.ts +0 -6
- package/@types/soundfont/basic_soundfont/write_sf2/phdr.d.ts +0 -6
- package/@types/soundfont/basic_soundfont/write_sf2/pmod.d.ts +0 -6
- package/@types/soundfont/basic_soundfont/write_sf2/sdta.d.ts +0 -11
- package/@types/soundfont/basic_soundfont/write_sf2/shdr.d.ts +0 -8
- package/@types/soundfont/basic_soundfont/write_sf2/soundfont_trimmer.d.ts +0 -6
- package/@types/soundfont/basic_soundfont/write_sf2/write.d.ts +0 -21
- package/@types/soundfont/dls/articulator_converter.d.ts +0 -19
- package/@types/soundfont/dls/dls_destinations.d.ts +0 -29
- package/@types/soundfont/dls/dls_preset.d.ts +0 -13
- package/@types/soundfont/dls/dls_sample.d.ts +0 -19
- package/@types/soundfont/dls/dls_soundfont.d.ts +0 -31
- package/@types/soundfont/dls/dls_sources.d.ts +0 -27
- package/@types/soundfont/dls/dls_zone.d.ts +0 -23
- package/@types/soundfont/dls/read_articulation.d.ts +0 -12
- package/@types/soundfont/dls/read_instrument.d.ts +0 -5
- package/@types/soundfont/dls/read_instrument_list.d.ts +0 -5
- package/@types/soundfont/dls/read_lart.d.ts +0 -7
- package/@types/soundfont/dls/read_region.d.ts +0 -7
- package/@types/soundfont/dls/read_samples.d.ts +0 -5
- package/@types/soundfont/load_soundfont.d.ts +0 -6
- package/@types/soundfont/read_sf2/generators.d.ts +0 -16
- package/@types/soundfont/read_sf2/instruments.d.ts +0 -29
- package/@types/soundfont/read_sf2/modulators.d.ts +0 -15
- package/@types/soundfont/read_sf2/presets.d.ts +0 -30
- package/@types/soundfont/read_sf2/samples.d.ts +0 -55
- package/@types/soundfont/read_sf2/soundfont.d.ts +0 -28
- package/@types/soundfont/read_sf2/zones.d.ts +0 -99
- package/@types/synthetizer/audio_effects/effects_config.d.ts +0 -41
- package/@types/synthetizer/audio_effects/fancy_chorus.d.ts +0 -97
- package/@types/synthetizer/audio_effects/reverb.d.ts +0 -7
- package/@types/synthetizer/key_modifier_manager.d.ts +0 -56
- package/@types/synthetizer/synth_event_handler.d.ts +0 -263
- package/@types/synthetizer/synth_soundfont_manager.d.ts +0 -52
- package/@types/synthetizer/synthetizer.d.ts +0 -358
- package/@types/synthetizer/worklet_system/message_protocol/worklet_message.d.ts +0 -98
- package/@types/synthetizer/worklet_system/worklet_methods/worklet_key_modifier.d.ts +0 -77
- package/@types/synthetizer/worklet_system/worklet_methods/worklet_soundfont_manager/sfman_message.d.ts +0 -7
- package/@types/synthetizer/worklet_system/worklet_utilities/controller_tables.d.ts +0 -23
- package/@types/synthetizer/worklet_system/worklet_utilities/worklet_processor_channel.d.ts +0 -155
- package/@types/synthetizer/worklet_url.d.ts +0 -5
- package/@types/utils/buffer_to_wav.d.ts +0 -31
- package/@types/utils/byte_functions/big_endian.d.ts +0 -13
- package/@types/utils/byte_functions/little_endian.d.ts +0 -35
- package/@types/utils/byte_functions/string.d.ts +0 -27
- package/@types/utils/byte_functions/variable_length_quantity.d.ts +0 -12
- package/@types/utils/indexed_array.d.ts +0 -21
- package/@types/utils/loggin.d.ts +0 -26
- package/@types/utils/other.d.ts +0 -37
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* * // NOTE: Every message needs a channel number (if not relevant or all, set to -1)
|
|
3
|
-
*/
|
|
4
|
-
export type workletMessageType = number;
|
|
5
|
-
export namespace workletMessageType {
|
|
6
|
-
let noteOff: number;
|
|
7
|
-
let noteOn: number;
|
|
8
|
-
let ccChange: number;
|
|
9
|
-
let programChange: number;
|
|
10
|
-
let channelPressure: number;
|
|
11
|
-
let polyPressure: number;
|
|
12
|
-
let killNote: number;
|
|
13
|
-
let ccReset: number;
|
|
14
|
-
let setChannelVibrato: number;
|
|
15
|
-
let soundFontManager: number;
|
|
16
|
-
let stopAll: number;
|
|
17
|
-
let killNotes: number;
|
|
18
|
-
let muteChannel: number;
|
|
19
|
-
let addNewChannel: number;
|
|
20
|
-
let customcCcChange: number;
|
|
21
|
-
let debugMessage: number;
|
|
22
|
-
let systemExclusive: number;
|
|
23
|
-
let setMasterParameter: number;
|
|
24
|
-
let setDrums: number;
|
|
25
|
-
let pitchWheel: number;
|
|
26
|
-
let transpose: number;
|
|
27
|
-
let highPerformanceMode: number;
|
|
28
|
-
let lockController: number;
|
|
29
|
-
let sequencerSpecific: number;
|
|
30
|
-
let requestSynthesizerSnapshot: number;
|
|
31
|
-
let setLogLevel: number;
|
|
32
|
-
let keyModifierManager: number;
|
|
33
|
-
let setEffectsGain: number;
|
|
34
|
-
let destroyWorklet: number;
|
|
35
|
-
}
|
|
36
|
-
export type masterParameterType = number;
|
|
37
|
-
export namespace masterParameterType {
|
|
38
|
-
let mainVolume: number;
|
|
39
|
-
let masterPan: number;
|
|
40
|
-
let voicesCap: number;
|
|
41
|
-
let interpolationType: number;
|
|
42
|
-
}
|
|
43
|
-
export const ALL_CHANNELS_OR_DIFFERENT_ACTION: -1;
|
|
44
|
-
export type returnMessageType = number;
|
|
45
|
-
export namespace returnMessageType {
|
|
46
|
-
export let channelProperties: number;
|
|
47
|
-
export let eventCall: number;
|
|
48
|
-
export let reportedCurrentTime: number;
|
|
49
|
-
let sequencerSpecific_1: number;
|
|
50
|
-
export { sequencerSpecific_1 as sequencerSpecific };
|
|
51
|
-
export let synthesizerSnapshot: number;
|
|
52
|
-
export let ready: number;
|
|
53
|
-
export let soundfontError: number;
|
|
54
|
-
export let identify: number;
|
|
55
|
-
}
|
|
56
|
-
export type WorkletMessage = {
|
|
57
|
-
channelNumber: number;
|
|
58
|
-
messageType: workletMessageType;
|
|
59
|
-
messageData: (number[] | boolean[] | WorkletVoice[] | number | {
|
|
60
|
-
sampleData: Float32Array;
|
|
61
|
-
sampleID: number;
|
|
62
|
-
} | {
|
|
63
|
-
rate: number;
|
|
64
|
-
depth: number;
|
|
65
|
-
delay: number;
|
|
66
|
-
} | boolean | ArrayBuffer | {
|
|
67
|
-
messageType: WorkletSequencerMessageType;
|
|
68
|
-
messageData: any;
|
|
69
|
-
} | {
|
|
70
|
-
messageType: workletKeyModifierMessageType;
|
|
71
|
-
messageData: any;
|
|
72
|
-
});
|
|
73
|
-
};
|
|
74
|
-
export type WorkletReturnMessage = {
|
|
75
|
-
/**
|
|
76
|
-
* - the message's type
|
|
77
|
-
*/
|
|
78
|
-
messageType: returnMessageType;
|
|
79
|
-
/**
|
|
80
|
-
* - the message's data
|
|
81
|
-
*
|
|
82
|
-
* 0 - channel properties -> [...<ChannelProperty>] see message_sending.js line 29
|
|
83
|
-
* 1 - event call -> {eventName<string>, eventData:<the event's data>}
|
|
84
|
-
* 2 - reported current time -> currentTime<number>
|
|
85
|
-
* 3 - sequencer specific -> [messageType<WorkletSequencerReturnMessageType> messageData<any>] note: refer to sequencer_message.js
|
|
86
|
-
* 4 - synthesizer snapshot -> snapshot<SynthesizerSnapshot> note: refer to snapshot.js
|
|
87
|
-
* 5 - ready -> (no data)
|
|
88
|
-
* 6 - soundfontError -> errorMessage<string>
|
|
89
|
-
* 7 - idenfity -> version<string>
|
|
90
|
-
*/
|
|
91
|
-
messageData: {
|
|
92
|
-
eventName: string;
|
|
93
|
-
eventData: any;
|
|
94
|
-
} | ChannelProperty[] | PresetListElement[] | string | {
|
|
95
|
-
messageType: WorkletSequencerReturnMessageType;
|
|
96
|
-
messageData: any;
|
|
97
|
-
} | SynthesizerSnapshot | [WorkletSoundfontManagerMessageType, any];
|
|
98
|
-
};
|
|
@@ -1,77 +0,0 @@
|
|
|
1
|
-
export class KeyModifier {
|
|
2
|
-
/**
|
|
3
|
-
* @param velocity {number}
|
|
4
|
-
* @param bank {number}
|
|
5
|
-
* @param program {number}
|
|
6
|
-
*/
|
|
7
|
-
constructor(velocity?: number, bank?: number, program?: number);
|
|
8
|
-
/**
|
|
9
|
-
* The new override velocity. -1 means unchanged
|
|
10
|
-
* @type {number}
|
|
11
|
-
*/
|
|
12
|
-
velocity: number;
|
|
13
|
-
/**
|
|
14
|
-
* The patch this key uses. -1 on either means default
|
|
15
|
-
* @type {{bank: number, program: number}}
|
|
16
|
-
*/
|
|
17
|
-
patch: {
|
|
18
|
-
bank: number;
|
|
19
|
-
program: number;
|
|
20
|
-
};
|
|
21
|
-
}
|
|
22
|
-
export type workletKeyModifierMessageType = number;
|
|
23
|
-
export namespace workletKeyModifierMessageType {
|
|
24
|
-
let addMapping: number;
|
|
25
|
-
let deleteMapping: number;
|
|
26
|
-
let clearMappings: number;
|
|
27
|
-
}
|
|
28
|
-
export class WorkletKeyModifierManager {
|
|
29
|
-
/**
|
|
30
|
-
* The velocity override mappings for MIDI keys
|
|
31
|
-
* @type {KeyModifier[][]}
|
|
32
|
-
* @private
|
|
33
|
-
*/
|
|
34
|
-
private _keyMappings;
|
|
35
|
-
/**
|
|
36
|
-
* @param type {workletKeyModifierMessageType}
|
|
37
|
-
* @param data {any}
|
|
38
|
-
*/
|
|
39
|
-
handleMessage(type: workletKeyModifierMessageType, data: any): void;
|
|
40
|
-
/**
|
|
41
|
-
* @param channel {number}
|
|
42
|
-
* @param midiNote {number}
|
|
43
|
-
* @param mapping {KeyModifier}
|
|
44
|
-
*/
|
|
45
|
-
addMapping(channel: number, midiNote: number, mapping: KeyModifier): void;
|
|
46
|
-
deleteMapping(channel: any, midiNote: any): void;
|
|
47
|
-
clearMappings(): void;
|
|
48
|
-
/**
|
|
49
|
-
* @param mappings {KeyModifier[][]}
|
|
50
|
-
*/
|
|
51
|
-
setMappings(mappings: KeyModifier[][]): void;
|
|
52
|
-
/**
|
|
53
|
-
* @returns {KeyModifier[][]}
|
|
54
|
-
*/
|
|
55
|
-
getMappings(): KeyModifier[][];
|
|
56
|
-
/**
|
|
57
|
-
* @param channel {number}
|
|
58
|
-
* @param midiNote {number}
|
|
59
|
-
* @returns {number} velocity, -1 if unchanged
|
|
60
|
-
*/
|
|
61
|
-
getVelocity(channel: number, midiNote: number): number;
|
|
62
|
-
/**
|
|
63
|
-
* @param channel {number}
|
|
64
|
-
* @param midiNote {number}
|
|
65
|
-
* @returns {boolean}
|
|
66
|
-
*/
|
|
67
|
-
hasOverridePatch(channel: number, midiNote: number): boolean;
|
|
68
|
-
/**
|
|
69
|
-
* @param channel {number}
|
|
70
|
-
* @param midiNote {number}
|
|
71
|
-
* @returns {{bank: number, program: number}} -1 if unchanged
|
|
72
|
-
*/
|
|
73
|
-
getPatch(channel: number, midiNote: number): {
|
|
74
|
-
bank: number;
|
|
75
|
-
program: number;
|
|
76
|
-
};
|
|
77
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
export const NON_CC_INDEX_OFFSET: 128;
|
|
2
|
-
export const CONTROLLER_TABLE_SIZE: 147;
|
|
3
|
-
export const resetArray: Int16Array<ArrayBuffer>;
|
|
4
|
-
export function setResetValue(i: any, v: any): number;
|
|
5
|
-
export namespace customControllers {
|
|
6
|
-
let channelTuning: number;
|
|
7
|
-
let channelTransposeFine: number;
|
|
8
|
-
let modulationMultiplier: number;
|
|
9
|
-
let masterTuning: number;
|
|
10
|
-
let channelTuningSemitones: number;
|
|
11
|
-
}
|
|
12
|
-
export const CUSTOM_CONTROLLER_TABLE_SIZE: number;
|
|
13
|
-
export const customResetArray: Float32Array<ArrayBuffer>;
|
|
14
|
-
export type dataEntryStates = number;
|
|
15
|
-
export namespace dataEntryStates {
|
|
16
|
-
let Idle: number;
|
|
17
|
-
let RPCoarse: number;
|
|
18
|
-
let RPFine: number;
|
|
19
|
-
let NRPCoarse: number;
|
|
20
|
-
let NRPFine: number;
|
|
21
|
-
let DataCoarse: number;
|
|
22
|
-
let DataFine: number;
|
|
23
|
-
}
|
|
@@ -1,155 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @typedef {Object} WorkletProcessorChannel
|
|
3
|
-
* @property {Int16Array} midiControllers - array of MIDI controller values + the values used by modulators as source (pitch bend, bend range etc.)
|
|
4
|
-
* @property {boolean[]} lockedControllers - array indicating if a controller is locked
|
|
5
|
-
* @property {Float32Array} customControllers - array of custom (not sf2) control values such as RPN pitch tuning, transpose, modulation depth, etc.
|
|
6
|
-
*
|
|
7
|
-
* @property {number} channelTransposeKeyShift - key shift of the channel
|
|
8
|
-
* @property {Int8Array} channelOctaveTuning - the tuning for octave on this channel
|
|
9
|
-
* @property {Int16Array} keyCentTuning - tuning of individual keys in cents
|
|
10
|
-
* @property {boolean} holdPedal - indicates whether the hold pedal is active
|
|
11
|
-
* @property {boolean} drumChannel - indicates whether the channel is a drum channel
|
|
12
|
-
* @property {number} velocityOverride - overrides velocity if > 0 otherwise disabled
|
|
13
|
-
*
|
|
14
|
-
* @property {dataEntryStates} dataEntryState - the current state of the data entry
|
|
15
|
-
* @property {number} NRPCoarse - the current coarse value of the Non-Registered Parameter
|
|
16
|
-
* @property {number} NRPFine - the current fine value of the Non-Registered Parameter
|
|
17
|
-
* @property {number} RPValue - the current value of the Registered Parameter
|
|
18
|
-
*
|
|
19
|
-
* @property {number} bank - the channel's bank number
|
|
20
|
-
* @property {BasicPreset} preset - the channel's preset
|
|
21
|
-
* @property {boolean} lockPreset - indicates whether the program on the channel is locked
|
|
22
|
-
* @property {boolean} presetUsesOverride - indcates if the channel uses a preset from the override soundfont.
|
|
23
|
-
*
|
|
24
|
-
* @property {boolean} lockGSNRPNParams - indicates whether the GS NRPN parameters are enabled
|
|
25
|
-
* @property {Object} channelVibrato - vibrato settings for the channel
|
|
26
|
-
* @property {number} channelVibrato.depth - depth of the vibrato effect (cents)
|
|
27
|
-
* @property {number} channelVibrato.delay - delay before the vibrato effect starts (seconds)
|
|
28
|
-
* @property {number} channelVibrato.rate - rate of the vibrato oscillation (Hz)
|
|
29
|
-
|
|
30
|
-
* @property {boolean} isMuted - indicates whether the channel is muted
|
|
31
|
-
* @property {WorkletVoice[]} voices - array of voices currently active on the channel
|
|
32
|
-
* @property {WorkletVoice[]} sustainedVoices - array of voices that are sustained on the channel
|
|
33
|
-
* @property {WorkletVoice[][][]} cachedVoices - first is midi note, second is velocity. output is an array of WorkletVoices
|
|
34
|
-
*/
|
|
35
|
-
/**
|
|
36
|
-
* @param sendEvent {boolean}
|
|
37
|
-
* @this {SpessaSynthProcessor}
|
|
38
|
-
*/
|
|
39
|
-
export function createWorkletChannel(this: SpessaSynthProcessor, sendEvent?: boolean): void;
|
|
40
|
-
/**
|
|
41
|
-
* @param channel {WorkletProcessorChannel}
|
|
42
|
-
* @param bank {number}
|
|
43
|
-
*/
|
|
44
|
-
export function setBankSelect(channel: WorkletProcessorChannel, bank: number): void;
|
|
45
|
-
/**
|
|
46
|
-
* @param channel {WorkletProcessorChannel}
|
|
47
|
-
* @returns {number}
|
|
48
|
-
*/
|
|
49
|
-
export function getBankSelect(channel: WorkletProcessorChannel): number;
|
|
50
|
-
/**
|
|
51
|
-
* This is a channel configuration enum, it is internally sent from Synthetizer via controller change
|
|
52
|
-
*/
|
|
53
|
-
export type channelConfiguration = number;
|
|
54
|
-
export namespace channelConfiguration {
|
|
55
|
-
let velocityOverride: number;
|
|
56
|
-
}
|
|
57
|
-
export type WorkletProcessorChannel = {
|
|
58
|
-
/**
|
|
59
|
-
* - array of MIDI controller values + the values used by modulators as source (pitch bend, bend range etc.)
|
|
60
|
-
*/
|
|
61
|
-
midiControllers: Int16Array;
|
|
62
|
-
/**
|
|
63
|
-
* - array indicating if a controller is locked
|
|
64
|
-
*/
|
|
65
|
-
lockedControllers: boolean[];
|
|
66
|
-
/**
|
|
67
|
-
* - array of custom (not sf2) control values such as RPN pitch tuning, transpose, modulation depth, etc.
|
|
68
|
-
*/
|
|
69
|
-
customControllers: Float32Array;
|
|
70
|
-
/**
|
|
71
|
-
* - key shift of the channel
|
|
72
|
-
*/
|
|
73
|
-
channelTransposeKeyShift: number;
|
|
74
|
-
/**
|
|
75
|
-
* - the tuning for octave on this channel
|
|
76
|
-
*/
|
|
77
|
-
channelOctaveTuning: Int8Array;
|
|
78
|
-
/**
|
|
79
|
-
* - tuning of individual keys in cents
|
|
80
|
-
*/
|
|
81
|
-
keyCentTuning: Int16Array;
|
|
82
|
-
/**
|
|
83
|
-
* - indicates whether the hold pedal is active
|
|
84
|
-
*/
|
|
85
|
-
holdPedal: boolean;
|
|
86
|
-
/**
|
|
87
|
-
* - indicates whether the channel is a drum channel
|
|
88
|
-
*/
|
|
89
|
-
drumChannel: boolean;
|
|
90
|
-
/**
|
|
91
|
-
* - overrides velocity if > 0 otherwise disabled
|
|
92
|
-
*/
|
|
93
|
-
velocityOverride: number;
|
|
94
|
-
/**
|
|
95
|
-
* - the current state of the data entry
|
|
96
|
-
*/
|
|
97
|
-
dataEntryState: dataEntryStates;
|
|
98
|
-
/**
|
|
99
|
-
* - the current coarse value of the Non-Registered Parameter
|
|
100
|
-
*/
|
|
101
|
-
NRPCoarse: number;
|
|
102
|
-
/**
|
|
103
|
-
* - the current fine value of the Non-Registered Parameter
|
|
104
|
-
*/
|
|
105
|
-
NRPFine: number;
|
|
106
|
-
/**
|
|
107
|
-
* - the current value of the Registered Parameter
|
|
108
|
-
*/
|
|
109
|
-
RPValue: number;
|
|
110
|
-
/**
|
|
111
|
-
* - the channel's bank number
|
|
112
|
-
*/
|
|
113
|
-
bank: number;
|
|
114
|
-
/**
|
|
115
|
-
* - the channel's preset
|
|
116
|
-
*/
|
|
117
|
-
preset: BasicPreset;
|
|
118
|
-
/**
|
|
119
|
-
* - indicates whether the program on the channel is locked
|
|
120
|
-
*/
|
|
121
|
-
lockPreset: boolean;
|
|
122
|
-
/**
|
|
123
|
-
* - indcates if the channel uses a preset from the override soundfont.
|
|
124
|
-
*/
|
|
125
|
-
presetUsesOverride: boolean;
|
|
126
|
-
/**
|
|
127
|
-
* - indicates whether the GS NRPN parameters are enabled
|
|
128
|
-
*/
|
|
129
|
-
lockGSNRPNParams: boolean;
|
|
130
|
-
/**
|
|
131
|
-
* - vibrato settings for the channel
|
|
132
|
-
*/
|
|
133
|
-
channelVibrato: {
|
|
134
|
-
depth: number;
|
|
135
|
-
delay: number;
|
|
136
|
-
rate: number;
|
|
137
|
-
};
|
|
138
|
-
/**
|
|
139
|
-
* - indicates whether the channel is muted
|
|
140
|
-
*/
|
|
141
|
-
isMuted: boolean;
|
|
142
|
-
/**
|
|
143
|
-
* - array of voices currently active on the channel
|
|
144
|
-
*/
|
|
145
|
-
voices: WorkletVoice[];
|
|
146
|
-
/**
|
|
147
|
-
* - array of voices that are sustained on the channel
|
|
148
|
-
*/
|
|
149
|
-
sustainedVoices: WorkletVoice[];
|
|
150
|
-
/**
|
|
151
|
-
* - first is midi note, second is velocity. output is an array of WorkletVoices
|
|
152
|
-
*/
|
|
153
|
-
cachedVoices: WorkletVoice[][][];
|
|
154
|
-
};
|
|
155
|
-
import { dataEntryStates } from "./controller_tables.js";
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
*
|
|
3
|
-
* @param audioBuffer {AudioBuffer}
|
|
4
|
-
* @param normalizeAudio {boolean} find the max sample point and set it to 1, and scale others with it
|
|
5
|
-
* @param channelOffset {number} channel offset and channel offset + 1 get saved
|
|
6
|
-
* @param metadata {WaveMetadata}
|
|
7
|
-
* @param loop {{start: number, end: number}} loop start and end points in seconds. Undefined if no loop
|
|
8
|
-
* @returns {Blob}
|
|
9
|
-
*/
|
|
10
|
-
export function audioBufferToWav(audioBuffer: AudioBuffer, normalizeAudio?: boolean, channelOffset?: number, metadata?: WaveMetadata, loop?: {
|
|
11
|
-
start: number;
|
|
12
|
-
end: number;
|
|
13
|
-
}): Blob;
|
|
14
|
-
export type WaveMetadata = {
|
|
15
|
-
/**
|
|
16
|
-
* - the song's title
|
|
17
|
-
*/
|
|
18
|
-
title: string | undefined;
|
|
19
|
-
/**
|
|
20
|
-
* - the song's artist
|
|
21
|
-
*/
|
|
22
|
-
artist: string | undefined;
|
|
23
|
-
/**
|
|
24
|
-
* - the song's album
|
|
25
|
-
*/
|
|
26
|
-
album: string | undefined;
|
|
27
|
-
/**
|
|
28
|
-
* - the song's genre
|
|
29
|
-
*/
|
|
30
|
-
genre: string | undefined;
|
|
31
|
-
};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Reads as Big endian
|
|
3
|
-
* @param dataArray {IndexedByteArray}
|
|
4
|
-
* @param bytesAmount {number}
|
|
5
|
-
* @returns {number}
|
|
6
|
-
*/
|
|
7
|
-
export function readBytesAsUintBigEndian(dataArray: IndexedByteArray, bytesAmount: number): number;
|
|
8
|
-
/**
|
|
9
|
-
* @param number {number}
|
|
10
|
-
* @param bytesAmount {number}
|
|
11
|
-
* @returns {number[]}
|
|
12
|
-
*/
|
|
13
|
-
export function writeBytesAsUintBigEndian(number: number, bytesAmount: number): number[];
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Reads as little endian
|
|
3
|
-
* @param dataArray {IndexedByteArray}
|
|
4
|
-
* @param bytesAmount {number}
|
|
5
|
-
* @returns {number}
|
|
6
|
-
*/
|
|
7
|
-
export function readLittleEndian(dataArray: IndexedByteArray, bytesAmount: number): number;
|
|
8
|
-
/**
|
|
9
|
-
* Writes a number as little endian seems to also work for negative numbers so yay?
|
|
10
|
-
* @param dataArray {IndexedByteArray}
|
|
11
|
-
* @param number {number}
|
|
12
|
-
* @param byteTarget {number}
|
|
13
|
-
*/
|
|
14
|
-
export function writeLittleEndian(dataArray: IndexedByteArray, number: number, byteTarget: number): void;
|
|
15
|
-
/**
|
|
16
|
-
* @param dataArray {IndexedByteArray}
|
|
17
|
-
* @param word {number}
|
|
18
|
-
*/
|
|
19
|
-
export function writeWord(dataArray: IndexedByteArray, word: number): void;
|
|
20
|
-
/**
|
|
21
|
-
* @param dataArray {IndexedByteArray}
|
|
22
|
-
* @param dword {number}
|
|
23
|
-
*/
|
|
24
|
-
export function writeDword(dataArray: IndexedByteArray, dword: number): void;
|
|
25
|
-
/**
|
|
26
|
-
* @param byte1 {number}
|
|
27
|
-
* @param byte2 {number}
|
|
28
|
-
* @returns {number}
|
|
29
|
-
*/
|
|
30
|
-
export function signedInt16(byte1: number, byte2: number): number;
|
|
31
|
-
/**
|
|
32
|
-
* @param byte {number}
|
|
33
|
-
* @returns {number}
|
|
34
|
-
*/
|
|
35
|
-
export function signedInt8(byte: number): number;
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @param dataArray {IndexedByteArray}
|
|
3
|
-
* @param bytes {number}
|
|
4
|
-
* @param encoding {string} the textElement encoding
|
|
5
|
-
* @param trimEnd {boolean} if we should trim once we reach an invalid byte
|
|
6
|
-
* @returns {string}
|
|
7
|
-
*/
|
|
8
|
-
export function readBytesAsString(dataArray: IndexedByteArray, bytes: number, encoding?: string, trimEnd?: boolean): string;
|
|
9
|
-
/**
|
|
10
|
-
* @param string {string}
|
|
11
|
-
* @param padLength {number}
|
|
12
|
-
* @returns {IndexedByteArray}
|
|
13
|
-
*/
|
|
14
|
-
export function getStringBytes(string: string, padLength?: number): IndexedByteArray;
|
|
15
|
-
/**
|
|
16
|
-
* @param string {string}
|
|
17
|
-
* @returns {IndexedByteArray}
|
|
18
|
-
*/
|
|
19
|
-
export function getStringBytesZero(string: string): IndexedByteArray;
|
|
20
|
-
/**
|
|
21
|
-
* @param string {string}
|
|
22
|
-
* @param outArray {IndexedByteArray}
|
|
23
|
-
* @param padLength {number}
|
|
24
|
-
* @returns {IndexedByteArray} modified IN PLACE
|
|
25
|
-
*/
|
|
26
|
-
export function writeStringAsBytes(outArray: IndexedByteArray, string: string, padLength?: number): IndexedByteArray;
|
|
27
|
-
import { IndexedByteArray } from "../indexed_array.js";
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Reads VLQ From a MIDI byte array
|
|
3
|
-
* @param MIDIbyteArray {IndexedByteArray}
|
|
4
|
-
* @returns {number}
|
|
5
|
-
*/
|
|
6
|
-
export function readVariableLengthQuantity(MIDIbyteArray: IndexedByteArray): number;
|
|
7
|
-
/**
|
|
8
|
-
* Write a VLQ from a number to a byte array
|
|
9
|
-
* @param number {number}
|
|
10
|
-
* @returns {number[]}
|
|
11
|
-
*/
|
|
12
|
-
export function writeVariableLengthQuantity(number: number): number[];
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @param arrs {(IndexedByteArray|Uint8Array)[]}
|
|
3
|
-
* @returns {IndexedByteArray|Uint8Array}
|
|
4
|
-
*/
|
|
5
|
-
export function combineArrays(arrs: (IndexedByteArray | Uint8Array)[]): IndexedByteArray | Uint8Array;
|
|
6
|
-
/**
|
|
7
|
-
* indexed_array.js
|
|
8
|
-
* purpose: exteds Uint8Array with a currentIndex property
|
|
9
|
-
*/
|
|
10
|
-
export class IndexedByteArray extends Uint8Array<ArrayBuffer> {
|
|
11
|
-
/**
|
|
12
|
-
* Creates a new instance of an Uint8Array with a currentIndex property
|
|
13
|
-
* @param args {any} same as for Uint8Array
|
|
14
|
-
*/
|
|
15
|
-
constructor(args: any);
|
|
16
|
-
/**
|
|
17
|
-
* The current index of the array
|
|
18
|
-
* @type {number}
|
|
19
|
-
*/
|
|
20
|
-
currentIndex: number;
|
|
21
|
-
}
|
package/@types/utils/loggin.d.ts
DELETED
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Enables or disables looging
|
|
3
|
-
* @param enableInfo {boolean} - enables info
|
|
4
|
-
* @param enableWarn {boolean} - enables warning
|
|
5
|
-
* @param enableGroup {boolean} - enables groups
|
|
6
|
-
* @param enableTable {boolean} - enables tables
|
|
7
|
-
*/
|
|
8
|
-
export function SpessaSynthLogging(enableInfo: boolean, enableWarn: boolean, enableGroup: boolean, enableTable: boolean): void;
|
|
9
|
-
/**
|
|
10
|
-
* @param message {...any}
|
|
11
|
-
*/
|
|
12
|
-
export function SpessaSynthInfo(...message: any[]): void;
|
|
13
|
-
/**
|
|
14
|
-
* @param message {...any}
|
|
15
|
-
*/
|
|
16
|
-
export function SpessaSynthWarn(...message: any[]): void;
|
|
17
|
-
export function SpessaSynthTable(...args: any[]): void;
|
|
18
|
-
/**
|
|
19
|
-
* @param message {...any} the message
|
|
20
|
-
*/
|
|
21
|
-
export function SpessaSynthGroup(...message: any[]): void;
|
|
22
|
-
/**
|
|
23
|
-
* @param message {...any} the message
|
|
24
|
-
*/
|
|
25
|
-
export function SpessaSynthGroupCollapsed(...message: any[]): void;
|
|
26
|
-
export function SpessaSynthGroupEnd(): void;
|
package/@types/utils/other.d.ts
DELETED
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* other.js
|
|
3
|
-
* purpose: contains some useful functions that don't belong in any specific category
|
|
4
|
-
*/
|
|
5
|
-
/**
|
|
6
|
-
* Formats the given seconds to nice readable time
|
|
7
|
-
* @param totalSeconds {number} time in seconds
|
|
8
|
-
* @return {{seconds: number, minutes: number, time: string}}
|
|
9
|
-
*/
|
|
10
|
-
export function formatTime(totalSeconds: number): {
|
|
11
|
-
seconds: number;
|
|
12
|
-
minutes: number;
|
|
13
|
-
time: string;
|
|
14
|
-
};
|
|
15
|
-
/**
|
|
16
|
-
* @param fileName {string}
|
|
17
|
-
* @returns {string}
|
|
18
|
-
*/
|
|
19
|
-
export function formatTitle(fileName: string): string;
|
|
20
|
-
/**
|
|
21
|
-
* Does what it says
|
|
22
|
-
* @param arr {number[]}
|
|
23
|
-
* @returns {string}
|
|
24
|
-
*/
|
|
25
|
-
export function arrayToHexString(arr: number[]): string;
|
|
26
|
-
/**
|
|
27
|
-
* @param eventData {Uint8Array}
|
|
28
|
-
* @returns {Uint8Array}
|
|
29
|
-
*/
|
|
30
|
-
export function sanitizeKarLyrics(eventData: Uint8Array): Uint8Array;
|
|
31
|
-
export namespace consoleColors {
|
|
32
|
-
let warn: string;
|
|
33
|
-
let unrecognized: string;
|
|
34
|
-
let info: string;
|
|
35
|
-
let recognized: string;
|
|
36
|
-
let value: string;
|
|
37
|
-
}
|