Set blendfunc when calling draw2DImageFromRTT.

This commit is contained in:
Vincent Lejeune 2014-06-23 14:46:02 +02:00
parent d5e1bb6631
commit 1a8b35c796

View File

@ -781,7 +781,11 @@ void draw2DImageFromRTT(GLuint texture, size_t texture_w, size_t texture_h,
const core::rect<s32>& sourceRect, const core::rect<s32>* clipRect,
bool useAlphaChannelOfTexture)
{
glEnable(GL_BLEND);
if (useAlphaChannelOfTexture)
{
glEnable(GL_BLEND);
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
}
float width, height,
center_pos_x, center_pos_y,
tex_width, tex_height,