15
User Display Interface
All color types are supported, although the appearance of the image will be dependent on the capabilities of the device's screen. Color types that include alpha channel data are supported; however, the implementation may ignore all alpha channel information and treat all pixels as opaque.
All bit depth values for the given color type are supported.
Compression method 0 (deflate) is the only supported compression method. This is the same compression method that is used for jar files, and so the decompression (inflate) code may be shared between the jar decoding and PNG decoding implementations.
The filter method represents a series of encoding schemes that may be used to optimize compression. The PNG spec currently defines a single filter method (method 0) that is an adaptive filtering scheme with five basic filter types. Filtering is essential for optimal compression since it allows the deflate algorithm to exploit spatial similarities within the image. Therefore, MIDP devices must support all five filter types defined by filter method 0.
MIDP devices are required to read PNG images that are encoded with either interlace method 0 (None) or interlace method 1 (Adam7). Image loading in MIDP is synchronous and cannot be overlapped with image rendering. There is no advantage for an application to use interlace method 1. Support for decoding interlaced images is required for compatibility with PNG and for the convenience of developers who may already have interlaced images available.
oThe PLTE chunk.
oThe IDAT chunk. Image data may be encoded using any of the 5 filter types defined by filter method 0 (None, Sub, Up, Average, Path).
oThe IEND chunk. This chunk must be found in order for the image to be considered valid.
oAncillary chunk support. PNG defines several 'ancillary' chunks that may be present in a PNG image but are not critical for image decoding. A MIDP implementation may (but is not required to) support any of these chunks. The implementation should silently ignore any unsupported ancillary chunks that it encounters. The defined ancillary chunks are:
bKGD cHRM gAMA hIST iCCP iTXt pHYs sBIT sPLT sRGB tEXt tIME tRNS zTXt
oAll MIDlets will be displayed in the ZOOM OUT mode. Once the MIDlet is exited, the handset will return to the user’s
66