mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-14 16:14:38 +00:00
skip mip calculation for non pow2 textures if it's not for a rendertarget
This commit is contained in:
parent
7aa4ea75a6
commit
7fcdd03b50
1 changed files with 1 additions and 1 deletions
|
|
@ -1418,7 +1418,7 @@ void GFXTextureManager::_validateTexParams( const U32 width, const U32 height,
|
||||||
{
|
{
|
||||||
// If a texture is not power-of-2 in size for both dimensions, it must
|
// If a texture is not power-of-2 in size for both dimensions, it must
|
||||||
// have only 1 mip level.
|
// have only 1 mip level.
|
||||||
inOutNumMips = mFloor(mLog2(mMax(width, height))) + 1;
|
inOutNumMips = profile->isRenderTarget() ? mFloor(mLog2(mMax(width, height))) + 1 : 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check format, and compatibility with texture profile requirements
|
// Check format, and compatibility with texture profile requirements
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue