x_ite 16.1.0 → 16.1.2

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 (56) hide show
  1. package/README.md +5 -5
  2. package/dist/assets/components/AnnotationComponent.js +1 -1
  3. package/dist/assets/components/AnnotationComponent.min.js +1 -1
  4. package/dist/assets/components/CADGeometryComponent.js +1 -1
  5. package/dist/assets/components/CADGeometryComponent.min.js +1 -1
  6. package/dist/assets/components/CubeMapTexturingComponent.js +1 -1
  7. package/dist/assets/components/CubeMapTexturingComponent.min.js +1 -1
  8. package/dist/assets/components/DISComponent.js +1 -1
  9. package/dist/assets/components/DISComponent.min.js +1 -1
  10. package/dist/assets/components/EventUtilitiesComponent.js +1 -1
  11. package/dist/assets/components/EventUtilitiesComponent.min.js +1 -1
  12. package/dist/assets/components/GaussianSplatsComponent.js +1 -1
  13. package/dist/assets/components/GaussianSplatsComponent.min.js +1 -1
  14. package/dist/assets/components/Geometry2DComponent.js +1 -1
  15. package/dist/assets/components/Geometry2DComponent.min.js +1 -1
  16. package/dist/assets/components/Geometry3DComponent.js +1 -1
  17. package/dist/assets/components/Geometry3DComponent.min.js +1 -1
  18. package/dist/assets/components/GeospatialComponent.js +6 -13
  19. package/dist/assets/components/GeospatialComponent.min.js +2 -2
  20. package/dist/assets/components/HAnimComponent.js +1 -1
  21. package/dist/assets/components/HAnimComponent.min.js +1 -1
  22. package/dist/assets/components/KeyDeviceSensorComponent.js +1 -1
  23. package/dist/assets/components/KeyDeviceSensorComponent.min.js +1 -1
  24. package/dist/assets/components/LayoutComponent.js +1 -1
  25. package/dist/assets/components/LayoutComponent.min.js +1 -1
  26. package/dist/assets/components/NURBSComponent.js +1 -1
  27. package/dist/assets/components/NURBSComponent.min.js +1 -1
  28. package/dist/assets/components/ParticleSystemsComponent.js +1 -1
  29. package/dist/assets/components/ParticleSystemsComponent.min.js +1 -1
  30. package/dist/assets/components/PickingComponent.js +1 -1
  31. package/dist/assets/components/PickingComponent.min.js +1 -1
  32. package/dist/assets/components/RigidBodyPhysicsComponent.js +1 -1
  33. package/dist/assets/components/RigidBodyPhysicsComponent.min.js +1 -1
  34. package/dist/assets/components/ScriptingComponent.js +1 -1
  35. package/dist/assets/components/ScriptingComponent.min.js +1 -1
  36. package/dist/assets/components/TextComponent.js +1 -1
  37. package/dist/assets/components/TextComponent.min.js +1 -1
  38. package/dist/assets/components/TextureProjectionComponent.js +1 -1
  39. package/dist/assets/components/TextureProjectionComponent.min.js +1 -1
  40. package/dist/assets/components/Texturing3DComponent.js +9 -9
  41. package/dist/assets/components/Texturing3DComponent.min.js +2 -2
  42. package/dist/assets/components/VolumeRenderingComponent.js +1 -1
  43. package/dist/assets/components/VolumeRenderingComponent.min.js +1 -1
  44. package/dist/assets/components/WebXRComponent.js +1 -1
  45. package/dist/assets/components/WebXRComponent.min.js +1 -1
  46. package/dist/assets/components/X_ITEComponent.js +1 -1
  47. package/dist/assets/components/X_ITEComponent.min.js +1 -1
  48. package/dist/example.html +1 -1
  49. package/dist/x_ite.css +1 -1
  50. package/dist/x_ite.d.ts +195 -40
  51. package/dist/x_ite.js +284 -296
  52. package/dist/x_ite.min.js +2 -2
  53. package/dist/x_ite.min.mjs +2 -2
  54. package/dist/x_ite.mjs +284 -296
  55. package/dist/x_ite.zip +0 -0
  56. package/package.json +3 -3
