checkSingleTile

src/checkSingleTile.js

Checks if you have enough memory for single tile

checkSingleTile(info: object): object
Parameters
info (object) Return object from scanInputData
Returns
object: Object like { singleTile: false, x: 8, y: 11 }

Determines the maximum size of a merged tile

_checkSubTile(x: number, y: number, info: object): object
Parameters
x (number) [description]
y (number) [description]
info (object) Return object from scanInputData
Returns
object: Object like { singleTile: false, x: 8, y: 11 }

TODO

convertImage(getNextTask: any, callback: any)
Parameters
getNextTask (any)
callback (any)

TODO

convertImages(info: any, tiles: any, callback: any)
Parameters
info (any)
tiles (any)
callback (any)

TODO

copyWorldFile(info: any, tile: any)
Parameters
info (any)
tile (any)

determineMergedTiles

src/determineMergedTiles.js

TODO [determineMergedTiles description]

determineMergedTiles(info: [type], check: [type]): object
Parameters
info ([type]) [description]
check ([type]) [description]
Returns
object: [description]
Example
//Return object
[
  { name: 'x0_y0', x: { from: 0, to: 15 }, y: { from:  0, to: 21 } },
  { name: 'x0_y1', x: { from: 0, to: 15 }, y: { from: 22, to: 43 } }
]

Determines the x and y value as integer from filename.

determineXY(file: string): object
Parameters
file (string) Filename of a wms-downloader tile.
Returns
object: Object with x and y values as integer like {file: "x0_y1.tif", x: 0, y: 1}.

ensureOutputDirs

src/ensureOutputDirs.js

TODO

ensureOutputDirs(info: any)
Parameters
info (any)

Checks, if the file is a supported image.

isImage(file: String): (Boolean | String)
Parameters
file (String) File name
Returns
(Boolean | String): false: File name is no image; string: File extension

TODO

log(msg: any, level: any)
Parameters
msg (any)
level (any)

TODO

merge(options: any, callback: any)
Parameters
options (any)
callback (any)

TODO

mergeLine(info: any, tile: any, getNextLineIndex: any, callback: any)
Parameters
info (any)
tile (any)
getNextLineIndex (any)
callback (any)

TODO

mergeTile(info: any, tile: any, callback: any)
Parameters
info (any)
tile (any)
callback (any)

TODO

mergeTiles(info: any, tiles: any, callback: any, index: any)
Parameters
info (any)
tiles (any)
callback (any)
index (any)

Determines information about the input data

scanInputData(options: any): object
Parameters
options (any)
Returns
object: Object with a lots of information about the input data, see example.
Example
//execute function
scanInputData('D:/input', 'D:/output', ['gif', 'tif']);

//return object
{
  "inputDir": "D:/input",
  "outputDir": "D:/output",
  "outputFormats": [
    {
      "fileExt": "gif",
      "worldFileExt": "gfw"
    }
  ],
  "workers": 2,
  "freeMemory": 12207316992,
  "tiles": {
    "fileExt": "tif",
    "worldFileExt": "tfw",
    "numOfX": 15,
    "numOfY": 22,
    "width": 3000,
    "height": 3000,
    "bytesPerPixel": 3
  }
}