How to save JPG file to array for reuse #989
Answered
by
Bodmer
LarsMachiels
asked this question in
Q&A - General
-
I am trying to figure out how I can save a JPG from ESP32 SPIFFS into an array so I can reuse it without reloading. |
Beta Was this translation helpful? Give feedback.
Answered by
Bodmer
Feb 10, 2021
Replies: 1 comment
-
The header comments here tell you how to convert a file into an array and then it can be kept in FLASH instead of SPIFFS. Typically Jpeg files are highly compressed and most processors do not have the space to store large decompressed image arrays. Another approach is to avoid an array and render the jpeg into a sprite, then save the meory block. |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
Bodmer
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The header comments here tell you how to convert a file into an array and then it can be kept in FLASH instead of SPIFFS.
Typically Jpeg files are highly compressed and most processors do not have the space to store large decompressed image arrays.
Another approach is to avoid an array and render the jpeg into a sprite, then save the meory block.