@loaders.gl/tile-converter 4.0.4 → 4.0.5

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/index.cjs CHANGED
@@ -5291,6 +5291,8 @@ var Tiles3DConverter = class {
5291
5291
  this.loaderOptions = {
5292
5292
  _nodeWorkers: true,
5293
5293
  reuseWorkers: true,
5294
+ // TODO: converter freezes in the end because of i3s-content-worker
5295
+ worker: false,
5294
5296
  i3s: { coordinateSystem: import_i3s2.COORDINATE_SYSTEM.LNGLAT_OFFSETS, decodeTextures: false },
5295
5297
  // We need to load local fs workers because nodejs can't load workers from the Internet
5296
5298
  "i3s-content": {
@@ -5414,11 +5416,9 @@ var Tiles3DConverter = class {
5414
5416
  if (this.options.maxDepth && level > this.options.maxDepth) {
5415
5417
  return;
5416
5418
  }
5417
- const promises = [];
5418
5419
  for (const childNodeInfo of parentSourceNode.children || []) {
5419
- promises.push(this.convertChildNode(parentSourceNode, parentNode, level, childNodeInfo));
5420
+ await this.convertChildNode(parentSourceNode, parentNode, level, childNodeInfo);
5420
5421
  }
5421
- await Promise.all(promises);
5422
5422
  }
5423
5423
  /**
5424
5424
  * Load a child node having information from the node header
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@loaders.gl/tile-converter",
3
- "version": "4.0.4",
3
+ "version": "4.0.5",
4
4
  "description": "Converter",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -52,18 +52,18 @@
52
52
  "build-i3s-server-bundle": "esbuild src/i3s-server/bin/www.ts --outfile=dist/i3s-server/bin/i3s-server.min.cjs --platform=node --target=esnext,node14 --minify --bundle --define:__VERSION__=\\\"$npm_package_version\\\""
53
53
  },
54
54
  "dependencies": {
55
- "@loaders.gl/3d-tiles": "4.0.4",
56
- "@loaders.gl/crypto": "4.0.4",
57
- "@loaders.gl/draco": "4.0.4",
58
- "@loaders.gl/gltf": "4.0.4",
59
- "@loaders.gl/i3s": "4.0.4",
60
- "@loaders.gl/images": "4.0.4",
61
- "@loaders.gl/loader-utils": "4.0.4",
62
- "@loaders.gl/polyfills": "4.0.4",
63
- "@loaders.gl/textures": "4.0.4",
64
- "@loaders.gl/tiles": "4.0.4",
65
- "@loaders.gl/worker-utils": "4.0.4",
66
- "@loaders.gl/zip": "4.0.4",
55
+ "@loaders.gl/3d-tiles": "4.0.5",
56
+ "@loaders.gl/crypto": "4.0.5",
57
+ "@loaders.gl/draco": "4.0.5",
58
+ "@loaders.gl/gltf": "4.0.5",
59
+ "@loaders.gl/i3s": "4.0.5",
60
+ "@loaders.gl/images": "4.0.5",
61
+ "@loaders.gl/loader-utils": "4.0.5",
62
+ "@loaders.gl/polyfills": "4.0.5",
63
+ "@loaders.gl/textures": "4.0.5",
64
+ "@loaders.gl/tiles": "4.0.5",
65
+ "@loaders.gl/worker-utils": "4.0.5",
66
+ "@loaders.gl/zip": "4.0.5",
67
67
  "@math.gl/core": "^4.0.0",
68
68
  "@math.gl/culling": "^4.0.0",
69
69
  "@math.gl/geoid": "^4.0.0",
@@ -87,7 +87,7 @@
87
87
  "join-images": "^1.1.3",
88
88
  "sharp": "^0.31.3"
89
89
  },
90
- "gitHead": "4dc810fa04bb400f4aedfef98a83c7ef882ed3d7",
90
+ "gitHead": "9cc48b95bdad8842ebfd9a19f487c534f32526e9",
91
91
  "devDependencies": {
92
92
  "@types/express": "^4.17.17",
93
93
  "@types/node": "^20.4.2"
@@ -44,6 +44,8 @@ export default class Tiles3DConverter {
44
44
  loaderOptions: I3SLoaderOptions = {
45
45
  _nodeWorkers: true,
46
46
  reuseWorkers: true,
47
+ // TODO: converter freezes in the end because of i3s-content-worker
48
+ worker: false,
47
49
  i3s: {coordinateSystem: COORDINATE_SYSTEM.LNGLAT_OFFSETS, decodeTextures: false},
48
50
  // We need to load local fs workers because nodejs can't load workers from the Internet
49
51
  'i3s-content': {
@@ -208,11 +210,9 @@ export default class Tiles3DConverter {
208
210
  if (this.options.maxDepth && level > this.options.maxDepth) {
209
211
  return;
210
212
  }
211
- const promises: Promise<void>[] = [];
212
213
  for (const childNodeInfo of parentSourceNode.children || []) {
213
- promises.push(this.convertChildNode(parentSourceNode, parentNode, level, childNodeInfo));
214
+ await this.convertChildNode(parentSourceNode, parentNode, level, childNodeInfo);
214
215
  }
215
- await Promise.all(promises);
216
216
  }
217
217
 
218
218
  /**
@@ -158,7 +158,7 @@ async function convert(options: ValidatedTileConversionOptions) {
158
158
  switch (inputType) {
159
159
  case TILESET_TYPE.I3S:
160
160
  const tiles3DConverter = new Tiles3DConverter();
161
- tiles3DConverter.convert({
161
+ await tiles3DConverter.convert({
162
162
  inputUrl: options.tileset,
163
163
  outputPath: options.output,
164
164
  tilesetName: options.name,