package/dist/x_ite.js CHANGED
@@ -1,4 +1,4 @@
1
- /* X_ITE v16.1.0 */
1
+ /* X_ITE v16.1.2 */
2
2
  (function webpackUniversalModuleDefinition(root, factory) {
3
3
  if(typeof exports === 'object' && typeof module === 'object')
4
4
  module.exports = factory();
@@ -12,7 +12,7 @@
12
12
  return /******/ (() => { // webpackBootstrap
13
13
  /******/ var __webpack_modules__ = ({
14
14
 
15
- /***/ 548
15
+ /***/ 603
16
16
  (module, exports) {
17
17
 
18
18
  var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*
@@ -1017,7 +1017,7 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
1017
1017
 
1018
1018
  /***/ },
1019
1019
 
1020
- /***/ 174
1020
+ /***/ 777
1021
1021
  (module) {
1022
1022
 
1023
1023
  (function webpackUniversalModuleDefinition(root, factory) {
@@ -2013,7 +2013,7 @@ return /******/ (function(modules) { // webpackBootstrap
2013
2013
 
2014
2014
  /***/ },
2015
2015
 
2016
- /***/ 246
2016
+ /***/ 457
2017
2017
  (module) {
2018
2018
 
2019
2019
  /**
@@ -8932,7 +8932,7 @@ const handler =
8932
8932
  },
8933
8933
  ownKeys (target)
8934
8934
  {
8935
- return Object .keys (target [_array]) .concat (Object .keys (target));
8935
+ return Object .keys (target [_array]) .concat (Reflect .ownKeys (target));
8936
8936
  },
8937
8937
  getOwnPropertyDescriptor (target, key)
8938
8938
  {
@@ -8944,7 +8944,7 @@ const handler =
8944
8944
  {
8945
8945
  if (index < target [_array] .length)
8946
8946
  {
8947
- const propertyDescriptor = Object .getOwnPropertyDescriptor (target [_array], key);
8947
+ const propertyDescriptor = Reflect .getOwnPropertyDescriptor (target [_array], key);
8948
8948
 
8949
8949
  if (propertyDescriptor)
8950
8950
  propertyDescriptor .writable = false;
@@ -8958,12 +8958,20 @@ const handler =
8958
8958
  },
8959
8959
  };
8960
8960
 
8961
+ const properties = {
8962
+ length: {
8963
+ get () { return this [_array] .length; },
8964
+ },
8965
+ };
8966
+
8961
8967
  function X3DInfoArray (values, valueType)
8962
8968
  {
8963
8969
  const proxy = new Proxy (this, handler);
8964
8970
 
8965
8971
  Base_X3DChildObject .call (this);
8966
8972
 
8973
+ Object .defineProperties (this, properties);
8974
+
8967
8975
  this [_array] = [ ];
8968
8976
  this [_index] = new Map ();
8969
8977
  this [_valueType] = valueType;
@@ -8980,6 +8988,7 @@ Object .assign (Object .setPrototypeOf (X3DInfoArray .prototype, Base_X3DChildOb
8980
8988
  {
8981
8989
  yield* this [_array];
8982
8990
  },
8991
+ // Public functions:
8983
8992
  copy ()
8984
8993
  {
8985
8994
  const copy = new (this .constructor) ();
@@ -8988,6 +8997,7 @@ Object .assign (Object .setPrototypeOf (X3DInfoArray .prototype, Base_X3DChildOb
8988
8997
 
8989
8998
  return copy;
8990
8999
  },
9000
+ // Private functions:
8991
9001
  clear ()
8992
9002
  {
8993
9003
  this [_array] .length = 0;
@@ -9005,6 +9015,7 @@ Object .assign (Object .setPrototypeOf (X3DInfoArray .prototype, Base_X3DChildOb
9005
9015
 
9006
9016
  this .addEvent ();
9007
9017
  },
9018
+ // Public functions:
9008
9019
  equals (array)
9009
9020
  {
9010
9021
  const
@@ -9026,6 +9037,7 @@ Object .assign (Object .setPrototypeOf (X3DInfoArray .prototype, Base_X3DChildOb
9026
9037
 
9027
9038
  return true;
9028
9039
  },
9040
+ // Private functions:
9029
9041
  has (key)
9030
9042
  {
9031
9043
  return this [_index] .has (key);
@@ -9100,41 +9112,42 @@ Object .assign (Object .setPrototypeOf (X3DInfoArray .prototype, Base_X3DChildOb
9100
9112
 
9101
9113
  this .addEvent ();
9102
9114
  },
9103
- at: Array .prototype .at,
9104
- // concat: Array .prototype .concat,
9105
- // copyWithin: Array.prototype.copyWithin,
9106
- entries: Array .prototype .entries,
9107
- every: Array .prototype .every,
9108
- // fill: Array .prototype .fill,
9115
+ // Public functions:
9116
+ // Add all non destructive functions:
9117
+ ... Object .fromEntries ([
9118
+ "at",
9119
+ "entries",
9120
+ "every",
9121
+ "find",
9122
+ "findIndex",
9123
+ "findLast",
9124
+ "findLastIndex",
9125
+ "flat",
9126
+ "flatMap",
9127
+ "forEach",
9128
+ "includes",
9129
+ "indexOf",
9130
+ "join",
9131
+ "keys",
9132
+ "lastIndexOf",
9133
+ "reduce",
9134
+ "reduceRight",
9135
+ "some",
9136
+ "values",
9137
+ ]
9138
+ .map (name => [name, Array .prototype [name]])),
9109
9139
  filter (callbackFn, thisArg)
9110
9140
  {
9111
9141
  return new (this .constructor) (Array .prototype .filter .call (this, callbackFn, thisArg));
9112
9142
  },
9113
- find: Array .prototype .find,
9114
- findIndex: Array .prototype .findIndex,
9115
- findLast: Array .prototype .findLast,
9116
- findLastIndex: Array .prototype .findLastIndex,
9117
- flat: Array .prototype .flat,
9118
- flatMap: Array .prototype .flatMap,
9119
- forEach: Array .prototype .forEach,
9120
- includes: Array .prototype .includes,
9121
- indexOf: Array .prototype .indexOf,
9122
- join: Array .prototype .join,
9123
- keys: Array .prototype .keys,
9124
- lastIndexOf: Array .prototype .lastIndexOf,
9125
9143
  map (callbackFn, thisArg)
9126
9144
  {
9127
9145
  return new (this .constructor) (Array .prototype .map .call (this, callbackFn, thisArg));
9128
9146
  },
9129
- reduce: Array .prototype .reduce,
9130
- reduceRight: Array .prototype .reduceRight,
9131
- // reverse: Array .prototype .reverse,
9132
9147
  slice (start, end)
9133
9148
  {
9134
9149
  return new (this .constructor) (Array .prototype .slice .call (this, start, end));
9135
9150
  },
9136
- some: Array .prototype .some,
9137
- // sort: Array .prototype .sort,
9138
9151
  toReversed ()
9139
9152
  {
9140
9153
  return new (this .constructor) ([... this] .reverse ());
@@ -9151,7 +9164,6 @@ Object .assign (Object .setPrototypeOf (X3DInfoArray .prototype, Base_X3DChildOb
9151
9164
 
9152
9165
  return new (this .constructor) (array);
9153
9166
  },
9154
- values: Array .prototype .values,
9155
9167
  with (index, value)
9156
9168
  {
9157
9169
  const array = [... this];
@@ -9160,6 +9172,7 @@ Object .assign (Object .setPrototypeOf (X3DInfoArray .prototype, Base_X3DChildOb
9160
9172
 
9161
9173
  return new (this .constructor) (array);
9162
9174
  },
9175
+ // Private functions:
9163
9176
  toVRMLStream (generator)
9164
9177
  {
9165
9178
  const proto = this .getTypeName () .includes ("Proto");
@@ -9175,7 +9188,7 @@ Object .assign (Object .setPrototypeOf (X3DInfoArray .prototype, Base_X3DChildOb
9175
9188
  if (proto)
9176
9189
  generator .TidyBreak ();
9177
9190
  }
9178
- catch (error)
9191
+ catch
9179
9192
  {
9180
9193
  // console .error (error);
9181
9194
  }
@@ -9191,7 +9204,7 @@ Object .assign (Object .setPrototypeOf (X3DInfoArray .prototype, Base_X3DChildOb
9191
9204
 
9192
9205
  generator .TidyBreak ();
9193
9206
  }
9194
- catch (error)
9207
+ catch
9195
9208
  {
9196
9209
  // console .error (error);
9197
9210
  }
@@ -9223,14 +9236,6 @@ Object .assign (Object .setPrototypeOf (X3DInfoArray .prototype, Base_X3DChildOb
9223
9236
  for (const key of Object .keys (X3DInfoArray .prototype))
9224
9237
  Object .defineProperty (X3DInfoArray .prototype, key, { enumerable: false });
9225
9238
 
9226
- Object .defineProperties (X3DInfoArray .prototype,
9227
- {
9228
- length:
9229
- {
9230
- get () { return this [_array] .length; },
9231
- },
9232
- });
9233
-
9234
9239
  const X3DInfoArray_default_ = X3DInfoArray;
9235
9240
  ;
9236
9241
 
@@ -9602,11 +9607,11 @@ Object .assign (Object .setPrototypeOf (X3DField .prototype, Base_X3DChildObject
9602
9607
  {
9603
9608
  this .fromVRMLString (value, scene);
9604
9609
  },
9605
- fromVRMLString (value, scene)
9610
+ fromVRMLString (/* value, scene */)
9606
9611
  {
9607
9612
  // Function will be overridden in VRMLParser.
9608
9613
  },
9609
- fromXMLString (value, scene)
9614
+ fromXMLString (/* value, scene */)
9610
9615
  {
9611
9616
  // Function will be overridden in XMLParser.
9612
9617
  },
@@ -14335,9 +14340,6 @@ const SFMatrix4_default_ = SFMatrix4;
14335
14340
 
14336
14341
  const cache = new WeakMap ();
14337
14342
 
14338
- // const r = new FinalizationRegistry (t => console .error (`object deleted ${--i} ${t}`));
14339
- // let i = 0;
14340
-
14341
14343
  const SFNodeCache =
14342
14344
  {
14343
14345
  get (baseNode)
@@ -14359,8 +14361,6 @@ const SFNodeCache =
14359
14361
  },
14360
14362
  set (baseNode, node)
14361
14363
  {
14362
- Object .defineProperties (node, properties);
14363
-
14364
14364
  cache .set (baseNode, node);
14365
14365
  },
14366
14366
  delete (baseNode)
@@ -14369,30 +14369,6 @@ const SFNodeCache =
14369
14369
  },
14370
14370
  };
14371
14371
 
14372
- const disable =
14373
- {
14374
- value: undefined,
14375
- configurable: true,
14376
- };
14377
-
14378
- const properties =
14379
- {
14380
- fromString: disable,
14381
- fromVRMLString: disable,
14382
- fromXMLString: disable,
14383
- fromJSONString: disable,
14384
- dispose:
14385
- {
14386
- value ()
14387
- {
14388
- this .getValue () ?.dispose ();
14389
-
14390
- Fields_SFNode .prototype .dispose .call (this);
14391
- },
14392
- configurable: true,
14393
- },
14394
- };
14395
-
14396
14372
  const SFNodeCache_default_ = SFNodeCache;
14397
14373
  ;
14398
14374
 
@@ -14439,9 +14415,7 @@ const SFNode_handler =
14439
14415
 
14440
14416
  if (field)
14441
14417
  {
14442
- const accessType = field .getAccessType ();
14443
-
14444
- if (accessType === Base_X3DConstants .outputOnly)
14418
+ if (field .getAccessType () === Base_X3DConstants .outputOnly)
14445
14419
  return false;
14446
14420
 
14447
14421
  field .setValue (value);
@@ -14468,7 +14442,7 @@ const SFNode_handler =
14468
14442
  ownKeys .push (name);
14469
14443
  }
14470
14444
 
14471
- return ownKeys .concat (Object .keys (target));
14445
+ return ownKeys .concat (Reflect .ownKeys (target));
14472
14446
  },
14473
14447
  getOwnPropertyDescriptor (target, key)
14474
14448
  {
@@ -14808,7 +14782,15 @@ Object .assign (Object .setPrototypeOf (SFNode .prototype, Base_X3DField .protot
14808
14782
  },
14809
14783
  dispose ()
14810
14784
  {
14811
- const target = this [_target];
14785
+ const
14786
+ target = this [_target],
14787
+ node = target .getValue ();
14788
+
14789
+ if (node)
14790
+ {
14791
+ if (Fields_SFNodeCache .get (node) === this)
14792
+ node .dispose ();
14793
+ }
14812
14794
 
14813
14795
  target .set (null);
14814
14796
  target .processInterests ();
@@ -15681,74 +15663,61 @@ function X3DArrayField (value)
15681
15663
 
15682
15664
  Object .assign (Object .setPrototypeOf (X3DArrayField .prototype, Base_X3DField .prototype),
15683
15665
  {
15684
- // Implement all function also in TypedArray, if possible.
15685
- at: Array .prototype .at,
15686
- concat: Array .prototype .concat,
15687
- // copyWithin: Array.prototype.copyWithin,
15688
- entries: Array .prototype .entries,
15689
- every: Array .prototype .every,
15690
- fill: Array .prototype .fill,
15691
- filter (/* callbackFn, thisArg */)
15666
+ // Add all function possible in Array and TypedArray:
15667
+ ... Object .fromEntries ([
15668
+ "at",
15669
+ "concat",
15670
+ "entries",
15671
+ "every",
15672
+ "fill",
15673
+ "find",
15674
+ "findIndex",
15675
+ "findLast",
15676
+ "findLastIndex",
15677
+ "flat",
15678
+ "flatMap",
15679
+ "forEach",
15680
+ "includes",
15681
+ "indexOf",
15682
+ "join",
15683
+ "keys",
15684
+ "lastIndexOf",
15685
+ "reduce",
15686
+ "reduceRight",
15687
+ "reverse",
15688
+ "some",
15689
+ "sort",
15690
+ "values",
15691
+ ]
15692
+ .map (name => [name, Array .prototype [name]])),
15693
+ filter (... args)
15692
15694
  {
15693
- const array = new (this .constructor) ();
15694
-
15695
- for (const v of Array .prototype .filter .call (this, ... arguments))
15696
- array .push (v);
15697
-
15698
- return array;
15695
+ return this .constructor .from (Array .prototype .filter .call (this, ... args));
15699
15696
  },
15700
- find: Array .prototype .find,
15701
- findIndex: Array .prototype .findIndex,
15702
- findLast: Array .prototype .findLast,
15703
- findLastIndex: Array .prototype .findLastIndex,
15704
- flat: Array .prototype .flat,
15705
- flatMap: Array .prototype .flatMap,
15706
- forEach: Array .prototype .forEach,
15707
- includes: Array .prototype .includes,
15708
- indexOf: Array .prototype .indexOf,
15709
- join: Array .prototype .join,
15710
- keys: Array .prototype .keys,
15711
- lastIndexOf: Array .prototype .lastIndexOf,
15712
- map (/* callbackFn, thisArg */)
15713
- {
15714
- const array = new (this .constructor) ();
15715
-
15716
- for (const v of Array .prototype .map .call (this, ... arguments))
15717
- array .push (v);
15718
-
15719
- return array;
15697
+ map (... args)
15698
+ {
15699
+ return this .constructor .from (this, ... args);
15720
15700
  },
15721
- reduce: Array .prototype .reduce,
15722
- reduceRight: Array .prototype .reduceRight,
15723
- reverse: Array .prototype .reverse,
15724
- slice (/* start, end */)
15701
+ slice (... args)
15725
15702
  {
15726
- const array = new (this .constructor) ();
15727
-
15728
- for (const v of Array .prototype .slice .call (this, ... arguments))
15729
- array .push (v);
15730
-
15731
- return array;
15703
+ return this .constructor .from (Array .prototype .slice .call (this, ... args));
15732
15704
  },
15733
- some: Array .prototype .some,
15734
- sort: Array .prototype .sort,
15735
15705
  toReversed ()
15736
15706
  {
15737
15707
  return this .copy () .reverse ();
15738
15708
  },
15739
- toSorted (/* compareFn */)
15709
+ toSorted (... args)
15740
15710
  {
15741
- return this .copy () .sort (... arguments);
15711
+ return this .copy () .sort (... args);
15742
15712
  },
15743
- toSpliced (/* start, deleteCount, ... insertValues */)
15713
+ toSpliced (... args)
15744
15714
  {
15745
15715
  const copy = this .copy ();
15746
15716
 
15747
- copy .splice (... arguments);
15717
+ copy .splice (... args);
15748
15718
 
15749
15719
  return copy;
15750
15720
  },
15751
- values: Array .prototype .values,
15752
15721
  with (index, value)
15753
15722
  {
15754
15723
  const copy = this .copy ();
@@ -15762,6 +15731,35 @@ Object .assign (Object .setPrototypeOf (X3DArrayField .prototype, Base_X3DField
15762
15731
  for (const key of Object .keys (X3DArrayField .prototype))
15763
15732
  Object .defineProperty (X3DArrayField .prototype, key, { enumerable: false });
15764
15733
 
15734
+ Object .defineProperties (X3DArrayField,
15735
+ {
15736
+ addStaticProperties:
15737
+ {
15738
+ value (constructor, typeName)
15739
+ {
15740
+ Base_X3DField .addStaticProperties (constructor, typeName);
15741
+
15742
+ Object .defineProperties (constructor,
15743
+ {
15744
+ from:
15745
+ {
15746
+ value (... args)
15747
+ {
15748
+ const
15749
+ array = new constructor (),
15750
+ target = array .getTarget ();
15751
+
15752
+ for (const v of Array .from (... args))
15753
+ target .push (v);
15754
+
15755
+ return array;
15756
+ },
15757
+ },
15758
+ });
15759
+ },
15760
+ },
15761
+ });
15762
+
15765
15763
  const X3DArrayField_default_ = X3DArrayField;
15766
15764
  ;
15767
15765
 
@@ -15832,7 +15830,7 @@ const X3DObjectArrayField_handler =
15832
15830
  },
15833
15831
  ownKeys (target)
15834
15832
  {
15835
- return Object .keys (target .getValue ()) .concat (Object .keys (target));
15833
+ return Object .keys (target .getValue ()) .concat (Reflect .ownKeys (target));
15836
15834
  },
15837
15835
  getOwnPropertyDescriptor (target, key)
15838
15836
  {
@@ -15843,7 +15841,7 @@ const X3DObjectArrayField_handler =
15843
15841
  if (Number .isInteger (index) && index >= 0)
15844
15842
  {
15845
15843
  if (index < target .getValue () .length)
15846
- return Object .getOwnPropertyDescriptor (target .getValue (), key);
15844
+ return Reflect .getOwnPropertyDescriptor (target .getValue (), key);
15847
15845
  }
15848
15846
  }
15849
15847
 
@@ -15851,12 +15849,21 @@ const X3DObjectArrayField_handler =
15851
15849
  },
15852
15850
  };
15853
15851
 
15852
+ const X3DObjectArrayField_properties = {
15853
+ length: {
15854
+ get () { return this [X3DObjectArrayField_target] .getValue () .length; },
15855
+ set (value) { this [X3DObjectArrayField_target] .resize (value); },
15856
+ },
15857
+ };
15858
+
15854
15859
  function X3DObjectArrayField (values)
15855
15860
  {
15856
15861
  const proxy = new Proxy (this, X3DObjectArrayField_handler);
15857
15862
 
15858
15863
  Base_X3DArrayField .call (this, [ ]);
15859
15864
 
15865
+ Object .defineProperties (this, X3DObjectArrayField_properties);
15866
+
15860
15867
  this [X3DObjectArrayField_target] = this;
15861
15868
  this [X3DObjectArrayField_proxy] = proxy;
15862
15869
 
@@ -16273,12 +16280,6 @@ Object .assign (Object .setPrototypeOf (X3DObjectArrayField .prototype, Base_X3D
16273
16280
  for (const key of Object .keys (X3DObjectArrayField .prototype))
16274
16281
  Object .defineProperty (X3DObjectArrayField .prototype, key, { enumerable: false });
16275
16282
 
16276
- Object .defineProperty (X3DObjectArrayField .prototype, "length",
16277
- {
16278
- get () { return this [X3DObjectArrayField_target] .getValue () .length; },
16279
- set (value) { this [X3DObjectArrayField_target] .resize (value); },
16280
- });
16281
-
16282
16283
  const X3DObjectArrayField_default_ = X3DObjectArrayField;
16283
16284
  ;
16284
16285
 
@@ -16390,7 +16391,7 @@ const X3DTypedArrayField_handler =
16390
16391
  for (let i = 0; i < length; ++ i)
16391
16392
  ownKeys .push (String (i));
16392
16393
 
16393
- return ownKeys .concat (Object .keys (target));
16394
+ return ownKeys .concat (Reflect .ownKeys (target));
16394
16395
  },
16395
16396
  getOwnPropertyDescriptor (target, key)
16396
16397
  {
@@ -16401,7 +16402,7 @@ const X3DTypedArrayField_handler =
16401
16402
  if (Number .isInteger (index) && index >= 0)
16402
16403
  {
16403
16404
  if (index < target [_length])
16404
- return Object .getOwnPropertyDescriptor (target .getValue (), key);
16405
+ return Reflect .getOwnPropertyDescriptor (target .getValue (), key);
16405
16406
  }
16406
16407
  }
16407
16408
 
@@ -16409,12 +16410,26 @@ const X3DTypedArrayField_handler =
16409
16410
  },
16410
16411
  };
16411
16412
 
16413
+ const X3DTypedArrayField_properties = {
16414
+ length: {
16415
+ get () { return this [_length]; },
16416
+ set (value)
16417
+ {
16418
+ const target = this [X3DTypedArrayField_target];
16419
+
16420
+ target .resize (value, target .getSingleValue ());
16421
+ },
16422
+ },
16423
+ };
16424
+
16412
16425
  function X3DTypedArrayField (values)
16413
16426
  {
16414
16427
  const proxy = new Proxy (this, X3DTypedArrayField_handler);
16415
16428
 
16416
16429
  Base_X3DArrayField .call (this, new (this .getArrayType ()) (16));
16417
16430
 
16431
+ Object .defineProperties (this, X3DTypedArrayField_properties);
16432
+
16418
16433
  this [X3DTypedArrayField_target] = this;
16419
16434
  this [X3DTypedArrayField_proxy] = proxy;
16420
16435
 
@@ -16515,9 +16530,8 @@ Object .assign (Object .setPrototypeOf (X3DTypedArrayField .prototype, Base_X3DA
16515
16530
  set (otherArray /* value of field */, l /* length of field */)
16516
16531
  {
16517
16532
  const
16518
- target = this [X3DTypedArrayField_target],
16519
- components = target .getComponents (),
16520
- length = target [_length];
16533
+ target = this [X3DTypedArrayField_target],
16534
+ components = target .getComponents ();
16521
16535
 
16522
16536
  let
16523
16537
  array = target .getValue (),
@@ -16539,16 +16553,10 @@ Object .assign (Object .setPrototypeOf (X3DTypedArrayField .prototype, Base_X3DA
16539
16553
  array = target [_grow] (otherArray .length);
16540
16554
 
16541
16555
  array .set (otherArray);
16542
-
16543
- if (rest)
16544
- array .fill (0, otherLength * components, otherLength * components + rest);
16545
16556
  }
16546
16557
  else
16547
16558
  {
16548
16559
  array .set (otherArray);
16549
-
16550
- if (otherLength < length)
16551
- array .fill (0, otherLength * components, length * components);
16552
16560
  }
16553
16561
 
16554
16562
  target [_length] = otherLength;
@@ -16639,7 +16647,6 @@ Object .assign (Object .setPrototypeOf (X3DTypedArrayField .prototype, Base_X3DA
16639
16647
  }
16640
16648
 
16641
16649
  array .copyWithin (0, components, length * components);
16642
- array .fill (0, components * newLength, length * components);
16643
16650
 
16644
16651
  target [_length] = newLength;
16645
16652
 
@@ -16712,8 +16719,6 @@ Object .assign (Object .setPrototypeOf (X3DTypedArrayField .prototype, Base_X3DA
16712
16719
  value = new valueType (... tmp);
16713
16720
  }
16714
16721
 
16715
- array .fill (0, newLength * components, length * components);
16716
-
16717
16722
  target [_length] = newLength;
16718
16723
 
16719
16724
  target .addEvent ();
@@ -16804,7 +16809,6 @@ Object .assign (Object .setPrototypeOf (X3DTypedArrayField .prototype, Base_X3DA
16804
16809
  last *= components;
16805
16810
 
16806
16811
  array .copyWithin (first, last, length * components);
16807
- array .fill (0, newLength * components, length * components);
16808
16812
 
16809
16813
  target [_length] = newLength;
16810
16814
 
@@ -16831,8 +16835,6 @@ Object .assign (Object .setPrototypeOf (X3DTypedArrayField .prototype, Base_X3DA
16831
16835
 
16832
16836
  if (newLength < length)
16833
16837
  {
16834
- array .fill (0, newLength * components, length * components);
16835
-
16836
16838
  if (components > 1)
16837
16839
  target [_cache] .length = newLength;
16838
16840
 
@@ -16843,7 +16845,9 @@ Object .assign (Object .setPrototypeOf (X3DTypedArrayField .prototype, Base_X3DA
16843
16845
  {
16844
16846
  array = target [_grow] (newLength * components);
16845
16847
 
16846
- if (value !== undefined)
16848
+ if (value === undefined)
16849
+ array .fill (0, length * components, newLength * components);
16850
+ else
16847
16851
  this [_fill] (value, length, newLength);
16848
16852
 
16849
16853
  if (!silently)
@@ -16862,14 +16866,29 @@ Object .assign (Object .setPrototypeOf (X3DTypedArrayField .prototype, Base_X3DA
16862
16866
  return array;
16863
16867
 
16864
16868
  const
16865
- maxLength = Math_Algorithm .nextPowerOfTwo (length),
16866
- newArray = new (target .getArrayType ()) (maxLength);
16869
+ arrayType = target .getArrayType (),
16870
+ buffer = array .buffer;
16867
16871
 
16868
- newArray .set (array);
16872
+ if (length <= buffer .byteLength / arrayType .BYTES_PER_ELEMENT)
16873
+ {
16874
+ const newArray = new arrayType (buffer);
16869
16875
 
16870
- Base_X3DArrayField .prototype .set .call (target, newArray);
16876
+ Base_X3DArrayField .prototype .set .call (target, newArray);
16871
16877
 
16872
- return newArray;
16878
+ return newArray;
16879
+ }
16880
+ else
16881
+ {
16882
+ const
16883
+ nextLength = Math_Algorithm .nextPowerOfTwo (length),
16884
+ newArray = new arrayType (nextLength);
16885
+
16886
+ newArray .set (array);
16887
+
16888
+ Base_X3DArrayField .prototype .set .call (target, newArray);
16889
+
16890
+ return newArray;
16891
+ }
16873
16892
  },
16874
16893
  shrinkToFit ()
16875
16894
  {
@@ -16918,13 +16937,13 @@ Object .assign (Object .setPrototypeOf (X3DTypedArrayField .prototype, Base_X3DA
16918
16937
  valueType = target .getValueType ();
16919
16938
 
16920
16939
  if (components === 1)
16921
- return Array .from (array, value => valueType (value));
16940
+ return Array .from (array, valueType);
16922
16941
 
16923
16942
  return Array .from (array);
16924
16943
  },
16925
16944
  flatMap (... args)
16926
16945
  {
16927
- return this .map (...args) .flat ();
16946
+ return this .map (... args) .flat ();
16928
16947
  },
16929
16948
  [_fill] (value, start = 0, end = this .length)
16930
16949
  {
@@ -16935,7 +16954,7 @@ Object .assign (Object .setPrototypeOf (X3DTypedArrayField .prototype, Base_X3DA
16935
16954
  components = target .getComponents ();
16936
16955
 
16937
16956
  if (-length <= start && start < 0)
16938
- start = start + length;
16957
+ start += length;
16939
16958
 
16940
16959
  if (start < -length)
16941
16960
  start = 0;
@@ -16944,7 +16963,7 @@ Object .assign (Object .setPrototypeOf (X3DTypedArrayField .prototype, Base_X3DA
16944
16963
  return;
16945
16964
 
16946
16965
  if (-length <= end && end < 0)
16947
- end = end + length;
16966
+ end += length;
16948
16967
 
16949
16968
  if (end < -length)
16950
16969
  end = 0;
@@ -17326,17 +17345,6 @@ Object .assign (Object .setPrototypeOf (X3DTypedArrayField .prototype, Base_X3DA
17326
17345
  for (const key of Object .keys (X3DTypedArrayField .prototype))
17327
17346
  Object .defineProperty (X3DTypedArrayField .prototype, key, { enumerable: false });
17328
17347
 
17329
- Object .defineProperty (X3DTypedArrayField .prototype, "length",
17330
- {
17331
- get () { return this [_length]; },
17332
- set (value)
17333
- {
17334
- const target = this [X3DTypedArrayField_target];
17335
-
17336
- target .resize (value, target .getSingleValue ());
17337
- },
17338
- });
17339
-
17340
17348
  // Getter/Setter functions to reference a value for a given index.
17341
17349
 
17342
17350
  function createValue (target, index, components, valueType)
@@ -17407,7 +17415,6 @@ const X3DTypedArrayField_default_ = X3DTypedArrayField;
17407
17415
 
17408
17416
 
17409
17417
 
17410
-
17411
17418
 
17412
17419
  const
17413
17420
  { SFBool, SFDouble, SFFloat, SFInt32, SFString, SFTime } = Fields_SFScalar,
@@ -17636,7 +17643,7 @@ Object .assign (Object .setPrototypeOf (MFNode .prototype, Base_X3DObjectArrayFi
17636
17643
  for (const key of Object .keys (MFNode .prototype))
17637
17644
  Object .defineProperty (MFNode .prototype, key, { enumerable: false });
17638
17645
 
17639
- Base_X3DField .addStaticProperties (MFNode, "MFNode");
17646
+ Base_X3DArrayField .addStaticProperties (MFNode, "MFNode");
17640
17647
 
17641
17648
  function MFString (... args)
17642
17649
  {
@@ -17678,7 +17685,7 @@ Object .assign (Object .setPrototypeOf (MFString .prototype, Base_X3DObjectArray
17678
17685
  for (const key of Object .keys (MFString .prototype))
17679
17686
  Object .defineProperty (MFString .prototype, key, { enumerable: false });
17680
17687
 
17681
- Base_X3DField .addStaticProperties (MFString, "MFString");
17688
+ Base_X3DArrayField .addStaticProperties (MFString, "MFString");
17682
17689
 
17683
17690
  /**
17684
17691
  * MFImage
@@ -17700,7 +17707,7 @@ Object .assign (Object .setPrototypeOf (MFImage .prototype, Base_X3DObjectArrayF
17700
17707
  for (const key of Object .keys (MFImage .prototype))
17701
17708
  Object .defineProperty (MFImage .prototype, key, { enumerable: false });
17702
17709
 
17703
- Base_X3DField .addStaticProperties (MFImage, "MFImage");
17710
+ Base_X3DArrayField .addStaticProperties (MFImage, "MFImage");
17704
17711
 
17705
17712
  function TypedArrayTemplate (TypeName, SingleType, ValueType, ArrayType, Components, singleValue)
17706
17713
  {
@@ -17736,7 +17743,7 @@ function TypedArrayTemplate (TypeName, SingleType, ValueType, ArrayType, Compone
17736
17743
  for (const key of Object .keys (ArrayField .prototype))
17737
17744
  Object .defineProperty (ArrayField .prototype, key, { enumerable: false });
17738
17745
 
17739
- Base_X3DField .addStaticProperties (ArrayField, TypeName);
17746
+ Base_X3DArrayField .addStaticProperties (ArrayField, TypeName);
17740
17747
 
17741
17748
  return ArrayField;
17742
17749
  }
@@ -17757,7 +17764,7 @@ const ArrayFields =
17757
17764
  MFMatrix4d: TypedArrayTemplate ("MFMatrix4d", SFMatrix4d, SFMatrix4d, Float64Array, 16, Numbers_Matrix4 .IDENTITY),
17758
17765
  MFMatrix4f: TypedArrayTemplate ("MFMatrix4f", SFMatrix4f, SFMatrix4f, Float32Array, 16, Numbers_Matrix4 .IDENTITY),
17759
17766
  MFNode,
17760
- MFQuaternion: TypedArrayTemplate ("MFQuaternion", Fields_SFQuaternion, Fields_SFQuaternion, Float64Array, 4, Numbers_Quaternion .ZERO),
17767
+ MFQuaternion: TypedArrayTemplate ("MFQuaternion", Fields_SFQuaternion, Fields_SFQuaternion, Float64Array, 4),
17761
17768
  MFRotation: TypedArrayTemplate ("MFRotation", Fields_SFRotation, Fields_SFRotation, Float64Array, 4, Numbers_Rotation4 .IDENTITY),
17762
17769
  MFString,
17763
17770
  MFTime: TypedArrayTemplate ("MFTime", SFTime, Value, Float64Array, 1, -1),
@@ -18322,7 +18329,11 @@ Object .assign (Object .setPrototypeOf (X3DBaseNode .prototype, Base_X3DChildObj
18322
18329
 
18323
18330
  // Change function.
18324
18331
 
18325
- Object .defineProperty (this, "getLive", { value: getLive });
18332
+ Object .defineProperty (this, "getLive",
18333
+ {
18334
+ value: getLive,
18335
+ configurable: true,
18336
+ });
18326
18337
 
18327
18338
  // Add isLive event.
18328
18339
 
@@ -18407,6 +18418,7 @@ Object .assign (Object .setPrototypeOf (X3DBaseNode .prototype, Base_X3DChildObj
18407
18418
  {
18408
18419
  get () { return field; },
18409
18420
  set (value) { field .setValue (value); },
18421
+ configurable: true,
18410
18422
  });
18411
18423
  },
18412
18424
  getFieldDefinition (name)
@@ -18846,7 +18858,7 @@ const Legacy_default_ = Legacy;
18846
18858
 
18847
18859
  /* harmony default export */ const Browser_Legacy = (x_ite_Namespace .add ("Legacy", Legacy_default_));
18848
18860
  ;// ./src/x_ite/BROWSER_VERSION.js
18849
- const BROWSER_VERSION_default_ = "16.1.0";
18861
+ const BROWSER_VERSION_default_ = "16.1.2";
18850
18862
  ;
18851
18863
 
18852
18864
  /* harmony default export */ const BROWSER_VERSION = (x_ite_Namespace .add ("BROWSER_VERSION", BROWSER_VERSION_default_));
@@ -23957,51 +23969,67 @@ const NamedNodesArray_default_ = NamedNodesArray;
23957
23969
  const
23958
23970
  _importedName = Symbol (),
23959
23971
  _importedNode = Symbol (),
23960
- X3DImportedNodeProxy_type = Symbol ();
23972
+ X3DImportedNodeProxy_type = Symbol (),
23973
+ _functions = Symbol ();
23961
23974
 
23962
23975
  const X3DImportedNodeProxy_handler =
23963
23976
  {
23964
- get (target, key)
23977
+ get (target, key, receiver)
23965
23978
  {
23966
- if (key in target)
23967
- return target [key];
23979
+ if (Reflect .has (target, key))
23980
+ return Reflect .get (target, key, receiver);
23968
23981
 
23969
- const
23970
- node = target .getSharedNode (),
23971
- property = node ?.[key];
23982
+ const node = target .getSharedNode ();
23983
+
23984
+ if (node)
23985
+ {
23986
+ const property = Reflect .get (node, key, receiver);
23987
+
23988
+ if (typeof property === "function")
23989
+ {
23990
+ return target [_functions] .get (key) ?? (() =>
23991
+ {
23992
+ const func = property .bind (node);
23972
23993
 
23973
- if (typeof property === "function")
23974
- return property .bind (node);
23994
+ target [_functions] .set (key, func);
23975
23995
 
23976
- return property;
23996
+ return func;
23997
+ })();
23998
+ }
23999
+
24000
+ return property;
24001
+ }
23977
24002
  },
23978
- set (target, key, value)
24003
+ set (target, key, value, receiver)
23979
24004
  {
23980
- if (key in target)
24005
+ if (Reflect .has (target, key))
23981
24006
  {
23982
- target [key] = value;
24007
+ return Reflect .set (target, key, value, receiver);
23983
24008
  }
23984
24009
  else
23985
24010
  {
23986
24011
  const node = target .getSharedNode ();
23987
24012
 
23988
24013
  if (node)
23989
- node [key] = value;
23990
- }
24014
+ return Reflect .set (node, key, value, receiver);
23991
24015
 
23992
- return true;
24016
+ return false;
24017
+ }
23993
24018
  },
23994
24019
  has (target, key)
23995
24020
  {
23996
- return key in (target .getSharedNode () ?? { });
24021
+ return Reflect .has (target, key)
24022
+ || Reflect .has (target .getSharedNode () ?? { }, key);
23997
24023
  },
23998
24024
  ownKeys (target)
23999
24025
  {
24000
- return Object .keys (target .getSharedNode () ?? { });
24026
+ return Array .from (new Set (Reflect .ownKeys (target)
24027
+ .concat (Reflect .ownKeys (target .getSharedNode () ?? { }))));
24001
24028
  },
24002
24029
  getOwnPropertyDescriptor (target, key)
24003
24030
  {
24004
- return Object .getOwnPropertyDescriptor (target .getSharedNode () ?? { }, key);
24031
+ return Reflect .getOwnPropertyDescriptor (target, key)
24032
+ ?? Reflect .getOwnPropertyDescriptor (target .getSharedNode () ?? { }, key);
24005
24033
  },
24006
24034
  };
24007
24035
 
@@ -24013,6 +24041,7 @@ function X3DImportedNodeProxy (executionContext, importedName, type)
24013
24041
 
24014
24042
  this [_importedName] = importedName;
24015
24043
  this [X3DImportedNodeProxy_type] = type;
24044
+ this [_functions] = new Map ();
24016
24045
 
24017
24046
  this .setup ();
24018
24047
 
@@ -26007,7 +26036,7 @@ Object .assign (X3DParser .prototype,
26007
26036
  },
26008
26037
  sanitizeName (name = "")
26009
26038
  {
26010
- /* eslint-disable no-control-regex */
26039
+
26011
26040
 
26012
26041
  // NonIdFirstChar
26013
26042
  name = name .replace (/^[\x30-\x39\x00-\x20\x22\x23\x27\x2b\x2c\x2d\x2e\x5b\x5c\x5d\x7b\x7d\x7f]*/, "");
@@ -26023,7 +26052,7 @@ Object .assign (X3DParser .prototype,
26023
26052
 
26024
26053
  return name;
26025
26054
 
26026
- /* eslint-enable no-control-regex */
26055
+
26027
26056
  },
26028
26057
  renameExistingNode (name)
26029
26058
  {
@@ -26303,10 +26332,10 @@ const Grammar = Parser_Expressions ({
26303
26332
  Period: /\./y,
26304
26333
  Colon: /:/y,
26305
26334
 
26306
- /* eslint-disable no-control-regex */
26335
+ // eslint-disable-next-line no-control-regex
26307
26336
  Id: /[^\x30-\x39\x00-\x20\x22\x23\x27\x2b\x2c\x2d\x2e\x5b\x5c\x5d\x7b\x7d\x7f]{1}[^\x00-\x20\x22\x23\x27\x2c\x2e\x5b\x5c\x5d\x7b\x7d\x7f]*/y,
26337
+ // eslint-disable-next-line no-control-regex
26308
26338
  ComponentNameId: /[^\x30-\x39\x00-\x20\x22\x23\x27\x2b\x2c\x2d\x2e\x5b\x5c\x5d\x7b\x7d\x7f\x3a]{1}[^\x00-\x20\x22\x23\x27\x2c\x2e\x5b\x5c\x5d\x7b\x7d\x7f\x3a]*/y,
26309
- /* eslint-enable no-control-regex */
26310
26339
 
26311
26340
  initializeOnly: /initializeOnly/y,
26312
26341
  inputOnly: /inputOnly/y,
@@ -31158,7 +31187,7 @@ const Plane3_default_ = Plane3;
31158
31187
 
31159
31188
  /* harmony default export */ const Geometry_Plane3 = (x_ite_Namespace .add ("Plane3", Plane3_default_));
31160
31189
  ;// ./src/standard/Math/Geometry/Triangle3.js
31161
- /* provided dependency */ var libtess = __webpack_require__(246);
31190
+ /* provided dependency */ var libtess = __webpack_require__(457);
31162
31191
 
31163
31192
 
31164
31193
  const Triangle3 =
@@ -37531,7 +37560,7 @@ Object .assign (Object .setPrototypeOf (X3DSingleTextureNode .prototype, Texturi
37531
37560
  {
37532
37561
  return false;
37533
37562
  },
37534
- getRenderedTextures (renderedTextures)
37563
+ getRenderedTextures (/* renderedTextures */)
37535
37564
  { },
37536
37565
  loadImage (fileURL)
37537
37566
  {
@@ -42148,8 +42177,10 @@ function eventsProcessed ()
42148
42177
  {
42149
42178
  scene .addNamedNode (scene .getUniqueName (name), shapeNode);
42150
42179
 
42151
- if (shapeNode .getGeometry ?.() && !shapeNode .getGeometry () .getName ())
42152
- scene .addNamedNode (scene .getUniqueName (`${name}-Mesh-${i}`), shapeNode .getGeometry ());
42180
+ const geometryNode = shapeNode .getGeometry ?.();
42181
+
42182
+ if (geometryNode && !geometryNode .getName ())
42183
+ scene .addNamedNode (scene .getUniqueName (`${name}-Mesh-${i}`), geometryNode);
42153
42184
  }
42154
42185
  }
42155
42186
 
@@ -47856,7 +47887,7 @@ const Bezier_default_ = Bezier;
47856
47887
 
47857
47888
  /* harmony default export */ const Algorithms_Bezier = (x_ite_Namespace .add ("Bezier", Bezier_default_));
47858
47889
  ;// ./src/x_ite/Parser/SVGParser.js
47859
- /* provided dependency */ var SVGParser_libtess = __webpack_require__(246);
47890
+ /* provided dependency */ var SVGParser_libtess = __webpack_require__(457);
47860
47891
 
47861
47892
 
47862
47893
 
@@ -54555,7 +54586,7 @@ function X3DCoreContext (element)
54555
54586
  {
54556
54587
  const link = document .createElement ("link");
54557
54588
 
54558
- link .integrity = "sha384-FFe+A/LlgO2IEpOMp+dkCR3QO/mFR66blaOr+NTadcKHxnGzSm8EdCuwQ+HtDZHM";
54589
+ link .integrity = "sha384-FEmsQpL8R1dkzlxB19h2qi5U9Cuh8Zk2953YCudH0PTQSwiWiUovdIWVDBu3/YAc";
54559
54590
  link .rel = "stylesheet";
54560
54591
  link .crossOrigin = "anonymous";
54561
54592
  link .onload = resolve;
@@ -55578,11 +55609,8 @@ Object .assign (Object .setPrototypeOf (X3DComposedGeometryNode .prototype, Rend
55578
55609
  attribNodes [a] .addValue (index, attribArrays [a]);
55579
55610
 
55580
55611
  fogCoordNode ?.addDepth (index, fogDepthArray);
55581
-
55582
55612
  colorNode ?.addColor (colorPerVertex ? index : face, colorArray);
55583
-
55584
55613
  texCoordNode ?.addPoint (index, multiTexCoordArray);
55585
-
55586
55614
  tangentNode ?.addVector (normalPerVertex ? index : face, tangentArray);
55587
55615
  normalNode ?.addVector (normalPerVertex ? index : face, normalArray);
55588
55616
 
@@ -55757,26 +55785,6 @@ Object .assign (Object .setPrototypeOf (IndexedFaceSet .prototype, Rendering_X3D
55757
55785
  this ._set_normalIndex .addFieldInterest (this ._normalIndex);
55758
55786
  this ._set_coordIndex .addFieldInterest (this ._coordIndex);
55759
55787
  },
55760
- getTexCoordPerVertexIndex (index)
55761
- {
55762
- return this ._texCoordIndex [index] ?? this ._coordIndex [index];
55763
- },
55764
- getColorPerVertexIndex (index)
55765
- {
55766
- return this ._colorIndex [index] ?? this ._coordIndex [index];
55767
- },
55768
- getColorPerFaceIndex (index)
55769
- {
55770
- return this ._colorIndex [index] ?? index;
55771
- },
55772
- getNormalPerVertexIndex (index)
55773
- {
55774
- return this ._normalIndex [index] ?? this ._coordIndex [index];
55775
- },
55776
- getNormalPerFaceIndex (index)
55777
- {
55778
- return this ._normalIndex [index] ?? index;
55779
- },
55780
55788
  build ()
55781
55789
  {
55782
55790
  // Triangulate
@@ -55793,6 +55801,9 @@ Object .assign (Object .setPrototypeOf (IndexedFaceSet .prototype, Rendering_X3D
55793
55801
  const
55794
55802
  colorPerVertex = this ._colorPerVertex .getValue (),
55795
55803
  normalPerVertex = this ._normalPerVertex .getValue (),
55804
+ colorIndex = this ._colorIndex .shrinkToFit (),
55805
+ texCoordIndex = this ._texCoordIndex .shrinkToFit (),
55806
+ normalIndex = this ._normalIndex .shrinkToFit (),
55796
55807
  coordIndex = this ._coordIndex .getValue (),
55797
55808
  coordIndicesArray = this .getCoordIndices (),
55798
55809
  attribNodes = this .getAttrib (),
@@ -55825,13 +55836,10 @@ Object .assign (Object .setPrototypeOf (IndexedFaceSet .prototype, Rendering_X3D
55825
55836
  attribNodes [a] .addValue (index, attribArrays [a]);
55826
55837
 
55827
55838
  fogCoordNode ?.addDepth (index, fogDepthArray);
55828
-
55829
- colorNode ?.addColor (colorPerVertex ? this .getColorPerVertexIndex (i) : this .getColorPerFaceIndex (face), colorArray);
55830
-
55831
- texCoordNode ?.addPoint (this .getTexCoordPerVertexIndex (i), multiTexCoordArray);
55832
-
55833
- tangentNode ?.addVector (normalPerVertex ? this .getNormalPerVertexIndex (i) : this .getNormalPerFaceIndex (face), tangentArray);
55834
- normalNode ?.addVector (normalPerVertex ? this .getNormalPerVertexIndex (i) : this .getNormalPerFaceIndex (face), normalArray);
55839
+ colorNode ?.addColor (colorPerVertex ? (colorIndex [i] ?? index) : (colorIndex [face] ?? face), colorArray);
55840
+ texCoordNode ?.addPoint (texCoordIndex [i] ?? index, multiTexCoordArray);
55841
+ tangentNode ?.addVector (normalPerVertex ? (normalIndex [i] ?? index) : (normalIndex [face] ?? face), tangentArray);
55842
+ normalNode ?.addVector (normalPerVertex ? (normalIndex [i] ?? index) : (normalIndex [face] ?? face), normalArray);
55835
55843
 
55836
55844
  coordNode .addPoint (index, vertexArray);
55837
55845
  }
@@ -59017,14 +59025,6 @@ Object .assign (Object .setPrototypeOf (IndexedLineSet .prototype, Rendering_X3D
59017
59025
  this .set_normal__ ();
59018
59026
  this .set_coord__ ();
59019
59027
  },
59020
- getColorPerVertexIndex (index)
59021
- {
59022
- return this ._colorIndex [index] ?? this ._coordIndex [index];
59023
- },
59024
- getColorIndex (index)
59025
- {
59026
- return this ._colorIndex [index] ?? index;
59027
- },
59028
59028
  getPolylineIndices ()
59029
59029
  {
59030
59030
  const
@@ -59067,7 +59067,8 @@ Object .assign (Object .setPrototypeOf (IndexedLineSet .prototype, Rendering_X3D
59067
59067
  return;
59068
59068
 
59069
59069
  const
59070
- coordIndex = this ._coordIndex,
59070
+ colorIndex = this ._colorIndex .shrinkToFit (),
59071
+ coordIndex = this ._coordIndex .getValue (),
59071
59072
  polylines = this .getPolylineIndices (),
59072
59073
  colorPerVertex = this ._colorPerVertex .getValue (),
59073
59074
  coordIndicesArray = this .getCoordIndices (),
@@ -59113,9 +59114,7 @@ Object .assign (Object .setPrototypeOf (IndexedLineSet .prototype, Rendering_X3D
59113
59114
  attribNodes [a] .addValue (index, attribArrays [a]);
59114
59115
 
59115
59116
  fogCoordNode ?.addDepth (index, fogDepthArray);
59116
-
59117
- colorNode ?.addColor (colorPerVertex ? this .getColorPerVertexIndex (i) : this .getColorIndex (face), colorArray);
59118
-
59117
+ colorNode ?.addColor (colorPerVertex ? (colorIndex [i] ?? coordIndex [i]) : (colorIndex [face] ?? face), colorArray);
59119
59118
  tangentNode ?.addVector (index, tangentArray);
59120
59119
  normalNode ?.addVector (index, normalArray);
59121
59120
 
@@ -61126,7 +61125,7 @@ Object .assign (Object .setPrototypeOf (ExamineViewer .prototype, Navigation_X3D
61126
61125
  pixelPerRevolutionX = this .getViewport () [2] * 2,
61127
61126
  pixelPerRevolutionY = this .getViewport () [3] * 2,
61128
61127
  startRoll = Math .acos (Math_Algorithm .clamp (this .startOrientation .multVecRot (axis .assign (Numbers_Vector3 .Z_AXIS)) .dot (upVector), -1, 1)),
61129
- roll = Math .PI * 2 * +translation .y / pixelPerRevolutionY,
61128
+ roll = Math .PI * 2 * translation .y / pixelPerRevolutionY,
61130
61129
  clampedRoll = Math_Algorithm .clamp (startRoll + roll, CRITICAL_ANGLE, Math .PI - CRITICAL_ANGLE) - startRoll;
61131
61130
 
61132
61131
  // Adjust fromPointer y.
@@ -61724,7 +61723,8 @@ const
61724
61723
  PAN_SPEED_FACTOR = SPEED_FACTOR,
61725
61724
  PAN_SHIFT_SPEED_FACTOR = 1.4 * PAN_SPEED_FACTOR,
61726
61725
  ROLL_ANGLE = X3DFlyViewer_SLOW_SCROLL ? Math .PI / 512 : Math .PI / 32,
61727
- X3DFlyViewer_ROTATE_TIME = 0.3;
61726
+ X3DFlyViewer_ROTATE_TIME = 0.3,
61727
+ X3DFlyViewer_CRITICAL_ANGLE = 0.99;
61728
61728
 
61729
61729
  const
61730
61730
  MOVE = 0,
@@ -62235,7 +62235,8 @@ Object .assign (Object .setPrototypeOf (X3DFlyViewer .prototype, Navigation_X3DV
62235
62235
  {
62236
62236
  const
62237
62237
  userOrientation = new Numbers_Rotation4 (),
62238
- orientationOffset = new Numbers_Rotation4 ();
62238
+ orientationOffset = new Numbers_Rotation4 (),
62239
+ upVector = new Numbers_Vector3 ();
62239
62240
 
62240
62241
  return function (fromVector, toVector)
62241
62242
  {
@@ -62251,6 +62252,9 @@ Object .assign (Object .setPrototypeOf (X3DFlyViewer .prototype, Navigation_X3DV
62251
62252
  if (this .getStraightenHorizon ())
62252
62253
  viewpoint .straightenHorizon (userOrientation);
62253
62254
 
62255
+ if (Math .abs (viewpoint .getUpVector () .dot (userOrientation .multVecRot (upVector .set (0, 0, 1)))) > X3DFlyViewer_CRITICAL_ANGLE)
62256
+ return;
62257
+
62254
62258
  orientationOffset .assign (viewpoint .getOrientation ()) .inverse () .multRight (userOrientation);
62255
62259
 
62256
62260
  this .orientationChaser ._set_destination = orientationOffset;
@@ -62264,6 +62268,9 @@ Object .assign (Object .setPrototypeOf (X3DFlyViewer .prototype, Navigation_X3DV
62264
62268
  if (this .getStraightenHorizon ())
62265
62269
  viewpoint .straightenHorizon (userOrientation);
62266
62270
 
62271
+ if (Math .abs (viewpoint .getUpVector () .dot (userOrientation .multVecRot (upVector .set (0, 0, 1)))) > X3DFlyViewer_CRITICAL_ANGLE)
62272
+ return;
62273
+
62267
62274
  orientationOffset .assign (viewpoint .getOrientation ()) .inverse () .multRight (userOrientation);
62268
62275
 
62269
62276
  this .orientationChaser ._set_value = viewpoint ._orientationOffset;
@@ -77179,13 +77186,6 @@ Object .assign (Object .setPrototypeOf (ElevationGrid .prototype, Rendering_X3DG
77179
77186
  this .set_tangent__ ();
77180
77187
  this .set_normal__ ();
77181
77188
  },
77182
- getHeight (index)
77183
- {
77184
- if (index < this ._height .length)
77185
- return this ._height [index];
77186
-
77187
- return 0;
77188
- },
77189
77189
  createTexCoords ()
77190
77190
  {
77191
77191
  const
@@ -77281,15 +77281,14 @@ Object .assign (Object .setPrototypeOf (ElevationGrid .prototype, Rendering_X3DG
77281
77281
  xDimension = this ._xDimension .getValue (),
77282
77282
  zDimension = this ._zDimension .getValue (),
77283
77283
  xSpacing = this ._xSpacing .getValue (),
77284
- zSpacing = this ._zSpacing .getValue ();
77284
+ zSpacing = this ._zSpacing .getValue (),
77285
+ height = this ._height .shrinkToFit ();
77285
77286
 
77286
77287
  for (let z = 0; z < zDimension; ++ z)
77287
77288
  {
77288
77289
  for (let x = 0; x < xDimension; ++ x)
77289
77290
  {
77290
- points .push (new Numbers_Vector3 (xSpacing * x,
77291
- this .getHeight (x + z * xDimension),
77292
- zSpacing * z));
77291
+ points .push (new Numbers_Vector3 (xSpacing * x, height [x + z * xDimension] ?? 0, zSpacing * z));
77293
77292
  }
77294
77293
  }
77295
77294
 
@@ -77345,8 +77344,8 @@ Object .assign (Object .setPrototypeOf (ElevationGrid .prototype, Rendering_X3DG
77345
77344
  for (let p = 0; p < 6; ++ p, ++ c)
77346
77345
  {
77347
77346
  const
77348
- index = coordIndex [c],
77349
- { x, y, z} = points [index];
77347
+ index = coordIndex [c],
77348
+ { x, y, z } = points [index];
77350
77349
 
77351
77350
  coordIndicesArray .push (index);
77352
77351
 
@@ -77354,7 +77353,6 @@ Object .assign (Object .setPrototypeOf (ElevationGrid .prototype, Rendering_X3DG
77354
77353
  attribNodes [a] .addValue (index, attribArrays [a]);
77355
77354
 
77356
77355
  fogCoordNode ?.addDepth (index, fogDepthArray);
77357
-
77358
77356
  colorNode ?.addColor (colorPerVertex ? index : face, colorArray);
77359
77357
 
77360
77358
  if (texCoordNode)
@@ -79418,6 +79416,8 @@ Object .assign (Object .setPrototypeOf (TextureCoordinateGenerator .prototype, T
79418
79416
  ["SPHERE-REFLECT-LOCAL", TextureCoordinateGeneratorModeType .SPHERE_REFLECT_LOCAL],
79419
79417
  ]);
79420
79418
 
79419
+ modes .delete ("NONE");
79420
+
79421
79421
  return function ()
79422
79422
  {
79423
79423
  this .mode = modes .get (this ._mode .getValue ())
@@ -91269,8 +91269,8 @@ const PNGMedia_default_ = PNGMedia;
91269
91269
 
91270
91270
  /* harmony default export */ const Texturing_PNGMedia = (x_ite_Namespace .add ("PNGMedia", PNGMedia_default_));
91271
91271
  ;// ./src/x_ite/Components/Texturing/MovieTexture.js
91272
- /* provided dependency */ var SuperGif = __webpack_require__(548);
91273
- /* provided dependency */ var APNG = __webpack_require__(174);
91272
+ /* provided dependency */ var SuperGif = __webpack_require__(603);
91273
+ /* provided dependency */ var APNG = __webpack_require__(777);
91274
91274
 
91275
91275
 
91276
91276
 
@@ -91626,23 +91626,7 @@ Object .assign (Object .setPrototypeOf (MultiTexture .prototype, Texturing_X3DTe
91626
91626
  },
91627
91627
  getCount ()
91628
91628
  {
91629
- return Math .min (this .maxTextures, this .textureNodes .length);
91630
- },
91631
- getMode (index)
91632
- {
91633
- return this .modes [index] ?? Texturing_ModeType .MODULATE;
91634
- },
91635
- getAlphaMode (index)
91636
- {
91637
- return this .alphaModes [index] ?? Texturing_ModeType .MODULATE;
91638
- },
91639
- getSource (index)
91640
- {
91641
- return this .sources [index] ?? Texturing_SourceType .DEFAULT;
91642
- },
91643
- getFunction (index)
91644
- {
91645
- return this .functions [index] ?? Texturing_FunctionType .DEFAULT;
91629
+ return Math .min (this .textureNodes .length, this .maxTextures);
91646
91630
  },
91647
91631
  set_color__ ()
91648
91632
  {
@@ -91697,6 +91681,8 @@ Object .assign (Object .setPrototypeOf (MultiTexture .prototype, Texturing_X3DTe
91697
91681
  {
91698
91682
  const sourceTypes = new Map (Object .entries (Texturing_SourceType));
91699
91683
 
91684
+ sourceTypes .delete ("DEFAULT");
91685
+
91700
91686
  return function ()
91701
91687
  {
91702
91688
  this .sources .length = 0;
@@ -91713,6 +91699,8 @@ Object .assign (Object .setPrototypeOf (MultiTexture .prototype, Texturing_X3DTe
91713
91699
  ["ALPHAREPLICATE", Texturing_FunctionType .ALPHA_REPLICATE],
91714
91700
  ]);
91715
91701
 
91702
+ functionsTypes .delete ("DEFAULT");
91703
+
91716
91704
  return function ()
91717
91705
  {
91718
91706
  this .functions .length = 0;
@@ -91746,7 +91734,7 @@ Object .assign (Object .setPrototypeOf (MultiTexture .prototype, Texturing_X3DTe
91746
91734
  const
91747
91735
  maxTextures = this .maxTextures,
91748
91736
  textureNodes = this .textureNodes,
91749
- channels = Math .min (maxTextures, textureNodes .length);
91737
+ channels = Math .min (textureNodes .length, maxTextures);
91750
91738
 
91751
91739
  for (let i = 0; i < channels; ++ i)
91752
91740
  textureNodes [i] .updateTextureBits (textureBits, i);
@@ -91762,7 +91750,7 @@ Object .assign (Object .setPrototypeOf (MultiTexture .prototype, Texturing_X3DTe
91762
91750
  {
91763
91751
  const
91764
91752
  textureNodes = this .textureNodes,
91765
- channels = Math .min (this .maxTextures, textureNodes .length);
91753
+ channels = Math .min (textureNodes .length, this .maxTextures);
91766
91754
 
91767
91755
  for (let i = 0; i < channels; ++ i)
91768
91756
  textureNodes [i] .getShaderOptions (options, i);
@@ -91771,7 +91759,7 @@ Object .assign (Object .setPrototypeOf (MultiTexture .prototype, Texturing_X3DTe
91771
91759
  {
91772
91760
  const
91773
91761
  textureNodes = this .textureNodes,
91774
- channels = Math .min (this .maxTextures, textureNodes .length);
91762
+ channels = Math .min (textureNodes .length, this .maxTextures);
91775
91763
 
91776
91764
  gl .uniform4fv (shaderObject .x3d_MultiTextureColor, this .color);
91777
91765
 
@@ -91781,10 +91769,10 @@ Object .assign (Object .setPrototypeOf (MultiTexture .prototype, Texturing_X3DTe
91781
91769
 
91782
91770
  textureNodes [i] .setShaderUniforms (gl, shaderObject .x3d_Texture [i]);
91783
91771
 
91784
- gl .uniform1i (uniforms .mode, this .getMode (i));
91785
- gl .uniform1i (uniforms .alphaMode, this .getAlphaMode (i));
91786
- gl .uniform1i (uniforms .source, this .getSource (i));
91787
- gl .uniform1i (uniforms .function, this .getFunction (i));
91772
+ gl .uniform1i (uniforms .mode, this .modes [i] ?? Texturing_ModeType .MODULATE);
91773
+ gl .uniform1i (uniforms .alphaMode, this .alphaModes [i] ?? Texturing_ModeType .MODULATE);
91774
+ gl .uniform1i (uniforms .source, this .sources [i] ?? Texturing_SourceType .DEFAULT);
91775
+ gl .uniform1i (uniforms .function, this .functions [i] ?? Texturing_FunctionType .DEFAULT);
91788
91776
  }
91789
91777
  },
91790
91778
  });
@@ -93920,7 +93908,7 @@ const QuickSort_default_ = QuickSort;
93920
93908
 
93921
93909
  /* harmony default export */ const Algorithms_QuickSort = (x_ite_Namespace .add ("QuickSort", QuickSort_default_));
93922
93910
  ;// ./src/lib/libtess.js
93923
- /* provided dependency */ var libtess_libtess = __webpack_require__(246);
93911
+ /* provided dependency */ var libtess_libtess = __webpack_require__(457);
93924
93912
  const libtess_default_ = libtess_libtess;
93925
93913
  ;
93926
93914