@loaders.gl/tiles-3d 5.0.0-beta.4 → 5.0.0-beta.6

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 (65) hide show
  1. package/README.md +1 -1
  2. package/dist/3d-tiles/3d-tiles-archive-loader.js +1 -1
  3. package/dist/3d-tiles/dist.dev.js +941 -621
  4. package/dist/3d-tiles/dist.min.js +37 -37
  5. package/dist/3d-tiles/index.cjs +876 -947
  6. package/dist/3d-tiles/index.cjs.map +3 -3
  7. package/dist/3d-tiles/lib/parsers/parse-3d-tile-instanced-model.js +5 -1
  8. package/dist/3d-tiles/lib/parsers/parse-3d-tile-instanced-model.js.map +1 -1
  9. package/dist/3d-tiles/lib/utils/version.js +1 -1
  10. package/dist/3d-tiles-archive-writer.cjs +1 -1
  11. package/dist/cesium-ion-loader-with-parser.cjs +821 -942
  12. package/dist/cesium-ion-loader-with-parser.cjs.map +3 -3
  13. package/dist/copc/copc-source-loader.js +2 -2
  14. package/dist/copc/copc-source-loader.js.map +1 -1
  15. package/dist/copc/copc-writer.js +1 -1
  16. package/dist/copc/index.cjs +121 -181
  17. package/dist/copc/index.cjs.map +3 -3
  18. package/dist/dist.dev.js +323 -40
  19. package/dist/dist.min.js +10 -10
  20. package/dist/i3s/arcgis-webscene-loader.js +1 -1
  21. package/dist/i3s/dist.dev.js +3173 -712
  22. package/dist/i3s/dist.min.js +47 -47
  23. package/dist/i3s/i3s-attribute-loader.js +1 -1
  24. package/dist/i3s/i3s-building-scene-layer-loader.js +1 -1
  25. package/dist/i3s/i3s-content-loader.js +1 -1
  26. package/dist/i3s/i3s-lepcc-loader-types.js +1 -1
  27. package/dist/i3s/i3s-loader.js +1 -1
  28. package/dist/i3s/i3s-node-page-loader.js +1 -1
  29. package/dist/i3s/i3s-slpk-loader.js +1 -1
  30. package/dist/i3s/i3s-slpk-writer.js +1 -1
  31. package/dist/i3s/index.cjs +2097 -544
  32. package/dist/i3s/index.cjs.map +3 -3
  33. package/dist/i3s-content-worker-node.js +11 -11
  34. package/dist/i3s-content-worker-node.js.map +4 -4
  35. package/dist/i3s-content-worker.js +768 -346
  36. package/dist/i3s-lepcc-worker-node.js +245 -12
  37. package/dist/i3s-lepcc-worker-node.js.map +4 -4
  38. package/dist/i3s-lepcc-worker.js +240 -12
  39. package/dist/i3s-mesh-writer.cjs +1749 -290
  40. package/dist/i3s-mesh-writer.cjs.map +3 -3
  41. package/dist/i3s-slpk-writer.cjs +1 -1
  42. package/dist/index.cjs +98 -4
  43. package/dist/index.cjs.map +2 -2
  44. package/dist/point-cloud-tile-source-loader-types.js +1 -1
  45. package/dist/point-cloud-tile-source-loader.cjs +46 -2
  46. package/dist/point-cloud-tile-source-loader.cjs.map +2 -2
  47. package/dist/point-cloud-tile-source.cjs +45 -1
  48. package/dist/point-cloud-tile-source.cjs.map +1 -1
  49. package/dist/potree/dist.dev.js +325 -91
  50. package/dist/potree/dist.min.js +30 -30
  51. package/dist/potree/index.cjs +115 -176
  52. package/dist/potree/index.cjs.map +3 -3
  53. package/dist/potree/potree-bin-loader.js +1 -1
  54. package/dist/potree/potree-hierarchy-chunk-loader.js +1 -1
  55. package/dist/potree/potree-loader-types.js +1 -1
  56. package/dist/potree/potree-source-loader.js +1 -1
  57. package/dist/potree/potree-writer.js +1 -1
  58. package/dist/potree/potree2-source.d.ts.map +1 -1
  59. package/dist/potree/potree2-source.js +3 -13
  60. package/dist/potree/potree2-source.js.map +1 -1
  61. package/dist/potree-loader.cjs +1 -1
  62. package/package.json +13 -13
  63. package/src/3d-tiles/lib/parsers/parse-3d-tile-instanced-model.ts +4 -1
  64. package/src/copc/copc-source-loader.ts +1 -1
  65. package/src/potree/potree2-source.ts +3 -14
@@ -112,7 +112,7 @@
112
112
 
113
113
  // ../core/src/worker-utils/lib/env-utils/version.ts
114
114
  function getVersion() {
115
- const version = false ? NPM_TAG : "5.0.0-beta.4";
115
+ const version = false ? NPM_TAG : "5.0.0-beta.6";
116
116
  globalThis._loadersgl_ = globalThis._loadersgl_ || {};
117
117
  globalThis._loadersgl_.version ||= version;
118
118
  return version;
@@ -161,15 +161,15 @@
161
161
  }
162
162
  });
163
163
 
164
- // ../../node_modules/@math.gl/core/dist/worker-utils/lib/node/worker_threads-browser.js
164
+ // ../../node_modules/@math.gl/tasks/dist/worker-utils/lib/node/worker_threads-browser.js
165
165
  var parentPort;
