x_ite 9.4.5 → 9.5.0

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 (48) hide show
  1. package/README.md +19 -5
  2. package/dist/assets/components/Annotation.js +13 -13
  3. package/dist/assets/components/Annotation.min.js +1 -1
  4. package/dist/assets/components/CADGeometry.js +33 -17
  5. package/dist/assets/components/CADGeometry.min.js +1 -1
  6. package/dist/assets/components/CubeMapTexturing.js +25 -25
  7. package/dist/assets/components/CubeMapTexturing.min.js +1 -1
  8. package/dist/assets/components/DIS.js +13 -13
  9. package/dist/assets/components/DIS.min.js +1 -1
  10. package/dist/assets/components/EventUtilities.js +9 -9
  11. package/dist/assets/components/EventUtilities.min.js +1 -1
  12. package/dist/assets/components/Geometry2D.js +20 -20
  13. package/dist/assets/components/Geometry2D.min.js +1 -1
  14. package/dist/assets/components/Geospatial.js +45 -60
  15. package/dist/assets/components/Geospatial.min.js +1 -1
  16. package/dist/assets/components/HAnim.js +37 -34
  17. package/dist/assets/components/HAnim.min.js +1 -1
  18. package/dist/assets/components/KeyDeviceSensor.js +8 -8
  19. package/dist/assets/components/KeyDeviceSensor.min.js +1 -1
  20. package/dist/assets/components/Layout.js +27 -27
  21. package/dist/assets/components/Layout.min.js +1 -1
  22. package/dist/assets/components/NURBS.js +23 -23
  23. package/dist/assets/components/NURBS.min.js +1 -1
  24. package/dist/assets/components/ParticleSystems.js +107 -155
  25. package/dist/assets/components/ParticleSystems.min.js +1 -1
  26. package/dist/assets/components/Picking.js +18 -18
  27. package/dist/assets/components/Picking.min.js +1 -1
  28. package/dist/assets/components/RigidBodyPhysics.js +17 -17
  29. package/dist/assets/components/RigidBodyPhysics.min.js +1 -1
  30. package/dist/assets/components/Scripting.js +38 -38
  31. package/dist/assets/components/Scripting.min.js +1 -1
  32. package/dist/assets/components/Text.js +24 -24
  33. package/dist/assets/components/Text.min.js +1 -1
  34. package/dist/assets/components/TextureProjection.js +15 -15
  35. package/dist/assets/components/TextureProjection.min.js +1 -1
  36. package/dist/assets/components/Texturing3D.js +28 -28
  37. package/dist/assets/components/Texturing3D.min.js +1 -1
  38. package/dist/assets/components/VolumeRendering.js +19 -19
  39. package/dist/assets/components/VolumeRendering.min.js +1 -1
  40. package/dist/assets/components/X_ITE.js +303 -8
  41. package/dist/assets/components/X_ITE.min.js +1 -1
  42. package/dist/x_ite.css +1 -1
  43. package/dist/x_ite.js +1517 -1097
  44. package/dist/x_ite.min.js +1 -1
  45. package/dist/x_ite.min.mjs +1 -1
  46. package/dist/x_ite.mjs +1517 -1097
  47. package/dist/x_ite.zip +0 -0
  48. package/package.json +3 -2
