Package jj2000.j2k.codestream.reader
Class CBlkInfo
- java.lang.Object
-
- jj2000.j2k.codestream.reader.CBlkInfo
-
public class CBlkInfo extends Object
This class contains location of code-blocks' piece of codewords (there is one piece per layer) and some other information.
-
-
Field Summary
Fields Modifier and Type Field Description int
ctp
The cumulative number of truncation pointsint
h
Height of the code-blockint[]
len
Length of each piece of code-block's codewordsint
msbSkipped
The number of most significant bits which are skipped for this code-block (= Mb-1-bitDepth).int[]
ntp
The number of truncation point for each layerint[]
off
Offset of each piece of code-block's codewords in the fileint[]
pktIdx
Index of the packet where each layer has been foundint[][]
segLen
The length of each segment (used with regular termination or in selective arithmetic bypass coding mode)int
ulx
Upper-left x-coordinate of the code-block (relative to the tile)int
uly
Upper-left y-coordinate of the code-block (relative to the tile)int
w
Width of the code-block
-
Constructor Summary
Constructors Constructor Description CBlkInfo(int ulx, int uly, int w, int h, int nl)
Constructs a new instance with specified number of layers and code-block coordinates.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addNTP(int l, int newtp)
Adds the number of new truncation for specified layer.String
toString()
Object information in a string.
-
-
-
Field Detail
-
ulx
public int ulx
Upper-left x-coordinate of the code-block (relative to the tile)
-
uly
public int uly
Upper-left y-coordinate of the code-block (relative to the tile)
-
w
public int w
Width of the code-block
-
h
public int h
Height of the code-block
-
msbSkipped
public int msbSkipped
The number of most significant bits which are skipped for this code-block (= Mb-1-bitDepth). See VM text
-
len
public int[] len
Length of each piece of code-block's codewords
-
off
public int[] off
Offset of each piece of code-block's codewords in the file
-
ntp
public int[] ntp
The number of truncation point for each layer
-
ctp
public int ctp
The cumulative number of truncation points
-
segLen
public int[][] segLen
The length of each segment (used with regular termination or in selective arithmetic bypass coding mode)
-
pktIdx
public int[] pktIdx
Index of the packet where each layer has been found
-
-
Constructor Detail
-
CBlkInfo
public CBlkInfo(int ulx, int uly, int w, int h, int nl)
Constructs a new instance with specified number of layers and code-block coordinates. The number corresponds to the maximum piece of codeword for one code-block.- Parameters:
ulx
- The uper-left x-coordinateuly
- The uper-left y-coordinatew
- Width of the code-blockh
- Height of the code-blocknl
- The number of layers
-
-