2

What is the difference?

As far as i know, compressed textures would speed things up, because the PCIe bus has to transfer less amount of data, and the interconnect is the main latency issue with GPU's. For this i'm certain.

What i'm not sure of, and this is what i mainly want an answer to is, does the GPU decompress the textures on the fly, or does it display the uncompressed textures? In other words, is there any visual impact of using the compressed textures? The GPU decompresses them automatically? Does this vary with the compression algorithm used, or is it a GPU specific thing?

Thanks in advance.

KeyC0de
  • 130
  • 1
  • 3
  • 10

1 Answers1

5

All GPU texture compressions are lossy. There is a slight degradation in image quality that may or may not be noticeable depending on what is in the texture.

The compressed textures are stored compressed in memory (both CPU and GPU memory) and decompressed on the fly during texture lookups. This reduces both the memory requirement on the GPU and increases texel lookup rate by reducing memory bandwidth requirement.

Depending on the GPU it can also increase texture cache efficiency as less cache is used per texel when the texture is held compressed into the GPU texture (and/or unified) cache.

The entire texture does not get decompressed to RAM when used. It remains compressed in memory. The GPU reads the compressed texture itself (through its texture samplers).

In practice the impact on the PCIe (or other) bus is minimal as textures are rarely transfered between CPU memory and GPU memory. It's on the GPU's RAM bus during texture lookups that the big difference happens. This also applies to unified memory integrated GPUs.

In some cases when the hardware does not support the compression the texture will be converted by the driver (CPU) to either another compressed format or uncompressed. In other cases the texture won't be supported at all but generally game engines take care of this for you.

Stephane Hockenhull
  • 11,962
  • 1
  • 25
  • 44