openplanet-nl / issues

Issue tracker for Openplanet.
10 stars 0 forks source link

Support .webp images #372

Open XertroV opened 11 months ago

XertroV commented 11 months ago

Seems like UI::LoadTexture doesn't support webp

codecat commented 11 months ago

Apparently, this will never come to stb_image:

Will you add more image types to stb_image.h?

No. As stb_image use has grown, it has become more important for us to focus on security of the codebase. Adding new image formats increases the amount of code we need to secure, so it is no longer worth adding new formats.

So if I were to implement this, I'd have to add another (potentially large) third party library.

XertroV commented 11 months ago

Hmm, yeah okay.

Have you seen https://sail.software/ btw? https://github.com/HappySeaFox/sail

Game devs are one of their target audiences, and sail seems to outperform stb (but maybe doesn't support some formats, or needs dependencies for them).

Not sure if it could selectively be added just for webp (and other missing formats mb)

XertroV commented 11 months ago

also, libwebp.dll is already loaded by the game it seems. So you probably don't need to add extra libraries if you import it.