|
iipsrv
1.0
|
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, JPEGCompressor *j, std::ofstream *s, int l) | |
| Constructor. More... | |
| RawTile | getTile (int resolution, int tile, int xangle, int yangle, int layers, CompressionType c) |
| Get a tile from the cache. More... | |
| 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. More... | |
Class to manage access to the tile cache and tile cropping.
|
inline |
Constructor.
| 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 |
| 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.
| 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 |
| 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.
| 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 |