From 540c67f7015834c185da1bb5e89eddc5b6b33fac Mon Sep 17 00:00:00 2001 From: Dhilan007 Date: Tue, 1 Apr 2014 15:03:17 +0800 Subject: [PATCH] Label:fixed possible appear OpenGL error 0x500. --- cocos/2d/CCLabel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cocos/2d/CCLabel.cpp b/cocos/2d/CCLabel.cpp index 4a6d110979..8c7c8bbefd 100644 --- a/cocos/2d/CCLabel.cpp +++ b/cocos/2d/CCLabel.cpp @@ -1082,7 +1082,7 @@ void Label::drawTextSprite(Renderer *renderer, bool parentTransformUpdated) if (_shadowEnabled && _shadowNode == nullptr) { _shadowNode = Sprite::createWithTexture(_textSprite->getTexture()); - if (_shadowNode) + if (_shadowNode && _blendFuncDirty) { _shadowNode->setBlendFunc(_blendFunc); }