Skip to content

Commit

Permalink
Merge pull request #94 from geotiffjs/multi-ranges
Browse files Browse the repository at this point in the history
Multi ranges
  • Loading branch information
constantinius authored Mar 24, 2021
2 parents b47771d + 80687f3 commit fb6541c
Show file tree
Hide file tree
Showing 23 changed files with 1,465 additions and 552 deletions.
17 changes: 17 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -372,6 +372,23 @@ const multiTiff = await fromUrls(
);
```

### AbortController Support

Geotiff.js supports the use of [`AbortController`s](https://developer.mozilla.org/en-US/docs/Web/API/AbortController). Calls to `getRasters`, `readRGB` and `getTileOrStrip` will throw an `Error` with name `AbortSignal` similar to the browser's `fetch` behavior.

```javascript
const abortController = new AbortController();
const { signal } = abortController;
abortController.abort();
try {
const data = await tiff.readRasters({ signal });
} catch(e) {
if (err.name === 'AbortError') {
// do stuff
}
}
```

### Writing GeoTIFFs (Beta Version)

You can create a binary representation of a GeoTIFF using `writeArrayBuffer`.
Expand Down
200 changes: 188 additions & 12 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit fb6541c

Please sign in to comment.