TileManager Class Reference

Class to manage access to the tile cache and tile cropping. More...

`#include <TileManager.h>`

## Public Member Functions

| TileManager (Cache *tc, IIPImage *im, Watermark *w, Compressor *j, Logger *s, int l)
| Constructor.
RawTile | getTile (int resolution, int tile, int xangle, int yangle, int layers, CompressionType c)
| Get a tile from the cache.
RawTile | getRegion (unsigned int res, int xangle, int yangle, int layers, unsigned int x, unsigned int y, unsigned int w, unsigned int h)
| Generate a complete region.

## Detailed Description

Class to manage access to the tile cache and tile cropping.

## Constructor & Destructor Documentation

## TileManager()

TileManager::TileManager | ( | Cache * | tc,
|  | IIPImage * | im,
|  | Watermark * | w,
|  | Compressor * | j,
|  | Logger * | s,
|  | int | l )

inline

Constructor.

Parameters

  tc | pointer to tile cache object
  im | pointer to IIPImage object
  w | pointer to watermark object
  j | pointer to JPEGCompressor object
  s | pointer to output file stream
  l | logging level

## Member Function Documentation

## getRegion()

RawTile TileManager::getRegion | ( | unsigned int | res,
|  | int | xangle,
|  | int | yangle,
|  | int | layers,
|  | unsigned int | x,
|  | unsigned int | y,
|  | unsigned int | w,
|  | unsigned int | h )

Generate a complete region.

Build up an arbitrary region by extracting tiles from the cache by using getTile function. Data returned as uncompressed data.

Parameters

  res | resolution number
  xangle | horizontal sequence number
  yangle | vertical sequence number
  layers | number of quality layers within image to decode
  x | left offset with respect to full image
  y | top offset with respect to full image
  w | width of region requested
  h | height of region requested

Returns
  RawTile

## getTile()

RawTile TileManager::getTile | ( | int | resolution,
|  | int | tile,
|  | int | xangle,
|  | int | yangle,
|  | int | layers,
|  | CompressionType | c )

Get a tile from the cache.

If the JPEG tile already exists in the cache, use that, otherwise check for an uncompressed tile. If that does not exist either, extract a tile from the image. If this is an edge tile, crop it.

Parameters

  resolution | resolution number
  tile | tile number
  xangle | horizontal sequence number
  yangle | vertical sequence number
  layers | number of quality layers within image to decode
  c | CompressionType

Returns
  RawTile

The documentation for this class was generated from the following file:

- TileManager.h