From 63fbec05e9957419d1672c6fbad42a8d1f7673bb Mon Sep 17 00:00:00 2001 From: CaiWenzhi Date: Mon, 6 Jan 2014 12:19:59 +0800 Subject: [PATCH] Modify wrong codes --- cocos/gui/UILayout.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cocos/gui/UILayout.cpp b/cocos/gui/UILayout.cpp index bc89ea0e47..1462a58545 100644 --- a/cocos/gui/UILayout.cpp +++ b/cocos/gui/UILayout.cpp @@ -269,7 +269,7 @@ void Layout::onBeforeVisitStencil() glGetBooleanv(GL_DEPTH_WRITEMASK, &_currentDepthWriteMask); glDepthMask(GL_FALSE); glStencilFunc(GL_NEVER, mask_layer, mask_layer); - glStencilOp(!false ? GL_ZERO : GL_REPLACE, GL_KEEP, GL_KEEP); + glStencilOp(GL_ZERO, GL_KEEP, GL_KEEP); kmGLMatrixMode(KM_GL_MODELVIEW); kmGLPushMatrix(); kmGLLoadIdentity(); @@ -285,7 +285,7 @@ void Layout::onBeforeVisitStencil() kmGLMatrixMode(KM_GL_MODELVIEW); kmGLPopMatrix(); glStencilFunc(GL_NEVER, mask_layer, mask_layer); - glStencilOp(!false ? GL_REPLACE : GL_ZERO, GL_KEEP, GL_KEEP); + glStencilOp(GL_REPLACE, GL_KEEP, GL_KEEP); } void Layout::onAfterDrawStencil()