The CODBLOCKSTYLE structure provides a series of bit flags that indicate the behavior of the code blocks.
TRUE if the "lazy coding mode" is adopted. In this case, trailing bit-planes bypass the arithmetic coder except in the normalization pass. Otherwise, the arithmetic coder is used on all passes.
TRUE if the arithmetic coder's probability models are reset between coding passes. This controls where the end of encoded data is and limits the amount of potentially lost data in the event of a transmission error.
TRUE if the arithmetic code-word generation process stops on a byte boundary at the end of each coding pass.
TRUE if the context models are restricted to being vertically causal within each sub-block.
TRUE if the encoder has a predictable termination policy and identifies that the policy was used in the code-stream COD/COC markers. This can be used to implement error detection and concealment.
TRUE if a 4 symbol marker is included for each bit-plane, following the normalization pass.
Reserved for future use.
Arithmetic Encoder Settings (Advanced Users Only)
This style of coding allows bypassing the arithmetic coder for the significance propagation pass and magnitude refinement coding passes starting in the fifth significant bit-plane of the code-block. The first cleanup pass (which is the first bit-plane of a code-block with a non-zero element) and the next three sets of significance propagation, magnitude refinement, and cleanup coding passes are decoded with the arithmetic coder. The fourth cleanup pass includes an arithmetic coder termination.
This style of coding constrains the context formation to the current and past code-block scans (four rows of vertically scanned coefficients). That is, any coefficient from the next code-block scan is considered to be insignificant.
A segmentation symbol is a special symbol. The symbol is coded with the UNIFORM context of the arithmetic coder at the end of each bit-plane. The correct decoding of this symbol confirms the correctness of the decoding of this bit-plane, which allows error detection. At the decoder, a segmentation symbol 1010 or 0xA should be decoded at the end of each bit-plane (at the end of a cleanup pass). If the segmentation symbol is not decoded correctly, then bit errors occurred for this bit-plane.
Medical Web Viewer .NET
.NET, Java, Android, and iOS/macOS Assemblies
C API/C++ Class Libraries