Added guard around the blend mode setter.

This commit is contained in:
Richard Davey 2015-09-27 01:44:38 +01:00
parent cbf9b3f71f
commit 84a566bf79

View file

@ -42,7 +42,11 @@ PIXI.WebGLBlendModeManager.prototype.setBlendMode = function(blendMode)
this.currentBlendMode = blendMode;
var blendModeWebGL = PIXI.blendModesWebGL[this.currentBlendMode];
if (blendModeWebGL)
{
this.gl.blendFunc(blendModeWebGL[0], blendModeWebGL[1]);
}
return true;
};