|
@@ -132,17 +132,17 @@
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- if (!url) {
|
|
|
+ if (!this.url) {
|
|
|
this._delayedOnLoad = load;
|
|
|
this._delayedOnError = onError;
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
- this._texture = this._getFromCache(url, noMipmap, samplingMode);
|
|
|
+ this._texture = this._getFromCache(this.url, noMipmap, samplingMode);
|
|
|
|
|
|
if (!this._texture) {
|
|
|
if (!scene.useDelayedTextureLoading) {
|
|
|
- this._texture = scene.getEngine().createTexture(url, noMipmap, invertY, scene, this._samplingMode, load, onError, this._buffer, null, this._format);
|
|
|
+ this._texture = scene.getEngine().createTexture(this.url, noMipmap, invertY, scene, this._samplingMode, load, onError, this._buffer, null, this._format);
|
|
|
if (deleteBuffer) {
|
|
|
delete this._buffer;
|
|
|
}
|
|
@@ -159,8 +159,6 @@
|
|
|
this._texture.onLoadedObservable.add(load);
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
- scene.getEngine().onAfterTextureInitObservable.notifyObservers(this);
|
|
|
}
|
|
|
|
|
|
public updateURL(url: string): void {
|