@loaders.gl/core 5.0.0-beta.1 → 5.0.0-beta.4

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.
Files changed (143) hide show
  1. package/README.md +3 -1
  2. package/dist/cluster-source.cjs +7228 -0
  3. package/dist/cluster-source.cjs.map +6 -0
  4. package/dist/cluster-source.d.ts +2 -0
  5. package/dist/cluster-source.d.ts.map +1 -0
  6. package/dist/cluster-source.js +2 -0
  7. package/dist/cluster-source.js.map +1 -0
  8. package/dist/dist.dev.js +2141 -438
  9. package/dist/dist.min.js +3 -3
  10. package/dist/federated-table-scan-source.cjs +2677 -0
  11. package/dist/federated-table-scan-source.cjs.map +6 -0
  12. package/dist/federated-table-scan-source.d.ts +2 -0
  13. package/dist/federated-table-scan-source.d.ts.map +1 -0
  14. package/dist/federated-table-scan-source.js +2 -0
  15. package/dist/federated-table-scan-source.js.map +1 -0
  16. package/dist/index.cjs +268 -960
  17. package/dist/index.cjs.map +3 -3
  18. package/dist/lib/init.js +1 -1
  19. package/dist/loader-utils/index.cjs +418 -1234
  20. package/dist/loader-utils/index.cjs.map +3 -3
  21. package/dist/loader-utils/json-loader.js +1 -1
  22. package/dist/loader-utils/lib/log-utils/log.js +1 -1
  23. package/dist/loader-utils/lib/worker-loader-utils/encode-with-worker.d.ts.map +1 -1
  24. package/dist/loader-utils/lib/worker-loader-utils/encode-with-worker.js +2 -5
  25. package/dist/loader-utils/lib/worker-loader-utils/encode-with-worker.js.map +1 -1
  26. package/dist/loader-utils/lib/worker-loader-utils/parse-with-worker.d.ts.map +1 -1
  27. package/dist/loader-utils/lib/worker-loader-utils/parse-with-worker.js +14 -6
  28. package/dist/loader-utils/lib/worker-loader-utils/parse-with-worker.js.map +1 -1
  29. package/dist/loader-utils/loader-types.d.ts +2 -2
  30. package/dist/loader-utils/loader-types.d.ts.map +1 -1
  31. package/dist/null-loader.js +1 -1
  32. package/dist/null-worker-node.js +538 -82
  33. package/dist/null-worker.js +514 -81
  34. package/dist/polyfills/images/encode-image-node.d.ts +18 -15
  35. package/dist/polyfills/images/encode-image-node.d.ts.map +1 -1
  36. package/dist/polyfills/images/encode-image-node.js +19 -33
  37. package/dist/polyfills/images/encode-image-node.js.map +1 -1
  38. package/dist/polyfills/images/image-codecs-node.d.ts +2 -6
  39. package/dist/polyfills/images/image-codecs-node.d.ts.map +1 -1
  40. package/dist/polyfills/images/image-codecs-node.js +2 -24
  41. package/dist/polyfills/images/image-codecs-node.js.map +1 -1
  42. package/dist/polyfills/images/load-sharp.d.ts +3 -0
  43. package/dist/polyfills/images/load-sharp.d.ts.map +1 -0
  44. package/dist/polyfills/images/load-sharp.js +11 -0
  45. package/dist/polyfills/images/load-sharp.js.map +1 -0
  46. package/dist/polyfills/images/node-image-bitmap.d.ts +1 -1
  47. package/dist/polyfills/images/node-image-bitmap.js +1 -1
  48. package/dist/polyfills/images/node-image-formats.d.ts +1 -1
  49. package/dist/polyfills/images/node-image-formats.d.ts.map +1 -1
  50. package/dist/polyfills/images/node-image-formats.js +10 -4
  51. package/dist/polyfills/images/node-image-formats.js.map +1 -1
  52. package/dist/polyfills/images/parse-image-node.d.ts +10 -2
  53. package/dist/polyfills/images/parse-image-node.d.ts.map +1 -1
  54. package/dist/polyfills/images/parse-image-node.js +20 -32
  55. package/dist/polyfills/images/parse-image-node.js.map +1 -1
  56. package/dist/polyfills/index.cjs +73 -149
  57. package/dist/vector-table-scan-source.cjs +1703 -0
  58. package/dist/vector-table-scan-source.cjs.map +6 -0
  59. package/dist/vector-table-scan-source.d.ts +2 -0
  60. package/dist/vector-table-scan-source.d.ts.map +1 -0
  61. package/dist/vector-table-scan-source.js +2 -0
  62. package/dist/vector-table-scan-source.js.map +1 -0
  63. package/dist/worker-utils/index.cjs +371 -1182
  64. package/dist/worker-utils/index.cjs.map +3 -3
  65. package/dist/worker-utils/index.d.ts +5 -8
  66. package/dist/worker-utils/index.d.ts.map +1 -1
  67. package/dist/worker-utils/index.js +4 -10
  68. package/dist/worker-utils/index.js.map +1 -1
  69. package/dist/worker-utils/lib/env-utils/version.js +1 -1
  70. package/dist/worker-utils/lib/worker-api/create-worker.d.ts +5 -7
  71. package/dist/worker-utils/lib/worker-api/create-worker.d.ts.map +1 -1
  72. package/dist/worker-utils/lib/worker-api/create-worker.js +76 -146
  73. package/dist/worker-utils/lib/worker-api/create-worker.js.map +1 -1
  74. package/dist/worker-utils/lib/worker-api/process-on-worker.d.ts +16 -47
  75. package/dist/worker-utils/lib/worker-api/process-on-worker.d.ts.map +1 -1
  76. package/dist/worker-utils/lib/worker-api/process-on-worker.js +214 -312
  77. package/dist/worker-utils/lib/worker-api/process-on-worker.js.map +1 -1
  78. package/dist/worker-utils/lib/worker-api/task-runtime.d.ts +36 -0
  79. package/dist/worker-utils/lib/worker-api/task-runtime.d.ts.map +1 -0
  80. package/dist/worker-utils/lib/worker-api/task-runtime.js +23 -0
  81. package/dist/worker-utils/lib/worker-api/task-runtime.js.map +1 -0
  82. package/dist/worker-utils/lib/worker-utils/get-transfer-list.d.ts +1 -0
  83. package/dist/worker-utils/lib/worker-utils/get-transfer-list.d.ts.map +1 -1
  84. package/dist/worker-utils/lib/worker-utils/get-transfer-list.js +3 -1
  85. package/dist/worker-utils/lib/worker-utils/get-transfer-list.js.map +1 -1
  86. package/dist/worker-utils/null-worker-node.js +603 -147
  87. package/dist/worker-utils/null-worker-node.js.map +4 -4
  88. package/dist/worker-utils/null-worker.js +576 -143
  89. package/dist/worker-utils/null-worker.js.map +4 -4
  90. package/dist/worker-utils/types.d.ts +55 -72
  91. package/dist/worker-utils/types.d.ts.map +1 -1
  92. package/package.json +27 -29
  93. package/src/cluster-source.ts +1 -0
  94. package/src/federated-table-scan-source.ts +1 -0
  95. package/src/loader-utils/lib/worker-loader-utils/encode-with-worker.ts +5 -6
  96. package/src/loader-utils/lib/worker-loader-utils/parse-with-worker.ts +14 -6
  97. package/src/loader-utils/loader-types.ts +2 -2
  98. package/src/polyfills/README.md +2 -2
  99. package/src/polyfills/images/encode-image-node.ts +44 -37
  100. package/src/polyfills/images/image-codecs-node.ts +2 -37
  101. package/src/polyfills/images/load-sharp.ts +13 -0
  102. package/src/polyfills/images/node-image-bitmap.ts +1 -1
  103. package/src/polyfills/images/node-image-formats.ts +10 -4
  104. package/src/polyfills/images/parse-image-node.ts +31 -40
  105. package/src/vector-table-scan-source.ts +1 -0
  106. package/src/worker-utils/index.ts +17 -17
  107. package/src/worker-utils/lib/worker-api/create-worker.ts +89 -188
  108. package/src/worker-utils/lib/worker-api/process-on-worker.ts +249 -403
  109. package/src/worker-utils/lib/worker-api/task-runtime.ts +66 -0
  110. package/src/worker-utils/lib/worker-utils/get-transfer-list.ts +2 -0
  111. package/src/worker-utils/types.ts +74 -109
  112. package/dist/worker-utils/lib/async-queue/async-queue.d.ts +0 -32
  113. package/dist/worker-utils/lib/async-queue/async-queue.d.ts.map +0 -1
  114. package/dist/worker-utils/lib/async-queue/async-queue.js +0 -91
  115. package/dist/worker-utils/lib/async-queue/async-queue.js.map +0 -1
  116. package/dist/worker-utils/lib/worker-farm/worker-body.d.ts +0 -20
  117. package/dist/worker-utils/lib/worker-farm/worker-body.d.ts.map +0 -1
  118. package/dist/worker-utils/lib/worker-farm/worker-body.js +0 -131
  119. package/dist/worker-utils/lib/worker-farm/worker-body.js.map +0 -1
  120. package/dist/worker-utils/lib/worker-farm/worker-farm.d.ts +0 -58
  121. package/dist/worker-utils/lib/worker-farm/worker-farm.d.ts.map +0 -1
  122. package/dist/worker-utils/lib/worker-farm/worker-farm.js +0 -116
  123. package/dist/worker-utils/lib/worker-farm/worker-farm.js.map +0 -1
  124. package/dist/worker-utils/lib/worker-farm/worker-job.d.ts +0 -34
  125. package/dist/worker-utils/lib/worker-farm/worker-job.d.ts.map +0 -1
  126. package/dist/worker-utils/lib/worker-farm/worker-job.js +0 -74
  127. package/dist/worker-utils/lib/worker-farm/worker-job.js.map +0 -1
  128. package/dist/worker-utils/lib/worker-farm/worker-pool.d.ts +0 -94
  129. package/dist/worker-utils/lib/worker-farm/worker-pool.d.ts.map +0 -1
  130. package/dist/worker-utils/lib/worker-farm/worker-pool.js +0 -246
  131. package/dist/worker-utils/lib/worker-farm/worker-pool.js.map +0 -1
  132. package/dist/worker-utils/lib/worker-farm/worker-thread.d.ts +0 -67
  133. package/dist/worker-utils/lib/worker-farm/worker-thread.d.ts.map +0 -1
  134. package/dist/worker-utils/lib/worker-farm/worker-thread.js +0 -175
  135. package/dist/worker-utils/lib/worker-farm/worker-thread.js.map +0 -1
  136. package/src/polyfills/images/encode-image.node.ts.disabled +0 -41
  137. package/src/polyfills/images/parse-image.node.ts.disabled +0 -55
  138. package/src/worker-utils/lib/async-queue/async-queue.ts +0 -100
  139. package/src/worker-utils/lib/worker-farm/worker-body.ts +0 -145
  140. package/src/worker-utils/lib/worker-farm/worker-farm.ts +0 -144
  141. package/src/worker-utils/lib/worker-farm/worker-job.ts +0 -85
  142. package/src/worker-utils/lib/worker-farm/worker-pool.ts +0 -316
  143. package/src/worker-utils/lib/worker-farm/worker-thread.ts +0 -206
