Bodmer / TJpg_Decoder

Jpeg decoder library based on Tiny JPEG Decompressor
Other
228 stars 43 forks source link

Saving bitmap from JPEG #75

Open ethaanlau opened 7 months ago

ethaanlau commented 7 months ago

Hi Bodmer,

I'm trying to use the TJpg_Decoder library to display a jpeg to a tft display. I have it working, but the only issue is that it's very slow (I'm using the Adafruit GFX library with the Adafruit RA8875 board). To speed up drawing, I want to save all pixel data in a bitmap so I can use the hardware accelerated function for the RA8875 to scan in pixels line by line instead of by block.

Is there a way to store the entire decoded JPEG data in an array?

Any help from others who have had similar issues would be greatly appreciated!

Bodmer commented 7 months ago

The simplest option is to load the image into an app such as MS Paint and save as a bmp file then convert to an array using an online tool.