[]
This class places an image in the canvas coordinate system, tiles it, if so specified, and performs the coordinate conversions transparently. The source must be a 'BlkImgDataSrc' which is not tiled and has a the image origin at the canvas origin (i.e. it is not "canvased"), or an exception is thrown by the constructor. A tiled and "canvased" output is given through the 'BlkImgDataSrc' interface. See the 'ImgData' interface for a description of the canvas and tiling.
<p>All tiles produced are rectangular, non-overlapping and their union
covers all the image. However, the tiling may not be uniform, depending on
the nominal tile size, tiling origin, component subsampling and other
factors. Therefore it might not be assumed that all tiles are of the same
width and height.</p><p>The nominal dimension of the tiles is the maximal one, in the reference
grid. All the components of the image have the same number of tiles.</p>
public class Tiler : ImgDataAdapter, BlkImgDataSrc, ImgData
Name | Description |
---|---|
Tiler(BlkImgDataSrc, int, int, int, int, int, int) |
Name | Description |
---|---|
ImgULX | Returns the horizontal coordinate of the image origin, the top-left corner, in the canvas system, on the reference grid. |
ImgULY | Returns the vertical coordinate of the image origin, the top-left corner, in the canvas system, on the reference grid. |
NomTileHeight | Returns the nominal width of the tiles in the reference grid. |
NomTileWidth | Returns the nominal width of the tiles in the reference grid. |
TileHeight | Returns the overall height of the current tile in pixels. This is the tile's width without accounting for any component subsampling. |
TileIdx | Returns the index of the current tile, relative to a standard scan-line order. |
TilePartULX | Returns the horizontal tile partition offset in the reference grid |
TilePartULY | Returns the vertical tile partition offset in the reference grid |
TileWidth | Returns the overall width of the current tile in pixels. This is the tile's width without accounting for any component subsampling. |
Name | Description |
---|---|
ToString() | Returns a String object representing Tiler's informations |
getCompData(DataBlk, int) | Returns, in the blk argument, a block of image data containing the specifed rectangular area, in the specified component. The data is returned, as a copy of the internal data, therefore the returned data can be modified "in place".
|
getCompULX(int) | Returns the horizontal coordinate of the upper-left corner of the specified component in the current tile. |
getCompULY(int) | Returns the vertical coordinate of the upper-left corner of the specified component in the current tile. |
getFixedPoint(int) | Returns the position of the fixed point in the specified component. This is the position of the least significant integral (i.e. non-fractional) bit, which is equivalent to the number of fractional bits. For instance, for fixed-point values with 2 fractional bits, 2 is returned. For floating-point data this value does not apply and 0 should be returned. Position 0 is the position of the least significant bit in the data. |
getInternCompData(DataBlk, int) | Returns, in the blk argument, a block of image data containing the specifed rectangular area, in the specified component. The data is returned, as a reference to the internal data, if any, instead of as a copy, therefore the returned data should not be modified.
|
getNumTiles() | Returns the total number of tiles in the image. |
getNumTiles(Coord) | Returns the number of tiles in the horizontal and vertical directions. |
getTile(Coord) | Returns the horizontal and vertical indexes of the current tile. |
getTileCompHeight(int, int) | Returns the height in pixels of the specified tile-component. |
getTileCompWidth(int, int) | Returns the width in pixels of the specified tile-component. |
getTilingOrigin(Coord) | Returns the tiling origin, referred to as '(xt0siz,yt0siz)' in the codestream header (SIZ marker segment). |
nextTile() | Advances to the next tile, in standard scan-line order (by rows then columns). An NoNextElementException is thrown if the current tile is the last one (i.e. there is no next tile). |
setTile(int, int) | Changes the current tile, given the new tile indexes. An IllegalArgumentException is thrown if the coordinates do not correspond to a valid tile. |