Skip to main content

load

since 0.9.4

Description​

This function initiates a load of the score using the given data. The supported types is depending on the platform.

Signatures​

TypeValues
function load(score)JavaScript

Load the given score object

function load(score, trackIndexes)JavaScript

Load the given score object

function load(arrayBuffer)JavaScript

Load the score from the given raw bytes using the available score loaders

function load(arrayBuffer, trackIndexes)JavaScript

Load the score from the given raw bytes using the available score loaders

function load(uint8array)JavaScript

Load the score from the given raw bytes using the available score loaders

function load(uint8array, trackIndexes)JavaScript

Load the score from the given raw bytes using the available score loaders

function load(url)JavaScript

Load the score from the given URL via Ajax using the available score loaders

function load(url, trackIndexes)JavaScript

Load the score from the given URL via Ajax using the available score loaders

alphaTab('load', score)jQuery

Load the given score object

alphaTab('load', score, trackIndexes)jQuery

Load the given score object

alphaTab('load', arraybuffer)jQuery

Load the score from the given raw bytes using the available score loaders

alphaTab('load', arraybuffer, trackIndexes)jQuery

Load the score from the given raw bytes using the available score loaders

alphaTab('load', uint8array)jQuery

Load the score from the given raw bytes using the available score loaders

alphaTab('load', uint8array, trackIndexes)jQuery

Load the score from the given raw bytes using the available score loaders

alphaTab('load', url)jQuery

Load the score from the given URL via Ajax using the available score loaders

alphaTab('load', url, trackIndexes)jQuery

Load the score from the given URL via Ajax using the available score loaders

bool Load(Score score).net

Load the given score object

bool Load(Score score, int[] trackIndexes).net

Load the given score object

bool Load(byte[] raw).net

Load the score from the given raw bytes using the available score loaders

bool Load(byte[] raw, int[] trackIndexes).net

Load the score from the given raw bytes using the available score loaders

bool Load(Stream raw).net

Load the score from the given stream using the available score loaders

bool Load(Stream raw, int[] trackIndexes).net

Load the score from the given stream using the available score loaders

fun load(score: Score, trackIndexes: alphaTab.collections.DoubleList? = null)Android

Load the given score object

fun load(raw: ByteArray, trackIndexes: alphaTab.collections.DoubleList? = null)Android

Load the score from the given raw bytes using the available score loaders

fun load(raw: UByteArray, trackIndexes: alphaTab.collections.DoubleList? = null)Android

Load the score from the given raw bytes using the available score loaders

fun load(stream: java.io.InputStream, trackIndexes: alphaTab.collections.DoubleList? = null)Android

Load the score from the given strean using the available score loaders

Parameters​

ParametersTypeSummary
arraybufferJavaScript & jQueryArrayBuffer

The arraybuffer containing the raw bytes of a file supported by the score loaders

uint8arrayJavaScript & jQueryUint8Array

The Uint8Array containing the raw bytes of a file supported by the score loaders

trackIndexesAllint[]

A indexes of the tracks that should be rendered after the track is loaded. If not supplied, the first song will be rendered.

score.netAlphaTab.Model.Score

The score object to load.

raw.netbyte[]

The raw bytes containing a file supported by the score loaders.

raw.netSystem.IO.Stream

The stream containing a file supported by the score loaders.

scoreAndroidalphaTab.model.Score

The score object to load.

rawAndroidByteArray

The raw bytes containing a file supported by the score loaders.

rawAndroidUByteArray

The raw bytes containing a file supported by the score loaders.

streamAndroidjava.io.InputStream

The stream containing a file supported by the score loaders.

Returns​

true if the passed in object is a supported format and loading was initiated, otherwise false.

Examples​

const api = new alphaTab.AlphaTabApi(document.querySelector('#alphaTab'));
api.load('/assets/MyFile.gp');