x_ite 9.0.0 → 9.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. package/dist/assets/components/Annotation.js +13 -13
  2. package/dist/assets/components/Annotation.min.js +1 -1
  3. package/dist/assets/components/CADGeometry.js +14 -14
  4. package/dist/assets/components/CADGeometry.min.js +1 -1
  5. package/dist/assets/components/CubeMapTexturing.js +41 -46
  6. package/dist/assets/components/CubeMapTexturing.min.js +1 -1
  7. package/dist/assets/components/DIS.js +13 -13
  8. package/dist/assets/components/DIS.min.js +1 -1
  9. package/dist/assets/components/EventUtilities.js +9 -9
  10. package/dist/assets/components/EventUtilities.min.js +1 -1
  11. package/dist/assets/components/Geometry2D.js +19 -19
  12. package/dist/assets/components/Geometry2D.min.js +1 -1
  13. package/dist/assets/components/Geospatial.js +33 -33
  14. package/dist/assets/components/Geospatial.min.js +1 -1
  15. package/dist/assets/components/HAnim.js +23 -23
  16. package/dist/assets/components/HAnim.min.js +1 -1
  17. package/dist/assets/components/KeyDeviceSensor.js +8 -8
  18. package/dist/assets/components/KeyDeviceSensor.min.js +1 -1
  19. package/dist/assets/components/Layout.js +27 -27
  20. package/dist/assets/components/Layout.min.js +1 -1
  21. package/dist/assets/components/NURBS.js +24 -24
  22. package/dist/assets/components/NURBS.min.js +1 -1
  23. package/dist/assets/components/ParticleSystems.js +30 -25
  24. package/dist/assets/components/ParticleSystems.min.js +1 -1
  25. package/dist/assets/components/Picking.js +18 -18
  26. package/dist/assets/components/Picking.min.js +1 -1
  27. package/dist/assets/components/RigidBodyPhysics.js +17 -17
  28. package/dist/assets/components/RigidBodyPhysics.min.js +1 -1
  29. package/dist/assets/components/Scripting.js +38 -38
  30. package/dist/assets/components/Scripting.min.js +1 -1
  31. package/dist/assets/components/Text.js +24 -24
  32. package/dist/assets/components/Text.min.js +1 -1
  33. package/dist/assets/components/TextureProjection.js +15 -15
  34. package/dist/assets/components/TextureProjection.min.js +1 -1
  35. package/dist/assets/components/Texturing3D.js +30 -30
  36. package/dist/assets/components/Texturing3D.min.js +1 -1
  37. package/dist/assets/components/VolumeRendering.js +19 -19
  38. package/dist/assets/components/VolumeRendering.min.js +1 -1
  39. package/dist/assets/components/X_ITE.js +9 -9
  40. package/dist/assets/components/X_ITE.min.js +1 -1
  41. package/dist/x_ite.css +1 -1
  42. package/dist/x_ite.js +411 -448
  43. package/dist/x_ite.min.js +1 -1
  44. package/dist/x_ite.min.mjs +1 -1
  45. package/dist/x_ite.mjs +411 -448
  46. package/dist/x_ite.zip +0 -0
  47. package/package.json +1 -1
