~yosh@unix.dog

texture vram calculator

simple javascript tool to calculate the VRAM size of a texture given its dimensions, organized in a nice table by texture format, as I got annoyed doing this calculation manually all the time

the "real size" column is the size of the texture after block compression is done, which will round up to the nearest block size multiple. the "+mipmaps" column includes mipmaps that halve in size until both dimensions of the source image are 1.

you can use "k" as a suffix to multiply the input by 1024, e.g. 2k is 2048.

Format Real size VRAM +Mipmaps
Uncompressed RGB/RGBA
BC1, BC4
BC2, BC3, BC5, BC6, BC7
ETC1, ETC2 (RGB, R11 EAC)
ETC2 (RGBA, RG11 EAC)
ASTC 4x4
ASTC 5x4
ASTC 5x5
ASTC 6x5
ASTC 6x6
ASTC 8x5
ASTC 8x6
ASTC 8x8
ASTC 10x5
ASTC 10x6
ASTC 10x8
ASTC 10x10
ASTC 12x10
ASTC 12x12

notes:

for documentation on the various texture formats, there's...

of course, wikipedia has articles for S3TC, ETC, and ASTC, as well as some other texture compression formats, should you want to seek out more information via its references.

back