@@ -0,0 +1,23 @@
1
+ // loaders.gl
2
+ // SPDX-License-Identifier: MIT
3
+ // Copyright (c) vis.gl contributors
4
+ import { initializeTaskWorker as initializeMathTaskWorker } from '@math.gl/core/tasks';
5
+ /** Normalizes optional task labels for loader progress consumers. */
6
+ export function normalizeTaskProgress(progress) {
7
+ return { ...progress, phase: progress.phase ?? 'process', unit: progress.unit ?? 'items' };
8
+ }
9
+ /** Detects worker execution without importing Node APIs into browser bundles. */
10
+ export async function isWorkerThread() {
11
+ if (typeof self !== 'undefined' &&
12
+ typeof document === 'undefined' &&
13
+ typeof self.postMessage === 'function')
14
+ return true;
15
+ if (typeof process !== 'undefined' && process.versions?.node) {
16
+ const { isMainThread } = await import("../node/worker_threads.js");
17
+ return !isMainThread;
18
+ }
19
+ return false;
20
+ }
21
+ /** Installs the upstream runtime, including its Node CommonJS worker support. */
22
+ export const initializeTaskWorker = initializeMathTaskWorker;
23
+ //# sourceMappingURL=task-runtime.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"task-runtime.js","sourceRoot":"","sources":["../../../../src/worker-utils/lib/worker-api/task-runtime.ts"],"names":[],"mappings":"AAAA,aAAa;AACb,+BAA+B;AAC/B,oCAAoC;AAEpC,OAAO,EACL,oBAAoB,IAAI,wBAAwB,EAGjD,MAAM,qBAAqB,CAAC;AAkC7B,qEAAqE;AACrE,MAAM,UAAU,qBAAqB,CACnC,QAAsD;IAEtD,OAAO,EAAC,GAAG,QAAQ,EAAE,KAAK,EAAE,QAAQ,CAAC,KAAK,IAAI,SAAS,EAAE,IAAI,EAAE,QAAQ,CAAC,IAAI,IAAI,OAAO,EAAC,CAAC;AAC3F,CAAC;AAED,iFAAiF;AACjF,MAAM,CAAC,KAAK,UAAU,cAAc;IAClC,IACE,OAAO,IAAI,KAAK,WAAW;QAC3B,OAAO,QAAQ,KAAK,WAAW;QAC/B,OAAO,IAAI,CAAC,WAAW,KAAK,UAAU;QAEtC,OAAO,IAAI,CAAC;IACd,IAAI,OAAO,OAAO,KAAK,WAAW,IAAI,OAAO,CAAC,QAAQ,EAAE,IAAI,EAAE,CAAC;QAC7D,MAAM,EAAC,YAAY,EAAC,GAAG,MAAM,MAAM,6BAA0B,CAAC;QAC9D,OAAO,CAAC,YAAY,CAAC;IACvB,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC;AAED,iFAAiF;AACjF,MAAM,CAAC,MAAM,oBAAoB,GAAG,wBAAwB,CAAC"}
@@ -9,6 +9,7 @@
9
9
  export declare function getTransferList(object: any, recursive?: boolean, transfers?: Set<any>): Transferable[];
