mirror of
https://github.com/love2d/love.git
synced 2026-08-18 11:44:15 +02:00
remove some dead code
This commit is contained in:
@@ -369,11 +369,8 @@ bool Texture::loadVolatile()
|
||||
if (isReadable())
|
||||
createTexture();
|
||||
|
||||
if (!usingDefaultTexture && framebufferStatus == GL_FRAMEBUFFER_COMPLETE
|
||||
&& (!isReadable() || actualSamples > 1))
|
||||
{
|
||||
if (framebufferStatus == GL_FRAMEBUFFER_COMPLETE && (!isReadable() || actualSamples > 1))
|
||||
framebufferStatus = newRenderbuffer(pixelWidth, pixelHeight, actualSamples, format, renderbuffer);
|
||||
}
|
||||
|
||||
textureGLError = glGetError();
|
||||
|
||||
@@ -403,7 +400,6 @@ bool Texture::loadVolatile()
|
||||
|
||||
setGraphicsMemorySize(memsize);
|
||||
|
||||
usingDefaultTexture = false;
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -575,13 +571,6 @@ void Texture::setSamplerState(const SamplerState &s)
|
||||
samplerState.mipmapFilter = SamplerState::MIPMAP_FILTER_NEAREST;
|
||||
}
|
||||
|
||||
// We don't want filtering or (attempted) mipmaps on the default texture.
|
||||
if (usingDefaultTexture)
|
||||
{
|
||||
samplerState.mipmapFilter = SamplerState::MIPMAP_FILTER_NONE;
|
||||
samplerState.minFilter = samplerState.magFilter = SamplerState::FILTER_NEAREST;
|
||||
}
|
||||
|
||||
// If we only have limited NPOT support then the wrap mode must be CLAMP.
|
||||
if ((GLAD_ES_VERSION_2_0 && !(GLAD_ES_VERSION_3_0 || GLAD_OES_texture_npot))
|
||||
&& (pixelWidth != nextP2(pixelWidth) || pixelHeight != nextP2(pixelHeight) || depth != nextP2(depth)))
|
||||
|
||||
Reference in New Issue
Block a user