ComponentOne PdfViewer for WPF and Silverlight
C1.WPF.PdfViewer.4.6.2 Assembly / CSJ2K.j2k.entropy.decoder Namespace
Inheritance Hierarchy
In This Topic
    CSJ2K.j2k.entropy.decoder Namespace
    In This Topic
    Classes
     ClassDescription
    ClassThis class provides a byte input facility from byte buffers. It is similar to the ByteArrayInputStream class, but adds the possibility to add data to the stream after the creation of the object.

    Unlike the ByteArrayInputStream this class is not thread safe (i.e. no two threads can use the same object at the same time, but different objects may be used in different threads).

    This class can modify the contents of the buffer given to the constructor, when the addByteArray() method is called.

    ClassThis class provides an adapter to perform bit based input on byte based output obejcts that inherit from a 'ByteInputBuffer' class. This class also performs the bit unstuffing procedure specified for the 'selective arithmetic coding bypass' mode of the JPEG 2000 entropy coder.
    ClassThis class stores coded (compressed) code-blocks that are organized in layers. This object can contain either all code-block data (i.e. all layers), or a subset of all the layers that make up the whole compressed code-block. It is applicable to the decoder engine only. Some data of the coded-block is stored in the super class, see CodedCBlk.

    A code-block may have its progressive attribute set (i.e. the 'prog' flag is true). If a code-block is progressive then it means that more data for it may be obtained for an improved quality. If the progressive flag is false then no more data is available from the source for this code-block.

    Class 
    ClassThis class implements the MQ arithmetic decoder. It is implemented using the software conventions decoder for better performance (i.e. execution time performance). The initial states for each context of the MQ-coder are specified in the constructor.
    ClassThis class implements the JPEG 2000 entropy decoder, which codes stripes in code-blocks. This entropy decoding engine decodes one code-block at a time.

    The code-blocks are rectangular and their dimensions must be powers of 2. Each dimension cannot be smaller than 4 and larger than 256. The product of the two dimensions (i.e. area of the code-block) cannot exceed 4096.

    Context 0 of the MQ-coder is used as the uniform one (uniform, non-adaptive probability distribution). Context 1 is used for RLC coding. Contexts 2-10 are used for zero-coding (ZC), contexts 11-15 are used for sign-coding (SC) and contexts 16-18 are used for magnitude-refinement (MR).

    This implementation also provides some timing features. They can be enabled by setting the 'DO_TIMING' constant of this class to true and recompiling. The timing uses the 'System.currentTimeMillis()' Java API call, which returns wall clock time, not the actual CPU time used. The timing results will be printed on the message output. Since the times reported are wall clock times and not CPU usage times they can not be added to find the total used time (i.e. some time might be counted in several places). When timing is disabled ('DO_TIMING' is false) there is no penalty if the compiler performs some basic optimizations. Even if not the penalty should be negligeable.

    Interfaces
     InterfaceDescription
    InterfaceThis interface defines a source of entropy coded data and methods to transfer it in a code-block by code-block basis. In each call to 'geCodeBlock()' a specified coded code-block is returned.

    This interface is the source of data for the entropy decoder. See the 'EntropyDecoder' class.

    For each coded-code-block the entropy-coded data is returned along with its truncation point information in a 'DecLyrdCBlk' object.

    See Also