Loading textures from memory in PVRTexLib

Hey, I’m developing an application that needs to load multiple textures (mostly ktx1 or ktx2) in one big binary file that I load into memory and read.
I want to use PVRTexLib to get an uncompressed array of pixels but the problem is that API has only one constructor to load from memory and as constructor description says “Header may be any version of PVR.”. I assumed that constructor could only load pvr but still i tried to load ktx hoping for luck and i just got an error about a invalid data pointer.
I also looked at all examples, but none of them have anything that can relate to loading textures from memory.
As a workaround, I can save texture buffer to a temporary file and then read it, but this is not a very elegant way.

So, is there any way to load ktx file directly from memory using PVRTexLib?

Hi DaniilSV,

Welcome to PVR Developer Forum!

It would be good for us to test and investigate the issue if you share the code example you are trying with KTX textures.

Kindly raise a ticket on our internal support platform:
https://pvrsupport.imgtec.com

Regards,
Melih