package/dist/x_ite.js CHANGED
@@ -1,4 +1,4 @@
1
- /* X_ITE v9.0.0 */(function webpackUniversalModuleDefinition(root, factory) {
1
+ /* X_ITE v9.0.2 */(function webpackUniversalModuleDefinition(root, factory) {
2
2
  if(typeof exports === 'object' && typeof module === 'object')
3
3
  module.exports = factory();
4
4
  else if(typeof define === 'function' && define.amd)
@@ -11,10 +11,10 @@
11
11
  return /******/ (() => { // webpackBootstrap
12
12
  /******/ var __webpack_modules__ = ({
13
13
 
14
- /***/ 1:
14
+ /***/ 699:
15
15
  /***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => {
16
16
 
17
- /* provided dependency */ var jQuery = __webpack_require__(978);
17
+ /* provided dependency */ var jQuery = __webpack_require__(718);
18
18
  /**
19
19
  * @preserve jquery.fullscreen 1.1.5
20
20
  * https://github.com/code-lts/jquery-fullscreen-plugin
@@ -210,7 +210,7 @@ installFullScreenHandlers();
210
210
 
211
211
  /***/ }),
212
212
 
213
- /***/ 436:
213
+ /***/ 801:
214
214
  /***/ ((module, exports, __webpack_require__) => {
215
215
 
216
216
  var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
@@ -224,7 +224,7 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
224
224
  (function (factory) {
225
225
  if ( true ) {
226
226
  // AMD. Register as an anonymous module.
227
- !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(978)], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory),
227
+ !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(718)], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory),
228
228
  __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ?
229
229
  (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__),
230
230
  __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
@@ -435,7 +435,7 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
435
435
 
436
436
  /***/ }),
437
437
 
438
- /***/ 978:
438
+ /***/ 718:
439
439
  /***/ (function(module, exports) {
440
440
 
441
441
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
@@ -11159,7 +11159,7 @@ return jQuery;
11159
11159
 
11160
11160
  /***/ }),
11161
11161
 
11162
- /***/ 728:
11162
+ /***/ 89:
11163
11163
  /***/ ((module) => {
11164
11164
 
11165
11165
  /**
@@ -15938,7 +15938,7 @@ if (true) {
15938
15938
 
15939
15939
  /***/ }),
15940
15940
 
15941
- /***/ 899:
15941
+ /***/ 994:
15942
15942
  /***/ (function(__unused_webpack_module, exports) {
15943
15943
 
15944
15944
 
@@ -19183,7 +19183,7 @@ if (true) {
19183
19183
 
19184
19184
  /***/ }),
19185
19185
 
19186
- /***/ 11:
19186
+ /***/ 630:
19187
19187
  /***/ (function(module, exports) {
19188
19188
 
19189
19189
  var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*
@@ -20311,7 +20311,7 @@ Object .defineProperty (Namespace, "add",
20311
20311
  }
20312
20312
  else
20313
20313
  {
20314
- const X3D = window [Symbol .for ("X_ITE.X3D-9.0.0")];
20314
+ const X3D = window [Symbol .for ("X_ITE.X3D-9.0.2")];
20315
20315
 
20316
20316
  if (X3D)
20317
20317
  X3D [name] = module;
@@ -34133,7 +34133,7 @@ const X3DBaseNode_default_ = X3DBaseNode;
34133
34133
  x_ite_Namespace .add ("X3DBaseNode", "x_ite/Base/X3DBaseNode", X3DBaseNode_default_);
34134
34134
  /* harmony default export */ const Base_X3DBaseNode = (X3DBaseNode_default_);
34135
34135
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Legacy.js
34136
- /* provided dependency */ var $ = __webpack_require__(978);
34136
+ /* provided dependency */ var $ = __webpack_require__(718);
34137
34137
  /*******************************************************************************
34138
34138
  *
34139
34139
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -34270,7 +34270,7 @@ x_ite_Namespace .add ("Legacy", "x_ite/Browser/Legacy", Legacy_default_);
34270
34270
  *
34271
34271
  ******************************************************************************/
34272
34272
 
34273
- const VERSION_default_ = "9.0.0";
34273
+ const VERSION_default_ = "9.0.2";
34274
34274
  ;
34275
34275
 
34276
34276
  x_ite_Namespace .add ("VERSION", "x_ite/Browser/VERSION", VERSION_default_);
@@ -38072,7 +38072,7 @@ const X3DProtoDeclarationNode_default_ = X3DProtoDeclarationNode;
38072
38072
  x_ite_Namespace .add ("X3DProtoDeclarationNode", "x_ite/Prototype/X3DProtoDeclarationNode", X3DProtoDeclarationNode_default_);
38073
38073
  /* harmony default export */ const Prototype_X3DProtoDeclarationNode = (X3DProtoDeclarationNode_default_);
38074
38074
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/X3DParser.js
38075
- /* provided dependency */ var X3DParser_$ = __webpack_require__(978);
38075
+ /* provided dependency */ var X3DParser_$ = __webpack_require__(718);
38076
38076
  /*******************************************************************************
38077
38077
  *
38078
38078
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -38897,7 +38897,7 @@ const X3DProtoDeclaration_default_ = X3DProtoDeclaration;
38897
38897
  x_ite_Namespace .add ("X3DProtoDeclaration", "x_ite/Prototype/X3DProtoDeclaration", X3DProtoDeclaration_default_);
38898
38898
  /* harmony default export */ const Prototype_X3DProtoDeclaration = (X3DProtoDeclaration_default_);
38899
38899
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/VRMLParser.js
38900
- /* provided dependency */ var VRMLParser_$ = __webpack_require__(978);
38900
+ /* provided dependency */ var VRMLParser_$ = __webpack_require__(718);
38901
38901
  /*******************************************************************************
38902
38902
  *
38903
38903
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -41442,7 +41442,7 @@ const VRMLParser_default_ = VRMLParser;
41442
41442
  x_ite_Namespace .add ("VRMLParser", "x_ite/Parser/VRMLParser", VRMLParser_default_);
41443
41443
  /* harmony default export */ const Parser_VRMLParser = (VRMLParser_default_);
41444
41444
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/XMLParser.js
41445
- /* provided dependency */ var XMLParser_$ = __webpack_require__(978);
41445
+ /* provided dependency */ var XMLParser_$ = __webpack_require__(718);
41446
41446
  /*******************************************************************************
41447
41447
  *
41448
41448
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -43534,7 +43534,7 @@ const URLs_default_ = URLs;
43534
43534
  x_ite_Namespace .add ("URLs", "x_ite/Browser/Networking/URLs", URLs_default_);
43535
43535
  /* harmony default export */ const Networking_URLs = (URLs_default_);
43536
43536
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/GLTF2Parser.js
43537
- /* provided dependency */ var GLTF2Parser_$ = __webpack_require__(978);
43537
+ /* provided dependency */ var GLTF2Parser_$ = __webpack_require__(718);
43538
43538
  /*******************************************************************************
43539
43539
  *
43540
43540
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -46835,7 +46835,7 @@ const GLTF2Parser_default_ = GLTF2Parser;
46835
46835
  x_ite_Namespace .add ("GLTF2Parser", "x_ite/Parser/GLTF2Parser", GLTF2Parser_default_);
46836
46836
  /* harmony default export */ const Parser_GLTF2Parser = (GLTF2Parser_default_);
46837
46837
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/GLB2Parser.js
46838
- /* provided dependency */ var GLB2Parser_$ = __webpack_require__(978);
46838
+ /* provided dependency */ var GLB2Parser_$ = __webpack_require__(718);
46839
46839
  /*******************************************************************************
46840
46840
  *
46841
46841
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -46987,7 +46987,7 @@ const GLB2Parser_default_ = GLB2Parser;
46987
46987
  x_ite_Namespace .add ("GLB2Parser", "x_ite/Parser/GLB2Parser", GLB2Parser_default_);
46988
46988
  /* harmony default export */ const Parser_GLB2Parser = (GLB2Parser_default_);
46989
46989
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/OBJParser.js
46990
- /* provided dependency */ var OBJParser_$ = __webpack_require__(978);
46990
+ /* provided dependency */ var OBJParser_$ = __webpack_require__(718);
46991
46991
  /*******************************************************************************
46992
46992
  *
46993
46993
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -50342,8 +50342,8 @@ const MatrixStack_default_ = MatrixStack;
50342
50342
  x_ite_Namespace .add ("MatrixStack", "standard/Math/Utility/MatrixStack", MatrixStack_default_);
50343
50343
  /* harmony default export */ const Utility_MatrixStack = (MatrixStack_default_);
50344
50344
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/SVGParser.js
50345
- /* provided dependency */ var SVGParser_$ = __webpack_require__(978);
50346
- /* provided dependency */ var libtess = __webpack_require__(728);
50345
+ /* provided dependency */ var SVGParser_$ = __webpack_require__(718);
50346
+ /* provided dependency */ var libtess = __webpack_require__(89);
50347
50347
  /*******************************************************************************
50348
50348
  *
50349
50349
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53111,7 +53111,7 @@ const SVGParser_default_ = SVGParser;
53111
53111
  x_ite_Namespace .add ("SVGParser", "x_ite/Parser/SVGParser", SVGParser_default_);
53112
53112
  /* harmony default export */ const Parser_SVGParser = (SVGParser_default_);
53113
53113
  ;// CONCATENATED MODULE: ./src/x_ite/Parser/GoldenGate.js
53114
- /* provided dependency */ var GoldenGate_$ = __webpack_require__(978);
53114
+ /* provided dependency */ var GoldenGate_$ = __webpack_require__(718);
53115
53115
  /*******************************************************************************
53116
53116
  *
53117
53117
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53448,7 +53448,7 @@ const Plane3_default_ = Plane3;
53448
53448
  x_ite_Namespace .add ("Plane3", "standard/Math/Geometry/Plane3", Plane3_default_);
53449
53449
  /* harmony default export */ const Geometry_Plane3 = (Plane3_default_);
53450
53450
  ;// CONCATENATED MODULE: ./src/standard/Math/Geometry/Triangle3.js
53451
- /* provided dependency */ var Triangle3_libtess = __webpack_require__(728);
53451
+ /* provided dependency */ var Triangle3_libtess = __webpack_require__(89);
53452
53452
  /*******************************************************************************
53453
53453
  *
53454
53454
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55574,6 +55574,128 @@ const Line3_default_ = Line3;
55574
55574
 
55575
55575
  x_ite_Namespace .add ("Line3", "standard/Math/Geometry/Line3", Line3_default_);
55576
55576
  /* harmony default export */ const Geometry_Line3 = (Line3_default_);
55577
+ ;// CONCATENATED MODULE: ./src/standard/Utility/BitSet.js
55578
+ /*******************************************************************************
55579
+ *
55580
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
55581
+ *
55582
+ * Copyright create3000, Scheffelstraße 31a, Leipzig, Germany 2011 - 2022.
55583
+ *
55584
+ * All rights reserved. Holger Seelig <holger.seelig@yahoo.de>.
55585
+ *
55586
+ * The copyright notice above does not evidence any actual of intended
55587
+ * publication of such source code, and is an unpublished work by create3000.
55588
+ * This material contains CONFIDENTIAL INFORMATION that is the property of
55589
+ * create3000.
55590
+ *
55591
+ * No permission is granted to copy, distribute, or create derivative works from
55592
+ * the contents of this software, in whole or in part, without the prior written
55593
+ * permission of create3000.
55594
+ *
55595
+ * NON-MILITARY USE ONLY
55596
+ *
55597
+ * All create3000 software are effectively free software with a non-military use
55598
+ * restriction. It is free. Well commented source is provided. You may reuse the
55599
+ * source in any way you please with the exception anything that uses it must be
55600
+ * marked to indicate is contains 'non-military use only' components.
55601
+ *
55602
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
55603
+ *
55604
+ * Copyright 2011 - 2022, Holger Seelig <holger.seelig@yahoo.de>.
55605
+ *
55606
+ * This file is part of the X_ITE Project.
55607
+ *
55608
+ * X_ITE is free software: you can redistribute it and/or modify it under the
55609
+ * terms of the GNU General Public License version 3 only, as published by the
55610
+ * Free Software Foundation.
55611
+ *
55612
+ * X_ITE is distributed in the hope that it will be useful, but WITHOUT ANY
55613
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
55614
+ * A PARTICULAR PURPOSE. See the GNU General Public License version 3 for more
55615
+ * details (a copy is included in the LICENSE file that accompanied this code).
55616
+ *
55617
+ * You should have received a copy of the GNU General Public License version 3
55618
+ * along with X_ITE. If not, see <https://www.gnu.org/licenses/gpl.html> for a
55619
+ * copy of the GPLv3 License.
55620
+ *
55621
+ * For Silvio, Joy and Adi.
55622
+ *
55623
+ ******************************************************************************/
55624
+
55625
+
55626
+
55627
+ function BitSet (value = 0)
55628
+ {
55629
+ this .value = value;
55630
+ }
55631
+
55632
+ Object .assign (BitSet .prototype,
55633
+ {
55634
+ *[Symbol .iterator] ()
55635
+ {
55636
+ let
55637
+ value = this .value,
55638
+ index = 0;
55639
+
55640
+ while (value)
55641
+ {
55642
+ if (value & 1)
55643
+ yield index;
55644
+
55645
+ value >>>= 1;
55646
+ index += 1;
55647
+ }
55648
+ },
55649
+ get (index)
55650
+ {
55651
+ const mask = 1 << index;
55652
+
55653
+ return !! (this .value & mask);
55654
+ },
55655
+ set (index, value)
55656
+ {
55657
+ const mask = 1 << index;
55658
+
55659
+ if (value)
55660
+ this .value |= mask;
55661
+ else
55662
+ this .value &= ~mask;
55663
+ },
55664
+ clear ()
55665
+ {
55666
+ this .value = 0;
55667
+ },
55668
+ *entries ()
55669
+ {
55670
+ for (const i of this)
55671
+ yield [i, i];
55672
+ },
55673
+ valueOf ()
55674
+ {
55675
+ return this .value;
55676
+ },
55677
+ toString (radix)
55678
+ {
55679
+ return this .value .toString (radix);
55680
+ },
55681
+ });
55682
+
55683
+ BitSet .prototype .keys = BitSet .prototype [Symbol .iterator];
55684
+ BitSet .prototype .values = BitSet .prototype [Symbol .iterator];
55685
+
55686
+ Object .defineProperty (BitSet .prototype, "size",
55687
+ {
55688
+ get ()
55689
+ {
55690
+ return Math_Algorithm .bitCount (this .value);
55691
+ },
55692
+ });
55693
+
55694
+ const BitSet_default_ = BitSet;
55695
+ ;
55696
+
55697
+ x_ite_Namespace .add ("BitSet", "standard/Utility/BitSet", BitSet_default_);
55698
+ /* harmony default export */ const Utility_BitSet = (BitSet_default_);
55577
55699
  ;// CONCATENATED MODULE: ./src/standard/Time/StopWatch.js
55578
55700
  /*******************************************************************************
55579
55701
  *
@@ -55725,12 +55847,14 @@ x_ite_Namespace .add ("StopWatch", "standard/Time/StopWatch", StopWatch_default_
55725
55847
 
55726
55848
 
55727
55849
 
55850
+
55728
55851
  const DEPTH_BUFFER_SIZE = 16;
55729
55852
 
55730
55853
  function X3DRenderObject (executionContext)
55731
55854
  {
55732
55855
  const browser = executionContext .getBrowser ();
55733
55856
 
55857
+ this .renderBits = new Utility_BitSet ();
55734
55858
  this .renderCount = 0;
55735
55859
  this .viewVolumes = [ ];
55736
55860
  this .cameraSpaceMatrix = new Utility_MatrixStack (Numbers_Matrix4);
@@ -55780,10 +55904,24 @@ Object .assign (X3DRenderObject .prototype,
55780
55904
  {
55781
55905
  return true;
55782
55906
  },
55907
+ getRenderBits ()
55908
+ {
55909
+ return this .renderBits;
55910
+ },
55783
55911
  getRenderCount ()
55784
55912
  {
55785
55913
  return this .renderCount;
55786
55914
  },
55915
+ getNextRenderCount: (function ()
55916
+ {
55917
+ let renderCount = 0;
55918
+
55919
+ return function ()
55920
+ {
55921
+ renderCount >>>= 0; // uintesize
55922
+ return ++ renderCount;
55923
+ }
55924
+ })(),
55787
55925
  getViewVolumes ()
55788
55926
  {
55789
55927
  return this .viewVolumes;
@@ -55820,10 +55958,6 @@ Object .assign (X3DRenderObject .prototype,
55820
55958
  {
55821
55959
  return this .cameraSpaceMatrixArray;
55822
55960
  },
55823
- getLogarithmicDepthBuffer ()
55824
- {
55825
- return this .logarithmicDepthBuffer;
55826
- },
55827
55961
  getHitRay ()
55828
55962
  {
55829
55963
  return this .hitRay;
@@ -56640,158 +56774,152 @@ Object .assign (X3DRenderObject .prototype,
56640
56774
  }
56641
56775
  };
56642
56776
  })(),
56643
- draw: (function ()
56777
+ draw ()
56644
56778
  {
56645
- let renderCount = 0;
56646
-
56647
- return function ()
56648
- {
56649
- const
56650
- browser = this .getBrowser (),
56651
- gl = browser .getContext (),
56652
- frameBuffer = browser .getFrameBuffer (),
56653
- viewport = this .getViewVolume () .getViewport (),
56654
- lights = this .lights,
56655
- globalLightsKeys = this .globalLightsKeys,
56656
- globalLights = this .globalLights,
56657
- generatedCubeMapTextures = this .generatedCubeMapTextures,
56658
- globalShadows = this .globalShadows,
56659
- shadows = globalShadows .at (-1),
56660
- headlight = this .getNavigationInfo () ._headlight .getValue (),
56661
- oit = frameBuffer .getOIT ();
56779
+ const
56780
+ browser = this .getBrowser (),
56781
+ gl = browser .getContext (),
56782
+ frameBuffer = browser .getFrameBuffer (),
56783
+ viewport = this .getViewVolume () .getViewport (),
56784
+ lights = this .lights,
56785
+ globalLightsKeys = this .globalLightsKeys,
56786
+ globalLights = this .globalLights,
56787
+ generatedCubeMapTextures = this .generatedCubeMapTextures,
56788
+ globalShadows = this .globalShadows,
56789
+ shadows = globalShadows .at (-1),
56790
+ headlight = this .getNavigationInfo () ._headlight .getValue (),
56791
+ oit = frameBuffer .getOIT ();
56662
56792
 
56663
- renderCount >>>= 0; // uintesize
56664
- this .renderCount = ++ renderCount;
56793
+ this .renderCount = this .getNextRenderCount ();
56665
56794
 
56666
- this .logarithmicDepthBuffer = browser .getBrowserOption ("LogarithmicDepthBuffer")
56667
- || this .getViewpoint () .getLogarithmicDepthBuffer ();
56795
+ this .renderBits .set (0, browser .getRenderingProperty ("LogarithmicDepthBuffer") || this .getViewpoint () .getLogarithmicDepthBuffer ());
56796
+ this .renderBits .set (1, browser .getBrowserOption ("OrderIndependentTransparency"));
56668
56797
 
56669
- // PREPARATIONS
56798
+ // PREPARATIONS
56670
56799
 
56671
- if (this .isIndependent ())
56672
- {
56673
- // Render shadow maps.
56800
+ if (this .isIndependent ())
56801
+ {
56802
+ // Render shadow maps.
56674
56803
 
56675
- for (const light of lights)
56676
- light .renderShadowMap (this);
56804
+ for (const light of lights)
56805
+ light .renderShadowMap (this);
56677
56806
 
56678
- // Render GeneratedCubeMapTextures.
56807
+ // Render GeneratedCubeMapTextures.
56679
56808
 
56680
- for (const generatedCubeMapTexture of generatedCubeMapTextures)
56681
- generatedCubeMapTexture .renderTexture (this);
56809
+ for (const generatedCubeMapTexture of generatedCubeMapTextures)
56810
+ generatedCubeMapTexture .renderTexture (this);
56682
56811
 
56683
- frameBuffer .bind ();
56684
- }
56812
+ frameBuffer .bind ();
56813
+ }
56685
56814
 
56686
- // Set up shadow matrix for all lights, and matrix for all projective textures.
56815
+ // Set up shadow matrix for all lights, and matrix for all projective textures.
56687
56816
 
56688
- if (headlight)
56689
- browser .getHeadlight () .setGlobalVariables (this);
56817
+ if (headlight)
56818
+ browser .getHeadlight () .setGlobalVariables (this);
56690
56819
 
56691
- for (const light of lights)
56692
- light .setGlobalVariables (this);
56820
+ for (const light of lights)
56821
+ light .setGlobalVariables (this);
56693
56822
 
56694
- for (const light of globalLights)
56695
- globalLightsKeys .push (light .lightNode .getLightKey ());
56823
+ for (const light of globalLights)
56824
+ globalLightsKeys .push (light .lightNode .getLightKey ());
56696
56825
 
56697
- // Set global uniforms.
56826
+ // Set global uniforms.
56698
56827
 
56699
- this .viewportArray .set (viewport);
56700
- this .cameraSpaceMatrixArray .set (this .getCameraSpaceMatrix () .get ());
56701
- this .projectionMatrixArray .set (this .getProjectionMatrix () .get ());
56828
+ this .viewportArray .set (viewport);
56829
+ this .cameraSpaceMatrixArray .set (this .getCameraSpaceMatrix () .get ());
56830
+ this .projectionMatrixArray .set (this .getProjectionMatrix () .get ());
56702
56831
 
56703
- // DRAW
56832
+ // DRAW
56704
56833
 
56705
- // Configure viewport and background
56834
+ // Configure viewport and background
56706
56835
 
56707
- gl .viewport (... viewport);
56708
- gl .scissor (... viewport);
56836
+ gl .viewport (... viewport);
56837
+ gl .scissor (... viewport);
56709
56838
 
56710
- // Draw background.
56839
+ // Draw background.
56711
56840
 
56712
- gl .clear (gl .DEPTH_BUFFER_BIT);
56713
- gl .blendFuncSeparate (gl .SRC_ALPHA, gl .ONE_MINUS_SRC_ALPHA, gl .ONE, gl .ONE_MINUS_SRC_ALPHA);
56841
+ gl .clear (gl .DEPTH_BUFFER_BIT);
56842
+ gl .blendFuncSeparate (gl .SRC_ALPHA, gl .ONE_MINUS_SRC_ALPHA, gl .ONE, gl .ONE_MINUS_SRC_ALPHA);
56714
56843
 
56715
- this .getBackground () .display (gl, this, viewport);
56844
+ this .getBackground () .display (gl, this, viewport);
56716
56845
 
56717
- // Sorted blend or order independent transparency
56846
+ // Sorted blend or order independent transparency
56718
56847
 
56719
- // Render opaque objects first
56848
+ // Render opaque objects first
56720
56849
 
56721
- const opaqueShapes = this .opaqueShapes;
56850
+ const opaqueShapes = this .opaqueShapes;
56722
56851
 
56723
- for (let i = 0, length = this .numOpaqueShapes; i < length; ++ i)
56724
- {
56725
- const renderContext = opaqueShapes [i];
56852
+ for (let i = 0, length = this .numOpaqueShapes; i < length; ++ i)
56853
+ {
56854
+ const renderContext = opaqueShapes [i];
56726
56855
 
56727
- gl .scissor (... renderContext .scissor);
56856
+ gl .scissor (... renderContext .scissor);
56728
56857
 
56729
- renderContext .shadows = renderContext .shadows || shadows;
56730
- renderContext .objectsKeys .push (... globalLightsKeys);
56858
+ renderContext .shadows = renderContext .shadows || shadows;
56859
+ renderContext .objectsKeys .push (... globalLightsKeys);
56731
56860
 
56732
- renderContext .shapeNode .display (gl, renderContext);
56733
- browser .resetTextureUnits ();
56734
- }
56861
+ renderContext .shapeNode .display (gl, renderContext);
56862
+ browser .resetTextureUnits ();
56863
+ }
56735
56864
 
56736
- // Render transparent objects
56865
+ // Render transparent objects
56737
56866
 
56738
- const transparentShapes = this .transparentShapes;
56867
+ const transparentShapes = this .transparentShapes;
56739
56868
 
56740
- if (oit)
56741
- frameBuffer .bindTransparency ();
56742
- else
56743
- this .transparencySorter .sort (0, this .numTransparentShapes);
56869
+ if (oit)
56870
+ frameBuffer .bindTransparency ();
56871
+ else
56872
+ this .transparencySorter .sort (0, this .numTransparentShapes);
56744
56873
 
56745
- gl .depthMask (false);
56746
- gl .enable (gl .BLEND);
56874
+ gl .depthMask (false);
56875
+ gl .enable (gl .BLEND);
56747
56876
 
56748
- for (let i = 0, length = this .numTransparentShapes; i < length; ++ i)
56749
- {
56750
- const renderContext = transparentShapes [i];
56877
+ for (let i = 0, length = this .numTransparentShapes; i < length; ++ i)
56878
+ {
56879
+ const renderContext = transparentShapes [i];
56751
56880
 
56752
- gl .scissor (... renderContext .scissor);
56881
+ gl .scissor (... renderContext .scissor);
56753
56882
 
56754
- renderContext .shadows = renderContext .shadows || shadows;
56755
- renderContext .objectsKeys .push (... globalLightsKeys);
56883
+ renderContext .shadows = renderContext .shadows || shadows;
56884
+ renderContext .objectsKeys .push (... globalLightsKeys);
56756
56885
 
56757
- renderContext .shapeNode .display (gl, renderContext);
56758
- browser .resetTextureUnits ();
56759
- }
56886
+ renderContext .shapeNode .display (gl, renderContext);
56887
+ browser .resetTextureUnits ();
56888
+ }
56760
56889
 
56761
- gl .depthMask (true);
56762
- gl .disable (gl .BLEND);
56890
+ gl .depthMask (true);
56891
+ gl .disable (gl .BLEND);
56763
56892
 
56764
- if (oit)
56765
- frameBuffer .compose ();
56893
+ if (oit)
56894
+ frameBuffer .compose ();
56766
56895
 
56767
- // POST DRAW
56896
+ // POST DRAW
56768
56897
 
56769
- if (this .isIndependent ())
56770
- {
56771
- // Recycle clip planes, local fogs, local lights, and local projective textures.
56898
+ if (this .isIndependent ())
56899
+ {
56900
+ // Recycle clip planes, local fogs, local lights, and local projective textures.
56772
56901
 
56773
- const localObjects = browser .getLocalObjects ();
56902
+ const localObjects = browser .getLocalObjects ();
56774
56903
 
56775
- for (const localObject of localObjects)
56776
- localObject .dispose ();
56904
+ for (const localObject of localObjects)
56905
+ localObject .dispose ();
56777
56906
 
56778
- localObjects .length = 0;
56907
+ localObjects .length = 0;
56779
56908
 
56780
- // Recycle global lights and global projective textures.
56909
+ // Recycle global lights and global projective textures.
56781
56910
 
56782
- for (const globalObject of globalLights)
56783
- globalObject .dispose ();
56784
- }
56911
+ for (const globalObject of globalLights)
56912
+ globalObject .dispose ();
56913
+ }
56785
56914
 
56786
- // Reset containers.
56915
+ // Reset containers.
56787
56916
 
56788
- globalLightsKeys .length = 0;
56789
- globalLights .length = 0;
56790
- lights .length = 0;
56791
- globalShadows .length = 1;
56792
- generatedCubeMapTextures .length = 0;
56793
- };
56794
- })(),
56917
+ globalLightsKeys .length = 0;
56918
+ globalLights .length = 0;
56919
+ lights .length = 0;
56920
+ globalShadows .length = 1;
56921
+ generatedCubeMapTextures .length = 0;
56922
+ },
56795
56923
  });
56796
56924
 
56797
56925
  function X3DRenderObject_assign (lhs, rhs)
@@ -59481,128 +59609,6 @@ const GeometryContext_default_ = GeometryContext;
59481
59609
 
59482
59610
  x_ite_Namespace .add ("GeometryContext", "x_ite/Browser/Rendering/GeometryContext", GeometryContext_default_);
59483
59611
  /* harmony default export */ const Rendering_GeometryContext = (GeometryContext_default_);
59484
- ;// CONCATENATED MODULE: ./src/standard/Utility/BitSet.js
59485
- /*******************************************************************************
59486
- *
59487
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
59488
- *
59489
- * Copyright create3000, Scheffelstraße 31a, Leipzig, Germany 2011 - 2022.
59490
- *
59491
- * All rights reserved. Holger Seelig <holger.seelig@yahoo.de>.
59492
- *
59493
- * The copyright notice above does not evidence any actual of intended
59494
- * publication of such source code, and is an unpublished work by create3000.
59495
- * This material contains CONFIDENTIAL INFORMATION that is the property of
59496
- * create3000.
59497
- *
59498
- * No permission is granted to copy, distribute, or create derivative works from
59499
- * the contents of this software, in whole or in part, without the prior written
59500
- * permission of create3000.
59501
- *
59502
- * NON-MILITARY USE ONLY
59503
- *
59504
- * All create3000 software are effectively free software with a non-military use
59505
- * restriction. It is free. Well commented source is provided. You may reuse the
59506
- * source in any way you please with the exception anything that uses it must be
59507
- * marked to indicate is contains 'non-military use only' components.
59508
- *
59509
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
59510
- *
59511
- * Copyright 2011 - 2022, Holger Seelig <holger.seelig@yahoo.de>.
59512
- *
59513
- * This file is part of the X_ITE Project.
59514
- *
59515
- * X_ITE is free software: you can redistribute it and/or modify it under the
59516
- * terms of the GNU General Public License version 3 only, as published by the
59517
- * Free Software Foundation.
59518
- *
59519
- * X_ITE is distributed in the hope that it will be useful, but WITHOUT ANY
59520
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
59521
- * A PARTICULAR PURPOSE. See the GNU General Public License version 3 for more
59522
- * details (a copy is included in the LICENSE file that accompanied this code).
59523
- *
59524
- * You should have received a copy of the GNU General Public License version 3
59525
- * along with X_ITE. If not, see <https://www.gnu.org/licenses/gpl.html> for a
59526
- * copy of the GPLv3 License.
59527
- *
59528
- * For Silvio, Joy and Adi.
59529
- *
59530
- ******************************************************************************/
59531
-
59532
-
59533
-
59534
- function BitSet (value = 0)
59535
- {
59536
- this .value = value;
59537
- }
59538
-
59539
- Object .assign (BitSet .prototype,
59540
- {
59541
- *[Symbol .iterator] ()
59542
- {
59543
- let
59544
- value = this .value,
59545
- index = 0;
59546
-
59547
- while (value)
59548
- {
59549
- if (value & 1)
59550
- yield index;
59551
-
59552
- value >>>= 1;
59553
- index += 1;
59554
- }
59555
- },
59556
- get (index)
59557
- {
59558
- const mask = 1 << index;
59559
-
59560
- return !! (this .value & mask);
59561
- },
59562
- set (index, value)
59563
- {
59564
- const mask = 1 << index;
59565
-
59566
- if (value)
59567
- this .value |= mask;
59568
- else
59569
- this .value &= ~mask;
59570
- },
59571
- clear ()
59572
- {
59573
- this .value = 0;
59574
- },
59575
- *entries ()
59576
- {
59577
- for (const i of this)
59578
- yield [i, i];
59579
- },
59580
- valueOf ()
59581
- {
59582
- return this .value;
59583
- },
59584
- toString (radix)
59585
- {
59586
- return this .value .toString (radix);
59587
- },
59588
- });
59589
-
59590
- BitSet .prototype .keys = BitSet .prototype [Symbol .iterator];
59591
- BitSet .prototype .values = BitSet .prototype [Symbol .iterator];
59592
-
59593
- Object .defineProperty (BitSet .prototype, "size",
59594
- {
59595
- get ()
59596
- {
59597
- return Math_Algorithm .bitCount (this .value);
59598
- },
59599
- });
59600
-
59601
- const BitSet_default_ = BitSet;
59602
- ;
59603
-
59604
- x_ite_Namespace .add ("BitSet", "standard/Utility/BitSet", BitSet_default_);
59605
- /* harmony default export */ const Utility_BitSet = (BitSet_default_);
59606
59612
  ;// CONCATENATED MODULE: ./src/x_ite/Components/EnvironmentalEffects/X3DBackgroundNode.js
59607
59613
  /*******************************************************************************
59608
59614
  *
@@ -60649,10 +60655,8 @@ Object .assign (Object .setPrototypeOf (X3DSingleTextureNode .prototype, Texturi
60649
60655
  if (this .texturePropertiesNode)
60650
60656
  this .texturePropertiesNode .removeInterest ("updateTextureParameters", this);
60651
60657
 
60652
- this .texturePropertiesNode = Base_X3DCast (Base_X3DConstants .TextureProperties, this ._textureProperties);
60653
-
60654
- if (!this .texturePropertiesNode)
60655
- this .texturePropertiesNode = this .getBrowser () .getDefaultTextureProperties ();
60658
+ this .texturePropertiesNode = Base_X3DCast (Base_X3DConstants .TextureProperties, this ._textureProperties)
60659
+ ?? this .getBrowser () .getDefaultTextureProperties ();
60656
60660
 
60657
60661
  this .texturePropertiesNode .addInterest ("updateTextureParameters", this);
60658
60662
 
@@ -60687,8 +60691,9 @@ Object .assign (Object .setPrototypeOf (X3DSingleTextureNode .prototype, Texturi
60687
60691
  {
60688
60692
  if (this .generateMipMaps)
60689
60693
  {
60694
+ // https://stackoverflow.com/a/25640078/1818915
60690
60695
  this .levels = textureProperties ._generateMipMaps .getValue ()
60691
- ? 1 + Math .log2 (Math .max (width, height))
60696
+ ? 1 + Math .floor (Math .log2 (Math .max (width, height)))
60692
60697
  : 1;
60693
60698
 
60694
60699
  if (textureProperties ._generateMipMaps .getValue ())
@@ -60952,7 +60957,7 @@ const X3DTexture2DNode_default_ = X3DTexture2DNode;
60952
60957
  x_ite_Namespace .add ("X3DTexture2DNode", "x_ite/Components/Texturing/X3DTexture2DNode", X3DTexture2DNode_default_);
60953
60958
  /* harmony default export */ const Texturing_X3DTexture2DNode = (X3DTexture2DNode_default_);
60954
60959
  ;// CONCATENATED MODULE: ./src/x_ite/Components/Texturing/ImageTexture.js
60955
- /* provided dependency */ var ImageTexture_$ = __webpack_require__(978);
60960
+ /* provided dependency */ var ImageTexture_$ = __webpack_require__(718);
60956
60961
  /*******************************************************************************
60957
60962
  *
60958
60963
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63673,9 +63678,7 @@ Object .assign (Object .setPrototypeOf (X3DViewpointNode .prototype, Core_X3DBin
63673
63678
  {
63674
63679
  bbox = bbox .copy () .multRight (this .getModelMatrix () .copy () .inverse ());
63675
63680
 
63676
- const minDistance = Math .max (layerNode .getNavigationInfo () .getNearValue () * 2, this .getLookAtDistance (bbox));
63677
-
63678
- this .lookAt (layerNode, bbox .center, minDistance, transitionTime, factor, straighten);
63681
+ this .lookAt (layerNode, bbox .center, this .getLookAtDistance (bbox), transitionTime, factor, straighten);
63679
63682
  },
63680
63683
  lookAt (layerNode, point, distance, transitionTime = 1, factor = 1, straighten = false)
63681
63684
  {
@@ -63712,7 +63715,7 @@ Object .assign (Object .setPrototypeOf (X3DViewpointNode .prototype, Core_X3DBin
63712
63715
 
63713
63716
  this ._fieldOfViewScale = 1;
63714
63717
  this ._centerOfRotationOffset = point .copy () .subtract (this .getCenterOfRotation ());
63715
- this .nearDistance = Math .min (distance / 2, 0.125);
63718
+ this .nearDistance = distance * (0.125 / 10);
63716
63719
  this .farDistance = this .nearDistance * this .getMaxFarValue () / 0.125;
63717
63720
 
63718
63721
  this .setInterpolators (this, relative);
@@ -63770,7 +63773,7 @@ Object .assign (Object .setPrototypeOf (X3DViewpointNode .prototype, Core_X3DBin
63770
63773
  })(),
63771
63774
  viewAll (bbox)
63772
63775
  {
63773
- bbox .multRight (this .modelMatrix .copy () .inverse ());
63776
+ bbox .copy () .multRight (this .modelMatrix .copy () .inverse ());
63774
63777
 
63775
63778
  const
63776
63779
  direction = this .getUserPosition () .copy () .subtract (bbox .center) .normalize (),
@@ -63782,7 +63785,7 @@ Object .assign (Object .setPrototypeOf (X3DViewpointNode .prototype, Core_X3DBin
63782
63785
  this ._orientationOffset = this .getOrientation () .copy () .inverse () .multRight (userOrientation);
63783
63786
  this ._centerOfRotationOffset = bbox .center .copy () .subtract (this .getCenterOfRotation ());
63784
63787
  this ._fieldOfViewScale = 1;
63785
- this .nearDistance = Math .min ((distance - bbox .size .magnitude ()) / 2, 0.125);
63788
+ this .nearDistance = distance * (0.125 / 10);
63786
63789
  this .farDistance = this .nearDistance * this .getMaxFarValue () / 0.125;
63787
63790
  },
63788
63791
  traverse (type, renderObject)
@@ -65543,7 +65546,7 @@ const X3DWorld_default_ = X3DWorld;
65543
65546
  x_ite_Namespace .add ("X3DWorld", "x_ite/Execution/X3DWorld", X3DWorld_default_);
65544
65547
  /* harmony default export */ const Execution_X3DWorld = (X3DWorld_default_);
65545
65548
  ;// CONCATENATED MODULE: ./src/x_ite/InputOutput/FileLoader.js
65546
- /* provided dependency */ var FileLoader_$ = __webpack_require__(978);
65549
+ /* provided dependency */ var FileLoader_$ = __webpack_require__(718);
65547
65550
  /*******************************************************************************
65548
65551
  *
65549
65552
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -79669,7 +79672,7 @@ Object .assign (Object .setPrototypeOf (X3DLightNode .prototype, Core_X3DChildNo
79669
79672
  },
79670
79673
  getLightKey ()
79671
79674
  {
79672
- return 1;
79675
+ return 1; // [ClipPlane 0, X3DLightNode 1, EnvironmentLight 2, X3DTextureProjectorNode 3]
79673
79676
  },
79674
79677
  getEnabled ()
79675
79678
  {
@@ -80214,14 +80217,16 @@ Object .assign (EnvironmentLightContainer .prototype,
80214
80217
  gl .uniform3f (shaderObject .x3d_EnvironmentLightColor, color .r, color .g, color .b);
80215
80218
  gl .uniform1f (shaderObject .x3d_EnvironmentLightIntensity, lightNode .getIntensity ());
80216
80219
  gl .uniformMatrix3fv (shaderObject .x3d_EnvironmentLightRotation, false, lightNode .getRotation ());
80220
+ gl .uniform1i (shaderObject .x3d_EnvironmentLightDiffuseTextureLinear, diffuseTexture ?.isLinear ());
80221
+ gl .uniform1i (shaderObject .x3d_EnvironmentLightSpecularTextureLinear, specularTexture ?.isLinear ());
80217
80222
  gl .uniform1i (shaderObject .x3d_EnvironmentLightSpecularTextureLevels, specularTexture ?.getLevels () ?? 1);
80218
80223
 
80219
80224
  gl .activeTexture (gl .TEXTURE0 + diffuseTextureUnit);
80220
- gl .bindTexture (gl .TEXTURE_CUBE_MAP, diffuseTexture ?.getTexture () ?? browser .getDefaultTextureCubeBlack ());
80225
+ gl .bindTexture (gl .TEXTURE_CUBE_MAP, diffuseTexture ?.getTexture () ?? browser .getDefaultTextureCube ());
80221
80226
  gl .uniform1i (shaderObject .x3d_EnvironmentLightDiffuseTexture, diffuseTextureUnit);
80222
80227
 
80223
80228
  gl .activeTexture (gl .TEXTURE0 + specularTextureUnit);
80224
- gl .bindTexture (gl .TEXTURE_CUBE_MAP, specularTexture ?.getTexture () ?? browser .getDefaultTextureCubeBlack ());
80229
+ gl .bindTexture (gl .TEXTURE_CUBE_MAP, specularTexture ?.getTexture () ?? browser .getDefaultTextureCube ());
80225
80230
  gl .uniform1i (shaderObject .x3d_EnvironmentLightSpecularTexture, specularTextureUnit);
80226
80231
 
80227
80232
  gl .activeTexture (gl .TEXTURE0 + GGXLUTTextureUnit);
@@ -89138,7 +89143,7 @@ const X3DShaderNode_default_ = X3DShaderNode;
89138
89143
  x_ite_Namespace .add ("X3DShaderNode", "x_ite/Components/Shaders/X3DShaderNode", X3DShaderNode_default_);
89139
89144
  /* harmony default export */ const Shaders_X3DShaderNode = (X3DShaderNode_default_);
89140
89145
  ;// CONCATENATED MODULE: ./src/x_ite/Components/Shaders/X3DProgrammableShaderObject.js
89141
- /* provided dependency */ var X3DProgrammableShaderObject_$ = __webpack_require__(978);
89146
+ /* provided dependency */ var X3DProgrammableShaderObject_$ = __webpack_require__(718);
89142
89147
  /*******************************************************************************
89143
89148
  *
89144
89149
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -89337,7 +89342,9 @@ Object .assign (X3DProgrammableShaderObject .prototype,
89337
89342
  this .x3d_EnvironmentLightAmbientIntensity = gl .getUniformLocation (program, "x3d_EnvironmentLightSource.ambientIntensity");
89338
89343
  this .x3d_EnvironmentLightRotation = gl .getUniformLocation (program, "x3d_EnvironmentLightSource.rotation");
89339
89344
  this .x3d_EnvironmentLightDiffuseTexture = gl .getUniformLocation (program, "x3d_EnvironmentLightSource.diffuseTexture");
89345
+ this .x3d_EnvironmentLightDiffuseTextureLinear = gl .getUniformLocation (program, "x3d_EnvironmentLightSource.diffuseTextureLinear");
89340
89346
  this .x3d_EnvironmentLightSpecularTexture = gl .getUniformLocation (program, "x3d_EnvironmentLightSource.specularTexture");
89347
+ this .x3d_EnvironmentLightSpecularTextureLinear = gl .getUniformLocation (program, "x3d_EnvironmentLightSource.specularTextureLinear");
89341
89348
  this .x3d_EnvironmentLightSpecularTextureLevels = gl .getUniformLocation (program, "x3d_EnvironmentLightSource.specularTextureLevels");
89342
89349
  this .x3d_EnvironmentLightGGXLUTTexture = gl .getUniformLocation (program, "x3d_EnvironmentLightSource.GGXLUTTexture");
89343
89350
 
@@ -90170,7 +90177,7 @@ Object .assign (X3DProgrammableShaderObject .prototype,
90170
90177
 
90171
90178
  // Logarithmic depth buffer support
90172
90179
 
90173
- if (renderObject .getLogarithmicDepthBuffer ())
90180
+ if (renderObject .getRenderBits () .get (0))
90174
90181
  {
90175
90182
  const
90176
90183
  viewpoint = renderObject .getViewpoint (),
@@ -91534,7 +91541,7 @@ mediump vec3 shadowColor;mediump float shadowIntensity;mediump float shadowBias;
91534
91541
  };
91535
91542
  #endif
91536
91543
  #if defined(X3D_USE_IBL)
91537
- struct x3d_EnvironmentLightSourceParameters{mediump vec3 color;mediump float intensity;mediump float ambientIntensity;mediump mat3 rotation;mediump samplerCube diffuseTexture;mediump samplerCube specularTexture;mediump int specularTextureLevels;mediump sampler2D GGXLUTTexture;};
91544
+ struct x3d_EnvironmentLightSourceParameters{mediump vec3 color;mediump float intensity;mediump float ambientIntensity;mediump mat3 rotation;mediump samplerCube diffuseTexture;bool diffuseTextureLinear;mediump samplerCube specularTexture;bool specularTextureLinear;mediump int specularTextureLevels;mediump sampler2D GGXLUTTexture;};
91538
91545
  #endif
91539
91546
  #if defined(X3D_GEOMETRY_0D)&&defined(X3D_STYLE_PROPERTIES)
91540
91547
  struct x3d_PointPropertiesParameters{mediump float pointSizeScaleFactor;mediump float pointSizeMinValue;mediump float pointSizeMaxValue;mediump vec3 attenuation;};
@@ -94099,14 +94106,17 @@ return finalColor;}void main(){fragment_main();}`
94099
94106
  x_ite_Namespace .add ("Unlit2.fs", "assets/shaders/webgl2/Unlit2.fs", Unlit2_fs_default_);
94100
94107
  /* harmony default export */ const Unlit2_fs = (Unlit2_fs_default_);
94101
94108
  ;// CONCATENATED MODULE: ./src/assets/shaders/webgl1/pbr/BDRF1.glsl.js
94102
- const BDRF1_glsl_default_ = /* glsl */ `const float M_PI=3.14159265359;vec3 F_Schlick(vec3 f0,vec3 f90,float VdotH){return f0+(f90-f0)*pow(clamp(1.0-VdotH,0.0,1.0),5.0);}float V_GGX(float NdotL,float NdotV,float alphaRoughness){float alphaRoughnessSq=alphaRoughness*alphaRoughness;float GGXV=NdotL*sqrt(NdotV*NdotV*(1.0-alphaRoughnessSq)+alphaRoughnessSq);float GGXL=NdotV*sqrt(NdotL*NdotL*(1.0-alphaRoughnessSq)+alphaRoughnessSq);float GGX=GGXV+GGXL;if(GGX>0.0){return 0.5/GGX;}return 0.0;}float D_GGX(float NdotH,float alphaRoughness){float alphaRoughnessSq=alphaRoughness*alphaRoughness;float f=(NdotH*NdotH)*(alphaRoughnessSq-1.0)+1.0;return alphaRoughnessSq/(M_PI*f*f);}vec3 BRDF_lambertian(vec3 f0,vec3 f90,vec3 diffuseColor,float specularWeight,float VdotH){return(1.0-specularWeight*F_Schlick(f0,f90,VdotH))*(diffuseColor/M_PI);}vec3 BRDF_specularGGX(vec3 f0,vec3 f90,float alphaRoughness,float specularWeight,float VdotH,float NdotL,float NdotV,float NdotH){vec3 F=F_Schlick(f0,f90,VdotH);float Vis=V_GGX(NdotL,NdotV,alphaRoughness);float D=D_GGX(NdotH,alphaRoughness);return specularWeight*F*Vis*D;}`
94109
+ const BDRF1_glsl_default_ = /* glsl */ `#if defined(X3D_LIGHTING)
94110
+ const float M_PI=3.14159265359;vec3 F_Schlick(vec3 f0,vec3 f90,float VdotH){return f0+(f90-f0)*pow(clamp(1.0-VdotH,0.0,1.0),5.0);}float V_GGX(float NdotL,float NdotV,float alphaRoughness){float alphaRoughnessSq=alphaRoughness*alphaRoughness;float GGXV=NdotL*sqrt(NdotV*NdotV*(1.0-alphaRoughnessSq)+alphaRoughnessSq);float GGXL=NdotV*sqrt(NdotL*NdotL*(1.0-alphaRoughnessSq)+alphaRoughnessSq);float GGX=GGXV+GGXL;if(GGX>0.0){return 0.5/GGX;}return 0.0;}float D_GGX(float NdotH,float alphaRoughness){float alphaRoughnessSq=alphaRoughness*alphaRoughness;float f=(NdotH*NdotH)*(alphaRoughnessSq-1.0)+1.0;return alphaRoughnessSq/(M_PI*f*f);}vec3 BRDF_lambertian(vec3 f0,vec3 f90,vec3 diffuseColor,float specularWeight,float VdotH){return(1.0-specularWeight*F_Schlick(f0,f90,VdotH))*(diffuseColor/M_PI);}vec3 BRDF_specularGGX(vec3 f0,vec3 f90,float alphaRoughness,float specularWeight,float VdotH,float NdotL,float NdotV,float NdotH){vec3 F=F_Schlick(f0,f90,VdotH);float Vis=V_GGX(NdotL,NdotV,alphaRoughness);float D=D_GGX(NdotH,alphaRoughness);return specularWeight*F*Vis*D;}
94111
+ #endif
94112
+ `
94103
94113
  ;
94104
94114
 
94105
94115
  x_ite_Namespace .add ("BDRF1.glsl", "assets/shaders/webgl1/pbr/BDRF1.glsl", BDRF1_glsl_default_);
94106
94116
  /* harmony default export */ const BDRF1_glsl = (BDRF1_glsl_default_);
94107
94117
  ;// CONCATENATED MODULE: ./src/assets/shaders/webgl1/pbr/IBL1.glsl.js
94108
94118
  const IBL1_glsl_default_ = /* glsl */ `#if defined(X3D_USE_IBL)
94109
- uniform x3d_EnvironmentLightSourceParameters x3d_EnvironmentLightSource;vec3 getDiffuseLight(const in vec3 n){return textureCube(x3d_EnvironmentLightSource.diffuseTexture,x3d_EnvironmentLightSource.rotation*n).rgb*x3d_EnvironmentLightSource.color*x3d_EnvironmentLightSource.intensity;}vec3 getSpecularLight(const in vec3 reflection,const in float lod){return textureCubeLodEXT(x3d_EnvironmentLightSource.specularTexture,x3d_EnvironmentLightSource.rotation*reflection,lod).rgb*x3d_EnvironmentLightSource.color*x3d_EnvironmentLightSource.intensity;}vec3 getIBLRadianceGGX(const in vec3 n,const in vec3 v,const in float roughness,const in vec3 F0,const in float specularWeight){float NdotV=clamp(dot(n,v),0.0,1.0);float lod=roughness*float(x3d_EnvironmentLightSource.specularTextureLevels-1);vec3 reflection=normalize(reflect(-v,n));vec2 brdfSamplePoint=clamp(vec2(NdotV,1.0-roughness),vec2(0.0),vec2(1.0));vec2 f_ab=texture2D(x3d_EnvironmentLightSource.GGXLUTTexture,brdfSamplePoint).rg;vec3 specularLight=getSpecularLight(reflection,lod);vec3 Fr=max(vec3(1.0-roughness),F0)-F0;vec3 k_S=F0+Fr*pow(1.0-NdotV,5.0);vec3 FssEss=k_S*f_ab.x+f_ab.y;return specularWeight*specularLight*FssEss;}vec3 getIBLRadianceLambertian(const in vec3 n,const in vec3 v,const in float roughness,const in vec3 diffuseColor,const in vec3 F0,const in float specularWeight){float NdotV=clamp(dot(n,v),0.0,1.0);vec2 brdfSamplePoint=clamp(vec2(NdotV,1.0-roughness),vec2(0.0),vec2(1.0));vec2 f_ab=texture2D(x3d_EnvironmentLightSource.GGXLUTTexture,brdfSamplePoint).rg;vec3 irradiance=getDiffuseLight(n);vec3 Fr=max(vec3(1.0-roughness),F0)-F0;vec3 k_S=F0+Fr*pow(1.0-NdotV,5.0);vec3 FssEss=specularWeight*k_S*f_ab.x+f_ab.y;float Ems=(1.0-(f_ab.x+f_ab.y));vec3 F_avg=specularWeight*(F0+(1.0-F0)/21.0);vec3 FmsEms=Ems*FssEss*F_avg/(1.0-F_avg*Ems);vec3 k_D=diffuseColor*(1.0-FssEss+FmsEms);return(FmsEms+k_D)*irradiance;}
94119
+ uniform x3d_EnvironmentLightSourceParameters x3d_EnvironmentLightSource;vec3 getDiffuseLight(const in vec3 n){vec3 textureColor=textureCube(x3d_EnvironmentLightSource.diffuseTexture,x3d_EnvironmentLightSource.rotation*n).rgb;if(!x3d_EnvironmentLightSource.diffuseTextureLinear)textureColor=sRGBToLinear(textureColor);return textureColor*x3d_EnvironmentLightSource.color*x3d_EnvironmentLightSource.intensity;}vec3 getSpecularLight(const in vec3 reflection,const in float lod){vec3 textureColor=textureCubeLodEXT(x3d_EnvironmentLightSource.specularTexture,x3d_EnvironmentLightSource.rotation*reflection,lod).rgb;if(!x3d_EnvironmentLightSource.specularTextureLinear)textureColor=sRGBToLinear(textureColor);return textureColor*x3d_EnvironmentLightSource.color*x3d_EnvironmentLightSource.intensity;}vec3 getIBLRadianceGGX(const in vec3 n,const in vec3 v,const in float roughness,const in vec3 F0,const in float specularWeight){float NdotV=clamp(dot(n,v),0.0,1.0);float lod=roughness*float(x3d_EnvironmentLightSource.specularTextureLevels-1);vec3 reflection=normalize(reflect(-v,n));vec2 brdfSamplePoint=clamp(vec2(NdotV,roughness),vec2(0.0),vec2(1.0));vec2 f_ab=texture2D(x3d_EnvironmentLightSource.GGXLUTTexture,brdfSamplePoint).rg;vec3 specularLight=getSpecularLight(reflection,lod);vec3 Fr=max(vec3(1.0-roughness),F0)-F0;vec3 k_S=F0+Fr*pow(1.0-NdotV,5.0);vec3 FssEss=k_S*f_ab.x+f_ab.y;return specularWeight*specularLight*FssEss;}vec3 getIBLRadianceLambertian(const in vec3 n,const in vec3 v,const in float roughness,const in vec3 diffuseColor,const in vec3 F0,const in float specularWeight){float NdotV=clamp(dot(n,v),0.0,1.0);vec2 brdfSamplePoint=clamp(vec2(NdotV,roughness),vec2(0.0),vec2(1.0));vec2 f_ab=texture2D(x3d_EnvironmentLightSource.GGXLUTTexture,brdfSamplePoint).rg;vec3 irradiance=getDiffuseLight(n);vec3 Fr=max(vec3(1.0-roughness),F0)-F0;vec3 k_S=F0+Fr*pow(1.0-NdotV,5.0);vec3 FssEss=specularWeight*k_S*f_ab.x+f_ab.y;float Ems=(1.0-(f_ab.x+f_ab.y));vec3 F_avg=specularWeight*(F0+(1.0-F0)/21.0);vec3 FmsEms=Ems*FssEss*F_avg/(1.0-F_avg*Ems);vec3 k_D=diffuseColor*(1.0-FssEss+FmsEms);return(FmsEms+k_D)*irradiance;}
94110
94120
  #endif
94111
94121
  `
94112
94122
  ;
@@ -94187,7 +94197,7 @@ return baseColor;}
94187
94197
  #if defined(X3D_METALLIC_ROUGHNESS_TEXTURE)
94188
94198
  uniform x3d_MetallicRoughnessTextureParameters x3d_MetallicRoughnessTexture;
94189
94199
  #endif
94190
- MaterialInfo getMetallicRoughnessInfo(MaterialInfo info){info.metallic=x3d_Material.metallic;info.perceptualRoughness=x3d_Material.roughness;
94200
+ MaterialInfo getMetallicRoughnessInfo(in MaterialInfo info){info.metallic=x3d_Material.metallic;info.perceptualRoughness=x3d_Material.roughness;
94191
94201
  #if defined(X3D_METALLIC_ROUGHNESS_TEXTURE)
94192
94202
  vec3 texCoord=getTexCoord(x3d_MetallicRoughnessTexture.textureTransformMapping,x3d_MetallicRoughnessTexture.textureCoordinateMapping);
94193
94203
  #if defined(X3D_METALLIC_ROUGHNESS_TEXTURE_FLIP_Y)
@@ -94222,7 +94232,7 @@ emissiveColor*=textureColor;
94222
94232
  emissiveColor*=sRGBToLinear(textureColor);
94223
94233
  #endif
94224
94234
  #endif
94225
- return emissiveColor.rgb;}
94235
+ return emissiveColor;}
94226
94236
  #if defined(X3D_OCCLUSION_TEXTURE)
94227
94237
  uniform x3d_OcclusionTextureParameters x3d_OcclusionTexture;
94228
94238
  #endif
@@ -94246,7 +94256,7 @@ return 1.0;
94246
94256
  x_ite_Namespace .add ("MaterialInfo1.glsl", "assets/shaders/webgl1/pbr/MaterialInfo1.glsl", MaterialInfo1_glsl_default_);
94247
94257
  /* harmony default export */ const MaterialInfo1_glsl = (MaterialInfo1_glsl_default_);
94248
94258
  ;// CONCATENATED MODULE: ./src/assets/shaders/webgl1/pbr/ToneMapping1.glsl.js
94249
- const ToneMapping1_glsl_default_ = /* glsl */ `const float exposure=1.0;const float GAMMA=2.2;const float INV_GAMMA=1.0/GAMMA;vec3 linearTosRGB(const in vec3 color){return pow(color,vec3(INV_GAMMA));}vec4 linearTosRGB(const in vec4 color){return vec4(linearTosRGB(color.rgb),color.a);}vec3 sRGBToLinear(const in vec3 color){return vec3(pow(color,vec3(GAMMA)));}vec4 sRGBToLinear(const in vec4 color){return vec4(sRGBToLinear(color.rgb),color.a);}
94259
+ const ToneMapping1_glsl_default_ = /* glsl */ `const float exposure=1.0;const float GAMMA=2.2;const float INV_GAMMA=1.0/GAMMA;vec3 linearTosRGB(const in vec3 color){return pow(color,vec3(INV_GAMMA));}vec4 linearTosRGB(const in vec4 color){return vec4(linearTosRGB(color.rgb),color.a);}vec3 sRGBToLinear(const in vec3 color){return pow(color,vec3(GAMMA));}vec4 sRGBToLinear(const in vec4 color){return vec4(sRGBToLinear(color.rgb),color.a);}
94250
94260
  #if defined(X3D_TONEMAP_ACES_NARKOWICZ)
94251
94261
  vec3 toneMapACES_Narkowicz(const in vec3 color){const float A=2.51;const float B=0.03;const float C=2.43;const float D=0.59;const float E=0.14;return clamp((color*(A*color+B))/(color*(C*color+D)+E),0.0,1.0);}
94252
94262
  #endif
@@ -94269,14 +94279,17 @@ return linearTosRGB(color);}`
94269
94279
  x_ite_Namespace .add ("ToneMapping1.glsl", "assets/shaders/webgl1/pbr/ToneMapping1.glsl", ToneMapping1_glsl_default_);
94270
94280
  /* harmony default export */ const ToneMapping1_glsl = (ToneMapping1_glsl_default_);
94271
94281
  ;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/pbr/BDRF2.glsl.js
94272
- const BDRF2_glsl_default_ = /* glsl */ `const float M_PI=3.1415926535897932384626433832795;vec3 F_Schlick(vec3 f0,vec3 f90,float VdotH){return f0+(f90-f0)*pow(clamp(1.0-VdotH,0.0,1.0),5.0);}float V_GGX(float NdotL,float NdotV,float alphaRoughness){float alphaRoughnessSq=alphaRoughness*alphaRoughness;float GGXV=NdotL*sqrt(NdotV*NdotV*(1.0-alphaRoughnessSq)+alphaRoughnessSq);float GGXL=NdotV*sqrt(NdotL*NdotL*(1.0-alphaRoughnessSq)+alphaRoughnessSq);float GGX=GGXV+GGXL;if(GGX>0.0){return 0.5/GGX;}return 0.0;}float D_GGX(float NdotH,float alphaRoughness){float alphaRoughnessSq=alphaRoughness*alphaRoughness;float f=(NdotH*NdotH)*(alphaRoughnessSq-1.0)+1.0;return alphaRoughnessSq/(M_PI*f*f);}vec3 BRDF_lambertian(vec3 f0,vec3 f90,vec3 diffuseColor,float specularWeight,float VdotH){return(1.0-specularWeight*F_Schlick(f0,f90,VdotH))*(diffuseColor/M_PI);}vec3 BRDF_specularGGX(vec3 f0,vec3 f90,float alphaRoughness,float specularWeight,float VdotH,float NdotL,float NdotV,float NdotH){vec3 F=F_Schlick(f0,f90,VdotH);float Vis=V_GGX(NdotL,NdotV,alphaRoughness);float D=D_GGX(NdotH,alphaRoughness);return specularWeight*F*Vis*D;}`
94282
+ const BDRF2_glsl_default_ = /* glsl */ `#if defined(X3D_LIGHTING)
94283
+ const float M_PI=3.1415926535897932384626433832795;vec3 F_Schlick(vec3 f0,vec3 f90,float VdotH){return f0+(f90-f0)*pow(clamp(1.0-VdotH,0.0,1.0),5.0);}float V_GGX(float NdotL,float NdotV,float alphaRoughness){float alphaRoughnessSq=alphaRoughness*alphaRoughness;float GGXV=NdotL*sqrt(NdotV*NdotV*(1.0-alphaRoughnessSq)+alphaRoughnessSq);float GGXL=NdotV*sqrt(NdotL*NdotL*(1.0-alphaRoughnessSq)+alphaRoughnessSq);float GGX=GGXV+GGXL;if(GGX>0.0){return 0.5/GGX;}return 0.0;}float D_GGX(float NdotH,float alphaRoughness){float alphaRoughnessSq=alphaRoughness*alphaRoughness;float f=(NdotH*NdotH)*(alphaRoughnessSq-1.0)+1.0;return alphaRoughnessSq/(M_PI*f*f);}vec3 BRDF_lambertian(vec3 f0,vec3 f90,vec3 diffuseColor,float specularWeight,float VdotH){return(1.0-specularWeight*F_Schlick(f0,f90,VdotH))*(diffuseColor/M_PI);}vec3 BRDF_specularGGX(vec3 f0,vec3 f90,float alphaRoughness,float specularWeight,float VdotH,float NdotL,float NdotV,float NdotH){vec3 F=F_Schlick(f0,f90,VdotH);float Vis=V_GGX(NdotL,NdotV,alphaRoughness);float D=D_GGX(NdotH,alphaRoughness);return specularWeight*F*Vis*D;}
94284
+ #endif
94285
+ `
94273
94286
  ;
94274
94287
 
94275
94288
  x_ite_Namespace .add ("BDRF2.glsl", "assets/shaders/webgl2/pbr/BDRF2.glsl", BDRF2_glsl_default_);
94276
94289
  /* harmony default export */ const BDRF2_glsl = (BDRF2_glsl_default_);
94277
94290
  ;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/pbr/IBL2.glsl.js
94278
94291
  const IBL2_glsl_default_ = /* glsl */ `#if defined(X3D_USE_IBL)
94279
- uniform x3d_EnvironmentLightSourceParameters x3d_EnvironmentLightSource;vec3 getDiffuseLight(const in vec3 n){return texture(x3d_EnvironmentLightSource.diffuseTexture,x3d_EnvironmentLightSource.rotation*n).rgb*x3d_EnvironmentLightSource.color*x3d_EnvironmentLightSource.intensity;}vec3 getSpecularLight(const in vec3 reflection,const in float lod){return textureLod(x3d_EnvironmentLightSource.specularTexture,x3d_EnvironmentLightSource.rotation*reflection,lod).rgb*x3d_EnvironmentLightSource.color*x3d_EnvironmentLightSource.intensity;}vec3 getIBLRadianceGGX(const in vec3 n,const in vec3 v,const in float roughness,const in vec3 F0,const in float specularWeight){float NdotV=clamp(dot(n,v),0.0,1.0);float lod=roughness*float(x3d_EnvironmentLightSource.specularTextureLevels-1);vec3 reflection=normalize(reflect(-v,n));vec2 brdfSamplePoint=clamp(vec2(NdotV,1.0-roughness),vec2(0.0),vec2(1.0));vec2 f_ab=texture(x3d_EnvironmentLightSource.GGXLUTTexture,brdfSamplePoint).rg;vec3 specularLight=getSpecularLight(reflection,lod);vec3 Fr=max(vec3(1.0-roughness),F0)-F0;vec3 k_S=F0+Fr*pow(1.0-NdotV,5.0);vec3 FssEss=k_S*f_ab.x+f_ab.y;return specularWeight*specularLight*FssEss;}vec3 getIBLRadianceLambertian(const in vec3 n,const in vec3 v,const in float roughness,const in vec3 diffuseColor,const in vec3 F0,const in float specularWeight){float NdotV=clamp(dot(n,v),0.0,1.0);vec2 brdfSamplePoint=clamp(vec2(NdotV,1.0-roughness),vec2(0.0),vec2(1.0));vec2 f_ab=texture(x3d_EnvironmentLightSource.GGXLUTTexture,brdfSamplePoint).rg;vec3 irradiance=getDiffuseLight(n);vec3 Fr=max(vec3(1.0-roughness),F0)-F0;vec3 k_S=F0+Fr*pow(1.0-NdotV,5.0);vec3 FssEss=specularWeight*k_S*f_ab.x+f_ab.y;float Ems=(1.0-(f_ab.x+f_ab.y));vec3 F_avg=specularWeight*(F0+(1.0-F0)/21.0);vec3 FmsEms=Ems*FssEss*F_avg/(1.0-F_avg*Ems);vec3 k_D=diffuseColor*(1.0-FssEss+FmsEms);return(FmsEms+k_D)*irradiance;}
94292
+ uniform x3d_EnvironmentLightSourceParameters x3d_EnvironmentLightSource;vec3 getDiffuseLight(const in vec3 n){vec3 textureColor=texture(x3d_EnvironmentLightSource.diffuseTexture,x3d_EnvironmentLightSource.rotation*n).rgb;if(!x3d_EnvironmentLightSource.diffuseTextureLinear)textureColor=sRGBToLinear(textureColor);return textureColor*x3d_EnvironmentLightSource.color*x3d_EnvironmentLightSource.intensity;}vec3 getSpecularLight(const in vec3 reflection,const in float lod){vec3 textureColor=textureLod(x3d_EnvironmentLightSource.specularTexture,x3d_EnvironmentLightSource.rotation*reflection,lod).rgb;if(!x3d_EnvironmentLightSource.specularTextureLinear)textureColor=sRGBToLinear(textureColor);return textureColor*x3d_EnvironmentLightSource.color*x3d_EnvironmentLightSource.intensity;}vec3 getIBLRadianceGGX(const in vec3 n,const in vec3 v,const in float roughness,const in vec3 F0,const in float specularWeight){float NdotV=clamp(dot(n,v),0.0,1.0);float lod=roughness*float(x3d_EnvironmentLightSource.specularTextureLevels-1);vec3 reflection=normalize(reflect(-v,n));vec2 brdfSamplePoint=clamp(vec2(NdotV,roughness),vec2(0.0),vec2(1.0));vec2 f_ab=texture(x3d_EnvironmentLightSource.GGXLUTTexture,brdfSamplePoint).rg;vec3 specularLight=getSpecularLight(reflection,lod);vec3 Fr=max(vec3(1.0-roughness),F0)-F0;vec3 k_S=F0+Fr*pow(1.0-NdotV,5.0);vec3 FssEss=k_S*f_ab.x+f_ab.y;return specularWeight*specularLight*FssEss;}vec3 getIBLRadianceLambertian(const in vec3 n,const in vec3 v,const in float roughness,const in vec3 diffuseColor,const in vec3 F0,const in float specularWeight){float NdotV=clamp(dot(n,v),0.0,1.0);vec2 brdfSamplePoint=clamp(vec2(NdotV,roughness),vec2(0.0),vec2(1.0));vec2 f_ab=texture(x3d_EnvironmentLightSource.GGXLUTTexture,brdfSamplePoint).rg;vec3 irradiance=getDiffuseLight(n);vec3 Fr=max(vec3(1.0-roughness),F0)-F0;vec3 k_S=F0+Fr*pow(1.0-NdotV,5.0);vec3 FssEss=specularWeight*k_S*f_ab.x+f_ab.y;float Ems=(1.0-(f_ab.x+f_ab.y));vec3 F_avg=specularWeight*(F0+(1.0-F0)/21.0);vec3 FmsEms=Ems*FssEss*F_avg/(1.0-F_avg*Ems);vec3 k_D=diffuseColor*(1.0-FssEss+FmsEms);return(FmsEms+k_D)*irradiance;}
94280
94293
  #endif
94281
94294
  `
94282
94295
  ;
@@ -94361,7 +94374,7 @@ return baseColor;}
94361
94374
  #if defined(X3D_METALLIC_ROUGHNESS_TEXTURE)
94362
94375
  uniform x3d_MetallicRoughnessTextureParameters x3d_MetallicRoughnessTexture;
94363
94376
  #endif
94364
- MaterialInfo getMetallicRoughnessInfo(MaterialInfo info){info.metallic=x3d_Material.metallic;info.perceptualRoughness=x3d_Material.roughness;
94377
+ MaterialInfo getMetallicRoughnessInfo(in MaterialInfo info){info.metallic=x3d_Material.metallic;info.perceptualRoughness=x3d_Material.roughness;
94365
94378
  #if defined(X3D_METALLIC_ROUGHNESS_TEXTURE)
94366
94379
  vec3 texCoord=getTexCoord(x3d_MetallicRoughnessTexture.textureTransformMapping,x3d_MetallicRoughnessTexture.textureCoordinateMapping);
94367
94380
  #if defined(X3D_METALLIC_ROUGHNESS_TEXTURE_FLIP_Y)
@@ -94400,7 +94413,7 @@ emissiveColor*=textureColor;
94400
94413
  emissiveColor*=sRGBToLinear(textureColor);
94401
94414
  #endif
94402
94415
  #endif
94403
- return emissiveColor.rgb;}
94416
+ return emissiveColor;}
94404
94417
  #if defined(X3D_OCCLUSION_TEXTURE)
94405
94418
  uniform x3d_OcclusionTextureParameters x3d_OcclusionTexture;
94406
94419
  #endif
@@ -94426,7 +94439,7 @@ return 1.0;
94426
94439
  x_ite_Namespace .add ("MaterialInfo2.glsl", "assets/shaders/webgl2/pbr/MaterialInfo2.glsl", MaterialInfo2_glsl_default_);
94427
94440
  /* harmony default export */ const MaterialInfo2_glsl = (MaterialInfo2_glsl_default_);
94428
94441
  ;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/pbr/ToneMapping2.glsl.js
94429
- const ToneMapping2_glsl_default_ = /* glsl */ `const float exposure=1.0;const float GAMMA=2.2;const float INV_GAMMA=1.0/GAMMA;vec3 linearTosRGB(const in vec3 color){return pow(color,vec3(INV_GAMMA));}vec4 linearTosRGB(const in vec4 color){return vec4(linearTosRGB(color.rgb),color.a);}vec3 sRGBToLinear(const in vec3 color){return vec3(pow(color,vec3(GAMMA)));}vec4 sRGBToLinear(const in vec4 color){return vec4(sRGBToLinear(color.rgb),color.a);}
94442
+ const ToneMapping2_glsl_default_ = /* glsl */ `const float exposure=1.0;const float GAMMA=2.2;const float INV_GAMMA=1.0/GAMMA;vec3 linearTosRGB(const in vec3 color){return pow(color,vec3(INV_GAMMA));}vec4 linearTosRGB(const in vec4 color){return vec4(linearTosRGB(color.rgb),color.a);}vec3 sRGBToLinear(const in vec3 color){return pow(color,vec3(GAMMA));}vec4 sRGBToLinear(const in vec4 color){return vec4(sRGBToLinear(color.rgb),color.a);}
94430
94443
  #if defined(X3D_TONEMAP_ACES_NARKOWICZ)
94431
94444
  vec3 toneMapACES_Narkowicz(const in vec3 color){const float A=2.51;const float B=0.03;const float C=2.43;const float D=0.59;const float E=0.14;return clamp((color*(A*color+B))/(color*(C*color+D)+E),0.0,1.0);}
94432
94445
  #endif
@@ -94771,7 +94784,7 @@ const ShaderCompiler_default_ = ShaderCompiler;
94771
94784
  x_ite_Namespace .add ("ShaderCompiler", "x_ite/Browser/Shaders/ShaderCompiler", ShaderCompiler_default_);
94772
94785
  /* harmony default export */ const Shaders_ShaderCompiler = (ShaderCompiler_default_);
94773
94786
  ;// CONCATENATED MODULE: ./src/x_ite/Components/Shaders/ShaderPart.js
94774
- /* provided dependency */ var ShaderPart_$ = __webpack_require__(978);
94787
+ /* provided dependency */ var ShaderPart_$ = __webpack_require__(718);
94775
94788
  /*******************************************************************************
94776
94789
  *
94777
94790
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -95428,7 +95441,7 @@ const X3DAppearanceNode_default_ = X3DAppearanceNode;
95428
95441
  x_ite_Namespace .add ("X3DAppearanceNode", "x_ite/Components/Shape/X3DAppearanceNode", X3DAppearanceNode_default_);
95429
95442
  /* harmony default export */ const Shape_X3DAppearanceNode = (X3DAppearanceNode_default_);
95430
95443
  ;// CONCATENATED MODULE: ./src/x_ite/Components/Shape/Appearance.js
95431
- /* provided dependency */ var Appearance_$ = __webpack_require__(978);
95444
+ /* provided dependency */ var Appearance_$ = __webpack_require__(718);
95432
95445
  /*******************************************************************************
95433
95446
  *
95434
95447
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -96352,7 +96365,7 @@ Object .assign (Object .setPrototypeOf (X3DMaterialNode .prototype, Shape_X3DApp
96352
96365
 
96353
96366
  key += shapeNode .getAlphaMode ();
96354
96367
  key += this .getMaterialKey ();
96355
- key += renderObject .getLogarithmicDepthBuffer () ? 1 : 0;
96368
+ key += renderObject .getRenderBits () .toString (32); // 5 Bits
96356
96369
  key += shadows ? 1 : 0;
96357
96370
  key += fogNode ?.getFogType () ?? 0;
96358
96371
  key += shapeNode .getShapeKey ();
@@ -96368,7 +96381,7 @@ Object .assign (Object .setPrototypeOf (X3DMaterialNode .prototype, Shape_X3DApp
96368
96381
  }
96369
96382
  else
96370
96383
  {
96371
- // Rubberband, X3DBackgroundNode, ParticleSystem
96384
+ // Rubberband, X3DBackgroundNode
96372
96385
 
96373
96386
  const { alphaMode, textureNode, objectsKeys } = geometryContext;
96374
96387
 
@@ -96403,7 +96416,7 @@ Object .assign (Object .setPrototypeOf (X3DMaterialNode .prototype, Shape_X3DApp
96403
96416
  {
96404
96417
  const { renderObject, fogNode, shapeNode, appearanceNode, humanoidNode, objectsKeys, textureNode } = renderContext;
96405
96418
 
96406
- if (renderObject .getLogarithmicDepthBuffer ())
96419
+ if (renderObject .getRenderBits () .get (0))
96407
96420
  options .push ("X3D_LOGARITHMIC_DEPTH_BUFFER");
96408
96421
 
96409
96422
  switch (shapeNode .getAlphaMode ())
@@ -96422,7 +96435,7 @@ Object .assign (Object .setPrototypeOf (X3DMaterialNode .prototype, Shape_X3DApp
96422
96435
  {
96423
96436
  options .push ("X3D_ALPHA_MODE_BLEND");
96424
96437
 
96425
- if (browser .getBrowserOption ("OrderIndependentTransparency"))
96438
+ if (renderObject .getRenderBits () .get (1))
96426
96439
  options .push ("X3D_ORDER_INDEPENDENT_TRANSPARENCY");
96427
96440
 
96428
96441
  break;
@@ -97952,6 +97965,10 @@ Object .assign (Object .setPrototypeOf (X3DShapeNode .prototype, Core_X3DChildNo
97952
97965
  {
97953
97966
  return this .alphaMode;
97954
97967
  },
97968
+ setAlphaMode (value)
97969
+ {
97970
+ this .alphaMode = value;
97971
+ },
97955
97972
  getAppearance ()
97956
97973
  {
97957
97974
  return this .appearanceNode;
@@ -98003,6 +98020,8 @@ Object .assign (Object .setPrototypeOf (X3DShapeNode .prototype, Core_X3DChildNo
98003
98020
  },
98004
98021
  set_transparent__ ()
98005
98022
  {
98023
+ // This function is overloaded in ParticleSystem!
98024
+
98006
98025
  const alphaMode = this .appearanceNode .getAlphaMode ();
98007
98026
 
98008
98027
  if (alphaMode === Shape_AlphaMode .AUTO)
@@ -98829,7 +98848,7 @@ const Components_Shape_default_ = {
98829
98848
  x_ite_Namespace .add ("Shape", "x_ite/Components/Shape", Components_Shape_default_);
98830
98849
  /* harmony default export */ const Components_Shape = (Components_Shape_default_);
98831
98850
  ;// CONCATENATED MODULE: ./src/x_ite/Components/Sound/X3DSoundProcessingNode.js
98832
- /* provided dependency */ var X3DSoundProcessingNode_$ = __webpack_require__(978);
98851
+ /* provided dependency */ var X3DSoundProcessingNode_$ = __webpack_require__(718);
98833
98852
  /*******************************************************************************
98834
98853
  *
98835
98854
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -99469,7 +99488,7 @@ const X3DSoundSourceNode_default_ = X3DSoundSourceNode;
99469
99488
  x_ite_Namespace .add ("X3DSoundSourceNode", "x_ite/Components/Sound/X3DSoundSourceNode", X3DSoundSourceNode_default_);
99470
99489
  /* harmony default export */ const Sound_X3DSoundSourceNode = (X3DSoundSourceNode_default_);
99471
99490
  ;// CONCATENATED MODULE: ./src/x_ite/Components/Sound/AudioClip.js
99472
- /* provided dependency */ var AudioClip_$ = __webpack_require__(978);
99491
+ /* provided dependency */ var AudioClip_$ = __webpack_require__(718);
99473
99492
  /*******************************************************************************
99474
99493
  *
99475
99494
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -99771,7 +99790,7 @@ const X3DSoundNode_default_ = X3DSoundNode;
99771
99790
  x_ite_Namespace .add ("X3DSoundNode", "x_ite/Components/Sound/X3DSoundNode", X3DSoundNode_default_);
99772
99791
  /* harmony default export */ const Sound_X3DSoundNode = (X3DSoundNode_default_);
99773
99792
  ;// CONCATENATED MODULE: ./src/x_ite/Components/Sound/X3DSoundDestinationNode.js
99774
- /* provided dependency */ var X3DSoundDestinationNode_$ = __webpack_require__(978);
99793
+ /* provided dependency */ var X3DSoundDestinationNode_$ = __webpack_require__(718);
99775
99794
  /*******************************************************************************
99776
99795
  *
99777
99796
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -101421,7 +101440,7 @@ const ListenerPointSource_default_ = ListenerPointSource;
101421
101440
  x_ite_Namespace .add ("ListenerPointSource", "x_ite/Components/Sound/ListenerPointSource", ListenerPointSource_default_);
101422
101441
  /* harmony default export */ const Sound_ListenerPointSource = (ListenerPointSource_default_);
101423
101442
  ;// CONCATENATED MODULE: ./src/x_ite/Components/Sound/MicrophoneSource.js
101424
- /* provided dependency */ var MicrophoneSource_$ = __webpack_require__(978);
101443
+ /* provided dependency */ var MicrophoneSource_$ = __webpack_require__(718);
101425
101444
  /*******************************************************************************
101426
101445
  *
101427
101446
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -103090,8 +103109,8 @@ const GifMedia_default_ = GifMedia;
103090
103109
  x_ite_Namespace .add ("GifMedia", "x_ite/Browser/Texturing/GifMedia", GifMedia_default_);
103091
103110
  /* harmony default export */ const Texturing_GifMedia = (GifMedia_default_);
103092
103111
  ;// CONCATENATED MODULE: ./src/x_ite/Components/Texturing/MovieTexture.js
103093
- /* provided dependency */ var MovieTexture_$ = __webpack_require__(978);
103094
- /* provided dependency */ var SuperGif = __webpack_require__(11);
103112
+ /* provided dependency */ var MovieTexture_$ = __webpack_require__(718);
103113
+ /* provided dependency */ var SuperGif = __webpack_require__(630);
103095
103114
  /*******************************************************************************
103096
103115
  *
103097
103116
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -104269,7 +104288,7 @@ const MultiTextureTransform_default_ = MultiTextureTransform;
104269
104288
  x_ite_Namespace .add ("MultiTextureTransform", "x_ite/Components/Texturing/MultiTextureTransform", MultiTextureTransform_default_);
104270
104289
  /* harmony default export */ const Texturing_MultiTextureTransform = (MultiTextureTransform_default_);
104271
104290
  ;// CONCATENATED MODULE: ./src/x_ite/Components/Texturing/PixelTexture.js
104272
- /* provided dependency */ var PixelTexture_$ = __webpack_require__(978);
104291
+ /* provided dependency */ var PixelTexture_$ = __webpack_require__(718);
104273
104292
  /*******************************************************************************
104274
104293
  *
104275
104294
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -105695,63 +105714,6 @@ x_ite_Namespace .add ("Time", "x_ite/Components/Time", Time_default_);
105695
105714
 
105696
105715
 
105697
105716
 
105698
- const extensions = [
105699
- "ANGLE_instanced_arrays",
105700
- "EXT_blend_minmax",
105701
- "EXT_frag_depth",
105702
- "EXT_shader_texture_lod",
105703
- "EXT_texture_filter_anisotropic",
105704
- "OES_element_index_uint",
105705
- "OES_standard_derivatives",
105706
- "OES_texture_float",
105707
- "OES_texture_float_linear",
105708
- "OES_texture_half_float",
105709
- "OES_texture_half_float_linear",
105710
- "OES_vertex_array_object",
105711
- "WEBGL_compressed_texture_s3tc",
105712
- //"WEBGL_debug_renderer_info",
105713
- "WEBGL_debug_shaders",
105714
- "WEBGL_depth_texture",
105715
- "WEBGL_draw_buffers",
105716
- "WEBGL_lose_context",
105717
-
105718
- "EXT_color_buffer_float",
105719
- "EXT_color_buffer_half_float",
105720
- "EXT_disjoint_timer_query",
105721
- "EXT_disjoint_timer_query_webgl2",
105722
- "EXT_sRGB",
105723
- "WEBGL_color_buffer_float",
105724
- "WEBGL_compressed_texture_astc",
105725
- "WEBGL_compressed_texture_atc",
105726
- "WEBGL_compressed_texture_etc",
105727
- "WEBGL_compressed_texture_etc1",
105728
- "WEBGL_compressed_texture_pvrtc",
105729
- "WEBGL_compressed_texture_s3tc",
105730
- "WEBGL_compressed_texture_s3tc_srgb",
105731
-
105732
- "EXT_float_blend",
105733
- "OES_fbo_render_mipmap",
105734
- "WEBGL_get_buffer_sub_data_async",
105735
- "WEBGL_multiview",
105736
- "WEBGL_security_sensitive_resources",
105737
- "WEBGL_shared_resources",
105738
-
105739
- "EXT_clip_cull_distance",
105740
- "WEBGL_debug",
105741
- "WEBGL_dynamic_texture",
105742
- "WEBGL_subarray_uploads",
105743
- "WEBGL_texture_multisample",
105744
- "WEBGL_texture_source_iframe",
105745
- "WEBGL_video_texture",
105746
-
105747
- "EXT_texture_storage",
105748
- "OES_depth24",
105749
- "WEBGL_debug_shader_precision",
105750
- "WEBGL_draw_elements_no_range_check",
105751
- "WEBGL_subscribe_uniform",
105752
- "WEBGL_texture_from_depth_video",
105753
- ];
105754
-
105755
105717
  const Context =
105756
105718
  {
105757
105719
  create (canvas, version, preserveDrawingBuffer, mobile)
@@ -105793,7 +105755,7 @@ const Context =
105793
105755
 
105794
105756
  // Load extensions.
105795
105757
 
105796
- for (const extension of extensions)
105758
+ for (const extension of gl .getSupportedExtensions ())
105797
105759
  gl .getExtension (extension);
105798
105760
 
105799
105761
  // Feature detection:
@@ -105823,9 +105785,11 @@ const Context =
105823
105785
  {
105824
105786
  const
105825
105787
  color_buffer_float = gl .getExtension ("WEBGL_color_buffer_float"),
105826
- draw_buffers = gl .getExtension ("WEBGL_draw_buffers");
105788
+ draw_buffers = gl .getExtension ("WEBGL_draw_buffers"),
105789
+ sRGB = gl .getExtension ("EXT_sRGB");
105827
105790
 
105828
105791
  gl .RGBA32F = color_buffer_float .RGBA32F_EXT;
105792
+ gl .SRGB8_ALPHA8 = sRGB .SRGB_ALPHA_EXT;
105829
105793
  gl .MAX_COLOR_ATTACHMENTS = draw_buffers .MAX_COLOR_ATTACHMENTS_WEBGL;
105830
105794
  gl .drawBuffers = draw_buffers .drawBuffersWEBGL .bind (draw_buffers);
105831
105795
 
@@ -106425,7 +106389,7 @@ const gettext_default_ = gettext;
106425
106389
  x_ite_Namespace .add ("gettext", "locale/gettext", gettext_default_);
106426
106390
  /* harmony default export */ const locale_gettext = (gettext_default_);
106427
106391
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/BrowserTimings.js
106428
- /* provided dependency */ var BrowserTimings_$ = __webpack_require__(978);
106392
+ /* provided dependency */ var BrowserTimings_$ = __webpack_require__(718);
106429
106393
  /*******************************************************************************
106430
106394
  *
106431
106395
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -106855,7 +106819,7 @@ const TextureQuality_default_ = TextureQuality;
106855
106819
  x_ite_Namespace .add ("TextureQuality", "x_ite/Browser/Core/TextureQuality", TextureQuality_default_);
106856
106820
  /* harmony default export */ const Core_TextureQuality = (TextureQuality_default_);
106857
106821
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/BrowserOptions.js
106858
- /* provided dependency */ var BrowserOptions_$ = __webpack_require__(978);
106822
+ /* provided dependency */ var BrowserOptions_$ = __webpack_require__(718);
106859
106823
  /*******************************************************************************
106860
106824
  *
106861
106825
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -107195,10 +107159,7 @@ Object .assign (Object .setPrototypeOf (BrowserOptions .prototype, Base_X3DBaseN
107195
107159
  },
107196
107160
  set_orderIndependentTransparency__ ()
107197
107161
  {
107198
- const browser = this .getBrowser ();
107199
-
107200
- browser .getShaders () .clear ();
107201
- browser .reshape ();
107162
+ this .getBrowser () .reshape ();
107202
107163
  },
107203
107164
  set_timings__ (timings)
107204
107165
  {
@@ -107448,7 +107409,7 @@ const RenderingProperties_default_ = RenderingProperties;
107448
107409
  x_ite_Namespace .add ("RenderingProperties", "x_ite/Browser/Core/RenderingProperties", RenderingProperties_default_);
107449
107410
  /* harmony default export */ const Core_RenderingProperties = (RenderingProperties_default_);
107450
107411
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/Notification.js
107451
- /* provided dependency */ var Notification_$ = __webpack_require__(978);
107412
+ /* provided dependency */ var Notification_$ = __webpack_require__(718);
107452
107413
  /*******************************************************************************
107453
107414
  *
107454
107415
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -107571,8 +107532,8 @@ const Notification_default_ = Notification;
107571
107532
  x_ite_Namespace .add ("Notification", "x_ite/Browser/Core/Notification", Notification_default_);
107572
107533
  /* harmony default export */ const Core_Notification = (Notification_default_);
107573
107534
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/ContextMenu.js
107574
- /* provided dependency */ var jquery_fullscreen = __webpack_require__(1);
107575
- /* provided dependency */ var ContextMenu_$ = __webpack_require__(978);
107535
+ /* provided dependency */ var jquery_fullscreen = __webpack_require__(699);
107536
+ /* provided dependency */ var ContextMenu_$ = __webpack_require__(718);
107576
107537
  /*******************************************************************************
107577
107538
  *
107578
107539
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -110324,7 +110285,7 @@ const DataStorage_default_ = DataStorage;
110324
110285
  x_ite_Namespace .add ("DataStorage", "standard/Utility/DataStorage", DataStorage_default_);
110325
110286
  /* harmony default export */ const Utility_DataStorage = (DataStorage_default_);
110326
110287
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/X3DCoreContext.js
110327
- /* provided dependency */ var X3DCoreContext_$ = __webpack_require__(978);
110288
+ /* provided dependency */ var X3DCoreContext_$ = __webpack_require__(718);
110328
110289
  /*******************************************************************************
110329
110290
  *
110330
110291
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -112132,7 +112093,9 @@ Object .assign (X3DLightingContext .prototype,
112132
112093
  getGGXLUTTexture ()
112133
112094
  {
112134
112095
  this [_GGXLUTTexture] = new Texturing_ImageTexture (this .getPrivateScene ());
112135
- this [_GGXLUTTexture] ._url = [Networking_URLs .getLibraryURL ("lut_ggx.png")];
112096
+ this [_GGXLUTTexture] ._url = [Networking_URLs .getLibraryURL ("lut_ggx.png")];
112097
+ this [_GGXLUTTexture] ._repeatS = false;
112098
+ this [_GGXLUTTexture] ._repeatT = false;
112136
112099
  this [_GGXLUTTexture] .setup ();
112137
112100
 
112138
112101
  this .getGGXLUTTexture = function () { return this [_GGXLUTTexture]; };
@@ -112387,8 +112350,8 @@ const X3DViewer_default_ = X3DViewer;
112387
112350
  x_ite_Namespace .add ("X3DViewer", "x_ite/Browser/Navigation/X3DViewer", X3DViewer_default_);
112388
112351
  /* harmony default export */ const Navigation_X3DViewer = (X3DViewer_default_);
112389
112352
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Navigation/ExamineViewer.js
112390
- /* provided dependency */ var jquery_mousewheel = __webpack_require__(436);
112391
- /* provided dependency */ var ExamineViewer_$ = __webpack_require__(978);
112353
+ /* provided dependency */ var jquery_mousewheel = __webpack_require__(801);
112354
+ /* provided dependency */ var ExamineViewer_$ = __webpack_require__(718);
112392
112355
  /*******************************************************************************
112393
112356
  *
112394
112357
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -113260,8 +113223,8 @@ const ExamineViewer_default_ = ExamineViewer;
113260
113223
  x_ite_Namespace .add ("ExamineViewer", "x_ite/Browser/Navigation/ExamineViewer", ExamineViewer_default_);
113261
113224
  /* harmony default export */ const Navigation_ExamineViewer = (ExamineViewer_default_);
113262
113225
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Navigation/X3DFlyViewer.js
113263
- /* provided dependency */ var X3DFlyViewer_jquery_mousewheel = __webpack_require__(436);
113264
- /* provided dependency */ var X3DFlyViewer_$ = __webpack_require__(978);
113226
+ /* provided dependency */ var X3DFlyViewer_jquery_mousewheel = __webpack_require__(801);
113227
+ /* provided dependency */ var X3DFlyViewer_$ = __webpack_require__(718);
113265
113228
  /*******************************************************************************
113266
113229
  *
113267
113230
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -114270,8 +114233,8 @@ const FlyViewer_default_ = FlyViewer;
114270
114233
  x_ite_Namespace .add ("FlyViewer", "x_ite/Browser/Navigation/FlyViewer", FlyViewer_default_);
114271
114234
  /* harmony default export */ const Navigation_FlyViewer = (FlyViewer_default_);
114272
114235
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Navigation/PlaneViewer.js
114273
- /* provided dependency */ var PlaneViewer_jquery_mousewheel = __webpack_require__(436);
114274
- /* provided dependency */ var PlaneViewer_$ = __webpack_require__(978);
114236
+ /* provided dependency */ var PlaneViewer_jquery_mousewheel = __webpack_require__(801);
114237
+ /* provided dependency */ var PlaneViewer_$ = __webpack_require__(718);
114275
114238
  /*******************************************************************************
114276
114239
  *
114277
114240
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -114602,8 +114565,8 @@ const NoneViewer_default_ = NoneViewer;
114602
114565
  x_ite_Namespace .add ("NoneViewer", "x_ite/Browser/Navigation/NoneViewer", NoneViewer_default_);
114603
114566
  /* harmony default export */ const Navigation_NoneViewer = (NoneViewer_default_);
114604
114567
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Navigation/LookAtViewer.js
114605
- /* provided dependency */ var LookAtViewer_jquery_mousewheel = __webpack_require__(436);
114606
- /* provided dependency */ var LookAtViewer_$ = __webpack_require__(978);
114568
+ /* provided dependency */ var LookAtViewer_jquery_mousewheel = __webpack_require__(801);
114569
+ /* provided dependency */ var LookAtViewer_$ = __webpack_require__(718);
114607
114570
  /*******************************************************************************
114608
114571
  *
114609
114572
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -115742,8 +115705,8 @@ const X3DPickingContext_default_ = X3DPickingContext;
115742
115705
  x_ite_Namespace .add ("X3DPickingContext", "x_ite/Browser/Picking/X3DPickingContext", X3DPickingContext_default_);
115743
115706
  /* harmony default export */ const Picking_X3DPickingContext = (X3DPickingContext_default_);
115744
115707
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/PointingDeviceSensor/PointingDevice.js
115745
- /* provided dependency */ var PointingDevice_jquery_mousewheel = __webpack_require__(436);
115746
- /* provided dependency */ var PointingDevice_$ = __webpack_require__(978);
115708
+ /* provided dependency */ var PointingDevice_jquery_mousewheel = __webpack_require__(801);
115709
+ /* provided dependency */ var PointingDevice_$ = __webpack_require__(718);
115747
115710
  /*******************************************************************************
115748
115711
  *
115749
115712
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -116662,7 +116625,7 @@ function MultiSampleFrameBuffer (browser, width, height, samples, oit)
116662
116625
  const gl = browser .getContext ();
116663
116626
 
116664
116627
  if (gl .getVersion () === 1 || width === 0 || height === 0)
116665
- return Fallback;
116628
+ return new Fallback (browser, width, height, samples);
116666
116629
 
116667
116630
  this .browser = browser;
116668
116631
  this .context = gl;
@@ -116964,17 +116927,41 @@ Object .assign (MultiSampleFrameBuffer .prototype,
116964
116927
  },
116965
116928
  });
116966
116929
 
116967
- const Fallback = {
116968
- getWidth: Function .prototype,
116969
- getHeight: Function .prototype,
116970
- getSamples: Function .prototype,
116971
- getOIT: Function .prototype,
116972
- bind: Function .prototype,
116973
- clear: Function .prototype,
116930
+ function Fallback (browser, width, height, samples)
116931
+ {
116932
+ const gl = browser .getContext ();
116933
+
116934
+ this .browser = browser;
116935
+ this .context = gl;
116936
+ this .width = width;
116937
+ this .height = height;
116938
+ this .samples = samples;
116939
+ }
116940
+
116941
+ Object .assign (Fallback .prototype,
116942
+ {
116943
+ getWidth () { return this .width; },
116944
+ getHeight () { return this .height; },
116945
+ getSamples () { return this .samples; },
116946
+ getOIT () { return false; },
116947
+ bind ()
116948
+ {
116949
+ const { context: gl } = this;
116950
+
116951
+ gl .bindFramebuffer (gl .FRAMEBUFFER, null);
116952
+ },
116953
+ clear ()
116954
+ {
116955
+ const { context: gl } = this;
116956
+
116957
+ gl .clearColor (0, 0, 0, 1);
116958
+ gl .clear (gl .COLOR_BUFFER_BIT);
116959
+ gl .blendFuncSeparate (gl .ONE, gl .ONE, gl .ZERO, gl .ONE_MINUS_SRC_ALPHA);
116960
+ },
116974
116961
  blit: Function .prototype,
116975
116962
  compose: Function .prototype,
116976
116963
  dispose: Function .prototype,
116977
- };
116964
+ });
116978
116965
 
116979
116966
  const MultiSampleFrameBuffer_default_ = MultiSampleFrameBuffer;
116980
116967
  ;
@@ -116982,7 +116969,7 @@ const MultiSampleFrameBuffer_default_ = MultiSampleFrameBuffer;
116982
116969
  x_ite_Namespace .add ("MultiSampleFrameBuffer", "x_ite/Rendering/MultiSampleFrameBuffer", MultiSampleFrameBuffer_default_);
116983
116970
  /* harmony default export */ const Rendering_MultiSampleFrameBuffer = (MultiSampleFrameBuffer_default_);
116984
116971
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Rendering/X3DRenderingContext.js
116985
- /* provided dependency */ var X3DRenderingContext_$ = __webpack_require__(978);
116972
+ /* provided dependency */ var X3DRenderingContext_$ = __webpack_require__(718);
116986
116973
  /*******************************************************************************
116987
116974
  *
116988
116975
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -117885,7 +117872,7 @@ const X3DSoundContext_default_ = X3DSoundContext;
117885
117872
  x_ite_Namespace .add ("X3DSoundContext", "x_ite/Browser/Sound/X3DSoundContext", X3DSoundContext_default_);
117886
117873
  /* harmony default export */ const Sound_X3DSoundContext = (X3DSoundContext_default_);
117887
117874
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/Texturing/KTXDecoder.js
117888
- /* provided dependency */ var KTXDecoder_$ = __webpack_require__(978);
117875
+ /* provided dependency */ var KTXDecoder_$ = __webpack_require__(718);
117889
117876
  const KTXDecoder_default_ = class KTXDecoder
117890
117877
  {
117891
117878
  constructor (gl, externalKtxlib, scriptDir)
@@ -117957,6 +117944,7 @@ const KTXDecoder_default_ = class KTXDecoder
117957
117944
  if (!texture)
117958
117945
  throw new Error ("Could not load KTX data");
117959
117946
 
117947
+ // https://stackoverflow.com/a/25640078/1818915
117960
117948
  texture .levels = 1 + Math .floor (Math .log2 (Math .max (ktxTexture .baseWidth, ktxTexture .baseHeight)));
117961
117949
  texture .baseWidth = ktxTexture .baseWidth;
117962
117950
  texture .baseHeight = ktxTexture .baseHeight;
@@ -118039,12 +118027,9 @@ const
118039
118027
  _texture2DUnitIndex = Symbol (),
118040
118028
  _texture3DUnitIndex = Symbol (),
118041
118029
  _textureCubeUnitIndex = Symbol (),
118042
- _defaultTexture2DBlack = Symbol (),
118043
- _defaultTexture2DWhite = Symbol (),
118044
- _defaultTexture3DBlack = Symbol (),
118045
- _defaultTexture3DWhite = Symbol (),
118046
- _defaultTextureCubeBlack = Symbol (),
118047
- _defaultTextureCubeWhite = Symbol (),
118030
+ _defaultTexture2D = Symbol (),
118031
+ _defaultTexture3D = Symbol (),
118032
+ _defaultTextureCube = Symbol (),
118048
118033
  _defaultTextureProperties = Symbol (),
118049
118034
  _defaultTextureTransform = Symbol (),
118050
118035
  _defaultTextureCoordinate = Symbol (),
@@ -118081,46 +118066,37 @@ Object .assign (X3DTexturingContext .prototype,
118081
118066
 
118082
118067
  // Default Texture 2D Unit
118083
118068
 
118084
- const defaultData = [new Uint8Array (4), new Uint8Array ([ 255, 255, 255, 255 ])];
118069
+ const defaultData = new Uint8Array ([ 255, 255, 255, 255 ]);
118085
118070
 
118086
- for (const [i, _defaultTexture2D] of [_defaultTexture2DBlack, _defaultTexture2DWhite] .entries ())
118087
- {
118088
- this [_defaultTexture2D] = gl .createTexture ();
118071
+ this [_defaultTexture2D] = gl .createTexture ();
118089
118072
 
118090
- gl .activeTexture (gl .TEXTURE0 + this [_texture2DUnits] [0]);
118091
- gl .bindTexture (gl .TEXTURE_2D, this [_defaultTexture2D]);
118092
- gl .texImage2D (gl .TEXTURE_2D, 0, gl .RGBA, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData [i]);
118093
- }
118073
+ gl .activeTexture (gl .TEXTURE0 + this [_texture2DUnits] [0]);
118074
+ gl .bindTexture (gl .TEXTURE_2D, this [_defaultTexture2D]);
118075
+ gl .texImage2D (gl .TEXTURE_2D, 0, gl .RGBA, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData);
118094
118076
 
118095
118077
  // Default Texture 3D Unit
118096
118078
 
118097
118079
  if (gl .getVersion () >= 2)
118098
118080
  {
118099
- for (const [i, _defaultTexture3D] of [_defaultTexture3DBlack, _defaultTexture3DWhite] .entries ())
118100
- {
118101
- this [_defaultTexture3D] = gl .createTexture ();
118081
+ this [_defaultTexture3D] = gl .createTexture ();
118102
118082
 
118103
- gl .activeTexture (gl .TEXTURE0 + this [_texture3DUnits] [0]);
118104
- gl .bindTexture (gl .TEXTURE_3D, this [_defaultTexture3D]);
118105
- gl .texImage3D (gl .TEXTURE_3D, 0, gl .RGBA, 1, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData [i]);
118106
- }
118083
+ gl .activeTexture (gl .TEXTURE0 + this [_texture3DUnits] [0]);
118084
+ gl .bindTexture (gl .TEXTURE_3D, this [_defaultTexture3D]);
118085
+ gl .texImage3D (gl .TEXTURE_3D, 0, gl .RGBA, 1, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData);
118107
118086
  }
118108
118087
 
118109
118088
  // Default Texture Cube Unit
118110
118089
 
118111
- for (const [i, _defaultTextureCube] of [_defaultTextureCubeBlack, _defaultTextureCubeWhite] .entries ())
118112
- {
118113
- this [_defaultTextureCube] = gl .createTexture ();
118090
+ this [_defaultTextureCube] = gl .createTexture ();
118114
118091
 
118115
- gl .activeTexture (gl .TEXTURE0 + this [_textureCubeUnits] [0]);
118116
- gl .bindTexture (gl .TEXTURE_CUBE_MAP, this [_defaultTextureCube]);
118117
- gl .texImage2D (gl .TEXTURE_CUBE_MAP_POSITIVE_Z, 0, gl .RGBA, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData [i]);
118118
- gl .texImage2D (gl .TEXTURE_CUBE_MAP_NEGATIVE_Z, 0, gl .RGBA, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData [i]);
118119
- gl .texImage2D (gl .TEXTURE_CUBE_MAP_NEGATIVE_X, 0, gl .RGBA, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData [i]);
118120
- gl .texImage2D (gl .TEXTURE_CUBE_MAP_POSITIVE_X, 0, gl .RGBA, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData [i]);
118121
- gl .texImage2D (gl .TEXTURE_CUBE_MAP_POSITIVE_Y, 0, gl .RGBA, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData [i]);
118122
- gl .texImage2D (gl .TEXTURE_CUBE_MAP_NEGATIVE_Y, 0, gl .RGBA, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData [i]);
118123
- }
118092
+ gl .activeTexture (gl .TEXTURE0 + this [_textureCubeUnits] [0]);
118093
+ gl .bindTexture (gl .TEXTURE_CUBE_MAP, this [_defaultTextureCube]);
118094
+ gl .texImage2D (gl .TEXTURE_CUBE_MAP_POSITIVE_Z, 0, gl .RGBA, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData);
118095
+ gl .texImage2D (gl .TEXTURE_CUBE_MAP_NEGATIVE_Z, 0, gl .RGBA, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData);
118096
+ gl .texImage2D (gl .TEXTURE_CUBE_MAP_NEGATIVE_X, 0, gl .RGBA, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData);
118097
+ gl .texImage2D (gl .TEXTURE_CUBE_MAP_POSITIVE_X, 0, gl .RGBA, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData);
118098
+ gl .texImage2D (gl .TEXTURE_CUBE_MAP_POSITIVE_Y, 0, gl .RGBA, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData);
118099
+ gl .texImage2D (gl .TEXTURE_CUBE_MAP_NEGATIVE_Y, 0, gl .RGBA, 1, 1, 0, gl .RGBA, gl .UNSIGNED_BYTE, defaultData);
118124
118100
 
118125
118101
  // Init texture units.
118126
118102
 
@@ -118270,37 +118246,24 @@ Object .assign (X3DTexturingContext .prototype,
118270
118246
  {
118271
118247
  return NaN;
118272
118248
  },
118273
- getDefaultTexture2DBlack ()
118249
+ getDefaultTexture2D ()
118274
118250
  {
118275
- return this [_defaultTexture2DBlack];
118251
+ return this [_defaultTexture2D];
118276
118252
  },
118277
- getDefaultTexture2DWhite ()
118253
+ getDefaultTexture3D ()
118278
118254
  {
118279
- return this [_defaultTexture2DWhite];
118255
+ return this [_defaultTexture3D];
118280
118256
  },
118281
- getDefaultTexture3DBlack ()
118257
+ getDefaultTextureCube ()
118282
118258
  {
118283
- return this [_defaultTexture3DBlack];
118284
- },
118285
- getDefaultTexture3DWhite ()
118286
- {
118287
- return this [_defaultTexture3DWhite];
118288
- },
118289
- getDefaultTextureCubeBlack ()
118290
- {
118291
- return this [_defaultTextureCubeBlack];
118292
- },
118293
- getDefaultTextureCubeWhite ()
118294
- {
118295
- return this [_defaultTextureCubeWhite];
118259
+ return this [_defaultTextureCube];
118296
118260
  },
118297
118261
  getDefaultTextureProperties ()
118298
118262
  {
118299
118263
  this [_defaultTextureProperties] = new Texturing_TextureProperties (this .getPrivateScene ());
118300
- this [_defaultTextureProperties] ._magnificationFilter = "NICEST";
118301
- this [_defaultTextureProperties] ._minificationFilter = "NEAREST_PIXEL_AVG_MIPMAP";
118302
118264
  this [_defaultTextureProperties] ._generateMipMaps = true;
118303
- this [_defaultTextureProperties] ._textureCompression = "NICEST";
118265
+ this [_defaultTextureProperties] ._minificationFilter = "NICEST";
118266
+ this [_defaultTextureProperties] ._magnificationFilter = "NICEST";
118304
118267
 
118305
118268
  this [_defaultTextureProperties] .setup ();
118306
118269
 
@@ -119461,7 +119424,7 @@ const Components_default_ = Components;
119461
119424
  x_ite_Namespace .add ("Components", "x_ite/Components", Components_default_);
119462
119425
  /* harmony default export */ const x_ite_Components = ((/* unused pure expression or super */ null && (Components_default_)));
119463
119426
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/DOMIntegration.js
119464
- /* provided dependency */ var DOMIntegration_$ = __webpack_require__(978);
119427
+ /* provided dependency */ var DOMIntegration_$ = __webpack_require__(718);
119465
119428
  /*******************************************************************************
119466
119429
  * MIT License
119467
119430
  *
@@ -120600,7 +120563,7 @@ const SupportedProfiles_default_ = SupportedProfiles;
120600
120563
  x_ite_Namespace .add ("SupportedProfiles", "x_ite/Configuration/SupportedProfiles", SupportedProfiles_default_);
120601
120564
  /* harmony default export */ const Configuration_SupportedProfiles = (SupportedProfiles_default_);
120602
120565
  ;// CONCATENATED MODULE: ./src/x_ite/Browser/X3DBrowser.js
120603
- /* provided dependency */ var X3DBrowser_$ = __webpack_require__(978);
120566
+ /* provided dependency */ var X3DBrowser_$ = __webpack_require__(718);
120604
120567
  /*******************************************************************************
120605
120568
  *
120606
120569
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -121681,7 +121644,7 @@ const X3DBrowser_default_ = X3DBrowser;
121681
121644
  x_ite_Namespace .add ("X3DBrowser", "x_ite/Browser/X3DBrowser", X3DBrowser_default_);
121682
121645
  /* harmony default export */ const Browser_X3DBrowser = (X3DBrowser_default_);
121683
121646
  ;// CONCATENATED MODULE: ./src/x_ite/X3DCanvasElement.js
121684
- /* provided dependency */ var X3DCanvasElement_$ = __webpack_require__(978);
121647
+ /* provided dependency */ var X3DCanvasElement_$ = __webpack_require__(718);
121685
121648
  /*******************************************************************************
121686
121649
  *
121687
121650
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -121813,8 +121776,8 @@ const X3DCanvasElement_default_ = X3DCanvasElement;
121813
121776
  x_ite_Namespace .add ("X3DCanvasElement", "x_ite/X3DCanvasElement", X3DCanvasElement_default_);
121814
121777
  /* harmony default export */ const x_ite_X3DCanvasElement = (X3DCanvasElement_default_);
121815
121778
  ;// CONCATENATED MODULE: ./src/lib/jquery.js
121816
- /* provided dependency */ var jquery_$ = __webpack_require__(978);
121817
- /* provided dependency */ var pako = __webpack_require__(899);
121779
+ /* provided dependency */ var jquery_$ = __webpack_require__(718);
121780
+ /* provided dependency */ var pako = __webpack_require__(994);
121818
121781
  Object .assign (jquery_$,
121819
121782
  {
121820
121783
  decodeText (input)
@@ -121891,14 +121854,14 @@ const jquery_default_ = jquery_$;
121891
121854
  x_ite_Namespace .add ("jquery", "lib/jquery", jquery_default_);
121892
121855
  /* harmony default export */ const jquery = ((/* unused pure expression or super */ null && (jquery_default_)));
121893
121856
  ;// CONCATENATED MODULE: ./src/lib/libtess.js
121894
- /* provided dependency */ var libtess_libtess = __webpack_require__(728);
121857
+ /* provided dependency */ var libtess_libtess = __webpack_require__(89);
121895
121858
  const libtess_default_ = libtess_libtess;
121896
121859
  ;
121897
121860
 
121898
121861
  x_ite_Namespace .add ("libtess", "lib/libtess", libtess_default_);
121899
121862
  /* harmony default export */ const lib_libtess = ((/* unused pure expression or super */ null && (libtess_default_)));
121900
121863
  ;// CONCATENATED MODULE: ./src/x_ite/X3D.js
121901
- /* provided dependency */ var X3D_$ = __webpack_require__(978);
121864
+ /* provided dependency */ var X3D_$ = __webpack_require__(718);
121902
121865
  /*******************************************************************************
121903
121866
  *
121904
121867
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -122292,7 +122255,7 @@ x_ite_Namespace .add ("shim", "shim", shim_default_);
122292
122255
 
122293
122256
  // Assign X3D to global namespace.
122294
122257
 
122295
- window [Symbol .for ("X_ITE.X3D-9.0.0")] = x_ite_X3D;
122258
+ window [Symbol .for ("X_ITE.X3D-9.0.2")] = x_ite_X3D;
122296
122259
 
122297
122260
  customElements .define ("x3d-canvas", x_ite_X3DCanvasElement);
122298
122261