Don't trust the file extension when loading icons

Fixes #439
This commit is contained in:
Guillaume Meunier
2025-08-18 21:16:08 +02:00
parent 94aceb3f0f
commit c2f23223a2
3 changed files with 337 additions and 346 deletions
+10 -2
View File
@@ -23,5 +23,13 @@
namespace wivrn
{
const std::vector<std::byte> & load_icon(const std::filesystem::path & filename, int size);
}
struct icon
{
int width;
int height;
int bpp;
std::vector<std::byte> png_data;
};
const std::vector<icon> & load_icon(const std::filesystem::path & filename);
} // namespace wivrn