166
166
  var init_worker_threads_browser = __esm({
167
- "../../node_modules/@math.gl/core/dist/worker-utils/lib/node/worker_threads-browser.js"() {
167
+ "../../node_modules/@math.gl/tasks/dist/worker-utils/lib/node/worker_threads-browser.js"() {
168
168
  parentPort = globalThis.process?.getBuiltinModule?.("node:worker_threads")?.parentPort ?? null;
169
169
  }
170
170
  });
171
171
 
172
- // ../../node_modules/@math.gl/core/dist/worker-utils/lib/worker-utils/get-transfer-list.js
172
+ // ../../node_modules/@math.gl/tasks/dist/worker-utils/lib/worker-utils/get-transfer-list.js
173
173
  function getTransferList(object2, recursive = true, transfers) {
174
174
  const transfersSet = transfers || /* @__PURE__ */ new Set();
175
175
  const seen = /* @__PURE__ */ new Set();
@@ -220,11 +220,11 @@
220
220
  return false;
221
221
  }
222
222
  var init_get_transfer_list = __esm({
223
- "../../node_modules/@math.gl/core/dist/worker-utils/lib/worker-utils/get-transfer-list.js"() {
223
+ "../../node_modules/@math.gl/tasks/dist/worker-utils/lib/worker-utils/get-transfer-list.js"() {
224
224
  }
225
225
  });
226
226
 
227
- // ../../node_modules/@math.gl/core/dist/worker-utils/lib/worker-farm/worker-body.js
227
+ // ../../node_modules/@math.gl/tasks/dist/worker-utils/lib/worker-farm/worker-body.js
228
228
  async function getParentPort() {
229
229
  return parentPort;
230
230
  }
@@ -237,7 +237,7 @@
237
237
  }
238
238
  var onMessageWrapperMap, WorkerBody;
239
239
  var init_worker_body = __esm({
240
- "../../node_modules/@math.gl/core/dist/worker-utils/lib/worker-farm/worker-body.js"() {
240
+ "../../node_modules/@math.gl/tasks/dist/worker-utils/lib/worker-farm/worker-body.js"() {
241
241
  init_get_transfer_list();
242
242
  init_worker_threads_browser();
243
243
  onMessageWrapperMap = /* @__PURE__ */ new Map();
@@ -318,10 +318,10 @@
318
318
  }
319
319
  });
320
320
 
321
- // ../../node_modules/@math.gl/core/dist/worker-utils/lib/async-queue/async-queue.js
321
+ // ../../node_modules/@math.gl/tasks/dist/worker-utils/lib/async-queue/async-queue.js
322
322
  var AsyncQueue;
323
323
  var init_async_queue = __esm({
324
- "../../node_modules/@math.gl/core/dist/worker-utils/lib/async-queue/async-queue.js"() {
324
+ "../../node_modules/@math.gl/tasks/dist/worker-utils/lib/async-queue/async-queue.js"() {
325
325
  AsyncQueue = class {
326
326
  constructor() {
327
327
  this._values = [];
@@ -390,10 +390,10 @@
390
390
  }
391
391
  });
392
392
 
393
- // ../../node_modules/@math.gl/core/dist/worker-utils/lib/worker-api/shared-state.js
393
+ // ../../node_modules/@math.gl/tasks/dist/worker-utils/lib/worker-api/shared-state.js
394
394
  var SharedWorkerState;
395
395
  var init_shared_state = __esm({
396
- "../../node_modules/@math.gl/core/dist/worker-utils/lib/worker-api/shared-state.js"() {
396
+ "../../node_modules/@math.gl/tasks/dist/worker-utils/lib/worker-api/shared-state.js"() {
397
397
  SharedWorkerState = class {
398
398
  constructor(buffer) {
399
399
  if (typeof SharedArrayBuffer === "undefined" || !(buffer instanceof SharedArrayBuffer) || buffer.byteLength !== 16)
@@ -434,18 +434,18 @@
434
434
  }
435
435
  });
436
436
 
437
- // ../../node_modules/@math.gl/core/dist/worker-utils/lib/worker-api/validate-output-ownership.js
437
+ // ../../node_modules/@math.gl/tasks/dist/worker-utils/lib/worker-api/validate-output-ownership.js
438
438
  function validateOutputOwnership(ownership) {
439
439
  if (ownership !== void 0 && ownership !== "copy" && ownership !== "transfer") {
440
440
  throw new Error("Invalid worker output ownership");
441
441
  }
442
442
  }
443
443
  var init_validate_output_ownership = __esm({
444
- "../../node_modules/@math.gl/core/dist/worker-utils/lib/worker-api/validate-output-ownership.js"() {
444
+ "../../node_modules/@math.gl/tasks/dist/worker-utils/lib/worker-api/validate-output-ownership.js"() {
445
445
  }
446
446
  });
447
447
 
448
- // ../../node_modules/@math.gl/core/dist/worker-utils/lib/worker-api/create-worker.js
448
+ // ../../node_modules/@math.gl/tasks/dist/worker-utils/lib/worker-api/create-worker.js
449
449
  async function createWorker(process2, processInBatches, preload5) {
450
450
  if (!await WorkerBody.inWorkerThread()) {
451
451
  return;
@@ -650,7 +650,7 @@
650
650
  }
651
651
  var requestId, activeController, activeInputBatches, activeOutputAcknowledgements;
652
652
  var init_create_worker = __esm({
653
- "../../node_modules/@math.gl/core/dist/worker-utils/lib/worker-api/create-worker.js"() {
653
+ "../../node_modules/@math.gl/tasks/dist/worker-utils/lib/worker-api/create-worker.js"() {
654
654
  init_shared_state();
655
655
  init_async_queue();
656
656
  init_worker_body();
@@ -662,19 +662,20 @@
662
662
  }
663
663
  });
664
664
 
665
- // ../../node_modules/@math.gl/core/dist/worker-utils/index.js
665
+ // ../../node_modules/@math.gl/tasks/dist/worker-utils/index.js
666
666
  var import_meta, path, moduleUrl;
667
667
  var init_worker_utils = __esm({
668
- "../../node_modules/@math.gl/core/dist/worker-utils/index.js"() {
668
+ "../../node_modules/@math.gl/tasks/dist/worker-utils/index.js"() {
669
669
  init_worker_body();
670
670
  init_create_worker();
671
+ init_get_transfer_list();
671
672
  import_meta = {};
672
673
  path = typeof __filename === "string" ? __filename.replace(/\\/g, "/") : "";
673
674
  moduleUrl = path ? `file://${path.startsWith("/") ? "" : "/"}${encodeURI(path).replace(/#/g, "%23").replace(/\?/g, "%3F")}` : import_meta.url;
674
675
  }
675
676
  });
676
677
 
677
- // ../../node_modules/@math.gl/core/dist/tasks/task-preload.js
678
+ // ../../node_modules/@math.gl/tasks/dist/tasks/task-preload.js
678
679
  function preloadTaskCode(task, signal) {
679
680
  if (!task.preload)
680
681
  return Promise.resolve();
@@ -710,23 +711,193 @@
710
711
  }
711
712
  var pending, loaded;
712
713
  var init_task_preload = __esm({
713
- "../../node_modules/@math.gl/core/dist/tasks/task-preload.js"() {
714
+ "../../node_modules/@math.gl/tasks/dist/tasks/task-preload.js"() {
714
715
  pending = /* @__PURE__ */ new WeakMap();
715
716
  loaded = /* @__PURE__ */ new WeakSet();
716
717
  }
717
718
  });
718
719
 
719
- // ../../node_modules/@math.gl/core/dist/tasks/task-runtime.js
720
+ // ../../node_modules/@math.gl/tasks/dist/tasks/task-channel.js
721
+ var TaskRequestError, TaskChannel;
722
+ var init_task_channel = __esm({
723
+ "../../node_modules/@math.gl/tasks/dist/tasks/task-channel.js"() {
724
+ TaskRequestError = class extends Error {
725
+ };
726
+ TaskChannel = class {
727
+ constructor(options) {
728
+ this.options = options;
729
+ this.nextId = 1;
730
+ this.pending = /* @__PURE__ */ new Map();
731
+ this.incoming = /* @__PURE__ */ new Map();
732
+ }
733
+ /** Send a request without serializing other in-flight requests. */
734
+ request(operation2, value2, signal, transfer = []) {
735
+ if (this.failure)
736
+ return Promise.reject(this.failure.reason);
737
+ if (signal?.aborted)
738
+ return Promise.reject(signal.reason);
739
+ const id = this.nextId++;
740
+ return new Promise((resolve, reject) => {
741
+ const abort = () => {
742
+ const pending2 = this.pending.get(id);
743
+ if (!pending2)
744
+ return;
745
+ this.pending.delete(id);
746
+ pending2.cleanup();
747
+ reject(signal?.reason);
748
+ this.send({ source: "math.gl/tasks", kind: "cancel", id });
749
+ };
750
+ this.pending.set(id, {
751
+ resolve,
752
+ reject,
753
+ cleanup: () => signal?.removeEventListener("abort", abort)
754
+ });
755
+ signal?.addEventListener("abort", abort, { once: true });
756
+ this.send({ source: "math.gl/tasks", kind: "request", id, operation: operation2, value: value2 }, transfer);
757
+ });
758
+ }
759
+ /** Send a one-way notification. */
760
+ emit(operation2, value2, transfer = []) {
761
+ if (this.failure)
762
+ throw this.failure.reason;
763
+ this.send({ source: "math.gl/tasks", kind: "event", id: 0, operation: operation2, value: value2 }, transfer);
764
+ }
765
+ /** Dispatch a transport message; unrelated protocols are ignored. */
766
+ receive(message) {
767
+ if (this.failure || message?.source !== "math.gl/tasks")
768
+ return;
769
+ if (message.kind === "failure") {
770
+ const reason = new Error(message.error?.message ?? "Task channel failed");
771
+ this.close(reason);
772
+ this.options.onFailure?.(reason);
773
+ } else if (message.kind === "result" || message.kind === "error") {
774
+ const pending2 = this.pending.get(message.id);
775
+ if (!pending2)
776
+ return;
777
+ this.pending.delete(message.id);
778
+ pending2.cleanup();
779
+ if (message.kind === "result")
780
+ pending2.resolve(message.value);
781
+ else {
782
+ const error = new TaskRequestError(message.error?.message ?? "Task request failed");
783
+ error.name = message.error?.name ?? "Error";
784
+ pending2.reject(error);
785
+ }
786
+ } else if (message.kind === "cancel") {
787
+ this.incoming.get(message.id)?.abort(new DOMException("Task request cancelled", "AbortError"));
788
+ } else if (message.kind === "event") {
789
+ try {
790
+ this.options.handleEvent?.(message.operation, message.value);
791
+ } catch (error) {
792
+ this.fail(error);
793
+ }
794
+ } else if (message.kind === "request") {
795
+ if (this.incoming.has(message.id)) {
796
+ this.fail(new Error("Duplicate task request identifier"));
797
+ return;
798
+ }
799
+ const controller = new AbortController();
800
+ this.incoming.set(message.id, controller);
801
+ void Promise.resolve().then(() => {
802
+ controller.signal.throwIfAborted();
803
+ return this.options.handleRequest(message.operation, message.value, controller.signal);
804
+ }).then((value2) => {
805
+ if (!controller.signal.aborted && !this.failure) {
806
+ this.send({ source: "math.gl/tasks", kind: "result", id: message.id, value: value2 }, this.options.getResultTransferList?.(value2, message.value));
807
+ }
808
+ }).catch((reason) => {
809
+ if (!controller.signal.aborted && !this.failure) {
810
+ this.send({
811
+ source: "math.gl/tasks",
812
+ kind: "error",
813
+ id: message.id,
814
+ error: {
815
+ name: reason instanceof Error ? reason.name : "Error",
816
+ message: reason instanceof Error ? reason.message : String(reason)
817
+ }
818
+ });
819
+ }
820
+ }).finally(() => this.incoming.delete(message.id));
821
+ }
822
+ }
823
+ /** Reject all outstanding calls with a common cause and abort incoming callbacks. */
824
+ close(reason = new Error("Task channel closed")) {
825
+ if (this.failure)
826
+ return;
827
+ this.failure = { reason };
828
+ for (const pending2 of this.pending.values()) {
829
+ pending2.cleanup();
830
+ pending2.reject(reason);
831
+ }
832
+ this.pending.clear();
833
+ for (const controller of this.incoming.values())
834
+ controller.abort(reason);
835
+ this.incoming.clear();
836
+ }
837
+ send(message, transfer = []) {
838
+ if (this.failure)
839
+ return;
840
+ try {
841
+ this.options.send(message, transfer);
842
+ } catch (error) {
843
+ this.fail(error);
844
+ }
845
+ }
846
+ /** Invalidate the channel and notify the peer when the transport still works. */
847
+ fail(reason) {
848
+ if (this.failure)
849
+ return;
850
+ this.close(reason);
851
+ try {
852
+ this.options.send({
853
+ source: "math.gl/tasks",
854
+ kind: "failure",
855
+ id: 0,
856
+ error: {
857
+ name: reason instanceof Error ? reason.name : "Error",
858
+ message: reason instanceof Error ? reason.message : String(reason)
859
+ }
860
+ }, []);
861
+ } catch {
862
+ }
863
+ this.options.onFailure?.(reason);
864
+ }
865
+ };
866
+ }
867
+ });
868
+
869
+ // ../../node_modules/@math.gl/tasks/dist/tasks/task-runtime.js
720
870
  function assertPayload(value2) {
721
871
  if (!value2 || typeof value2 !== "object" || Object.getPrototypeOf(value2) !== Object.prototype) {
722
872
  throw new TypeError("Task payloads must be plain objects with named fields");
723
873
  }
724
874
  }
875
+ function clonePayload(value2, ownership = "copy") {
876
+ assertPayload(value2);
877
+ if (!["copy", "transfer", "share"].includes(ownership))
878
+ throw new TypeError("Invalid input ownership");
879
+ const transfer = getTransferList(value2);
880
+ if (ownership === "share" && transfer.length)
881
+ throw new TypeError("Share requires shared storage");
882
+ return structuredClone(value2, {
883
+ transfer: ownership === "transfer" ? transfer : []
884
+ });
885
+ }
725
886
  function taskContext(state, context = {}) {
726
887
  const signal = context.signal ?? new AbortController().signal;
727
888
  return {
728
889
  state,
729
890
  signal,
891
+ requestHost: async (operation2, payload, controls) => {
892
+ signal.throwIfAborted();
893
+ if (!context.requestHost)
894
+ throw new Error("No host request handler configured");
895
+ return context.requestHost(operation2, payload, controls);
896
+ },
897
+ emitHost: (operation2, payload) => {
898
+ signal.throwIfAborted();
899
+ context.emitHost?.(operation2, payload);
900
+ },
730
901
  throwIfAborted: () => {
731
902
  signal.throwIfAborted();
732
903
  context.throwIfAborted?.();
@@ -745,6 +916,69 @@
745
916
  throw new Error("A task is already installed in this worker");
746
917
  installed = true;
747
918
  const runtime = new TaskRuntime(task);
919
+ let channelStream;
920
+ const channel = new TaskChannel({
921
+ getResultTransferList: (value2, request) => request.outputOwnership === "transfer" ? getTransferList(value2) : [],
922
+ send: (message, transfer) => {
923
+ const snapshot = structuredClone(message, { transfer });
924
+ void WorkerBody.postMessage("task-channel", snapshot).catch((reason) => channel.fail(reason));
925
+ },
926
+ handleRequest: async (operation2, value2, signal) => {
927
+ const request = value2;
928
+ const context = {
929
+ signal,
930
+ reportProgress: (progress) => channel.emit("task:progress", { id: request.progressId, progress }),
931
+ requestHost: (operation3, payload, controls = {}) => {
932
+ const request2 = {
933
+ operation: operation3,
934
+ payload: clonePayload(payload, controls.inputOwnership),
935
+ outputOwnership: controls.outputOwnership ?? "copy"
936
+ };
937
+ return channel.request("task:host-request", request2, signal, getTransferList(request2));
938
+ },
939
+ emitHost: (operation3, payload) => channel.emit("task:host-event", { operation: operation3, payload, id: request.progressId })
940
+ };
941
+ switch (operation2) {
942
+ case "initialize":
943
+ return runtime.initialize(request.input, context);
944
+ case "process":
945
+ return runtime.process(request.input, request.options, context);
946
+ case "stream-open": {
947
+ if (channelStream)
948
+ throw new Error("A task stream is already open");
949
+ async function* inputs() {
950
+ while (true) {
951
+ const result = await channel.request("task:next-input", { outputOwnership: "transfer" }, signal);
952
+ if (result.done)
953
+ return;
954
+ yield result.value;
955
+ }
956
+ }
957
+ channelStream = runtime.stream(inputs(), request.options, context)[Symbol.asyncIterator]();
958
+ return {};
959
+ }
960
+ case "stream-next":
961
+ if (!channelStream)
962
+ throw new Error("No active task stream");
963
+ return channelStream.next();
964
+ case "stream-close":
965
+ try {
966
+ await channelStream?.return?.();
967
+ } finally {
968
+ channelStream = void 0;
969
+ }
970
+ return {};
971
+ case "destroy":
972
+ return runtime.destroy();
973
+ default:
974
+ throw new Error("Unknown task channel operation");
975
+ }
976
+ }
977
+ });
978
+ await WorkerBody.addEventListener((type, payload) => {
979
+ if (type === "task-channel")
980
+ channel.receive(payload);
981
+ });
748
982
  let streamOptions = {};
749
983
  return createWorker(async (request, _options, context) => {
750
984
  switch (request.operation) {
@@ -776,9 +1010,10 @@
776
1010
  }
777
1011
  var TaskRuntime, installed;
778
1012
  var init_task_runtime = __esm({
779
- "../../node_modules/@math.gl/core/dist/tasks/task-runtime.js"() {
1013
+ "../../node_modules/@math.gl/tasks/dist/tasks/task-runtime.js"() {
780
1014
  init_worker_utils();
781
1015
  init_task_preload();
1016
+ init_task_channel();
782
1017
  TaskRuntime = class {
783
1018
  constructor(task) {
784
1019
  this.task = task;
@@ -829,13 +1064,20 @@
829
1064
  }
830
1065
  });
831
1066
 
832
- // ../../node_modules/@math.gl/core/dist/tasks/index.js
1067
+ // ../../node_modules/@math.gl/tasks/dist/tasks/index.js
833
1068
  var init_tasks = __esm({
834
- "../../node_modules/@math.gl/core/dist/tasks/index.js"() {
1069
+ "../../node_modules/@math.gl/tasks/dist/tasks/index.js"() {
835
1070
  init_task_runtime();
836
1071
  }
837
1072
  });
838
1073
 
1074
+ // ../../node_modules/@math.gl/tasks/dist/index.js
1075
+ var init_dist = __esm({
1076
+ "../../node_modules/@math.gl/tasks/dist/index.js"() {
1077
+ init_tasks();
1078
+ }
1079
+ });
1080
+
839
1081
  // ../core/src/worker-utils/lib/node/worker_threads-browser.ts
840
1082
  var worker_threads_browser_exports = {};
841
1083
  __export(worker_threads_browser_exports, {
@@ -880,7 +1122,7 @@
880
1122
  var init_task_runtime2 = __esm({
881
1123
  "../core/src/worker-utils/lib/worker-api/task-runtime.ts"() {
882
1124
  "use strict";
883
- init_tasks();
1125
+ init_dist();
884
1126
  initializeTaskWorker2 = initializeTaskWorker;
885
1127
  }
886
1128
  });
@@ -1108,6 +1350,7 @@
1108
1350
  } catch {
1109
1351
  const moduleUrl2 = new URL(moduleLibraryUrl, globalThis.location.href).href;
1110
1352
  const library2 = await import(
1353
+ /* webpackIgnore: true */
1111
1354
  /* @vite-ignore */
1112
1355
  moduleUrl2
1113
1356
  );
@@ -4004,6 +4247,35 @@
4004
4247
  out[15] = 1;
4005
4248
  return out;
4006
4249
  }
4250
+ function affineComponents(matrix) {
4251
+ if (matrix.length !== 16 || Array.from(matrix).some((x) => !Number.isFinite(x)) || matrix[3] !== 0 || matrix[7] !== 0 || matrix[11] !== 0 || matrix[15] !== 1) {
4252
+ throw new RangeError("Expected a finite affine matrix");
4253
+ }
4254
+ const scale6 = [
4255
+ Math.hypot(matrix[0], matrix[1], matrix[2]),
4256
+ Math.hypot(matrix[4], matrix[5], matrix[6]),
4257
+ Math.hypot(matrix[8], matrix[9], matrix[10])
4258
+ ];
4259
+ if (scale6.some((x) => x === 0 || !Number.isFinite(x)))
4260
+ throw new RangeError("Singular transform");
4261
+ const rotation2 = Array.from({ length: 9 }, (_, i) => matrix[Math.floor(i / 3) * 4 + i % 3] / scale6[Math.floor(i / 3)]);
4262
+ for (const [a, b] of [
4263
+ [0, 3],
4264
+ [0, 6],
4265
+ [3, 6]
4266
+ ]) {
4267
+ if (Math.abs(rotation2[a] * rotation2[b] + rotation2[a + 1] * rotation2[b + 1] + rotation2[a + 2] * rotation2[b + 2]) > 1e-7) {
4268
+ throw new RangeError("Sheared transforms do not have a TRS decomposition");
4269
+ }
4270
+ }
4271
+ const determinant3 = rotation2[0] * (rotation2[4] * rotation2[8] - rotation2[5] * rotation2[7]) - rotation2[3] * (rotation2[1] * rotation2[8] - rotation2[2] * rotation2[7]) + rotation2[6] * (rotation2[1] * rotation2[5] - rotation2[2] * rotation2[4]);
4272
+ if (determinant3 < 0) {
4273
+ scale6[0] = -scale6[0];
4274
+ for (let i = 0; i < 3; i++)
4275
+ rotation2[i] = -rotation2[i];
4276
+ }
4277
+ return { rotation: rotation2, scale: scale6, translation: [matrix[12], matrix[13], matrix[14]] };
4278
+ }
4007
4279
  var perspective, ortho;
4008
4280
  var init_mat4 = __esm({
4009
4281
  "../../node_modules/@math.gl/core/dist/gl-matrix/mat4.js"() {
@@ -4137,6 +4409,7 @@
4137
4409
  var init_matrix4 = __esm({
4138
4410
  "../../node_modules/@math.gl/core/dist/classes/matrix4.js"() {
4139
4411
  init_matrix();
4412
+ init_mat4();
4140
4413
  init_validators();
4141
4414
  init_gl_matrix_extras();
4142
4415
  init_mat4();
@@ -4421,27 +4694,15 @@
4421
4694
  * @returns self
4422
4695
  */
4423
4696
  getRotation(result, scaleResult) {
4424
- result = result || [-0, -0, -0, -0, -0, -0, -0, -0, -0, -0, -0, -0, -0, -0, -0, -0];
4425
- scaleResult = scaleResult || [-0, -0, -0];
4426
- const scale6 = this.getScale(scaleResult);
4427
- const inverseScale0 = 1 / scale6[0];
4428
- const inverseScale1 = 1 / scale6[1];
4429
- const inverseScale2 = 1 / scale6[2];
4430
- result[0] = this[0] * inverseScale0;
4431
- result[1] = this[1] * inverseScale1;
4432
- result[2] = this[2] * inverseScale2;
4433
- result[3] = 0;
4434
- result[4] = this[4] * inverseScale0;
4435
- result[5] = this[5] * inverseScale1;
4436
- result[6] = this[6] * inverseScale2;
4437
- result[7] = 0;
4438
- result[8] = this[8] * inverseScale0;
4439
- result[9] = this[9] * inverseScale1;
4440
- result[10] = this[10] * inverseScale2;
4441
- result[11] = 0;
4442
- result[12] = 0;
4443
- result[13] = 0;
4444
- result[14] = 0;
4697
+ const { rotation: rotation2, scale: scale6 } = affineComponents(this);
4698
+ result = result || new Array(16);
4699
+ if (scaleResult)
4700
+ for (let i = 0; i < 3; i++)
4701
+ scaleResult[i] = scale6[i];
4702
+ for (let i = 0; i < 16; i++)
4703
+ result[i] = 0;
4704
+ for (let i = 0; i < 9; i++)
4705
+ result[Math.floor(i / 3) * 4 + i % 3] = rotation2[i];
4445
4706
  result[15] = 1;
4446
4707
  return result;
4447
4708
  }
@@ -4452,21 +4713,13 @@
4452
4713
  * @returns self
4453
4714
  */
4454
4715
  getRotationMatrix3(result, scaleResult) {
4455
- result = result || [-0, -0, -0, -0, -0, -0, -0, -0, -0];
4456
- scaleResult = scaleResult || [-0, -0, -0];
4457
- const scale6 = this.getScale(scaleResult);
4458
- const inverseScale0 = 1 / scale6[0];
4459
- const inverseScale1 = 1 / scale6[1];
4460
- const inverseScale2 = 1 / scale6[2];
4461
- result[0] = this[0] * inverseScale0;
4462
- result[1] = this[1] * inverseScale1;
4463
- result[2] = this[2] * inverseScale2;
4464
- result[3] = this[4] * inverseScale0;
4465
- result[4] = this[5] * inverseScale1;
4466
- result[5] = this[6] * inverseScale2;
4467
- result[6] = this[8] * inverseScale0;
4468
- result[7] = this[9] * inverseScale1;
4469
- result[8] = this[10] * inverseScale2;
4716
+ const { rotation: rotation2, scale: scale6 } = affineComponents(this);
4717
+ result = result || new Array(9);
4718
+ if (scaleResult)
4719
+ for (let i = 0; i < 3; i++)
4720
+ scaleResult[i] = scale6[i];
4721
+ for (let i = 0; i < 9; i++)
4722
+ result[i] = rotation2[i];
4470
4723
  return result;
4471
4724
  }
4472
4725
  // Modifiers
@@ -4779,6 +5032,28 @@
4779
5032
  }
4780
5033
  return out;
4781
5034
  }
5035
+ function rotateTowards(out, a, b, step) {
5036
+ if (a.length !== 4 || b.length !== 4 || [...Array.from(a), ...Array.from(b), step].some((x) => !Number.isFinite(x))) {
5037
+ throw new RangeError("Expected finite quaternions and step");
5038
+ }
5039
+ if (a.length !== 4 || step < 0)
5040
+ throw new RangeError("Expected quaternions and a nonnegative step");
5041
+ const aScale = Math.max(...Array.from(a, Math.abs)), bScale = Math.max(...Array.from(b, Math.abs));
5042
+ if (!aScale || !bScale)
5043
+ throw new RangeError("Zero quaternion");
5044
+ const an = Array.from(a, (x) => x / aScale), bn = Array.from(b, (x) => x / bScale);
5045
+ const al = Math.hypot(...an), bl = Math.hypot(...bn);
5046
+ for (let i = 0; i < 4; i++) {
5047
+ an[i] /= al;
5048
+ bn[i] /= bl;
5049
+ }
5050
+ const dot5 = an.reduce((sum, x, i) => sum + x * bn[i], 0);
5051
+ const angle2 = 2 * Math.acos(Math.min(1, Math.abs(dot5)));
5052
+ if (out.length < 4)
5053
+ throw new RangeError("Result buffer is too short");
5054
+ slerp(out, an, bn, angle2 === 0 ? 0 : Math.min(1, step / angle2));
5055
+ return out;
5056
+ }
4782
5057
  var add2, scale4, dot3, lerp2, length3, squaredLength2, normalize3, rotationTo;
4783
5058
  var init_quat = __esm({
4784
5059
  "../../node_modules/@math.gl/core/dist/gl-matrix/quat.js"() {
@@ -4827,6 +5102,7 @@
4827
5102
  var Quaternion;
4828
5103
  var init_quaternion = __esm({
4829
5104
  "../../node_modules/@math.gl/core/dist/classes/quaternion.js"() {
5105
+ init_quat();
4830
5106
  init_math_array();
4831
5107
  init_validators();
4832
5108
  init_quat();
@@ -4900,6 +5176,9 @@
4900
5176
  return this.check();
4901
5177
  }
4902
5178
  /** Set a quat to the identity quaternion */
5179
+ rotateTowards(target, step) {
5180
+ return rotateTowards(this, this, target, step);
5181
+ }
4903
5182
  identity() {
4904
5183
  identity2(this);
4905
5184
  return this.check();
@@ -5376,7 +5655,7 @@
5376
5655
  });
5377
5656
 
5378
5657
  // ../../node_modules/@math.gl/core/dist/index.js
5379
- var init_dist = __esm({
5658
+ var init_dist2 = __esm({
5380
5659
  "../../node_modules/@math.gl/core/dist/index.js"() {
5381
5660
  init_vector3();
5382
5661
  init_matrix3();
@@ -5468,7 +5747,7 @@
5468
5747
  var scratchVector;
5469
5748
  var init_type_utils = __esm({
5470
5749
  "../../node_modules/@math.gl/geospatial/dist/type-utils.js"() {
5471
- init_dist();
5750
+ init_dist2();
5472
5751
  scratchVector = new Vector3();
5473
5752
  }
5474
5753
  });
@@ -5706,7 +5985,7 @@
5706
5985
  var surface;
5707
5986
  var init_scale_to_geodetic_surface = __esm({
5708
5987
  "../../node_modules/@math.gl/geospatial/dist/ellipsoid-helpers/scale-to-geodetic-surface.js"() {
5709
- init_dist();
5988
+ init_dist2();
5710
5989
  init_nearest_surface();
5711
5990
  surface = { x: 0, y: 0, z: 0 };
5712
5991
  }
@@ -5728,8 +6007,8 @@
5728
6007
  var spheroidScratch, scratchVector2, scratchNormal, scratchPosition, scratchCartesian, Ellipsoid;
5729
6008
  var init_ellipsoid = __esm({
5730
6009
  "../../node_modules/@math.gl/geospatial/dist/ellipsoid.js"() {
5731
- init_dist();
5732
- init_dist();
6010
+ init_dist2();
6011
+ init_dist2();
5733
6012
  init_constants();
5734
6013
  init_type_utils();
5735
6014
  init_scale_to_geodetic_surface();
@@ -7433,8 +7712,8 @@
7433
7712
  var EPSILON142, scratchOrigin, scratchBasis, VECTOR_PRODUCT_LOCAL_FRAME, degeneratePositionLocalFrame, scratchAxisVectors, scratchVector1, scratchVector22, scratchVector3;
7434
7713
  var init_ellipsoid_transform = __esm({
7435
7714
  "../../node_modules/@math.gl/geospatial/dist/ellipsoid-helpers/ellipsoid-transform.js"() {
7436
- init_dist();
7437
- init_dist();
7715
+ init_dist2();
7716
+ init_dist2();
7438
7717
  EPSILON142 = 1e-14;
7439
7718
  scratchOrigin = new Vector3();
7440
7719
  scratchBasis = createLocalFrameBasis();
@@ -7504,7 +7783,7 @@
7504
7783
  }
7505
7784
  var init_ellipsoid_transforms = __esm({
7506
7785
  "../../node_modules/@math.gl/geospatial/dist/ellipsoid-transforms.js"() {
7507
- init_dist();
7786
+ init_dist2();
7508
7787
  init_ellipsoid_transform();
7509
7788
  }
7510
7789
  });
@@ -7558,7 +7837,7 @@
7558
7837
  });
7559
7838
 
7560
7839
  // ../../node_modules/@math.gl/geometry/dist/index.js
7561
- var init_dist2 = __esm({
7840
+ var init_dist3 = __esm({
7562
7841
  "../../node_modules/@math.gl/geometry/dist/index.js"() {
7563
7842
  init_utils();
7564
7843
  }
@@ -9267,7 +9546,7 @@
9267
9546
  });
9268
9547
 
9269
9548
  // ../../node_modules/@math.gl/geospatial/dist/index.js
9270
- var init_dist3 = __esm({
9549
+ var init_dist4 = __esm({
9271
9550
  "../../node_modules/@math.gl/geospatial/dist/index.js"() {
9272
9551
  init_ellipsoid2();
9273
9552
  init_globe();
@@ -9497,7 +9776,7 @@
9497
9776
  var init_version2 = __esm({
9498
9777
  "../images/src/lib/utils/version.ts"() {
9499
9778
  "use strict";
9500
- VERSION2 = true ? "5.0.0-beta.4" : "latest";
9779
+ VERSION2 = true ? "5.0.0-beta.6" : "latest";
9501
9780
  }
9502
9781
  });
9503
9782
 
@@ -26423,6 +26702,305 @@ return true;`);
26423
26702
  }
26424
26703
  });
26425
26704
 
26705
+ // ../../node_modules/@math.gl/arrow/dist/arrow/arrow-data.js
26706
+ function getArrowVariadicBuffers(data) {
26707
+ return data.variadicBuffers ?? [];
26708
+ }
26709
+ function createArrowData(type, offset2, length4, nullCount, buffers, children2, dictionary, variadicBuffers) {
26710
+ return Reflect.construct(Data, [
26711
+ type,
26712
+ offset2,
26713
+ length4,
26714
+ nullCount,
26715
+ buffers,
26716
+ children2,
26717
+ dictionary,
26718
+ variadicBuffers
26719
+ ]);
26720
+ }
26721
+ var init_arrow_data = __esm({
26722
+ "../../node_modules/@math.gl/arrow/dist/arrow/arrow-data.js"() {
26723
+ init_Arrow_dom();
26724
+ }
26725
+ });
26726
+
26727
+ // ../../node_modules/@math.gl/arrow/dist/arrow/split-arrow-buffers.js
26728
+ function splitArrowBuffers(input, options = {}) {
26729
+ const context = { ...options, copies: /* @__PURE__ */ new WeakMap() };
26730
+ if (isArrowTable2(input)) {
26731
+ return splitArrowTableBuffersInternal(input, context);
26732
+ }
26733
+ if (isArrowRecordBatch2(input)) {
26734
+ return splitArrowRecordBatchBuffers(input, context);
26735
+ }
26736
+ if (isArrowVector2(input)) {
26737
+ return splitArrowVectorBuffers(input, context);
26738
+ }
26739
+ return splitArrowDataBuffers(input, context);
26740
+ }
26741
+ function isArrowTable2(input) {
26742
+ return "batches" in input;
26743
+ }
26744
+ function isArrowRecordBatch2(input) {
26745
+ return "schema" in input && "data" in input && !Array.isArray(input.data);
26746
+ }
26747
+ function isArrowVector2(input) {
26748
+ return "data" in input && Array.isArray(input.data);
26749
+ }
26750
+ function splitArrowTableBuffersInternal(arrowTable, options) {
26751
+ const recordBatches = arrowTable.batches.map((recordBatch) => splitArrowRecordBatchBuffers(recordBatch, options));
26752
+ return new Table(arrowTable.schema, recordBatches);
26753
+ }
26754
+ function splitArrowRecordBatchBuffers(recordBatch, options) {
26755
+ return new RecordBatch3(recordBatch.schema, splitArrowDataBuffers(recordBatch.data, options));
26756
+ }
26757
+ function splitArrowDataBuffers(data, options) {
26758
+ const children2 = data.children.map((childData) => splitArrowDataBuffers(childData, options));
26759
+ const dictionary = data.dictionary ? splitArrowVectorBuffers(data.dictionary, options) : void 0;
26760
+ const buffers = {
26761
+ [BufferType.OFFSET]: splitArrowBuffer(data.buffers[BufferType.OFFSET], options),
26762
+ [BufferType.DATA]: splitArrowBuffer(data.buffers[BufferType.DATA], options),
26763
+ [BufferType.VALIDITY]: splitArrowBuffer(data.buffers[BufferType.VALIDITY], options),
26764
+ [BufferType.TYPE]: splitArrowBuffer(data.buffers[BufferType.TYPE], options)
26765
+ };
26766
+ return createArrowData(
26767
+ data.type,
26768
+ data.offset,
26769
+ data.length,
26770
+ // @ts-expect-error _nullCount is protected. Reuse it to preserve lazy null-count state.
26771
+ data._nullCount,
26772
+ buffers,
26773
+ children2,
26774
+ dictionary,
26775
+ getArrowVariadicBuffers(data).map((buffer) => splitArrowBuffer(buffer, options))
26776
+ );
26777
+ }
26778
+ function splitArrowVectorBuffers(vector, options) {
26779
+ return new Vector2(vector.data.map((data) => splitArrowDataBuffers(data, options)));
26780
+ }
26781
+ function splitArrowBuffer(array2, options) {
26782
+ if (!isArrowTypedArray(array2)) {
26783
+ return array2;
26784
+ }
26785
+ if (options.copy === "none") {
26786
+ return array2;
26787
+ }
26788
+ if (options.copy !== "all" && array2.byteOffset === 0 && array2.byteLength === array2.buffer.byteLength) {
26789
+ return array2;
26790
+ }
26791
+ let copy2 = options.copies.get(array2);
26792
+ if (!copy2) {
26793
+ copy2 = array2 instanceof Uint8Array ? new Uint8Array(array2) : array2.slice();
26794
+ options.copies.set(array2, copy2);
26795
+ }
26796
+ return copy2;
26797
+ }
26798
+ function isArrowTypedArray(value2) {
26799
+ return ArrayBuffer.isView(value2) && !(value2 instanceof DataView);
26800
+ }
26801
+ var init_split_arrow_buffers = __esm({
26802
+ "../../node_modules/@math.gl/arrow/dist/arrow/split-arrow-buffers.js"() {
26803
+ init_Arrow_dom();
26804
+ init_arrow_data();
26805
+ }
26806
+ });
26807
+
26808
+ // ../../node_modules/@math.gl/arrow/dist/arrow/indexed-arrow-vector.js
26809
+ var init_indexed_arrow_vector = __esm({
26810
+ "../../node_modules/@math.gl/arrow/dist/arrow/indexed-arrow-vector.js"() {
26811
+ }
26812
+ });
26813
+
26814
+ // ../../node_modules/@math.gl/arrow/dist/arrow/indexed-arrow-table.js
26815
+ var init_indexed_arrow_table = __esm({
26816
+ "../../node_modules/@math.gl/arrow/dist/arrow/indexed-arrow-table.js"() {
26817
+ }
26818
+ });
26819
+
26820
+ // ../../node_modules/@math.gl/arrow/dist/arrow/mapped-arrow-table.js
26821
+ var init_mapped_arrow_table = __esm({
26822
+ "../../node_modules/@math.gl/arrow/dist/arrow/mapped-arrow-table.js"() {
26823
+ }
26824
+ });
26825
+
26826
+ // ../../node_modules/@math.gl/arrow/dist/arrow/rename-arrow-columns.js
26827
+ var init_rename_arrow_columns = __esm({
26828
+ "../../node_modules/@math.gl/arrow/dist/arrow/rename-arrow-columns.js"() {
26829
+ }
26830
+ });
26831
+
26832
+ // ../../node_modules/@math.gl/arrow/dist/arrow/arrow-table-transport.js
26833
+ function dehydrateArrowTable(arrowTable, options) {
26834
+ const splitTable = splitArrowBuffers(arrowTable, options);
26835
+ return {
26836
+ transport: "arrow-js",
26837
+ version: 1,
26838
+ schema: tableToIPC(new Table(splitTable.schema, [])),
26839
+ metadataVersion: splitTable.schema.metadataVersion,
26840
+ batches: splitTable.batches.map((batch) => dehydrateArrowData(batch.data))
26841
+ };
26842
+ }
26843
+ function hydrateArrowTable(table) {
26844
+ if (table.transport !== "arrow-js" || table.version !== 1) {
26845
+ throw new Error("Unsupported Arrow column-buffer transport protocol.");
26846
+ }
26847
+ const decodedSchema = tableFromIPC(table.schema).schema;
26848
+ const schema = new Schema2(decodedSchema.fields, decodedSchema.metadata, decodedSchema.dictionaries, table.metadataVersion);
26849
+ const type = new Struct(schema.fields);
26850
+ const batches = table.batches.map((data) => new RecordBatch3(schema, hydrateArrowData(data, type)));
26851
+ return new Table(schema, batches);
26852
+ }
26853
+ function dehydrateArrowData(data) {
26854
+ return {
26855
+ offset: data.offset,
26856
+ length: data.length,
26857
+ nullCount: data.nullCount,
26858
+ buffers: {
26859
+ [BufferType.OFFSET]: data.buffers[BufferType.OFFSET],
26860
+ [BufferType.DATA]: data.buffers[BufferType.DATA],
26861
+ [BufferType.VALIDITY]: data.buffers[BufferType.VALIDITY],
26862
+ [BufferType.TYPE]: data.buffers[BufferType.TYPE]
26863
+ },
26864
+ children: data.children.map((child2) => dehydrateArrowData(child2)),
26865
+ variadicBuffers: getArrowVariadicBuffers(data),
26866
+ dictionary: data.dictionary?.data.map((chunk) => dehydrateArrowData(chunk))
26867
+ };
26868
+ }
26869
+ function hydrateArrowData(data, type) {
26870
+ const children2 = data.children.map((child2, index) => hydrateArrowData(child2, type.children[index].type));
26871
+ const dictionary = data.dictionary && DataType.isDictionary(type) ? new Vector2(data.dictionary.map((chunk) => hydrateArrowData(chunk, type.dictionary))) : void 0;
26872
+ return createArrowData(type, data.offset, data.length, data.nullCount, data.buffers, children2, dictionary, data.variadicBuffers);
26873
+ }
26874
+ var init_arrow_table_transport = __esm({
26875
+ "../../node_modules/@math.gl/arrow/dist/arrow/arrow-table-transport.js"() {
26876
+ init_Arrow_dom();
26877
+ init_arrow_data();
26878
+ init_split_arrow_buffers();
26879
+ }
26880
+ });
26881
+
26882
+ // ../../node_modules/@math.gl/arrow/dist/arrow/index.js
26883
+ var init_arrow = __esm({
26884
+ "../../node_modules/@math.gl/arrow/dist/arrow/index.js"() {
26885
+ init_indexed_arrow_table();
26886
+ init_indexed_arrow_vector();
26887
+ init_mapped_arrow_table();
26888
+ init_rename_arrow_columns();
26889
+ init_split_arrow_buffers();
26890
+ init_arrow_table_transport();
26891
+ }
26892
+ });
26893
+
26894
+ // ../../node_modules/@math.gl/arrow/dist/index.js
26895
+ var init_dist5 = __esm({
26896
+ "../../node_modules/@math.gl/arrow/dist/index.js"() {
26897
+ init_arrow();
26898
+ }
26899
+ });
26900
+
26901
+ // ../core/src/arrow-worker-transport.ts
26902
+ function serializeArrowWorkerResult(result, options) {
26903
+ if (!isArrowTableWrapper(result)) {
26904
+ return result;
26905
+ }
26906
+ const workerOptions = options;
26907
+ const bufferCopyMode = workerOptions?.core?.workerTransferBufferCopy ?? workerOptions?.workerTransferBufferCopy;
26908
+ return {
26909
+ ...result,
26910
+ data: dehydrateArrowTable(result.data, bufferCopyMode ? { copy: bufferCopyMode } : void 0)
26911
+ };
26912
+ }
26913
+ function deserializeArrowWorkerResult(result) {
26914
+ if (!isDehydratedArrowTableWrapper(result)) {
26915
+ return result;
26916
+ }
26917
+ return { ...result, data: hydrateArrowTable(result.data) };
26918
+ }
26919
+ function isArrowTableWrapper(value2) {
26920
+ const table = value2;
26921
+ return Boolean(
26922
+ table && table.shape === "arrow-table" && table.data && typeof table.data === "object" && "batches" in table.data
26923
+ );
26924
+ }
26925
+ function isDehydratedArrowTableWrapper(value2) {
26926
+ const table = value2;
26927
+ return Boolean(
26928
+ table && table.shape === "arrow-table" && table.data && table.data.transport === "arrow-js" && Array.isArray(table.data.batches)
26929
+ );
26930
+ }
26931
+ var init_arrow_worker_transport = __esm({
26932
+ "../core/src/arrow-worker-transport.ts"() {
26933
+ "use strict";
26934
+ init_dist5();
26935
+ }
26936
+ });
26937
+
26938
+ // ../core/src/schema-utils/lib/schema/data-type.ts
26939
+ function getDataTypeFromValue(value2, defaultNumberType = "float32") {
26940
+ if (value2 instanceof Date) {
26941
+ return "date-millisecond";
26942
+ }
26943
+ if (typeof value2 === "number") {
26944
+ return defaultNumberType;
26945
+ }
26946
+ if (typeof value2 === "boolean") {
26947
+ return "bool";
26948
+ }
26949
+ if (typeof value2 === "string") {
26950
+ return "utf8";
26951
+ }
26952
+ if (value2 === null || value2 === "undefined") {
26953
+ return "null";
26954
+ }
26955
+ return "null";
26956
+ }
26957
+ function getDataTypeFromArray(array2) {
26958
+ let type = getDataTypeFromTypedArray(array2);
26959
+ if (type !== "null") {
26960
+ return { type, nullable: false };
26961
+ }
26962
+ if (array2.length > 0) {
26963
+ type = getDataTypeFromValue(array2[0]);
26964
+ return { type, nullable: true };
26965
+ }
26966
+ return { type: "null", nullable: true };
26967
+ }
26968
+ function getDataTypeFromTypedArray(array2) {
26969
+ if (typeof Float16Array !== "undefined" && array2 instanceof Float16Array) {
26970
+ return "float16";
26971
+ }
26972
+ switch (array2.constructor) {
26973
+ case Int8Array:
26974
+ return "int8";
26975
+ case Uint8Array:
26976
+ case Uint8ClampedArray:
26977
+ return "uint8";
26978
+ case Int16Array:
26979
+ return "int16";
26980
+ case Uint16Array:
26981
+ return "uint16";
26982
+ case Int32Array:
26983
+ return "int32";
26984
+ case Uint32Array:
26985
+ return "uint32";
26986
+ case BigInt64Array:
26987
+ return "int64";
26988
+ case BigUint64Array:
26989
+ return "uint64";
26990
+ case Float32Array:
26991
+ return "float32";
26992
+ case Float64Array:
26993
+ return "float64";
26994
+ default:
26995
+ return "null";
26996
+ }
26997
+ }
26998
+ var init_data_type = __esm({
26999
+ "../core/src/schema-utils/lib/schema/data-type.ts"() {
27000
+ "use strict";
27001
+ }
27002
+ });
27003
+
26426
27004
  // ../core/src/schema-utils/lib/schema/convert-arrow-schema.ts
26427
27005
  function serializeArrowSchema(arrowSchema) {
26428
27006
  return {
@@ -26430,12 +27008,6 @@ return true;`);
26430
27008
  metadata: serializeArrowMetadata(arrowSchema.metadata)
26431
27009
  };
26432
27010
  }
26433
- function deserializeArrowSchema(schema, options) {
26434
- return new Schema2(
26435
- schema.fields.map((field) => deserializeArrowField(field, options)),
26436
- deserializeArrowMetadata(schema.metadata)
26437
- );
26438
- }
26439
27011
  function serializeArrowMetadata(arrowMetadata) {
26440
27012
  return Object.fromEntries(arrowMetadata);
26441
27013
  }
@@ -26858,260 +27430,6 @@ return true;`);
26858
27430
  }
26859
27431
  });
26860
27432
 
26861
- // ../core/src/schema-utils/lib/arrow/split-arrow-buffers.ts
26862
- function splitArrowBuffers(input, options = {}) {
26863
- const context = { ...options, copies: /* @__PURE__ */ new WeakMap() };
26864
- if (isArrowTable2(input)) {
26865
- return splitArrowTableBuffersInternal(input, context);
26866
- }
26867
- if (isArrowRecordBatch2(input)) {
26868
- return splitArrowRecordBatchBuffers(input, context);
26869
- }
26870
- if (isArrowVector2(input)) {
26871
- return splitArrowVectorBuffers(input, context);
26872
- }
26873
- return splitArrowDataBuffers(input, context);
26874
- }
26875
- function isArrowTable2(input) {
26876
- return "batches" in input;
26877
- }
26878
- function isArrowRecordBatch2(input) {
26879
- return "schema" in input && "data" in input && !Array.isArray(input.data);
26880
- }
26881
- function isArrowVector2(input) {
26882
- return "data" in input && Array.isArray(input.data);
26883
- }
26884
- function splitArrowTableBuffersInternal(table, options) {
26885
- const recordBatches = table.batches.map(
26886
- (recordBatch) => splitArrowRecordBatchBuffers(recordBatch, options)
26887
- );
26888
- return new Table(table.schema, recordBatches);
26889
- }
26890
- function splitArrowRecordBatchBuffers(recordBatch, options) {
26891
- return new RecordBatch3(
26892
- recordBatch.schema,
26893
- splitArrowDataBuffers(recordBatch.data, options)
26894
- );
26895
- }
26896
- function splitArrowDataBuffers(data, options) {
26897
- const children2 = data.children.map((childData) => splitArrowDataBuffers(childData, options));
26898
- const dictionary = data.dictionary ? splitArrowVectorBuffers(data.dictionary, options) : void 0;
26899
- const buffers = {
26900
- [BufferType.OFFSET]: splitArrowBuffer(data.buffers[BufferType.OFFSET], options),
26901
- [BufferType.DATA]: splitArrowBuffer(data.buffers[BufferType.DATA], options),
26902
- [BufferType.VALIDITY]: splitArrowBuffer(data.buffers[BufferType.VALIDITY], options),
26903
- [BufferType.TYPE]: splitArrowBuffer(data.buffers[BufferType.TYPE], options)
26904
- };
26905
- return new Data(
26906
- data.type,
26907
- data.offset,
26908
- data.length,
26909
- // @ts-expect-error _nullCount is protected. Reuse it to preserve lazy null-count state.
26910
- data._nullCount,
26911
- buffers,
26912
- children2,
26913
- dictionary
26914
- );
26915
- }
26916
- function splitArrowVectorBuffers(vector, options) {
26917
- return new Vector2(vector.data.map((data) => splitArrowDataBuffers(data, options)));
26918
- }
26919
- function splitArrowBuffer(array2, options) {
26920
- if (!isArrowTypedArray(array2)) {
26921
- return array2;
26922
- }
26923
- if (options.copy === "none") {
26924
- return array2;
26925
- }
26926
- if (options.copy !== "all" && array2.byteOffset === 0 && array2.byteLength === array2.buffer.byteLength) {
26927
- return array2;
26928
- }
26929
- let copy2 = options.copies.get(array2);
26930
- if (!copy2) {
26931
- copy2 = array2.slice();
26932
- options.copies.set(array2, copy2);
26933
- }
26934
- return copy2;
26935
- }
26936
- function isArrowTypedArray(value2) {
26937
- return ArrayBuffer.isView(value2) && !(value2 instanceof DataView);
26938
- }
26939
- var init_split_arrow_buffers = __esm({
26940
- "../core/src/schema-utils/lib/arrow/split-arrow-buffers.ts"() {
26941
- "use strict";
26942
- init_Arrow_dom();
26943
- }
26944
- });
26945
-
26946
- // ../core/src/schema-utils/lib/arrow/arrow-table-transport.ts
26947
- function dehydrateArrowTable(table, options) {
26948
- const splitTable = splitArrowBuffers(table, options);
26949
- return {
26950
- shape: "arrow-table",
26951
- transport: "arrow-js",
26952
- schema: serializeArrowSchema(splitTable.schema),
26953
- batches: splitTable.batches.map((recordBatch) => dehydrateArrowRecordBatch(recordBatch))
26954
- };
26955
- }
26956
- function hydrateArrowTable(table) {
26957
- const schema = deserializeArrowSchema(table.schema);
26958
- const recordBatches = table.batches.map(
26959
- (recordBatch) => new RecordBatch3(schema, hydrateArrowData(recordBatch.data))
26960
- );
26961
- return new Table(schema, recordBatches);
26962
- }
26963
- function serializeArrowWorkerResult(result, options) {
26964
- if (!isArrowTableWrapper(result)) {
26965
- return result;
26966
- }
26967
- const workerOptions = options;
26968
- const bufferCopyMode = workerOptions?.core?.workerTransferBufferCopy ?? workerOptions?.workerTransferBufferCopy;
26969
- return {
26970
- ...result,
26971
- data: dehydrateArrowTable(result.data, bufferCopyMode ? { copy: bufferCopyMode } : void 0)
26972
- };
26973
- }
26974
- function deserializeArrowWorkerResult(result) {
26975
- if (!isDehydratedArrowTableWrapper(result)) {
26976
- return result;
26977
- }
26978
- return { ...result, data: hydrateArrowTable(result.data) };
26979
- }
26980
- function isArrowTableWrapper(value2) {
26981
- const table = value2;
26982
- return Boolean(
26983
- table && table.shape === "arrow-table" && table.data && typeof table.data === "object" && "batches" in table.data
26984
- );
26985
- }
26986
- function isDehydratedArrowTableWrapper(value2) {
26987
- const table = value2;
26988
- return Boolean(
26989
- table && table.shape === "arrow-table" && table.data && table.data.transport === "arrow-js" && Array.isArray(table.data.batches)
26990
- );
26991
- }
26992
- function dehydrateArrowRecordBatch(recordBatch) {
26993
- return { data: dehydrateArrowData(recordBatch.data) };
26994
- }
26995
- function dehydrateArrowData(data) {
26996
- return {
26997
- type: serializeArrowType(data.type),
26998
- offset: data.offset,
26999
- length: data.length,
27000
- // @ts-expect-error _nullCount is protected. Preserve the Arrow lazy null-count state.
27001
- nullCount: data._nullCount,
27002
- buffers: {
27003
- [BufferType.OFFSET]: data.buffers[BufferType.OFFSET],
27004
- [BufferType.DATA]: data.buffers[BufferType.DATA],
27005
- [BufferType.VALIDITY]: data.buffers[BufferType.VALIDITY],
27006
- [BufferType.TYPE]: data.buffers[BufferType.TYPE]
27007
- },
27008
- children: data.children.map((childData) => dehydrateArrowData(childData)),
27009
- dictionary: data.dictionary ? dehydrateArrowVector(data.dictionary) : void 0
27010
- };
27011
- }
27012
- function dehydrateArrowVector(vector) {
27013
- return { data: vector.data.map((data) => dehydrateArrowData(data)) };
27014
- }
27015
- function hydrateArrowData(data) {
27016
- const children2 = data.children.map((childData) => hydrateArrowData(childData));
27017
- const dictionary = data.dictionary ? hydrateArrowVector(data.dictionary) : void 0;
27018
- return new Data(
27019
- deserializeArrowType(data.type),
27020
- data.offset,
27021
- data.length,
27022
- data.nullCount,
27023
- data.buffers,
27024
- children2,
27025
- dictionary
27026
- );
27027
- }
27028
- function hydrateArrowVector(vector) {
27029
- return new Vector2(vector.data.map((data) => hydrateArrowData(data)));
27030
- }
27031
- var init_arrow_table_transport = __esm({
27032
- "../core/src/schema-utils/lib/arrow/arrow-table-transport.ts"() {
27033
- "use strict";
27034
- init_Arrow_dom();
27035
- init_convert_arrow_schema();
27036
- init_split_arrow_buffers();
27037
- }
27038
- });
27039
-
27040
- // ../core/src/schema-utils/arrow-transport.ts
27041
- var init_arrow_transport = __esm({
27042
- "../core/src/schema-utils/arrow-transport.ts"() {
27043
- "use strict";
27044
- init_arrow_table_transport();
27045
- init_split_arrow_buffers();
27046
- }
27047
- });
27048
-
27049
- // ../core/src/schema-utils/lib/schema/data-type.ts
27050
- function getDataTypeFromValue(value2, defaultNumberType = "float32") {
27051
- if (value2 instanceof Date) {
27052
- return "date-millisecond";
27053
- }
27054
- if (typeof value2 === "number") {
27055
- return defaultNumberType;
27056
- }
27057
- if (typeof value2 === "boolean") {
27058
- return "bool";
27059
- }
27060
- if (typeof value2 === "string") {
27061
- return "utf8";
27062
- }
27063
- if (value2 === null || value2 === "undefined") {
27064
- return "null";
27065
- }
27066
- return "null";
27067
- }
27068
- function getDataTypeFromArray(array2) {
27069
- let type = getDataTypeFromTypedArray(array2);
27070
- if (type !== "null") {
27071
- return { type, nullable: false };
27072
- }
27073
- if (array2.length > 0) {
27074
- type = getDataTypeFromValue(array2[0]);
27075
- return { type, nullable: true };
27076
- }
27077
- return { type: "null", nullable: true };
27078
- }
27079
- function getDataTypeFromTypedArray(array2) {
27080
- if (typeof Float16Array !== "undefined" && array2 instanceof Float16Array) {
27081
- return "float16";
27082
- }
27083
- switch (array2.constructor) {
27084
- case Int8Array:
27085
- return "int8";
27086
- case Uint8Array:
27087
- case Uint8ClampedArray:
27088
- return "uint8";
27089
- case Int16Array:
27090
- return "int16";
27091
- case Uint16Array:
27092
- return "uint16";
27093
- case Int32Array:
27094
- return "int32";
27095
- case Uint32Array:
27096
- return "uint32";
27097
- case BigInt64Array:
27098
- return "int64";
27099
- case BigUint64Array:
27100
- return "uint64";
27101
- case Float32Array:
27102
- return "float32";
27103
- case Float64Array:
27104
- return "float64";
27105
- default:
27106
- return "null";
27107
- }
27108
- }
27109
- var init_data_type = __esm({
27110
- "../core/src/schema-utils/lib/schema/data-type.ts"() {
27111
- "use strict";
27112
- }
27113
- });
27114
-
27115
27433
  // ../core/src/schema-utils/lib/mesh/mesh-utils.ts
27116
27434
  function getMeshBoundingBox(attributes) {
27117
27435
  const positionAttribute = attributes?.POSITION;
@@ -27202,7 +27520,7 @@ return true;`);
27202
27520
  var init_float162 = __esm({
27203
27521
  "../core/src/schema/float16.ts"() {
27204
27522
  "use strict";
27205
- init_dist();
27523
+ init_dist2();
27206
27524
  }
27207
27525
  });
27208
27526
 
@@ -27519,7 +27837,7 @@ return true;`);
27519
27837
  var init_version3 = __esm({
27520
27838
  "../scene/src/draco/lib/utils/version.ts"() {
27521
27839
  "use strict";
27522
- VERSION3 = true ? "5.0.0-beta.4" : "latest";
27840
+ VERSION3 = true ? "5.0.0-beta.6" : "latest";
27523
27841
  }
27524
27842
  });
27525
27843
 
@@ -28598,7 +28916,7 @@ return true;`);
28598
28916
  var init_draco_loader_types = __esm({
28599
28917
  "../scene/src/draco/draco-loader-types.ts"() {
28600
28918
  "use strict";
28601
- init_arrow_transport();
28919
+ init_arrow_worker_transport();
28602
28920
  init_version3();
28603
28921
  init_draco_format();
28604
28922
  init_draco_loader_options();
@@ -30005,7 +30323,7 @@ return true;`);
30005
30323
  var ARC_SECOND, WGS84;
30006
30324
  var init_datum = __esm({
30007
30325
  "../../node_modules/@math.gl/geospatial/dist/projection/experimental/datum.js"() {
30008
- init_dist();
30326
+ init_dist2();
30009
30327
  ARC_SECOND = Math.PI / (180 * 3600);
30010
30328
  WGS84 = {
30011
30329
  ellipsoid: {
@@ -30079,6 +30397,59 @@ return true;`);
30079
30397
  }
30080
30398
  });
30081
30399
 
30400
+ // ../../node_modules/@math.gl/geospatial/dist/projection/experimental/transform-description.js
30401
+ function describeCRS(crs) {
30402
+ const ellipsoid = Object.freeze({ ...crs.ellipsoid });
30403
+ return Object.freeze({
30404
+ kind: crs.kind,
30405
+ projection: crs.projection,
30406
+ parameters: Object.freeze(Object.fromEntries(Object.entries(crs.parameters).map(([name, value2]) => [name, value2 ?? null]))),
30407
+ ellipsoid,
30408
+ datum: Object.freeze({
30409
+ ellipsoid: Object.freeze({ ...crs.datum.ellipsoid }),
30410
+ towgs84: crs.datum.towgs84 && Object.freeze([...crs.datum.towgs84]),
30411
+ grids: crs.datum.grids && Object.freeze(crs.datum.grids.map((reference) => Object.freeze({
30412
+ name: reference.name,
30413
+ optional: reference.optional,
30414
+ loaded: Boolean(reference.grid)
30415
+ })))
30416
+ }),
30417
+ angularUnit: crs.angularUnit,
30418
+ toMeter: crs.toMeter,
30419
+ verticalUnit: crs.verticalUnit,
30420
+ primeMeridian: crs.primeMeridian,
30421
+ axis: crs.axis,
30422
+ storedAxis: crs.storedAxis,
30423
+ longitudeWrap: crs.longitudeWrap,
30424
+ areaOfUse: crs.areaOfUse && Object.freeze([...crs.areaOfUse]),
30425
+ lossy: crs.lossy,
30426
+ algorithm: crs.algorithm && Object.freeze({ ...crs.algorithm })
30427
+ });
30428
+ }
30429
+ function describeTransform(source, target, forward33, inverse33) {
30430
+ const opaqueReasons = [];
30431
+ if (!source.algorithm)
30432
+ opaqueReasons.push("source-algorithm");
30433
+ if (!target.algorithm)
30434
+ opaqueReasons.push("target-algorithm");
30435
+ if (source.datum.grids || target.datum.grids || source.parameters["geoidgrids"] || target.parameters["geoidgrids"])
30436
+ opaqueReasons.push("grid-resource");
30437
+ return Object.freeze({
30438
+ version: 1,
30439
+ source,
30440
+ target,
30441
+ forward: forward33,
30442
+ inverse: inverse33,
30443
+ lossy: source.lossy || target.lossy,
30444
+ complete: opaqueReasons.length === 0,
30445
+ opaqueReasons: Object.freeze(opaqueReasons)
30446
+ });
30447
+ }
30448
+ var init_transform_description = __esm({
30449
+ "../../node_modules/@math.gl/geospatial/dist/projection/experimental/transform-description.js"() {
30450
+ }
30451
+ });
30452
+
30082
30453
  // ../../node_modules/@math.gl/geospatial/dist/projection/experimental/typescript-projection.js
30083
30454
  function requiredProjections(options) {
30084
30455
  const available = registry(options.projections || []);
@@ -30148,7 +30519,8 @@ return true;`);
30148
30519
  const verticalGrid = compileVerticalGrid(crs.parameters["geoidgrids"], options.verticalGrids);
30149
30520
  if (verticalGrid && (crs.kind === "geocentric" || crs.kind === "identity" || crs.lossy))
30150
30521
  unsupportedStage("Vertical grids require a non-lossy geographic or projected CRS");
30151
- return { ...crs, datum, implementation, verticalGrid };
30522
+ const algorithm = plugin ? plugin.semantics : { id: "@math.gl/geospatial/" + crs.kind, version: 1 };
30523
+ return { ...crs, datum, implementation, verticalGrid, algorithm };
30152
30524
  }
30153
30525
  function finite(point) {
30154
30526
  return Number.isFinite(point.x) && Number.isFinite(point.y) && Number.isFinite(point.z);
@@ -30191,9 +30563,51 @@ return true;`);
30191
30563
  if (from.kind === "projected" && to.kind === "geographic")
30192
30564
  flat = from.implementation?.createInverseFlat?.(context);
30193
30565
  }
30566
+ const requiresInputZ = Boolean(from.verticalGrid || to.verticalGrid) || from.kind === "geocentric" || /[ud]/.test(fromAxis.slice(0, 2)) || /[ud]/.test(toAxis.slice(0, 2));
30567
+ const stages = [];
30568
+ if (inputAxis)
30569
+ stages.push("input-axis");
30570
+ if (horizontalOnly)
30571
+ stages.push("discard-height");
30572
+ if (inputScale !== 1)
30573
+ stages.push("input-scale");
30574
+ if (source)
30575
+ stages.push("source-inverse");
30576
+ if (inputVerticalScale !== 1)
30577
+ stages.push("input-height-scale");
30578
+ stages.push("geographic-domain-check");
30579
+ if (fromPrime)
30580
+ stages.push("source-prime-meridian");
30581
+ if (from.verticalGrid)
30582
+ stages.push("source-vertical-grid");
30583
+ if (datum)
30584
+ stages.push("datum");
30585
+ if (to.verticalGrid)
30586
+ stages.push("target-vertical-grid");
30587
+ if (toPrime)
30588
+ stages.push("target-prime-meridian");
30589
+ if (longitudeWrap !== void 0)
30590
+ stages.push("longitude-wrap");
30591
+ if (target)
30592
+ stages.push("target-forward");
30593
+ if (outputScale !== 1)
30594
+ stages.push("output-scale");
30595
+ if (outputVerticalScale !== 1)
30596
+ stages.push("output-height-scale");
30597
+ if (horizontalOnly)
30598
+ stages.push("restore-height");
30599
+ if (outputAxis)
30600
+ stages.push("output-axis");
30194
30601
  return {
30602
+ description: Object.freeze({
30603
+ inputAxis: fromAxis,
30604
+ outputAxis: toAxis,
30605
+ requiresInputZ,
30606
+ geocentricOutput: to.kind === "geocentric",
30607
+ stages: Object.freeze(stages)
30608
+ }),
30195
30609
  flat,
30196
- requiresInputZ: Boolean(from.verticalGrid || to.verticalGrid) || from.kind === "geocentric" || /[ud]/.test(fromAxis.slice(0, 2)) || /[ud]/.test(toAxis.slice(0, 2)),
30610
+ requiresInputZ,
30197
30611
  geocentricOutput: to.kind === "geocentric",
30198
30612
  run(point) {
30199
30613
  if (!finite(point))
@@ -30307,6 +30721,7 @@ return true;`);
30307
30721
  init_parameters();
30308
30722
  init_geographic_rendering_profile();
30309
30723
  init_vertical_datum();
30724
+ init_transform_description();
30310
30725
  ProjectionTransform = class _ProjectionTransform {
30311
30726
  /** Resolve required descriptors once, then return an ordinary synchronous instance. */
30312
30727
  static async create(options = {}) {
@@ -30320,6 +30735,10 @@ return true;`);
30320
30735
  getTargetRenderingProfile(coverage) {
30321
30736
  return this.targetRenderingProfile && resolveRenderingProfile(this.targetRenderingProfile, coverage);
30322
30737
  }
30738
+ /** Deferred transforms expose metadata only once their implementations are prepared. */
30739
+ get description() {
30740
+ return this.deferred?.implementation?.description ?? this.resolvedDescription;
30741
+ }
30323
30742
  constructor(options = {}) {
30324
30743
  this.coordinateScratch = new ProjectionScratch();
30325
30744
  this.targetLongitudeOrigin = 0;
@@ -30345,6 +30764,7 @@ return true;`);
30345
30764
  unsupportedStage("Horizontal extraction cannot be combined with vertical grids");
30346
30765
  this.forwardTransform = compileTransform(from, to, Boolean(options.enforceAxis));
30347
30766
  this.inverseTransform = compileTransform(to, from, Boolean(options.enforceAxis));
30767
+ this.resolvedDescription = describeTransform(describeCRS(from), describeCRS(to), this.forwardTransform.description, this.inverseTransform.description);
30348
30768
  }
30349
30769
  this.project = this.project.bind(this);
30350
30770
  this.unproject = this.unproject.bind(this);
@@ -30856,6 +31276,7 @@ return true;`);
30856
31276
  init_rendering_bounds();
30857
31277
  mercator = {
30858
31278
  name: "merc",
31279
+ semantics: { id: "@math.gl/geospatial/merc", version: 1 },
30859
31280
  aliases: [
30860
31281
  "Mercator",
30861
31282
  "Popular Visualisation Pseudo Mercator",
@@ -30949,6 +31370,7 @@ return true;`);
30949
31370
  init_rendering_bounds();
30950
31371
  equidistantCylindrical = {
30951
31372
  name: "eqc",
31373
+ semantics: { id: "@math.gl/geospatial/eqc", version: 1 },
30952
31374
  aliases: ["Equirectangular", "Equidistant_Cylindrical", "Equidistant_Cylindrical_Spherical"],
30953
31375
  parameters: ["lon_0", "lat_0", "lat_ts", "x_0", "y_0"],
30954
31376
  create({ semiMajorAxis: a, parameters, primeMeridian: primeMeridian2 = 0 }) {
@@ -38233,8 +38655,8 @@ return true;`);
38233
38655
  var init_spatial_coordinate_transformer = __esm({
38234
38656
  "src/spatial/spatial-coordinate-transformer.ts"() {
38235
38657
  "use strict";
38236
- init_dist();
38237
- init_dist3();
38658
+ init_dist2();
38659
+ init_dist4();
38238
38660
  init_bulk();
38239
38661
  init_spatial_resource_registry();
38240
38662
  init_normalize_crs_identifier();
@@ -38628,8 +39050,8 @@ return true;`);
38628
39050
  var init_i3s_spatial_transformer = __esm({
38629
39051
  "src/spatial/i3s-spatial-transformer.ts"() {
38630
39052
  "use strict";
38631
- init_dist();
38632
- init_dist3();
39053
+ init_dist2();
39054
+ init_dist4();
38633
39055
  init_spatial_coordinate_transformer();
38634
39056
  init_spatial_types();
38635
39057
  init_i3s_elevation();
@@ -39268,7 +39690,7 @@ return true;`);
39268
39690
  var init_constants6 = __esm({
39269
39691
  "src/i3s/lib/parsers/constants.ts"() {
39270
39692
  "use strict";
39271
- init_dist2();
39693
+ init_dist3();
39272
39694
  GL_TYPE_MAP = {
39273
39695
  UInt8: GL.UNSIGNED_BYTE,
39274
39696
  UInt16: GL.UNSIGNED_SHORT,
@@ -40016,9 +40438,9 @@ return true;`);
40016
40438
  "src/i3s/lib/parsers/parse-i3s-tile-content.ts"() {
40017
40439
  "use strict";
40018
40440
  init_schema3();
40019
- init_dist();
40020
- init_dist3();
40021
- init_dist3();
40441
+ init_dist2();
40442
+ init_dist4();
40443
+ init_dist4();
40022
40444
  init_loader_utils();
40023
40445
  init_src();
40024
40446
  init_src2();
@@ -40108,7 +40530,7 @@ return true;`);
40108
40530
  "use strict";
40109
40531
  init_i3s_format();
40110
40532
  init_i3s_loader_options();
40111
- VERSION4 = true ? "5.0.0-beta.4" : "latest";
40533
+ VERSION4 = true ? "5.0.0-beta.6" : "latest";
40112
40534
  I3SContentLoader = {
40113
40535
  ...I3SContentFormat,
40114
40536
  dataType: null,