17
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-11-09 02:50:59 +01:00

Map BC7 (BPTC) dds textures to native VK_FORMAT_BC7 in the Vulkan renderer

This commit is contained in:
2026-10-31 16:46:35 +01:00
parent 7078edf138
commit 75cb88f275
3 changed files with 16 additions and 7 deletions

View File

@@ -20,6 +20,15 @@ http://mozilla.org/MPL/2.0/.
#include "gl/ubo.h"
#include "interfaces/ITexture.h"
// BC7, core since GL 4.2 (ARB_texture_compression_bptc), the bundled glad is generated for 3.3. data_format of BC7 dds files,
// which the vulkan renderer maps too
#ifndef GL_COMPRESSED_RGBA_BPTC_UNORM
#define GL_COMPRESSED_RGBA_BPTC_UNORM 0x8E8C
#endif
#ifndef GL_COMPRESSED_SRGB_ALPHA_BPTC_UNORM
#define GL_COMPRESSED_SRGB_ALPHA_BPTC_UNORM 0x8E8D
#endif
struct texture_request; // texture data read by a worker thread, with gfx.textures.streaming
// a texture as its file gives it, whichever api draws it: read and decoded (dds, tga, png, bmp, jpg, ktx, tex), with the mipmaps