how to use compressed textures in Vulkan? Is it the same way as non-compressed textures with formats from one of compressed formats? If yes, when we copy data from memory to GPU, how do we calculate the size of image data? Lets say we have format as VK_FORMAT_ASTC_4x4_UNORM_BLOCK how do we get the size of data to be copied ?
Asked
Active
Viewed 1,060 times
-1
-
Your question is very broad. Vulkan's handling of compressed textures is reasonably well defined in the specification. It's not clear what part you're having problems with. – Nicol Bolas Dec 31 '16 at 14:04
-
@NicolBolas could you please point me to it? – debonair Jan 03 '17 at 03:03
-
The Vulkan specification is available on [the Vulkan registry](https://www.khronos.org/registry/vulkan/). – Nicol Bolas Jan 03 '17 at 03:52
1 Answers
0
For texel addressing the same way, except you should not cut into the block (i.e. should be in appropriate multiples in the given axis).
For byte addressing it is also quite obvious. The bit sizes are listed next to the formats in 32.3.1. Format Definition chapter.
E.g. image copy command uses texel addressing. For VK_FORMAT_ASTC_4x4_UNORM_BLOCK
it would be the same as for any uncompressed format except the width and height offset and size must be a multiple of 4.

krOoze
- 12,301
- 1
- 20
- 34
-
Can you give me some reference links? I am not very much clear about data uploads in VKimage – debonair Jan 04 '17 at 01:42