Update ForwardDiffuseLightPipeline.js

This commit is contained in:
Richard Davey 2020-07-16 15:51:12 +01:00
parent 6aba9e71b1
commit 76de5c246a

View file

@ -328,9 +328,10 @@ var ForwardDiffuseLightPipeline = new Class({
*/ */
setTexture2D: function (texture, gameObject) setTexture2D: function (texture, gameObject)
{ {
if (texture === undefined) { texture = this.renderer.blankTexture.glTexture; }
var renderer = this.renderer; var renderer = this.renderer;
if (texture === undefined) { texture = renderer.tempTextures[0]; }
var normalTexture = this.getNormalMap(gameObject); var normalTexture = this.getNormalMap(gameObject);
if (renderer.isNewNormalMap()) if (renderer.isNewNormalMap())