geotiff 3.0.2 → 3.0.4-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist-browser/geotiff.js +3 -3
- package/dist-browser/geotiff.js.map +1 -1
- package/dist-module/compression/basedecoder.d.ts +30 -4
- package/dist-module/compression/basedecoder.d.ts.map +1 -1
- package/dist-module/compression/basedecoder.js +22 -1
- package/dist-module/compression/basedecoder.js.map +1 -0
- package/dist-module/compression/deflate.d.ts +2 -1
- package/dist-module/compression/deflate.d.ts.map +1 -1
- package/dist-module/compression/deflate.js +2 -0
- package/dist-module/compression/deflate.js.map +1 -0
- package/dist-module/compression/index.d.ts +14 -22
- package/dist-module/compression/index.d.ts.map +1 -1
- package/dist-module/compression/index.js +36 -25
- package/dist-module/compression/index.js.map +1 -0
- package/dist-module/compression/jpeg.d.ts +55 -15
- package/dist-module/compression/jpeg.d.ts.map +1 -1
- package/dist-module/compression/jpeg.js +187 -16
- package/dist-module/compression/jpeg.js.map +1 -0
- package/dist-module/compression/lerc.d.ts +11 -1
- package/dist-module/compression/lerc.d.ts.map +1 -1
- package/dist-module/compression/lerc.js +16 -4
- package/dist-module/compression/lerc.js.map +1 -0
- package/dist-module/compression/lzw.d.ts +2 -1
- package/dist-module/compression/lzw.d.ts.map +1 -1
- package/dist-module/compression/lzw.js +29 -1
- package/dist-module/compression/lzw.js.map +1 -0
- package/dist-module/compression/packbits.d.ts +2 -1
- package/dist-module/compression/packbits.d.ts.map +1 -1
- package/dist-module/compression/packbits.js +2 -0
- package/dist-module/compression/packbits.js.map +1 -0
- package/dist-module/compression/raw.d.ts +2 -1
- package/dist-module/compression/raw.d.ts.map +1 -1
- package/dist-module/compression/raw.js +2 -0
- package/dist-module/compression/raw.js.map +1 -0
- package/dist-module/compression/webimage.d.ts +2 -1
- package/dist-module/compression/webimage.d.ts.map +1 -1
- package/dist-module/compression/webimage.js +5 -0
- package/dist-module/compression/webimage.js.map +1 -0
- package/dist-module/compression/zstd.d.ts +4 -2
- package/dist-module/compression/zstd.d.ts.map +1 -1
- package/dist-module/compression/zstd.js +3 -1
- package/dist-module/compression/zstd.js.map +1 -0
- package/dist-module/dataslice.d.ts +78 -22
- package/dist-module/dataslice.d.ts.map +1 -1
- package/dist-module/dataslice.js +57 -1
- package/dist-module/dataslice.js.map +1 -0
- package/dist-module/dataview64.d.ts +71 -14
- package/dist-module/dataview64.d.ts.map +1 -1
- package/dist-module/dataview64.js +58 -1
- package/dist-module/dataview64.js.map +1 -0
- package/dist-module/geotiff.d.ts +61 -12
- package/dist-module/geotiff.d.ts.map +1 -1
- package/dist-module/geotiff.js +73 -14
- package/dist-module/geotiff.js.map +1 -0
- package/dist-module/geotiffimage.d.ts +41 -15
- package/dist-module/geotiffimage.d.ts.map +1 -1
- package/dist-module/geotiffimage.js +132 -52
- package/dist-module/geotiffimage.js.map +1 -0
- package/dist-module/geotiffwriter.d.ts +28 -1
- package/dist-module/geotiffwriter.d.ts.map +1 -1
- package/dist-module/geotiffwriter.js +206 -84
- package/dist-module/geotiffwriter.js.map +1 -0
- package/dist-module/globals.d.ts +912 -92
- package/dist-module/globals.d.ts.map +1 -1
- package/dist-module/globals.js +201 -227
- package/dist-module/globals.js.map +1 -0
- package/dist-module/imagefiledirectory.d.ts +72 -19
- package/dist-module/imagefiledirectory.d.ts.map +1 -1
- package/dist-module/imagefiledirectory.js +51 -26
- package/dist-module/imagefiledirectory.js.map +1 -0
- package/dist-module/logging.d.ts +36 -10
- package/dist-module/logging.d.ts.map +1 -1
- package/dist-module/logging.js +16 -2
- package/dist-module/logging.js.map +1 -0
- package/dist-module/pool.d.ts +15 -8
- package/dist-module/pool.d.ts.map +1 -1
- package/dist-module/pool.js +11 -3
- package/dist-module/pool.js.map +1 -0
- package/dist-module/predictor.d.ts +10 -1
- package/dist-module/predictor.d.ts.map +1 -1
- package/dist-module/predictor.js +19 -0
- package/dist-module/predictor.js.map +1 -0
- package/dist-module/resample.d.ts.map +1 -1
- package/dist-module/resample.js +12 -0
- package/dist-module/resample.js.map +1 -0
- package/dist-module/rgb.js +1 -0
- package/dist-module/rgb.js.map +1 -0
- package/dist-module/source/arraybuffer.d.ts +7 -4
- package/dist-module/source/arraybuffer.d.ts.map +1 -1
- package/dist-module/source/arraybuffer.js +15 -1
- package/dist-module/source/arraybuffer.js.map +1 -0
- package/dist-module/source/basesource.d.ts +11 -6
- package/dist-module/source/basesource.d.ts.map +1 -1
- package/dist-module/source/basesource.js +7 -4
- package/dist-module/source/basesource.js.map +1 -0
- package/dist-module/source/blockedsource.d.ts +2 -2
- package/dist-module/source/blockedsource.d.ts.map +1 -1
- package/dist-module/source/blockedsource.js +8 -5
- package/dist-module/source/blockedsource.js.map +1 -0
- package/dist-module/source/client/base.d.ts +8 -7
- package/dist-module/source/client/base.d.ts.map +1 -1
- package/dist-module/source/client/base.js +7 -5
- package/dist-module/source/client/base.js.map +1 -0
- package/dist-module/source/client/fetch.d.ts +6 -2
- package/dist-module/source/client/fetch.d.ts.map +1 -1
- package/dist-module/source/client/fetch.js +7 -2
- package/dist-module/source/client/fetch.js.map +1 -0
- package/dist-module/source/client/http.d.ts +27 -5
- package/dist-module/source/client/http.d.ts.map +1 -1
- package/dist-module/source/client/http.js +16 -2
- package/dist-module/source/client/http.js.map +1 -0
- package/dist-module/source/client/xhr.d.ts +22 -3
- package/dist-module/source/client/xhr.d.ts.map +1 -1
- package/dist-module/source/client/xhr.js +12 -2
- package/dist-module/source/client/xhr.js.map +1 -0
- package/dist-module/source/file.d.ts +8 -5
- package/dist-module/source/file.d.ts.map +1 -1
- package/dist-module/source/file.js +40 -8
- package/dist-module/source/file.js.map +1 -0
- package/dist-module/source/filereader.d.ts +12 -4
- package/dist-module/source/filereader.d.ts.map +1 -1
- package/dist-module/source/filereader.js +15 -2
- package/dist-module/source/filereader.js.map +1 -0
- package/dist-module/source/httputils.d.ts +16 -9
- package/dist-module/source/httputils.d.ts.map +1 -1
- package/dist-module/source/httputils.js +19 -12
- package/dist-module/source/httputils.js.map +1 -0
- package/dist-module/source/remote.d.ts.map +1 -1
- package/dist-module/source/remote.js +19 -7
- package/dist-module/source/remote.js.map +1 -0
- package/dist-module/utils.d.ts +36 -41
- package/dist-module/utils.d.ts.map +1 -1
- package/dist-module/utils.js +17 -12
- package/dist-module/utils.js.map +1 -0
- package/dist-module/worker/create.js +1 -1
- package/dist-module/worker/create.js.map +1 -0
- package/dist-module/worker/decoder.d.ts +2 -0
- package/dist-module/worker/decoder.d.ts.map +1 -0
- package/dist-module/worker/decoder.js +21 -0
- package/dist-module/worker/decoder.js.map +1 -0
- package/dist-node/compression/basedecoder.d.ts +30 -4
- package/dist-node/compression/basedecoder.d.ts.map +1 -1
- package/dist-node/compression/basedecoder.js +22 -1
- package/dist-node/compression/basedecoder.js.map +1 -1
- package/dist-node/compression/deflate.d.ts +2 -1
- package/dist-node/compression/deflate.d.ts.map +1 -1
- package/dist-node/compression/deflate.js +2 -0
- package/dist-node/compression/deflate.js.map +1 -1
- package/dist-node/compression/index.d.ts +14 -22
- package/dist-node/compression/index.d.ts.map +1 -1
- package/dist-node/compression/index.js +36 -25
- package/dist-node/compression/index.js.map +1 -1
- package/dist-node/compression/jpeg.d.ts +55 -16
- package/dist-node/compression/jpeg.d.ts.map +1 -1
- package/dist-node/compression/jpeg.js +187 -16
- package/dist-node/compression/jpeg.js.map +1 -1
- package/dist-node/compression/lerc.d.ts +11 -1
- package/dist-node/compression/lerc.d.ts.map +1 -1
- package/dist-node/compression/lerc.js +16 -4
- package/dist-node/compression/lerc.js.map +1 -1
- package/dist-node/compression/lzw.d.ts +2 -1
- package/dist-node/compression/lzw.d.ts.map +1 -1
- package/dist-node/compression/lzw.js +29 -1
- package/dist-node/compression/lzw.js.map +1 -1
- package/dist-node/compression/packbits.d.ts +2 -1
- package/dist-node/compression/packbits.d.ts.map +1 -1
- package/dist-node/compression/packbits.js +2 -0
- package/dist-node/compression/packbits.js.map +1 -1
- package/dist-node/compression/raw.d.ts +2 -1
- package/dist-node/compression/raw.d.ts.map +1 -1
- package/dist-node/compression/raw.js +2 -0
- package/dist-node/compression/raw.js.map +1 -1
- package/dist-node/compression/webimage.d.ts +2 -2
- package/dist-node/compression/webimage.d.ts.map +1 -1
- package/dist-node/compression/webimage.js +5 -0
- package/dist-node/compression/webimage.js.map +1 -1
- package/dist-node/compression/zstd.d.ts +2 -1
- package/dist-node/compression/zstd.d.ts.map +1 -1
- package/dist-node/compression/zstd.js +3 -1
- package/dist-node/compression/zstd.js.map +1 -1
- package/dist-node/dataslice.d.ts +78 -22
- package/dist-node/dataslice.d.ts.map +1 -1
- package/dist-node/dataslice.js +57 -1
- package/dist-node/dataslice.js.map +1 -1
- package/dist-node/dataview64.d.ts +71 -14
- package/dist-node/dataview64.d.ts.map +1 -1
- package/dist-node/dataview64.js +58 -1
- package/dist-node/dataview64.js.map +1 -1
- package/dist-node/geotiff.d.ts +61 -12
- package/dist-node/geotiff.d.ts.map +1 -1
- package/dist-node/geotiff.js +75 -15
- package/dist-node/geotiff.js.map +1 -1
- package/dist-node/geotiffimage.d.ts +41 -15
- package/dist-node/geotiffimage.d.ts.map +1 -1
- package/dist-node/geotiffimage.js +132 -52
- package/dist-node/geotiffimage.js.map +1 -1
- package/dist-node/geotiffwriter.d.ts +28 -1
- package/dist-node/geotiffwriter.d.ts.map +1 -1
- package/dist-node/geotiffwriter.js +206 -84
- package/dist-node/geotiffwriter.js.map +1 -1
- package/dist-node/globals.d.ts +910 -90
- package/dist-node/globals.d.ts.map +1 -1
- package/dist-node/globals.js +202 -228
- package/dist-node/globals.js.map +1 -1
- package/dist-node/imagefiledirectory.d.ts +72 -19
- package/dist-node/imagefiledirectory.d.ts.map +1 -1
- package/dist-node/imagefiledirectory.js +51 -26
- package/dist-node/imagefiledirectory.js.map +1 -1
- package/dist-node/logging.d.ts +36 -10
- package/dist-node/logging.d.ts.map +1 -1
- package/dist-node/logging.js +16 -2
- package/dist-node/logging.js.map +1 -1
- package/dist-node/pool.d.ts +15 -8
- package/dist-node/pool.d.ts.map +1 -1
- package/dist-node/pool.js +11 -3
- package/dist-node/pool.js.map +1 -1
- package/dist-node/predictor.d.ts +10 -1
- package/dist-node/predictor.d.ts.map +1 -1
- package/dist-node/predictor.js +19 -0
- package/dist-node/predictor.js.map +1 -1
- package/dist-node/resample.d.ts.map +1 -1
- package/dist-node/resample.js +12 -0
- package/dist-node/resample.js.map +1 -1
- package/dist-node/rgb.js +1 -0
- package/dist-node/rgb.js.map +1 -1
- package/dist-node/source/arraybuffer.d.ts +7 -4
- package/dist-node/source/arraybuffer.d.ts.map +1 -1
- package/dist-node/source/arraybuffer.js +15 -1
- package/dist-node/source/arraybuffer.js.map +1 -1
- package/dist-node/source/basesource.d.ts +11 -6
- package/dist-node/source/basesource.d.ts.map +1 -1
- package/dist-node/source/basesource.js +7 -4
- package/dist-node/source/basesource.js.map +1 -1
- package/dist-node/source/blockedsource.d.ts +2 -2
- package/dist-node/source/blockedsource.d.ts.map +1 -1
- package/dist-node/source/blockedsource.js +8 -5
- package/dist-node/source/blockedsource.js.map +1 -1
- package/dist-node/source/client/base.d.ts +8 -7
- package/dist-node/source/client/base.d.ts.map +1 -1
- package/dist-node/source/client/base.js +7 -5
- package/dist-node/source/client/base.js.map +1 -1
- package/dist-node/source/client/fetch.d.ts +5 -2
- package/dist-node/source/client/fetch.d.ts.map +1 -1
- package/dist-node/source/client/fetch.js +7 -2
- package/dist-node/source/client/fetch.js.map +1 -1
- package/dist-node/source/client/http.d.ts +22 -4
- package/dist-node/source/client/http.d.ts.map +1 -1
- package/dist-node/source/client/http.js +16 -2
- package/dist-node/source/client/http.js.map +1 -1
- package/dist-node/source/client/xhr.d.ts +23 -3
- package/dist-node/source/client/xhr.d.ts.map +1 -1
- package/dist-node/source/client/xhr.js +12 -2
- package/dist-node/source/client/xhr.js.map +1 -1
- package/dist-node/source/file.d.ts +8 -5
- package/dist-node/source/file.d.ts.map +1 -1
- package/dist-node/source/file.js +40 -8
- package/dist-node/source/file.js.map +1 -1
- package/dist-node/source/filereader.d.ts +12 -4
- package/dist-node/source/filereader.d.ts.map +1 -1
- package/dist-node/source/filereader.js +15 -2
- package/dist-node/source/filereader.js.map +1 -1
- package/dist-node/source/httputils.d.ts +16 -9
- package/dist-node/source/httputils.d.ts.map +1 -1
- package/dist-node/source/httputils.js +19 -12
- package/dist-node/source/httputils.js.map +1 -1
- package/dist-node/source/remote.d.ts.map +1 -1
- package/dist-node/source/remote.js +19 -7
- package/dist-node/source/remote.js.map +1 -1
- package/dist-node/utils.d.ts +9 -8
- package/dist-node/utils.d.ts.map +1 -1
- package/dist-node/utils.js +17 -12
- package/dist-node/utils.js.map +1 -1
- package/dist-node/worker/create.js +1 -1
- package/dist-node/worker/create.js.map +1 -1
- package/dist-node/worker/decoder.d.ts +2 -0
- package/dist-node/worker/decoder.d.ts.map +1 -0
- package/dist-node/worker/decoder.js +24 -0
- package/dist-node/worker/decoder.js.map +1 -0
- package/package.json +5 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create.js","sourceRoot":"","sources":["../../dist-module/worker/create.js"],"names":[],"mappings":";;;;;AAEA,yBAKC;AAPD,4DAAgC;AAEhC,SAAwB,MAAM;IAC5B,MAAM,MAAM,GAAG,
|
|
1
|
+
{"version":3,"file":"create.js","sourceRoot":"","sources":["../../dist-module/worker/create.js"],"names":[],"mappings":";;;;;AAEA,yBAKC;AAPD,4DAAgC;AAEhC,SAAwB,MAAM;IAC5B,MAAM,MAAM,GAAG,k7/OAAk7/O,CAAC;IACl8/O,OAAO,IAAI,oBAAM,CAAC,OAAO,MAAM,KAAK,WAAW;QAC7C,CAAC,CAAC,qCAAqC,GAAG,MAAM,CAAC,IAAI,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC,QAAQ,CAAC,QAAQ,CAAC;QAC1F,CAAC,CAAC,GAAG,CAAC,eAAe,CAAC,IAAI,IAAI,CAAC,CAAC,MAAM,CAAC,EAAE,EAAE,IAAI,EAAE,wBAAwB,EAAE,CAAC,CAAC,CAAC,CAAC;AACnF,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"decoder.d.ts","sourceRoot":"","sources":["../../dist-module/worker/decoder.js"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
/* global globalThis */
|
|
4
|
+
/* eslint-disable import/no-mutable-exports */
|
|
5
|
+
const index_js_1 = require("../compression/index.js");
|
|
6
|
+
const worker = globalThis;
|
|
7
|
+
worker.addEventListener('message', async (e) => {
|
|
8
|
+
const { compression, decoderParameters, buffer, ...extra } = e.data;
|
|
9
|
+
try {
|
|
10
|
+
const decoder = await (0, index_js_1.getDecoder)(compression, decoderParameters);
|
|
11
|
+
const decoded = await decoder.decode(buffer);
|
|
12
|
+
worker.postMessage({ decoded, ...extra }, { transfer: [decoded] });
|
|
13
|
+
}
|
|
14
|
+
catch (error) {
|
|
15
|
+
if (error instanceof Error) {
|
|
16
|
+
worker.postMessage({ error: error.message, ...extra });
|
|
17
|
+
}
|
|
18
|
+
else {
|
|
19
|
+
worker.postMessage({ error: String(error), ...extra });
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
});
|
|
23
|
+
//# sourceMappingURL=decoder.js.map
|
|
24
|
+
//# sourceMappingURL=decoder.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"decoder.js","sourceRoot":"","sources":["../../dist-module/worker/decoder.js"],"names":[],"mappings":";;AAAA,uBAAuB;AACvB,8CAA8C;AAC9C,sDAAqD;AACrD,MAAM,MAAM,GAAG,UAAU,CAAC;AAC1B,MAAM,CAAC,gBAAgB,CAAC,SAAS,EAAE,KAAK,EAAE,CAAC,EAAE,EAAE;IAC3C,MAAM,EAAE,WAAW,EAAE,iBAAiB,EAAE,MAAM,EAAE,GAAG,KAAK,EAAE,GAAG,CAAC,CAAC,IAAI,CAAC;IACpE,IAAI,CAAC;QACD,MAAM,OAAO,GAAG,MAAM,IAAA,qBAAU,EAAC,WAAW,EAAE,iBAAiB,CAAC,CAAC;QACjE,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;QAC7C,MAAM,CAAC,WAAW,CAAC,EAAE,OAAO,EAAE,GAAG,KAAK,EAAE,EAAE,EAAE,QAAQ,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC,CAAC;IACvE,CAAC;IACD,OAAO,KAAK,EAAE,CAAC;QACX,IAAI,KAAK,YAAY,KAAK,EAAE,CAAC;YACzB,MAAM,CAAC,WAAW,CAAC,EAAE,KAAK,EAAE,KAAK,CAAC,OAAO,EAAE,GAAG,KAAK,EAAE,CAAC,CAAC;QAC3D,CAAC;aACI,CAAC;YACF,MAAM,CAAC,WAAW,CAAC,EAAE,KAAK,EAAE,MAAM,CAAC,KAAK,CAAC,EAAE,GAAG,KAAK,EAAE,CAAC,CAAC;QAC3D,CAAC;IACL,CAAC;AACL,CAAC,CAAC,CAAC;AACH,mCAAmC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "geotiff",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.4-beta.0",
|
|
4
4
|
"description": "GeoTIFF image decoding in JavaScript",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"node": ">=10.19"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@petamoriken/float16": "^3.
|
|
37
|
+
"@petamoriken/float16": "^3.9.3",
|
|
38
38
|
"lerc": "^3.0.0",
|
|
39
39
|
"pako": "^2.0.4",
|
|
40
40
|
"parse-headers": "^2.0.2",
|
|
@@ -51,6 +51,8 @@
|
|
|
51
51
|
"@rollup/plugin-babel": "^5.3.0",
|
|
52
52
|
"@rollup/plugin-commonjs": "^21.0.1",
|
|
53
53
|
"@rollup/plugin-node-resolve": "^13.1.3",
|
|
54
|
+
"@types/node": "^25.2.0",
|
|
55
|
+
"@types/pako": "^2.0.4",
|
|
54
56
|
"chai": "^4.2.0",
|
|
55
57
|
"chai-as-promised": "^8.0.1",
|
|
56
58
|
"chokidar-cli": "^3.0.0",
|
|
@@ -80,7 +82,7 @@
|
|
|
80
82
|
"prebuild": "npm run build:clean",
|
|
81
83
|
"build": "npm run build:module && run-p build:browser build:node",
|
|
82
84
|
"build:clean": "shx rm -rf dist-node/ dist-browser/ dist-module/",
|
|
83
|
-
"build:module": "tsc
|
|
85
|
+
"build:module": "tsc && rollup -c rollup.worker.config.js",
|
|
84
86
|
"build:browser": "rollup -c rollup.config.js",
|
|
85
87
|
"build:node": "tsc --project tsconfig.build.json && shx echo \"{\\\"type\\\":\\\"commonjs\\\"}\" > dist-node/package.json",
|
|
86
88
|
"build:types": "tsc --outdir dist-module/",
|