libspng icon indicating copy to clipboard operation
libspng copied to clipboard

libpng transform translation API

Open randy408 opened this issue 4 years ago • 0 comments

libpng has transform functions that change the image's final output format, the interaction between these transforms and the PNG's bit depth, format and meta-data is complicated and is difficult to translate to libspng formats and flags, consider creating an API that abstracts away this complexity:

enum spng_transforms
{
    SPNG_XFORM_EXPAND_GRAY_1_2_4_TO_8,
    SPNG_XFORM_TRNS_TO_ALPHA
};

int spng_apply_transform(spng_ctx*, int xform, int *fmt, int *flags);

randy408 avatar Jun 11 '20 13:06 randy408