parent
e6615d640d
commit
e8072e0eb0
|
@ -783,7 +783,10 @@ static void BeginRenderPoly()
|
||||||
xglPolygonMode (GL_FRONT_AND_BACK, GL_LINE);
|
xglPolygonMode (GL_FRONT_AND_BACK, GL_LINE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (gfx3d.renderState.enableTexturing)
|
||||||
|
{
|
||||||
setTexture(textureFormat, texturePalette);
|
setTexture(textureFormat, texturePalette);
|
||||||
|
}
|
||||||
|
|
||||||
if(isTranslucent)
|
if(isTranslucent)
|
||||||
enableDepthWrite = alphaDepthWrite;
|
enableDepthWrite = alphaDepthWrite;
|
||||||
|
@ -879,8 +882,28 @@ static void InstallPolygonAttrib(u32 val)
|
||||||
|
|
||||||
static void Control()
|
static void Control()
|
||||||
{
|
{
|
||||||
if(gfx3d.renderState.enableTexturing) glEnable (GL_TEXTURE_2D);
|
if (gfx3d.renderState.enableTexturing)
|
||||||
else glDisable (GL_TEXTURE_2D);
|
{
|
||||||
|
if (hasShaders)
|
||||||
|
{
|
||||||
|
glUniform1i(hasTexLoc, 1);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
glEnable(GL_TEXTURE_2D);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (hasShaders)
|
||||||
|
{
|
||||||
|
glUniform1i(hasTexLoc, 0);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
glDisable(GL_TEXTURE_2D);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if(gfx3d.renderState.enableAlphaTest)
|
if(gfx3d.renderState.enableAlphaTest)
|
||||||
// FIXME: alpha test should pass gfx3d.alphaTestRef==poly->getAlpha
|
// FIXME: alpha test should pass gfx3d.alphaTestRef==poly->getAlpha
|
||||||
|
|
Loading…
Reference in New Issue