ComponentOne PdfViewer for WPF and Silverlight
C1.WPF.PdfViewer.4.6.2 Assembly / CSJ2K.j2k.codestream.reader Namespace
Inheritance Hierarchy
In This Topic
    CSJ2K.j2k.codestream.reader Namespace
    In This Topic
    Classes
     ClassDescription
    ClassThis is the generic interface for bit stream reader agents. A bit stream reader agent is an entity that allows reading from a bit stream and requesting compressed code-blocks. It can be a simple file reader, or a network connection, or anything else.

    The bit stream reader agent allows to make request for compressed block data in any order. The amount of data returned would normally depend on the data available at the time of the request, be it from a file or from a network connection.

    The bit stream reader agent has the notion of a current tile, and coordinates are relative to the current tile, where applicable.

    Resolution level 0 is the lowest resolution level, i.e. the LL subband alone.

    ClassThis class contains location of code-blocks' piece of codewords (there is one piece per layer) and some other information.
    ClassThis class reads the bit stream (with the help of HeaderDecoder for tile headers and PktDecoder for packets header and body) and retrives location of all code-block's codewords.

    Note: All tile-parts headers are read by the constructor whereas packets are processed when decoding related tile (when setTile method is called).

    In parsing mode, the reader simulates a virtual layer-resolution progressive bit stream with the same truncation points in each code-block, whereas in truncation mode, only the first bytes are taken into account (it behaves like if it is a real truncated codestream).

    ClassThis class reads main and tile-part headers from the codestream given a RandomAccessIO instance located at the beginning of the codestream (i.e just before the SOC marker) or at the beginning of a tile-part (i.e. just before a SOT marker segment) respectively.

    A marker segment includes a marker and eventually marker segment parameters. It is designed by the three letters code of the marker associated with the marker segment. JPEG 2000 part 1 defines 6 types of markers segments:

    • Delimiting : SOC, SOT, SOD, EOC
    • Fixed information: SIZ.
    • Functional: COD, COC, RGN, QCD, QCC,POC.
    • In bit-stream: SOP, EPH.
    • Pointer: TLM, PLM, PLT, PPM, PPT.
    • Informational: CRG, COM.

    The main header is read when the constructor is called whereas tile-part headers are read when the FileBitstreamReaderAgent instance is created. The reading is done in 2 passes:

    1. All marker segments are buffered and their corresponding flag is activated (extractMainMarkSeg and extractTilePartMarkSeg methods).
    2. Buffered marker segment are analyzed in a logical way and specifications are stored in appropriate member of DecoderSpecs instance (readFoundMainMarkSeg and readFoundTilePartMarkSeg methods).

    Whenever a marker segment is not recognized a warning message is displayed and its length parameter is used to skip it.

    The information found in this header is stored in HeaderInfo and DecoderSpecs instances.

    ClassThis class is used to read packet's head and body. All the members must be re-initialized at the beginning of each tile thanks to the restart() method.
    ClassThis class provides a bit based reading facility from a byte based one, applying the bit unstuffing procedure as required by the packet headers.
    ClassThis class defines an object used to countain informations about a packet to which the current code-block belongs.
    ClassThis class implements the tag tree decoder. A tag tree codes a 2D matrix of integer elements in an efficient way. The decoding procedure 'update()' updates a value of the matrix from a stream of coded data, given a threshold. This procedure decodes enough information to identify whether or not the value is greater than or equal to the threshold, and updates the value accordingly.

    In general the decoding procedure must follow the same sequence of elements and thresholds as the encoding one. The encoder is implemented by the TagTreeEncoder class.

    Tag trees that have one dimension, or both, as 0 are allowed for convenience. Of course no values can be set or coded in such cases.

    See Also