darksylinc / betsy

Betsy GPU compressor
Other
314 stars 18 forks source link

Can't output a texture on windows 10 #4

Closed fire closed 3 years ago

fire commented 3 years ago
.\betsy.exe .\50496585556_94b95fd9d4_o.jpg --codec=etc2_rgba "put.ktx"
Initializing API
GL Context creation suceeded.
Could not save to 'α♦p♣ú☻' Check write access and whether the disk is full
Shutting down

Can't output a texture on windows 10.

50496585556_94b95fd9d4_o

https://www.flickr.com/photos/studebakerbirds/50496585556/in/explore-2020-10-17/

darksylinc commented 3 years ago

Interesting. There seems to be some memory corruption going on.

It seems the cause is that the picture's resolution is not a multiple of 4 (a known limitation of ETC2).

Betsy should internally upscale the image from 3802x2517 to 3804x2520

darksylinc commented 3 years ago

It seems it was two bugs in one:

  1. Resolutions with non-multiple of 4 were broken.
  2. On Windows the command line parser was broken.

I'll be uploading a new binary release today

darksylinc commented 3 years ago

Done

Thanks for the report!

fire commented 3 years ago

This is not exactly the test case but it works on Fedora 33.

image

PS. Do you know how to open KTX files for BC5 and BC6?

darksylinc commented 3 years ago

Unfortunately I don't. Most viewers out there (all the ones I tried) are horribly working and only support a small subset of formats.

I gave up on that and debugged the output on RenderDoc (add '--renderdoc' to command line)