Skip to main content

alphaTab.importer.ScoreLoader

The ScoreLoader enables you easy loading of Scores using all available importers

 class ScoreLoader

Methods​

loadAlphaTex​

Loads the given alphaTex string.

static loadAlphaTex(tex: string, settings?: Settings): Score
ParameterSummary
texAll

The alphaTex string.

settingsAll

The settings to use for parsing.

Returns​

The parsed {@see Score}.

loadScoreAsync​

Loads a score asynchronously from the given datasource

static loadScoreAsync(path: string, success: (score: Score) => void, error: (error: any) => void, settings?: Settings): void
ParameterSummary
pathAll

the source path to load the binary file from

successAll

this function is called if the Score was successfully loaded from the datasource

errorAll

this function is called if any error during the loading occured.

settingsAll

settings for the score import

loadScoreFromBytes​

Loads the score from the given binary data.

static loadScoreFromBytes(data: Uint8Array, settings?: Settings): Score
ParameterSummary
dataAll

The binary data containing a score in any known file format.

settingsAll

The settings to use during importing.

Returns​

The loaded score.