ADD: KTX loader completed

This commit is contained in:
2025-11-10 18:30:14 +09:00
parent 8f340ec08a
commit 50f1503f09
9 changed files with 152 additions and 320 deletions

View File

@@ -412,6 +412,7 @@ std::optional<std::shared_ptr<LoadedGLTF> > loadGltf(VulkanEngine *engine, std::
const bool hasSampler = tex.samplerIndex.has_value();
const VkSampler sampler = hasSampler ? file.samplers[tex.samplerIndex.value()] : engine->_samplerManager->defaultLinear();
auto key = buildTextureKey(imgIndex, false);
key.channels = TextureCache::TextureKey::ChannelsHint::RG; // prefer BC5 for normals
if (key.hash != 0)
{
hNorm = cache->request(key, sampler);