setting texture mode when blending
git-svn-id: svn://anubis/anaglym/trunk@314 99a6e188-d820-4881-8870-2d33a10e2619
This commit is contained in:
parent
9ea65f4e65
commit
3e3ba194f9
@ -1426,13 +1426,14 @@ void Engine::Object::render()
|
||||
int attrib_flags = GL_ENABLE_BIT;
|
||||
if (m_enable_blending)
|
||||
{
|
||||
attrib_flags |= GL_COLOR_BUFFER_BIT;
|
||||
attrib_flags |= GL_COLOR_BUFFER_BIT | GL_TEXTURE_BIT;
|
||||
}
|
||||
glPushAttrib(attrib_flags);
|
||||
if (m_enable_blending)
|
||||
{
|
||||
glEnable(GL_BLEND);
|
||||
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
|
||||
glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_REPLACE);
|
||||
}
|
||||
if (m_texture != 0)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user