Implementing JPEG 2000 Plug in Features
JPEG 2000 is a wavelet-based compression stored in a hierarchical format, which contains several stored resolutions of the image in the same bit-stream without duplication. For that reason, a JPEG 2000 compressed image can then be sent to a device in the resolution that best fits, without additional storage overhead.
The LEADTOOLS JPEG 2000 Plug in provides support for encoding and decoding a JPEG 2000 bit-stream. The JPEG 2000 compression provides greater flexibility and better image quality, especially at higher compression ratios, than standard JPEG. The greater flexibility includes the ability to control:
whether or not to transform RGB images to YUV prior to compression
the type of quantization to use when determining the quantization step size
the amount of compression
the size and location of tiles
the number of resolution levels in the bit-stream
the progression order
the code block height and width
whether to use markers to help detect corruption during transmission
etc.
LEADTOOLS provides several options for controlling the JPEG 2000 features listed above. You can access these options through the J2KOptions object (property), which has the following properties (attributes):
J2KCBS_ErrorResilienceSymbol property
J2KCBS_PredictableTermination property
J2KCBS_ResetContextOnBoundaries property
J2KCBS_SelectiveACBypass property
J2KCBS_TerminationOnEachPass property
J2KCBS_VerticallyCausalContext property
J2KCompressionControl property
J2KDerivedBaseExponent property
J2KDerivedBaseMantissa property
J2KDerivedQuantization property
To update the properties listed above with the default JPEG 2000 compression options, call the J2KSetDefaults method. To change the JPEG 2000 features, set the properties themselves.
A region of interest can now be used for a J2K-compressed image. The J2KUseROI property indicates whether or not to use a region of interest. If this is TRUE, then the region of interest is defined based on the J2KROIControl property. If the J2KUseROI property is TRUE and the J2KROIControl property is set to J2K_USELEAD_REGION, then the region of interest is designated by the LEAD bitmap region. If the J2KUseROI property is TRUE and the J2KROIControl property is set to J2K_USEOPTION_RECT, then the region of interest is designated by the rectangle defined by the J2KROILeft, J2KROITop, J2KROIHeight, and J2KROIWidth properties.
This support is available only in the LEADTOOLS JPEG 2000 Plug in, and must be unlocked. For more information on unlocking this support, refer to JPEG 2000 Plug In Support Instructions.