Key takeaways
- Mipmaps add roughly one third more memory
- Compressed formats often require POT
- Move size validation to export time
A 2048×2048 RGBA texture takes 16 MB, and mipmaps add roughly a third more. With many textures, memory and bandwidth become the bottleneck before frame rate does. Mipmaps and size limits are not optional polish; they are constraints to verify before shipping.
What mipmaps solve
When a texture is displayed smaller than its resolution, sampling frequency exceeds pixel frequency, producing moire and shimmer. Mipmaps pre-generate halved copies and pick a level by distance, reducing shimmer and bandwidth.
The cost is about 33% more memory, plus edge handling when generating. UI sprites, text and small images that must stay crisp usually disable mipmaps; large surfaces in 3D scenes usually enable them.
POT versus NPOT
Power-of-two dimensions are mandatory on older hardware and for some compressed formats. Mobile compressed textures such as ETC2 and ASTC relate closely to POT block layout, and some platforms require POT for mip generation. Even where NPOT works, target the strictest platform you ship to.
- Mobile: 2048 or 4096 max dimension is common, and compression often requires POT.
- Desktop: higher limits, NPOT generally fine.
- WebGL: device and driver dependent; 2048 is the safer ceiling.
Estimating memory
The rough formula is width × height × bytes per pixel. RGBA8 is 4 bytes, RGB565 is 2, single channel is 1. Multiply by about 1.33 with mipmaps. Doing the math up front is cheaper than discovering an out-of-memory crash on device.
Move validation earlier
The best time to catch an oversized texture is at export, not when packaging an APK or importing into the engine. TexForge validates dimensions, POT and maximum size against the target platform while building mipmaps and atlases, and flags violations.
If an error can be reported at export time, do not save it for device testing.
Practical advice
- Set the size ceiling by your lowest-end target platform; others inherit it.
- Disable mipmaps for UI and text, enable them for 3D scene textures.
- Decide compression format and POT together, not separately.
- Estimate total memory before a large batch to confirm devices can handle it.
Takeaway
Mipmaps and size limits are a trade-off between sharpness, memory and compatibility. Write them into platform specs and let the tool validate at export — far more reliable than memory and post-hoc debugging.