Creates a new ImageLoader.
The loadingManager for the loader to use. Default is THREE.DefaultLoadingManager.
Creates a new Loader.
The loadingManager for the loader to use. Default is THREE.DefaultLoadingManager.
The crossOrigin string to implement CORS for loading the url from a different domain that allows CORS. Default is anonymous.
The loadingManager the loader is using. Default is DefaultLoadingManager.
The base path from which the asset will be loaded. Default is the empty string.
The request header used in HTTP request. See .setRequestHeader. Default is empty object.
The base path from which additional resources like textures will be loaded. Default is the empty string.
Whether the XMLHttpRequest uses credentials. See .setWithCredentials. Default is false.
Begin loading from url and return the image object that will contain the data.
The path or URL to the file. This can also be a Data URI.
Will be called when load completes. The argument will be the loaded image.
This callback function is currently not supported.
Will be called when load errors.
Begin loading from url and return the image object that will contain the data.
The path or URL to the file. This can also be a Data URI.
This callback function is currently not supported.
The crossOrigin string to implement CORS for loading the url from a different domain that allows CORS.
Set the base path for the asset.
key: The name of the header whose value is to be set. value: The value to set as the body of the header. Set the request header used in HTTP request.
Set the base path for dependent resources like textures.
Whether the XMLHttpRequest uses credentials such as cookies, authorization headers or TLS client certificates. See XMLHttpRequest.withCredentials. Note that this has no effect if you are loading files locally or from the same domain.
Generated using TypeDoc
A loader for loading an Image. This is used internally by the CubeTextureLoader, ObjectLoader and TextureLoader.
Examples
WebGL / loader / obj | WebGL / shaders / ocean
Code Example
Please note three.js r84 dropped support for ImageLoader progress events. For an ImageLoader that supports progress events, see this thread.