10
10
  /**
11
11
  * Recursively drop non serializable values like functions and regexps.
12
+ * Preserve nested null values; a null top-level options argument normalizes to an empty object.
12
13
  * @param object
13
14
  */
14
15
  export declare function getTransferListForWriter(object: object | null): object;
@@ -1 +1 @@
1
- {"version":3,"file":"get-transfer-list.d.ts","sourceRoot":"","sources":["../../../../src/worker-utils/lib/worker-utils/get-transfer-list.ts"],"names":[],"mappings":"AAOA;;;;;;;GAOG;AACH,wBAAgB,eAAe,CAC7B,MAAM,EAAE,GAAG,EACX,SAAS,GAAE,OAAc,EACzB,SAAS,CAAC,EAAE,GAAG,CAAC,GAAG,CAAC,GACnB,YAAY,EAAE,CAwBhB;AAuBD;;;GAGG;AACH,wBAAgB,wBAAwB,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,GAAG,MAAM,CAsBtE"}
1
+ {"version":3,"file":"get-transfer-list.d.ts","sourceRoot":"","sources":["../../../../src/worker-utils/lib/worker-utils/get-transfer-list.ts"],"names":[],"mappings":"AAOA;;;;;;;GAOG;AACH,wBAAgB,eAAe,CAC7B,MAAM,EAAE,GAAG,EACX,SAAS,GAAE,OAAc,EACzB,SAAS,CAAC,EAAE,GAAG,CAAC,GAAG,CAAC,GACnB,YAAY,EAAE,CAwBhB;AAuBD;;;;GAIG;AACH,wBAAgB,wBAAwB,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,GAAG,MAAM,CAuBtE"}
@@ -60,6 +60,7 @@ function isTransferable(object) {
60
60
  }
