After fixing #174 in my application code, I saw that Compressonator was failing on error code 28 CMP_ERR_GENERIC on saving the destination texture. I looked into the code and SaveTexture returns this error code when the IMAGE plugin responsible for saving the particular image format is not available.
It turns out that CMP_InitFramework adds a IMAGE plugin for DDS files; Compressonator application code adds plugins manually for ASTC, EXR, KTX, KTX2, and more formats. To register these plugins myself, I have to include internal header files (application/_plugins/common/pluginmanager.h) which is not good.
I think there are two solutions:
Document that you have to register these plugins manually and add them to compressonator.h so developers don't have to access internal header files.
Register these plugins automatically in CMP_InitFramework. I think this one is better.
After fixing #174 in my application code, I saw that Compressonator was failing on error code 28
CMP_ERR_GENERIC
on saving the destination texture. I looked into the code andSaveTexture
returns this error code when the IMAGE plugin responsible for saving the particular image format is not available.It turns out that
CMP_InitFramework
adds a IMAGE plugin for DDS files; Compressonator application code adds plugins manually for ASTC, EXR, KTX, KTX2, and more formats. To register these plugins myself, I have to include internal header files (application/_plugins/common/pluginmanager.h) which is not good.I think there are two solutions:
compressonator.h
so developers don't have to access internal header files.CMP_InitFramework
. I think this one is better.