Fix drawLine & drawPoints won't use blendFunc bug

This commit is contained in:
XiaoFeng 2015-07-03 11:30:38 +08:00
parent 668dc50e07
commit 993e420ce4
1 changed files with 6 additions and 2 deletions

View File

@ -371,7 +371,9 @@ void DrawNode::onDrawGLLine(const Mat4 &transform, uint32_t flags)
auto glProgram = GLProgramCache::getInstance()->getGLProgram(GLProgram::SHADER_NAME_POSITION_LENGTH_TEXTURE_COLOR);
glProgram->use();
glProgram->setUniformsForBuiltins(transform);
GL::blendFunc(_blendFunc.src, _blendFunc.dst);
if (_dirtyGLLine)
{
glBindBuffer(GL_ARRAY_BUFFER, _vboGLLine);
@ -412,7 +414,9 @@ void DrawNode::onDrawGLPoint(const Mat4 &transform, uint32_t flags)
auto glProgram = GLProgramCache::getInstance()->getGLProgram(GLProgram::SHADER_NAME_POSITION_COLOR_TEXASPOINTSIZE);
glProgram->use();
glProgram->setUniformsForBuiltins(transform);
GL::blendFunc(_blendFunc.src, _blendFunc.dst);
if (_dirtyGLPoint)
{
glBindBuffer(GL_ARRAY_BUFFER, _vboGLPoint);