Skip to content

Commit

Permalink
Merge branch 'master' of github.com:GeoTIFF/geoblaze into refactor-stats
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielJDufour committed Dec 10, 2023
2 parents be8f405 + 1338a3e commit 177e3c7
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -107,3 +107,4 @@ out
data/geotiff-test-data/*.cog
data/geotiff-test-data/*.tif*
Pipfile*
package-lock.json
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "geoblaze",
"version": "2.3.0",
"version": "2.5.0",
"description": "Blazing Fast JavaScript Raster Processing Engine",
"main": "dist/geoblaze.node.min.js",
"browser": "./dist/geoblaze.web.min.js",
Expand Down Expand Up @@ -79,7 +79,7 @@
"quick-promise": "^0.1.0",
"quick-resolve": "^0.0.1",
"reproject-bbox": "^0.12.0",
"reproject-geojson": "^0.3.0",
"reproject-geojson": "^0.5.0",
"snap-bbox": "^0.5.0",
"terraformer-arcgis-parser": "^1.1.0",
"underscore": "^1.13.6",
Expand Down
7 changes: 6 additions & 1 deletion src/wrap-geom.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,12 @@ export default function wrapGeom(func) {
if (Array.isArray(geometry) && geometry.length === 4 && geometry.every(n => typeof n === "number")) {
geom = reprojectBoundingBox({ bbox: geometry, density: 10, from: srs, to: georaster.projection });
} else {
geom = reprojectGeoJSON(geometry, { from: srs, to: georaster.projection });
geom = reprojectGeoJSON(geometry, {
// adds 3 points to every edge, basically dividing each edge into quarters
densify: typeof geom.densify === "number" ? Math.round(geom.densify) : 3,
from: srs,
to: georaster.projection
});
}
} else {
geom = geom.geometry;
Expand Down

0 comments on commit 177e3c7

Please sign in to comment.