Skip to content

MTY_DecompressImage

chrisd1100 edited this page Aug 25, 2022 · 1 revision

Decompress an image into RGBA.

void *MTY_DecompressImage(
    const void * input,
    size_t       size,
    uint32_t *   width,
    uint32_t *   height
);

Parameters

input (const void *)

The compressed image data.

size (size_t)

The size in bytes of input.

width (uint32_t *)

Set to the width of the returned buffer.

height (uint32_t *)

Set to the height of the returned buffer.

Return value

void *

The size of the returned buffer can be calculated as width * height * 4.

On failure, NULL is returned. Call MTY_GetLog for details.

The returned buffer must be destroyed with MTY_Free.

Platform support

Windows   macOS   Android   Linux   Web  

See also

Module: Image

Clone this wiki locally