@loaders.gl/mvt 4.3.0-alpha.1 → 4.3.0-alpha.3

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 (93) hide show
  1. package/dist/dist.dev.js +1289 -807
  2. package/dist/dist.min.js +1 -1
  3. package/dist/index.cjs +923 -773
  4. package/dist/index.cjs.map +4 -4
  5. package/dist/index.d.ts +7 -6
  6. package/dist/index.d.ts.map +1 -1
  7. package/dist/index.js +6 -2
  8. package/dist/lib/parse-mvt.d.ts +1 -1
  9. package/dist/lib/parse-mvt.js +2 -30
  10. package/dist/lib/parse-tilejson.d.ts +4 -4
  11. package/dist/lib/parse-tilejson.d.ts.map +1 -1
  12. package/dist/lib/parse-tilejson.js +1 -1
  13. package/dist/lib/utils/geometry-utils.d.ts +38 -1
  14. package/dist/lib/utils/geometry-utils.d.ts.map +1 -1
  15. package/dist/lib/utils/geometry-utils.js +65 -6
  16. package/dist/lib/vector-tile/vector-tile-feature.d.ts +28 -9
  17. package/dist/lib/vector-tile/vector-tile-feature.d.ts.map +1 -1
  18. package/dist/lib/vector-tile/vector-tile-feature.js +47 -50
  19. package/dist/lib/{geojsonvt/clip.d.ts → vector-tiler/features/clip-features.d.ts} +4 -4
  20. package/dist/lib/vector-tiler/features/clip-features.d.ts.map +1 -0
  21. package/dist/lib/{geojsonvt/clip.js → vector-tiler/features/clip-features.js} +4 -4
  22. package/dist/lib/vector-tiler/features/convert-feature.d.ts +18 -0
  23. package/dist/lib/vector-tiler/features/convert-feature.d.ts.map +1 -0
  24. package/dist/lib/vector-tiler/features/convert-feature.js +140 -0
  25. package/dist/lib/vector-tiler/features/proto-feature.d.ts +30 -0
  26. package/dist/lib/vector-tiler/features/proto-feature.d.ts.map +1 -0
  27. package/dist/lib/vector-tiler/features/proto-feature.js +52 -0
  28. package/dist/lib/{geojsonvt/simplify.d.ts → vector-tiler/features/simplify-path.d.ts} +2 -2
  29. package/dist/lib/vector-tiler/features/simplify-path.d.ts.map +1 -0
  30. package/dist/lib/{geojsonvt/simplify.js → vector-tiler/features/simplify-path.js} +3 -3
  31. package/dist/lib/{geojsonvt/wrap.d.ts → vector-tiler/features/wrap-features.d.ts} +5 -5
  32. package/dist/lib/vector-tiler/features/wrap-features.d.ts.map +1 -0
  33. package/dist/lib/{geojsonvt/wrap.js → vector-tiler/features/wrap-features.js} +33 -26
  34. package/dist/lib/vector-tiler/proto-tile.d.ts +40 -0
  35. package/dist/lib/vector-tiler/proto-tile.d.ts.map +1 -0
  36. package/dist/lib/vector-tiler/proto-tile.js +138 -0
  37. package/dist/lib/vector-tiler/tile-to-geojson.d.ts +12 -0
  38. package/dist/lib/vector-tiler/tile-to-geojson.d.ts.map +1 -0
  39. package/dist/lib/vector-tiler/tile-to-geojson.js +81 -0
  40. package/dist/lib/vector-tiler/transform-tile.d.ts +7 -0
  41. package/dist/lib/vector-tiler/transform-tile.d.ts.map +1 -0
  42. package/dist/lib/vector-tiler/transform-tile.js +41 -0
  43. package/dist/mvt-loader.d.ts +1 -1
  44. package/dist/mvt-loader.js +1 -1
  45. package/dist/mvt-source.d.ts +35 -18
  46. package/dist/mvt-source.d.ts.map +1 -1
  47. package/dist/mvt-source.js +30 -10
  48. package/dist/mvt-worker.js +101 -56
  49. package/dist/table-tile-source.d.ts +148 -0
  50. package/dist/table-tile-source.d.ts.map +1 -0
  51. package/dist/table-tile-source.js +420 -0
  52. package/dist/tilejson-loader.js +1 -1
  53. package/package.json +7 -6
  54. package/src/index.ts +14 -7
  55. package/src/lib/parse-mvt.ts +4 -33
  56. package/src/lib/parse-tilejson.ts +6 -6
  57. package/src/lib/utils/geometry-utils.ts +66 -1
  58. package/src/lib/vector-tile/vector-tile-feature.ts +65 -56
  59. package/src/lib/{geojsonvt/clip.ts → vector-tiler/features/clip-features.ts} +8 -8
  60. package/src/lib/vector-tiler/features/convert-feature.ts +191 -0
  61. package/src/lib/vector-tiler/features/proto-feature.ts +104 -0
  62. package/src/lib/{geojsonvt/simplify.ts → vector-tiler/features/simplify-path.ts} +8 -3
  63. package/src/lib/{geojsonvt/wrap.ts → vector-tiler/features/wrap-features.ts} +44 -29
  64. package/src/lib/vector-tiler/proto-tile.ts +217 -0
  65. package/src/lib/vector-tiler/tile-to-geojson.ts +105 -0
  66. package/src/lib/vector-tiler/transform-tile.ts +57 -0
  67. package/src/mvt-source.ts +47 -24
  68. package/src/table-tile-source.ts +553 -0
  69. package/src/tilejson-loader.ts +2 -2
  70. package/dist/geojson-tile-source.d.ts +0 -79
  71. package/dist/geojson-tile-source.d.ts.map +0 -1
  72. package/dist/geojson-tile-source.js +0 -319
  73. package/dist/lib/geojsonvt/clip.d.ts.map +0 -1
  74. package/dist/lib/geojsonvt/convert.d.ts +0 -10
  75. package/dist/lib/geojsonvt/convert.d.ts.map +0 -1
  76. package/dist/lib/geojsonvt/convert.js +0 -132
  77. package/dist/lib/geojsonvt/feature.d.ts +0 -3
  78. package/dist/lib/geojsonvt/feature.d.ts.map +0 -1
  79. package/dist/lib/geojsonvt/feature.js +0 -44
  80. package/dist/lib/geojsonvt/simplify.d.ts.map +0 -1
  81. package/dist/lib/geojsonvt/tile.d.ts +0 -38
  82. package/dist/lib/geojsonvt/tile.d.ts.map +0 -1
  83. package/dist/lib/geojsonvt/tile.js +0 -123
  84. package/dist/lib/geojsonvt/transform.d.ts +0 -7
  85. package/dist/lib/geojsonvt/transform.d.ts.map +0 -1
  86. package/dist/lib/geojsonvt/transform.js +0 -41
  87. package/dist/lib/geojsonvt/wrap.d.ts.map +0 -1
  88. package/src/geojson-tile-source.ts +0 -422
  89. package/src/lib/geojsonvt/convert.ts +0 -160
  90. package/src/lib/geojsonvt/feature.ts +0 -47
  91. package/src/lib/geojsonvt/tile.ts +0 -187
  92. package/src/lib/geojsonvt/transform.ts +0 -57
  93. /package/src/lib/{geojsonvt → vector-tiler}/LICENSE +0 -0