package/dist/x_ite.mjs CHANGED
@@ -1,9 +1,9 @@
1
- /* X_ITE v9.4.5 */var __webpack_modules__ = ({
1
+ /* X_ITE v9.5.0 */var __webpack_modules__ = ({
2
2
 
3
- /***/ 405:
3
+ /***/ 543:
4
4
  /***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => {
5
5
 
6
- /* provided dependency */ var jQuery = __webpack_require__(349);
6
+ /* provided dependency */ var jQuery = __webpack_require__(275);
7
7
  /**
8
8
  * @preserve jquery.fullscreen 1.1.5
9
9
  * https://github.com/code-lts/jquery-fullscreen-plugin
@@ -199,7 +199,7 @@ installFullScreenHandlers();
199
199
 
200
200
  /***/ }),
201
201
 
202
- /***/ 5:
202
+ /***/ 419:
203
203
  /***/ ((module, exports, __webpack_require__) => {
204
204
 
205
205
  var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
@@ -213,7 +213,7 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
213
213
  (function (factory) {
214
214
  if ( true ) {
215
215
  // AMD. Register as an anonymous module.
216
- !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(349)], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory),
216
+ !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(275)], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory),
217
217
  __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ?
218
218
  (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__),
219
219
  __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
@@ -424,7 +424,7 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
424
424
 
425
425
  /***/ }),
426
426
 
427
- /***/ 349:
427
+ /***/ 275:
428
428
  /***/ (function(module, exports) {
429
429
 
430
430
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
@@ -11148,7 +11148,7 @@ return jQuery;
11148
11148
 
11149
11149
  /***/ }),
11150
11150
 
11151
- /***/ 94:
11151
+ /***/ 224:
11152
11152
  /***/ ((module) => {
11153
11153
 
11154
11154
  /**
@@ -15927,7 +15927,7 @@ if (true) {
15927
15927
 
15928
15928
  /***/ }),
15929
15929
 
15930
- /***/ 929:
15930
+ /***/ 35:
15931
15931
  /***/ (function(__unused_webpack_module, exports) {
15932
15932
 
15933
15933
 
@@ -19172,7 +19172,7 @@ if (true) {
19172
19172
 
19173
19173
  /***/ }),
19174
19174
 
19175
- /***/ 886:
19175
+ /***/ 964:
19176
19176
  /***/ (function(module, exports) {
19177
19177
 
19178
19178
  var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*
@@ -20299,7 +20299,7 @@ Object .defineProperty (Namespace, "add",
20299
20299
  }
20300
20300
  else
20301
20301
  {
20302
- const X3D = window [Symbol .for ("X_ITE.X3D-9.4.5")];
20302
+ const X3D = window [Symbol .for ("X_ITE.X3D-9.5.0")];
20303
20303
 
20304
20304
  if (X3D)
20305
20305
  X3D [name] = module;
@@ -23409,6 +23409,9 @@ Object .assign (Color3 .prototype,
23409
23409
  },
23410
23410
  });
23411
23411
 
23412
+ for (const key of Object .keys (Color3 .prototype))
23413
+ Object .defineProperty (Color3 .prototype, key, { enumerable: false });
23414
+
23412
23415
  const r = {
23413
23416
  get () { return this [_r]; },
23414
23417
  set (value) { this [_r] = clamp (value, 0, 1); },
@@ -23863,6 +23866,9 @@ Object .assign (Color4 .prototype,
23863
23866
  },
23864
23867
  });
23865
23868
 
23869
+ for (const key of Object .keys (Color4 .prototype))
23870
+ Object .defineProperty (Color4 .prototype, key, { enumerable: false });
23871
+
23866
23872
  const Numbers_Color4_r = {
23867
23873
  get () { return this [Color4_r]; },
23868
23874
  set (value) { this [Color4_r] = Color4_clamp (value, 0, 1); },
@@ -24907,6 +24913,9 @@ Object .assign (Vector2 .prototype,
24907
24913
  }
24908
24914
  });
24909
24915
 
24916
+ for (const key of Object .keys (Vector2 .prototype))
24917
+ Object .defineProperty (Vector2 .prototype, key, { enumerable: false });
24918
+
24910
24919
  Object .defineProperties (Vector2 .prototype,
24911
24920
  {
24912
24921
  length: { value: 2 },
@@ -25198,6 +25207,9 @@ Object .assign (Vector3 .prototype,
25198
25207
  }
25199
25208
  });
25200
25209
 
25210
+ for (const key of Object .keys (Vector3 .prototype))
25211
+ Object .defineProperty (Vector3 .prototype, key, { enumerable: false });
25212
+
25201
25213
  Object .defineProperties (Vector3 .prototype,
25202
25214
  {
25203
25215
  length: { value: 3 },
@@ -25466,6 +25478,9 @@ Object .assign (Matrix2 .prototype,
25466
25478
  },
25467
25479
  });
25468
25480
 
25481
+ for (const key of Object .keys (Matrix2 .prototype))
25482
+ Object .defineProperty (Matrix2 .prototype, key, { enumerable: false });
25483
+
25469
25484
  Object .defineProperties (Matrix2 .prototype,
25470
25485
  {
25471
25486
  order: { value: 2 },
@@ -26284,6 +26299,9 @@ Object .assign (Matrix3 .prototype,
26284
26299
  },
26285
26300
  });
26286
26301
 
26302
+ for (const key of Object .keys (Matrix3 .prototype))
26303
+ Object .defineProperty (Matrix3 .prototype, key, { enumerable: false });
26304
+
26287
26305
  Object .defineProperties (Matrix3 .prototype,
26288
26306
  {
26289
26307
  order: { value: 3 },
@@ -26817,6 +26835,9 @@ Object .assign (Vector4 .prototype,
26817
26835
  },
26818
26836
  });
26819
26837
 
26838
+ for (const key of Object .keys (Vector4 .prototype))
26839
+ Object .defineProperty (Vector4 .prototype, key, { enumerable: false });
26840
+
26820
26841
  Object .defineProperties (Vector4 .prototype,
26821
26842
  {
26822
26843
  length: { value: 4 },
@@ -27435,6 +27456,9 @@ Object .assign (Quaternion .prototype,
27435
27456
  },
27436
27457
  });
27437
27458
 
27459
+ for (const key of Object .keys (Quaternion .prototype))
27460
+ Object .defineProperty (Quaternion .prototype, key, { enumerable: false });
27461
+
27438
27462
  Object .defineProperties (Quaternion .prototype,
27439
27463
  {
27440
27464
  length: { value: 4 },
@@ -27945,6 +27969,9 @@ Object .assign (Rotation4 .prototype,
27945
27969
  }
27946
27970
  });
27947
27971
 
27972
+ for (const key of Object .keys (Rotation4 .prototype))
27973
+ Object .defineProperty (Rotation4 .prototype, key, { enumerable: false });
27974
+
27948
27975
  const x = {
27949
27976
  get ()
27950
27977
  {
@@ -28717,6 +28744,9 @@ Object .assign (Matrix4_Matrix4 .prototype,
28717
28744
  },
28718
28745
  });
28719
28746
 
28747
+ for (const key of Object .keys (Matrix4_Matrix4 .prototype))
28748
+ Object .defineProperty (Matrix4_Matrix4 .prototype, key, { enumerable: false });
28749
+
28720
28750
  Object .defineProperties (Matrix4_Matrix4 .prototype,
28721
28751
  {
28722
28752
  order: { value: 4 },
@@ -34236,7 +34266,7 @@ const X3DBaseNode_default_ = X3DBaseNode;
34236
34266
  x_ite_Namespace .add ("X3DBaseNode", "x_ite/Base/X3DBaseNode", X3DBaseNode_default_);
34237
34267
  /* harmony default export */ const Base_X3DBaseNode = (X3DBaseNode_default_);
34238
34268
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Legacy.js
34239
- /* provided dependency */ var $ = __webpack_require__(349);
34269
+ /* provided dependency */ var $ = __webpack_require__(275);
34240
34270
  /*******************************************************************************
34241
34271
  *
34242
34272
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -34373,7 +34403,7 @@ x_ite_Namespace .add ("Legacy", "x_ite/Browser/Legacy", Legacy_default_);
34373
34403
  *
34374
34404
  ******************************************************************************/
34375
34405
 
34376
- const BROWSER_VERSION_default_ = "9.4.5";
34406
+ const BROWSER_VERSION_default_ = "9.5.0";
34377
34407
  ;
34378
34408
 
34379
34409
  x_ite_Namespace .add ("BROWSER_VERSION", "x_ite/BROWSER_VERSION", BROWSER_VERSION_default_);
@@ -34777,6 +34807,22 @@ Object .assign (Object .setPrototypeOf (X3DNode .prototype, Base_X3DBaseNode .pr
34777
34807
 
34778
34808
  return field;
34779
34809
  }
34810
+ else if (field)
34811
+ {
34812
+ // Support for Numbers (Vector234, Color34, ...).
34813
+
34814
+ if (!metadataObject)
34815
+ return field;
34816
+
34817
+ const value = metadataObject .value;
34818
+
34819
+ let i = 0;
34820
+
34821
+ for (const key in field)
34822
+ field [key] = value [i ++];
34823
+
34824
+ return field;
34825
+ }
34780
34826
 
34781
34827
  return metadataObject ? Array .from (metadataObject .value) : [ ];
34782
34828
  },
@@ -34871,6 +34917,13 @@ Object .assign (Object .setPrototypeOf (X3DNode .prototype, Base_X3DBaseNode .pr
34871
34917
  break;
34872
34918
  }
34873
34919
  }
34920
+ else if (!Array .isArray (value) && value .valueOf () instanceof Object)
34921
+ {
34922
+ // Support for Numbers (Vector234, Color34, ...).
34923
+
34924
+ value = Array .from (value);
34925
+ value .type = "double";
34926
+ }
34874
34927
 
34875
34928
  metadataSet .getValue () .setMetaValue (last, value);
34876
34929
 
@@ -36835,7 +36888,7 @@ Object .assign (Object .setPrototypeOf (MetadataSet .prototype, Core_X3DNode .pr
36835
36888
  setMetaValue (name, value)
36836
36889
  {
36837
36890
  if (!Array .isArray (value))
36838
- value = [value];
36891
+ value = [value .valueOf ()];
36839
36892
 
36840
36893
  switch (value .type ?? (typeof value [0]))
36841
36894
  {
@@ -36845,14 +36898,6 @@ Object .assign (Object .setPrototypeOf (MetadataSet .prototype, Core_X3DNode .pr
36845
36898
  return;
36846
36899
  }
36847
36900
  case "number":
36848
- {
36849
- if (value .every (v => Number .isInteger (v)))
36850
- this .getMetadataObject ("MetadataInteger", name, true) .value = value;
36851
- else
36852
- this .getMetadataObject ("MetadataDouble", name, true) .value = value;
36853
-
36854
- return;
36855
- }
36856
36901
  case "double":
36857
36902
  {
36858
36903
  this .getMetadataObject ("MetadataDouble", name, true) .value = value;
@@ -38014,8 +38059,8 @@ function X3DUrlObject (executionContext)
38014
38059
  {
38015
38060
  this .addType (Base_X3DConstants .X3DUrlObject);
38016
38061
 
38017
- this .addChildObjects (Base_X3DConstants .outputOnly, "loadState", new x_ite_Fields .SFInt32 (Base_X3DConstants .NOT_STARTED_STATE),
38018
- Base_X3DConstants .inputOutput, "loadData", new x_ite_Fields .SFTime ());
38062
+ this .addChildObjects (Base_X3DConstants .outputOnly, "loadState", new x_ite_Fields .SFInt32 (Base_X3DConstants .NOT_STARTED_STATE),
38063
+ Base_X3DConstants .outputOnly, "loadData", new x_ite_Fields .SFTime ());
38019
38064
 
38020
38065
  this [X3DUrlObject_cache] = true;
38021
38066
  this [_autoRefreshStartTime] = Date .now ();
@@ -38970,7 +39015,7 @@ const X3DProtoDeclaration_default_ = X3DProtoDeclaration;
38970
39015
  x_ite_Namespace .add ("X3DProtoDeclaration", "x_ite/Prototype/X3DProtoDeclaration", X3DProtoDeclaration_default_);
38971
39016
  /* harmony default export */ const Prototype_X3DProtoDeclaration = (X3DProtoDeclaration_default_);
38972
39017
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/X3DParser.js
38973
- /* provided dependency */ var X3DParser_$ = __webpack_require__(349);
39018
+ /* provided dependency */ var X3DParser_$ = __webpack_require__(275);
38974
39019
  /*******************************************************************************
38975
39020
  *
38976
39021
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39232,7 +39277,7 @@ const Expressions_default_ = Expressions;
39232
39277
  x_ite_Namespace .add ("Expressions", "x_ite/Parser/Expressions", Expressions_default_);
39233
39278
  /* harmony default export */ const Parser_Expressions = (Expressions_default_);
39234
39279
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/VRMLParser.js
39235
- /* provided dependency */ var VRMLParser_$ = __webpack_require__(349);
39280
+ /* provided dependency */ var VRMLParser_$ = __webpack_require__(275);
39236
39281
  /*******************************************************************************
39237
39282
  *
39238
39283
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -41918,7 +41963,7 @@ const VRMLParser_default_ = VRMLParser;
41918
41963
  x_ite_Namespace .add ("VRMLParser", "x_ite/Parser/VRMLParser", VRMLParser_default_);
41919
41964
  /* harmony default export */ const Parser_VRMLParser = (VRMLParser_default_);
41920
41965
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/XMLParser.js
41921
- /* provided dependency */ var XMLParser_$ = __webpack_require__(349);
41966
+ /* provided dependency */ var XMLParser_$ = __webpack_require__(275);
41922
41967
  /*******************************************************************************
41923
41968
  *
41924
41969
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -44027,7 +44072,7 @@ const URLs_default_ = URLs;
44027
44072
  x_ite_Namespace .add ("URLs", "x_ite/Browser/Networking/URLs", URLs_default_);
44028
44073
  /* harmony default export */ const Networking_URLs = (URLs_default_);
44029
44074
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/GLTF2Parser.js
44030
- /* provided dependency */ var GLTF2Parser_$ = __webpack_require__(349);
44075
+ /* provided dependency */ var GLTF2Parser_$ = __webpack_require__(275);
44031
44076
  /*******************************************************************************
44032
44077
  *
44033
44078
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -44323,6 +44368,15 @@ Object .assign (Object .setPrototypeOf (GLTF2Parser .prototype, Parser_X3DParser
44323
44368
  // {
44324
44369
  // break;
44325
44370
  // },
44371
+ case "EXT_mesh_gpu_instancing":
44372
+ {
44373
+ const component = browser .getComponent ("X_ITE", 1);
44374
+
44375
+ if (!scene .hasComponent (component))
44376
+ scene .addComponent (component);
44377
+
44378
+ break;
44379
+ }
44326
44380
  case "KHR_texture_transform":
44327
44381
  {
44328
44382
  const component = browser .getComponent ("Texturing3D", 2);
@@ -45267,7 +45321,7 @@ Object .assign (Object .setPrototypeOf (GLTF2Parser .prototype, Parser_X3DParser
45267
45321
 
45268
45322
  this .meshes = meshes;
45269
45323
  },
45270
- meshObject (mesh, skin)
45324
+ meshObject (mesh, skin, EXT_mesh_gpu_instancing)
45271
45325
  {
45272
45326
  if (!(mesh instanceof Object))
45273
45327
  return;
@@ -45285,7 +45339,7 @@ Object .assign (Object .setPrototypeOf (GLTF2Parser .prototype, Parser_X3DParser
45285
45339
  return mesh .shapeNodes;
45286
45340
  }
45287
45341
 
45288
- const shapeNodes = this .primitivesArray (mesh, skin);
45342
+ const shapeNodes = this .primitivesArray (mesh, skin, EXT_mesh_gpu_instancing);
45289
45343
 
45290
45344
  // Name Shape nodes.
45291
45345
 
@@ -45301,7 +45355,7 @@ Object .assign (Object .setPrototypeOf (GLTF2Parser .prototype, Parser_X3DParser
45301
45355
 
45302
45356
  return mesh .shapeNodes = shapeNodes;
45303
45357
  },
45304
- primitivesArray ({ primitives, weights }, skin)
45358
+ primitivesArray ({ primitives, weights }, skin, EXT_mesh_gpu_instancing)
45305
45359
  {
45306
45360
  if (!(primitives instanceof Array))
45307
45361
  return [ ];
@@ -45309,11 +45363,11 @@ Object .assign (Object .setPrototypeOf (GLTF2Parser .prototype, Parser_X3DParser
45309
45363
  const shapeNodes = [ ];
45310
45364
 
45311
45365
  for (const primitive of primitives)
45312
- this .primitiveObject (primitive, weights, skin, shapeNodes);
45366
+ this .primitiveObject (primitive, weights, skin, EXT_mesh_gpu_instancing, shapeNodes);
45313
45367
 
45314
45368
  return shapeNodes;
45315
45369
  },
45316
- primitiveObject (primitive, weights, skin, shapeNodes)
45370
+ primitiveObject (primitive, weights, skin, EXT_mesh_gpu_instancing, shapeNodes)
45317
45371
  {
45318
45372
  if (!(primitive instanceof Object))
45319
45373
  return;
@@ -45326,7 +45380,7 @@ Object .assign (Object .setPrototypeOf (GLTF2Parser .prototype, Parser_X3DParser
45326
45380
 
45327
45381
  this .primitiveExtensionsObject (primitive .extensions, primitive)
45328
45382
 
45329
- shapeNodes .push (primitive .shapeNode = this .createShape (primitive, weights, skin));
45383
+ shapeNodes .push (primitive .shapeNode = this .createShape (primitive, weights, skin, EXT_mesh_gpu_instancing));
45330
45384
  },
45331
45385
  attributesObject (attributes)
45332
45386
  {
@@ -45716,8 +45770,9 @@ Object .assign (Object .setPrototypeOf (GLTF2Parser .prototype, Parser_X3DParser
45716
45770
  // Add mesh.
45717
45771
 
45718
45772
  const
45719
- skin = this .skins [node .skin],
45720
- shapeNodes = this .meshObject (this .meshes [node .mesh], skin);
45773
+ skin = this .skins [node .skin],
45774
+ EXT_mesh_gpu_instancing = node .extensions ?.EXT_mesh_gpu_instancing,
45775
+ shapeNodes = this .meshObject (this .meshes [node .mesh], skin, EXT_mesh_gpu_instancing);
45721
45776
 
45722
45777
  // Add camera.
45723
45778
 
@@ -45737,7 +45792,7 @@ Object .assign (Object .setPrototypeOf (GLTF2Parser .prototype, Parser_X3DParser
45737
45792
  // Add Shape nodes.
45738
45793
 
45739
45794
  if (shapeNodes)
45740
- transformNode ._children .push (... this .meshInstancing (node .extensions ?.EXT_mesh_gpu_instancing, shapeNodes));
45795
+ transformNode ._children .push (... shapeNodes);
45741
45796
 
45742
45797
  transformNode .setup ();
45743
45798
 
@@ -45806,71 +45861,6 @@ Object .assign (Object .setPrototypeOf (GLTF2Parser .prototype, Parser_X3DParser
45806
45861
 
45807
45862
  transformNode ._children .push (lightNode);
45808
45863
  },
45809
- meshInstancing (EXT_mesh_gpu_instancing, shapeNodes)
45810
- {
45811
- if (!(EXT_mesh_gpu_instancing instanceof Object))
45812
- return shapeNodes;
45813
-
45814
- let
45815
- attributes = EXT_mesh_gpu_instancing .attributes,
45816
- translation = this .accessors [attributes ?.TRANSLATION],
45817
- rotation = this .accessors [attributes ?.ROTATION],
45818
- scale = this .accessors [attributes ?.SCALE],
45819
- count = Math .max (translation ?.count ?? 0, rotation ?.count ?? 0, scale ?.count ?? 0);
45820
-
45821
- if (!count)
45822
- return shapeNodes;
45823
-
45824
- if (translation ?.type !== "VEC3")
45825
- translation = null;
45826
-
45827
- if (rotation ?.type !== "VEC4")
45828
- rotation = null;
45829
-
45830
- if (scale ?.type !== "VEC3")
45831
- scale = null;
45832
-
45833
- const
45834
- scene = this .getScene (),
45835
- transformNodes = [ ],
45836
- tArray = translation ?.array,
45837
- rArray = rotation ?.normalizedArray,
45838
- sArray = scale ?.array;
45839
-
45840
- for (let i = 0; i < count; ++ i)
45841
- {
45842
- const transformNode = scene .createNode ("Transform", false);
45843
-
45844
- if (translation && i < translation .count)
45845
- {
45846
- transformNode ._translation = new Numbers_Vector3 (tArray [i * 3 + 0],
45847
- tArray [i * 3 + 1],
45848
- tArray [i * 3 + 2]);
45849
- }
45850
-
45851
- if (rotation && i < rotation .count)
45852
- {
45853
- transformNode ._rotation = new Numbers_Rotation4 (new Numbers_Quaternion (rArray [i * 4 + 0],
45854
- rArray [i * 4 + 1],
45855
- rArray [i * 4 + 2],
45856
- rArray [i * 4 + 3]));
45857
- }
45858
-
45859
- if (scale && i < scale .count)
45860
- {
45861
- transformNode ._scale = new Numbers_Vector3 (sArray [i * 3 + 0],
45862
- sArray [i * 3 + 1],
45863
- sArray [i * 3 + 2]);
45864
- }
45865
-
45866
- transformNode ._children = shapeNodes;
45867
-
45868
- transformNode .setup ();
45869
- transformNodes .push (transformNode);
45870
- }
45871
-
45872
- return transformNodes;
45873
- },
45874
45864
  nodeChildrenArray (children)
45875
45865
  {
45876
45866
  if (!(children instanceof Array))
@@ -46174,11 +46164,11 @@ Object .assign (Object .setPrototypeOf (GLTF2Parser .prototype, Parser_X3DParser
46174
46164
 
46175
46165
  return navigationInfoNode;
46176
46166
  },
46177
- createShape (primitive, weights, skin)
46167
+ createShape (primitive, weights, skin, EXT_mesh_gpu_instancing)
46178
46168
  {
46179
46169
  const
46180
46170
  scene = this .getExecutionContext (),
46181
- shapeNode = scene .createNode ("Shape", false),
46171
+ shapeNode = this .meshInstancing (EXT_mesh_gpu_instancing) ?? scene .createNode ("Shape", false),
46182
46172
  appearanceNode = this .materialObject (primitive),
46183
46173
  geometryNode = this .createGeometry (primitive, weights, skin);
46184
46174
 
@@ -46189,6 +46179,60 @@ Object .assign (Object .setPrototypeOf (GLTF2Parser .prototype, Parser_X3DParser
46189
46179
 
46190
46180
  return shapeNode;
46191
46181
  },
46182
+ meshInstancing (EXT_mesh_gpu_instancing)
46183
+ {
46184
+ if (!(EXT_mesh_gpu_instancing instanceof Object))
46185
+ return null;
46186
+
46187
+ let
46188
+ attributes = EXT_mesh_gpu_instancing .attributes,
46189
+ translation = this .accessors [attributes ?.TRANSLATION],
46190
+ rotation = this .accessors [attributes ?.ROTATION],
46191
+ scale = this .accessors [attributes ?.SCALE],
46192
+ count = Math .max (translation ?.count ?? 0, rotation ?.count ?? 0, scale ?.count ?? 0);
46193
+
46194
+ if (!count)
46195
+ return null;
46196
+
46197
+ if (translation ?.type !== "VEC3")
46198
+ translation = null;
46199
+
46200
+ if (rotation ?.type !== "VEC4")
46201
+ rotation = null;
46202
+
46203
+ if (scale ?.type !== "VEC3")
46204
+ scale = null;
46205
+
46206
+ const
46207
+ scene = this .getScene (),
46208
+ instancedShapeNode = scene .createNode ("InstancedShape", false),
46209
+ translationArray = translation ?.array,
46210
+ rotationArray = rotation ?.normalizedArray,
46211
+ scaleArray = scale ?.array;
46212
+
46213
+ if (translationArray)
46214
+ instancedShapeNode ._translations = translationArray;
46215
+
46216
+ if (rotationArray)
46217
+ {
46218
+ const length = rotation .count * 4;
46219
+
46220
+ for (let i = 0; i < length; i += 4)
46221
+ {
46222
+ instancedShapeNode ._rotations .push (new Numbers_Rotation4 (new Numbers_Quaternion (rotationArray [i + 0],
46223
+ rotationArray [i + 1],
46224
+ rotationArray [i + 2],
46225
+ rotationArray [i + 3])));
46226
+ }
46227
+ }
46228
+
46229
+ if (scaleArray)
46230
+ instancedShapeNode ._scales = scaleArray;
46231
+
46232
+ instancedShapeNode .setup ();
46233
+
46234
+ return instancedShapeNode;
46235
+ },
46192
46236
  getDefaultAppearance (mode)
46193
46237
  {
46194
46238
  mode = mode > 3;
@@ -47330,7 +47374,7 @@ const GLTF2Parser_default_ = GLTF2Parser;
47330
47374
  x_ite_Namespace .add ("GLTF2Parser", "x_ite/Parser/GLTF2Parser", GLTF2Parser_default_);
47331
47375
  /* harmony default export */ const Parser_GLTF2Parser = (GLTF2Parser_default_);
47332
47376
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/GLB2Parser.js
47333
- /* provided dependency */ var GLB2Parser_$ = __webpack_require__(349);
47377
+ /* provided dependency */ var GLB2Parser_$ = __webpack_require__(275);
47334
47378
  /*******************************************************************************
47335
47379
  *
47336
47380
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -47482,7 +47526,7 @@ const GLB2Parser_default_ = GLB2Parser;
47482
47526
  x_ite_Namespace .add ("GLB2Parser", "x_ite/Parser/GLB2Parser", GLB2Parser_default_);
47483
47527
  /* harmony default export */ const Parser_GLB2Parser = (GLB2Parser_default_);
47484
47528
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/OBJParser.js
47485
- /* provided dependency */ var OBJParser_$ = __webpack_require__(349);
47529
+ /* provided dependency */ var OBJParser_$ = __webpack_require__(275);
47486
47530
  /*******************************************************************************
47487
47531
  *
47488
47532
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -50144,6 +50188,9 @@ Object .assign (Complex .prototype,
50144
50188
  },
50145
50189
  });
50146
50190
 
50191
+ for (const key of Object .keys (Complex .prototype))
50192
+ Object .defineProperty (Complex .prototype, key, { enumerable: false });
50193
+
50147
50194
  Object .defineProperties (Complex .prototype,
50148
50195
  {
50149
50196
  length: { value: 2 },
@@ -50837,8 +50884,8 @@ const MatrixStack_default_ = MatrixStack;
50837
50884
  x_ite_Namespace .add ("MatrixStack", "standard/Math/Utility/MatrixStack", MatrixStack_default_);
50838
50885
  /* harmony default export */ const Utility_MatrixStack = (MatrixStack_default_);
50839
50886
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/SVGParser.js
50840
- /* provided dependency */ var SVGParser_$ = __webpack_require__(349);
50841
- /* provided dependency */ var libtess = __webpack_require__(94);
50887
+ /* provided dependency */ var SVGParser_$ = __webpack_require__(275);
50888
+ /* provided dependency */ var libtess = __webpack_require__(224);
50842
50889
  /*******************************************************************************
50843
50890
  *
50844
50891
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53606,7 +53653,7 @@ const SVGParser_default_ = SVGParser;
53606
53653
  x_ite_Namespace .add ("SVGParser", "x_ite/Parser/SVGParser", SVGParser_default_);
53607
53654
  /* harmony default export */ const Parser_SVGParser = (SVGParser_default_);
53608
53655
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/GoldenGate.js
53609
- /* provided dependency */ var GoldenGate_$ = __webpack_require__(349);
53656
+ /* provided dependency */ var GoldenGate_$ = __webpack_require__(275);
53610
53657
  /*******************************************************************************
53611
53658
  *
53612
53659
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53956,7 +54003,7 @@ const Plane3_default_ = Plane3;
53956
54003
  x_ite_Namespace .add ("Plane3", "standard/Math/Geometry/Plane3", Plane3_default_);
53957
54004
  /* harmony default export */ const Geometry_Plane3 = (Plane3_default_);
53958
54005
  ;// CONCATENATED MODULE: ./src/standard/Math/Geometry/Triangle3.js
53959
- /* provided dependency */ var Triangle3_libtess = __webpack_require__(94);
54006
+ /* provided dependency */ var Triangle3_libtess = __webpack_require__(224);
53960
54007
  /*******************************************************************************
53961
54008
  *
53962
54009
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56604,34 +56651,36 @@ Object .assign (X3DRenderObject .prototype,
56604
56651
  {
56605
56652
  return this .shadowShapes;
56606
56653
  },
56607
- setNumOpaqueShapes (value)
56608
- {
56609
- this .numOpaqueShapes = value;
56610
- },
56611
56654
  getNumOpaqueShapes ()
56612
56655
  {
56613
56656
  return this .numOpaqueShapes;
56614
56657
  },
56615
- getOpaqueShapes ()
56658
+ setNumOpaqueShapes (value)
56616
56659
  {
56617
- return this .opaqueShapes;
56660
+ // Needed for StaticGroup.
56661
+ this .numOpaqueShapes = value;
56618
56662
  },
56619
- setNumTransparentShapes (value)
56663
+ getOpaqueShapes ()
56620
56664
  {
56621
- this .numTransparentShapes = value;
56665
+ return this .opaqueShapes;
56622
56666
  },
56623
56667
  getNumTransparentShapes ()
56624
56668
  {
56625
56669
  return this .numTransparentShapes;
56626
56670
  },
56671
+ setNumTransparentShapes (value)
56672
+ {
56673
+ // Needed for StaticGroup.
56674
+ this .numTransparentShapes = value;
56675
+ },
56627
56676
  getTransparentShapes ()
56628
56677
  {
56629
56678
  return this .transparentShapes;
56630
56679
  },
56631
56680
  constrainTranslation (translation, stepBack)
56632
56681
  {
56633
- /// Contrains @a translation to a possible value the avatar can move. If the avatar reaches and intersects with an
56634
- /// and obstacle and @a stepBack is true a translation in the opposite directiion is returned. Future implementation will
56682
+ /// Constrains @a translation to a possible value the avatar can move. If the avatar reaches and intersects with an
56683
+ /// and obstacle and @a stepBack is true a translation in the opposite direction is returned. Future implementation will
56635
56684
  /// will then return a value where the avatar slides along the wall. Modifies translation in place.
56636
56685
 
56637
56686
  // Constrain translation when the viewer collides with an obstacle.
@@ -60769,8 +60818,8 @@ Object .assign (Object .setPrototypeOf (X3DGeometryNode .prototype, Core_X3DNode
60769
60818
 
60770
60819
  delete this .displaySimple;
60771
60820
  delete this .display;
60772
- delete this .displaySimpleParticles;
60773
- delete this .displayParticles;
60821
+ delete this .displaySimpleInstanced;
60822
+ delete this .displayInstanced;
60774
60823
  }
60775
60824
  else
60776
60825
  {
@@ -60778,8 +60827,8 @@ Object .assign (Object .setPrototypeOf (X3DGeometryNode .prototype, Core_X3DNode
60778
60827
 
60779
60828
  this .displaySimple = Function .prototype;
60780
60829
  this .display = Function .prototype;
60781
- this .displaySimpleParticles = Function .prototype;
60782
- this .displayParticles = Function .prototype;
60830
+ this .displaySimpleInstanced = Function .prototype;
60831
+ this .displayInstanced = Function .prototype;
60783
60832
  }
60784
60833
  },
60785
60834
  traverse (type, renderObject)
@@ -60908,26 +60957,32 @@ Object .assign (Object .setPrototypeOf (X3DGeometryNode .prototype, Core_X3DNode
60908
60957
  for (const node of renderModeNodes)
60909
60958
  node .disable (gl);
60910
60959
  },
60911
- displaySimpleParticles (gl, shaderNode, particleSystem)
60960
+ displaySimpleInstanced (gl, shaderNode, shapeNode)
60912
60961
  {
60913
- const outputParticles = particleSystem .outputParticles;
60962
+ const instances = shapeNode .getInstances ();
60914
60963
 
60915
- if (outputParticles .vertexArrayObject .update (this .updateParticles) .enable (shaderNode .getProgram ()))
60964
+ if (instances .vertexArrayObject .update (this .updateParticles) .enable (shaderNode .getProgram ()))
60916
60965
  {
60917
- const { particleStride, particleOffset, matrixOffset } = particleSystem;
60966
+ const { instancesStride, particleOffset, matrixOffset, normalMatrixOffset } = shapeNode;
60967
+
60968
+ if (particleOffset !== undefined)
60969
+ shaderNode .enableParticleAttribute (gl, instances, instancesStride, particleOffset, 1);
60918
60970
 
60919
- shaderNode .enableParticleAttribute (gl, outputParticles, particleStride, particleOffset, 1);
60920
- shaderNode .enableParticleMatrixAttribute (gl, outputParticles, particleStride, matrixOffset, 1);
60921
- shaderNode .enableTexCoordAttribute (gl, this .texCoordBuffers, 0, 0);
60922
- shaderNode .enableNormalAttribute (gl, this .normalBuffer, 0, 0);
60923
- shaderNode .enableVertexAttribute (gl, this .vertexBuffer, 0, 0);
60971
+ shaderNode .enableInstanceMatrixAttribute (gl, instances, instancesStride, matrixOffset, 1);
60972
+
60973
+ if (normalMatrixOffset !== undefined)
60974
+ shaderNode .enableInstanceNormalMatrixAttribute (gl, instances, instancesStride, normalMatrixOffset, 1);
60975
+
60976
+ shaderNode .enableTexCoordAttribute (gl, this .texCoordBuffers, 0, 0);
60977
+ shaderNode .enableNormalAttribute (gl, this .normalBuffer, 0, 0);
60978
+ shaderNode .enableVertexAttribute (gl, this .vertexBuffer, 0, 0);
60924
60979
 
60925
60980
  this .updateParticles = false;
60926
60981
  }
60927
60982
 
60928
- gl .drawArraysInstanced (this .primitiveMode, 0, this .vertexCount, particleSystem .numParticles);
60983
+ gl .drawArraysInstanced (this .primitiveMode, 0, this .vertexCount, shapeNode .getNumInstances ());
60929
60984
  },
60930
- displayParticles (gl, renderContext, particleSystem)
60985
+ displayInstanced (gl, renderContext, shapeNode)
60931
60986
  {
60932
60987
  const
60933
60988
  browser = this .getBrowser (),
@@ -60936,17 +60991,17 @@ Object .assign (Object .setPrototypeOf (X3DGeometryNode .prototype, Core_X3DNode
60936
60991
 
60937
60992
  if (this .solid || !appearanceNode .getBackMaterial () || browser .getWireframe ())
60938
60993
  {
60939
- this .displayParticlesGeometry (gl, renderContext, appearanceNode, shaderNode, true, true, particleSystem);
60994
+ this .displayInstancedGeometry (gl, renderContext, appearanceNode, shaderNode, true, true, shapeNode);
60940
60995
  }
60941
60996
  else
60942
60997
  {
60943
60998
  const backShaderNode = appearanceNode .getBackShader (this, renderContext);
60944
60999
 
60945
- this .displayParticlesGeometry (gl, renderContext, appearanceNode, backShaderNode, true, false, particleSystem);
60946
- this .displayParticlesGeometry (gl, renderContext, appearanceNode, shaderNode, false, true, particleSystem);
61000
+ this .displayInstancedGeometry (gl, renderContext, appearanceNode, backShaderNode, true, false, shapeNode);
61001
+ this .displayInstancedGeometry (gl, renderContext, appearanceNode, shaderNode, false, true, shapeNode);
60947
61002
  }
60948
61003
  },
60949
- displayParticlesGeometry (gl, renderContext, appearanceNode, shaderNode, back, front, particleSystem)
61004
+ displayInstancedGeometry (gl, renderContext, appearanceNode, shaderNode, back, front, shapeNode)
60950
61005
  {
60951
61006
  const
60952
61007
  browser = this .getBrowser (),
@@ -60965,14 +61020,19 @@ Object .assign (Object .setPrototypeOf (X3DGeometryNode .prototype, Core_X3DNode
60965
61020
 
60966
61021
  // Setup vertex attributes.
60967
61022
 
60968
- const outputParticles = particleSystem .outputParticles;
61023
+ const instances = shapeNode .getInstances ();
60969
61024
 
60970
- if (outputParticles .vertexArrayObject .update (this .updateParticles) .enable (shaderNode .getProgram ()))
61025
+ if (instances .vertexArrayObject .update (this .updateParticles) .enable (shaderNode .getProgram ()))
60971
61026
  {
60972
- const { particleStride, particleOffset, matrixOffset } = particleSystem;
61027
+ const { instancesStride, particleOffset, matrixOffset, normalMatrixOffset } = shapeNode;
60973
61028
 
60974
- shaderNode .enableParticleAttribute (gl, outputParticles, particleStride, particleOffset, 1);
60975
- shaderNode .enableParticleMatrixAttribute (gl, outputParticles, particleStride, matrixOffset, 1);
61029
+ if (particleOffset !== undefined)
61030
+ shaderNode .enableParticleAttribute (gl, instances, instancesStride, particleOffset, 1);
61031
+
61032
+ shaderNode .enableInstanceMatrixAttribute (gl, instances, instancesStride, matrixOffset, 1);
61033
+
61034
+ if (normalMatrixOffset !== undefined)
61035
+ shaderNode .enableInstanceNormalMatrixAttribute (gl, instances, instancesStride, normalMatrixOffset, 1);
60976
61036
 
60977
61037
  for (let i = 0, length = attribNodes .length; i < length; ++ i)
60978
61038
  attribNodes [i] .enable (gl, shaderNode, attribBuffers [i]);
@@ -61005,13 +61065,13 @@ Object .assign (Object .setPrototypeOf (X3DGeometryNode .prototype, Core_X3DNode
61005
61065
  if (back && !this .solid)
61006
61066
  {
61007
61067
  gl .cullFace (gl .FRONT);
61008
- gl .drawArraysInstanced (primitiveMode, 0, this .vertexCount, particleSystem .numParticles);
61068
+ gl .drawArraysInstanced (primitiveMode, 0, this .vertexCount, shapeNode .getNumInstances ());
61009
61069
  }
61010
61070
 
61011
61071
  if (front)
61012
61072
  {
61013
61073
  gl .cullFace (gl .BACK);
61014
- gl .drawArraysInstanced (primitiveMode, 0, this .vertexCount, particleSystem .numParticles);
61074
+ gl .drawArraysInstanced (primitiveMode, 0, this .vertexCount, shapeNode .getNumInstances ());
61015
61075
  }
61016
61076
  }
61017
61077
  else
@@ -61023,7 +61083,7 @@ Object .assign (Object .setPrototypeOf (X3DGeometryNode .prototype, Core_X3DNode
61023
61083
  else
61024
61084
  gl .disable (gl .CULL_FACE);
61025
61085
 
61026
- gl .drawArraysInstanced (primitiveMode, 0, this .vertexCount, particleSystem .numParticles);
61086
+ gl .drawArraysInstanced (primitiveMode, 0, this .vertexCount, shapeNode .getNumInstances ());
61027
61087
  }
61028
61088
 
61029
61089
  for (const node of renderModeNodes)
@@ -62449,7 +62509,7 @@ const X3DTexture2DNode_default_ = X3DTexture2DNode;
62449
62509
  x_ite_Namespace .add ("X3DTexture2DNode", "x_ite/Components/Texturing/X3DTexture2DNode", X3DTexture2DNode_default_);
62450
62510
  /* harmony default export */ const Texturing_X3DTexture2DNode = (X3DTexture2DNode_default_);
62451
62511
  ;// CONCATENATED MODULE: ./src/x_ite/Components/Texturing/ImageTexture.js
62452
- /* provided dependency */ var ImageTexture_$ = __webpack_require__(349);
62512
+ /* provided dependency */ var ImageTexture_$ = __webpack_require__(275);
62453
62513
  /*******************************************************************************
62454
62514
  *
62455
62515
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -64794,7 +64854,7 @@ function X3DViewpointNode (executionContext)
64794
64854
  Base_X3DConstants .inputOutput, "fieldOfViewScale", new x_ite_Fields .SFFloat (1));
64795
64855
 
64796
64856
  this .descriptions = [ ];
64797
- this .userPosition = new Numbers_Vector3 (0, 1, 0);
64857
+ this .userPosition = new Numbers_Vector3 ();
64798
64858
  this .userOrientation = new Numbers_Rotation4 ();
64799
64859
  this .userCenterOfRotation = new Numbers_Vector3 ();
64800
64860
  this .modelMatrix = new Numbers_Matrix4 ();
@@ -64875,10 +64935,10 @@ Object .assign (Object .setPrototypeOf (X3DViewpointNode .prototype, Core_X3DBin
64875
64935
  },
64876
64936
  set_viewAll__ ()
64877
64937
  {
64878
- if (! this ._viewAll .getValue ())
64938
+ if (!this ._viewAll .getValue ())
64879
64939
  return;
64880
64940
 
64881
- if (! this ._isBound .getValue ())
64941
+ if (!this ._isBound .getValue ())
64882
64942
  return;
64883
64943
 
64884
64944
  this ._set_bind = true;
@@ -65008,7 +65068,7 @@ Object .assign (Object .setPrototypeOf (X3DViewpointNode .prototype, Core_X3DBin
65008
65068
  {
65009
65069
  const relative = this .getRelativeTransformation (fromViewpointNode);
65010
65070
 
65011
- if (! this ._retainUserOffsets .getValue ())
65071
+ if (!this ._retainUserOffsets .getValue ())
65012
65072
  this .resetUserOffsets ();
65013
65073
 
65014
65074
  if (this ._viewAll .getValue ())
@@ -65432,6 +65492,10 @@ Object .assign (Object .setPrototypeOf (Viewpoint .prototype, Navigation_X3DView
65432
65492
 
65433
65493
  return fov > 0 && fov < Math .PI ? fov : Math .PI / 4;
65434
65494
  },
65495
+ setFieldOfView (value)
65496
+ {
65497
+ this ._fieldOfView = value;
65498
+ },
65435
65499
  getUserFieldOfView ()
65436
65500
  {
65437
65501
  const fov = this ._fieldOfView .getValue () * this ._fieldOfViewScale .getValue ();
@@ -66043,7 +66107,7 @@ const X3DWorld_default_ = X3DWorld;
66043
66107
  x_ite_Namespace .add ("X3DWorld", "x_ite/Execution/X3DWorld", X3DWorld_default_);
66044
66108
  /* harmony default export */ const Execution_X3DWorld = (X3DWorld_default_);
66045
66109
  ;// CONCATENATED MODULE: ./src/x_ite/InputOutput/FileLoader.js
66046
- /* provided dependency */ var FileLoader_$ = __webpack_require__(349);
66110
+ /* provided dependency */ var FileLoader_$ = __webpack_require__(275);
66047
66111
  /*******************************************************************************
66048
66112
  *
66049
66113
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -66979,7 +67043,7 @@ const ProtoDeclarationArray_default_ = ProtoDeclarationArray;
66979
67043
  x_ite_Namespace .add ("ProtoDeclarationArray", "x_ite/Prototype/ProtoDeclarationArray", ProtoDeclarationArray_default_);
66980
67044
  /* harmony default export */ const Prototype_ProtoDeclarationArray = (ProtoDeclarationArray_default_);
66981
67045
  ;// CONCATENATED MODULE: ./src/x_ite/Routing/X3DRoute.js
66982
- /* provided dependency */ var X3DRoute_$ = __webpack_require__(349);
67046
+ /* provided dependency */ var X3DRoute_$ = __webpack_require__(275);
66983
67047
  /*******************************************************************************
66984
67048
  *
66985
67049
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -67581,7 +67645,6 @@ x_ite_Namespace .add ("RouteArray", "x_ite/Routing/RouteArray", RouteArray_defau
67581
67645
 
67582
67646
 
67583
67647
 
67584
-
67585
67648
  const
67586
67649
  _outerNode = Symbol (),
67587
67650
  _namedNodes = Symbol (),
@@ -67597,18 +67660,22 @@ function X3DExecutionContext (executionContext, outerNode = null, browser = exec
67597
67660
  this .addType (Base_X3DConstants .X3DExecutionContext)
67598
67661
 
67599
67662
  this .addChildObjects (Base_X3DConstants .initializeOnly, "rootNodes", new x_ite_Fields .MFNode (),
67663
+ Base_X3DConstants .inputOutput, "countPrimitives", new x_ite_Fields .SFBool (true),
67600
67664
  Base_X3DConstants .outputOnly, "worldInfos", new x_ite_Fields .MFNode (),
67601
67665
  Base_X3DConstants .outputOnly, "sceneGraph_changed", new x_ite_Fields .SFTime ())
67602
67666
 
67603
67667
  this ._rootNodes .setPrivate (false);
67604
67668
  this ._rootNodes .collectCloneCount = () => 1;
67605
67669
 
67606
- this [_outerNode] = outerNode;
67607
- this [_namedNodes] = new Execution_NamedNodesArray ();
67608
- this [_importedNodes] = new Execution_ImportedNodesArray ();
67609
- this [_protos] = new Prototype_ProtoDeclarationArray ();
67610
- this [_externprotos] = new Prototype_ExternProtoDeclarationArray ();
67611
- this [X3DExecutionContext_routes] = new Routing_RouteArray ();
67670
+ this ._countPrimitives .addReference (executionContext ._countPrimitives);
67671
+ this ._sceneGraph_changed .addFieldInterest (this ._sceneGraph_changed);
67672
+
67673
+ this [_outerNode] = outerNode;
67674
+ this [_namedNodes] = new Execution_NamedNodesArray ();
67675
+ this [_importedNodes] = new Execution_ImportedNodesArray ();
67676
+ this [_protos] = new Prototype_ProtoDeclarationArray ();
67677
+ this [_externprotos] = new Prototype_ExternProtoDeclarationArray ();
67678
+ this [X3DExecutionContext_routes] = new Routing_RouteArray ();
67612
67679
 
67613
67680
  this [_namedNodes] .addParent (this);
67614
67681
  this [_importedNodes] .addParent (this);
@@ -67619,16 +67686,15 @@ function X3DExecutionContext (executionContext, outerNode = null, browser = exec
67619
67686
 
67620
67687
  Object .assign (Object .setPrototypeOf (X3DExecutionContext .prototype, Base_X3DBaseNode .prototype),
67621
67688
  {
67622
- initialize ()
67689
+ setExecutionContext (executionContext)
67623
67690
  {
67624
- Base_X3DBaseNode .prototype .initialize .call (this);
67691
+ this ._countPrimitives .removeReference (this .getExecutionContext () ._countPrimitives);
67692
+ this ._sceneGraph_changed .removeFieldInterest (this .getExecutionContext () ._sceneGraph_changed);
67625
67693
 
67626
- if (!this .isScene ())
67627
- this ._sceneGraph_changed .addInterest ("set_sceneGraph", this)
67628
- },
67629
- set_sceneGraph ()
67630
- {
67631
- this .getExecutionContext () ._sceneGraph_changed = this .getBrowser () .getCurrentTime ();
67694
+ Base_X3DBaseNode .prototype .setExecutionContext .call (this, executionContext);
67695
+
67696
+ this ._countPrimitives .addReference (executionContext ._countPrimitives);
67697
+ this ._sceneGraph_changed .addFieldInterest (executionContext ._sceneGraph_changed);
67632
67698
  },
67633
67699
  isScene ()
67634
67700
  {
@@ -67639,6 +67705,14 @@ Object .assign (Object .setPrototypeOf (X3DExecutionContext .prototype, Base_X3D
67639
67705
  // Can be either of type X3DProtoDeclaration or X3DPrototypeInstance, or null.
67640
67706
  return this [_outerNode];
67641
67707
  },
67708
+ getCountPrimitives ()
67709
+ {
67710
+ return this ._countPrimitives .getValue ();
67711
+ },
67712
+ setCountPrimitives (value)
67713
+ {
67714
+ this ._countPrimitives = this .getExecutionContext () .getCountPrimitives () && value;
67715
+ },
67642
67716
  getSpecificationVersion ()
67643
67717
  {
67644
67718
  return this .getExecutionContext () .getSpecificationVersion ();
@@ -67873,7 +67947,7 @@ Object .assign (Object .setPrototypeOf (X3DExecutionContext .prototype, Base_X3D
67873
67947
 
67874
67948
  this [_importedNodes] .add (importedName, importedNode);
67875
67949
 
67876
- this ._importedNodes_changed = this .getBrowser () .getCurrentTime ();
67950
+ this ._sceneGraph_changed = this .getBrowser () .getCurrentTime ();
67877
67951
  },
67878
67952
  renameImportedNode (oldImportedName, newImportedName)
67879
67953
  {
@@ -67888,6 +67962,8 @@ Object .assign (Object .setPrototypeOf (X3DExecutionContext .prototype, Base_X3D
67888
67962
  importedNode [Symbol .for ("X_ITE.X3DImportedNode.setImportName")] (newImportedName);
67889
67963
 
67890
67964
  this [_importedNodes] .update (oldImportedName, newImportedName, importedNode);
67965
+
67966
+ this ._sceneGraph_changed = this .getBrowser () .getCurrentTime ();
67891
67967
  },
67892
67968
  removeImportedNode (importedName)
67893
67969
  {
@@ -67902,7 +67978,7 @@ Object .assign (Object .setPrototypeOf (X3DExecutionContext .prototype, Base_X3D
67902
67978
 
67903
67979
  this [_importedNodes] .remove (importedName);
67904
67980
 
67905
- this ._importedNodes_changed = this .getBrowser () .getCurrentTime ();
67981
+ this ._sceneGraph_changed = this .getBrowser () .getCurrentTime ();
67906
67982
  },
67907
67983
  getImportedNode (importedName)
67908
67984
  {
@@ -68003,7 +68079,7 @@ Object .assign (Object .setPrototypeOf (X3DExecutionContext .prototype, Base_X3D
68003
68079
  this [_protos] .add (name, proto);
68004
68080
  proto .setName (name);
68005
68081
 
68006
- this ._protos_changed = this .getBrowser () .getCurrentTime ();
68082
+ this ._sceneGraph_changed = this .getBrowser () .getCurrentTime ();
68007
68083
  },
68008
68084
  updateProtoDeclaration (name, proto)
68009
68085
  {
@@ -68023,7 +68099,7 @@ Object .assign (Object .setPrototypeOf (X3DExecutionContext .prototype, Base_X3D
68023
68099
  this [_protos] .update (proto .getName (), name, proto);
68024
68100
  proto .setName (name);
68025
68101
 
68026
- this ._protos_changed = this .getBrowser () .getCurrentTime ();
68102
+ this ._sceneGraph_changed = this .getBrowser () .getCurrentTime ();
68027
68103
  },
68028
68104
  removeProtoDeclaration (name)
68029
68105
  {
@@ -68031,7 +68107,7 @@ Object .assign (Object .setPrototypeOf (X3DExecutionContext .prototype, Base_X3D
68031
68107
 
68032
68108
  this [_protos] .remove (name);
68033
68109
 
68034
- this ._protos_changed = this .getBrowser () .getCurrentTime ();
68110
+ this ._sceneGraph_changed = this .getBrowser () .getCurrentTime ();
68035
68111
  },
68036
68112
  getProtoDeclarations ()
68037
68113
  {
@@ -68076,7 +68152,7 @@ Object .assign (Object .setPrototypeOf (X3DExecutionContext .prototype, Base_X3D
68076
68152
  this [_externprotos] .add (name, externproto);
68077
68153
  externproto .setName (name);
68078
68154
 
68079
- this ._externprotos_changed = this .getBrowser () .getCurrentTime ();
68155
+ this ._sceneGraph_changed = this .getBrowser () .getCurrentTime ();
68080
68156
  },
68081
68157
  updateExternProtoDeclaration (name, externproto)
68082
68158
  {
@@ -68096,7 +68172,7 @@ Object .assign (Object .setPrototypeOf (X3DExecutionContext .prototype, Base_X3D
68096
68172
  this [_externprotos] .update (externproto .getName (), name, externproto);
68097
68173
  externproto .setName (name);
68098
68174
 
68099
- this ._externprotos_changed = this .getBrowser () .getCurrentTime ();
68175
+ this ._sceneGraph_changed = this .getBrowser () .getCurrentTime ();
68100
68176
  },
68101
68177
  removeExternProtoDeclaration (name)
68102
68178
  {
@@ -68104,7 +68180,7 @@ Object .assign (Object .setPrototypeOf (X3DExecutionContext .prototype, Base_X3D
68104
68180
 
68105
68181
  this [_externprotos] .remove (name);
68106
68182
 
68107
- this ._externprotos_changed = this .getBrowser () .getCurrentTime ();
68183
+ this ._sceneGraph_changed = this .getBrowser () .getCurrentTime ();
68108
68184
  },
68109
68185
  getExternProtoDeclarations ()
68110
68186
  {
@@ -68583,6 +68659,7 @@ Object .assign (Object .setPrototypeOf (X3DPrototypeInstance .prototype, Core_X3
68583
68659
  // Dispose body and assign field definitions.
68584
68660
 
68585
68661
  this [X3DPrototypeInstance_body] ?.dispose ();
68662
+
68586
68663
  this [X3DPrototypeInstance_fieldDefinitions] .assign (protoNode .getFieldDefinitions ());
68587
68664
 
68588
68665
  // If there is a proto, the externproto is completely loaded.
@@ -74790,7 +74867,7 @@ Object .assign (Object .setPrototypeOf (ElevationGrid .prototype, Rendering_X3DG
74790
74867
  if (!this ._normalPerVertex .getValue ())
74791
74868
  return normals;
74792
74869
 
74793
- return this .refineNormals (normalIndex, normals, this ._creaseAngle .getValue ());
74870
+ return this .refineNormals (normalIndex, normals, creaseAngle ?? this ._creaseAngle .getValue ());
74794
74871
  },
74795
74872
  createCoordIndex ()
74796
74873
  {
@@ -74894,8 +74971,8 @@ Object .assign (Object .setPrototypeOf (ElevationGrid .prototype, Rendering_X3DG
74894
74971
  for (let p = 0; p < 6; ++ p, ++ c)
74895
74972
  {
74896
74973
  const
74897
- index = coordIndex [c],
74898
- point = points [index];
74974
+ index = coordIndex [c],
74975
+ { x, y, z} = points [index];
74899
74976
 
74900
74977
  coordIndicesArray .push (index);
74901
74978
 
@@ -74904,13 +74981,7 @@ Object .assign (Object .setPrototypeOf (ElevationGrid .prototype, Rendering_X3DG
74904
74981
 
74905
74982
  fogCoordNode ?.addDepth (index, fogDepthArray);
74906
74983
 
74907
- if (colorNode)
74908
- {
74909
- if (colorPerVertex)
74910
- colorNode .addColor (index, colorArray);
74911
- else
74912
- colorNode .addColor (face, colorArray);
74913
- }
74984
+ colorNode ?.addColor (colorPerVertex ? index : face, colorArray);
74914
74985
 
74915
74986
  if (texCoordNode)
74916
74987
  {
@@ -74918,21 +74989,14 @@ Object .assign (Object .setPrototypeOf (ElevationGrid .prototype, Rendering_X3DG
74918
74989
  }
74919
74990
  else
74920
74991
  {
74921
- const t = texCoords [index];
74992
+ const { x, y } = texCoords [index];
74922
74993
 
74923
- texCoordArray .push (t .x, t .y, 0, 1);
74994
+ texCoordArray .push (x, y, 0, 1);
74924
74995
  }
74925
74996
 
74926
- if (normalNode)
74927
- {
74928
- if (normalPerVertex)
74929
- normalNode .addVector (index, normalArray);
74997
+ normalNode ?.addVector (normalPerVertex ? index : face, normalArray);
74930
74998
 
74931
- else
74932
- normalNode .addVector (face, normalArray);
74933
- }
74934
-
74935
- vertexArray .push (point .x, point .y, point .z, 1);
74999
+ vertexArray .push (x, y, z, 1);
74936
75000
  }
74937
75001
  }
74938
75002
 
@@ -74942,10 +75006,8 @@ Object .assign (Object .setPrototypeOf (ElevationGrid .prototype, Rendering_X3DG
74942
75006
  {
74943
75007
  const normals = this .createNormals (points, coordIndex);
74944
75008
 
74945
- for (const normal of normals)
74946
- {
74947
- normalArray .push (normal .x, normal .y, normal .z);
74948
- }
75009
+ for (const { x, y, z } of normals)
75010
+ normalArray .push (x, y, z);
74949
75011
  }
74950
75012
 
74951
75013
  this .setSolid (this ._solid .getValue ());
@@ -75560,8 +75622,8 @@ Object .assign (Object .setPrototypeOf (Extrusion .prototype, Rendering_X3DGeome
75560
75622
 
75561
75623
  const refinedNormals = this .refineNormals (normalIndex, normals, this ._creaseAngle .getValue ());
75562
75624
 
75563
- for (const normal of refinedNormals)
75564
- normalArray .push (normal .x, normal .y, normal .z);
75625
+ for (const { x, y, z } of refinedNormals)
75626
+ normalArray .push (x, y, z);
75565
75627
 
75566
75628
  // Build caps
75567
75629
 
@@ -75970,23 +76032,11 @@ Object .assign (Object .setPrototypeOf (X3DComposedGeometryNode .prototype, Rend
75970
76032
 
75971
76033
  fogCoordNode ?.addDepth (index, fogDepthArray);
75972
76034
 
75973
- if (colorNode)
75974
- {
75975
- if (colorPerVertex)
75976
- colorNode .addColor (index, colorArray);
75977
- else
75978
- colorNode .addColor (face, colorArray);
75979
- }
76035
+ colorNode ?.addColor (colorPerVertex ? index : face, colorArray);
75980
76036
 
75981
76037
  texCoordNode ?.addPoint (index, multiTexCoordArray);
75982
76038
 
75983
- if (normalNode)
75984
- {
75985
- if (normalPerVertex)
75986
- normalNode .addVector (index, normalArray);
75987
- else
75988
- normalNode .addVector (face, normalArray);
75989
- }
76039
+ normalNode ?.addVector (normalPerVertex ? index : face, normalArray);
75990
76040
 
75991
76041
  coordNode .addPoint (index, vertexArray);
75992
76042
  }
@@ -76007,9 +76057,9 @@ Object .assign (Object .setPrototypeOf (X3DComposedGeometryNode .prototype, Rend
76007
76057
 
76008
76058
  for (let i = 0; i < trianglesSize; ++ i)
76009
76059
  {
76010
- const normal = normals [this .getTriangleIndex (i)];
76060
+ const { x, y, z } = normals [this .getTriangleIndex (i)];
76011
76061
 
76012
- normalArray .push (normal .x, normal .y, normal .z);
76062
+ normalArray .push (x, y, z);
76013
76063
  }
76014
76064
  },
76015
76065
  createNormals (verticesPerPolygon, polygonsSize)
@@ -76265,23 +76315,11 @@ Object .assign (Object .setPrototypeOf (IndexedFaceSet .prototype, Rendering_X3D
76265
76315
 
76266
76316
  fogCoordNode ?.addDepth (index, fogDepthArray);
76267
76317
 
76268
- if (colorNode)
76269
- {
76270
- if (colorPerVertex)
76271
- colorNode .addColor (this .getColorPerVertexIndex (i), colorArray);
76272
- else
76273
- colorNode .addColor (this .getColorIndex (face), colorArray);
76274
- }
76318
+ colorNode ?.addColor (colorPerVertex ? this .getColorPerVertexIndex (i) : this .getColorIndex (face), colorArray);
76275
76319
 
76276
76320
  texCoordNode ?.addPoint (this .getTexCoordPerVertexIndex (i), multiTexCoordArray);
76277
76321
 
76278
- if (normalNode)
76279
- {
76280
- if (normalPerVertex)
76281
- normalNode .addVector (this .getNormalPerVertexIndex (i), normalArray);
76282
- else
76283
- normalNode .addVector (this .getNormalIndex (face), normalArray);
76284
- }
76322
+ normalNode ?.addVector (normalPerVertex ? this .getNormalPerVertexIndex (i) : this .getNormalIndex (face), normalArray);
76285
76323
 
76286
76324
  coordNode .addPoint (index, vertexArray);
76287
76325
  }
@@ -82586,6 +82624,10 @@ Object .assign (Object .setPrototypeOf (OrthoViewpoint .prototype, Navigation_X3
82586
82624
  this .getMaximumY (),
82587
82625
  ];
82588
82626
  },
82627
+ setFieldOfView (value)
82628
+ {
82629
+ this ._fieldOfView = value;
82630
+ },
82589
82631
  getUserFieldOfView ()
82590
82632
  {
82591
82633
  return [
@@ -87458,7 +87500,7 @@ Object .assign (Object .setPrototypeOf (X3DLineGeometryNode .prototype, Renderin
87458
87500
  gl .lineWidth (1);
87459
87501
  };
87460
87502
  })(),
87461
- displayParticles (gl, renderContext, particleSystem)
87503
+ displayInstanced (gl, renderContext, shapeNode)
87462
87504
  {
87463
87505
  const
87464
87506
  browser = this .getBrowser (),
@@ -87479,14 +87521,19 @@ Object .assign (Object .setPrototypeOf (X3DLineGeometryNode .prototype, Renderin
87479
87521
 
87480
87522
  // Setup vertex attributes.
87481
87523
 
87482
- const outputParticles = particleSystem .outputParticles;
87524
+ const instances = shapeNode .getInstances ();
87483
87525
 
87484
- if (outputParticles .vertexArrayObject .update (this .updateParticles) .enable (shaderNode .getProgram ()))
87526
+ if (instances .vertexArrayObject .update (this .updateParticles) .enable (shaderNode .getProgram ()))
87485
87527
  {
87486
- const particleStride = particleSystem .particleStride;
87528
+ const { instancesStride, particleOffset, matrixOffset, normalMatrixOffset } = shapeNode;
87487
87529
 
87488
- shaderNode .enableParticleAttribute (gl, outputParticles, particleStride, particleSystem .particleOffset, 1);
87489
- shaderNode .enableParticleMatrixAttribute (gl, outputParticles, particleStride, particleSystem .matrixOffset, 1);
87530
+ if (particleOffset !== undefined)
87531
+ shaderNode .enableParticleAttribute (gl, instances, instancesStride, particleOffset, 1);
87532
+
87533
+ shaderNode .enableInstanceMatrixAttribute (gl, instances, instancesStride, matrixOffset, 1);
87534
+
87535
+ if (normalMatrixOffset !== undefined)
87536
+ shaderNode .enableInstanceNormalMatrixAttribute (gl, instances, instancesStride, normalMatrixOffset, 1);
87490
87537
 
87491
87538
  for (let i = 0, length = attribNodes .length; i < length; ++ i)
87492
87539
  attribNodes [i] .enable (gl, shaderNode, attribBuffers [i]);
@@ -87507,7 +87554,7 @@ Object .assign (Object .setPrototypeOf (X3DLineGeometryNode .prototype, Renderin
87507
87554
 
87508
87555
  // Wireframes are always solid so only one drawing call is needed.
87509
87556
 
87510
- gl .drawArraysInstanced (primitiveMode, 0, this .vertexCount, particleSystem .numParticles);
87557
+ gl .drawArraysInstanced (primitiveMode, 0, this .vertexCount, shapeNode .getNumInstances ());
87511
87558
 
87512
87559
  for (const node of renderModeNodes)
87513
87560
  node .disable (gl);
@@ -87781,13 +87828,7 @@ Object .assign (Object .setPrototypeOf (IndexedLineSet .prototype, Rendering_X3D
87781
87828
 
87782
87829
  fogCoordNode ?.addDepth (index, fogDepthArray);
87783
87830
 
87784
- if (colorNode)
87785
- {
87786
- if (colorPerVertex)
87787
- colorNode .addColor (this .getColorPerVertexIndex (i), colorArray);
87788
- else
87789
- colorNode .addColor (this .getColorIndex (face), colorArray);
87790
- }
87831
+ colorNode ?.addColor (colorPerVertex ? this .getColorPerVertexIndex (i) : this .getColorIndex (face), colorArray);
87791
87832
 
87792
87833
  normalNode ?.addVector (index, normalArray);
87793
87834
 
@@ -87963,144 +88004,160 @@ Object .assign (Object .setPrototypeOf (IndexedTriangleFanSet .prototype, Render
87963
88004
  {
87964
88005
  return this .triangleIndex [index];
87965
88006
  },
87966
- build ()
87967
- {
87968
- Rendering_X3DComposedGeometryNode .prototype .build .call (this, 3, this .triangleIndex .length, 3, this .triangleIndex .length);
87969
- },
87970
- });
87971
-
87972
- Object .defineProperties (IndexedTriangleFanSet,
87973
- {
87974
- typeName:
87975
- {
87976
- value: "IndexedTriangleFanSet",
87977
- enumerable: true,
87978
- },
87979
- componentInfo:
87980
- {
87981
- value: Object .freeze ({ name: "Rendering", level: 3 }),
87982
- enumerable: true,
87983
- },
87984
- containerField:
87985
- {
87986
- value: "geometry",
87987
- enumerable: true,
87988
- },
87989
- specificationRange:
87990
- {
87991
- value: Object .freeze ({ from: "3.0", to: "Infinity" }),
87992
- enumerable: true,
87993
- },
87994
- fieldDefinitions:
87995
- {
87996
- value: new Base_FieldDefinitionArray ([
87997
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "metadata", new x_ite_Fields .SFNode ()),
87998
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOnly, "set_index", new x_ite_Fields .MFInt32 ()),
87999
- new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "solid", new x_ite_Fields .SFBool (true)),
88000
- new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "ccw", new x_ite_Fields .SFBool (true)),
88001
- new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "colorPerVertex", new x_ite_Fields .SFBool (true)),
88002
- new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "normalPerVertex", new x_ite_Fields .SFBool (true)),
88003
- new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "index", new x_ite_Fields .MFInt32 ()),
88004
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "attrib", new x_ite_Fields .MFNode ()),
88005
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "fogCoord", new x_ite_Fields .SFNode ()),
88006
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "color", new x_ite_Fields .SFNode ()),
88007
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "texCoord", new x_ite_Fields .SFNode ()),
88008
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "normal", new x_ite_Fields .SFNode ()),
88009
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "coord", new x_ite_Fields .SFNode ()),
88010
- ]),
88011
- enumerable: true,
88012
- },
88013
- });
88014
-
88015
- const IndexedTriangleFanSet_default_ = IndexedTriangleFanSet;
88016
- ;
88017
-
88018
- x_ite_Namespace .add ("IndexedTriangleFanSet", "x_ite/Components/Rendering/IndexedTriangleFanSet", IndexedTriangleFanSet_default_);
88019
- /* harmony default export */ const Rendering_IndexedTriangleFanSet = (IndexedTriangleFanSet_default_);
88020
- ;// CONCATENATED MODULE: ./src/x_ite/Components/Rendering/IndexedTriangleSet.js
88021
- /*******************************************************************************
88022
- *
88023
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
88024
- *
88025
- * Copyright create3000, Scheffelstraße 31a, Leipzig, Germany 2011 - 2022.
88026
- *
88027
- * All rights reserved. Holger Seelig <holger.seelig@yahoo.de>.
88028
- *
88029
- * The copyright notice above does not evidence any actual of intended
88030
- * publication of such source code, and is an unpublished work by create3000.
88031
- * This material contains CONFIDENTIAL INFORMATION that is the property of
88032
- * create3000.
88033
- *
88034
- * No permission is granted to copy, distribute, or create derivative works from
88035
- * the contents of this software, in whole or in part, without the prior written
88036
- * permission of create3000.
88037
- *
88038
- * NON-MILITARY USE ONLY
88039
- *
88040
- * All create3000 software are effectively free software with a non-military use
88041
- * restriction. It is free. Well commented source is provided. You may reuse the
88042
- * source in any way you please with the exception anything that uses it must be
88043
- * marked to indicate is contains 'non-military use only' components.
88044
- *
88045
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
88046
- *
88047
- * Copyright 2011 - 2022, Holger Seelig <holger.seelig@yahoo.de>.
88048
- *
88049
- * This file is part of the X_ITE Project.
88050
- *
88051
- * X_ITE is free software: you can redistribute it and/or modify it under the
88052
- * terms of the GNU General Public License version 3 only, as published by the
88053
- * Free Software Foundation.
88054
- *
88055
- * X_ITE is distributed in the hope that it will be useful, but WITHOUT ANY
88056
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
88057
- * A PARTICULAR PURPOSE. See the GNU General Public License version 3 for more
88058
- * details (a copy is included in the LICENSE file that accompanied this code).
88059
- *
88060
- * You should have received a copy of the GNU General Public License version 3
88061
- * along with X_ITE. If not, see <https://www.gnu.org/licenses/gpl.html> for a
88062
- * copy of the GPLv3 License.
88063
- *
88064
- * For Silvio, Joy and Adi.
88065
- *
88066
- ******************************************************************************/
88067
-
88068
-
88069
-
88070
-
88071
-
88072
-
88073
-
88074
- function IndexedTriangleSet (executionContext)
88075
- {
88076
- Rendering_X3DComposedGeometryNode .call (this, executionContext);
88077
-
88078
- this .addType (Base_X3DConstants .IndexedTriangleSet);
88079
- }
88080
-
88081
- Object .assign (Object .setPrototypeOf (IndexedTriangleSet .prototype, Rendering_X3DComposedGeometryNode .prototype),
88082
- {
88083
- getPolygonIndex (i)
88007
+ getVerticesPerPolygon ()
88084
88008
  {
88085
- return this ._index [i];
88009
+ return 3;
88086
88010
  },
88087
- initialize ()
88011
+ getNumVertices ()
88088
88012
  {
88089
- Rendering_X3DComposedGeometryNode .prototype .initialize .call (this);
88090
-
88091
- this ._set_index .addFieldInterest (this ._index);
88013
+ return this .triangleIndex .length;
88092
88014
  },
88093
88015
  build ()
88094
88016
  {
88095
- Rendering_X3DComposedGeometryNode .prototype .build .call (this, 3, this ._index .length, 3, this ._index .length);
88017
+ Rendering_X3DComposedGeometryNode .prototype .build .call (this, 3, this .triangleIndex .length, 3, this .triangleIndex .length);
88096
88018
  },
88097
88019
  });
88098
88020
 
88099
- Object .defineProperties (IndexedTriangleSet,
88021
+ Object .defineProperties (IndexedTriangleFanSet,
88100
88022
  {
88101
88023
  typeName:
88102
88024
  {
88103
- value: "IndexedTriangleSet",
88025
+ value: "IndexedTriangleFanSet",
88026
+ enumerable: true,
88027
+ },
88028
+ componentInfo:
88029
+ {
88030
+ value: Object .freeze ({ name: "Rendering", level: 3 }),
88031
+ enumerable: true,
88032
+ },
88033
+ containerField:
88034
+ {
88035
+ value: "geometry",
88036
+ enumerable: true,
88037
+ },
88038
+ specificationRange:
88039
+ {
88040
+ value: Object .freeze ({ from: "3.0", to: "Infinity" }),
88041
+ enumerable: true,
88042
+ },
88043
+ fieldDefinitions:
88044
+ {
88045
+ value: new Base_FieldDefinitionArray ([
88046
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "metadata", new x_ite_Fields .SFNode ()),
88047
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOnly, "set_index", new x_ite_Fields .MFInt32 ()),
88048
+ new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "solid", new x_ite_Fields .SFBool (true)),
88049
+ new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "ccw", new x_ite_Fields .SFBool (true)),
88050
+ new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "colorPerVertex", new x_ite_Fields .SFBool (true)),
88051
+ new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "normalPerVertex", new x_ite_Fields .SFBool (true)),
88052
+ new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "index", new x_ite_Fields .MFInt32 ()),
88053
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "attrib", new x_ite_Fields .MFNode ()),
88054
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "fogCoord", new x_ite_Fields .SFNode ()),
88055
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "color", new x_ite_Fields .SFNode ()),
88056
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "texCoord", new x_ite_Fields .SFNode ()),
88057
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "normal", new x_ite_Fields .SFNode ()),
88058
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "coord", new x_ite_Fields .SFNode ()),
88059
+ ]),
88060
+ enumerable: true,
88061
+ },
88062
+ });
88063
+
88064
+ const IndexedTriangleFanSet_default_ = IndexedTriangleFanSet;
88065
+ ;
88066
+
88067
+ x_ite_Namespace .add ("IndexedTriangleFanSet", "x_ite/Components/Rendering/IndexedTriangleFanSet", IndexedTriangleFanSet_default_);
88068
+ /* harmony default export */ const Rendering_IndexedTriangleFanSet = (IndexedTriangleFanSet_default_);
88069
+ ;// CONCATENATED MODULE: ./src/x_ite/Components/Rendering/IndexedTriangleSet.js
88070
+ /*******************************************************************************
88071
+ *
88072
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
88073
+ *
88074
+ * Copyright create3000, Scheffelstraße 31a, Leipzig, Germany 2011 - 2022.
88075
+ *
88076
+ * All rights reserved. Holger Seelig <holger.seelig@yahoo.de>.
88077
+ *
88078
+ * The copyright notice above does not evidence any actual of intended
88079
+ * publication of such source code, and is an unpublished work by create3000.
88080
+ * This material contains CONFIDENTIAL INFORMATION that is the property of
88081
+ * create3000.
88082
+ *
88083
+ * No permission is granted to copy, distribute, or create derivative works from
88084
+ * the contents of this software, in whole or in part, without the prior written
88085
+ * permission of create3000.
88086
+ *
88087
+ * NON-MILITARY USE ONLY
88088
+ *
88089
+ * All create3000 software are effectively free software with a non-military use
88090
+ * restriction. It is free. Well commented source is provided. You may reuse the
88091
+ * source in any way you please with the exception anything that uses it must be
88092
+ * marked to indicate is contains 'non-military use only' components.
88093
+ *
88094
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
88095
+ *
88096
+ * Copyright 2011 - 2022, Holger Seelig <holger.seelig@yahoo.de>.
88097
+ *
88098
+ * This file is part of the X_ITE Project.
88099
+ *
88100
+ * X_ITE is free software: you can redistribute it and/or modify it under the
88101
+ * terms of the GNU General Public License version 3 only, as published by the
88102
+ * Free Software Foundation.
88103
+ *
88104
+ * X_ITE is distributed in the hope that it will be useful, but WITHOUT ANY
88105
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
88106
+ * A PARTICULAR PURPOSE. See the GNU General Public License version 3 for more
88107
+ * details (a copy is included in the LICENSE file that accompanied this code).
88108
+ *
88109
+ * You should have received a copy of the GNU General Public License version 3
88110
+ * along with X_ITE. If not, see <https://www.gnu.org/licenses/gpl.html> for a
88111
+ * copy of the GPLv3 License.
88112
+ *
88113
+ * For Silvio, Joy and Adi.
88114
+ *
88115
+ ******************************************************************************/
88116
+
88117
+
88118
+
88119
+
88120
+
88121
+
88122
+
88123
+ function IndexedTriangleSet (executionContext)
88124
+ {
88125
+ Rendering_X3DComposedGeometryNode .call (this, executionContext);
88126
+
88127
+ this .addType (Base_X3DConstants .IndexedTriangleSet);
88128
+ }
88129
+
88130
+ Object .assign (Object .setPrototypeOf (IndexedTriangleSet .prototype, Rendering_X3DComposedGeometryNode .prototype),
88131
+ {
88132
+ getPolygonIndex (i)
88133
+ {
88134
+ return this ._index [i];
88135
+ },
88136
+ getVerticesPerPolygon ()
88137
+ {
88138
+ return 3;
88139
+ },
88140
+ getNumVertices ()
88141
+ {
88142
+ return this ._index .length;
88143
+ },
88144
+ initialize ()
88145
+ {
88146
+ Rendering_X3DComposedGeometryNode .prototype .initialize .call (this);
88147
+
88148
+ this ._set_index .addFieldInterest (this ._index);
88149
+ },
88150
+ build ()
88151
+ {
88152
+ Rendering_X3DComposedGeometryNode .prototype .build .call (this, 3, this ._index .length, 3, this ._index .length);
88153
+ },
88154
+ });
88155
+
88156
+ Object .defineProperties (IndexedTriangleSet,
88157
+ {
88158
+ typeName:
88159
+ {
88160
+ value: "IndexedTriangleSet",
88104
88161
  enumerable: true,
88105
88162
  },
88106
88163
  componentInfo:
@@ -88268,6 +88325,14 @@ Object .assign (Object .setPrototypeOf (IndexedTriangleStripSet .prototype, Rend
88268
88325
  {
88269
88326
  return this .triangleIndex [index];
88270
88327
  },
88328
+ getVerticesPerPolygon ()
88329
+ {
88330
+ return 3;
88331
+ },
88332
+ getNumVertices ()
88333
+ {
88334
+ return this .triangleIndex .length;
88335
+ },
88271
88336
  build ()
88272
88337
  {
88273
88338
  Rendering_X3DComposedGeometryNode .prototype .build .call (this, 3, this .triangleIndex .length, 3, this .triangleIndex .length);
@@ -88917,7 +88982,7 @@ Object .assign (Object .setPrototypeOf (X3DPointGeometryNode .prototype, Renderi
88917
88982
  for (const node of renderModeNodes)
88918
88983
  node .disable (gl);
88919
88984
  },
88920
- displayParticles (gl, renderContext, particleSystem)
88985
+ displayInstanced (gl, renderContext, shapeNode)
88921
88986
  {
88922
88987
  const
88923
88988
  appearanceNode = renderContext .appearanceNode,
@@ -88936,14 +89001,19 @@ Object .assign (Object .setPrototypeOf (X3DPointGeometryNode .prototype, Renderi
88936
89001
 
88937
89002
  // Setup vertex attributes.
88938
89003
 
88939
- const outputParticles = particleSystem .outputParticles;
89004
+ const instances = shapeNode .getInstances ();
88940
89005
 
88941
- if (outputParticles .vertexArrayObject .update (this .updateParticles) .enable (shaderNode .getProgram ()))
89006
+ if (instances .vertexArrayObject .update (this .updateParticles) .enable (shaderNode .getProgram ()))
88942
89007
  {
88943
- const particleStride = particleSystem .particleStride;
89008
+ const { instancesStride, particleOffset, matrixOffset, normalMatrixOffset } = shapeNode;
89009
+
89010
+ if (particleOffset !== undefined)
89011
+ shaderNode .enableParticleAttribute (gl, instances, instancesStride, particleOffset, 1);
88944
89012
 
88945
- shaderNode .enableParticleAttribute (gl, outputParticles, particleStride, particleSystem .particleOffset, 1);
88946
- shaderNode .enableParticleMatrixAttribute (gl, outputParticles, particleStride, particleSystem .matrixOffset, 1);
89013
+ shaderNode .enableInstanceMatrixAttribute (gl, instances, instancesStride, matrixOffset, 1);
89014
+
89015
+ if (normalMatrixOffset !== undefined)
89016
+ shaderNode .enableInstanceNormalMatrixAttribute (gl, instances, instancesStride, normalMatrixOffset, 1);
88947
89017
 
88948
89018
  for (let i = 0, length = attribNodes .length; i < length; ++ i)
88949
89019
  attribNodes [i] .enable (gl, shaderNode, attribBuffers [i]);
@@ -88964,7 +89034,7 @@ Object .assign (Object .setPrototypeOf (X3DPointGeometryNode .prototype, Renderi
88964
89034
 
88965
89035
  // Wireframes are always solid so only one drawing call is needed.
88966
89036
 
88967
- gl .drawArraysInstanced (this .primitiveMode, 0, this .vertexCount, particleSystem .numParticles);
89037
+ gl .drawArraysInstanced (this .primitiveMode, 0, this .vertexCount, shapeNode .getNumInstances ());
88968
89038
 
88969
89039
  for (const node of renderModeNodes)
88970
89040
  node .disable (gl);
@@ -89316,140 +89386,156 @@ Object .assign (Object .setPrototypeOf (TriangleFanSet .prototype, Rendering_X3D
89316
89386
  {
89317
89387
  return this .triangleIndex [index];
89318
89388
  },
89319
- build ()
89389
+ getVerticesPerPolygon ()
89320
89390
  {
89321
- Rendering_X3DComposedGeometryNode .prototype .build .call (this, 3, this .triangleIndex .length, 3, this .triangleIndex .length);
89391
+ return 3;
89322
89392
  },
89323
- });
89324
-
89325
- Object .defineProperties (TriangleFanSet,
89326
- {
89327
- typeName:
89393
+ getNumVertices ()
89328
89394
  {
89329
- value: "TriangleFanSet",
89330
- enumerable: true,
89395
+ return this .triangleIndex .length;
89331
89396
  },
89332
- componentInfo:
89333
- {
89334
- value: Object .freeze ({ name: "Rendering", level: 3 }),
89335
- enumerable: true,
89336
- },
89337
- containerField:
89338
- {
89339
- value: "geometry",
89340
- enumerable: true,
89341
- },
89342
- specificationRange:
89343
- {
89344
- value: Object .freeze ({ from: "3.0", to: "Infinity" }),
89345
- enumerable: true,
89346
- },
89347
- fieldDefinitions:
89348
- {
89349
- value: new Base_FieldDefinitionArray ([
89350
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "metadata", new x_ite_Fields .SFNode ()),
89351
- new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "solid", new x_ite_Fields .SFBool (true)),
89352
- new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "ccw", new x_ite_Fields .SFBool (true)),
89353
- new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "colorPerVertex", new x_ite_Fields .SFBool (true)),
89354
- new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "normalPerVertex", new x_ite_Fields .SFBool (true)),
89355
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "fanCount", new x_ite_Fields .MFInt32 ()),
89356
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "attrib", new x_ite_Fields .MFNode ()),
89357
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "fogCoord", new x_ite_Fields .SFNode ()),
89358
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "color", new x_ite_Fields .SFNode ()),
89359
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "texCoord", new x_ite_Fields .SFNode ()),
89360
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "normal", new x_ite_Fields .SFNode ()),
89361
- new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "coord", new x_ite_Fields .SFNode ()),
89362
- ]),
89363
- enumerable: true,
89364
- },
89365
- });
89366
-
89367
- const TriangleFanSet_default_ = TriangleFanSet;
89368
- ;
89369
-
89370
- x_ite_Namespace .add ("TriangleFanSet", "x_ite/Components/Rendering/TriangleFanSet", TriangleFanSet_default_);
89371
- /* harmony default export */ const Rendering_TriangleFanSet = (TriangleFanSet_default_);
89372
- ;// CONCATENATED MODULE: ./src/x_ite/Components/Rendering/TriangleSet.js
89373
- /*******************************************************************************
89374
- *
89375
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
89376
- *
89377
- * Copyright create3000, Scheffelstraße 31a, Leipzig, Germany 2011 - 2022.
89378
- *
89379
- * All rights reserved. Holger Seelig <holger.seelig@yahoo.de>.
89380
- *
89381
- * The copyright notice above does not evidence any actual of intended
89382
- * publication of such source code, and is an unpublished work by create3000.
89383
- * This material contains CONFIDENTIAL INFORMATION that is the property of
89384
- * create3000.
89385
- *
89386
- * No permission is granted to copy, distribute, or create derivative works from
89387
- * the contents of this software, in whole or in part, without the prior written
89388
- * permission of create3000.
89389
- *
89390
- * NON-MILITARY USE ONLY
89391
- *
89392
- * All create3000 software are effectively free software with a non-military use
89393
- * restriction. It is free. Well commented source is provided. You may reuse the
89394
- * source in any way you please with the exception anything that uses it must be
89395
- * marked to indicate is contains 'non-military use only' components.
89396
- *
89397
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
89398
- *
89399
- * Copyright 2011 - 2022, Holger Seelig <holger.seelig@yahoo.de>.
89400
- *
89401
- * This file is part of the X_ITE Project.
89402
- *
89403
- * X_ITE is free software: you can redistribute it and/or modify it under the
89404
- * terms of the GNU General Public License version 3 only, as published by the
89405
- * Free Software Foundation.
89406
- *
89407
- * X_ITE is distributed in the hope that it will be useful, but WITHOUT ANY
89408
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
89409
- * A PARTICULAR PURPOSE. See the GNU General Public License version 3 for more
89410
- * details (a copy is included in the LICENSE file that accompanied this code).
89411
- *
89412
- * You should have received a copy of the GNU General Public License version 3
89413
- * along with X_ITE. If not, see <https://www.gnu.org/licenses/gpl.html> for a
89414
- * copy of the GPLv3 License.
89415
- *
89416
- * For Silvio, Joy and Adi.
89417
- *
89418
- ******************************************************************************/
89419
-
89420
-
89421
-
89422
-
89423
-
89424
-
89425
-
89426
- function TriangleSet (executionContext)
89427
- {
89428
- Rendering_X3DComposedGeometryNode .call (this, executionContext);
89429
-
89430
- this .addType (Base_X3DConstants .TriangleSet);
89431
- }
89432
-
89433
- Object .assign (Object .setPrototypeOf (TriangleSet .prototype, Rendering_X3DComposedGeometryNode .prototype),
89434
- {
89435
89397
  build ()
89436
89398
  {
89437
- if (! this .getCoord ())
89438
- return;
89439
-
89440
- Rendering_X3DComposedGeometryNode .prototype .build .call (this, 3, this .getCoord () .getSize (), 3, this .getCoord () .getSize ());
89441
- },
89442
- createNormals (verticesPerPolygon, polygonsSize)
89443
- {
89444
- return this .createFaceNormals (verticesPerPolygon, polygonsSize);
89399
+ Rendering_X3DComposedGeometryNode .prototype .build .call (this, 3, this .triangleIndex .length, 3, this .triangleIndex .length);
89445
89400
  },
89446
89401
  });
