Analogous to a GeoTIFF file format, but in PNG form for easier editing. Single variable. Part of Geospatiale III.
- Source:
Methods
(static) convertToGeoJSON(arg0_file_path, arg1_file_path, arg2_options)
Transforms a PNG raster map to GeoJSON MultiPolygons, ignoring specified colours.
Parameters:
| Name | Type | Description | ||||||
|---|---|---|---|---|---|---|---|---|
arg0_file_path |
string
|
Input PNG file path |
||||||
arg1_file_path |
string
|
Output GeoJSON file path |
||||||
arg2_options |
Object
|
Options object
|
(static) getImageSum(arg0_file_pathopt) → {number}
Fetches the total sum of all int values within an image.
Parameters:
| Name | Type | Attributes | Description |
|---|---|---|---|
arg0_file_path |
String
|
<optional> |
The file path to the image to fetch the sum of. |
Returns:
- Type:
-
number
(static) getRGBAFromPixel(arg0_image_object, arg1_index) → {Array.<number>}
getRGBAFromPixel() - Fetches the RGBA value of a pixel based on its index.
Parameters:
| Name | Type | Description |
|---|---|---|
arg0_image_object |
Object
|
|
arg1_index |
number
|
Returns:
- Type:
-
Array.<number>
(static) kNNBin(arg0_input_path, arg1_output_path, arg2_options)
Robustly eliminates specific colours by binning them to the nearest available non-binned colour.
Parameters:
| Name | Type | Description | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
arg0_input_path |
string
|
||||||||||
arg1_output_path |
string
|
||||||||||
arg2_options |
Object
|
|
(static) loadImage(arg0_file_path) → {Object}
loadImage() - Loads an image into the assigned variable.
Parameters:
| Name | Type | Description |
|---|---|---|
arg0_file_path |
String
|
Returns:
- Type:
-
Object
(static) loadNumberFromPixel(arg0_image_object, arg1_index) → {number}
loadNumberFromPixel() - Loads an int value from a pixel based on its index.
Parameters:
| Name | Type | Description |
|---|---|---|
arg0_image_object |
Object
|
|
arg1_index |
number
|
Returns:
- Type:
-
number
(static) loadNumberRasterImage(arg0_file_path, arg1_optionsopt) → {Object|string}
loadNumberRasterImage() - Loads a number raster image into the assigned variable.
Parameters:
| Name | Type | Attributes | Description | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
arg0_file_path |
string
|
||||||||||||
arg1_options |
Object
|
<optional> |
|
Returns:
- Type:
-
Object|string
(static) operateNumberRasterImage(arg0_optionsopt)
operateNumberRasterImage() - Runs an operation on a raster image for a file.
Parameters:
| Name | Type | Attributes | Description | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
arg0_options |
Object
|
<optional> |
|
(static) saveNumberRasterImage(arg0_optionsopt)
saveNumberRasterImage() - Saves a number raster image to a file.
Parameters:
| Name | Type | Attributes | Description | ||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
arg0_options |
Object
|
<optional> |
|
(static) saveNumberToPixel(arg0_image_object, arg1_index, arg2_number, arg3_typeopt) → {Array.<number>}
saveNumberToPixel() - Saves an int value to a pixel based on the corresponding index.
Parameters:
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
arg0_image_object |
string
|
The image object to use. |
||
arg1_index |
number
|
The index of the pixel to save the number to. |
||
arg2_number |
number
|
string
|
The number to save to the pixel. |
||
arg3_type |
string
|
<optional> |
"32bit_int_positive" |
Either '32bit_int_positive'/'greyscale'. |
Returns:
- Type:
-
Array.<number>
(static) savePercentageRasterImage(arg0_input_file_path, arg1_output_file_path) → {Object}
savePercentageRasterImage() - Saves a percentage raster image to a file based on a number raster image.
Parameters:
| Name | Type | Description |
|---|---|---|
arg0_input_file_path |
String
|
The file path to the number raster image to save the percentage raster image from. |
arg1_output_file_path |
String
|
The file path to save the percentage raster image to. |
Returns:
- Type:
-
Object