playcanvas
Version:
Open-source WebGL/WebGPU 3D engine for the web
31 lines (30 loc) • 1.22 kB
TypeScript
export class SogBundleParser {
constructor(app: any);
/** @type {AppBase} */
app: AppBase;
canParse(context: any): boolean;
/**
* Checks if loading should be aborted due to asset unload or invalid device.
*
* @param {Asset} asset - The asset being loaded.
* @param {boolean} unloaded - Whether the asset was unloaded during async loading.
* @returns {boolean} True if loading should be aborted.
* @private
*/
private _shouldAbort;
/**
* @param {object} url - The URL of the resource to load.
* @param {string} url.load - The URL to use for loading the resource.
* @param {string} url.original - The original URL useful for identifying the resource type.
* @param {ResourceHandlerCallback} callback - The callback used when
* the resource is loaded or an error occurs.
* @param {Asset} asset - Container asset.
*/
load(url: {
load: string;
original: string;
}, callback: ResourceHandlerCallback, asset: Asset): Promise<void>;
}
import type { AppBase } from '../app-base.js';
import type { ResourceHandlerCallback } from '../handlers/handler.js';
import { Asset } from '../../framework/asset/asset.js';