89447
89402
 
89448
- Object .defineProperties (TriangleSet,
89403
+ Object .defineProperties (TriangleFanSet,
89449
89404
  {
89450
89405
  typeName:
89451
89406
  {
89452
- value: "TriangleSet",
89407
+ value: "TriangleFanSet",
89408
+ enumerable: true,
89409
+ },
89410
+ componentInfo:
89411
+ {
89412
+ value: Object .freeze ({ name: "Rendering", level: 3 }),
89413
+ enumerable: true,
89414
+ },
89415
+ containerField:
89416
+ {
89417
+ value: "geometry",
89418
+ enumerable: true,
89419
+ },
89420
+ specificationRange:
89421
+ {
89422
+ value: Object .freeze ({ from: "3.0", to: "Infinity" }),
89423
+ enumerable: true,
89424
+ },
89425
+ fieldDefinitions:
89426
+ {
89427
+ value: new Base_FieldDefinitionArray ([
89428
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "metadata", new x_ite_Fields .SFNode ()),
89429
+ new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "solid", new x_ite_Fields .SFBool (true)),
89430
+ new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "ccw", new x_ite_Fields .SFBool (true)),
89431
+ new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "colorPerVertex", new x_ite_Fields .SFBool (true)),
89432
+ new Base_X3DFieldDefinition (Base_X3DConstants .initializeOnly, "normalPerVertex", new x_ite_Fields .SFBool (true)),
89433
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "fanCount", new x_ite_Fields .MFInt32 ()),
89434
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "attrib", new x_ite_Fields .MFNode ()),
89435
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "fogCoord", new x_ite_Fields .SFNode ()),
89436
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "color", new x_ite_Fields .SFNode ()),
89437
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "texCoord", new x_ite_Fields .SFNode ()),
89438
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "normal", new x_ite_Fields .SFNode ()),
89439
+ new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "coord", new x_ite_Fields .SFNode ()),
89440
+ ]),
89441
+ enumerable: true,
89442
+ },
89443
+ });
89444
+
89445
+ const TriangleFanSet_default_ = TriangleFanSet;
89446
+ ;
89447
+
89448
+ x_ite_Namespace .add ("TriangleFanSet", "x_ite/Components/Rendering/TriangleFanSet", TriangleFanSet_default_);
89449
+ /* harmony default export */ const Rendering_TriangleFanSet = (TriangleFanSet_default_);
89450
+ ;// CONCATENATED MODULE: ./src/x_ite/Components/Rendering/TriangleSet.js
89451
+ /*******************************************************************************
89452
+ *
89453
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
89454
+ *
89455
+ * Copyright create3000, Scheffelstraße 31a, Leipzig, Germany 2011 - 2022.
89456
+ *
89457
+ * All rights reserved. Holger Seelig <holger.seelig@yahoo.de>.
89458
+ *
89459
+ * The copyright notice above does not evidence any actual of intended
89460
+ * publication of such source code, and is an unpublished work by create3000.
89461
+ * This material contains CONFIDENTIAL INFORMATION that is the property of
89462
+ * create3000.
89463
+ *
89464
+ * No permission is granted to copy, distribute, or create derivative works from
89465
+ * the contents of this software, in whole or in part, without the prior written
89466
+ * permission of create3000.
89467
+ *
89468
+ * NON-MILITARY USE ONLY
89469
+ *
89470
+ * All create3000 software are effectively free software with a non-military use
89471
+ * restriction. It is free. Well commented source is provided. You may reuse the
89472
+ * source in any way you please with the exception anything that uses it must be
89473
+ * marked to indicate is contains 'non-military use only' components.
89474
+ *
89475
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
89476
+ *
89477
+ * Copyright 2011 - 2022, Holger Seelig <holger.seelig@yahoo.de>.
89478
+ *
89479
+ * This file is part of the X_ITE Project.
89480
+ *
89481
+ * X_ITE is free software: you can redistribute it and/or modify it under the
89482
+ * terms of the GNU General Public License version 3 only, as published by the
89483
+ * Free Software Foundation.
89484
+ *
89485
+ * X_ITE is distributed in the hope that it will be useful, but WITHOUT ANY
89486
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
89487
+ * A PARTICULAR PURPOSE. See the GNU General Public License version 3 for more
89488
+ * details (a copy is included in the LICENSE file that accompanied this code).
89489
+ *
89490
+ * You should have received a copy of the GNU General Public License version 3
89491
+ * along with X_ITE. If not, see <https://www.gnu.org/licenses/gpl.html> for a
89492
+ * copy of the GPLv3 License.
89493
+ *
89494
+ * For Silvio, Joy and Adi.
89495
+ *
89496
+ ******************************************************************************/
89497
+
89498
+
89499
+
89500
+
89501
+
89502
+
89503
+
89504
+ function TriangleSet (executionContext)
89505
+ {
89506
+ Rendering_X3DComposedGeometryNode .call (this, executionContext);
89507
+
89508
+ this .addType (Base_X3DConstants .TriangleSet);
89509
+ }
89510
+
89511
+ Object .assign (Object .setPrototypeOf (TriangleSet .prototype, Rendering_X3DComposedGeometryNode .prototype),
89512
+ {
89513
+ getVerticesPerPolygon ()
89514
+ {
89515
+ return 3;
89516
+ },
89517
+ getNumVertices ()
89518
+ {
89519
+ return this .getCoord () ?.getSize ();
89520
+ },
89521
+ build ()
89522
+ {
89523
+ if (!this .getCoord ())
89524
+ return;
89525
+
89526
+ Rendering_X3DComposedGeometryNode .prototype .build .call (this, 3, this .getCoord () .getSize (), 3, this .getCoord () .getSize ());
89527
+ },
89528
+ createNormals (verticesPerPolygon, polygonsSize)
89529
+ {
89530
+ return this .createFaceNormals (verticesPerPolygon, polygonsSize);
89531
+ },
89532
+ });
89533
+
89534
+ Object .defineProperties (TriangleSet,
89535
+ {
89536
+ typeName:
89537
+ {
89538
+ value: "TriangleSet",
89453
89539
  enumerable: true,
89454
89540
  },
89455
89541
  componentInfo:
@@ -89594,6 +89680,14 @@ Object .assign (Object .setPrototypeOf (TriangleStripSet .prototype, Rendering_X
89594
89680
  {
89595
89681
  return this .triangleIndex [index];
89596
89682
  },
89683
+ getVerticesPerPolygon ()
89684
+ {
89685
+ return 3;
89686
+ },
89687
+ getNumVertices ()
89688
+ {
89689
+ return this .triangleIndex .length;
89690
+ },
89597
89691
  build ()
89598
89692
  {
89599
89693
  Rendering_X3DComposedGeometryNode .prototype .build .call (this, 3, this .triangleIndex .length, 3, this .triangleIndex .length);
@@ -89715,7 +89809,6 @@ x_ite_Namespace .add ("TriangleStripSet", "x_ite/Components/Rendering/TriangleSt
89715
89809
 
89716
89810
 
89717
89811
 
89718
-
89719
89812
 
89720
89813
 
89721
89814
  const Rendering_default_ = {
@@ -89745,7 +89838,6 @@ const Rendering_default_ = {
89745
89838
  Rendering_X3DCoordinateNode,
89746
89839
  Rendering_X3DGeometricPropertyNode,
89747
89840
  Rendering_X3DGeometryNode,
89748
- Rendering_X3DLineGeometryNode,
89749
89841
  Rendering_X3DNormalNode,
89750
89842
  ],
89751
89843
  };
@@ -89863,7 +89955,7 @@ const X3DShaderNode_default_ = X3DShaderNode;
89863
89955
  x_ite_Namespace .add ("X3DShaderNode", "x_ite/Components/Shaders/X3DShaderNode", X3DShaderNode_default_);
89864
89956
  /* harmony default export */ const Shaders_X3DShaderNode = (X3DShaderNode_default_);
89865
89957
  ;// CONCATENATED MODULE: ./src/x_ite/Components/Shaders/X3DProgrammableShaderObject.js
89866
- /* provided dependency */ var X3DProgrammableShaderObject_$ = __webpack_require__(349);
89958
+ /* provided dependency */ var X3DProgrammableShaderObject_$ = __webpack_require__(275);
89867
89959
  /*******************************************************************************
89868
89960
  *
89869
89961
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -90171,11 +90263,27 @@ Object .assign (X3DProgrammableShaderObject .prototype,
90171
90263
  "Vertex",
90172
90264
  "Particle",
90173
90265
  "ParticleMatrix",
90266
+ "ParticleNormalMatrix",
90267
+ "InstanceMatrix",
90268
+ "InstanceNormalMatrix",
90174
90269
  ];
90175
90270
 
90271
+ const attributeMappings = {
90272
+ "InstanceMatrix": ["ParticleMatrix"],
90273
+ "InstanceNormalMatrix": ["ParticleNormalMatrix"],
90274
+ };
90275
+
90176
90276
  for (const name of attributes)
90177
90277
  {
90178
- const attribute = gl .getAttribLocation (program, `x3d_${name}`);
90278
+ let attribute = gl .getAttribLocation (program, `x3d_${name}`);
90279
+
90280
+ for (const alias of attributeMappings [name] ?? [ ])
90281
+ {
90282
+ if (attribute === -1)
90283
+ attribute = gl .getAttribLocation (program, `x3d_${alias}`);
90284
+ else
90285
+ break;
90286
+ }
90179
90287
 
90180
90288
  this [`x3d_${name}`] = attribute;
90181
90289
 
@@ -91116,11 +91224,11 @@ Object .assign (X3DProgrammableShaderObject .prototype,
91116
91224
  gl .vertexAttribPointer (location, 4, gl .FLOAT, false, stride, offset);
91117
91225
  gl .vertexAttribDivisor (location, divisor);
91118
91226
  },
91119
- enableParticleMatrixAttribute (gl, buffer, stride, offset, divisor)
91227
+ enableInstanceMatrixAttribute (gl, buffer, stride, offset, divisor)
91120
91228
  {
91121
- const location0 = this .x3d_ParticleMatrix;
91229
+ const location0 = this .x3d_InstanceMatrix;
91122
91230
 
91123
- stride = stride || 64;
91231
+ stride = stride || 64; // 4 Bytes * 16
91124
91232
 
91125
91233
  gl .bindBuffer (gl .ARRAY_BUFFER, buffer);
91126
91234
 
@@ -91133,6 +91241,23 @@ Object .assign (X3DProgrammableShaderObject .prototype,
91133
91241
  gl .vertexAttribDivisor (location, divisor);
91134
91242
  }
91135
91243
  },
91244
+ enableInstanceNormalMatrixAttribute (gl, buffer, stride, offset, divisor)
91245
+ {
91246
+ const location0 = this .x3d_InstanceNormalMatrix;
91247
+
91248
+ stride = stride || 36; // 4 Bytes * 9
91249
+
91250
+ gl .bindBuffer (gl .ARRAY_BUFFER, buffer);
91251
+
91252
+ for (let i = 0; i < 3; ++ i)
91253
+ {
91254
+ const location = location0 + i;
91255
+
91256
+ gl .enableVertexAttribArray (location);
91257
+ gl .vertexAttribPointer (location, 3, gl .FLOAT, false, stride, offset + 12 * i);
91258
+ gl .vertexAttribDivisor (location, divisor);
91259
+ }
91260
+ },
91136
91261
  getProgramInfo ()
91137
91262
  {
91138
91263
  function cmp (lhs, rhs) { return lhs < rhs ? -1 : lhs > rhs ? 1 : 0; }
@@ -93599,23 +93724,29 @@ return normalize(normal)*facing;
93599
93724
 
93600
93725
  x_ite_Namespace .add ("Normal2.glsl", "assets/shaders/webgl2/common/Normal2.glsl", Normal2_glsl_default_);
93601
93726
  /* harmony default export */ const Normal2_glsl = (Normal2_glsl_default_);
93602
- ;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/common/Particle2.glsl.js
93603
- const Particle2_glsl_default_ = /* glsl */ `#if defined(X3D_PARTICLE_SYSTEM)
93727
+ ;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/common/Instancing2.glsl.js
93728
+ const Instancing2_glsl_default_ = /* glsl */ `#if defined(X3D_INSTANCING)
93604
93729
  #if defined(X3D_TEX_COORD_RAMP)
93605
- uniform sampler2D x3d_TexCoordRamp;in vec4 x3d_Particle;vec4 getParticleTexCoord(const in vec4 texCoord){const int map[6]=int[6](0,1,2,0,2,3);int index0=int(x3d_Particle[3]);return texelFetch(x3d_TexCoordRamp,index0+map[gl_VertexID % 6],0);}
93730
+ uniform sampler2D x3d_TexCoordRamp;in vec4 x3d_Particle;vec4 getInstanceTexCoord(const in vec4 texCoord){const int map[6]=int[6](0,1,2,0,2,3);int index0=int(x3d_Particle[3]);return texelFetch(x3d_TexCoordRamp,index0+map[gl_VertexID % 6],0);}
93606
93731
  #else
93607
- #define getParticleTexCoord(texCoord)(texCoord)
93732
+ #define getInstanceTexCoord(texCoord)(texCoord)
93608
93733
  #endif
93609
- in mat4 x3d_ParticleMatrix;vec4 getParticleVertex(const in vec4 vertex){return x3d_ParticleMatrix*vertex;}
93734
+ #if defined(X3D_INSTANCE_NORMAL)
93735
+ in mat3 x3d_InstanceNormalMatrix;vec3 getInstanceNormal(const in vec3 normal){return x3d_InstanceNormalMatrix*normal;}
93610
93736
  #else
93611
- #define getParticleVertex(vertex)(vertex)
93612
- #define getParticleTexCoord(texCoord)(texCoord)
93737
+ #define getInstanceNormal(normal)(normal)
93738
+ #endif
93739
+ in mat4 x3d_InstanceMatrix;vec4 getInstanceVertex(const in vec4 vertex){return x3d_InstanceMatrix*vertex;}
93740
+ #else
93741
+ #define getInstanceVertex(vertex)(vertex)
93742
+ #define getInstanceNormal(normal)(normal)
93743
+ #define getInstanceTexCoord(texCoord)(texCoord)
93613
93744
  #endif
93614
93745
  `
93615
93746
  ;
93616
93747
 
93617
- x_ite_Namespace .add ("Particle2.glsl", "assets/shaders/webgl2/common/Particle2.glsl", Particle2_glsl_default_);
93618
- /* harmony default export */ const Particle2_glsl = (Particle2_glsl_default_);
93748
+ x_ite_Namespace .add ("Instancing2.glsl", "assets/shaders/webgl2/common/Instancing2.glsl", Instancing2_glsl_default_);
93749
+ /* harmony default export */ const Instancing2_glsl = (Instancing2_glsl_default_);
93619
93750
  ;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/common/Perlin2.glsl.js
93620
93751
  const Perlin2_glsl_default_ = /* glsl */ `float rand(const in vec2 co){return fract(sin(dot(co.xy,vec2(12.9898,78.233)))*43758.5453);}float rand(const in vec2 co,const in float l){return rand(vec2(rand(co),l));}float rand(const in vec2 co,const in float l,const in float t){return rand(vec2(rand(co,l),t));}float perlin(const in vec2 p,const in float dim,const in float time){const float M_PI=3.14159265358979323846;vec2 pos=floor(p*dim);vec2 posx=pos+vec2(1.0,0.0);vec2 posy=pos+vec2(0.0,1.0);vec2 posxy=pos+vec2(1.0);float c=rand(pos,dim,time);float cx=rand(posx,dim,time);float cy=rand(posy,dim,time);float cxy=rand(posxy,dim,time);vec2 d=fract(p*dim);d=-0.5*cos(d*M_PI)+0.5;float ccx=mix(c,cx,d.x);float cycxy=mix(cy,cxy,d.x);float center=mix(ccx,cycxy,d.y);return center*2.0-1.0;}vec3 perlin(const in vec3 p){return vec3(perlin(p.xy,1.0,0.0),perlin(p.yz,1.0,0.0),perlin(p.zx,1.0,0.0));}`
93621
93752
  ;
@@ -93714,6 +93845,8 @@ in float x3d_CoordIndex;uniform sampler2D x3d_JointsTexture;uniform sampler2D x3
93714
93845
  #if defined(X3D_NORMALS)
93715
93846
  vec3 skinNormal=vec3(0.0);mat3 getJointNormalMatrix(const in int joint){vec4 a=texelFetch(x3d_JointMatricesTexture,joint*8+4,0);vec4 b=texelFetch(x3d_JointMatricesTexture,joint*8+5,0);vec4 c=texelFetch(x3d_JointMatricesTexture,joint*8+6,0);return mat3(a.xyz,vec3(a.w,b.xy),vec3(b.zw,c.x));}
93716
93847
  #define getSkinNormal(normal)(skinNormal)
93848
+ #else
93849
+ #define getSkinNormal(normal)(normal)
93717
93850
  #endif
93718
93851
  vec4 getSkinVertex(const in vec4 vertex,const in vec3 normal){int coordIndex=int(x3d_CoordIndex);vec4 skin=vertex;
93719
93852
  #if defined(X3D_NORMALS)
@@ -93835,7 +93968,7 @@ currentColor*=mix(vec3(1.0),T.rgb*x3d_TextureProjectorColor[i],T.a*x3d_TexturePr
93835
93968
  x_ite_Namespace .add ("Texture2.glsl", "assets/shaders/webgl2/common/Texture2.glsl", Texture2_glsl_default_);
93836
93969
  /* harmony default export */ const Texture2_glsl = (Texture2_glsl_default_);
93837
93970
  ;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/common/Utils2.glsl.js
93838
- const Utils2_glsl_default_ = /* glsl */ `#if defined(X3D_SKINNING)||defined(X3D_PARTICLE_SYSTEM)
93971
+ const Utils2_glsl_default_ = /* glsl */ `#if defined(X3D_SKINNING)||defined(X3D_INSTANCING)
93839
93972
  vec4 texelFetch(const in sampler2D _sampler,const in int index,const in int lod){int x=textureSize(_sampler,lod).x;ivec2 p=ivec2(index % x,index/x);vec4 t=texelFetch(_sampler,p,lod);return t;}
93840
93973
  #endif
93841
93974
  `
@@ -93903,13 +94036,13 @@ out float depth;
93903
94036
  #endif
93904
94037
  #pragma X3D include "Utils.glsl"
93905
94038
  #pragma X3D include "Skin.glsl"
93906
- #pragma X3D include "Particle.glsl"
94039
+ #pragma X3D include "Instancing.glsl"
93907
94040
  #pragma X3D include "PointSize.glsl"
93908
94041
  void vertex_main(){
93909
94042
  #if defined(X3D_NORMALS)
93910
- vec4 x3d_TransformedVertex=getParticleVertex(getSkinVertex(x3d_Vertex,x3d_Normal));vec3 x3d_TransformedNormal=getSkinNormal(x3d_Normal);
94043
+ vec4 x3d_TransformedVertex=getInstanceVertex(getSkinVertex(x3d_Vertex,x3d_Normal));vec3 x3d_TransformedNormal=getInstanceNormal(getSkinNormal(x3d_Normal));
93911
94044
  #else
93912
- vec4 x3d_TransformedVertex=getParticleVertex(getSkinVertex(x3d_Vertex,vec3(0.0)));
94045
+ vec4 x3d_TransformedVertex=getInstanceVertex(getSkinVertex(x3d_Vertex,vec3(0.0)));
93913
94046
  #endif
93914
94047
  vec4 position=x3d_ModelViewMatrix*x3d_TransformedVertex;vertex=position.xyz;
93915
94048
  #if defined(X3D_GEOMETRY_0D)
@@ -93933,7 +94066,7 @@ color=x3d_Color;
93933
94066
 
93934
94067
  ${Array .from ({ length: maxTexCoords }, (_, i) => /* glsl */ `
93935
94068
  #if X3D_NUM_TEXTURE_COORDINATES > ${i}
93936
- texCoord${i} = getParticleTexCoord (x3d_TexCoord${i});
94069
+ texCoord${i} = getInstanceTexCoord (x3d_TexCoord${i});
93937
94070
  #endif
93938
94071
  `) .join ("\n")}
93939
94072
 
@@ -94401,9 +94534,9 @@ const Depth2_vs_default_ = /* glsl */ `#version 300 es
94401
94534
  precision highp float;precision highp int;precision highp sampler2D;uniform mat4 x3d_ProjectionMatrix;uniform mat4 x3d_ModelViewMatrix;in vec4 x3d_Vertex;out vec3 vertex;
94402
94535
  #pragma X3D include "common/Utils.glsl"
94403
94536
  #pragma X3D include "common/Skin.glsl"
94404
- #pragma X3D include "common/Particle.glsl"
94537
+ #pragma X3D include "common/Instancing.glsl"
94405
94538
  #pragma X3D include "common/PointSize.glsl"
94406
- void main(){vec4 x3d_TransformedVertex=getParticleVertex(getSkinVertex(x3d_Vertex,vec3(0.0)));vec4 position=x3d_ModelViewMatrix*x3d_TransformedVertex;vertex=position.xyz;
94539
+ void main(){vec4 x3d_TransformedVertex=getInstanceVertex(getSkinVertex(x3d_Vertex,vec3(0.0)));vec4 position=x3d_ModelViewMatrix*x3d_TransformedVertex;vertex=position.xyz;
94407
94540
  #if defined(X3D_GEOMETRY_0D)
94408
94541
  #if defined(X3D_STYLE_PROPERTIES)
94409
94542
  gl_PointSize=max(pointSize=getPointSize(vertex),2.0);
@@ -94744,7 +94877,12 @@ x_ite_Namespace .add ("Pointing2.fs", "assets/shaders/webgl2/Pointing2.fs", Poin
94744
94877
  /* harmony default export */ const Pointing2_fs = (Pointing2_fs_default_);
94745
94878
  ;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/Pointing2.vs.js
94746
94879
  const Pointing2_vs_default_ = /* glsl */ `#version 300 es
94747
- precision highp float;precision highp int;precision highp sampler2D;uniform mat4 x3d_ProjectionMatrix;uniform mat4 x3d_ModelViewMatrix;in vec4 x3d_Vertex;in vec3 x3d_Normal;
94880
+ precision highp float;precision highp int;precision highp sampler2D;uniform mat4 x3d_ProjectionMatrix;uniform mat4 x3d_ModelViewMatrix;in vec4 x3d_Vertex;
94881
+ #if defined(X3D_NORMALS)
94882
+ in vec3 x3d_Normal;
94883
+ #else
94884
+ const vec3 x3d_Normal=vec3(0.0,0.0,1.0);
94885
+ #endif
94748
94886
  #if!defined(X3D_GEOMETRY_0D)&&!defined(X3D_GEOMETRY_1D)
94749
94887
  in vec4 x3d_TexCoord0;
94750
94888
  #endif
@@ -94760,13 +94898,13 @@ flat out float lengthSoFar;flat out vec2 startPoint;out vec2 midPoint;
94760
94898
  #endif
94761
94899
  #pragma X3D include "common/Utils.glsl"
94762
94900
  #pragma X3D include "common/Skin.glsl"
94763
- #pragma X3D include "common/Particle.glsl"
94901
+ #pragma X3D include "common/Instancing.glsl"
94764
94902
  #pragma X3D include "common/PointSize.glsl"
94765
94903
  void main(){
94766
94904
  #if defined(X3D_GEOMETRY_1D)&&defined(X3D_STYLE_PROPERTIES)
94767
94905
  lengthSoFar=x3d_LineStipple.z;startPoint=x3d_LineStipple.xy;midPoint=x3d_LineStipple.xy;
94768
94906
  #endif
94769
- vec4 x3d_TransformedVertex=getParticleVertex(getSkinVertex(x3d_Vertex,vec3(0.0)));vec4 position=x3d_ModelViewMatrix*x3d_TransformedVertex;vertex=position.xyz;normal=x3d_Normal;
94907
+ vec4 x3d_TransformedVertex=getInstanceVertex(getSkinVertex(x3d_Vertex,x3d_Normal));vec4 position=x3d_ModelViewMatrix*x3d_TransformedVertex;vertex=position.xyz;normal=getInstanceNormal(getSkinNormal(x3d_Normal));
94770
94908
  #if defined(X3D_GEOMETRY_0D)
94771
94909
  #if defined(X3D_STYLE_PROPERTIES)
94772
94910
  gl_PointSize=max(pointSize=getPointSize(vertex),2.0);
@@ -95339,7 +95477,7 @@ const ShaderRegistry = {
95339
95477
  Line2: Line22_glsl,
95340
95478
  Material: Material2_glsl,
95341
95479
  Normal: Normal2_glsl,
95342
- Particle: Particle2_glsl,
95480
+ Instancing: Instancing2_glsl,
95343
95481
  Perlin: Perlin2_glsl,
95344
95482
  Point: Point2_glsl,
95345
95483
  PointSize: PointSize2_glsl,
@@ -95504,7 +95642,7 @@ const ShaderCompiler_default_ = ShaderCompiler;
95504
95642
  x_ite_Namespace .add ("ShaderCompiler", "x_ite/Browser/Shaders/ShaderCompiler", ShaderCompiler_default_);
95505
95643
  /* harmony default export */ const Shaders_ShaderCompiler = (ShaderCompiler_default_);
95506
95644
  ;// CONCATENATED MODULE: ./src/x_ite/Components/Shaders/ShaderPart.js
95507
- /* provided dependency */ var ShaderPart_$ = __webpack_require__(349);
95645
+ /* provided dependency */ var ShaderPart_$ = __webpack_require__(275);
95508
95646
  /*******************************************************************************
95509
95647
  *
95510
95648
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -96161,7 +96299,7 @@ const X3DAppearanceNode_default_ = X3DAppearanceNode;
96161
96299
  x_ite_Namespace .add ("X3DAppearanceNode", "x_ite/Components/Shape/X3DAppearanceNode", X3DAppearanceNode_default_);
96162
96300
  /* harmony default export */ const Shape_X3DAppearanceNode = (X3DAppearanceNode_default_);
96163
96301
  ;// CONCATENATED MODULE: ./src/x_ite/Components/Shape/Appearance.js
96164
- /* provided dependency */ var Appearance_$ = __webpack_require__(349);
96302
+ /* provided dependency */ var Appearance_$ = __webpack_require__(275);
96165
96303
  /*******************************************************************************
96166
96304
  *
96167
96305
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -97122,7 +97260,8 @@ Object .assign (Object .setPrototypeOf (X3DMaterialNode .prototype, Shape_X3DApp
97122
97260
  key += textureNode ?.getTextureBits () .toString (16) ?? 0;
97123
97261
  }
97124
97262
 
97125
- return this .shaderNodes .get (key) ?? this .createShader (key, geometryContext, renderContext);
97263
+ return this .shaderNodes .get (key)
97264
+ ?? this .createShader (key, geometryContext, renderContext);
97126
97265
  },
97127
97266
  getShaderOptions (geometryContext, renderContext)
97128
97267
  {
@@ -97265,10 +97404,13 @@ Object .assign (Object .setPrototypeOf (X3DMaterialNode .prototype, Shape_X3DApp
97265
97404
  switch (shapeNode .getShapeKey ())
97266
97405
  {
97267
97406
  case 1:
97268
- options .push ("X3D_PARTICLE_SYSTEM");
97407
+ options .push ("X3D_INSTANCING");
97269
97408
  break;
97270
97409
  case 2:
97271
- options .push ("X3D_PARTICLE_SYSTEM", "X3D_TEX_COORD_RAMP");
97410
+ options .push ("X3D_INSTANCING", "X3D_TEX_COORD_RAMP");
97411
+ break;
97412
+ case 3:
97413
+ options .push ("X3D_INSTANCING", "X3D_INSTANCE_NORMAL");
97272
97414
  break;
97273
97415
  }
97274
97416
  }
@@ -98708,6 +98850,10 @@ Object .assign (Object .setPrototypeOf (X3DShapeNode .prototype, Core_X3DChildNo
98708
98850
  {
98709
98851
  return this .geometryNode;
98710
98852
  },
98853
+ getGeometryContext ()
98854
+ {
98855
+ return this .getGeometry ();
98856
+ },
98711
98857
  set_appearance__ ()
98712
98858
  {
98713
98859
  if (this .appearanceNode)
@@ -98886,7 +99032,10 @@ Object .assign (Object .setPrototypeOf (Shape .prototype, Shape_X3DShapeNode .pr
98886
99032
  {
98887
99033
  return 0;
98888
99034
  },
98889
- getGeometryContext: Shape_X3DShapeNode .prototype .getGeometry,
99035
+ getNumInstances ()
99036
+ {
99037
+ return 1;
99038
+ },
98890
99039
  set_geometry__ ()
98891
99040
  {
98892
99041
  Shape_X3DShapeNode .prototype .set_geometry__ .call (this);
@@ -98937,13 +99086,17 @@ Object .assign (Object .setPrototypeOf (Shape .prototype, Shape_X3DShapeNode .pr
98937
99086
  case Rendering_TraverseType .DISPLAY:
98938
99087
  {
98939
99088
  if (renderObject .addDisplayShape (this))
98940
- this .getAppearance () .traverse (type, renderObject); // Currently used for GeneratedCubeMapTexture.
99089
+ {
99090
+ // Currently used for GeneratedCubeMapTexture.
99091
+ this .getAppearance () .traverse (type, renderObject);
99092
+ }
98941
99093
 
98942
99094
  break;
98943
99095
  }
98944
99096
  }
98945
99097
 
98946
- this .getGeometry () .traverse (type, renderObject); // Currently used for ScreenText.
99098
+ // Currently used for ScreenText and Tools.
99099
+ this .getGeometry () .traverse (type, renderObject);
98947
99100
  },
98948
99101
  picking (renderObject)
98949
99102
  {
@@ -105095,8 +105248,8 @@ const GifMedia_default_ = GifMedia;
105095
105248
  x_ite_Namespace .add ("GifMedia", "x_ite/Browser/Texturing/GifMedia", GifMedia_default_);
105096
105249
  /* harmony default export */ const Texturing_GifMedia = (GifMedia_default_);
105097
105250
  ;// CONCATENATED MODULE: ./src/x_ite/Components/Texturing/MovieTexture.js
105098
- /* provided dependency */ var MovieTexture_$ = __webpack_require__(349);
105099
- /* provided dependency */ var SuperGif = __webpack_require__(886);
105251
+ /* provided dependency */ var MovieTexture_$ = __webpack_require__(275);
105252
+ /* provided dependency */ var SuperGif = __webpack_require__(964);
105100
105253
  /*******************************************************************************
105101
105254
  *
105102
105255
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -107701,6 +107854,8 @@ x_ite_Namespace .add ("Time", "x_ite/Components/Time", Time_default_);
107701
107854
 
107702
107855
 
107703
107856
 
107857
+ const nop = Function .prototype;
107858
+
107704
107859
  const Context =
107705
107860
  {
107706
107861
  excludes: new Set ([
@@ -107733,10 +107888,16 @@ const Context =
107733
107888
  {
107734
107889
  const ext = gl .getExtension ("OES_vertex_array_object");
107735
107890
 
107736
- gl .bindVertexArray = ext .bindVertexArrayOES .bind (ext);
107737
- gl .createVertexArray = ext .createVertexArrayOES .bind (ext);
107738
- gl .deleteVertexArray = ext .deleteVertexArrayOES .bind (ext);
107739
- gl .isVertexArray = ext .isVertexArrayOES .bind (ext);
107891
+ gl .bindVertexArray = ext ?.bindVertexArrayOES .bind (ext) ?? nop;
107892
+ gl .createVertexArray = ext ?.createVertexArrayOES .bind (ext) ?? nop;
107893
+ gl .deleteVertexArray = ext ?.deleteVertexArrayOES .bind (ext) ?? nop;
107894
+ gl .isVertexArray = ext ?.isVertexArrayOES .bind (ext) ?? nop;
107895
+ }
107896
+
107897
+ {
107898
+ const ext = gl .getExtension ("ANGLE_instanced_arrays");
107899
+
107900
+ gl .drawArraysInstanced = ext ?.drawArraysInstancedANGLE .bind (ext) ?? nop;
107740
107901
  }
107741
107902
  }
107742
107903
  }
@@ -107758,7 +107919,7 @@ const Context =
107758
107919
 
107759
107920
  if (aliasedLineWidthRange [0] === 1 && aliasedLineWidthRange [1] === 1)
107760
107921
  {
107761
- gl .lineWidth = Function .prototype;
107922
+ gl .lineWidth = nop;
107762
107923
  gl .HAS_FEATURE_TRANSFORMED_LINES = gl .getVersion () >= 2;
107763
107924
 
107764
107925
  if (DEVELOPMENT)
@@ -107881,378 +108042,7 @@ const Context_default_ = Context;
107881
108042
 
107882
108043
  x_ite_Namespace .add ("Context", "x_ite/Browser/Core/Context", Context_default_);
107883
108044
  /* harmony default export */ const Core_Context = (Context_default_);
107884
- ;// CONCATENATED MODULE: ./src/locale/de.po.js
107885
- const de_po_default_ = `msgid ""
107886
- msgstr ""
107887
- "Project-Id-Version: X_ITE\n"
107888
- "POT-Creation-Date: 2015-12-23 04:56+0100\n"
107889
- "PO-Revision-Date: 2015-12-23 04:57+0100\n"
107890
- "Last-Translator: Holger Seelig <holger.seelig@yahoo.de>\n"
107891
- "Language-Team: \n"
107892
- "Language: de\n"
107893
- "MIME-Version: 1.0\n"
107894
- "Content-Type: text/plain; charset=UTF-8\n"
107895
- "Content-Transfer-Encoding: 8bit\n"
107896
- "X-Generator: Poedit 1.8.4\n"
107897
- "X-Poedit-Basepath: ../x_ite\n"
107898
- "Plural-Forms: nplurals=2; plural=(n != 1);\n"
107899
- "X-Poedit-SourceCharset: UTF-8\n"
107900
- "X-Poedit-SearchPath-0: .\n"
107901
-
107902
- msgid "Less Properties"
107903
- msgstr "Weniger Eigenschaften"
107904
-
107905
- msgid "More Properties"
107906
- msgstr "Mehr Eigenschaften"
107907
-
107908
- msgid "Frame rate"
107909
- msgstr "Bildrate"
107910
-
107911
- msgid "fps"
107912
- msgstr "BpS"
107913
-
107914
- msgid "Speed"
107915
- msgstr "Geschwindigkeit"
107916
-
107917
- msgid "m/s"
107918
- msgstr ""
107919
-
107920
- msgid "km/h"
107921
- msgstr ""
107922
-
107923
- msgid "Browser"
107924
- msgstr ""
107925
-
107926
- msgid "ms"
107927
- msgstr ""
107928
-
107929
- msgid "X3D total"
107930
- msgstr "X3D gesamt"
107931
-
107932
- msgid "Event Processing"
107933
- msgstr "Ereignisverarbeitung"
107934
-
107935
- msgid "Pointer"
107936
- msgstr "Zeigegerät"
107937
-
107938
- msgid "Camera"
107939
- msgstr "Kamera"
107940
-
107941
- msgid "Collision Detection"
107942
- msgstr "Kollisionserkennung"
107943
-
107944
- msgid "Rendering"
107945
- msgstr "Rendering"
107946
-
107947
- msgid "Number of Shapes"
107948
- msgstr "Anzahl der Formen"
107949
-
107950
- msgid "Number of Sensors"
107951
- msgstr "Anzahl der Sensoren"
107952
-
107953
- msgid "Browser Timings"
107954
- msgstr "Zeitberechnung"
107955
-
107956
- msgid "X_ITE Browser"
107957
- msgstr ""
107958
-
107959
- msgid "Viewpoints"
107960
- msgstr "Ansichtspunkte"
107961
-
107962
- msgid "Available Viewers"
107963
- msgstr "Verfügbare Betrachter"
107964
-
107965
- msgid "Straighten Horizon"
107966
- msgstr "Horizont gerade richten"
107967
-
107968
- msgid "Primitive Quality"
107969
- msgstr "Qualität der Grundobjekte"
107970
-
107971
- msgid "High"
107972
- msgstr "Hoch"
107973
-
107974
- msgid "high"
107975
- msgstr "hoch"
107976
-
107977
- msgid "Medium"
107978
- msgstr "Mittel"
107979
-
107980
- msgid "medium"
107981
- msgstr "mittel"
107982
-
107983
- msgid "Low"
107984
- msgstr "Niedrig"
107985
-
107986
- msgid "low"
107987
- msgstr "niedrig"
107988
-
107989
- msgid "Texture Quality"
107990
- msgstr "Textur Qualität"
107991
-
107992
- msgid "Display Rubberband"
107993
- msgstr "Gummiband anzeigen"
107994
-
107995
- msgid "Rubberband"
107996
- msgstr "Gummiband"
107997
-
107998
- msgid "on"
107999
- msgstr "an"
108000
-
108001
- msgid "off"
108002
- msgstr "aus"
108003
-
108004
- msgid "Mute Browser"
108005
- msgstr "Browser stumm schalten"
108006
-
108007
- msgid "Browser muted"
108008
- msgstr "Browser stumm geschalten"
108009
-
108010
- msgid "Browser unmuted"
108011
- msgstr "Browser Ton an"
108012
-
108013
- msgid "Leave Fullscreen"
108014
- msgstr "Vollbild verlassen"
108015
-
108016
- msgid "Fullscreen"
108017
- msgstr "Vollbild"
108018
-
108019
- msgid "About X_ITE"
108020
- msgstr "Über X_ITE"
108021
-
108022
- msgid "Examine Viewer"
108023
- msgstr "Untersuchen"
108024
-
108025
- msgid "Walk Viewer"
108026
- msgstr "Laufen"
108027
-
108028
- msgid "Fly Viewer"
108029
- msgstr "Fliegen"
108030
-
108031
- msgid "Plane Viewer"
108032
- msgstr "Ebenen Betrachter"
108033
-
108034
- msgid "Look At Viewer"
108035
- msgstr "Auf Objekte zielen"
108036
-
108037
- msgid "None Viewer"
108038
- msgstr "Kein Betrachter"
108039
-
108040
- msgid "Points"
108041
- msgstr "Punkte"
108042
-
108043
- msgid "Flat"
108044
- msgstr "Flach"
108045
-
108046
- msgid "Wireframe"
108047
- msgstr "Drahtgittermodel"
108048
-
108049
- msgid "Loading %1 file"
108050
- msgstr "Lade %1 Datei"
108051
-
108052
- msgid "Loading %1 files"
108053
- msgstr "Lade %1 Dateien"
108054
-
108055
- msgid "Loading done"
108056
- msgstr "Fertig mit Laden"
108057
-
108058
- msgid "Failed loading world."
108059
- msgstr "Laden der Dateien fehlgeschlagen."
108060
-
108061
- msgid "Show World Info"
108062
- msgstr "World Info anzeigen"
108063
-
108064
- msgid "Viewpoint is copied to clipboard."
108065
- msgstr "Ansichtspunkt wurde in die Zwischenablage kopiert."
108066
- `;
108067
- ;
108068
-
108069
- x_ite_Namespace .add ("de.po", "locale/de.po", de_po_default_);
108070
- /* harmony default export */ const de_po = (de_po_default_);
108071
- ;// CONCATENATED MODULE: ./src/locale/fr.po.js
108072
- const fr_po_default_ = `msgid ""
108073
- msgstr ""
108074
- "Project-Id-Version: X_ITE\n"
108075
- "POT-Creation-Date: 2015-12-23 04:58+0100\n"
108076
- "PO-Revision-Date: 2015-12-23 05:07+0100\n"
108077
- "Last-Translator: Holger Seelig <holger.seelig@yahoo.de>\n"
108078
- "Language-Team: \n"
108079
- "Language: fr\n"
108080
- "MIME-Version: 1.0\n"
108081
- "Content-Type: text/plain; charset=UTF-8\n"
108082
- "Content-Transfer-Encoding: 8bit\n"
108083
- "X-Generator: Poedit 1.8.4\n"
108084
- "X-Poedit-Basepath: ../x_ite\n"
108085
- "Plural-Forms: nplurals=2; plural=(n != 1);\n"
108086
- "X-Poedit-SourceCharset: UTF-8\n"
108087
- "X-Poedit-SearchPath-0: .\n"
108088
-
108089
- msgid "Less Properties"
108090
- msgstr "Moins de Propriétés"
108091
-
108092
- msgid "More Properties"
108093
- msgstr "Plus de Propriétés"
108094
-
108095
- msgid "Frame rate"
108096
- msgstr "Fréquence d'Images"
108097
-
108098
- msgid "fps"
108099
- msgstr "fps"
108100
-
108101
- msgid "Speed"
108102
- msgstr "Vélocité"
108103
-
108104
- msgid "m/s"
108105
- msgstr ""
108106
-
108107
- msgid "km/h"
108108
- msgstr ""
108109
-
108110
- msgid "Browser"
108111
- msgstr "X_ITE Navigateur"
108112
-
108113
- msgid "ms"
108114
- msgstr ""
108115
-
108116
- msgid "X3D total"
108117
- msgstr "X3D total"
108118
-
108119
- msgid "Event Processing"
108120
- msgstr "Traitement des Événements"
108121
-
108122
- msgid "Pointer"
108123
- msgstr "Pointeur"
108124
-
108125
- msgid "Camera"
108126
- msgstr "Caméra"
108127
-
108128
- msgid "Collision Detection"
108129
- msgstr "Détection des Collisions"
108130
-
108131
- msgid "Rendering"
108132
- msgstr "Rendement"
108133
-
108134
- msgid "Number of Shapes"
108135
- msgstr "Nombre de Formes"
108136
-
108137
- msgid "Number of Sensors"
108138
- msgstr "Nombre de Senseurs"
108139
-
108140
- msgid "Browser Timings"
108141
- msgstr "Calcul du Temps"
108142
-
108143
- msgid "X_ITE Browser"
108144
- msgstr "X_ITE Navigateur"
108145
-
108146
- msgid "Viewpoints"
108147
- msgstr "Points de Vue"
108148
-
108149
- msgid "Available Viewers"
108150
- msgstr "Visionneurs disponibles"
108151
-
108152
- msgid "Straighten Horizon"
108153
- msgstr "Redresser l'Horizon"
108154
-
108155
- msgid "Primitive Quality"
108156
- msgstr "Qualité des Objets simples"
108157
-
108158
- msgid "High"
108159
- msgstr "Haut"
108160
-
108161
- msgid "high"
108162
- msgstr "haut"
108163
-
108164
- msgid "Medium"
108165
- msgstr "Moyenne"
108166
-
108167
- msgid "medium"
108168
- msgstr "moyenne"
108169
-
108170
- msgid "Low"
108171
- msgstr "Faible"
108172
-
108173
- msgid "low"
108174
- msgstr "faible"
108175
-
108176
- msgid "Texture Quality"
108177
- msgstr "Qualité des Textures"
108178
-
108179
- msgid "Display Rubberband"
108180
- msgstr "Présenter le Bande élastique"
108181
-
108182
- msgid "Rubberband"
108183
- msgstr "Bande élastique"
108184
-
108185
- msgid "on"
108186
- msgstr "marche"
108187
-
108188
- msgid "off"
108189
- msgstr "arrêt"
108190
-
108191
- msgid "Mute Browser"
108192
- msgstr "Rendre Navigateur muet"
108193
-
108194
- msgid "Browser muted"
108195
- msgstr "Navigateur muet"
108196
-
108197
- msgid "Browser unmuted"
108198
- msgstr "Son de Navigateur réactivé"
108199
-
108200
- msgid "Leave Fullscreen"
108201
- msgstr "Laisser le plein Écran"
108202
-
108203
- msgid "Fullscreen"
108204
- msgstr "Plein Écran"
108205
-
108206
- msgid "About X_ITE"
108207
- msgstr "À propos de X_ITE"
108208
-
108209
- msgid "Examine Viewer"
108210
- msgstr "Examiner"
108211
-
108212
- msgid "Walk Viewer"
108213
- msgstr "Aller"
108214
-
108215
- msgid "Fly Viewer"
108216
- msgstr "Voler"
108217
-
108218
- msgid "Plane Viewer"
108219
- msgstr "Visionneur de la Plaine"
108220
-
108221
- msgid "Look At Viewer"
108222
- msgstr "Regarder un Objet de près"
108223
-
108224
- msgid "None Viewer"
108225
- msgstr "Pas de Visionneur"
108226
-
108227
- msgid "Flat"
108228
- msgstr "Plat"
108229
-
108230
- msgid "Wireframe"
108231
- msgstr "Image filaire"
108232
-
108233
- msgid "Loading %1 file"
108234
- msgstr "Télécharger %1 Fichier"
108235
-
108236
- msgid "Loading %1 files"
108237
- msgstr "Télécharger %1 Fichiers"
108238
-
108239
- msgid "Loading done"
108240
- msgstr "Téléchargement fini"
108241
-
108242
- msgid "Failed loading world."
108243
- msgstr "Le chargement des Fichiers a échoué."
108244
-
108245
- msgid "Show World Info"
108246
- msgstr "Afficher World Info"
108247
-
108248
- msgid "Viewpoint is copied to clipboard."
108249
- msgstr "Le point de Vue est copié dans le Presse-Papiers."
108250
- `;
108251
- ;
108252
-
108253
- x_ite_Namespace .add ("fr.po", "locale/fr.po", fr_po_default_);
108254
- /* harmony default export */ const fr_po = (fr_po_default_);
108255
- ;// CONCATENATED MODULE: ./src/locale/gettext.js
108045
+ ;// CONCATENATED MODULE: ./src/x_ite/Browser/ParticleSystems/GeometryTypes.js
108256
108046
  /*******************************************************************************
108257
108047
  *
108258
108048
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -108300,20 +108090,535 @@ x_ite_Namespace .add ("fr.po", "locale/fr.po", fr_po_default_);
108300
108090
  *
108301
108091
  ******************************************************************************/
108302
108092
 
108093
+ let GeometryTypes_i = 0;
108303
108094
 
108095
+ const GeometryTypes = {
108096
+ POINT: GeometryTypes_i ++,
108097
+ LINE: GeometryTypes_i ++,
108098
+ TRIANGLE: GeometryTypes_i ++,
108099
+ QUAD: GeometryTypes_i ++,
108100
+ SPRITE: GeometryTypes_i ++,
108101
+ GEOMETRY: GeometryTypes_i ++,
108102
+ };
108304
108103
 
108104
+ const GeometryTypes_default_ = GeometryTypes;
108105
+ ;
108305
108106
 
108306
- function execAll (regex, string)
108307
- {
108308
- const matches = [ ];
108107
+ x_ite_Namespace .add ("GeometryTypes", "x_ite/Browser/ParticleSystems/GeometryTypes", GeometryTypes_default_);
108108
+ /* harmony default export */ const ParticleSystems_GeometryTypes = (GeometryTypes_default_);
108109
+ ;// CONCATENATED MODULE: ./src/locale/de.js
108110
+ const de_default_ = [
108111
+ [
108112
+ "Less Properties",
108113
+ "Weniger Eigenschaften",
108114
+ ],
108115
+ [
108116
+ "More Properties",
108117
+ "Mehr Eigenschaften",
108118
+ ],
108119
+ [
108120
+ "Frame rate",
108121
+ "Bildrate",
108122
+ ],
108123
+ [
108124
+ "fps",
108125
+ "BpS",
108126
+ ],
108127
+ [
108128
+ "Speed",
108129
+ "Geschwindigkeit",
108130
+ ],
108131
+ [
108132
+ "m/s",
108133
+ "",
108134
+ ],
108135
+ [
108136
+ "km/h",
108137
+ "",
108138
+ ],
108139
+ [
108140
+ "Browser",
108141
+ "",
108142
+ ],
108143
+ [
108144
+ "ms",
108145
+ "",
108146
+ ],
108147
+ [
108148
+ "X3D total",
108149
+ "X3D gesamt",
108150
+ ],
108151
+ [
108152
+ "Event Processing",
108153
+ "Ereignisverarbeitung",
108154
+ ],
108155
+ [
108156
+ "Pointer",
108157
+ "Zeigegerät",
108158
+ ],
108159
+ [
108160
+ "Camera",
108161
+ "Kamera",
108162
+ ],
108163
+ [
108164
+ "Collision Detection",
108165
+ "Kollisionserkennung",
108166
+ ],
108167
+ [
108168
+ "Rendering",
108169
+ "Rendering",
108170
+ ],
108171
+ [
108172
+ "Number of Primitives",
108173
+ "Anzahl der Grundobjekte",
108174
+ ],
108175
+ [
108176
+ "Number of Shapes",
108177
+ "Anzahl der Formen",
108178
+ ],
108179
+ [
108180
+ "Number of Sensors",
108181
+ "Anzahl der Sensoren",
108182
+ ],
108183
+ [
108184
+ "Browser Timings",
108185
+ "Zeitberechnung",
108186
+ ],
108187
+ [
108188
+ "X_ITE Browser",
108189
+ "",
108190
+ ],
108191
+ [
108192
+ "Viewpoints",
108193
+ "Ansichtspunkte",
108194
+ ],
108195
+ [
108196
+ "Available Viewers",
108197
+ "Verfügbare Betrachter",
108198
+ ],
108199
+ [
108200
+ "Straighten Horizon",
108201
+ "Horizont gerade richten",
108202
+ ],
108203
+ [
108204
+ "Primitive Quality",
108205
+ "Qualität der Grundobjekte",
108206
+ ],
108207
+ [
108208
+ "High",
108209
+ "Hoch",
108210
+ ],
108211
+ [
108212
+ "high",
108213
+ "hoch",
108214
+ ],
108215
+ [
108216
+ "Medium",
108217
+ "Mittel",
108218
+ ],
108219
+ [
108220
+ "medium",
108221
+ "mittel",
108222
+ ],
108223
+ [
108224
+ "Low",
108225
+ "Niedrig",
108226
+ ],
108227
+ [
108228
+ "low",
108229
+ "niedrig",
108230
+ ],
108231
+ [
108232
+ "Texture Quality",
108233
+ "Textur Qualität",
108234
+ ],
108235
+ [
108236
+ "Display Rubberband",
108237
+ "Gummiband anzeigen",
108238
+ ],
108239
+ [
108240
+ "Rubberband",
108241
+ "Gummiband",
108242
+ ],
108243
+ [
108244
+ "on",
108245
+ "an",
108246
+ ],
108247
+ [
108248
+ "off",
108249
+ "aus",
108250
+ ],
108251
+ [
108252
+ "Mute Browser",
108253
+ "Browser stumm schalten",
108254
+ ],
108255
+ [
108256
+ "Browser muted",
108257
+ "Browser stumm geschalten",
108258
+ ],
108259
+ [
108260
+ "Browser unmuted",
108261
+ "Browser Ton an",
108262
+ ],
108263
+ [
108264
+ "Leave Fullscreen",
108265
+ "Vollbild verlassen",
108266
+ ],
108267
+ [
108268
+ "Fullscreen",
108269
+ "Vollbild",
108270
+ ],
108271
+ [
108272
+ "About X_ITE",
108273
+ "Über X_ITE",
108274
+ ],
108275
+ [
108276
+ "Examine Viewer",
108277
+ "Untersuchen",
108278
+ ],
108279
+ [
108280
+ "Walk Viewer",
108281
+ "Laufen",
108282
+ ],
108283
+ [
108284
+ "Fly Viewer",
108285
+ "Fliegen",
108286
+ ],
108287
+ [
108288
+ "Plane Viewer",
108289
+ "Ebenen Betrachter",
108290
+ ],
108291
+ [
108292
+ "Look At Viewer",
108293
+ "Auf Objekte zielen",
108294
+ ],
108295
+ [
108296
+ "None Viewer",
108297
+ "Kein Betrachter",
108298
+ ],
108299
+ [
108300
+ "Points",
108301
+ "Punkte",
108302
+ ],
108303
+ [
108304
+ "Flat",
108305
+ "Flach",
108306
+ ],
108307
+ [
108308
+ "Wireframe",
108309
+ "Drahtgittermodel",
108310
+ ],
108311
+ [
108312
+ "Loading %1 file",
108313
+ "Lade %1 Datei",
108314
+ ],
108315
+ [
108316
+ "Loading %1 files",
108317
+ "Lade %1 Dateien",
108318
+ ],
108319
+ [
108320
+ "Loading done",
108321
+ "Fertig mit Laden",
108322
+ ],
108323
+ [
108324
+ "Failed loading world.",
108325
+ "Laden der Dateien fehlgeschlagen.",
108326
+ ],
108327
+ [
108328
+ "Show World Info",
108329
+ "World Info anzeigen",
108330
+ ],
108331
+ [
108332
+ "Viewpoint is copied to clipboard.",
108333
+ "Ansichtspunkt wurde in die Zwischenablage kopiert.",
108334
+ ],
108335
+ ];
108336
+ ;
108337
+
108338
+ x_ite_Namespace .add ("de", "locale/de", de_default_);
108339
+ /* harmony default export */ const de = (de_default_);
108340
+ ;// CONCATENATED MODULE: ./src/locale/fr.js
108341
+ const fr_default_ = [
108342
+ [
108343
+ "Less Properties",
108344
+ "Moins de Propriétés",
108345
+ ],
108346
+ [
108347
+ "More Properties",
108348
+ "Plus de Propriétés",
108349
+ ],
108350
+ [
108351
+ "Frame rate",
108352
+ "Fréquence d'Images",
108353
+ ],
108354
+ [
108355
+ "fps",
108356
+ "fps",
108357
+ ],
108358
+ [
108359
+ "Speed",
108360
+ "Vélocité",
108361
+ ],
108362
+ [
108363
+ "m/s",
108364
+ "",
108365
+ ],
108366
+ [
108367
+ "km/h",
108368
+ "",
108369
+ ],
108370
+ [
108371
+ "Browser",
108372
+ "X_ITE Navigateur",
108373
+ ],
108374
+ [
108375
+ "ms",
108376
+ "",
108377
+ ],
108378
+ [
108379
+ "X3D total",
108380
+ "X3D total",
108381
+ ],
108382
+ [
108383
+ "Event Processing",
108384
+ "Traitement des Événements",
108385
+ ],
108386
+ [
108387
+ "Pointer",
108388
+ "Pointeur",
108389
+ ],
108390
+ [
108391
+ "Camera",
108392
+ "Caméra",
108393
+ ],
108394
+ [
108395
+ "Collision Detection",
108396
+ "Détection des Collisions",
108397
+ ],
108398
+ [
108399
+ "Rendering",
108400
+ "Rendement",
108401
+ ],
108402
+ [
108403
+ "Number of Primitives",
108404
+ "Nombre d'Objets de Base",
108405
+ ],
108406
+ [
108407
+ "Number of Shapes",
108408
+ "Nombre de Formes",
108409
+ ],
108410
+ [
108411
+ "Number of Sensors",
108412
+ "Nombre de Senseurs",
108413
+ ],
108414
+ [
108415
+ "Browser Timings",
108416
+ "Calcul du Temps",
108417
+ ],
108418
+ [
108419
+ "X_ITE Browser",
108420
+ "X_ITE Navigateur",
108421
+ ],
108422
+ [
108423
+ "Viewpoints",
108424
+ "Points de Vue",
108425
+ ],
108426
+ [
108427
+ "Available Viewers",
108428
+ "Visionneurs disponibles",
108429
+ ],
108430
+ [
108431
+ "Straighten Horizon",
108432
+ "Redresser l'Horizon",
108433
+ ],
108434
+ [
108435
+ "Primitive Quality",
108436
+ "Qualité des Objets simples",
108437
+ ],
108438
+ [
108439
+ "High",
108440
+ "Haut",
108441
+ ],
108442
+ [
108443
+ "high",
108444
+ "haut",
108445
+ ],
108446
+ [
108447
+ "Medium",
108448
+ "Moyenne",
108449
+ ],
108450
+ [
108451
+ "medium",
108452
+ "moyenne",
108453
+ ],
108454
+ [
108455
+ "Low",
108456
+ "Faible",
108457
+ ],
108458
+ [
108459
+ "low",
108460
+ "faible",
108461
+ ],
108462
+ [
108463
+ "Texture Quality",
108464
+ "Qualité des Textures",
108465
+ ],
108466
+ [
108467
+ "Display Rubberband",
108468
+ "Présenter le Bande élastique",
108469
+ ],
108470
+ [
108471
+ "Rubberband",
108472
+ "Bande élastique",
108473
+ ],
108474
+ [
108475
+ "on",
108476
+ "marche",
108477
+ ],
108478
+ [
108479
+ "off",
108480
+ "arrêt",
108481
+ ],
108482
+ [
108483
+ "Mute Browser",
108484
+ "Rendre Navigateur muet",
108485
+ ],
108486
+ [
108487
+ "Browser muted",
108488
+ "Navigateur muet",
108489
+ ],
108490
+ [
108491
+ "Browser unmuted",
108492
+ "Son de Navigateur réactivé",
108493
+ ],
108494
+ [
108495
+ "Leave Fullscreen",
108496
+ "Laisser le plein Écran",
108497
+ ],
108498
+ [
108499
+ "Fullscreen",
108500
+ "Plein Écran",
108501
+ ],
108502
+ [
108503
+ "About X_ITE",
108504
+ "À propos de X_ITE",
108505
+ ],
108506
+ [
108507
+ "Examine Viewer",
108508
+ "Examiner",
108509
+ ],
108510
+ [
108511
+ "Walk Viewer",
108512
+ "Aller",
108513
+ ],
108514
+ [
108515
+ "Fly Viewer",
108516
+ "Voler",
108517
+ ],
108518
+ [
108519
+ "Plane Viewer",
108520
+ "Visionneur de la Plaine",
108521
+ ],
108522
+ [
108523
+ "Look At Viewer",
108524
+ "Regarder un Objet de près",
108525
+ ],
108526
+ [
108527
+ "None Viewer",
108528
+ "Pas de Visionneur",
108529
+ ],
108530
+ [
108531
+ "Flat",
108532
+ "Plat",
108533
+ ],
108534
+ [
108535
+ "Wireframe",
108536
+ "Image filaire",
108537
+ ],
108538
+ [
108539
+ "Loading %1 file",
108540
+ "Télécharger %1 Fichier",
108541
+ ],
108542
+ [
108543
+ "Loading %1 files",
108544
+ "Télécharger %1 Fichiers",
108545
+ ],
108546
+ [
108547
+ "Loading done",
108548
+ "Téléchargement fini",
108549
+ ],
108550
+ [
108551
+ "Failed loading world.",
108552
+ "Le chargement des Fichiers a échoué.",
108553
+ ],
108554
+ [
108555
+ "Show World Info",
108556
+ "Afficher World Info",
108557
+ ],
108558
+ [
108559
+ "Viewpoint is copied to clipboard.",
108560
+ "Le point de Vue est copié dans le Presse-Papiers.",
108561
+ ]
108562
+ ];
108563
+ ;
108564
+
108565
+ x_ite_Namespace .add ("fr", "locale/fr", fr_default_);
108566
+ /* harmony default export */ const fr = (fr_default_);
108567
+ ;// CONCATENATED MODULE: ./src/locale/gettext.js
108568
+ /*******************************************************************************
108569
+ *
108570
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
108571
+ *
108572
+ * Copyright create3000, Scheffelstraße 31a, Leipzig, Germany 2011 - 2022.
108573
+ *
108574
+ * All rights reserved. Holger Seelig <holger.seelig@yahoo.de>.
108575
+ *
108576
+ * The copyright notice above does not evidence any actual of intended
108577
+ * publication of such source code, and is an unpublished work by create3000.
108578
+ * This material contains CONFIDENTIAL INFORMATION that is the property of
108579
+ * create3000.
108580
+ *
108581
+ * No permission is granted to copy, distribute, or create derivative works from
108582
+ * the contents of this software, in whole or in part, without the prior written
108583
+ * permission of create3000.
108584
+ *
108585
+ * NON-MILITARY USE ONLY
108586
+ *
108587
+ * All create3000 software are effectively free software with a non-military use
108588
+ * restriction. It is free. Well commented source is provided. You may reuse the
108589
+ * source in any way you please with the exception anything that uses it must be
108590
+ * marked to indicate is contains 'non-military use only' components.
108591
+ *
108592
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
108593
+ *
108594
+ * Copyright 2011 - 2022, Holger Seelig <holger.seelig@yahoo.de>.
108595
+ *
108596
+ * This file is part of the X_ITE Project.
108597
+ *
108598
+ * X_ITE is free software: you can redistribute it and/or modify it under the
108599
+ * terms of the GNU General Public License version 3 only, as published by the
108600
+ * Free Software Foundation.
108601
+ *
108602
+ * X_ITE is distributed in the hope that it will be useful, but WITHOUT ANY
108603
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
108604
+ * A PARTICULAR PURPOSE. See the GNU General Public License version 3 for more
108605
+ * details (a copy is included in the LICENSE file that accompanied this code).
108606
+ *
108607
+ * You should have received a copy of the GNU General Public License version 3
108608
+ * along with X_ITE. If not, see <https://www.gnu.org/licenses/gpl.html> for a
108609
+ * copy of the GPLv3 License.
108610
+ *
108611
+ * For Silvio, Joy and Adi.
108612
+ *
108613
+ ******************************************************************************/
108309
108614
 
108310
- let match = null;
108311
108615
 
108312
- while (match = regex .exec (string))
108313
- matches .push (match);
108314
108616
 
108315
- return matches;
108316
- }
108617
+
108618
+ const locales = new Map ([
108619
+ ["de", de],
108620
+ ["fr", fr],
108621
+ ]);
108317
108622
 
108318
108623
  function getLanguage ()
108319
108624
  {
@@ -108321,64 +108626,22 @@ function getLanguage ()
108321
108626
  {
108322
108627
  const language = value .split ("-") [0];
108323
108628
 
108324
- if (locales [language])
108629
+ if (locales .get (language))
108325
108630
  return language;
108326
108631
  }
108327
108632
 
108328
108633
  return (navigator .language || navigator .userLanguage) .split ("-") [0];
108329
108634
  }
108330
108635
 
108331
- function setLocale (language)
108332
- {
108333
- if (locales [language])
108334
- {
108335
- const
108336
- matches = execAll (msg, locales [language]),
108337
- locale = locales [language] = { };
108636
+ const locale = new Map (locales .get (getLanguage ()) ?? [ ]);
108338
108637
 
108339
- for (var i = 0, length = matches .length; i < length; ++ i)
108340
- {
108341
- if (matches [i] [2] .length)
108342
- locale [matches [i] [1]] = matches [i] [2];
108343
- }
108344
- }
108345
- }
108346
-
108347
- const locales =
108348
- {
108349
- en: "C",
108350
- de: de_po,
108351
- fr: fr_po,
108352
- };
108353
-
108354
- const
108355
- msg = /msgid\s+"(.*?)"\nmsgstr\s+"(.*?)"\n/g,
108356
- language = getLanguage ();
108357
-
108358
- setLocale (language);
108359
-
108360
- function gettext (string)
108361
- {
108362
- const locale = locales [language];
108363
-
108364
- if (locale === undefined)
108365
- return string;
108366
-
108367
- const translation = locale [string];
108368
-
108369
- if (translation === undefined)
108370
- return string;
108371
-
108372
- return translation;
108373
- }
108374
-
108375
- const gettext_default_ = gettext;
108638
+ const gettext_default_ = (string) => locale .get (string) || string;
108376
108639
  ;
108377
108640
 
108378
108641
  x_ite_Namespace .add ("gettext", "locale/gettext", gettext_default_);
108379
- /* harmony default export */ const locale_gettext = (gettext_default_);
108642
+ /* harmony default export */ const gettext = (gettext_default_);
108380
108643
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/BrowserTimings.js
108381
- /* provided dependency */ var BrowserTimings_$ = __webpack_require__(349);
108644
+ /* provided dependency */ var BrowserTimings_$ = __webpack_require__(275);
108382
108645
  /*******************************************************************************
108383
108646
  *
108384
108647
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -108430,12 +108693,15 @@ x_ite_Namespace .add ("gettext", "locale/gettext", gettext_default_);
108430
108693
 
108431
108694
 
108432
108695
 
108696
+
108697
+
108433
108698
  function BrowserTimings (executionContext)
108434
108699
  {
108435
108700
  Base_X3DBaseNode .call (this, executionContext);
108436
108701
 
108437
108702
  this .localStorage = this .getBrowser () .getLocalStorage () .addNameSpace ("BrowserTimings.");
108438
108703
  this .fps = new Time_StopWatch ();
108704
+ this .primitives = { };
108439
108705
  }
108440
108706
 
108441
108707
  Object .assign (Object .setPrototypeOf (BrowserTimings .prototype, Base_X3DBaseNode .prototype),
@@ -108459,7 +108725,7 @@ Object .assign (Object .setPrototypeOf (BrowserTimings .prototype, Base_X3DBaseN
108459
108725
  this .header = BrowserTimings_$("<thead></thead>")
108460
108726
  .append (BrowserTimings_$("<tr></tr>")
108461
108727
  .append (BrowserTimings_$("<th colspan='2'></th>")
108462
- .text (locale_gettext("Browser Timings"))))
108728
+ .text (gettext("Browser Timings"))))
108463
108729
  .appendTo (this .table);
108464
108730
 
108465
108731
  this .body = BrowserTimings_$("<tbody></tbody>")
@@ -108486,56 +108752,61 @@ Object .assign (Object .setPrototypeOf (BrowserTimings .prototype, Base_X3DBaseN
108486
108752
  this .pickingTime = BrowserTimings_$("<td></td>");
108487
108753
  this .collisionTime = BrowserTimings_$("<td></td>");
108488
108754
  this .renderTime = BrowserTimings_$("<td></td>");
108755
+ this .numPrimitives = BrowserTimings_$("<td></td>");
108489
108756
  this .numShapes = BrowserTimings_$("<td></td>");
108490
108757
  this .sensors = BrowserTimings_$("<td></td>");
108491
108758
 
108492
108759
  this .body .append (BrowserTimings_$("<tr></tr>")
108493
- .append (BrowserTimings_$("<td></td>") .text (locale_gettext("Frame rate") + ":"))
108760
+ .append (BrowserTimings_$("<td></td>") .text (gettext("Frame rate") + ":"))
108494
108761
  .append (this .frameRate));
108495
108762
 
108496
108763
  this .body .append (BrowserTimings_$("<tr></tr>")
108497
- .append (BrowserTimings_$("<td></td>") .text (locale_gettext("Speed") + ":"))
108764
+ .append (BrowserTimings_$("<td></td>") .text (gettext("Speed") + ":"))
108498
108765
  .append (this .speed)
108499
108766
  .addClass ("x_ite-private-more"));
108500
108767
 
108501
108768
  this .body .append (BrowserTimings_$("<tr></tr>")
108502
- .append (BrowserTimings_$("<td></td>") .text (locale_gettext("Browser") + ":"))
108769
+ .append (BrowserTimings_$("<td></td>") .text (gettext("Browser") + ":"))
108503
108770
  .append (this .browserTime));
108504
108771
 
108505
108772
  this .body .append (BrowserTimings_$("<tr></tr>")
108506
- .append (BrowserTimings_$("<td></td>") .text (locale_gettext("X3D total") + ":"))
108773
+ .append (BrowserTimings_$("<td></td>") .text (gettext("X3D total") + ":"))
108507
108774
  .append (this .x3dTotal));
108508
108775
 
108509
108776
  this .body .append (BrowserTimings_$("<tr></tr>")
108510
- .append (BrowserTimings_$("<td></td>") .text (locale_gettext("Event Processing") + ":"))
108777
+ .append (BrowserTimings_$("<td></td>") .text (gettext("Event Processing") + ":"))
108511
108778
  .append (this .eventProcessing));
108512
108779
 
108513
108780
  this .body .append (BrowserTimings_$("<tr></tr>")
108514
- .append (BrowserTimings_$("<td></td>") .text (locale_gettext("Pointer") + ":"))
108781
+ .append (BrowserTimings_$("<td></td>") .text (gettext("Pointer") + ":"))
108515
108782
  .append (this .pointerTime));
108516
108783
 
108517
108784
  this .body .append (BrowserTimings_$("<tr></tr>")
108518
- .append (BrowserTimings_$("<td></td>") .text (locale_gettext("Camera") + ":"))
108785
+ .append (BrowserTimings_$("<td></td>") .text (gettext("Camera") + ":"))
108519
108786
  .append (this .cameraTime));
108520
108787
 
108521
108788
  this .body .append (BrowserTimings_$("<tr></tr>")
108522
- .append (BrowserTimings_$("<td></td>") .text (locale_gettext("Picking") + ":"))
108789
+ .append (BrowserTimings_$("<td></td>") .text (gettext("Picking") + ":"))
108523
108790
  .append (this .pickingTime));
108524
108791
 
108525
108792
  this .body .append (BrowserTimings_$("<tr></tr>")
108526
- .append (BrowserTimings_$("<td></td>") .text (locale_gettext("Collision Detection") + ":"))
108793
+ .append (BrowserTimings_$("<td></td>") .text (gettext("Collision Detection") + ":"))
108527
108794
  .append (this .collisionTime));
108528
108795
 
108529
108796
  this .body .append (BrowserTimings_$("<tr></tr>")
108530
- .append (BrowserTimings_$("<td></td>") .text (locale_gettext("Rendering") + ":"))
108797
+ .append (BrowserTimings_$("<td></td>") .text (gettext("Rendering") + ":"))
108531
108798
  .append (this .renderTime));
108532
108799
 
108533
108800
  this .body .append (BrowserTimings_$("<tr></tr>")
108534
- .append (BrowserTimings_$("<td></td>") .text (locale_gettext("Number of Shapes") + ":"))
108801
+ .append (BrowserTimings_$("<td></td>") .text (gettext("Number of Primitives") + ":"))
108802
+ .append (this .numPrimitives));
108803
+
108804
+ this .body .append (BrowserTimings_$("<tr></tr>")
108805
+ .append (BrowserTimings_$("<td></td>") .text (gettext("Number of Shapes") + ":"))
108535
108806
  .append (this .numShapes));
108536
108807
 
108537
108808
  this .body .append (BrowserTimings_$("<tr></tr>")
108538
- .append (BrowserTimings_$("<td></td>") .text (locale_gettext("Number of Sensors") + ":"))
108809
+ .append (BrowserTimings_$("<td></td>") .text (gettext("Number of Sensors") + ":"))
108539
108810
  .append (this .sensors));
108540
108811
 
108541
108812
  this .button .on ("click touchend", this .set_type__ .bind (this));
@@ -108550,13 +108821,14 @@ Object .assign (Object .setPrototypeOf (BrowserTimings .prototype, Base_X3DBaseN
108550
108821
  {
108551
108822
  this .element .stop (true, true) .fadeIn ();
108552
108823
  this .fps .reset ();
108824
+ this .getBrowser () .addBrowserCallback (this, Base_X3DConstants .INITIALIZED_EVENT, () => this .reset ());
108553
108825
  this .getBrowser () .prepareEvents () .addInterest ("update", this);
108554
- this .update ();
108555
- this .build ();
108826
+ this .reset ();
108556
108827
  }
108557
108828
  else
108558
108829
  {
108559
108830
  this .element .stop (true, true) .fadeOut ();
108831
+ this .getBrowser () .removeBrowserCallback (this, Base_X3DConstants .INITIALIZED_EVENT);
108560
108832
  this .getBrowser () .prepareEvents () .removeInterest ("update", this);
108561
108833
  }
108562
108834
  },
@@ -108581,9 +108853,19 @@ Object .assign (Object .setPrototypeOf (BrowserTimings .prototype, Base_X3DBaseN
108581
108853
  set_button__ ()
108582
108854
  {
108583
108855
  if (this .localStorage .type === "MORE")
108584
- this .button .text (locale_gettext("Less Properties"));
108856
+ this .button .text (gettext("Less Properties"));
108585
108857
  else
108586
- this .button .text (locale_gettext("More Properties"));
108858
+ this .button .text (gettext("More Properties"));
108859
+ },
108860
+ reset ()
108861
+ {
108862
+ this .getBrowser () .addBrowserEvent ();
108863
+
108864
+ requestAnimationFrame (() =>
108865
+ {
108866
+ this .fps .reset ();
108867
+ this .build ();
108868
+ });
108587
108869
  },
108588
108870
  update ()
108589
108871
  {
@@ -108601,8 +108883,16 @@ Object .assign (Object .setPrototypeOf (BrowserTimings .prototype, Base_X3DBaseN
108601
108883
  {
108602
108884
  const browser = this .getBrowser ();
108603
108885
 
108604
- this .frameRate .text (`${f2 (1000 / this .fps .averageTime)} ${locale_gettext("fps")}`);
108605
- this .speed .text (`${f2 (this .getSpeed (browser .currentSpeed))} ${this .getSpeedUnit (browser .currentSpeed)}`);
108886
+ if (this .fps .elapsedTime)
108887
+ {
108888
+ this .frameRate .text (`${f2 (1000 / this .fps .averageTime)} ${gettext("fps")}`);
108889
+ this .speed .text (`${f2 (this .getSpeed (browser .currentSpeed ))} ${this .getSpeedUnit (browser .currentSpeed)}`);
108890
+ }
108891
+ else
108892
+ {
108893
+ this .frameRate .text (`${f2 (0)} ${gettext("fps")}`);
108894
+ this .speed .text (`${f2 (this .getSpeed (0))} ${this .getSpeedUnit (0)}`);
108895
+ }
108606
108896
 
108607
108897
  if (this .localStorage .type !== "MORE" || !browser .getWorld ())
108608
108898
  return;
@@ -108615,19 +108905,21 @@ Object .assign (Object .setPrototypeOf (BrowserTimings .prototype, Base_X3DBaseN
108615
108905
  routingTime = Math .max (0, browser .getBrowserTime () .averageTime - (browser .getCameraTime () .averageTime + browser .getCollisionTime () .averageTime + browser .getDisplayTime () .averageTime)),
108616
108906
  prepareEvents = browser .prepareEvents () .getInterests () .size - 1,
108617
108907
  sensors = browser .sensorEvents () .getInterests () .size,
108618
- opaqueShapes = layers .reduce ((n, layer) => n + layer .getNumOpaqueShapes (), 0),
108619
- transparentShapes = layers .reduce ((n, layer) => n + layer .getNumTransparentShapes (), 0);
108620
-
108621
- this .browserTime .text (`${f2 (browser .getSystemTime () .averageTime)} ${locale_gettext("ms")}`);
108622
- this .x3dTotal .text (`${f2 (browser .getBrowserTime () .averageTime)} ${locale_gettext("ms")}`);
108623
- this .eventProcessing .text (`${f2 (routingTime)} ${locale_gettext("ms")}`);
108624
- this .pointerTime .text (`${f2 (browser .getPointingTime () .averageTime)} ${locale_gettext("ms")}`);
108625
- this .cameraTime .text (`${f2 (browser .getCameraTime () .averageTime)} ${locale_gettext("ms")}`);
108626
- this .pickingTime .text (`${f2 (browser .getPickingTime () .averageTime)} ${locale_gettext("ms")}`);
108627
- this .collisionTime .text (`${f2 (collisionTime)} ${locale_gettext("ms")}`);
108628
- this .renderTime .text (`${f2 (browser .getDisplayTime () .averageTime)} ${locale_gettext("ms")}`);
108629
- this .numShapes .text (`${opaqueShapes} + ${transparentShapes}`);
108630
- this .sensors .text (prepareEvents + sensors);
108908
+ primitives = this .getPrimitives (layers),
108909
+ opaqueShapes = this .getOpaqueShapes (layers),
108910
+ transparentShapes = this .getTransparentShapes (layers);
108911
+
108912
+ this .browserTime .text (`${f2 (browser .getSystemTime () .averageTime)} ${gettext("ms")}`);
108913
+ this .x3dTotal .text (`${f2 (browser .getBrowserTime () .averageTime)} ${gettext("ms")}`);
108914
+ this .eventProcessing .text (`${f2 (routingTime)} ${gettext("ms")}`);
108915
+ this .pointerTime .text (`${f2 (browser .getPointingTime () .averageTime)} ${gettext("ms")}`);
108916
+ this .cameraTime .text (`${f2 (browser .getCameraTime () .averageTime)} ${gettext("ms")}`);
108917
+ this .pickingTime .text (`${f2 (browser .getPickingTime () .averageTime)} ${gettext("ms")}`);
108918
+ this .collisionTime .text (`${f2 (collisionTime)} ${gettext("ms")}`);
108919
+ this .renderTime .text (`${f2 (browser .getDisplayTime () .averageTime)} ${gettext("ms")}`);
108920
+ this .numPrimitives .text (`${f0 (primitives .points)}; ${f0 (primitives .lines)}; ${f0 (primitives .triangles)}`);
108921
+ this .numShapes .text (`${f0 (opaqueShapes)} + ${f0 (transparentShapes)}`);
108922
+ this .sensors .text (f0 (prepareEvents + sensors));
108631
108923
 
108632
108924
  browser .getSystemTime () .reset ();
108633
108925
  browser .getBrowserTime () .reset ();
@@ -108649,9 +108941,119 @@ Object .assign (Object .setPrototypeOf (BrowserTimings .prototype, Base_X3DBaseN
108649
108941
  getSpeedUnit (speed)
108650
108942
  {
108651
108943
  if (speed < 15)
108652
- return locale_gettext("m/s");
108944
+ return gettext("m/s");
108653
108945
 
108654
- return locale_gettext("km/h");
108946
+ return gettext("km/h");
108947
+ },
108948
+ getPrimitives (layerNodes)
108949
+ {
108950
+ this .primitives .points = 0;
108951
+ this .primitives .lines = 0;
108952
+ this .primitives .triangles = 0;
108953
+
108954
+ for (const layerNode of layerNodes)
108955
+ {
108956
+ const
108957
+ numOpaqueShapes = layerNode .getNumOpaqueShapes (),
108958
+ numTransparentShapes = layerNode .getNumTransparentShapes (),
108959
+ opaqueShapes = layerNode .getOpaqueShapes (),
108960
+ transparentShapes = layerNode .getTransparentShapes ();
108961
+
108962
+ this .countPrimitives (opaqueShapes, numOpaqueShapes);
108963
+ this .countPrimitives (transparentShapes, numTransparentShapes);
108964
+ }
108965
+
108966
+ return this .primitives;
108967
+ },
108968
+ countPrimitives (shapes, numShapes)
108969
+ {
108970
+ for (let i = 0; i < numShapes; ++ i)
108971
+ {
108972
+ const
108973
+ shapeNode = shapes [i] .shapeNode,
108974
+ numInstances = shapeNode .getNumInstances ();
108975
+
108976
+ if (shapeNode .getType () .at (-1) === Base_X3DConstants .ParticleSystem)
108977
+ {
108978
+ switch (shapeNode .getGeometryType ())
108979
+ {
108980
+ case ParticleSystems_GeometryTypes .POINT:
108981
+ {
108982
+ this .primitives .points += numInstances;
108983
+ continue;
108984
+ }
108985
+ case ParticleSystems_GeometryTypes .LINE:
108986
+ {
108987
+ this .primitives .lines += numInstances;
108988
+ continue;
108989
+ }
108990
+ case ParticleSystems_GeometryTypes .TRIANGLE:
108991
+ case ParticleSystems_GeometryTypes .QUAD:
108992
+ case ParticleSystems_GeometryTypes .SPRITE:
108993
+ {
108994
+ this .primitives .triangles += numInstances * 2;
108995
+ continue;
108996
+ }
108997
+ case ParticleSystems_GeometryTypes .GEOMETRY:
108998
+ {
108999
+ break;
109000
+ }
109001
+ }
109002
+ }
109003
+
109004
+ const geometryNode = shapeNode .getGeometry ();
109005
+
109006
+ // ParticleSystem nodes may have no geometry.
109007
+ if (!geometryNode)
109008
+ continue;
109009
+
109010
+ if (!geometryNode .getExecutionContext () .getCountPrimitives ())
109011
+ continue;
109012
+
109013
+ const vertices = geometryNode .getVertices () .length / 4 * numInstances;
109014
+
109015
+ switch (geometryNode .getGeometryType ())
109016
+ {
109017
+ case 0:
109018
+ {
109019
+ this .primitives .points += vertices;
109020
+ break;
109021
+ }
109022
+ case 1:
109023
+ {
109024
+ this .primitives .lines += vertices / 2;
109025
+ break;
109026
+ }
109027
+ case 2:
109028
+ case 3:
109029
+ {
109030
+ this .primitives .triangles += vertices / 3;
109031
+ break;
109032
+ }
109033
+ }
109034
+ }
109035
+ },
109036
+ getOpaqueShapes (layers)
109037
+ {
109038
+ return layers .reduce ((n, layer) => n + this .countShapes (layer .getOpaqueShapes (), layer .getNumOpaqueShapes ()), 0);
109039
+ },
109040
+ getTransparentShapes (layers)
109041
+ {
109042
+ return layers .reduce ((n, layer) => n + this .countShapes (layer .getTransparentShapes (), layer .getNumTransparentShapes ()), 0);
109043
+ },
109044
+ countShapes (shapes, numShapes)
109045
+ {
109046
+ let count = 0;
109047
+
109048
+ for (let i = 0; i < numShapes; ++ i)
109049
+ {
109050
+ if (!shapes [i] .shapeNode .getExecutionContext () .getCountPrimitives ())
109051
+ continue;
109052
+
109053
+ ++ count;
109054
+ }
109055
+
109056
+ return count;
108655
109057
  },
108656
109058
  });
108657
109059
 
@@ -108664,19 +109066,23 @@ Object .defineProperties (BrowserTimings,
108664
109066
  },
108665
109067
  });
108666
109068
 
108667
- const f2 = (() =>
109069
+ function format (minimumFractionDigits, maximumFractionDigits)
108668
109070
  {
108669
109071
  const format = new Intl .NumberFormat (navigator .language || navigator .userLanguage, {
108670
109072
  notation: "standard",
108671
- minimumFractionDigits: 2,
108672
- maximumFractionDigits: 2,
109073
+ minimumFractionDigits,
109074
+ maximumFractionDigits,
108673
109075
  }) .format;
108674
109076
 
108675
109077
  return function (value)
108676
109078
  {
108677
109079
  return format (Number .isFinite (value) ? value : 0);
108678
109080
  };
108679
- })();
109081
+ }
109082
+
109083
+ const
109084
+ f0 = format (0, 0),
109085
+ f2 = format (2, 2);
108680
109086
 
108681
109087
  const BrowserTimings_default_ = BrowserTimings;
108682
109088
  ;
@@ -108808,7 +109214,7 @@ const TextureQuality_default_ = TextureQuality;
108808
109214
  x_ite_Namespace .add ("TextureQuality", "x_ite/Browser/Core/TextureQuality", TextureQuality_default_);
108809
109215
  /* harmony default export */ const Core_TextureQuality = (TextureQuality_default_);
108810
109216
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/BrowserOptions.js
108811
- /* provided dependency */ var BrowserOptions_$ = __webpack_require__(349);
109217
+ /* provided dependency */ var BrowserOptions_$ = __webpack_require__(275);
108812
109218
  /*******************************************************************************
108813
109219
  *
108814
109220
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -109402,7 +109808,7 @@ const RenderingProperties_default_ = RenderingProperties;
109402
109808
  x_ite_Namespace .add ("RenderingProperties", "x_ite/Browser/Core/RenderingProperties", RenderingProperties_default_);
109403
109809
  /* harmony default export */ const Core_RenderingProperties = (RenderingProperties_default_);
109404
109810
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/Notification.js
109405
- /* provided dependency */ var Notification_$ = __webpack_require__(349);
109811
+ /* provided dependency */ var Notification_$ = __webpack_require__(275);
109406
109812
  /*******************************************************************************
109407
109813
  *
109408
109814
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -109525,8 +109931,8 @@ const Notification_default_ = Notification;
109525
109931
  x_ite_Namespace .add ("Notification", "x_ite/Browser/Core/Notification", Notification_default_);
109526
109932
  /* harmony default export */ const Core_Notification = (Notification_default_);
109527
109933
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/ContextMenu.js
109528
- /* provided dependency */ var jquery_fullscreen = __webpack_require__(405);
109529
- /* provided dependency */ var ContextMenu_$ = __webpack_require__(349);
109934
+ /* provided dependency */ var jquery_fullscreen = __webpack_require__(543);
109935
+ /* provided dependency */ var ContextMenu_$ = __webpack_require__(275);
109530
109936
  /*******************************************************************************
109531
109937
  *
109532
109938
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -109646,16 +110052,16 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109646
110052
  },
109647
110053
  "separator0": "--------",
109648
110054
  "viewpoints": {
109649
- name: locale_gettext("Viewpoints"),
110055
+ name: gettext("Viewpoints"),
109650
110056
  className: "context-menu-icon x_ite-private-icon-viewpoint",
109651
110057
  items: this .getViewpoints (),
109652
110058
  },
109653
110059
  "available-viewers": {
109654
- name: locale_gettext("Available Viewers"),
110060
+ name: gettext("Available Viewers"),
109655
110061
  items: this .getAvailableViewers (),
109656
110062
  },
109657
110063
  "straighten-horizon": {
109658
- name: locale_gettext("Straighten Horizon"),
110064
+ name: gettext("Straighten Horizon"),
109659
110065
  type: "checkbox",
109660
110066
  selected: browser .getBrowserOption ("StraightenHorizon"),
109661
110067
  events: {
@@ -109666,14 +110072,14 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109666
110072
  browser .setBrowserOption ("StraightenHorizon", straightenHorizon);
109667
110073
 
109668
110074
  if (straightenHorizon)
109669
- browser .getNotification () ._string = locale_gettext("Straighten Horizon") + ": " + locale_gettext("on");
110075
+ browser .getNotification () ._string = gettext("Straighten Horizon") + ": " + gettext("on");
109670
110076
  else
109671
- browser .getNotification () ._string = locale_gettext("Straighten Horizon") + ": " + locale_gettext("off");
110077
+ browser .getNotification () ._string = gettext("Straighten Horizon") + ": " + gettext("off");
109672
110078
  },
109673
110079
  },
109674
110080
  },
109675
110081
  "display-rubberband": {
109676
- name: locale_gettext("Display Rubberband"),
110082
+ name: gettext("Display Rubberband"),
109677
110083
  type: "checkbox",
109678
110084
  selected: browser .getBrowserOption ("Rubberband"),
109679
110085
  events: {
@@ -109684,19 +110090,19 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109684
110090
  browser .setBrowserOption ("Rubberband", rubberband);
109685
110091
 
109686
110092
  if (rubberband)
109687
- browser .getNotification () ._string = locale_gettext("Rubberband") + ": " + locale_gettext("on");
110093
+ browser .getNotification () ._string = gettext("Rubberband") + ": " + gettext("on");
109688
110094
  else
109689
- browser .getNotification () ._string = locale_gettext("Rubberband") + ": " + locale_gettext("off");
110095
+ browser .getNotification () ._string = gettext("Rubberband") + ": " + gettext("off");
109690
110096
  },
109691
110097
  },
109692
110098
  },
109693
110099
  "separator1": "--------",
109694
110100
  "primitive-quality": {
109695
- name: locale_gettext("Primitive Quality"),
110101
+ name: gettext("Primitive Quality"),
109696
110102
  className: "context-menu-icon x_ite-private-icon-primitive-quality",
109697
110103
  items: {
109698
110104
  "high": {
109699
- name: locale_gettext("High"),
110105
+ name: gettext("High"),
109700
110106
  type: "radio",
109701
110107
  radio: "primitive-quality",
109702
110108
  selected: browser .getBrowserOption ("PrimitiveQuality") === "HIGH",
@@ -109704,12 +110110,12 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109704
110110
  click: () =>
109705
110111
  {
109706
110112
  browser .setBrowserOption ("PrimitiveQuality", "HIGH");
109707
- browser .getNotification () ._string = locale_gettext("Primitive Quality") + ": " + locale_gettext("high");
110113
+ browser .getNotification () ._string = gettext("Primitive Quality") + ": " + gettext("high");
109708
110114
  },
109709
110115
  },
109710
110116
  },
109711
110117
  "medium": {
109712
- name: locale_gettext("Medium"),
110118
+ name: gettext("Medium"),
109713
110119
  type: "radio",
109714
110120
  radio: "primitive-quality",
109715
110121
  selected: browser .getBrowserOption ("PrimitiveQuality") === "MEDIUM",
@@ -109717,12 +110123,12 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109717
110123
  click: () =>
109718
110124
  {
109719
110125
  browser .setBrowserOption ("PrimitiveQuality", "MEDIUM");
109720
- browser .getNotification () ._string = locale_gettext("Primitive Quality") + ": " + locale_gettext("medium");
110126
+ browser .getNotification () ._string = gettext("Primitive Quality") + ": " + gettext("medium");
109721
110127
  },
109722
110128
  },
109723
110129
  },
109724
110130
  "low": {
109725
- name: locale_gettext("Low"),
110131
+ name: gettext("Low"),
109726
110132
  type: "radio",
109727
110133
  radio: "primitive-quality",
109728
110134
  selected: browser .getBrowserOption ("PrimitiveQuality") === "LOW",
@@ -109730,18 +110136,18 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109730
110136
  click: () =>
109731
110137
  {
109732
110138
  browser .setBrowserOption ("PrimitiveQuality", "LOW");
109733
- browser .getNotification () ._string = locale_gettext("Primitive Quality") + ": " + locale_gettext("low");
110139
+ browser .getNotification () ._string = gettext("Primitive Quality") + ": " + gettext("low");
109734
110140
  },
109735
110141
  },
109736
110142
  },
109737
110143
  },
109738
110144
  },
109739
110145
  "texture-quality": {
109740
- name: locale_gettext("Texture Quality"),
110146
+ name: gettext("Texture Quality"),
109741
110147
  className: "context-menu-icon x_ite-private-icon-texture-quality",
109742
110148
  items: {
109743
110149
  "high": {
109744
- name: locale_gettext("High"),
110150
+ name: gettext("High"),
109745
110151
  type: "radio",
109746
110152
  radio: "texture-quality",
109747
110153
  selected: browser .getBrowserOption ("TextureQuality") === "HIGH",
@@ -109749,12 +110155,12 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109749
110155
  click: () =>
109750
110156
  {
109751
110157
  browser .setBrowserOption ("TextureQuality", "HIGH");
109752
- browser .getNotification () ._string = locale_gettext("Texture Quality") + ": " + locale_gettext("high");
110158
+ browser .getNotification () ._string = gettext("Texture Quality") + ": " + gettext("high");
109753
110159
  },
109754
110160
  },
109755
110161
  },
109756
110162
  "medium": {
109757
- name: locale_gettext("Medium"),
110163
+ name: gettext("Medium"),
109758
110164
  type: "radio",
109759
110165
  radio: "texture-quality",
109760
110166
  selected: browser .getBrowserOption ("TextureQuality") === "MEDIUM",
@@ -109762,12 +110168,12 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109762
110168
  click: () =>
109763
110169
  {
109764
110170
  browser .setBrowserOption ("TextureQuality", "MEDIUM");
109765
- browser .getNotification () ._string = locale_gettext("Texture Quality") + ": " + locale_gettext("medium");
110171
+ browser .getNotification () ._string = gettext("Texture Quality") + ": " + gettext("medium");
109766
110172
  },
109767
110173
  },
109768
110174
  },
109769
110175
  "low": {
109770
- name: locale_gettext("Low"),
110176
+ name: gettext("Low"),
109771
110177
  type: "radio",
109772
110178
  radio: "texture-quality",
109773
110179
  selected: browser .getBrowserOption ("TextureQuality") === "LOW",
@@ -109775,18 +110181,18 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109775
110181
  click: () =>
109776
110182
  {
109777
110183
  browser .setBrowserOption ("TextureQuality", "LOW");
109778
- browser .getNotification () ._string = locale_gettext("Texture Quality") + ": " + locale_gettext("low");
110184
+ browser .getNotification () ._string = gettext("Texture Quality") + ": " + gettext("low");
109779
110185
  },
109780
110186
  },
109781
110187
  },
109782
110188
  },
109783
110189
  },
109784
110190
  "shading": {
109785
- name: locale_gettext("Shading"),
110191
+ name: gettext("Shading"),
109786
110192
  className: "context-menu-icon x_ite-private-icon-shading",
109787
110193
  items: {
109788
110194
  "point": {
109789
- name: locale_gettext("Points"),
110195
+ name: gettext("Points"),
109790
110196
  type: "radio",
109791
110197
  radio: "shading",
109792
110198
  selected: browser .getBrowserOption ("Shading") === "POINT",
@@ -109794,12 +110200,12 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109794
110200
  click: () =>
109795
110201
  {
109796
110202
  browser .setBrowserOption ("Shading", "POINT");
109797
- browser .getNotification () ._string = locale_gettext("Shading") + ": " + locale_gettext("Points");
110203
+ browser .getNotification () ._string = gettext("Shading") + ": " + gettext("Points");
109798
110204
  },
109799
110205
  },
109800
110206
  },
109801
110207
  "wireframe": {
109802
- name: locale_gettext("Wireframe"),
110208
+ name: gettext("Wireframe"),
109803
110209
  type: "radio",
109804
110210
  radio: "shading",
109805
110211
  selected: browser .getBrowserOption ("Shading") === "WIREFRAME",
@@ -109807,12 +110213,12 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109807
110213
  click: () =>
109808
110214
  {
109809
110215
  browser .setBrowserOption ("Shading", "WIREFRAME");
109810
- browser .getNotification () ._string = locale_gettext("Shading") + ": " + locale_gettext("Wireframe");
110216
+ browser .getNotification () ._string = gettext("Shading") + ": " + gettext("Wireframe");
109811
110217
  },
109812
110218
  },
109813
110219
  },
109814
110220
  "flat": {
109815
- name: locale_gettext("Flat"),
110221
+ name: gettext("Flat"),
109816
110222
  type: "radio",
109817
110223
  radio: "shading",
109818
110224
  selected: browser .getBrowserOption ("Shading") === "FLAT",
@@ -109820,12 +110226,12 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109820
110226
  click: () =>
109821
110227
  {
109822
110228
  browser .setBrowserOption ("Shading", "FLAT");
109823
- browser .getNotification () ._string = locale_gettext("Shading") + ": " + locale_gettext("Flat");
110229
+ browser .getNotification () ._string = gettext("Shading") + ": " + gettext("Flat");
109824
110230
  },
109825
110231
  },
109826
110232
  },
109827
110233
  "gouraud": {
109828
- name: locale_gettext("Gouraud"),
110234
+ name: gettext("Gouraud"),
109829
110235
  type: "radio",
109830
110236
  radio: "shading",
109831
110237
  selected: browser .getBrowserOption ("Shading") === "GOURAUD",
@@ -109833,12 +110239,12 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109833
110239
  click: () =>
109834
110240
  {
109835
110241
  browser .setBrowserOption ("Shading", "GOURAUD");
109836
- browser .getNotification () ._string = locale_gettext("Shading") + ": " + locale_gettext("Gouraud");
110242
+ browser .getNotification () ._string = gettext("Shading") + ": " + gettext("Gouraud");
109837
110243
  },
109838
110244
  },
109839
110245
  },
109840
110246
  "phong": {
109841
- name: locale_gettext("Phong"),
110247
+ name: gettext("Phong"),
109842
110248
  type: "radio",
109843
110249
  radio: "shading",
109844
110250
  selected: browser .getBrowserOption ("Shading") === "PHONG",
@@ -109846,7 +110252,7 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109846
110252
  click: () =>
109847
110253
  {
109848
110254
  browser .setBrowserOption ("Shading", "PHONG");
109849
- browser .getNotification () ._string = locale_gettext("Shading") + ": " + locale_gettext("Phong");
110255
+ browser .getNotification () ._string = gettext("Shading") + ": " + gettext("Phong");
109850
110256
  },
109851
110257
  },
109852
110258
  },
@@ -109854,7 +110260,7 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109854
110260
  },
109855
110261
  "separator2": "--------",
109856
110262
  "browser-timings": {
109857
- name: locale_gettext("Browser Timings"),
110263
+ name: gettext("Browser Timings"),
109858
110264
  type: "checkbox",
109859
110265
  selected: browser .getBrowserOption ("Timings"),
109860
110266
  events: {
@@ -109866,7 +110272,7 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109866
110272
  },
109867
110273
  },
109868
110274
  "fullscreen": {
109869
- name: fullscreen ? locale_gettext("Leave Fullscreen") : locale_gettext("Fullscreen"),
110275
+ name: fullscreen ? gettext("Leave Fullscreen") : gettext("Fullscreen"),
109870
110276
  className: "context-menu-icon " + (fullscreen
109871
110277
  ? "x_ite-private-icon-leave-fullscreen"
109872
110278
  : "x_ite-private-icon-enter-fullscreen"),
@@ -109884,7 +110290,7 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109884
110290
  Object .assign (menu .items, {
109885
110291
  "separator4": "--------",
109886
110292
  "world-info": {
109887
- name: locale_gettext("Show World Info"),
110293
+ name: gettext("Show World Info"),
109888
110294
  className: "context-menu-icon x_ite-private-icon-world-info",
109889
110295
  callback ()
109890
110296
  {
@@ -109914,7 +110320,7 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
109914
110320
  },
109915
110321
  },
109916
110322
  "about": {
109917
- name: locale_gettext("About X_ITE"),
110323
+ name: gettext("About X_ITE"),
109918
110324
  className: "context-menu-icon x_ite-private-icon-help-about",
109919
110325
  callback ()
109920
110326
  {
@@ -110004,12 +110410,12 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
110004
110410
  for (const viewer of availableViewers)
110005
110411
  {
110006
110412
  menu [viewer] = {
110007
- name: locale_gettext(this .getViewerName (viewer)),
110413
+ name: gettext(this .getViewerName (viewer)),
110008
110414
  className: "context-menu-icon x_ite-private-icon-" + viewer .toLowerCase () + "-viewer",
110009
110415
  callback: () =>
110010
110416
  {
110011
110417
  browser ._viewer = viewer;
110012
- browser .getNotification () ._string = locale_gettext(this .getViewerName (viewer));
110418
+ browser .getNotification () ._string = gettext(this .getViewerName (viewer));
110013
110419
  browser .getSurface () .focus ();
110014
110420
  },
110015
110421
  };
@@ -110025,17 +110431,17 @@ Object .assign (Object .setPrototypeOf (ContextMenu .prototype, Base_X3DBaseNode
110025
110431
  switch (viewer)
110026
110432
  {
110027
110433
  case "EXAMINE":
110028
- return locale_gettext("Examine Viewer");
110434
+ return gettext("Examine Viewer");
110029
110435
  case "WALK":
110030
- return locale_gettext("Walk Viewer");
110436
+ return gettext("Walk Viewer");
110031
110437
  case "FLY":
110032
- return locale_gettext("Fly Viewer");
110438
+ return gettext("Fly Viewer");
110033
110439
  case "PLANE":
110034
- return locale_gettext("Plane Viewer");
110440
+ return gettext("Plane Viewer");
110035
110441
  case "LOOKAT":
110036
- return locale_gettext("Look At Viewer");
110442
+ return gettext("Look At Viewer");
110037
110443
  case "NONE":
110038
- return locale_gettext("None Viewer");
110444
+ return gettext("None Viewer");
110039
110445
  }
110040
110446
  },
110041
110447
  init (options)
@@ -111351,7 +111757,7 @@ Object .assign (Object .setPrototypeOf (X3DScene .prototype, Execution_X3DExecut
111351
111757
 
111352
111758
  this .updateExportedNode (exportedName, node);
111353
111759
 
111354
- this ._exportedNodes_changed = this .getBrowser () .getCurrentTime ();
111760
+ this ._sceneGraph_changed = this .getBrowser () .getCurrentTime ();
111355
111761
  },
111356
111762
  updateExportedNode (exportedName, node)
111357
111763
  {
@@ -111371,7 +111777,7 @@ Object .assign (Object .setPrototypeOf (X3DScene .prototype, Execution_X3DExecut
111371
111777
 
111372
111778
  this [_exportedNodes] .update (exportedName, exportedName, exportedNode);
111373
111779
 
111374
- this ._exportedNodes_changed = this .getBrowser () .getCurrentTime ();
111780
+ this ._sceneGraph_changed = this .getBrowser () .getCurrentTime ();
111375
111781
  },
111376
111782
  removeExportedNode (exportedName)
111377
111783
  {
@@ -111379,7 +111785,7 @@ Object .assign (Object .setPrototypeOf (X3DScene .prototype, Execution_X3DExecut
111379
111785
 
111380
111786
  this [_exportedNodes] .remove (exportedName);
111381
111787
 
111382
- this ._exportedNodes_changed = this .getBrowser () .getCurrentTime ();
111788
+ this ._sceneGraph_changed = this .getBrowser () .getCurrentTime ();
111383
111789
  },
111384
111790
  getExportedNode (exportedName)
111385
111791
  {
@@ -112287,7 +112693,7 @@ const DataStorage_default_ = DataStorage;
112287
112693
  x_ite_Namespace .add ("DataStorage", "standard/Utility/DataStorage", DataStorage_default_);
112288
112694
  /* harmony default export */ const Utility_DataStorage = (DataStorage_default_);
112289
112695
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/X3DCoreContext.js
112290
- /* provided dependency */ var X3DCoreContext_$ = __webpack_require__(349);
112696
+ /* provided dependency */ var X3DCoreContext_$ = __webpack_require__(275);
112291
112697
  /*******************************************************************************
112292
112698
  *
112293
112699
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -112998,7 +113404,7 @@ Object .assign (X3DCoreContext .prototype,
112998
113404
  text += "\n";
112999
113405
 
113000
113406
  this .copyToClipboard (text);
113001
- this .getNotification () ._string = locale_gettext ("Viewpoint copied to clipboard.");
113407
+ this .getNotification () ._string = gettext ("Viewpoint copied to clipboard.");
113002
113408
 
113003
113409
  console .log ("Viewpoint copied to clipboard.");
113004
113410
  console .debug (text);
@@ -114810,8 +115216,8 @@ const X3DViewer_default_ = X3DViewer;
114810
115216
  x_ite_Namespace .add ("X3DViewer", "x_ite/Browser/Navigation/X3DViewer", X3DViewer_default_);
114811
115217
  /* harmony default export */ const Navigation_X3DViewer = (X3DViewer_default_);
114812
115218
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Navigation/ExamineViewer.js
114813
- /* provided dependency */ var jquery_mousewheel = __webpack_require__(5);
114814
- /* provided dependency */ var ExamineViewer_$ = __webpack_require__(349);
115219
+ /* provided dependency */ var jquery_mousewheel = __webpack_require__(419);
115220
+ /* provided dependency */ var ExamineViewer_$ = __webpack_require__(275);
114815
115221
  /*******************************************************************************
114816
115222
  *
114817
115223
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -115683,8 +116089,8 @@ const ExamineViewer_default_ = ExamineViewer;
115683
116089
  x_ite_Namespace .add ("ExamineViewer", "x_ite/Browser/Navigation/ExamineViewer", ExamineViewer_default_);
115684
116090
  /* harmony default export */ const Navigation_ExamineViewer = (ExamineViewer_default_);
115685
116091
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Navigation/X3DFlyViewer.js
115686
- /* provided dependency */ var X3DFlyViewer_jquery_mousewheel = __webpack_require__(5);
115687
- /* provided dependency */ var X3DFlyViewer_$ = __webpack_require__(349);
116092
+ /* provided dependency */ var X3DFlyViewer_jquery_mousewheel = __webpack_require__(419);
116093
+ /* provided dependency */ var X3DFlyViewer_$ = __webpack_require__(275);
115688
116094
  /*******************************************************************************
115689
116095
  *
115690
116096
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -116693,8 +117099,8 @@ const FlyViewer_default_ = FlyViewer;
116693
117099
  x_ite_Namespace .add ("FlyViewer", "x_ite/Browser/Navigation/FlyViewer", FlyViewer_default_);
116694
117100
  /* harmony default export */ const Navigation_FlyViewer = (FlyViewer_default_);
116695
117101
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Navigation/PlaneViewer.js
116696
- /* provided dependency */ var PlaneViewer_jquery_mousewheel = __webpack_require__(5);
116697
- /* provided dependency */ var PlaneViewer_$ = __webpack_require__(349);
117102
+ /* provided dependency */ var PlaneViewer_jquery_mousewheel = __webpack_require__(419);
117103
+ /* provided dependency */ var PlaneViewer_$ = __webpack_require__(275);
116698
117104
  /*******************************************************************************
116699
117105
  *
116700
117106
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -117025,8 +117431,8 @@ const NoneViewer_default_ = NoneViewer;
117025
117431
  x_ite_Namespace .add ("NoneViewer", "x_ite/Browser/Navigation/NoneViewer", NoneViewer_default_);
117026
117432
  /* harmony default export */ const Navigation_NoneViewer = (NoneViewer_default_);
117027
117433
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Navigation/LookAtViewer.js
117028
- /* provided dependency */ var LookAtViewer_jquery_mousewheel = __webpack_require__(5);
117029
- /* provided dependency */ var LookAtViewer_$ = __webpack_require__(349);
117434
+ /* provided dependency */ var LookAtViewer_jquery_mousewheel = __webpack_require__(419);
117435
+ /* provided dependency */ var LookAtViewer_$ = __webpack_require__(275);
117030
117436
  /*******************************************************************************
117031
117437
  *
117032
117438
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -117984,12 +118390,12 @@ Object .assign (X3DNetworkingContext .prototype,
117984
118390
  if (this ._loadCount .getValue () || this [_loading])
117985
118391
  {
117986
118392
  var string = ((loadingDisplay || 1) === 1
117987
- ? locale_gettext ("Loading %1 file")
117988
- : locale_gettext ("Loading %1 files")) .replace ("%1", loadingDisplay || 1);
118393
+ ? gettext ("Loading %1 file")
118394
+ : gettext ("Loading %1 files")) .replace ("%1", loadingDisplay || 1);
117989
118395
  }
117990
118396
  else
117991
118397
  {
117992
- var string = locale_gettext("Loading done");
118398
+ var string = gettext("Loading done");
117993
118399
  this .setCursor ("DEFAULT");
117994
118400
  }
117995
118401
 
@@ -118165,8 +118571,8 @@ const X3DPickingContext_default_ = X3DPickingContext;
118165
118571
  x_ite_Namespace .add ("X3DPickingContext", "x_ite/Browser/Picking/X3DPickingContext", X3DPickingContext_default_);
118166
118572
  /* harmony default export */ const Picking_X3DPickingContext = (X3DPickingContext_default_);
118167
118573
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/PointingDeviceSensor/PointingDevice.js
118168
- /* provided dependency */ var PointingDevice_jquery_mousewheel = __webpack_require__(5);
118169
- /* provided dependency */ var PointingDevice_$ = __webpack_require__(349);
118574
+ /* provided dependency */ var PointingDevice_jquery_mousewheel = __webpack_require__(419);
118575
+ /* provided dependency */ var PointingDevice_$ = __webpack_require__(275);
118170
118576
  /*******************************************************************************
118171
118577
  *
118172
118578
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -118986,34 +119392,36 @@ Object .assign (X3DPointingDeviceSensorContext .prototype,
118986
119392
  },
118987
119393
  getPointingShader (numClipPlanes, shapeNode, humanoidNode)
118988
119394
  {
118989
- const geometryContext = shapeNode .getGeometryContext ();
119395
+ const { geometryType, hasNormals } = shapeNode .getGeometryContext ();
118990
119396
 
118991
119397
  let key = "";
118992
119398
 
118993
119399
  key += numClipPlanes;
118994
119400
  key += ".";
118995
119401
  key += shapeNode .getShapeKey ();
118996
- key += geometryContext .geometryType;
119402
+ key += geometryType;
119403
+ key += hasNormals;
118997
119404
  key += ".";
118998
119405
  key += humanoidNode ?.getHumanoidKey () ?? "";
118999
119406
  key += ".";
119000
119407
 
119001
- if (geometryContext .geometryType >= 2)
119408
+ if (geometryType >= 2)
119002
119409
  {
119003
119410
  key += "0.0.0";
119004
119411
  }
119005
119412
  else
119006
119413
  {
119007
- const appearanceNode = shapeNode .getAppearance ();
119414
+ const appearanceNode = shapeNode .getAppearance ();
119008
119415
 
119009
- key += appearanceNode .getStyleProperties (geometryContext .geometryType) ? 1 : 0;
119416
+ key += appearanceNode .getStyleProperties (geometryType) ? 1 : 0;
119010
119417
  key += ".";
119011
119418
  key += appearanceNode .getTextureBits () .toString (16); // Textures for point and line.
119012
119419
  key += ".";
119013
119420
  key += appearanceNode .getMaterial () .getTextureBits () .toString (16); // Textures for point and line.
119014
119421
  }
119015
119422
 
119016
- return this [_pointingShaders] .get (key) || this .createPointingShader (key, numClipPlanes, shapeNode, humanoidNode);
119423
+ return this [_pointingShaders] .get (key)
119424
+ ?? this .createPointingShader (key, numClipPlanes, shapeNode, humanoidNode);
119017
119425
  },
119018
119426
  createPointingShader (key, numClipPlanes, shapeNode, humanoidNode)
119019
119427
  {
@@ -119022,14 +119430,25 @@ Object .assign (X3DPointingDeviceSensorContext .prototype,
119022
119430
  geometryContext = shapeNode .getGeometryContext (),
119023
119431
  options = [ ];
119024
119432
 
119433
+ if (geometryContext .hasNormals)
119434
+ options .push ("X3D_NORMALS");
119435
+
119025
119436
  if (numClipPlanes)
119026
119437
  {
119027
119438
  options .push ("X3D_CLIP_PLANES");
119028
119439
  options .push ("X3D_NUM_CLIP_PLANES " + numClipPlanes);
119029
119440
  }
119030
119441
 
119031
- if (shapeNode .getShapeKey () > 0)
119032
- options .push ("X3D_PARTICLE_SYSTEM");
119442
+ switch (shapeNode .getShapeKey ())
119443
+ {
119444
+ case 1:
119445
+ case 2:
119446
+ options .push ("X3D_INSTANCING");
119447
+ break;
119448
+ case 3:
119449
+ options .push ("X3D_INSTANCING", "X3D_INSTANCE_NORMAL");
119450
+ break;
119451
+ }
119033
119452
 
119034
119453
  options .push (`X3D_GEOMETRY_${geometryContext .geometryType}D`);
119035
119454
 
@@ -119457,7 +119876,7 @@ const MultiSampleFrameBuffer_default_ = MultiSampleFrameBuffer;
119457
119876
  x_ite_Namespace .add ("MultiSampleFrameBuffer", "x_ite/Rendering/MultiSampleFrameBuffer", MultiSampleFrameBuffer_default_);
119458
119877
  /* harmony default export */ const Rendering_MultiSampleFrameBuffer = (MultiSampleFrameBuffer_default_);
119459
119878
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Rendering/X3DRenderingContext.js
119460
- /* provided dependency */ var X3DRenderingContext_$ = __webpack_require__(349);
119879
+ /* provided dependency */ var X3DRenderingContext_$ = __webpack_require__(275);
119461
119880
  /*******************************************************************************
119462
119881
  *
119463
119882
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -119679,7 +120098,8 @@ Object .assign (X3DRenderingContext .prototype,
119679
120098
  key += appearanceNode .getMaterial () .getTextureBits () .toString (16); // Textures for point and line.
119680
120099
  }
119681
120100
 
119682
- return this [_depthShaders] .get (key) || this .createDepthShader (key, numClipPlanes, shapeNode, humanoidNode);
120101
+ return this [_depthShaders] .get (key)
120102
+ ?? this .createDepthShader (key, numClipPlanes, shapeNode, humanoidNode);
119683
120103
  },
119684
120104
  createDepthShader (key, numClipPlanes, shapeNode, humanoidNode)
119685
120105
  {
@@ -119695,7 +120115,7 @@ Object .assign (X3DRenderingContext .prototype,
119695
120115
  }
119696
120116
 
119697
120117
  if (shapeNode .getShapeKey () > 0)
119698
- options .push ("X3D_PARTICLE_SYSTEM");
120118
+ options .push ("X3D_INSTANCING");
119699
120119
 
119700
120120
  options .push (`X3D_GEOMETRY_${geometryContext .geometryType}D`);
119701
120121
 
@@ -120369,7 +120789,7 @@ const X3DSoundContext_default_ = X3DSoundContext;
120369
120789
  x_ite_Namespace .add ("X3DSoundContext", "x_ite/Browser/Sound/X3DSoundContext", X3DSoundContext_default_);
120370
120790
  /* harmony default export */ const Sound_X3DSoundContext = (X3DSoundContext_default_);
120371
120791
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Texturing/KTXDecoder.js
120372
- /* provided dependency */ var KTXDecoder_$ = __webpack_require__(349);
120792
+ /* provided dependency */ var KTXDecoder_$ = __webpack_require__(275);
120373
120793
  const KTXDecoder_default_ = class KTXDecoder
120374
120794
  {
120375
120795
  constructor (gl, externalKtxlib, scriptDir)
@@ -121923,7 +122343,7 @@ const Components_default_ = Components;
121923
122343
  x_ite_Namespace .add ("Components", "x_ite/Components", Components_default_);
121924
122344
  /* harmony default export */ const x_ite_Components = ((/* unused pure expression or super */ null && (Components_default_)));
121925
122345
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/DOMIntegration.js
121926
- /* provided dependency */ var DOMIntegration_$ = __webpack_require__(349);
122346
+ /* provided dependency */ var DOMIntegration_$ = __webpack_require__(275);
121927
122347
  /*******************************************************************************
121928
122348
  * MIT License
121929
122349
  *
@@ -123056,7 +123476,7 @@ const SupportedProfiles_default_ = SupportedProfiles;
123056
123476
  x_ite_Namespace .add ("SupportedProfiles", "x_ite/Configuration/SupportedProfiles", SupportedProfiles_default_);
123057
123477
  /* harmony default export */ const Configuration_SupportedProfiles = (SupportedProfiles_default_);
123058
123478
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/X3DBrowser.js
123059
- /* provided dependency */ var X3DBrowser_$ = __webpack_require__(349);
123479
+ /* provided dependency */ var X3DBrowser_$ = __webpack_require__(275);
123060
123480
  /*******************************************************************************
123061
123481
  *
123062
123482
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -123683,7 +124103,7 @@ Object .assign (Object .setPrototypeOf (X3DBrowser .prototype, Browser_X3DBrowse
123683
124103
  {
123684
124104
  this .getSplashScreen ()
123685
124105
  .find (".x_ite-private-spinner-text")
123686
- .text (locale_gettext ("Failed loading world."));
124106
+ .text (gettext ("Failed loading world."));
123687
124107
  });
123688
124108
 
123689
124109
  reject (new Error ("Couldn't load X3D file."));
@@ -124148,7 +124568,7 @@ const X3DBrowser_default_ = X3DBrowser;
124148
124568
  x_ite_Namespace .add ("X3DBrowser", "x_ite/Browser/X3DBrowser", X3DBrowser_default_);
124149
124569
  /* harmony default export */ const Browser_X3DBrowser = (X3DBrowser_default_);
124150
124570
  ;// CONCATENATED MODULE: ./src/x_ite/X3DCanvasElement.js
124151
- /* provided dependency */ var X3DCanvasElement_$ = __webpack_require__(349);
124571
+ /* provided dependency */ var X3DCanvasElement_$ = __webpack_require__(275);
124152
124572
  /*******************************************************************************
124153
124573
  *
124154
124574
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -124285,8 +124705,8 @@ const X3DCanvasElement_default_ = X3DCanvasElement;
124285
124705
  x_ite_Namespace .add ("X3DCanvasElement", "x_ite/X3DCanvasElement", X3DCanvasElement_default_);
124286
124706
  /* harmony default export */ const x_ite_X3DCanvasElement = (X3DCanvasElement_default_);
124287
124707
  ;// CONCATENATED MODULE: ./src/lib/jquery.js
124288
- /* provided dependency */ var jquery_$ = __webpack_require__(349);
124289
- /* provided dependency */ var pako = __webpack_require__(929);
124708
+ /* provided dependency */ var jquery_$ = __webpack_require__(275);
124709
+ /* provided dependency */ var pako = __webpack_require__(35);
124290
124710
  Object .assign (jquery_$,
124291
124711
  {
124292
124712
  decodeText (input)
@@ -124363,14 +124783,14 @@ const jquery_default_ = jquery_$;
124363
124783
  x_ite_Namespace .add ("jquery", "lib/jquery", jquery_default_);
124364
124784
  /* harmony default export */ const jquery = ((/* unused pure expression or super */ null && (jquery_default_)));
124365
124785
  ;// CONCATENATED MODULE: ./src/lib/libtess.js
124366
- /* provided dependency */ var libtess_libtess = __webpack_require__(94);
124786
+ /* provided dependency */ var libtess_libtess = __webpack_require__(224);
124367
124787
  const libtess_default_ = libtess_libtess;
124368
124788
  ;
124369
124789
 
124370
124790
  x_ite_Namespace .add ("libtess", "lib/libtess", libtess_default_);
124371
124791
  /* harmony default export */ const lib_libtess = ((/* unused pure expression or super */ null && (libtess_default_)));
124372
124792
  ;// CONCATENATED MODULE: ./src/x_ite/X3D.js
124373
- /* provided dependency */ var X3D_$ = __webpack_require__(349);
124793
+ /* provided dependency */ var X3D_$ = __webpack_require__(275);
124374
124794
  /*******************************************************************************
124375
124795
  *
124376
124796
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -124678,7 +125098,7 @@ Object .assign (X3D,
124678
125098
 
124679
125099
  // Assign X3D to global namespace.
124680
125100
 
124681
- window [Symbol .for ("X_ITE.X3D-9.4.5")] = x_ite_X3D;
125101
+ window [Symbol .for ("X_ITE.X3D-9.5.0")] = x_ite_X3D;
124682
125102
 
124683
125103
  customElements .define ("x3d-canvas", x_ite_X3DCanvasElement);
124684
125104