Just use it

Why

The RGB565 format is useful for embedded systems, as many LCD displays utilize this format.

How

Essentially, use canvas to obtain the pixel data and convert it to RGB565.

Some of the code was provided by Bing, powered by GPT, although I made some modifications to ensure it works properly.

The result is in little-endian format.