Closed mrcodetastic closed 3 years ago
There are internal functions to do what you want (JPEGInit, JPEGParseInfo), but the best way is to close and reopen the file. It didn't occur to me that anyone would want to decode the same file again without re-opening it because you already have the pixel data. I suppose I could add a "JPEGRewind" function to do what you want. If you're repeatedly working with small icons, why not keep them in RAM? The JPEG decoder structure needs about 17.5K. Do you have RAM to spare?
Hi Larry. No need to do any further work on the library! I've actually decided to use the excellent animated GIF decoder instead, so problem solved :-)
Hi Larry,
Fantastic library I must say.
I was testing this decoding some small icons, and I noticed that if I call decode twice (or more) then I get garbage. I want to do this in order to duplicate a jpg in my display output (long story).
The colors get screwed up more and more with each subsequent decode. Is this expected behaviour?
Example pseudocode:
I don't particulary want to open and close the jpg decoder file stream each time etc.