fix: backend: switch fp16/fp32 shader order
Some checks failed
(CI) lsfg-vk / build (push) Has been cancelled
(CI/Flatpak) lsfg-vk / flatpak-extensions (23.08) (push) Has been cancelled
(CI/Flatpak) lsfg-vk / flatpak-extensions (24.08) (push) Has been cancelled
(CI/Flatpak) lsfg-vk / flatpak-extensions (25.08) (push) Has been cancelled
(CI/Flatpak) lsfg-vk / flatpak-ui (push) Has been cancelled

shader order was swapped, causing fp16 to be used when fp32 was requested and vice versa.
This commit is contained in:
PancakeTAS 2026-01-31 18:53:25 +01:00
parent 14904b9f3d
commit d9cdcf8ba7
No known key found for this signature in database

View file

@ -21,11 +21,11 @@ namespace {
const std::unordered_map<uint32_t, std::vector<uint8_t>>& resources) {
const size_t BASE_OFFSET = 49;
const size_t OFFSET_PERF = 23;
const size_t OFFSET_FP16 = 49;
const size_t OFFSET_FP32 = 49;
auto it = resources.find(BASE_OFFSET + id +
(perf ? OFFSET_PERF : 0) +
(fp16 ? OFFSET_FP16 : 0));
(fp16 ? 0 : OFFSET_FP32));
if (it == resources.end())
throw ls::error("unable to find shader with id: " + std::to_string(id));