@loaders.gl/las 4.0.3 → 4.1.0-alpha.1
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/dist.dev.js +8 -9
- package/dist/index.cjs +8 -9
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/las-loader.d.ts +1 -0
- package/dist/las-loader.d.ts.map +1 -1
- package/dist/las-loader.js +8 -9
- package/dist/las-loader.js.map +1 -1
- package/dist/las-worker.js +12 -23
- package/package.json +4 -4
- package/src/index.ts +1 -0
- package/src/las-loader.ts +9 -10
package/dist/dist.dev.js
CHANGED
|
@@ -48,14 +48,6 @@ var __exports__ = (() => {
|
|
|
48
48
|
|
|
49
49
|
// src/las-loader.ts
|
|
50
50
|
var VERSION = typeof __VERSION__ !== "undefined" ? __VERSION__ : "latest";
|
|
51
|
-
var DEFAULT_LAS_OPTIONS = {
|
|
52
|
-
las: {
|
|
53
|
-
shape: "mesh",
|
|
54
|
-
fp64: false,
|
|
55
|
-
skip: 1,
|
|
56
|
-
colorDepth: 8
|
|
57
|
-
}
|
|
58
|
-
};
|
|
59
51
|
var LASLoader = {
|
|
60
52
|
name: "LAS",
|
|
61
53
|
id: "las",
|
|
@@ -67,7 +59,14 @@ var __exports__ = (() => {
|
|
|
67
59
|
text: true,
|
|
68
60
|
binary: true,
|
|
69
61
|
tests: ["LAS"],
|
|
70
|
-
options:
|
|
62
|
+
options: {
|
|
63
|
+
las: {
|
|
64
|
+
shape: "mesh",
|
|
65
|
+
fp64: false,
|
|
66
|
+
skip: 1,
|
|
67
|
+
colorDepth: 8
|
|
68
|
+
}
|
|
69
|
+
}
|
|
71
70
|
};
|
|
72
71
|
|
|
73
72
|
// ../schema/src/lib/table/simple-table/data-type.ts
|
package/dist/index.cjs
CHANGED
|
@@ -27,14 +27,6 @@ module.exports = __toCommonJS(src_exports);
|
|
|
27
27
|
|
|
28
28
|
// src/las-loader.ts
|
|
29
29
|
var VERSION = typeof __VERSION__ !== "undefined" ? __VERSION__ : "latest";
|
|
30
|
-
var DEFAULT_LAS_OPTIONS = {
|
|
31
|
-
las: {
|
|
32
|
-
shape: "mesh",
|
|
33
|
-
fp64: false,
|
|
34
|
-
skip: 1,
|
|
35
|
-
colorDepth: 8
|
|
36
|
-
}
|
|
37
|
-
};
|
|
38
30
|
var LASLoader = {
|
|
39
31
|
name: "LAS",
|
|
40
32
|
id: "las",
|
|
@@ -48,7 +40,14 @@ var LASLoader = {
|
|
|
48
40
|
text: true,
|
|
49
41
|
binary: true,
|
|
50
42
|
tests: ["LAS"],
|
|
51
|
-
options:
|
|
43
|
+
options: {
|
|
44
|
+
las: {
|
|
45
|
+
shape: "mesh",
|
|
46
|
+
fp64: false,
|
|
47
|
+
skip: 1,
|
|
48
|
+
colorDepth: 8
|
|
49
|
+
}
|
|
50
|
+
}
|
|
52
51
|
};
|
|
53
52
|
|
|
54
53
|
// src/lib/parse-las.ts
|
package/dist/index.d.ts
CHANGED
|
@@ -6,6 +6,7 @@ export type { LASLoaderOptions };
|
|
|
6
6
|
export { LASWorkerLoader };
|
|
7
7
|
/**
|
|
8
8
|
* Loader for the LAS (LASer) point cloud format
|
|
9
|
+
* @note Does not support LAS v1.4
|
|
9
10
|
*/
|
|
10
11
|
export declare const LASLoader: LoaderWithParser<LASMesh, never, LASLoaderOptions>;
|
|
11
12
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,gBAAgB,EAAC,MAAM,0BAA0B,CAAC;AAC/D,OAAO,KAAK,EAAC,gBAAgB,EAAC,MAAM,cAAc,CAAC;AACnD,OAAO,KAAK,EAAC,OAAO,EAAC,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAC,SAAS,IAAI,eAAe,EAAC,MAAM,cAAc,CAAC;AAK1D,YAAY,EAAC,gBAAgB,EAAC,CAAC;AAC/B,OAAO,EAAC,eAAe,EAAC,CAAC;AAEzB
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,gBAAgB,EAAC,MAAM,0BAA0B,CAAC;AAC/D,OAAO,KAAK,EAAC,gBAAgB,EAAC,MAAM,cAAc,CAAC;AACnD,OAAO,KAAK,EAAC,OAAO,EAAC,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAC,SAAS,IAAI,eAAe,EAAC,MAAM,cAAc,CAAC;AAK1D,YAAY,EAAC,gBAAgB,EAAC,CAAC;AAC/B,OAAO,EAAC,eAAe,EAAC,CAAC;AAEzB;;;GAGG;AACH,eAAO,MAAM,SAAS,EAAE,gBAAgB,CAAC,OAAO,EAAE,KAAK,EAAE,gBAAgB,CAMxE,CAAC"}
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["LASLoader","LASWorkerLoader","parseLAS","parse","arrayBuffer","options","parseSync"],"sources":["../src/index.ts"],"sourcesContent":["import type {LoaderWithParser} from '@loaders.gl/loader-utils';\nimport type {LASLoaderOptions} from './las-loader';\nimport type {LASMesh} from './lib/las-types';\nimport {LASLoader as LASWorkerLoader} from './las-loader';\nimport {parseLAS} from './lib/parse-las';\n\n// LASLoader\n\nexport type {LASLoaderOptions};\nexport {LASWorkerLoader};\n\n/**\n * Loader for the LAS (LASer) point cloud format\n */\nexport const LASLoader: LoaderWithParser<LASMesh, never, LASLoaderOptions> = {\n ...LASWorkerLoader,\n parse: async (arrayBuffer: ArrayBuffer, options?: LASLoaderOptions) =>\n parseLAS(arrayBuffer, options),\n parseSync: (arrayBuffer: ArrayBuffer, options?: LASLoaderOptions) =>\n parseLAS(arrayBuffer, options)\n};\n"],"mappings":"SAGQA,SAAS,IAAIC,eAAe;AAAA,SAC5BC,QAAQ;AAKhB,SAAQD,eAAe;
|
|
1
|
+
{"version":3,"file":"index.js","names":["LASLoader","LASWorkerLoader","parseLAS","parse","arrayBuffer","options","parseSync"],"sources":["../src/index.ts"],"sourcesContent":["import type {LoaderWithParser} from '@loaders.gl/loader-utils';\nimport type {LASLoaderOptions} from './las-loader';\nimport type {LASMesh} from './lib/las-types';\nimport {LASLoader as LASWorkerLoader} from './las-loader';\nimport {parseLAS} from './lib/parse-las';\n\n// LASLoader\n\nexport type {LASLoaderOptions};\nexport {LASWorkerLoader};\n\n/**\n * Loader for the LAS (LASer) point cloud format\n * @note Does not support LAS v1.4\n */\nexport const LASLoader: LoaderWithParser<LASMesh, never, LASLoaderOptions> = {\n ...LASWorkerLoader,\n parse: async (arrayBuffer: ArrayBuffer, options?: LASLoaderOptions) =>\n parseLAS(arrayBuffer, options),\n parseSync: (arrayBuffer: ArrayBuffer, options?: LASLoaderOptions) =>\n parseLAS(arrayBuffer, options)\n};\n"],"mappings":"SAGQA,SAAS,IAAIC,eAAe;AAAA,SAC5BC,QAAQ;AAKhB,SAAQD,eAAe;AAMvB,OAAO,MAAMD,SAA6D,GAAG;EAC3E,GAAGC,eAAe;EAClBE,KAAK,EAAE,MAAAA,CAAOC,WAAwB,EAAEC,OAA0B,KAChEH,QAAQ,CAACE,WAAW,EAAEC,OAAO,CAAC;EAChCC,SAAS,EAAEA,CAACF,WAAwB,EAAEC,OAA0B,KAC9DH,QAAQ,CAACE,WAAW,EAAEC,OAAO;AACjC,CAAC"}
|
package/dist/las-loader.d.ts
CHANGED
|
@@ -11,6 +11,7 @@ export type LASLoaderOptions = LoaderOptions & {
|
|
|
11
11
|
};
|
|
12
12
|
/**
|
|
13
13
|
* Loader for the LAS (LASer) point cloud format
|
|
14
|
+
* @note Does not support LAS v1.4
|
|
14
15
|
*/
|
|
15
16
|
export declare const LASLoader: Loader<LASMesh, never, LASLoaderOptions>;
|
|
16
17
|
//# sourceMappingURL=las-loader.d.ts.map
|
package/dist/las-loader.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"las-loader.d.ts","sourceRoot":"","sources":["../src/las-loader.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAC,MAAM,EAAE,aAAa,EAAC,MAAM,0BAA0B,CAAC;AACpE,OAAO,KAAK,EAAC,OAAO,EAAC,MAAM,iBAAiB,CAAC;AAM7C,MAAM,MAAM,gBAAgB,GAAG,aAAa,GAAG;IAC7C,GAAG,CAAC,EAAE;QACJ,KAAK,CAAC,EAAE,MAAM,GAAG,gBAAgB,GAAG,aAAa,CAAC;QAClD,IAAI,CAAC,EAAE,OAAO,CAAC;QACf,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;KAC9B,CAAC;IACF,UAAU,CAAC,EAAE,QAAQ,CAAC;CACvB,CAAC;
|
|
1
|
+
{"version":3,"file":"las-loader.d.ts","sourceRoot":"","sources":["../src/las-loader.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAC,MAAM,EAAE,aAAa,EAAC,MAAM,0BAA0B,CAAC;AACpE,OAAO,KAAK,EAAC,OAAO,EAAC,MAAM,iBAAiB,CAAC;AAM7C,MAAM,MAAM,gBAAgB,GAAG,aAAa,GAAG;IAC7C,GAAG,CAAC,EAAE;QACJ,KAAK,CAAC,EAAE,MAAM,GAAG,gBAAgB,GAAG,aAAa,CAAC;QAClD,IAAI,CAAC,EAAE,OAAO,CAAC;QACf,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;KAC9B,CAAC;IACF,UAAU,CAAC,EAAE,QAAQ,CAAC;CACvB,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,SAAS,EAAE,MAAM,CAAC,OAAO,EAAE,KAAK,EAAE,gBAAgB,CAmB9D,CAAC"}
|
package/dist/las-loader.js
CHANGED
|
@@ -1,12 +1,4 @@
|
|
|
1
1
|
const VERSION = typeof __VERSION__ !== 'undefined' ? __VERSION__ : 'latest';
|
|
2
|
-
const DEFAULT_LAS_OPTIONS = {
|
|
3
|
-
las: {
|
|
4
|
-
shape: 'mesh',
|
|
5
|
-
fp64: false,
|
|
6
|
-
skip: 1,
|
|
7
|
-
colorDepth: 8
|
|
8
|
-
}
|
|
9
|
-
};
|
|
10
2
|
export const LASLoader = {
|
|
11
3
|
name: 'LAS',
|
|
12
4
|
id: 'las',
|
|
@@ -18,6 +10,13 @@ export const LASLoader = {
|
|
|
18
10
|
text: true,
|
|
19
11
|
binary: true,
|
|
20
12
|
tests: ['LAS'],
|
|
21
|
-
options:
|
|
13
|
+
options: {
|
|
14
|
+
las: {
|
|
15
|
+
shape: 'mesh',
|
|
16
|
+
fp64: false,
|
|
17
|
+
skip: 1,
|
|
18
|
+
colorDepth: 8
|
|
19
|
+
}
|
|
20
|
+
}
|
|
22
21
|
};
|
|
23
22
|
//# sourceMappingURL=las-loader.js.map
|
package/dist/las-loader.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"las-loader.js","names":["VERSION","__VERSION__","
|
|
1
|
+
{"version":3,"file":"las-loader.js","names":["VERSION","__VERSION__","LASLoader","name","id","module","version","worker","extensions","mimeTypes","text","binary","tests","options","las","shape","fp64","skip","colorDepth"],"sources":["../src/las-loader.ts"],"sourcesContent":["// LASER (LAS) FILE FORMAT\nimport type {Loader, LoaderOptions} from '@loaders.gl/loader-utils';\nimport type {LASMesh} from './lib/las-types';\n\n// __VERSION__ is injected by babel-plugin-version-inline\n// @ts-ignore TS2304: Cannot find name '__VERSION__'.\nconst VERSION = typeof __VERSION__ !== 'undefined' ? __VERSION__ : 'latest';\n\nexport type LASLoaderOptions = LoaderOptions & {\n las?: {\n shape?: 'mesh' | 'columnar-table' | 'arrow-table';\n fp64?: boolean;\n skip?: number;\n colorDepth?: number | string;\n };\n onProgress?: Function;\n};\n\n/**\n * Loader for the LAS (LASer) point cloud format\n * @note Does not support LAS v1.4\n */\nexport const LASLoader: Loader<LASMesh, never, LASLoaderOptions> = {\n name: 'LAS',\n id: 'las',\n module: 'las',\n version: VERSION,\n worker: true,\n extensions: ['las', 'laz'], // LAZ is the \"compressed\" flavor of LAS,\n mimeTypes: ['application/octet-stream'], // TODO - text version?\n text: true,\n binary: true,\n tests: ['LAS'],\n options: {\n las: {\n shape: 'mesh',\n fp64: false,\n skip: 1,\n colorDepth: 8\n }\n }\n};\n"],"mappings":"AAMA,MAAMA,OAAO,GAAG,OAAOC,WAAW,KAAK,WAAW,GAAGA,WAAW,GAAG,QAAQ;AAgB3E,OAAO,MAAMC,SAAmD,GAAG;EACjEC,IAAI,EAAE,KAAK;EACXC,EAAE,EAAE,KAAK;EACTC,MAAM,EAAE,KAAK;EACbC,OAAO,EAAEN,OAAO;EAChBO,MAAM,EAAE,IAAI;EACZC,UAAU,EAAE,CAAC,KAAK,EAAE,KAAK,CAAC;EAC1BC,SAAS,EAAE,CAAC,0BAA0B,CAAC;EACvCC,IAAI,EAAE,IAAI;EACVC,MAAM,EAAE,IAAI;EACZC,KAAK,EAAE,CAAC,KAAK,CAAC;EACdC,OAAO,EAAE;IACPC,GAAG,EAAE;MACHC,KAAK,EAAE,MAAM;MACbC,IAAI,EAAE,KAAK;MACXC,IAAI,EAAE,CAAC;MACPC,UAAU,EAAE;IACd;EACF;AACF,CAAC"}
|
package/dist/las-worker.js
CHANGED
|
@@ -17,6 +17,9 @@
|
|
|
17
17
|
}
|
|
18
18
|
});
|
|
19
19
|
|
|
20
|
+
// ../worker-utils/src/lib/node/worker_threads-browser.ts
|
|
21
|
+
var parentPort = null;
|
|
22
|
+
|
|
20
23
|
// ../worker-utils/src/lib/worker-utils/get-transfer-list.ts
|
|
21
24
|
function getTransferList(object, recursive = true, transfers) {
|
|
22
25
|
const transfersSet = transfers || /* @__PURE__ */ new Set();
|
|
@@ -54,19 +57,6 @@
|
|
|
54
57
|
|
|
55
58
|
// ../worker-utils/src/lib/worker-farm/worker-body.ts
|
|
56
59
|
async function getParentPort() {
|
|
57
|
-
let parentPort;
|
|
58
|
-
try {
|
|
59
|
-
eval("globalThis.parentPort = require('worker_threads').parentPort");
|
|
60
|
-
parentPort = globalThis.parentPort;
|
|
61
|
-
} catch {
|
|
62
|
-
try {
|
|
63
|
-
eval("globalThis.workerThreadsPromise = import('worker_threads')");
|
|
64
|
-
const workerThreads = await globalThis.workerThreadsPromise;
|
|
65
|
-
parentPort = workerThreads.parentPort;
|
|
66
|
-
} catch (error) {
|
|
67
|
-
console.error(error.message);
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
60
|
return parentPort;
|
|
71
61
|
}
|
|
72
62
|
var onMessageWrapperMap = /* @__PURE__ */ new Map();
|
|
@@ -225,15 +215,7 @@
|
|
|
225
215
|
}
|
|
226
216
|
|
|
227
217
|
// src/las-loader.ts
|
|
228
|
-
var VERSION = true ? "4.0.
|
|
229
|
-
var DEFAULT_LAS_OPTIONS = {
|
|
230
|
-
las: {
|
|
231
|
-
shape: "mesh",
|
|
232
|
-
fp64: false,
|
|
233
|
-
skip: 1,
|
|
234
|
-
colorDepth: 8
|
|
235
|
-
}
|
|
236
|
-
};
|
|
218
|
+
var VERSION = true ? "4.1.0-alpha.1" : "latest";
|
|
237
219
|
var LASLoader = {
|
|
238
220
|
name: "LAS",
|
|
239
221
|
id: "las",
|
|
@@ -247,7 +229,14 @@
|
|
|
247
229
|
text: true,
|
|
248
230
|
binary: true,
|
|
249
231
|
tests: ["LAS"],
|
|
250
|
-
options:
|
|
232
|
+
options: {
|
|
233
|
+
las: {
|
|
234
|
+
shape: "mesh",
|
|
235
|
+
fp64: false,
|
|
236
|
+
skip: 1,
|
|
237
|
+
colorDepth: 8
|
|
238
|
+
}
|
|
239
|
+
}
|
|
251
240
|
};
|
|
252
241
|
|
|
253
242
|
// ../schema/src/lib/table/simple-table/data-type.ts
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@loaders.gl/las",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.1.0-alpha.1",
|
|
4
4
|
"description": "Framework-independent loader for the LAS and LAZ formats",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -49,9 +49,9 @@
|
|
|
49
49
|
},
|
|
50
50
|
"dependencies": {
|
|
51
51
|
"@babel/runtime": "^7.3.1",
|
|
52
|
-
"@loaders.gl/loader-utils": "4.0.
|
|
53
|
-
"@loaders.gl/schema": "4.0.
|
|
52
|
+
"@loaders.gl/loader-utils": "4.1.0-alpha.1",
|
|
53
|
+
"@loaders.gl/schema": "4.1.0-alpha.1",
|
|
54
54
|
"laz-perf": "^0.0.6"
|
|
55
55
|
},
|
|
56
|
-
"gitHead": "
|
|
56
|
+
"gitHead": "6a4d3da93d45115ad99861474a43c3f4a0b280a7"
|
|
57
57
|
}
|
package/src/index.ts
CHANGED
package/src/las-loader.ts
CHANGED
|
@@ -16,17 +16,9 @@ export type LASLoaderOptions = LoaderOptions & {
|
|
|
16
16
|
onProgress?: Function;
|
|
17
17
|
};
|
|
18
18
|
|
|
19
|
-
const DEFAULT_LAS_OPTIONS: LASLoaderOptions = {
|
|
20
|
-
las: {
|
|
21
|
-
shape: 'mesh',
|
|
22
|
-
fp64: false,
|
|
23
|
-
skip: 1,
|
|
24
|
-
colorDepth: 8
|
|
25
|
-
}
|
|
26
|
-
};
|
|
27
|
-
|
|
28
19
|
/**
|
|
29
20
|
* Loader for the LAS (LASer) point cloud format
|
|
21
|
+
* @note Does not support LAS v1.4
|
|
30
22
|
*/
|
|
31
23
|
export const LASLoader: Loader<LASMesh, never, LASLoaderOptions> = {
|
|
32
24
|
name: 'LAS',
|
|
@@ -39,5 +31,12 @@ export const LASLoader: Loader<LASMesh, never, LASLoaderOptions> = {
|
|
|
39
31
|
text: true,
|
|
40
32
|
binary: true,
|
|
41
33
|
tests: ['LAS'],
|
|
42
|
-
options:
|
|
34
|
+
options: {
|
|
35
|
+
las: {
|
|
36
|
+
shape: 'mesh',
|
|
37
|
+
fp64: false,
|
|
38
|
+
skip: 1,
|
|
39
|
+
colorDepth: 8
|
|
40
|
+
}
|
|
41
|
+
}
|
|
43
42
|
};
|