update three LoadingManager (#27846)

https://github.com/mrdoob/three.js/pull/11259
This commit is contained in:
remin
2018-08-04 05:59:00 +09:00
committed by Sheetal Nandi
parent 50fd5dc2e5
commit be86ebdb41

17
types/three/three-core.d.ts vendored Normal file → Executable file
View File

@@ -2302,8 +2302,21 @@ export class LoadingManager {
*/
onError: (url: string) => void;
/**
* If provided, the callback will be passed each resource URL before a request is sent.
* The callback may return the original URL, or a new URL to override loading behavior.
* This behavior can be used to load assets from .ZIP files, drag-and-drop APIs, and Data URIs.
* @param callback URL modifier callback. Called with url argument, and must return resolvedURL.
*/
setURLModifier(callback?: (url: string) => string): void;
/**
* Given a URL, uses the URL modifier callback (if any) and returns a resolved URL.
* If no URL modifier is set, returns the original URL.
* @param url the url to load
*/
resolveURL(url: string): string;
itemStart(url: string): void;
itemEnd(url: string): void;
itemError(url: string): void;
@@ -5568,12 +5581,12 @@ export class WebGLRenderer implements Renderer {
getPixelRatio(): number;
setPixelRatio(value: number): void;
getDrawingBufferSize(): { width: number; height: number; };
setDrawingBufferSize(width: number, height: number, pixelRatio: number): void;
getSize(): { width: number; height: number; };
/**
* Resizes the output canvas to (width, height), and also sets the viewport to fit that size, starting in (0, 0).
*/