@@ -0,0 +1,41 @@
1
+ // loaders.gl
2
+ // SPDX-License-Identifier: MIT
3
+ // Copyright (c) vis.gl contributors
4
+ // Forked from https://github.com/mapbox/geojson-vt under compatible ISC license
5
+ /**
6
+ * Transforms the coordinates of each protoFeature in the given protoTile from
7
+ * mercator-projected space into (extent x extent) protoTile space.
8
+ */
9
+ export function transformTile(protoTile, extent) {
10
+ if (protoTile.transformed) {
11
+ return protoTile;
12
+ }
13
+ const z2 = 1 << protoTile.z;
14
+ const tx = protoTile.x;
15
+ const ty = protoTile.y;
16
+ for (const protoFeature of protoTile.protoFeatures) {
17
+ const geom = protoFeature.geometry;
18
+ const simplifiedType = protoFeature.simplifiedType;
19
+ protoFeature.geometry = [];
20
+ if (simplifiedType === 1) {
21
+ for (let j = 0; j < geom.length; j += 2) {
22
+ protoFeature.geometry.push(transformPoint(geom[j], geom[j + 1], extent, z2, tx, ty));
23
+ }
24
+ }
25
+ else {
26
+ for (let j = 0; j < geom.length; j++) {
27
+ const ring = [];
28
+ for (let k = 0; k < geom[j].length; k += 2) {
29
+ ring.push(transformPoint(geom[j][k], geom[j][k + 1], extent, z2, tx, ty));
30
+ }
31
+ protoFeature.geometry.push(ring);
32
+ }
33
+ }
34
+ }
35
+ protoTile.transformed = true;
36
+ return protoTile;
37
+ }
38
+ // eslint-disable-next-line max-params
39
+ function transformPoint(x, y, extent, z2, tx, ty) {
40
+ return [Math.round(extent * (x * z2 - tx)), Math.round(extent * (y * z2 - ty))];
41
+ }
@@ -52,7 +52,7 @@ export declare const MVTWorkerLoader: {
52
52
  * Loader for the Mapbox Vector Tile format
53
53
  */
54
54
  export declare const MVTLoader: {
55
- readonly parse: (arrayBuffer: ArrayBuffer, options?: MVTLoaderOptions) => Promise<import("@loaders.gl/schema").GeoJSONTable | import("geojson").Feature<import("geojson").Geometry, import("geojson").GeoJsonProperties>[] | import("@loaders.gl/schema").BinaryFeatureCollection | {
55
+ readonly parse: (arrayBuffer: ArrayBuffer, options?: MVTLoaderOptions) => Promise<import("@loaders.gl/schema").BinaryFeatureCollection | import("@loaders.gl/schema").GeoJSONTable | import("geojson").Feature<import("geojson").Geometry, import("geojson").GeoJsonProperties>[] | {
56
56
  shape: string;
57
57
  data: import("@loaders.gl/schema").BinaryFeatureCollection;
58
58
  }>;
@@ -5,7 +5,7 @@
5
5
  import { parseMVT } from "./lib/parse-mvt.js";
6
6
  // __VERSION__ is injected by babel-plugin-version-inline
7
7
  // @ts-ignore TS2304: Cannot find name '__VERSION__'.
8
- const VERSION = typeof "4.2.0" !== 'undefined' ? "4.2.0" : 'latest';
8
+ const VERSION = typeof "4.3.0-alpha.2" !== 'undefined' ? "4.3.0-alpha.2" : 'latest';
9
9
  /**
10
10
  * Worker loader for the Mapbox Vector Tile format
11
11
  */
@@ -1,21 +1,38 @@
1
- import type { GetTileParameters, ImageType, DataSourceProps } from '@loaders.gl/loader-utils';
1
+ import type { ImageType, DataSourceProps } from '@loaders.gl/loader-utils';
2
2
  import type { ImageTileSource, VectorTileSource } from '@loaders.gl/loader-utils';
3
+ import type { GetTileParameters, GetTileDataParameters } from '@loaders.gl/loader-utils';
3
4
  import { DataSource } from '@loaders.gl/loader-utils';
4
5
  import { ImageLoaderOptions } from '@loaders.gl/images';
5
6
  import { MVTLoaderOptions, TileJSON, TileJSONLoaderOptions } from '@loaders.gl/mvt';
6
- import { TileLoadParameters } from '@loaders.gl/loader-utils';
7
+ /** Creates an MVTTileSource */
8
+ export declare const MVTSource: {
9
+ readonly name: "MVT";
10
+ readonly id: "mvt";
11
+ readonly module: "mvt";
12
+ readonly version: "0.0.0";
13
+ readonly extensions: ["mvt"];
14
+ readonly mimeTypes: ["application/octet-stream"];
15
+ readonly options: {
16
+ readonly mvt: {};
17
+ };
18
+ readonly type: "mvt";
19
+ readonly fromUrl: true;
20
+ readonly fromBlob: false;
21
+ readonly testURL: (url: string) => boolean;
22
+ readonly createDataSource: (url: string, props: MVTTileSourceProps) => MVTTileSource;
23
+ };
7
24
  /** Properties for a Mapbox Vector Tile Source */
8
- export type MVTSourceProps = DataSourceProps & {
9
- /** Root url of tileset */
10
- url: string;
11
- /** if not supplied, loads tilejson.json, If null does not load metadata */
12
- metadataUrl?: string | null;
13
- /** Override extension (necessary if no metadata) */
14
- extension?: string;
15
- /** Additional attribution, adds to any attribution loaded from tileset metadata */
16
- attributions?: string[];
17
- /** Specify load options for all sub loaders */
18
- loadOptions?: TileJSONLoaderOptions & MVTLoaderOptions & ImageLoaderOptions;
25
+ export type MVTTileSourceProps = DataSourceProps & {
26
+ mvt?: {
27
+ /** if not supplied, loads tilejson.json, If null does not load metadata */
28
+ metadataUrl?: string | null;
29
+ /** Override extension (necessary if no metadata) */
30
+ extension?: string;
31
+ /** Additional attribution, adds to any attribution loaded from tileset metadata */
32
+ attributions?: string[];
33
+ /** Specify load options for all sub loaders */
34
+ loadOptions?: TileJSONLoaderOptions & MVTLoaderOptions & ImageLoaderOptions;
35
+ };
19
36
  };
20
37
  /**
21
38
  * MVT data source for Mapbox Vector Tiles v1.
@@ -24,8 +41,8 @@ export type MVTSourceProps = DataSourceProps & {
24
41
  * A PMTiles data source
25
42
  * @note Can be either a raster or vector tile source depending on the contents of the PMTiles file.
26
43
  */
27
- export declare class MVTSource extends DataSource implements ImageTileSource, VectorTileSource {
28
- readonly props: MVTSourceProps;
44
+ export declare class MVTTileSource extends DataSource implements ImageTileSource, VectorTileSource {
45
+ readonly props: MVTTileSourceProps;
29
46
  readonly url: string;
30
47
  readonly metadataUrl: string | null;
31
48
  data: string;
@@ -33,11 +50,11 @@ export declare class MVTSource extends DataSource implements ImageTileSource, Ve
33
50
  metadata: Promise<TileJSON | null>;
34
51
  extension: string;
35
52
  mimeType: string | null;
36
- constructor(props: MVTSourceProps);
53
+ constructor(url: string, props: MVTTileSourceProps);
37
54
  getMetadata(): Promise<TileJSON | null>;
38
55
  getTileMIMEType(): string | null;
39
- getTile(tileParams: GetTileParameters): Promise<ArrayBuffer | null>;
40
- getTileData(tileParams: TileLoadParameters): Promise<unknown | null>;
56
+ getTile(parameters: GetTileParameters): Promise<ArrayBuffer | null>;
57
+ getTileData(parameters: GetTileDataParameters): Promise<any>;
41
58
  getImageTile(tileParams: GetTileParameters): Promise<ImageType | null>;
42
59
  protected _parseImageTile(arrayBuffer: ArrayBuffer): Promise<ImageType>;
43
60
  getVectorTile(tileParams: GetTileParameters): Promise<unknown | null>;
@@ -1 +1 @@
1
- {"version":3,"file":"mvt-source.d.ts","sourceRoot":"","sources":["../src/mvt-source.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAC,iBAAiB,EAAE,SAAS,EAAE,eAAe,EAAC,MAAM,0BAA0B,CAAC;AAC5F,OAAO,KAAK,EAAC,eAAe,EAAE,gBAAgB,EAAC,MAAM,0BAA0B,CAAC;AAChF,OAAO,EAAC,UAAU,EAAc,MAAM,0BAA0B,CAAC;AACjE,OAAO,EAAc,kBAAkB,EAAyB,MAAM,oBAAoB,CAAC;AAC3F,OAAO,EAEL,gBAAgB,EAEhB,QAAQ,EACR,qBAAqB,EACtB,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EAAC,kBAAkB,EAAC,MAAM,0BAA0B,CAAC;AAE5D,iDAAiD;AACjD,MAAM,MAAM,cAAc,GAAG,eAAe,GAAG;IAC7C,0BAA0B;IAC1B,GAAG,EAAE,MAAM,CAAC;IACZ,2EAA2E;IAC3E,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,oDAAoD;IACpD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,mFAAmF;IACnF,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IACxB,+CAA+C;IAC/C,WAAW,CAAC,EAAE,qBAAqB,GAAG,gBAAgB,GAAG,kBAAkB,CAAC;CAC7E,CAAC;AAEF;;GAEG;AACH;;;GAGG;AACH,qBAAa,SAAU,SAAQ,UAAW,YAAW,eAAe,EAAE,gBAAgB;IACpF,QAAQ,CAAC,KAAK,EAAE,cAAc,CAAC;IAC/B,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,WAAW,EAAE,MAAM,G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CAAC,EAAE,MAAM,EACT,CAAC,EAAE,MAAM,EACT,CAAC,EAAE,MAAM,EACT,EAAE,GAAE,MAAY,GACf,MAAM,CAiBR"}
@@ -4,6 +4,27 @@
4
4
  import { DataSource, resolvePath } from '@loaders.gl/loader-utils';
5
5
  import { ImageLoader, getBinaryImageMetadata } from '@loaders.gl/images';
6
6
  import { MVTLoader, TileJSONLoader } from '@loaders.gl/mvt';
7
+ /** Creates an MVTTileSource */
8
+ export const MVTSource = {
9
+ name: 'MVT',
10
+ id: 'mvt',
11
+ module: 'mvt',
12
+ version: '0.0.0',
13
+ extensions: ['mvt'],
14
+ mimeTypes: ['application/octet-stream'],
15
+ options: {
16
+ mvt: {
17
+ // TODO - add options here
18
+ }
19
+ },
20
+ type: 'mvt',
21
+ fromUrl: true,
22
+ fromBlob: false,
23
+ testURL: (url) => true,
24
+ createDataSource(url, props) {
25
+ return new MVTTileSource(url, props);
26
+ }
27
+ };
7
28
  /**
8
29
  * MVT data source for Mapbox Vector Tiles v1.
9
30
  */
@@ -11,7 +32,7 @@ import { MVTLoader, TileJSONLoader } from '@loaders.gl/mvt';
11
32
  * A PMTiles data source
12
33
  * @note Can be either a raster or vector tile source depending on the contents of the PMTiles file.
13
34
  */
14
- export class MVTSource extends DataSource {
35
+ export class MVTTileSource extends DataSource {
15
36
  props;
16
37
  url;
17
38
  metadataUrl = null;
@@ -20,13 +41,12 @@ export class MVTSource extends DataSource {
20
41
  metadata;
21
42
  extension;
22
43
  mimeType = null;
23
- constructor(props) {
44
+ constructor(url, props) {
24
45
  super(props);
25
46
  this.props = props;
26
- this.url = resolvePath(props.url);
27
- this.metadataUrl =
28
- props.metadataUrl === undefined ? `${this.url}/tilejson.json` : props.metadataUrl;
29
- this.extension = props.extension || '.png';
47
+ this.url = resolvePath(url);
48
+ this.metadataUrl = props.mvt?.metadataUrl || `${this.url}/tilejson.json`;
49
+ this.extension = props.mvt?.extension || '.png';
30
50
  this.data = this.url;
31
51
  this.getTileData = this.getTileData.bind(this);
32
52
  this.metadata = this.getMetadata();
@@ -67,8 +87,8 @@ export class MVTSource extends DataSource {
67
87
  getTileMIMEType() {
68
88
  return this.mimeType;
69
89
  }
70
- async getTile(tileParams) {
71
- const { x, y, z } = tileParams;
90
+ async getTile(parameters) {
91
+ const { x, y, z } = parameters;
72
92
  const tileUrl = this.getTileURL(x, y, z);
73
93
  const response = await this.fetch(tileUrl);
74
94
  if (!response.ok) {
@@ -79,8 +99,8 @@ export class MVTSource extends DataSource {
79
99
  }
80
100
  // Tile Source interface implementation: deck.gl compatible API
81
101
  // TODO - currently only handles image tiles, not vector tiles
82
- async getTileData(tileParams) {
83
- const { x, y, z } = tileParams.index;
102
+ async getTileData(parameters) {
103
+ const { x, y, z } = parameters.index;
84
104
  // const metadata = await this.metadata;
85
105
  // mimeType = metadata?.tileMIMEType || 'application/vnd.mapbox-vector-tile';
86
106
  const arrayBuffer = await this.getTile({ x, y, z, layers: [] });
@@ -1649,7 +1649,7 @@
1649
1649
  var navigator_ = globalThis.navigator || {};
1650
1650
 
1651
1651
  // ../../node_modules/@probe.gl/log/node_modules/@probe.gl/env/dist/utils/globals.js
1652
- var VERSION = true ? "4.2.0" : "untranspiled source";
1652
+ var VERSION = true ? "4.3.0-alpha.2" : "untranspiled source";
1653
1653
  var isBrowser2 = isBrowser();
1654
1654
 
1655
1655
  // ../../node_modules/@probe.gl/log/dist/utils/local-storage.js
@@ -2147,9 +2147,18 @@
2147
2147
  });
2148
2148
 
2149
2149
  // ../loader-utils/src/lib/log-utils/log.ts
2150
- var VERSION2 = true ? "4.2.0" : "latest";
2150
+ var VERSION2 = true ? "4.3.0-alpha.2" : "latest";
2151
2151
  var version = VERSION2[0] >= "0" && VERSION2[0] <= "9" ? `v${VERSION2}` : "";
2152
- var log = new Log({ id: `loaders.gl ${version}` });
2152
+ function createLog() {
2153
+ const log2 = new Log({ id: "loaders.gl" });
2154
+ globalThis.loaders = globalThis.loaders || {};
2155
+ globalThis.loaders.log = log2;
2156
+ globalThis.loaders.version = version;
2157
+ globalThis.probe = globalThis.probe || {};
2158
+ globalThis.probe.loaders = log2;
2159
+ return log2;
2160
+ }
2161
+ var log = createLog();
2153
2162
 
2154
2163
  // ../worker-utils/src/lib/node/worker_threads-browser.ts
2155
2164
  var parentPort = null;
@@ -2363,6 +2372,39 @@
2363
2372
  }
2364
2373
  return sum;
2365
2374
  }
2375
+ function convertToLocalCoordinates(coordinates, extent) {
2376
+ if (Array.isArray(coordinates[0])) {
2377
+ for (const subcoords of coordinates) {
2378
+ convertToLocalCoordinates(subcoords, extent);
2379
+ }
2380
+ return;
2381
+ }
2382
+ const p = coordinates;
2383
+ p[0] /= extent;
2384
+ p[1] /= extent;
2385
+ }
2386
+ function convertToLocalCoordinatesFlat(data, extent) {
2387
+ for (let i = 0; i < data.length; ++i) {
2388
+ data[i] /= extent;
2389
+ }
2390
+ }
2391
+ function projectToLngLat(line, tileIndex, extent) {
2392
+ if (typeof line[0][0] !== "number") {
2393
+ for (const point of line) {
2394
+ projectToLngLat(point, tileIndex, extent);
2395
+ }
2396
+ return;
2397
+ }
2398
+ const size = extent * Math.pow(2, tileIndex.z);
2399
+ const x0 = extent * tileIndex.x;
2400
+ const y0 = extent * tileIndex.y;
2401
+ for (let j = 0; j < line.length; j++) {
2402
+ const p = line[j];
2403
+ p[0] = (p[0] + x0) * 360 / size - 180;
2404
+ const y2 = 180 - (p[1] + y0) * 360 / size;
2405
+ p[1] = 360 / Math.PI * Math.atan(Math.exp(y2 * Math.PI / 180)) - 90;
2406
+ }
2407
+ }
2366
2408
  function projectToLngLatFlat(data, tileIndex, extent) {
2367
2409
  const { x, y, z } = tileIndex;
2368
2410
  const size = extent * Math.pow(2, z);
@@ -2472,39 +2514,37 @@
2472
2514
  this._geometryInfo = geometryInfo;
2473
2515
  pbf.readFields(readFeature, this, end);
2474
2516
  }
2475
- toGeoJSON(options) {
2517
+ toGeoJSONFeature(coordinates, tileIndex) {
2476
2518
  const coords = this.loadGeometry();
2477
- if (typeof options === "function") {
2478
- return _toGeoJSON(this, coords, options);
2479
- }
2480
- const { x, y, z } = options;
2481
- const size = this.extent * Math.pow(2, z);
2482
- const x0 = this.extent * x;
2483
- const y0 = this.extent * y;
2484
- function project(line) {
2485
- for (let j = 0; j < line.length; j++) {
2486
- const p = line[j];
2487
- p[0] = (p[0] + x0) * 360 / size - 180;
2488
- const y2 = 180 - (p[1] + y0) * 360 / size;
2489
- p[1] = 360 / Math.PI * Math.atan(Math.exp(y2 * Math.PI / 180)) - 90;
2490
- }
2519
+ switch (coordinates) {
2520
+ case "wgs84":
2521
+ return _toGeoJSONFeature(
2522
+ this,
2523
+ coords,
2524
+ (line) => projectToLngLat(line, tileIndex, this.extent)
2525
+ );
2526
+ default:
2527
+ return _toGeoJSONFeature(this, coords, convertToLocalCoordinates);
2491
2528
  }
2492
- return _toGeoJSON(this, coords, project);
2493
2529
  }
2494
2530
  /**
2495
2531
  *
2496
2532
  * @param options
2497
2533
  * @returns
2498
2534
  */
2499
- toBinaryCoordinates(options) {
2500
- if (typeof options === "function") {
2501
- return this._toBinaryCoordinates(options);
2535
+ toBinaryFeature(coordinates, tileIndex) {
2536
+ const geom = this.loadFlatGeometry();
2537
+ switch (coordinates) {
2538
+ case "wgs84":
2539
+ return this._toBinaryCoordinates(
2540
+ geom,
2541
+ (coords) => projectToLngLatFlat(coords, tileIndex, this.extent)
2542
+ );
2543
+ default:
2544
+ return this._toBinaryCoordinates(geom, convertToLocalCoordinatesFlat);
2502
2545
  }
2503
- const tileIndex = options;
2504
- return this._toBinaryCoordinates(
2505
- (data) => projectToLngLatFlat(data, tileIndex, this.extent)
2506
- );
2507
2546
  }
2547
+ /** Read a bounding box from the feature */
2508
2548
  // eslint-disable-next-line max-statements
2509
2549
  bbox() {
2510
2550
  const pbf = this._pbf;
@@ -2548,10 +2588,9 @@
2548
2588
  * @param transform
2549
2589
  * @returns result
2550
2590
  */
2551
- _toBinaryCoordinates(transform) {
2552
- const geom = this.loadFlatGeometry();
2591
+ _toBinaryCoordinates(geom, transform) {
2553
2592
  let geometry;
2554
- transform(geom.data, this);
2593
+ transform(geom.data, this.extent);
2555
2594
  const coordLength = 2;
2556
2595
  switch (this.type) {
2557
2596
  case 1:
@@ -2628,6 +2667,28 @@
2628
2667
  lines.push(line);
2629
2668
  return lines;
2630
2669
  }
2670
+ /**
2671
+ * Expands the protobuf data to an intermediate Flat GeoJSON
2672
+ * data format, which maps closely to the binary data buffers.
2673
+ * It is similar to GeoJSON, but rather than storing the coordinates
2674
+ * in multidimensional arrays, we have a 1D `data` with all the
2675
+ * coordinates, and then index into this using the `indices`
2676
+ * parameter, e.g.
2677
+ *
2678
+ * geometry: {
2679
+ * type: 'Point', data: [1,2], indices: [0]
2680
+ * }
2681
+ * geometry: {
2682
+ * type: 'LineString', data: [1,2,3,4,...], indices: [0]
2683
+ * }
2684
+ * geometry: {
2685
+ * type: 'Polygon', data: [1,2,3,4,...], indices: [[0, 2]]
2686
+ * }
2687
+ * Thus the indices member lets us look up the relevant range
2688
+ * from the data array.
2689
+ * The Multi* versions of the above types share the same data
2690
+ * structure, just with multiple elements in the indices array
2691
+ */
2631
2692
  // eslint-disable-next-line complexity, max-statements
2632
2693
  loadFlatGeometry() {
2633
2694
  const pbf = this._pbf;
@@ -2670,7 +2731,7 @@
2670
2731
  }
2671
2732
  };
2672
2733
  __publicField(VectorTileFeature, "types", ["Unknown", "Point", "LineString", "Polygon"]);
2673
- function _toGeoJSON(vtFeature, coords, transform) {
2734
+ function _toGeoJSONFeature(vtFeature, coords, transform) {
2674
2735
  let type = VectorTileFeature.types[vtFeature.type];
2675
2736
  let i;
2676
2737
  let j;
@@ -2682,19 +2743,19 @@
2682
2743
  points[i] = coords[i][0];
2683
2744
  }
2684
2745
  coordinates = points;
2685
- transform(coordinates, vtFeature);
2746
+ transform(coordinates, vtFeature.extent);
2686
2747
  break;
2687
2748
  case 2:
2688
2749
  coordinates = coords;
2689
2750
  for (i = 0; i < coordinates.length; i++) {
2690
- transform(coordinates[i], vtFeature);
2751
+ transform(coordinates[i], vtFeature.extent);
2691
2752
  }
2692
2753
  break;
2693
2754
  case 3:
2694
2755
  coordinates = classifyRings(coords);
2695
2756
  for (i = 0; i < coordinates.length; i++) {
2696
2757
  for (j = 0; j < coordinates[i].length; j++) {
2697
- transform(coordinates[i][j], vtFeature);
2758
+ transform(coordinates[i][j], vtFeature.extent);
2698
2759
  }
2699
2760
  }
2700
2761
  break;
@@ -2715,7 +2776,8 @@
2715
2776
  properties: vtFeature.properties
2716
2777
  };
2717
2778
  if (vtFeature.id !== null) {
2718
- result.id = vtFeature.id;
2779
+ result.properties ||= {};
2780
+ result.properties.id = vtFeature.id;
2719
2781
  }
2720
2782
  return result;
2721
2783
  }
@@ -2938,9 +3000,9 @@
2938
3000
  return options.mvt;
2939
3001
  }
2940
3002
  function getDecodedFeature(feature, options, layerName) {
2941
- const decodedFeature = feature.toGeoJSON(
2942
- // @ts-expect-error What is going on here?
2943
- options.coordinates === "wgs84" ? options.tileIndex : transformToLocalCoordinates
3003
+ const decodedFeature = feature.toGeoJSONFeature(
3004
+ options.coordinates || "local",
3005
+ options.tileIndex
2944
3006
  );
2945
3007
  if (options.layerProperty) {
2946
3008
  decodedFeature.properties ||= {};
@@ -2949,32 +3011,15 @@
2949
3011
  return decodedFeature;
2950
3012
  }
2951
3013
  function getDecodedFeatureBinary(feature, options, layerName) {
2952
- const decodedFeature = feature.toBinaryCoordinates(
2953
- // @ts-expect-error
2954
- options.coordinates === "wgs84" ? options.tileIndex : transformToLocalCoordinatesBinary
2955
- );
3014
+ const decodedFeature = feature.toBinaryFeature(options.coordinates || "local", options.tileIndex);
2956
3015
  if (options.layerProperty && decodedFeature.properties) {
2957
3016
  decodedFeature.properties[options.layerProperty] = layerName;
2958
3017
  }
2959
3018
  return decodedFeature;
2960
3019
  }
2961
- function transformToLocalCoordinates(line, feature) {
2962
- const { extent } = feature;
2963
- for (let i = 0; i < line.length; i++) {
2964
- const p = line[i];
2965
- p[0] /= extent;
2966
- p[1] /= extent;
2967
- }
2968
- }
2969
- function transformToLocalCoordinatesBinary(data, feature) {
2970
- const { extent } = feature;
2971
- for (let i = 0, il = data.length; i < il; ++i) {
2972
- data[i] /= extent;
2973
- }
2974
- }
2975
3020
 
2976
3021
  // src/mvt-loader.ts
2977
- var VERSION3 = true ? "4.2.0" : "latest";
3022
+ var VERSION3 = true ? "4.3.0-alpha.2" : "latest";
2978
3023
  var MVTWorkerLoader = {
2979
3024
  dataType: null,
2980
3025
  batchType: null,
@@ -0,0 +1,148 @@
1
+ import type { VectorTileSourceProps, GetTileDataParameters, GetTileParameters, LoaderWithParser } from '@loaders.gl/loader-utils';
2
+ import { VectorTileSource, TileSourceMetadata } from '@loaders.gl/loader-utils';
3
+ import { Schema, GeoJSONTable, Feature, BinaryFeatureCollection } from '@loaders.gl/schema';
4
+ import { Stats } from '@probe.gl/stats';
5
+ import type { ProtoFeature } from "./lib/vector-tiler/features/proto-feature.js";
6
+ import type { ProtoTile } from "./lib/vector-tiler/proto-tile.js";
7
+ /** Options to configure tiling */
8
+ export declare const TableTileSource: {
9
+ readonly name: "TableTiler";
10
+ readonly id: "table-tiler";
11
+ readonly version: "0.0.0";
12
+ readonly extensions: ["mvt"];
13
+ readonly mimeTypes: ["application/octet-stream"];
14
+ readonly options: {
15
+ readonly table: {
16
+ readonly coordinates: "local";
17
+ readonly promoteId: never;
18
+ readonly maxZoom: 14;
19
+ readonly indexMaxZoom: 5;
20
+ readonly maxPointsPerTile: 10000;
21
+ readonly tolerance: 3;
22
+ readonly extent: 4096;
23
+ readonly buffer: 64;
24
+ readonly generateId: undefined;
25
+ };
26
+ };
27
+ readonly type: "table";
28
+ readonly testURL: (url: string) => boolean;
29
+ readonly createDataSource: (url: string | Blob | GeoJSONTable | Promise<GeoJSONTable>, options: DynamicVectorTileSourceProps) => DynamicVectorTileSource;
30
+ };
31
+ /** Options to configure tiling */
32
+ export type DynamicVectorTileSourceProps = VectorTileSourceProps & {
33
+ table: {
34
+ coordinates: 'local' | 'wgs84' | 'EPSG:4326';
35
+ /** max zoom to preserve detail on */
36
+ maxZoom?: number;
37
+ /** max zoom in the tile index */
38
+ indexMaxZoom?: number;
39
+ /** max number of points per tile in the tile index */
40
+ maxPointsPerTile?: number;
41
+ /** simplification tolerance (higher means simpler) */
42
+ tolerance?: number;
43
+ /** tile extent */
44
+ extent?: number;
45
+ /** tile buffer on each side */
46
+ buffer?: number;
47
+ /** name of a feature property to be promoted to feature.id */
48
+ promoteId?: string;
49
+ /** whether to generate feature ids. Cannot be used with promoteId */
50
+ generateId?: boolean;
51
+ /** logging level (0, 1 or 2) */
52
+ debug?: number;
53
+ /** whether to calculate line metrics */
54
+ lineMetrics?: boolean;
55
+ /** table loders */
56
+ loaders?: LoaderWithParser[];
57
+ };
58
+ };
59
+ /**
60
+ * Dynamically vector tiles a table (the table needs a geometry column)
61
+ * - Tiles are generated when requested.
62
+ * - Each tile contains a tables of clipped features.
63
+ *
64
+ * @note - Currently only accepts `GeoJSONTable` tables
65
+ * @note - Currently only outputs `GeoJSONTable`
66
+ * @note - (can be initialized with a promise that resolves to GeoJSONTable).
67
+ *
68
+ * @todo - metadata should scan all rows to determine schema
69
+ * @todo - metadata scan all rows to determine tilestats (field values[] etc).
70
+ * @todo - handle binary input tables
71
+ * @todo - generate binary output tables
72
+ * @todo - how does TileSourceLayer specify coordinates / decided which layer to render with
73
+ */
74
+ export declare class DynamicVectorTileSource implements VectorTileSource<DynamicVectorTileSourceProps, TileSourceMetadata> {
75
+ /** Global stats for all DynamicVectorTileSources */
76
+ static stats: Stats;
77
+ /** Stats for this DynamicVectorTileSource */
78
+ stats: Stats;
79
+ /** MIME type of the tiles emitted by this tile source */
80
+ readonly mimeType = "application/vnd.mapbox-vector-tile";
81
+ readonly localCoordinates = true;
82
+ /** The props that this tile source was created with */
83
+ props: Required<DynamicVectorTileSourceProps['table']>;
84
+ schema: Schema | null;
85
+ /** Map of generated tiles, indexed by stringified tile coordinates */
86
+ tiles: Record<string, ProtoTile>;
87
+ /** Array of tile coordinates */
88
+ tileCoords: {
89
+ x: number;
90
+ y: number;
91
+ z: number;
92
+ }[];
93
+ /** Input data has loaded, initial top-level tiling is done, sync methods can now be called */
94
+ ready: Promise<void>;
95
+ /** Metadata for the tile source (generated TileJSON/tilestats */
96
+ metadata: Promise<unknown>;
97
+ constructor(table: GeoJSONTable | Promise<GeoJSONTable>, props?: DynamicVectorTileSourceProps);
98
+ initializeTilesAsync(tablePromise: GeoJSONTable | Promise<GeoJSONTable>): Promise<void>;
99
+ getMetadata(): Promise<TileSourceMetadata & {
100
+ schema: Schema | null;
101
+ }>;
102
+ getSchema(): Promise<Schema>;
103
+ /**
104
+ * Get a tile at the specified index
105
+ * @param tileIndex z, x, y of tile
106
+ * @returns
107
+ */
108
+ getVectorTile(tileIndex: GetTileParameters): Promise<GeoJSONTable | null>;
109
+ getTile(tileIndex: {
110
+ z: number;
111
+ x: number;
112
+ y: number;
113
+ }): Promise<GeoJSONTable | null>;
114
+ getTileData(tileParams: GetTileDataParameters): Promise<Feature[] | BinaryFeatureCollection>;
115
+ /**
116
+ * Synchronously request a tile
117
+ * @note Application must await `source.ready` before calling sync methods.
118
+ */
119
+ getTileSync(tileIndex: {
120
+ z: number;
121
+ x: number;
122
+ y: number;
123
+ }): GeoJSONTable | null;
124
+ /**
125
+ * Create the initial tiles
126
+ * @note the tiles stores all the features together with additional data
127
+ */
128
+ createRootTiles(table: GeoJSONTable): void;
129
+ /**
130
+ * Return geojsonvt-style "half formed" vector tile
131
+ * @note Application must await `source.ready` before calling sync methods.
132
+ */
133
+ getProtoTile(tileIndex: {
134
+ z: number;
135
+ x: number;
136
+ y: number;
137
+ }): ProtoTile | null;
138
+ /**
139
+ * splits features from a parent tile to sub-tiles.
140
+ * @param z, x, and y are the coordinates of the parent tile
141
+ * @param cz, cx, and cy are the coordinates of the target tile
142
+ *
143
+ * If no target tile is specified, splitting stops when we reach the maximum
144
+ * zoom or the number of points is low as specified in the props.
145
+ */
146
+ splitTile(features: ProtoFeature[], z: number, x: number, y: number, cz?: number, cx?: number, cy?: number): void;
147
+ }
148
+ //# sourceMappingURL=table-tile-source.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"table-tile-source.d.ts","sourceRoot":"","sources":["../src/table-tile-source.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EACV,qBAAqB,EACrB,qBAAqB,EACrB,iBAAiB,EACjB,gBAAgB,EACjB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAC,gBAAgB,EAAE,kBAAkB,EAAM,MAAM,0BAA0B,CAAC;AACnF,OAAO,EAAC,MAAM,EAAE,YAAY,EAAE,OAAO,EAAE,uBAAuB,EAAC,MAAM,oBAAoB,CAAC;AAE1F,OAAO,EAAC,KAAK,EAAO,MAAM,iBAAiB,CAAC;AAE5C,OAAO,KAAK,EAAC,YAAY,EAAC,qDAAkD;AAC5E,OAAO,KAAK,EAAC,SAAS,EAAC,yCAAsC;AAQ7D,kCAAkC;AAClC,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;4BAoBX,MAAM,KAAG,OAAO;qCAExB,MAAM,GAAG,IAAI,GAAG,YAAY,GAAG,QAAQ,YAAY,CAAC,WAChD,4BAA4B,KACpC,uBAAuB;CAOsD,CAAC;AAanF,kCAAkC;AAClC,MAAM,MAAM,4BAA4B,GAAG,qBAAqB,GAAG;IACjE,KAAK,EAAE;QACL,WAAW,EAAE,OAAO,GAAG,OAAO,GAAG,WAAW,CAAC;QAC7C,qCAAqC;QACrC,OAAO,CAAC,EAAE,MAAM,CAAC;QACjB,iCAAiC;QACjC,YAAY,CAAC,EAAE,MAAM,CAAC;QACtB,sDAAsD;QACtD,gBAAgB,CAAC,EAAE,MAAM,CAAC;QAC1B,sDAAsD;QACtD,SAAS,CAAC,EAAE,MAAM,CAAC;QACnB,kBAAkB;QAClB,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,+BAA+B;QAC/B,MAAM,CAAC,EAAE,MAAM,C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