What’s up everyone,
I’m making an art gallery using react-three-fiber. The gallery has 30 image textures in it and on mobile the textures take up too much vram, so I’m trying to compress them using either ktx or basis. I’m using the useLoader hook from r3f and my code currently looks like this but the issue is I’m only seeing black textures.
The texture in the third image is a .ktx texture and the console gives me the following warning “only compressed formats currently supported”
I’m compressing my textures using this repo
I looked over the documentation here Khronos Texture Tools: toktx but all of the compression methods they have produce a .ktx2 file instead of a .ktx file.
This has lead to a whole other problem entirely b/c though I can load ktx2 files on desktop with improved performance, they take way too long to load on mobile. I’ve also made sure to resize the textures to be powers of 2, which was what I had wrong at first with .ktx2 files.
I’m still new to this and I’m not really sure which problem I should be trying to tackle. Thanks for taking the time to read this and any pointers are welcome