@takram/three-geospatial 0.0.1-alpha.2 → 0.0.1-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.
package/build/index.js CHANGED
@@ -1,10 +1,10 @@
1
1
  var Tt = Object.defineProperty;
2
2
  var St = (e, t, n) => t in e ? Tt(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
3
  var c = (e, t, n) => St(e, typeof t != "symbol" ? t + "" : t, n);
4
- import { Loader as R, FileLoader as Pt, BufferAttribute as J, Box3 as Ot, Vector3 as f, Sphere as Mt, BufferGeometry as At, DataTexture as H, FloatType as I, Data3DTexture as zt, RGBAFormat as Et, ClampToEdgeWrapping as k, LinearFilter as tt, MathUtils as u, Matrix4 as It, Quaternion as Nt, Ray as Ct, Vector2 as ut } from "three";
4
+ import { Loader as R, FileLoader as Pt, BufferAttribute as J, Box3 as Ot, Vector3 as f, Sphere as Mt, BufferGeometry as At, DataTexture as H, FloatType as I, Data3DTexture as zt, RGBAFormat as Et, ClampToEdgeWrapping as k, LinearFilter as tt, MathUtils as u, Matrix4 as It, Quaternion as Ct, Ray as Lt, Vector2 as ut } from "three";
5
5
  import { E as et, G as m } from "./shared.js";
6
- import { a as xr } from "./shared.js";
7
- var Lt = `float reverseLogDepth(const float depth, const float near, const float far) {
6
+ import { a as wr } from "./shared.js";
7
+ var Nt = `float reverseLogDepth(const float depth, const float near, const float far) {
8
8
  #ifdef USE_LOGDEPTHBUF
9
9
  float d = pow(2.0, depth * log2(far + 1.0)) - 1.0;
10
10
  float a = far / (far - near);
@@ -55,7 +55,7 @@ function jt(e, t) {
55
55
  throw new Error(n);
56
56
  }
57
57
  }
58
- class Ut extends R {
58
+ class Gt extends R {
59
59
  load(t, n, r, i) {
60
60
  const a = new Pt(this.manager);
61
61
  a.setResponseType("arraybuffer"), a.setRequestHeader(this.requestHeader), a.setPath(this.path), a.setWithCredentials(this.withCredentials), a.load(
@@ -73,85 +73,76 @@ class Ut extends R {
73
73
  );
74
74
  }
75
75
  }
76
- function Zn(e) {
77
- }
78
- function Gt(e) {
79
- return e != null;
80
- }
81
- function Yn(e) {
82
- return e !== void 0;
76
+ function Xn(e) {
83
77
  }
84
- function Kn(e) {
85
- return e !== !1;
86
- }
87
- var Rt = typeof global == "object" && global && global.Object === Object && global, Ht = typeof self == "object" && self && self.Object === Object && self, B = Rt || Ht || Function("return this")(), p = B.Symbol, dt = Object.prototype, Bt = dt.hasOwnProperty, qt = dt.toString, x = p ? p.toStringTag : void 0;
88
- function Vt(e) {
89
- var t = Bt.call(e, x), n = e[x];
78
+ var Ut = typeof global == "object" && global && global.Object === Object && global, Rt = typeof self == "object" && self && self.Object === Object && self, B = Ut || Rt || Function("return this")(), p = B.Symbol, dt = Object.prototype, Ht = dt.hasOwnProperty, Bt = dt.toString, x = p ? p.toStringTag : void 0;
79
+ function qt(e) {
80
+ var t = Ht.call(e, x), n = e[x];
90
81
  try {
91
82
  e[x] = void 0;
92
83
  var r = !0;
93
84
  } catch {
94
85
  }
95
- var i = qt.call(e);
86
+ var i = Bt.call(e);
96
87
  return r && (t ? e[x] = n : delete e[x]), i;
97
88
  }
98
- var Wt = Object.prototype, Xt = Wt.toString;
99
- function Zt(e) {
100
- return Xt.call(e);
89
+ var Vt = Object.prototype, Wt = Vt.toString;
90
+ function Xt(e) {
91
+ return Wt.call(e);
101
92
  }
102
- var Yt = "[object Null]", Kt = "[object Undefined]", rt = p ? p.toStringTag : void 0;
93
+ var Zt = "[object Null]", Yt = "[object Undefined]", rt = p ? p.toStringTag : void 0;
103
94
  function q(e) {
104
- return e == null ? e === void 0 ? Kt : Yt : rt && rt in Object(e) ? Vt(e) : Zt(e);
95
+ return e == null ? e === void 0 ? Yt : Zt : rt && rt in Object(e) ? qt(e) : Xt(e);
105
96
  }
106
97
  function V(e) {
107
98
  return e != null && typeof e == "object";
108
99
  }
109
- var Qt = "[object Symbol]";
100
+ var Kt = "[object Symbol]";
110
101
  function W(e) {
111
- return typeof e == "symbol" || V(e) && q(e) == Qt;
102
+ return typeof e == "symbol" || V(e) && q(e) == Kt;
112
103
  }
113
- function Jt(e, t) {
104
+ function Qt(e, t) {
114
105
  for (var n = -1, r = e == null ? 0 : e.length, i = Array(r); ++n < r; )
115
106
  i[n] = t(e[n], n, e);
116
107
  return i;
117
108
  }
118
- var P = Array.isArray, kt = 1 / 0, it = p ? p.prototype : void 0, at = it ? it.toString : void 0;
109
+ var P = Array.isArray, Jt = 1 / 0, it = p ? p.prototype : void 0, at = it ? it.toString : void 0;
119
110
  function ft(e) {
120
111
  if (typeof e == "string")
121
112
  return e;
122
113
  if (P(e))
123
- return Jt(e, ft) + "";
114
+ return Qt(e, ft) + "";
124
115
  if (W(e))
125
116
  return at ? at.call(e) : "";
126
117
  var t = e + "";
127
- return t == "0" && 1 / e == -kt ? "-0" : t;
118
+ return t == "0" && 1 / e == -Jt ? "-0" : t;
128
119
  }
129
120
  function A(e) {
130
121
  var t = typeof e;
131
122
  return e != null && (t == "object" || t == "function");
132
123
  }
133
- function te(e) {
124
+ function kt(e) {
134
125
  return e;
135
126
  }
136
- var ee = "[object AsyncFunction]", ne = "[object Function]", re = "[object GeneratorFunction]", ie = "[object Proxy]";
137
- function ae(e) {
127
+ var te = "[object AsyncFunction]", ee = "[object Function]", ne = "[object GeneratorFunction]", re = "[object Proxy]";
128
+ function ie(e) {
138
129
  if (!A(e))
139
130
  return !1;
140
131
  var t = q(e);
141
- return t == ne || t == re || t == ee || t == ie;
132
+ return t == ee || t == ne || t == te || t == re;
142
133
  }
143
134
  var j = B["__core-js_shared__"], st = function() {
144
135
  var e = /[^.]+$/.exec(j && j.keys && j.keys.IE_PROTO || "");
145
136
  return e ? "Symbol(src)_1." + e : "";
146
137
  }();
147
- function se(e) {
138
+ function ae(e) {
148
139
  return !!st && st in e;
149
140
  }
150
- var oe = Function.prototype, ce = oe.toString;
151
- function he(e) {
141
+ var se = Function.prototype, oe = se.toString;
142
+ function ce(e) {
152
143
  if (e != null) {
153
144
  try {
154
- return ce.call(e);
145
+ return oe.call(e);
155
146
  } catch {
156
147
  }
157
148
  try {
@@ -161,23 +152,23 @@ function he(e) {
161
152
  }
162
153
  return "";
163
154
  }
164
- var le = /[\\^$.*+?()[\]{}|]/g, ue = /^\[object .+?Constructor\]$/, de = Function.prototype, fe = Object.prototype, pe = de.toString, ye = fe.hasOwnProperty, ge = RegExp(
165
- "^" + pe.call(ye).replace(le, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
155
+ var he = /[\\^$.*+?()[\]{}|]/g, le = /^\[object .+?Constructor\]$/, ue = Function.prototype, de = Object.prototype, fe = ue.toString, pe = de.hasOwnProperty, ye = RegExp(
156
+ "^" + fe.call(pe).replace(he, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
166
157
  );
167
- function we(e) {
168
- if (!A(e) || se(e))
158
+ function ge(e) {
159
+ if (!A(e) || ae(e))
169
160
  return !1;
170
- var t = ae(e) ? ge : ue;
171
- return t.test(he(e));
161
+ var t = ie(e) ? ye : le;
162
+ return t.test(ce(e));
172
163
  }
173
- function ve(e, t) {
164
+ function we(e, t) {
174
165
  return e == null ? void 0 : e[t];
175
166
  }
176
167
  function X(e, t) {
177
- var n = ve(e, t);
178
- return we(n) ? n : void 0;
168
+ var n = we(e, t);
169
+ return ge(n) ? n : void 0;
179
170
  }
180
- function me(e, t, n) {
171
+ function ve(e, t, n) {
181
172
  switch (n.length) {
182
173
  case 0:
183
174
  return e.call(t);
@@ -190,20 +181,20 @@ function me(e, t, n) {
190
181
  }
191
182
  return e.apply(t, n);
192
183
  }
193
- var xe = 800, _e = 16, be = Date.now;
194
- function Te(e) {
184
+ var me = 800, xe = 16, _e = Date.now;
185
+ function be(e) {
195
186
  var t = 0, n = 0;
196
187
  return function() {
197
- var r = be(), i = _e - (r - n);
188
+ var r = _e(), i = xe - (r - n);
198
189
  if (n = r, i > 0) {
199
- if (++t >= xe)
190
+ if (++t >= me)
200
191
  return arguments[0];
201
192
  } else
202
193
  t = 0;
203
194
  return e.apply(void 0, arguments);
204
195
  };
205
196
  }
206
- function Se(e) {
197
+ function Te(e) {
207
198
  return function() {
208
199
  return e;
209
200
  };
@@ -214,19 +205,19 @@ var z = function() {
214
205
  return e({}, "", {}), e;
215
206
  } catch {
216
207
  }
217
- }(), Pe = z ? function(e, t) {
208
+ }(), Se = z ? function(e, t) {
218
209
  return z(e, "toString", {
219
210
  configurable: !0,
220
211
  enumerable: !1,
221
- value: Se(t),
212
+ value: Te(t),
222
213
  writable: !0
223
214
  });
224
- } : te, Oe = Te(Pe), Me = 9007199254740991, Ae = /^(?:0|[1-9]\d*)$/;
215
+ } : kt, Pe = be(Se), Oe = 9007199254740991, Me = /^(?:0|[1-9]\d*)$/;
225
216
  function pt(e, t) {
226
217
  var n = typeof e;
227
- return t = t ?? Me, !!t && (n == "number" || n != "symbol" && Ae.test(e)) && e > -1 && e % 1 == 0 && e < t;
218
+ return t = t ?? Oe, !!t && (n == "number" || n != "symbol" && Me.test(e)) && e > -1 && e % 1 == 0 && e < t;
228
219
  }
229
- function ze(e, t, n) {
220
+ function Ae(e, t, n) {
230
221
  t == "__proto__" && z ? z(e, t, {
231
222
  configurable: !0,
232
223
  enumerable: !0,
@@ -237,10 +228,10 @@ function ze(e, t, n) {
237
228
  function yt(e, t) {
238
229
  return e === t || e !== e && t !== t;
239
230
  }
240
- var Ee = Object.prototype, Ie = Ee.hasOwnProperty;
241
- function Ne(e, t, n) {
231
+ var ze = Object.prototype, Ee = ze.hasOwnProperty;
232
+ function Ie(e, t, n) {
242
233
  var r = e[t];
243
- (!(Ie.call(e, t) && yt(r, n)) || n === void 0 && !(t in e)) && ze(e, t, n);
234
+ (!(Ee.call(e, t) && yt(r, n)) || n === void 0 && !(t in e)) && Ae(e, t, n);
244
235
  }
245
236
  var ot = Math.max;
246
237
  function Ce(e, t, n) {
@@ -250,54 +241,54 @@ function Ce(e, t, n) {
250
241
  i = -1;
251
242
  for (var o = Array(t + 1); ++i < t; )
252
243
  o[i] = r[i];
253
- return o[t] = n(s), me(e, this, o);
244
+ return o[t] = n(s), ve(e, this, o);
254
245
  };
255
246
  }
256
247
  var Le = 9007199254740991;
257
- function De(e) {
248
+ function Ne(e) {
258
249
  return typeof e == "number" && e > -1 && e % 1 == 0 && e <= Le;
259
250
  }
260
- var Fe = "[object Arguments]";
251
+ var De = "[object Arguments]";
261
252
  function ct(e) {
262
- return V(e) && q(e) == Fe;
253
+ return V(e) && q(e) == De;
263
254
  }
264
- var gt = Object.prototype, $e = gt.hasOwnProperty, je = gt.propertyIsEnumerable, wt = ct(/* @__PURE__ */ function() {
255
+ var gt = Object.prototype, Fe = gt.hasOwnProperty, $e = gt.propertyIsEnumerable, wt = ct(/* @__PURE__ */ function() {
265
256
  return arguments;
266
257
  }()) ? ct : function(e) {
267
- return V(e) && $e.call(e, "callee") && !je.call(e, "callee");
268
- }, Ue = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, Ge = /^\w*$/;
269
- function Re(e, t) {
258
+ return V(e) && Fe.call(e, "callee") && !$e.call(e, "callee");
259
+ }, je = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, Ge = /^\w*$/;
260
+ function Ue(e, t) {
270
261
  if (P(e))
271
262
  return !1;
272
263
  var n = typeof e;
273
- return n == "number" || n == "symbol" || n == "boolean" || e == null || W(e) ? !0 : Ge.test(e) || !Ue.test(e) || t != null && e in Object(t);
264
+ return n == "number" || n == "symbol" || n == "boolean" || e == null || W(e) ? !0 : Ge.test(e) || !je.test(e) || t != null && e in Object(t);
274
265
  }
275
266
  var T = X(Object, "create");
276
- function He() {
267
+ function Re() {
277
268
  this.__data__ = T ? T(null) : {}, this.size = 0;
278
269
  }
279
- function Be(e) {
270
+ function He(e) {
280
271
  var t = this.has(e) && delete this.__data__[e];
281
272
  return this.size -= t ? 1 : 0, t;
282
273
  }
283
- var qe = "__lodash_hash_undefined__", Ve = Object.prototype, We = Ve.hasOwnProperty;
284
- function Xe(e) {
274
+ var Be = "__lodash_hash_undefined__", qe = Object.prototype, Ve = qe.hasOwnProperty;
275
+ function We(e) {
285
276
  var t = this.__data__;
286
277
  if (T) {
287
278
  var n = t[e];
288
- return n === qe ? void 0 : n;
279
+ return n === Be ? void 0 : n;
289
280
  }
290
- return We.call(t, e) ? t[e] : void 0;
281
+ return Ve.call(t, e) ? t[e] : void 0;
291
282
  }
292
- var Ze = Object.prototype, Ye = Ze.hasOwnProperty;
293
- function Ke(e) {
283
+ var Xe = Object.prototype, Ze = Xe.hasOwnProperty;
284
+ function Ye(e) {
294
285
  var t = this.__data__;
295
- return T ? t[e] !== void 0 : Ye.call(t, e);
286
+ return T ? t[e] !== void 0 : Ze.call(t, e);
296
287
  }
297
- var Qe = "__lodash_hash_undefined__";
298
- function Je(e, t) {
288
+ var Ke = "__lodash_hash_undefined__";
289
+ function Qe(e, t) {
299
290
  var n = this.__data__;
300
- return this.size += this.has(e) ? 0 : 1, n[e] = T && t === void 0 ? Qe : t, this;
291
+ return this.size += this.has(e) ? 0 : 1, n[e] = T && t === void 0 ? Ke : t, this;
301
292
  }
302
293
  function g(e) {
303
294
  var t = -1, n = e == null ? 0 : e.length;
@@ -306,37 +297,37 @@ function g(e) {
306
297
  this.set(r[0], r[1]);
307
298
  }
308
299
  }
309
- g.prototype.clear = He;
310
- g.prototype.delete = Be;
311
- g.prototype.get = Xe;
312
- g.prototype.has = Ke;
313
- g.prototype.set = Je;
314
- function ke() {
300
+ g.prototype.clear = Re;
301
+ g.prototype.delete = He;
302
+ g.prototype.get = We;
303
+ g.prototype.has = Ye;
304
+ g.prototype.set = Qe;
305
+ function Je() {
315
306
  this.__data__ = [], this.size = 0;
316
307
  }
317
- function N(e, t) {
308
+ function C(e, t) {
318
309
  for (var n = e.length; n--; )
319
310
  if (yt(e[n][0], t))
320
311
  return n;
321
312
  return -1;
322
313
  }
323
- var tn = Array.prototype, en = tn.splice;
324
- function nn(e) {
325
- var t = this.__data__, n = N(t, e);
314
+ var ke = Array.prototype, tn = ke.splice;
315
+ function en(e) {
316
+ var t = this.__data__, n = C(t, e);
326
317
  if (n < 0)
327
318
  return !1;
328
319
  var r = t.length - 1;
329
- return n == r ? t.pop() : en.call(t, n, 1), --this.size, !0;
320
+ return n == r ? t.pop() : tn.call(t, n, 1), --this.size, !0;
330
321
  }
331
- function rn(e) {
332
- var t = this.__data__, n = N(t, e);
322
+ function nn(e) {
323
+ var t = this.__data__, n = C(t, e);
333
324
  return n < 0 ? void 0 : t[n][1];
334
325
  }
335
- function an(e) {
336
- return N(this.__data__, e) > -1;
326
+ function rn(e) {
327
+ return C(this.__data__, e) > -1;
337
328
  }
338
- function sn(e, t) {
339
- var n = this.__data__, r = N(n, e);
329
+ function an(e, t) {
330
+ var n = this.__data__, r = C(n, e);
340
331
  return r < 0 ? (++this.size, n.push([e, t])) : n[r][1] = t, this;
341
332
  }
342
333
  function v(e) {
@@ -346,39 +337,39 @@ function v(e) {
346
337
  this.set(r[0], r[1]);
347
338
  }
348
339
  }
349
- v.prototype.clear = ke;
350
- v.prototype.delete = nn;
351
- v.prototype.get = rn;
352
- v.prototype.has = an;
353
- v.prototype.set = sn;
354
- var on = X(B, "Map");
355
- function cn() {
340
+ v.prototype.clear = Je;
341
+ v.prototype.delete = en;
342
+ v.prototype.get = nn;
343
+ v.prototype.has = rn;
344
+ v.prototype.set = an;
345
+ var sn = X(B, "Map");
346
+ function on() {
356
347
  this.size = 0, this.__data__ = {
357
348
  hash: new g(),
358
- map: new (on || v)(),
349
+ map: new (sn || v)(),
359
350
  string: new g()
360
351
  };
361
352
  }
362
- function hn(e) {
353
+ function cn(e) {
363
354
  var t = typeof e;
364
355
  return t == "string" || t == "number" || t == "symbol" || t == "boolean" ? e !== "__proto__" : e === null;
365
356
  }
366
- function C(e, t) {
357
+ function L(e, t) {
367
358
  var n = e.__data__;
368
- return hn(t) ? n[typeof t == "string" ? "string" : "hash"] : n.map;
359
+ return cn(t) ? n[typeof t == "string" ? "string" : "hash"] : n.map;
369
360
  }
370
- function ln(e) {
371
- var t = C(this, e).delete(e);
361
+ function hn(e) {
362
+ var t = L(this, e).delete(e);
372
363
  return this.size -= t ? 1 : 0, t;
373
364
  }
374
- function un(e) {
375
- return C(this, e).get(e);
365
+ function ln(e) {
366
+ return L(this, e).get(e);
376
367
  }
377
- function dn(e) {
378
- return C(this, e).has(e);
368
+ function un(e) {
369
+ return L(this, e).has(e);
379
370
  }
380
- function fn(e, t) {
381
- var n = C(this, e), r = n.size;
371
+ function dn(e, t) {
372
+ var n = L(this, e), r = n.size;
382
373
  return n.set(e, t), this.size += n.size == r ? 0 : 1, this;
383
374
  }
384
375
  function w(e) {
@@ -388,15 +379,15 @@ function w(e) {
388
379
  this.set(r[0], r[1]);
389
380
  }
390
381
  }
391
- w.prototype.clear = cn;
392
- w.prototype.delete = ln;
393
- w.prototype.get = un;
394
- w.prototype.has = dn;
395
- w.prototype.set = fn;
396
- var pn = "Expected a function";
382
+ w.prototype.clear = on;
383
+ w.prototype.delete = hn;
384
+ w.prototype.get = ln;
385
+ w.prototype.has = un;
386
+ w.prototype.set = dn;
387
+ var fn = "Expected a function";
397
388
  function Z(e, t) {
398
389
  if (typeof e != "function" || t != null && typeof t != "function")
399
- throw new TypeError(pn);
390
+ throw new TypeError(fn);
400
391
  var n = function() {
401
392
  var r = arguments, i = t ? t.apply(this, r) : r[0], a = n.cache;
402
393
  if (a.has(i))
@@ -407,82 +398,82 @@ function Z(e, t) {
407
398
  return n.cache = new (Z.Cache || w)(), n;
408
399
  }
409
400
  Z.Cache = w;
410
- var yn = 500;
411
- function gn(e) {
401
+ var pn = 500;
402
+ function yn(e) {
412
403
  var t = Z(e, function(r) {
413
- return n.size === yn && n.clear(), r;
404
+ return n.size === pn && n.clear(), r;
414
405
  }), n = t.cache;
415
406
  return t;
416
407
  }
417
- var wn = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g, vn = /\\(\\)?/g, mn = gn(function(e) {
408
+ var gn = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g, wn = /\\(\\)?/g, vn = yn(function(e) {
418
409
  var t = [];
419
- return e.charCodeAt(0) === 46 && t.push(""), e.replace(wn, function(n, r, i, a) {
420
- t.push(i ? a.replace(vn, "$1") : r || n);
410
+ return e.charCodeAt(0) === 46 && t.push(""), e.replace(gn, function(n, r, i, a) {
411
+ t.push(i ? a.replace(wn, "$1") : r || n);
421
412
  }), t;
422
413
  });
423
- function xn(e) {
414
+ function mn(e) {
424
415
  return e == null ? "" : ft(e);
425
416
  }
426
- function L(e, t) {
427
- return P(e) ? e : Re(e, t) ? [e] : mn(xn(e));
417
+ function N(e, t) {
418
+ return P(e) ? e : Ue(e, t) ? [e] : vn(mn(e));
428
419
  }
429
- var _n = 1 / 0;
420
+ var xn = 1 / 0;
430
421
  function Y(e) {
431
422
  if (typeof e == "string" || W(e))
432
423
  return e;
433
424
  var t = e + "";
434
- return t == "0" && 1 / e == -_n ? "-0" : t;
425
+ return t == "0" && 1 / e == -xn ? "-0" : t;
435
426
  }
436
- function bn(e, t) {
437
- t = L(t, e);
427
+ function _n(e, t) {
428
+ t = N(t, e);
438
429
  for (var n = 0, r = t.length; e != null && n < r; )
439
430
  e = e[Y(t[n++])];
440
431
  return n && n == r ? e : void 0;
441
432
  }
442
- function Tn(e, t) {
433
+ function bn(e, t) {
443
434
  for (var n = -1, r = t.length, i = e.length; ++n < r; )
444
435
  e[i + n] = t[n];
445
436
  return e;
446
437
  }
447
438
  var ht = p ? p.isConcatSpreadable : void 0;
448
- function Sn(e) {
439
+ function Tn(e) {
449
440
  return P(e) || wt(e) || !!(ht && e && e[ht]);
450
441
  }
451
- function Pn(e, t, n, r, i) {
442
+ function Sn(e, t, n, r, i) {
452
443
  var a = -1, s = e.length;
453
- for (n || (n = Sn), i || (i = []); ++a < s; ) {
444
+ for (n || (n = Tn), i || (i = []); ++a < s; ) {
454
445
  var o = e[a];
455
- n(o) ? Tn(i, o) : i[i.length] = o;
446
+ n(o) ? bn(i, o) : i[i.length] = o;
456
447
  }
457
448
  return i;
458
449
  }
459
- function On(e) {
450
+ function Pn(e) {
460
451
  var t = e == null ? 0 : e.length;
461
- return t ? Pn(e) : [];
452
+ return t ? Sn(e) : [];
462
453
  }
463
- function Mn(e) {
464
- return Oe(Ce(e, void 0, On), e + "");
454
+ function On(e) {
455
+ return Pe(Ce(e, void 0, Pn), e + "");
465
456
  }
466
- function An(e, t) {
457
+ function Mn(e, t) {
467
458
  return e != null && t in Object(e);
468
459
  }
469
- function zn(e, t, n) {
470
- t = L(t, e);
460
+ function An(e, t, n) {
461
+ t = N(t, e);
471
462
  for (var r = -1, i = t.length, a = !1; ++r < i; ) {
472
463
  var s = Y(t[r]);
473
464
  if (!(a = e != null && n(e, s)))
474
465
  break;
475
466
  e = e[s];
476
467
  }
477
- return a || ++r != i ? a : (i = e == null ? 0 : e.length, !!i && De(i) && pt(s, i) && (P(e) || wt(e)));
468
+ return a || ++r != i ? a : (i = e == null ? 0 : e.length, !!i && Ne(i) && pt(s, i) && (P(e) || wt(e)));
478
469
  }
479
- function En(e, t) {
480
- return e != null && zn(e, t, An);
470
+ function zn(e, t) {
471
+ return e != null && An(e, t, Mn);
481
472
  }
482
- function In(e, t, n, r) {
473
+ function En(e, t, n, r) {
483
474
  if (!A(e))
484
475
  return e;
485
- t = L(t, e);
476
+ t = N(t, e);
486
477
  for (var i = -1, a = t.length, s = a - 1, o = e; o != null && ++i < a; ) {
487
478
  var h = Y(t[i]), l = n;
488
479
  if (h === "__proto__" || h === "constructor" || h === "prototype")
@@ -491,26 +482,26 @@ function In(e, t, n, r) {
491
482
  var y = o[h];
492
483
  l = void 0, l === void 0 && (l = A(y) ? y : pt(t[i + 1]) ? [] : {});
493
484
  }
494
- Ne(o, h, l), o = o[h];
485
+ Ie(o, h, l), o = o[h];
495
486
  }
496
487
  return e;
497
488
  }
498
- function Nn(e, t, n) {
489
+ function In(e, t, n) {
499
490
  for (var r = -1, i = t.length, a = {}; ++r < i; ) {
500
- var s = t[r], o = bn(e, s);
501
- n(o, s) && In(a, L(s, e), o);
491
+ var s = t[r], o = _n(e, s);
492
+ n(o, s) && En(a, N(s, e), o);
502
493
  }
503
494
  return a;
504
495
  }
505
496
  function Cn(e, t) {
506
- return Nn(e, t, function(n, r) {
507
- return En(e, r);
497
+ return In(e, t, function(n, r) {
498
+ return zn(e, r);
508
499
  });
509
500
  }
510
- var Ln = Mn(function(e, t) {
501
+ var Ln = On(function(e, t) {
511
502
  return e == null ? {} : Cn(e, t);
512
503
  });
513
- function Qn(e) {
504
+ function Zn(e) {
514
505
  var t;
515
506
  return [
516
507
  Ln(e, ["attributes", "index", "boundingBox", "boundingSphere"]),
@@ -519,10 +510,10 @@ function Qn(e) {
519
510
  (n) => n.array.buffer
520
511
  ),
521
512
  (t = e.index) == null ? void 0 : t.array.buffer
522
- ].filter(Gt)
513
+ ].filter((n) => n != null)
523
514
  ];
524
515
  }
525
- function Jn(e, t = new At()) {
516
+ function Yn(e, t = new At()) {
526
517
  for (const [n, r] of Object.entries(e.attributes))
527
518
  t.setAttribute(
528
519
  n,
@@ -558,18 +549,18 @@ function K(e, t, n, r = !0) {
558
549
  a[s] = i[n](o, r);
559
550
  return a;
560
551
  }
561
- function Dn(e, t) {
552
+ function Nn(e, t) {
562
553
  return K(e, Int16Array, "getInt16", t);
563
554
  }
564
- function Fn(e, t) {
555
+ function Dn(e, t) {
565
556
  return K(e, Uint16Array, "getUint16", t);
566
557
  }
567
- function $n(e, t) {
558
+ function Fn(e, t) {
568
559
  return K(e, Float32Array, "getFloat32", t);
569
560
  }
570
561
  class Q extends R {
571
562
  load(t, n, r, i) {
572
- const a = new Ut(this.manager);
563
+ const a = new Gt(this.manager);
573
564
  a.setRequestHeader(this.requestHeader), a.setPath(this.path), a.setWithCredentials(this.withCredentials), a.load(
574
565
  t,
575
566
  (s) => {
@@ -584,22 +575,22 @@ class Q extends R {
584
575
  );
585
576
  }
586
577
  }
587
- class jn extends Q {
578
+ class $n extends Q {
588
579
  constructor() {
589
580
  super(...arguments);
590
- c(this, "parseTypedArray", Dn);
581
+ c(this, "parseTypedArray", Nn);
591
582
  }
592
583
  }
593
- class Un extends Q {
584
+ class jn extends Q {
594
585
  constructor() {
595
586
  super(...arguments);
596
- c(this, "parseTypedArray", Fn);
587
+ c(this, "parseTypedArray", Dn);
597
588
  }
598
589
  }
599
590
  class vt extends Q {
600
591
  constructor() {
601
592
  super(...arguments);
602
- c(this, "parseTypedArray", $n);
593
+ c(this, "parseTypedArray", Fn);
603
594
  }
604
595
  }
605
596
  const D = {
@@ -626,29 +617,29 @@ class F extends R {
626
617
  );
627
618
  }
628
619
  }
629
- class kn extends F {
620
+ class Kn extends F {
630
621
  constructor() {
631
622
  super(...arguments);
632
623
  c(this, "Texture", H);
633
- c(this, "TypedArrayLoader", jn);
624
+ c(this, "TypedArrayLoader", $n);
634
625
  c(this, "parameters", {
635
626
  ...D,
636
627
  type: I
637
628
  });
638
629
  }
639
630
  }
640
- class tr extends F {
631
+ class Qn extends F {
641
632
  constructor() {
642
633
  super(...arguments);
643
634
  c(this, "Texture", H);
644
- c(this, "TypedArrayLoader", Un);
635
+ c(this, "TypedArrayLoader", jn);
645
636
  c(this, "parameters", {
646
637
  ...D,
647
638
  type: I
648
639
  });
649
640
  }
650
641
  }
651
- class er extends F {
642
+ class Jn extends F {
652
643
  constructor() {
653
644
  super(...arguments);
654
645
  c(this, "Texture", H);
@@ -659,7 +650,7 @@ class er extends F {
659
650
  });
660
651
  }
661
652
  }
662
- class nr extends F {
653
+ class kn extends F {
663
654
  constructor() {
664
655
  super(...arguments);
665
656
  c(this, "Texture", zt);
@@ -670,18 +661,18 @@ class nr extends F {
670
661
  });
671
662
  }
672
663
  }
673
- const Gn = u.clamp, rr = u.euclideanModulo, ir = u.inverseLerp, ar = u.lerp, sr = u.degToRad, or = u.radToDeg, cr = u.isPowerOfTwo, hr = u.ceilPowerOfTwo, lr = u.floorPowerOfTwo, ur = u.normalize;
674
- function dr(e, t, n) {
664
+ const Gn = u.clamp, tr = u.euclideanModulo, er = u.inverseLerp, nr = u.lerp, rr = u.degToRad, ir = u.radToDeg, ar = u.isPowerOfTwo, sr = u.ceilPowerOfTwo, or = u.floorPowerOfTwo, cr = u.normalize;
665
+ function hr(e, t, n) {
675
666
  return n <= e ? 0 : n >= t ? 1 : (n = (n - e) / (t - e), n * n * (3 - 2 * n));
676
667
  }
677
- function fr(e) {
668
+ function lr(e) {
678
669
  return Math.min(Math.max(e, 0), 1);
679
670
  }
680
- function pr(e, t, n, r = n) {
671
+ function ur(e, t, n, r = n) {
681
672
  const i = Math.abs(e - t);
682
673
  return i <= r || i <= n * Math.max(Math.abs(e), Math.abs(t));
683
674
  }
684
- const U = 1e-6, O = /* @__PURE__ */ new f(), M = /* @__PURE__ */ new f(), d = /* @__PURE__ */ new f(), _ = /* @__PURE__ */ new f(), G = /* @__PURE__ */ new f(), Rn = /* @__PURE__ */ new f(), Hn = /* @__PURE__ */ new It(), Bn = /* @__PURE__ */ new Nt(), qn = /* @__PURE__ */ new Ct();
675
+ const G = 1e-6, O = /* @__PURE__ */ new f(), M = /* @__PURE__ */ new f(), d = /* @__PURE__ */ new f(), _ = /* @__PURE__ */ new f(), U = /* @__PURE__ */ new f(), Un = /* @__PURE__ */ new f(), Rn = /* @__PURE__ */ new It(), Hn = /* @__PURE__ */ new Ct(), Bn = /* @__PURE__ */ new Lt();
685
676
  class mt {
686
677
  constructor(t = 0, n = 0, r = 0, i = 0) {
687
678
  // Distance from the target.
@@ -699,13 +690,13 @@ class mt {
699
690
  return this._distance;
700
691
  }
701
692
  set distance(t) {
702
- this._distance = Math.max(t, U);
693
+ this._distance = Math.max(t, G);
703
694
  }
704
695
  get pitch() {
705
696
  return this._pitch;
706
697
  }
707
698
  set pitch(t) {
708
- this._pitch = Gn(t, -Math.PI / 2 + U, Math.PI / 2 - U);
699
+ this._pitch = Gn(t, -Math.PI / 2 + G, Math.PI / 2 - G);
709
700
  }
710
701
  set(t, n, r, i) {
711
702
  return this.distance = t, this.heading = n, this.pitch = r, i != null && (this.roll = i), this;
@@ -727,20 +718,20 @@ class mt {
727
718
  d
728
719
  ), i == null || i.copy(d);
729
720
  const s = _.copy(O).multiplyScalar(Math.cos(this.heading)).add(
730
- G.copy(M).multiplyScalar(Math.sin(this.heading))
731
- ).multiplyScalar(Math.cos(this.pitch)).add(G.copy(d).multiplyScalar(Math.sin(this.pitch))).normalize().multiplyScalar(this.distance);
721
+ U.copy(M).multiplyScalar(Math.sin(this.heading))
722
+ ).multiplyScalar(Math.cos(this.pitch)).add(U.copy(d).multiplyScalar(Math.sin(this.pitch))).normalize().multiplyScalar(this.distance);
732
723
  if (n.copy(t).sub(s), this.roll !== 0) {
733
724
  const o = _.copy(t).sub(n).normalize();
734
725
  d.applyQuaternion(
735
- Bn.setFromAxisAngle(o, this.roll)
726
+ Hn.setFromAxisAngle(o, this.roll)
736
727
  );
737
728
  }
738
729
  r.setFromRotationMatrix(
739
- Hn.lookAt(n, t, d)
730
+ Rn.lookAt(n, t, d)
740
731
  );
741
732
  }
742
733
  setFromCamera(t, n = et.WGS84) {
743
- const r = _.setFromMatrixPosition(t.matrixWorld), i = G.set(0, 0, 0.5).unproject(t).sub(r).normalize(), a = n.getIntersection(qn.set(r, i));
734
+ const r = _.setFromMatrixPosition(t.matrixWorld), i = U.set(0, 0, 0.5).unproject(t).sub(r).normalize(), a = n.getIntersection(Bn.set(r, i));
744
735
  if (a == null)
745
736
  return;
746
737
  this.distance = r.distanceTo(a), n.getEastNorthUpVectors(
@@ -752,7 +743,7 @@ class mt {
752
743
  M.dot(i),
753
744
  O.dot(i)
754
745
  ), this.pitch = Math.asin(d.dot(i));
755
- const s = _.copy(t.up).applyQuaternion(t.quaternion), o = Rn.copy(i).multiplyScalar(-s.dot(i)).add(s).normalize(), h = _.copy(i).multiplyScalar(-d.dot(i)).add(d).normalize(), l = h.dot(o), y = i.dot(h.cross(o));
746
+ const s = _.copy(t.up).applyQuaternion(t.quaternion), o = Un.copy(i).multiplyScalar(-s.dot(i)).add(s).normalize(), h = _.copy(i).multiplyScalar(-d.dot(i)).add(d).normalize(), l = h.dot(o), y = i.dot(h.cross(o));
756
747
  return this.roll = Math.atan2(y, l), this;
757
748
  }
758
749
  }
@@ -884,50 +875,47 @@ class _t {
884
875
  return n.west = t.x * i + this.rectangle.west, n.east = (t.x + 1) * i + this.rectangle.west, n.north = this.rectangle.north - (r.y - t.y - 1) * a, n.south = this.rectangle.north - (r.y - t.y) * a, n;
885
876
  }
886
877
  }
887
- const yr = Lt, gr = Dt, wr = Ft;
878
+ const dr = Nt, fr = Dt, pr = Ft;
888
879
  export {
889
- Ut as ArrayBufferLoader,
880
+ Gt as ArrayBufferLoader,
890
881
  F as DataLoader,
891
882
  et as Ellipsoid,
892
- xr as EllipsoidGeometry,
883
+ wr as EllipsoidGeometry,
893
884
  vt as Float32ArrayLoader,
894
- er as Float32Data2DLoader,
895
- nr as Float32Data3DLoader,
885
+ Jn as Float32Data2DLoader,
886
+ kn as Float32Data3DLoader,
896
887
  m as Geodetic,
897
- jn as Int16ArrayLoader,
898
- kn as Int16Data2DLoader,
888
+ $n as Int16ArrayLoader,
889
+ Kn as Int16Data2DLoader,
899
890
  mt as PointOfView,
900
891
  E as Rectangle,
901
892
  S as TileCoordinate,
902
893
  _t as TilingScheme,
903
894
  Q as TypedArrayLoader,
904
- Un as Uint16ArrayLoader,
905
- tr as Uint16Data2DLoader,
906
- Zn as assertType,
907
- hr as ceilPowerOfTwo,
895
+ jn as Uint16ArrayLoader,
896
+ Qn as Uint16Data2DLoader,
897
+ Xn as assertType,
898
+ sr as ceilPowerOfTwo,
908
899
  Gn as clamp,
909
- pr as closeTo,
910
- or as degrees,
911
- yr as depthShader,
912
- rr as euclideanModulo,
913
- lr as floorPowerOfTwo,
914
- Jn as fromBufferGeometryLike,
915
- ir as inverseLerp,
916
- Kn as isNotFalse,
917
- Gt as isNotNullish,
918
- Yn as isNotUndefined,
919
- cr as isPowerOfTwo,
920
- ar as lerp,
921
- ur as normalize,
922
- gr as packingShader,
923
- $n as parseFloat32Array,
924
- Dn as parseInt16Array,
900
+ ur as closeTo,
901
+ ir as degrees,
902
+ dr as depthShader,
903
+ tr as euclideanModulo,
904
+ or as floorPowerOfTwo,
905
+ Yn as fromBufferGeometryLike,
906
+ er as inverseLerp,
907
+ ar as isPowerOfTwo,
908
+ nr as lerp,
909
+ cr as normalize,
910
+ fr as packingShader,
911
+ Fn as parseFloat32Array,
912
+ Nn as parseInt16Array,
925
913
  K as parseTypedArray,
926
- Fn as parseUint16Array,
927
- sr as radians,
928
- fr as saturate,
929
- dr as smoothstep,
930
- Qn as toBufferGeometryLike,
931
- wr as transformShader
914
+ Dn as parseUint16Array,
915
+ rr as radians,
916
+ lr as saturate,
917
+ hr as smoothstep,
918
+ Zn as toBufferGeometryLike,
919
+ pr as transformShader
932
920
  };
933
921
  //# sourceMappingURL=index.js.map