[HW render] set known blending equation.

This commit is contained in:
Themaister 2014-04-17 15:32:36 +02:00
parent 37c8ea816c
commit f8d065eeb6
2 changed files with 11 additions and 0 deletions

View File

@ -1458,6 +1458,7 @@ static bool gl_frame(void *data, const void *frame, unsigned width, unsigned hei
glDisable(GL_DITHER);
glDisable(GL_BLEND);
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
glBlendEquation(GL_FUNC_ADD);
glClearColor(0.0f, 0.0f, 0.0f, 1.0f);
}
#endif
@ -2070,6 +2071,7 @@ static void *gl_init(const video_info_t *video, const input_driver_t **input, vo
#endif
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
glBlendEquation(GL_FUNC_ADD);
if (!resolve_extensions(gl))
{

View File

@ -3096,6 +3096,15 @@ GLAPI void APIENTRY glBlendFunc( GLenum sfactor, GLenum dfactor )
LContext->needValidate |= RGL_VALIDATE_BLENDING;
}
GLAPI void APIENTRY glBlendEquation( GLenum func )
{
RGLcontext* LContext = (RGLcontext*)_CurrentContext;
LContext->BlendEquationRGB = func;
LContext->BlendEquationAlpha = func;
LContext->needValidate |= RGL_VALIDATE_BLENDING;
}
/*============================================================
FRAMEBUFFER OBJECTS
============================================================ */