Add texture size fields to terrain textures and improve editor performance

This commit is contained in:
Lukas Aldershaab 2021-01-02 18:33:15 +01:00
parent 9caa08b7f0
commit d3996aec84
7 changed files with 414 additions and 44 deletions

View file

@ -894,7 +894,7 @@ Torque::Path GFXTextureManager::validatePath(const Torque::Path &path)
return correctPath;
}
GBitmap *GFXTextureManager::loadUncompressedTexture(const Torque::Path &path, GFXTextureProfile *profile, U32 width, U32 height)
GBitmap *GFXTextureManager::loadUncompressedTexture(const Torque::Path &path, GFXTextureProfile *profile, U32 width, U32 height, bool genMips)
{
GBitmap* inBitmap = loadUncompressedTexture(path, &GFXTexturePersistentProfile);
@ -927,6 +927,9 @@ GBitmap *GFXTextureManager::loadUncompressedTexture(const Torque::Path &path, GF
}
}
if (genMips)
outBmp->extrudeMipLevels();
return outBmp;
}