Contains the logic to create the pyramid of tiles in quantized mesh format.
More...
#include <quantized_mesh_tiles_pyramid_builder.h>
|
| QuantizedMeshTilesPyramidBuilder (const std::vector< QuantizedMeshTiler > &qmTilers, const ZoomTilesScheduler &scheduler) |
|
void | createTmsPyramid (const int &startZoom, const int &endZoom, const std::string &outDir, const std::string &debugDir=std::string("")) |
| Creates the tile pyramid in quantized-mesh format. More...
|
|
void | createTmsPyramidUnconstrainedBorders (const int &startZoom, const int &endZoom, const std::string &outDir, const std::string &debugDir=std::string("")) |
| Creates the tile pyramid in quantized-mesh format without taking into account coherence along neighboring tiles' borders Useful when we know, by the way the simplification is created, that the vertices in the borders will always be the same (e.g., in the Delaunay TIN creation strategy)
|
|
BordersData | createTile (const ctb::TileCoordinate &coord, const int &numThread, const std::string &outDir, const BordersData &bd) |
| Create the required tile, in the given thread, and with the given data at the borders to maintain. The result is an output tile file created, and an updated BorderData structure with the data to maintain for neighboring tiles to be created. More...
|
|
bool | getNextTileToProcess (ctb::TilePoint &tileXY) |
|
|
static std::string | getTileFileAndCreateDirs (const ctb::TileCoordinate &coord, const std::string &mainOutDir) |
| Check if the tile folder (zoom/x) exists, and creates it otherwise. More...
|
|
Contains the logic to create the pyramid of tiles in quantized mesh format.
Since the quantized mesh format requires coherence between neighboring tiles, this class is the responsible of maintaining this coherence and schedule the building of tiles by taking into account the ones already built.
◆ QuantizedMeshTilesPyramidBuilder()
Constructor
- Parameters
-
qmTilers | Vector of tilers, one for each desired thread (they should be the same!) |
scheduler | The desired scheduler defining a preferred order for processing the tiles |
◆ createTile()
BordersData QuantizedMeshTilesPyramidBuilder::createTile |
( |
const ctb::TileCoordinate & |
coord, |
|
|
const int & |
numThread, |
|
|
const std::string & |
outDir, |
|
|
const BordersData & |
bd |
|
) |
| |
Create the required tile, in the given thread, and with the given data at the borders to maintain. The result is an output tile file created, and an updated BorderData structure with the data to maintain for neighboring tiles to be created.
- Parameters
-
coord | The tile coordinates |
numThread | The thread number where the process will take place |
outDir | The output directory where the output tile file will be generated |
bd | The BordersData structure input. It contains the data to preserve at the borders as a result of previously generated tiles. |
- Returns
- It returns the data at the borders to be maintained for neighboring tiles to be generated in the future (i.e., what was already restricted in
bd
, plus the new borders created).
◆ createTmsPyramid()
void QuantizedMeshTilesPyramidBuilder::createTmsPyramid |
( |
const int & |
startZoom, |
|
|
const int & |
endZoom, |
|
|
const std::string & |
outDir, |
|
|
const std::string & |
debugDir = std::string("") |
|
) |
| |
Creates the tile pyramid in quantized-mesh format.
Due to the quantized-mesh format requiring the vertices on the edges to coincide between neighbors, the creation of the tiles' for each zoom is not as simple as in the heightmap format, and it requires a more complex loop taking into account vertices at borders of the neighbors of the current tile being processed
◆ getNextTileToProcess()
bool QuantizedMeshTilesPyramidBuilder::getNextTileToProcess |
( |
ctb::TilePoint & |
tileXY | ) |
|
Get the next tile to process in the current zoom
- Parameters
-
tileXY | The (x,y) coordinates of the tile to process within the current zoom |
- Returns
- Returns true if a tile to be processed was located in the queue, false otherwise
◆ getTileFileAndCreateDirs()
std::string QuantizedMeshTilesPyramidBuilder::getTileFileAndCreateDirs |
( |
const ctb::TileCoordinate & |
coord, |
|
|
const std::string & |
mainOutDir |
|
) |
| |
|
static |
Check if the tile folder (zoom/x) exists, and creates it otherwise.
- Returns
- The path of the tile's file.
The documentation for this class was generated from the following files: