Logan Shaw wrote:
Anyway, if the memory space is really a concern, the simplest solution
is going to be to decode the JPEG in bands, then write each band
into the final 8-bit bitmap. For example, if you are decoding something
that's 320x320, create a 320x320 8-bit bitmap, then decode the first
80 rows of the JPEG into the temporary 16-bit bitmap. (I'm assuming
pnoJpegLib can do clipping as it decodes...) Then, fill in the first
80 rows of the 8-bit bitmap. Then repeat four times. By reducing the
number of rows in the band, you can make the extra memory overhead
arbitrarily small, or I should say arbitrarily close to the overhead
for a tiny image.
- Logan
Hi Logan,
thanks for the reply.
As it is very complicate to decode it and temporary memory is a problem
for low dynamic heap devices, the solution that I found is to split
large resources (320x320 in 2 of 160x320 for example) before use it.
regards
Erico
--
For information on using the PalmSource Developer Forums, or to unsubscribe,
please see http://www.palmos.com/dev/support/forums/