Skip to content
This repository has been archived by the owner on May 13, 2024. It is now read-only.

Commit

Permalink
Remove mistaken code block from OGLES1 driver
Browse files Browse the repository at this point in the history
Version can never be 200 here, this was probably mistakenly copy-pasted from the OpenGL driver.
  • Loading branch information
sfan5 committed Feb 17, 2024
1 parent 6ba6118 commit ad96fab
Showing 1 changed file with 1 addition and 27 deletions.
28 changes: 1 addition & 27 deletions source/Irrlicht/COGLESDriver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1872,33 +1872,7 @@ void COGLES1Driver::setTextureRenderStates(const SMaterial& material, bool reset
if (resetAllRenderstates)
statesCache.IsCached = false;

#ifdef GL_VERSION_2_1
if (Version >= 210)
{
if (!statesCache.IsCached || material.TextureLayers[i].LODBias != statesCache.LODBias)
{
if (material.TextureLayers[i].LODBias)
{
const float tmp = core::clamp(material.TextureLayers[i].LODBias * 0.125f, -MaxTextureLODBias, MaxTextureLODBias);
glTexParameterf(tmpTextureType, GL_TEXTURE_LOD_BIAS, tmp);
}
else
glTexParameterf(tmpTextureType, GL_TEXTURE_LOD_BIAS, 0.f);

statesCache.LODBias = material.TextureLayers[i].LODBias;
}
}
else if (FeatureAvailable[IRR_EXT_texture_lod_bias])
{
if (material.TextureLayers[i].LODBias)
{
const float tmp = core::clamp(material.TextureLayers[i].LODBias * 0.125f, -MaxTextureLODBias, MaxTextureLODBias);
glTexEnvf(GL_TEXTURE_FILTER_CONTROL_EXT, GL_TEXTURE_LOD_BIAS_EXT, tmp);
}
else
glTexEnvf(GL_TEXTURE_FILTER_CONTROL_EXT, GL_TEXTURE_LOD_BIAS_EXT, 0.f);
}
#elif defined(GL_EXT_texture_lod_bias)
#if defined(GL_EXT_texture_lod_bias)
if (FeatureAvailable[COGLESCoreExtensionHandler::IRR_GL_EXT_texture_lod_bias])
{
if (material.TextureLayers[i].LODBias)
Expand Down

0 comments on commit ad96fab

Please sign in to comment.