fix disabling of blendipoos!

SVN revision: 43655
This commit is contained in:
Carsten Haitzler 2009-11-13 07:30:03 +00:00
parent 2df6cb92bb
commit fccd2db126
1 changed files with 8 additions and 8 deletions

View File

@ -703,13 +703,6 @@ shader_array_flush(Evas_GL_Context *gc)
glActiveTexture(GL_TEXTURE0); glActiveTexture(GL_TEXTURE0);
glBindTexture(GL_TEXTURE_2D, gc->shader.cur_tex); glBindTexture(GL_TEXTURE_2D, gc->shader.cur_tex);
} }
if (gc->shader.blend != gc->shader.current.blend)
{
if (gc->shader.blend)
glEnable(GL_BLEND);
else
glDisable(GL_BLEND);
}
if (gc->shader.render_op != gc->shader.current.render_op) if (gc->shader.render_op != gc->shader.current.render_op)
{ {
switch (gc->shader.render_op) switch (gc->shader.render_op)
@ -718,7 +711,7 @@ shader_array_flush(Evas_GL_Context *gc)
glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA); glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA);
break; break;
case EVAS_RENDER_COPY: /**< d = s */ case EVAS_RENDER_COPY: /**< d = s */
glDisable(GL_BLEND); gc->shader.blend = 0;
glBlendFunc(GL_ONE, GL_ONE); glBlendFunc(GL_ONE, GL_ONE);
break; break;
// FIXME: fix blend funcs below! // FIXME: fix blend funcs below!
@ -737,6 +730,13 @@ shader_array_flush(Evas_GL_Context *gc)
break; break;
} }
} }
if (gc->shader.blend != gc->shader.current.blend)
{
if (gc->shader.blend)
glEnable(GL_BLEND);
else
glDisable(GL_BLEND);
}
if (gc->shader.smooth != gc->shader.current.smooth) if (gc->shader.smooth != gc->shader.current.smooth)
{ {
if (gc->shader.smooth) if (gc->shader.smooth)