1.0.2 • Published 5 years ago

image-to-tile v1.0.2

Weekly downloads
2
License
MIT
Repository
github
Last release
5 years ago

Image Tiler

Install

npm i image-to-tile

Usage in Code

import imageToTile from 'image-to-tile';

function makeItHappen() {
  imageToTile('./input.png', './output-dir/');
}

This converts the input.png to a scaled pyramid of the image. The output dir would have the input files name plus _files under the output dir. The folder structure would then be:

./output-dir/input_files/{x}/{y}/{z}.png

Usage in Cli

image-to-tile slice ./input.png ./output-dir/

This converts the input.png to a scaled pyramid of the image. The output dir would have the input files name plus _files under the output dir. The folder structure would then be:

./output-dir/input_files/{x}/{y}/{z}.png