It allows you to reduce tiles of a directory of wms-downloader tiles.
Windows: Use the installer from https://nodejs.org/
Ubuntu / Debian:
sudo apt install nodejs npm
Windows: Use the installer from http://www.graphicsmagick.org/
Ubuntu / Debian:
sudo apt install graphicsmagick
Use terminal:
npm i -g merge-tiles
Options:
-h, --help Output usage information
-V, --version Output the version number
-i, --input [path] Input directory of wms-downloader tiles. Default is the current directory.
-o, --output [path] Output directory of single tile. Default is the current directory.
-w, --workers [number] Count of graphicsmagick workers. Default is 1.
-f, --formats [ext] List of formats (gif_tif_png_jpg). Convert the single tile in the listed formats.
With default options:
cd dirOfTiles
merge
With custom options:
merge -i ./input -o ./output -w 2 -f tif_gif_jpg
const merge = require('merge-tiles');
let options = {
inputDir: __dirname + '/input',
outputDir: __dirname + '/output',
outputFormats: ['gif', 'jpg'],
workers: 4
};
merge(options, (err) => {
if (err) {
console.error(err);
} else {
console.log('Merged!');
}
});
Build api documentation:
npm run build-api-doc