61
61
  /**
62
62
  * Recursively drop non serializable values like functions and regexps.
63
+ * Preserve nested null values; a null top-level options argument normalizes to an empty object.
63
64
  * @param object
64
65
  */
65
66
  export function getTransferListForWriter(object) {
@@ -69,7 +70,8 @@ export function getTransferListForWriter(object) {
69
70
  const clone = Object.assign({}, object);
70
71
  Object.keys(clone).forEach(key => {
71
72
  // Typed Arrays and Arrays are passed with no change
72
- if (typeof object[key] === 'object' &&
73
+ if (object[key] !== null &&
74
+ typeof object[key] === 'object' &&
73
75
  !ArrayBuffer.isView(object[key]) &&
74
76
  !(object[key] instanceof Array)) {
75
77
  clone[key] = getTransferListForWriter(object[key]);
@@ -1 +1 @@
1
- {"version":3,"file":"get-transfer-list.js","sourceRoot":"","sources":["../../../../src/worker-utils/lib/worker-utils/get-transfer-list.ts"],"names":[],"mappings":"AAAA,aAAa;AACb,+BAA+B;AAC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C"}
1
+ {"version":3,"file":"get-transfer-list.js","sourceRoot":"","sources":["../../../../src/worker-utils/lib/worker-utils/get-transfer-list.ts"],"names":[],"mappings":"AAAA,aAAa;AACb,+BAA+B;AAC/B,oCAAoC;AAEpC,2EAA2E;AAC3E,mEAAmE;AAEnE;;;;;;;GAOG;AACH,MAAM,UAAU,eAAe,CAC7B,MAAW,EACX,YAAqB,IAAI,EACzB,SAAoB;IAEpB,sDAAsD;IACtD,MAAM,YAAY,GAAG,SAAS,IAAI,IAAI,GAAG,EAAE,CAAC;IAE5C,IAAI,CAAC,MAAM,EAAE,CAAC;QACZ,SAAS;IACX,CAAC;SAAM,IAAI,cAAc,CAAC,MAAM,CAAC,EAAE,CAAC;QAClC,YAAY,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IAC3B,CAAC;SAAM,IAAI,cAAc,CAAC,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC;QACzC,cAAc;QACd,YAAY,CAAC,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;IAClC,CAAC;SAAM,IAAI,WAAW,CAAC,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC;QACtC,4EAA4E;QAC5E,kDAAkD;IACpD,CAAC;SAAM,IAAI,SAAS,IAAI,OAAO,MAAM,KAAK,QAAQ,EAAE,CAAC;QACnD,KAAK,MAAM,GAAG,IAAI,MAAM,EAAE,CAAC;YACzB,0CAA0C;YAC1C,eAAe,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE,SAAS,EAAE,YAAY,CAAC,CAAC;QACxD,CAAC;IACH,CAAC;IAED,sDAAsD;IACtD,oCAAoC;IACpC,OAAO,SAAS,KAAK,SAAS,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC;AACjE,CAAC;AAED,gEAAgE;AAChE,SAAS,cAAc,CAAC,MAAe;IACrC,IAAI,CAAC,MAAM,EAAE,CAAC;QACZ,OAAO,KAAK,C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