x_ite 8.10.0 → 8.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Makefile +3 -0
- package/build/bin/version.pl +28 -20
- package/build/docs/glTF-samples.pl +151 -0
- package/build/docs/nodes.pl +1 -1
- package/build/src/nodes.pl +41 -0
- package/dist/assets/components/Annotation.js +13 -13
- package/dist/assets/components/Annotation.min.js +1 -1
- package/dist/assets/components/CADGeometry.js +13 -13
- package/dist/assets/components/CADGeometry.min.js +1 -1
- package/dist/assets/components/CubeMapTexturing.js +30 -26
- package/dist/assets/components/CubeMapTexturing.min.js +1 -1
- package/dist/assets/components/DIS.js +14 -14
- package/dist/assets/components/DIS.min.js +1 -1
- package/dist/assets/components/EventUtilities.js +9 -9
- package/dist/assets/components/EventUtilities.min.js +1 -1
- package/dist/assets/components/Geometry2D.js +19 -19
- package/dist/assets/components/Geometry2D.min.js +1 -1
- package/dist/assets/components/Geospatial.js +33 -33
- package/dist/assets/components/Geospatial.min.js +1 -1
- package/dist/assets/components/HAnim.js +394 -30
- package/dist/assets/components/HAnim.min.js +1 -1
- package/dist/assets/components/KeyDeviceSensor.js +8 -8
- package/dist/assets/components/KeyDeviceSensor.min.js +1 -1
- package/dist/assets/components/Layout.js +26 -26
- package/dist/assets/components/Layout.min.js +1 -1
- package/dist/assets/components/NURBS.js +24 -24
- package/dist/assets/components/NURBS.min.js +1 -1
- package/dist/assets/components/ParticleSystems.js +73 -74
- package/dist/assets/components/ParticleSystems.min.js +1 -1
- package/dist/assets/components/Picking.js +18 -18
- package/dist/assets/components/Picking.min.js +1 -1
- package/dist/assets/components/RigidBodyPhysics.js +18 -18
- package/dist/assets/components/RigidBodyPhysics.min.js +1 -1
- package/dist/assets/components/Scripting.js +37 -37
- package/dist/assets/components/Scripting.min.js +1 -1
- package/dist/assets/components/Text.js +55 -63
- package/dist/assets/components/Text.min.js +1 -1
- package/dist/assets/components/TextureProjector.js +14 -14
- package/dist/assets/components/TextureProjector.min.js +1 -1
- package/dist/assets/components/Texturing3D.js +35 -31
- package/dist/assets/components/Texturing3D.min.js +1 -1
- package/dist/assets/components/VolumeRendering.js +20 -20
- package/dist/assets/components/VolumeRendering.min.js +1 -1
- package/dist/assets/components/X_ITE.js +9 -9
- package/dist/assets/components/X_ITE.min.js +1 -1
- package/dist/x_ite.css +1 -1
- package/dist/x_ite.js +1456 -844
- package/dist/x_ite.min.js +1 -1
- package/dist/x_ite.zip +0 -0
- package/docs/_config.yml +2 -2
- package/docs/_posts/components/Core/MetadataBoolean.md +6 -4
- package/docs/_posts/components/Core/MetadataDouble.md +6 -4
- package/docs/_posts/components/Core/MetadataFloat.md +6 -4
- package/docs/_posts/components/Core/MetadataInteger.md +6 -4
- package/docs/_posts/components/Core/MetadataSet.md +6 -4
- package/docs/_posts/components/Core/MetadataString.md +6 -4
- package/docs/_posts/components/DIS/DISEntityTypeMapping.md +1 -1
- package/docs/_posts/components/HAnim/HAnimMotion.md +48 -48
- package/docs/_posts/components/RigidBodyPhysics/Contact.md +1 -1
- package/docs/_posts/getting-started.md +45 -35
- package/docs/_posts/reference/browser-services.md +6 -0
- package/docs/_posts/what's-new.md +23 -0
- package/docs/_tabs/playground.html +215 -15
- package/docs/assets/css/style.scss +35 -2
- package/docs/assets/js/example.js +95 -3
- package/docs/laboratory/gltf-sample-viewer.html +617 -240
- package/package.json +2 -2
- package/src/assets/shaders/Types.glsl.js +4 -0
- package/src/assets/shaders/webgl1/include/Hatch.glsl.js +2 -3
- package/src/assets/shaders/webgl2/Compose.fs.js +29 -0
- package/src/assets/shaders/webgl2/Compose.vs.js +14 -0
- package/src/assets/shaders/webgl2/include/Fragment.glsl.js +24 -2
- package/src/assets/shaders/webgl2/include/Hatch.glsl.js +2 -3
- package/src/assets/shaders/webgl2/include/Stipple.glsl.js +5 -3
- package/src/bookmarks.js +92 -5
- package/src/examples.js +1 -0
- package/src/standard/Math/Numbers/Quaternion.js +191 -13
- package/src/standard/Math/Numbers/Rotation4.js +23 -0
- package/src/standard/Time/{MicroTime.js → Time.js} +21 -28
- package/src/x_ite/Base/X3DChildObject.js +5 -4
- package/src/x_ite/Browser/Core/BrowserOptions.js +71 -60
- package/src/x_ite/Browser/Core/Context.js +2 -2
- package/src/x_ite/Browser/Core/X3DCoreContext.js +6 -0
- package/src/x_ite/Browser/DOMIntegration.js +0 -17
- package/src/x_ite/Browser/Navigation/ExamineViewer.js +5 -4
- package/src/x_ite/Browser/Navigation/X3DFlyViewer.js +7 -4
- package/src/x_ite/Browser/Rendering/X3DRenderingContext.js +20 -15
- package/src/x_ite/Browser/Shaders/Shaders.js +19 -15
- package/src/x_ite/Browser/Text/X3DTextContext.js +16 -16
- package/src/x_ite/Browser/Time/X3DTimeContext.js +3 -2
- package/src/x_ite/Browser/VERSION.js +1 -1
- package/src/x_ite/Browser/VolumeRendering/VolumeMaterial.js +2 -2
- package/src/x_ite/Browser/X3DBrowser.js +1 -2
- package/src/x_ite/Browser/X3DBrowserContext.js +0 -5
- package/src/x_ite/Components/Core/MetadataBoolean.js +8 -1
- package/src/x_ite/Components/Core/MetadataDouble.js +8 -1
- package/src/x_ite/Components/Core/MetadataFloat.js +8 -1
- package/src/x_ite/Components/Core/MetadataInteger.js +8 -1
- package/src/x_ite/Components/Core/MetadataSet.js +8 -1
- package/src/x_ite/Components/Core/MetadataString.js +8 -1
- package/src/x_ite/Components/Core/X3DPrototypeInstance.js +9 -6
- package/src/x_ite/Components/CubeMapTexturing/ImageCubeMapTexture.js +2 -1
- package/src/x_ite/Components/DIS/DISEntityTypeMapping.js +1 -1
- package/src/x_ite/Components/EnvironmentalEffects/X3DBackgroundNode.js +5 -1
- package/src/x_ite/Components/Grouping/X3DGroupingNode.js +2 -0
- package/src/x_ite/Components/HAnim/HAnimHumanoid.js +34 -2
- package/src/x_ite/Components/HAnim/HAnimMotion.js +331 -15
- package/src/x_ite/Components/Lighting/DirectionalLight.js +1 -3
- package/src/x_ite/Components/Lighting/PointLight.js +1 -3
- package/src/x_ite/Components/Lighting/SpotLight.js +1 -3
- package/src/x_ite/Components/Networking/X3DUrlObject.js +5 -4
- package/src/x_ite/Components/ParticleSystems/ParticleSystem.js +47 -51
- package/src/x_ite/Components/Rendering/X3DGeometryNode.js +4 -2
- package/src/x_ite/Components/RigidBodyPhysics/Contact.js +1 -1
- package/src/x_ite/Components/Shaders/X3DProgrammableShaderObject.js +1 -1
- package/src/x_ite/Components/Shape/FillProperties.js +4 -0
- package/src/x_ite/Components/Shape/LineProperties.js +4 -0
- package/src/x_ite/Components/Shape/PointProperties.js +4 -0
- package/src/x_ite/Components/Shape/X3DMaterialNode.js +44 -20
- package/src/x_ite/Components/Sound/AudioClip.js +2 -1
- package/src/x_ite/Components/Text/X3DFontStyleNode.js +13 -23
- package/src/x_ite/Components/Texturing/ImageTexture.js +2 -1
- package/src/x_ite/Components/Texturing/MovieTexture.js +2 -1
- package/src/x_ite/Components/Texturing3D/ImageTextureAtlas.js +2 -1
- package/src/x_ite/Components/Time/TimeSensor.js +25 -24
- package/src/x_ite/Components/Time/X3DTimeDependentNode.js +5 -4
- package/src/x_ite/Execution/BindableList.js +3 -3
- package/src/x_ite/Execution/X3DScene.js +2 -0
- package/src/x_ite/Parser/XMLParser.js +12 -2
- package/src/x_ite/Rendering/MultiSampleFrameBuffer.js +264 -26
- package/src/x_ite/Rendering/PointingBuffer.js +5 -7
- package/src/x_ite/Rendering/TextureBuffer.js +6 -14
- package/src/x_ite/Rendering/X3DRenderObject.js +28 -28
- package/src/x_ite/X3D.js +0 -1
- package/src/x_ite/X3DCanvasElement.js +2 -0
- package/src/x_ite.html +23 -24
- package/x_ite.min.html +23 -24
- /package/build/{bin → docs}/tags.pl +0 -0
package/dist/x_ite.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* X_ITE v8.
|
|
1
|
+
/* X_ITE v8.11.0 */(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,11 +11,11 @@
|
|
|
11
11
|
return /******/ (() => { // webpackBootstrap
|
|
12
12
|
/******/ var __webpack_modules__ = ({
|
|
13
13
|
|
|
14
|
-
/***/
|
|
14
|
+
/***/ 672:
|
|
15
15
|
/***/ (function(module, exports, __webpack_require__) {
|
|
16
16
|
|
|
17
17
|
"use strict";
|
|
18
|
-
/* provided dependency */ var jQuery = __webpack_require__(
|
|
18
|
+
/* provided dependency */ var jQuery = __webpack_require__(964);
|
|
19
19
|
var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_RESULT__;
|
|
20
20
|
|
|
21
21
|
/**
|
|
@@ -387,10 +387,10 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_RESULT__;
|
|
|
387
387
|
|
|
388
388
|
/***/ }),
|
|
389
389
|
|
|
390
|
-
/***/
|
|
390
|
+
/***/ 253:
|
|
391
391
|
/***/ ((__unused_webpack_module, __unused_webpack_exports, __webpack_require__) => {
|
|
392
392
|
|
|
393
|
-
/* provided dependency */ var jQuery = __webpack_require__(
|
|
393
|
+
/* provided dependency */ var jQuery = __webpack_require__(964);
|
|
394
394
|
/**
|
|
395
395
|
* @preserve jquery.fullscreen 1.1.5
|
|
396
396
|
* https://github.com/code-lts/jquery-fullscreen-plugin
|
|
@@ -586,7 +586,7 @@ installFullScreenHandlers();
|
|
|
586
586
|
|
|
587
587
|
/***/ }),
|
|
588
588
|
|
|
589
|
-
/***/
|
|
589
|
+
/***/ 759:
|
|
590
590
|
/***/ ((module, exports, __webpack_require__) => {
|
|
591
591
|
|
|
592
592
|
var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
|
|
@@ -600,7 +600,7 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
|
|
|
600
600
|
(function (factory) {
|
|
601
601
|
if ( true ) {
|
|
602
602
|
// AMD. Register as an anonymous module.
|
|
603
|
-
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(
|
|
603
|
+
!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(964)], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory),
|
|
604
604
|
__WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ?
|
|
605
605
|
(__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__),
|
|
606
606
|
__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
|
|
@@ -811,7 +811,7 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
|
|
|
811
811
|
|
|
812
812
|
/***/ }),
|
|
813
813
|
|
|
814
|
-
/***/
|
|
814
|
+
/***/ 964:
|
|
815
815
|
/***/ (function(module, exports) {
|
|
816
816
|
|
|
817
817
|
var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*!
|
|
@@ -11523,7 +11523,7 @@ return jQuery;
|
|
|
11523
11523
|
|
|
11524
11524
|
/***/ }),
|
|
11525
11525
|
|
|
11526
|
-
/***/
|
|
11526
|
+
/***/ 149:
|
|
11527
11527
|
/***/ ((module) => {
|
|
11528
11528
|
|
|
11529
11529
|
/**
|
|
@@ -16302,7 +16302,7 @@ if (true) {
|
|
|
16302
16302
|
|
|
16303
16303
|
/***/ }),
|
|
16304
16304
|
|
|
16305
|
-
/***/
|
|
16305
|
+
/***/ 931:
|
|
16306
16306
|
/***/ (function(__unused_webpack_module, exports) {
|
|
16307
16307
|
|
|
16308
16308
|
|
|
@@ -19547,7 +19547,7 @@ if (true) {
|
|
|
19547
19547
|
|
|
19548
19548
|
/***/ }),
|
|
19549
19549
|
|
|
19550
|
-
/***/
|
|
19550
|
+
/***/ 90:
|
|
19551
19551
|
/***/ (function(module, exports) {
|
|
19552
19552
|
|
|
19553
19553
|
var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*
|
|
@@ -22146,6 +22146,88 @@ const X3DObject_default_ = X3DObject;
|
|
|
22146
22146
|
|
|
22147
22147
|
x_ite_Namespace .set ("x_ite/Base/X3DObject", X3DObject_default_);
|
|
22148
22148
|
/* harmony default export */ const Base_X3DObject = (X3DObject_default_);
|
|
22149
|
+
;// CONCATENATED MODULE: ./src/standard/Time/Time.js
|
|
22150
|
+
/*******************************************************************************
|
|
22151
|
+
*
|
|
22152
|
+
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
22153
|
+
*
|
|
22154
|
+
* Copyright create3000, Scheffelstraße 31a, Leipzig, Germany 2011 - 2022.
|
|
22155
|
+
*
|
|
22156
|
+
* All rights reserved. Holger Seelig <holger.seelig@yahoo.de>.
|
|
22157
|
+
*
|
|
22158
|
+
* The copyright notice above does not evidence any actual of intended
|
|
22159
|
+
* publication of such source code, and is an unpublished work by create3000.
|
|
22160
|
+
* This material contains CONFIDENTIAL INFORMATION that is the property of
|
|
22161
|
+
* create3000.
|
|
22162
|
+
*
|
|
22163
|
+
* No permission is granted to copy, distribute, or create derivative works from
|
|
22164
|
+
* the contents of this software, in whole or in part, without the prior written
|
|
22165
|
+
* permission of create3000.
|
|
22166
|
+
*
|
|
22167
|
+
* NON-MILITARY USE ONLY
|
|
22168
|
+
*
|
|
22169
|
+
* All create3000 software are effectively free software with a non-military use
|
|
22170
|
+
* restriction. It is free. Well commented source is provided. You may reuse the
|
|
22171
|
+
* source in any way you please with the exception anything that uses it must be
|
|
22172
|
+
* marked to indicate is contains 'non-military use only' components.
|
|
22173
|
+
*
|
|
22174
|
+
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
22175
|
+
*
|
|
22176
|
+
* Copyright 2011 - 2022, Holger Seelig <holger.seelig@yahoo.de>.
|
|
22177
|
+
*
|
|
22178
|
+
* This file is part of the X_ITE Project.
|
|
22179
|
+
*
|
|
22180
|
+
* X_ITE is free software: you can redistribute it and/or modify it under the
|
|
22181
|
+
* terms of the GNU General Public License version 3 only, as published by the
|
|
22182
|
+
* Free Software Foundation.
|
|
22183
|
+
*
|
|
22184
|
+
* X_ITE is distributed in the hope that it will be useful, but WITHOUT ANY
|
|
22185
|
+
* WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
|
|
22186
|
+
* A PARTICULAR PURPOSE. See the GNU General Public License version 3 for more
|
|
22187
|
+
* details (a copy is included in the LICENSE file that accompanied this code).
|
|
22188
|
+
*
|
|
22189
|
+
* You should have received a copy of the GNU General Public License version 3
|
|
22190
|
+
* along with X_ITE. If not, see <https://www.gnu.org/licenses/gpl.html> for a
|
|
22191
|
+
* copy of the GPLv3 License.
|
|
22192
|
+
*
|
|
22193
|
+
* For Silvio, Joy and Adi.
|
|
22194
|
+
*
|
|
22195
|
+
******************************************************************************/
|
|
22196
|
+
|
|
22197
|
+
// Return a pseudo accurate timestamp.
|
|
22198
|
+
|
|
22199
|
+
const Time =
|
|
22200
|
+
{
|
|
22201
|
+
now: (function ()
|
|
22202
|
+
{
|
|
22203
|
+
let
|
|
22204
|
+
offset = 0,
|
|
22205
|
+
last = 0;
|
|
22206
|
+
|
|
22207
|
+
return function ()
|
|
22208
|
+
{
|
|
22209
|
+
const current = Date .now ();
|
|
22210
|
+
|
|
22211
|
+
if (current > last)
|
|
22212
|
+
{
|
|
22213
|
+
offset = 0;
|
|
22214
|
+
last = current;
|
|
22215
|
+
|
|
22216
|
+
return current;
|
|
22217
|
+
}
|
|
22218
|
+
else
|
|
22219
|
+
{
|
|
22220
|
+
return last = current + (offset < 1000 ? ++ offset : offset) / 1000;
|
|
22221
|
+
}
|
|
22222
|
+
};
|
|
22223
|
+
})(),
|
|
22224
|
+
};
|
|
22225
|
+
|
|
22226
|
+
const Time_default_ = Time;
|
|
22227
|
+
;
|
|
22228
|
+
|
|
22229
|
+
x_ite_Namespace .set ("standard/Time/Time", Time_default_);
|
|
22230
|
+
/* harmony default export */ const Time_Time = (Time_default_);
|
|
22149
22231
|
;// CONCATENATED MODULE: ./src/x_ite/Base/X3DChildObject.js
|
|
22150
22232
|
/*******************************************************************************
|
|
22151
22233
|
*
|
|
@@ -22197,6 +22279,7 @@ x_ite_Namespace .set ("x_ite/Base/X3DObject", X3DObject_default_);
|
|
|
22197
22279
|
|
|
22198
22280
|
|
|
22199
22281
|
|
|
22282
|
+
|
|
22200
22283
|
const
|
|
22201
22284
|
_modificationTime = Symbol (),
|
|
22202
22285
|
_tainted = Symbol (),
|
|
@@ -22246,14 +22329,14 @@ if (DEVELOPMENT)
|
|
|
22246
22329
|
},
|
|
22247
22330
|
addEvent ()
|
|
22248
22331
|
{
|
|
22249
|
-
this .setModificationTime (
|
|
22332
|
+
this .setModificationTime (Time_Time .now ());
|
|
22250
22333
|
|
|
22251
22334
|
for (const parent of this [_parents] .values ())
|
|
22252
22335
|
parent .deref () ?.addEvent (this);
|
|
22253
22336
|
},
|
|
22254
22337
|
addEventObject (field, event)
|
|
22255
22338
|
{
|
|
22256
|
-
this .setModificationTime (
|
|
22339
|
+
this .setModificationTime (Time_Time .now ());
|
|
22257
22340
|
|
|
22258
22341
|
for (const parent of this [_parents] .values ())
|
|
22259
22342
|
parent .deref () ?.addEventObject (this, event);
|
|
@@ -22353,14 +22436,14 @@ else
|
|
|
22353
22436
|
},
|
|
22354
22437
|
addEvent ()
|
|
22355
22438
|
{
|
|
22356
|
-
this .setModificationTime (
|
|
22439
|
+
this .setModificationTime (Time_Time .now ());
|
|
22357
22440
|
|
|
22358
22441
|
for (const parent of this [_parents])
|
|
22359
22442
|
parent .addEvent (this);
|
|
22360
22443
|
},
|
|
22361
22444
|
addEventObject (field, event)
|
|
22362
22445
|
{
|
|
22363
|
-
this .setModificationTime (
|
|
22446
|
+
this .setModificationTime (Time_Time .now ());
|
|
22364
22447
|
|
|
22365
22448
|
for (const parent of this [_parents])
|
|
22366
22449
|
parent .addEventObject (this, event);
|
|
@@ -27870,6 +27953,179 @@ Object .assign (Quaternion .prototype,
|
|
|
27870
27953
|
|
|
27871
27954
|
return matrix;
|
|
27872
27955
|
},
|
|
27956
|
+
setEuler (x, y, z, order = "XYZ")
|
|
27957
|
+
{
|
|
27958
|
+
// http://www.mathworks.com/matlabcentral/fileexchange/20696-function-to-convert-between-dcm-euler-angles-quaternions-and-euler-vectors/content/SpinCalc.m
|
|
27959
|
+
|
|
27960
|
+
const
|
|
27961
|
+
c1 = Math .cos (x / 2),
|
|
27962
|
+
c2 = Math .cos (y / 2),
|
|
27963
|
+
c3 = Math .cos (z / 2),
|
|
27964
|
+
s1 = Math .sin (x / 2),
|
|
27965
|
+
s2 = Math .sin (y / 2),
|
|
27966
|
+
s3 = Math .sin (z / 2);
|
|
27967
|
+
|
|
27968
|
+
switch (order)
|
|
27969
|
+
{
|
|
27970
|
+
case "XYZ":
|
|
27971
|
+
this .x = s1 * c2 * c3 + c1 * s2 * s3;
|
|
27972
|
+
this .y = c1 * s2 * c3 - s1 * c2 * s3;
|
|
27973
|
+
this .z = c1 * c2 * s3 + s1 * s2 * c3;
|
|
27974
|
+
this .w = c1 * c2 * c3 - s1 * s2 * s3;
|
|
27975
|
+
break;
|
|
27976
|
+
|
|
27977
|
+
case "ZYX":
|
|
27978
|
+
this .x = s1 * c2 * c3 - c1 * s2 * s3;
|
|
27979
|
+
this .y = c1 * s2 * c3 + s1 * c2 * s3;
|
|
27980
|
+
this .z = c1 * c2 * s3 - s1 * s2 * c3;
|
|
27981
|
+
this .w = c1 * c2 * c3 + s1 * s2 * s3;
|
|
27982
|
+
break;
|
|
27983
|
+
|
|
27984
|
+
case "YXZ":
|
|
27985
|
+
this .x = s1 * c2 * c3 + c1 * s2 * s3;
|
|
27986
|
+
this .y = c1 * s2 * c3 - s1 * c2 * s3;
|
|
27987
|
+
this .z = c1 * c2 * s3 - s1 * s2 * c3;
|
|
27988
|
+
this .w = c1 * c2 * c3 + s1 * s2 * s3;
|
|
27989
|
+
break;
|
|
27990
|
+
|
|
27991
|
+
case "ZXY":
|
|
27992
|
+
this .x = s1 * c2 * c3 - c1 * s2 * s3;
|
|
27993
|
+
this .y = c1 * s2 * c3 + s1 * c2 * s3;
|
|
27994
|
+
this .z = c1 * c2 * s3 + s1 * s2 * c3;
|
|
27995
|
+
this .w = c1 * c2 * c3 - s1 * s2 * s3;
|
|
27996
|
+
break;
|
|
27997
|
+
|
|
27998
|
+
case "YZX":
|
|
27999
|
+
this .x = s1 * c2 * c3 + c1 * s2 * s3;
|
|
28000
|
+
this .y = c1 * s2 * c3 + s1 * c2 * s3;
|
|
28001
|
+
this .z = c1 * c2 * s3 - s1 * s2 * c3;
|
|
28002
|
+
this .w = c1 * c2 * c3 - s1 * s2 * s3;
|
|
28003
|
+
break;
|
|
28004
|
+
|
|
28005
|
+
case "XZY":
|
|
28006
|
+
this .x = s1 * c2 * c3 - c1 * s2 * s3;
|
|
28007
|
+
this .y = c1 * s2 * c3 - s1 * c2 * s3;
|
|
28008
|
+
this .z = c1 * c2 * s3 + s1 * s2 * c3;
|
|
28009
|
+
this .w = c1 * c2 * c3 + s1 * s2 * s3;
|
|
28010
|
+
break;
|
|
28011
|
+
}
|
|
28012
|
+
|
|
28013
|
+
return this;
|
|
28014
|
+
},
|
|
28015
|
+
getEuler (euler = [ ], order = "XYZ")
|
|
28016
|
+
{
|
|
28017
|
+
const { 0: m0, 1: m1, 2: m2, 3: m3, 4: m4, 5: m5, 6: m6, 7: m7, 8: m8 } = this .getMatrix (Quaternion_m);
|
|
28018
|
+
|
|
28019
|
+
switch (order)
|
|
28020
|
+
{
|
|
28021
|
+
case "XYZ":
|
|
28022
|
+
{
|
|
28023
|
+
euler [1] = Math .asin (Math_Algorithm .clamp (m6, -1, 1));
|
|
28024
|
+
|
|
28025
|
+
if (Math .abs (m6) < 0.9999999)
|
|
28026
|
+
{
|
|
28027
|
+
euler [0] = Math .atan2 (-m7, m8);
|
|
28028
|
+
euler [2] = Math .atan2 (-m3, m0);
|
|
28029
|
+
}
|
|
28030
|
+
else
|
|
28031
|
+
{
|
|
28032
|
+
euler [0] = Math .atan2 (m5, m4);
|
|
28033
|
+
euler [2] = 0;
|
|
28034
|
+
}
|
|
28035
|
+
|
|
28036
|
+
break;
|
|
28037
|
+
}
|
|
28038
|
+
case "ZYX":
|
|
28039
|
+
{
|
|
28040
|
+
euler [1] = Math .asin (- Math_Algorithm .clamp (m2, -1, 1));
|
|
28041
|
+
|
|
28042
|
+
if (Math .abs (m2) < 0.9999999)
|
|
28043
|
+
{
|
|
28044
|
+
euler [0] = Math .atan2 (m5, m8);
|
|
28045
|
+
euler [2] = Math .atan2 (m1, m0);
|
|
28046
|
+
}
|
|
28047
|
+
else
|
|
28048
|
+
{
|
|
28049
|
+
euler [0] = 0;
|
|
28050
|
+
euler [2] = Math .atan2 (-m3, m4);
|
|
28051
|
+
}
|
|
28052
|
+
|
|
28053
|
+
break;
|
|
28054
|
+
}
|
|
28055
|
+
case "YXZ":
|
|
28056
|
+
{
|
|
28057
|
+
euler [0] = Math .asin (- Math_Algorithm .clamp (m7, -1, 1));
|
|
28058
|
+
|
|
28059
|
+
if (Math .abs (m7) < 0.9999999)
|
|
28060
|
+
{
|
|
28061
|
+
euler [1] = Math .atan2 (m6, m8);
|
|
28062
|
+
euler [2] = Math .atan2 (m1, m4);
|
|
28063
|
+
|
|
28064
|
+
}
|
|
28065
|
+
else
|
|
28066
|
+
{
|
|
28067
|
+
euler [1] = Math .atan2 (-m2, m0);
|
|
28068
|
+
euler [2] = 0;
|
|
28069
|
+
}
|
|
28070
|
+
|
|
28071
|
+
break;
|
|
28072
|
+
}
|
|
28073
|
+
case "ZXY":
|
|
28074
|
+
{
|
|
28075
|
+
euler [0] = Math .asin (Math_Algorithm .clamp (m5, -1, 1));
|
|
28076
|
+
|
|
28077
|
+
if (Math .abs (m5) < 0.9999999)
|
|
28078
|
+
{
|
|
28079
|
+
euler [1] = Math .atan2 (-m2, m8);
|
|
28080
|
+
euler [2] = Math .atan2 (-m3, m4);
|
|
28081
|
+
}
|
|
28082
|
+
else
|
|
28083
|
+
{
|
|
28084
|
+
euler [1] = 0;
|
|
28085
|
+
euler [2] = Math .atan2 (m1, m0);
|
|
28086
|
+
}
|
|
28087
|
+
|
|
28088
|
+
break;
|
|
28089
|
+
}
|
|
28090
|
+
case "YZX":
|
|
28091
|
+
{
|
|
28092
|
+
euler [2] = Math .asin (Math_Algorithm .clamp (m1, -1, 1));
|
|
28093
|
+
|
|
28094
|
+
if (Math .abs (m1) < 0.9999999)
|
|
28095
|
+
{
|
|
28096
|
+
euler [0] = Math .atan2 (-m7, m4);
|
|
28097
|
+
euler [1] = Math .atan2 (-m2, m0);
|
|
28098
|
+
}
|
|
28099
|
+
else
|
|
28100
|
+
{
|
|
28101
|
+
euler [0] = 0;
|
|
28102
|
+
euler [1] = Math .atan2 (m6, m8);
|
|
28103
|
+
}
|
|
28104
|
+
|
|
28105
|
+
break;
|
|
28106
|
+
}
|
|
28107
|
+
case "XZY":
|
|
28108
|
+
{
|
|
28109
|
+
euler [2] = Math .asin (- Math_Algorithm .clamp (m3, -1, 1));
|
|
28110
|
+
|
|
28111
|
+
if (Math .abs (m3) < 0.9999999)
|
|
28112
|
+
{
|
|
28113
|
+
euler [0] = Math .atan2 (m5, m4);
|
|
28114
|
+
euler [1] = Math .atan2 (m6, m0);
|
|
28115
|
+
|
|
28116
|
+
}
|
|
28117
|
+
else
|
|
28118
|
+
{
|
|
28119
|
+
euler [0] = Math .atan2 (-m7, m8);
|
|
28120
|
+
euler [1] = 0;
|
|
28121
|
+
}
|
|
28122
|
+
|
|
28123
|
+
break;
|
|
28124
|
+
}
|
|
28125
|
+
}
|
|
28126
|
+
|
|
28127
|
+
return euler;
|
|
28128
|
+
},
|
|
27873
28129
|
isReal ()
|
|
27874
28130
|
{
|
|
27875
28131
|
return !(this .x || this .y || this .z);
|
|
@@ -27960,31 +28216,35 @@ Object .assign (Quaternion .prototype,
|
|
|
27960
28216
|
},
|
|
27961
28217
|
multVecQuat (vector)
|
|
27962
28218
|
{
|
|
28219
|
+
// https://en.wikipedia.org/wiki/Conversion_between_quaternions_and_Euler_angles#Vector_rotation
|
|
28220
|
+
|
|
27963
28221
|
const
|
|
27964
28222
|
{ x: qx, y: qy, z: qz, w: qw } = this,
|
|
27965
28223
|
{ x: vx, y: vy, z: vz } = vector,
|
|
27966
|
-
|
|
27967
|
-
|
|
27968
|
-
|
|
28224
|
+
tx = 2 * (qy * vz - qz * vy),
|
|
28225
|
+
ty = 2 * (qz * vx - qx * vz),
|
|
28226
|
+
tz = 2 * (qx * vy - qy * vx);
|
|
27969
28227
|
|
|
27970
|
-
vector .x
|
|
27971
|
-
vector .y
|
|
27972
|
-
vector .z
|
|
28228
|
+
vector .x += qw * tx + qy * tz - qz * ty;
|
|
28229
|
+
vector .y += qw * ty + qz * tx - qx * tz;
|
|
28230
|
+
vector .z += qw * tz + qx * ty - qy * tx;
|
|
27973
28231
|
|
|
27974
28232
|
return vector;
|
|
27975
28233
|
},
|
|
27976
28234
|
multQuatVec (vector)
|
|
27977
28235
|
{
|
|
28236
|
+
// https://en.wikipedia.org/wiki/Conversion_between_quaternions_and_Euler_angles#Vector_rotation
|
|
28237
|
+
|
|
27978
28238
|
const
|
|
27979
28239
|
{ x: qx, y: qy, z: qz, w: qw } = this,
|
|
27980
28240
|
{ x: vx, y: vy, z: vz } = vector,
|
|
27981
|
-
|
|
27982
|
-
|
|
27983
|
-
|
|
28241
|
+
tx = 2 * (qz * vy - qy * vz),
|
|
28242
|
+
ty = 2 * (qx * vz - qz * vx),
|
|
28243
|
+
tz = 2 * (qy * vx - qx * vy);
|
|
27984
28244
|
|
|
27985
|
-
vector .x
|
|
27986
|
-
vector .y
|
|
27987
|
-
vector .z
|
|
28245
|
+
vector .x += qw * tx - qy * tz + qz * ty;
|
|
28246
|
+
vector .y += qw * ty - qz * tx + qx * tz;
|
|
28247
|
+
vector .z += qw * tz - qx * ty + qy * tx;
|
|
27988
28248
|
|
|
27989
28249
|
return vector;
|
|
27990
28250
|
},
|
|
@@ -28189,7 +28449,8 @@ Object .assign (Quaternion,
|
|
|
28189
28449
|
const
|
|
28190
28450
|
t1 = new Quaternion (0, 0, 0, 1),
|
|
28191
28451
|
t2 = new Quaternion (0, 0, 0, 1),
|
|
28192
|
-
t3 = new Quaternion (0, 0, 0, 1)
|
|
28452
|
+
t3 = new Quaternion (0, 0, 0, 1),
|
|
28453
|
+
Quaternion_m = new Numbers_Matrix3 ();
|
|
28193
28454
|
|
|
28194
28455
|
const Quaternion_default_ = Quaternion;
|
|
28195
28456
|
;
|
|
@@ -28502,6 +28763,17 @@ Object .assign (Rotation4 .prototype,
|
|
|
28502
28763
|
{
|
|
28503
28764
|
return this [_quaternion] .getMatrix (matrix);
|
|
28504
28765
|
},
|
|
28766
|
+
setEuler (x, y, z, order = "XYZ")
|
|
28767
|
+
{
|
|
28768
|
+
// Quaternion is then already normalized.
|
|
28769
|
+
this [_quaternion] .setEuler (x, y, z, order);
|
|
28770
|
+
this .update ();
|
|
28771
|
+
return this;
|
|
28772
|
+
},
|
|
28773
|
+
getEuler (euler = [ ], order = "XYZ")
|
|
28774
|
+
{
|
|
28775
|
+
return this [_quaternion] .getEuler (euler, order);
|
|
28776
|
+
},
|
|
28505
28777
|
equals (rotation)
|
|
28506
28778
|
{
|
|
28507
28779
|
return this [_quaternion] .equals (rotation [_quaternion]);
|
|
@@ -28642,6 +28914,18 @@ Object .defineProperties (Rotation4 .prototype,
|
|
|
28642
28914
|
Object .assign (Rotation4,
|
|
28643
28915
|
{
|
|
28644
28916
|
Identity: new Rotation4 (),
|
|
28917
|
+
fromQuaternion (quaternion)
|
|
28918
|
+
{
|
|
28919
|
+
return new Rotation4 () .setQuaternion (quaternion);
|
|
28920
|
+
},
|
|
28921
|
+
fromMatrix (matrix)
|
|
28922
|
+
{
|
|
28923
|
+
return new Rotation4 () .setMatrix (matrix);
|
|
28924
|
+
},
|
|
28925
|
+
fromEuler (x, y, z, order = "XYZ")
|
|
28926
|
+
{
|
|
28927
|
+
return new Rotation4 () .setEuler (x, y, z, order);
|
|
28928
|
+
},
|
|
28645
28929
|
spline (r0, r1, r2)
|
|
28646
28930
|
{
|
|
28647
28931
|
const copy = Object .create (this .prototype);
|
|
@@ -34274,7 +34558,7 @@ x_ite_Namespace .set ("x_ite/Base/X3DBaseNode", X3DBaseNode_default_);
|
|
|
34274
34558
|
*
|
|
34275
34559
|
******************************************************************************/
|
|
34276
34560
|
|
|
34277
|
-
const VERSION_default_ = "8.
|
|
34561
|
+
const VERSION_default_ = "8.11.0";
|
|
34278
34562
|
;
|
|
34279
34563
|
|
|
34280
34564
|
x_ite_Namespace .set ("x_ite/Browser/VERSION", VERSION_default_);
|
|
@@ -35828,6 +36112,13 @@ Object .assign (Object .setPrototypeOf (MetadataBoolean .prototype, Core_X3DNode
|
|
|
35828
36112
|
Core_X3DNode .prototype .initialize .call (this);
|
|
35829
36113
|
Core_X3DMetadataObject .prototype .initialize .call (this);
|
|
35830
36114
|
},
|
|
36115
|
+
getContainerField (parser = false)
|
|
36116
|
+
{
|
|
36117
|
+
if (parser && this .getExecutionContext () .getSpecificationVersion () <= 3.3)
|
|
36118
|
+
return "metadata";
|
|
36119
|
+
|
|
36120
|
+
return Core_X3DNode .prototype .getContainerField .call (this);
|
|
36121
|
+
},
|
|
35831
36122
|
dispose ()
|
|
35832
36123
|
{
|
|
35833
36124
|
Core_X3DMetadataObject .prototype .dispose .call (this);
|
|
@@ -35849,7 +36140,7 @@ Object .defineProperties (MetadataBoolean,
|
|
|
35849
36140
|
},
|
|
35850
36141
|
containerField:
|
|
35851
36142
|
{
|
|
35852
|
-
value: "
|
|
36143
|
+
value: "value",
|
|
35853
36144
|
enumerable: true,
|
|
35854
36145
|
},
|
|
35855
36146
|
specificationRange:
|
|
@@ -35945,6 +36236,13 @@ Object .assign (Object .setPrototypeOf (MetadataDouble .prototype, Core_X3DNode
|
|
|
35945
36236
|
Core_X3DNode .prototype .initialize .call (this);
|
|
35946
36237
|
Core_X3DMetadataObject .prototype .initialize .call (this);
|
|
35947
36238
|
},
|
|
36239
|
+
getContainerField (parser = false)
|
|
36240
|
+
{
|
|
36241
|
+
if (parser && this .getExecutionContext () .getSpecificationVersion () <= 3.3)
|
|
36242
|
+
return "metadata";
|
|
36243
|
+
|
|
36244
|
+
return Core_X3DNode .prototype .getContainerField .call (this);
|
|
36245
|
+
},
|
|
35948
36246
|
dispose ()
|
|
35949
36247
|
{
|
|
35950
36248
|
Core_X3DMetadataObject .prototype .dispose .call (this);
|
|
@@ -35966,7 +36264,7 @@ Object .defineProperties (MetadataDouble,
|
|
|
35966
36264
|
},
|
|
35967
36265
|
containerField:
|
|
35968
36266
|
{
|
|
35969
|
-
value: "
|
|
36267
|
+
value: "value",
|
|
35970
36268
|
enumerable: true,
|
|
35971
36269
|
},
|
|
35972
36270
|
specificationRange:
|
|
@@ -36062,6 +36360,13 @@ Object .assign (Object .setPrototypeOf (MetadataFloat .prototype, Core_X3DNode .
|
|
|
36062
36360
|
Core_X3DNode .prototype .initialize .call (this);
|
|
36063
36361
|
Core_X3DMetadataObject .prototype .initialize .call (this);
|
|
36064
36362
|
},
|
|
36363
|
+
getContainerField (parser = false)
|
|
36364
|
+
{
|
|
36365
|
+
if (parser && this .getExecutionContext () .getSpecificationVersion () <= 3.3)
|
|
36366
|
+
return "metadata";
|
|
36367
|
+
|
|
36368
|
+
return Core_X3DNode .prototype .getContainerField .call (this);
|
|
36369
|
+
},
|
|
36065
36370
|
dispose ()
|
|
36066
36371
|
{
|
|
36067
36372
|
Core_X3DMetadataObject .prototype .dispose .call (this);
|
|
@@ -36083,7 +36388,7 @@ Object .defineProperties (MetadataFloat,
|
|
|
36083
36388
|
},
|
|
36084
36389
|
containerField:
|
|
36085
36390
|
{
|
|
36086
|
-
value: "
|
|
36391
|
+
value: "value",
|
|
36087
36392
|
enumerable: true,
|
|
36088
36393
|
},
|
|
36089
36394
|
specificationRange:
|
|
@@ -36179,6 +36484,13 @@ Object .assign (Object .setPrototypeOf (MetadataInteger .prototype, Core_X3DNode
|
|
|
36179
36484
|
Core_X3DNode .prototype .initialize .call (this);
|
|
36180
36485
|
Core_X3DMetadataObject .prototype .initialize .call (this);
|
|
36181
36486
|
},
|
|
36487
|
+
getContainerField (parser = false)
|
|
36488
|
+
{
|
|
36489
|
+
if (parser && this .getExecutionContext () .getSpecificationVersion () <= 3.3)
|
|
36490
|
+
return "metadata";
|
|
36491
|
+
|
|
36492
|
+
return Core_X3DNode .prototype .getContainerField .call (this);
|
|
36493
|
+
},
|
|
36182
36494
|
dispose ()
|
|
36183
36495
|
{
|
|
36184
36496
|
Core_X3DMetadataObject .prototype .dispose .call (this);
|
|
@@ -36200,7 +36512,7 @@ Object .defineProperties (MetadataInteger,
|
|
|
36200
36512
|
},
|
|
36201
36513
|
containerField:
|
|
36202
36514
|
{
|
|
36203
|
-
value: "
|
|
36515
|
+
value: "value",
|
|
36204
36516
|
enumerable: true,
|
|
36205
36517
|
},
|
|
36206
36518
|
specificationRange:
|
|
@@ -36296,6 +36608,13 @@ Object .assign (Object .setPrototypeOf (MetadataSet .prototype, Core_X3DNode .pr
|
|
|
36296
36608
|
Core_X3DNode .prototype .initialize .call (this);
|
|
36297
36609
|
Core_X3DMetadataObject .prototype .initialize .call (this);
|
|
36298
36610
|
},
|
|
36611
|
+
getContainerField (parser = false)
|
|
36612
|
+
{
|
|
36613
|
+
if (parser && this .getExecutionContext () .getSpecificationVersion () <= 3.3)
|
|
36614
|
+
return "metadata";
|
|
36615
|
+
|
|
36616
|
+
return Core_X3DNode .prototype .getContainerField .call (this);
|
|
36617
|
+
},
|
|
36299
36618
|
dispose ()
|
|
36300
36619
|
{
|
|
36301
36620
|
Core_X3DMetadataObject .prototype .dispose .call (this);
|
|
@@ -36317,7 +36636,7 @@ Object .defineProperties (MetadataSet,
|
|
|
36317
36636
|
},
|
|
36318
36637
|
containerField:
|
|
36319
36638
|
{
|
|
36320
|
-
value: "
|
|
36639
|
+
value: "value",
|
|
36321
36640
|
enumerable: true,
|
|
36322
36641
|
},
|
|
36323
36642
|
specificationRange:
|
|
@@ -36413,6 +36732,13 @@ Object .assign (Object .setPrototypeOf (MetadataString .prototype, Core_X3DNode
|
|
|
36413
36732
|
Core_X3DNode .prototype .initialize .call (this);
|
|
36414
36733
|
Core_X3DMetadataObject .prototype .initialize .call (this);
|
|
36415
36734
|
},
|
|
36735
|
+
getContainerField (parser = false)
|
|
36736
|
+
{
|
|
36737
|
+
if (parser && this .getExecutionContext () .getSpecificationVersion () <= 3.3)
|
|
36738
|
+
return "metadata";
|
|
36739
|
+
|
|
36740
|
+
return Core_X3DNode .prototype .getContainerField .call (this);
|
|
36741
|
+
},
|
|
36416
36742
|
dispose ()
|
|
36417
36743
|
{
|
|
36418
36744
|
Core_X3DMetadataObject .prototype .dispose .call (this);
|
|
@@ -36434,7 +36760,7 @@ Object .defineProperties (MetadataString,
|
|
|
36434
36760
|
},
|
|
36435
36761
|
containerField:
|
|
36436
36762
|
{
|
|
36437
|
-
value: "
|
|
36763
|
+
value: "value",
|
|
36438
36764
|
enumerable: true,
|
|
36439
36765
|
},
|
|
36440
36766
|
specificationRange:
|
|
@@ -37618,6 +37944,7 @@ x_ite_Namespace .set ("x_ite/Execution/ImportedNodesArray", ImportedNodesArray_d
|
|
|
37618
37944
|
|
|
37619
37945
|
|
|
37620
37946
|
|
|
37947
|
+
|
|
37621
37948
|
const
|
|
37622
37949
|
X3DUrlObject_cache = Symbol (),
|
|
37623
37950
|
_autoRefreshStartTime = Symbol (),
|
|
@@ -37632,7 +37959,7 @@ function X3DUrlObject (executionContext)
|
|
|
37632
37959
|
Base_X3DConstants .inputOutput, "loadData", new x_ite_Fields .SFTime ());
|
|
37633
37960
|
|
|
37634
37961
|
this [X3DUrlObject_cache] = true;
|
|
37635
|
-
this [_autoRefreshStartTime] =
|
|
37962
|
+
this [_autoRefreshStartTime] = Time_Time .now ();
|
|
37636
37963
|
}
|
|
37637
37964
|
|
|
37638
37965
|
Object .assign (X3DUrlObject .prototype,
|
|
@@ -37653,7 +37980,7 @@ Object .assign (X3DUrlObject .prototype,
|
|
|
37653
37980
|
|
|
37654
37981
|
if (value === Base_X3DConstants .COMPLETE_STATE)
|
|
37655
37982
|
{
|
|
37656
|
-
this [_autoRefreshCompleteTime] =
|
|
37983
|
+
this [_autoRefreshCompleteTime] = Time_Time .now ();
|
|
37657
37984
|
this .setAutoRefreshTimer (this ._autoRefresh .getValue ());
|
|
37658
37985
|
}
|
|
37659
37986
|
|
|
@@ -37797,7 +38124,7 @@ Object .assign (X3DUrlObject .prototype,
|
|
|
37797
38124
|
|
|
37798
38125
|
if (autoRefreshTimeLimit !== 0)
|
|
37799
38126
|
{
|
|
37800
|
-
if ((
|
|
38127
|
+
if ((Time_Time .now () - this [_autoRefreshStartTime]) / 1000 > autoRefreshTimeLimit - autoRefreshInterval)
|
|
37801
38128
|
return;
|
|
37802
38129
|
}
|
|
37803
38130
|
|
|
@@ -37836,7 +38163,7 @@ Object .assign (X3DUrlObject .prototype,
|
|
|
37836
38163
|
return;
|
|
37837
38164
|
|
|
37838
38165
|
const
|
|
37839
|
-
elapsedTime = (
|
|
38166
|
+
elapsedTime = (Time_Time .now () - this [_autoRefreshCompleteTime]) / 1000,
|
|
37840
38167
|
autoRefresh = this ._autoRefresh .getValue ();
|
|
37841
38168
|
|
|
37842
38169
|
let autoRefreshInterval = autoRefresh - elapsedTime;
|
|
@@ -37986,7 +38313,7 @@ const X3DProtoDeclarationNode_default_ = X3DProtoDeclarationNode;
|
|
|
37986
38313
|
x_ite_Namespace .set ("x_ite/Prototype/X3DProtoDeclarationNode", X3DProtoDeclarationNode_default_);
|
|
37987
38314
|
/* harmony default export */ const Prototype_X3DProtoDeclarationNode = (X3DProtoDeclarationNode_default_);
|
|
37988
38315
|
;// CONCATENATED MODULE: ./src/x_ite/Parser/X3DParser.js
|
|
37989
|
-
/* provided dependency */ var $ = __webpack_require__(
|
|
38316
|
+
/* provided dependency */ var $ = __webpack_require__(964);
|
|
37990
38317
|
/*******************************************************************************
|
|
37991
38318
|
*
|
|
37992
38319
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -38810,7 +39137,7 @@ const X3DProtoDeclaration_default_ = X3DProtoDeclaration;
|
|
|
38810
39137
|
x_ite_Namespace .set ("x_ite/Prototype/X3DProtoDeclaration", X3DProtoDeclaration_default_);
|
|
38811
39138
|
/* harmony default export */ const Prototype_X3DProtoDeclaration = (X3DProtoDeclaration_default_);
|
|
38812
39139
|
;// CONCATENATED MODULE: ./src/x_ite/Parser/VRMLParser.js
|
|
38813
|
-
/* provided dependency */ var VRMLParser_$ = __webpack_require__(
|
|
39140
|
+
/* provided dependency */ var VRMLParser_$ = __webpack_require__(964);
|
|
38814
39141
|
/*******************************************************************************
|
|
38815
39142
|
*
|
|
38816
39143
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -41362,7 +41689,7 @@ const VRMLParser_default_ = VRMLParser;
|
|
|
41362
41689
|
x_ite_Namespace .set ("x_ite/Parser/VRMLParser", VRMLParser_default_);
|
|
41363
41690
|
/* harmony default export */ const Parser_VRMLParser = (VRMLParser_default_);
|
|
41364
41691
|
;// CONCATENATED MODULE: ./src/x_ite/Parser/XMLParser.js
|
|
41365
|
-
/* provided dependency */ var XMLParser_$ = __webpack_require__(
|
|
41692
|
+
/* provided dependency */ var XMLParser_$ = __webpack_require__(964);
|
|
41366
41693
|
/*******************************************************************************
|
|
41367
41694
|
*
|
|
41368
41695
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -42387,10 +42714,13 @@ Object .assign (Object .setPrototypeOf (XMLParser .prototype, Parser_X3DParser .
|
|
|
42387
42714
|
|
|
42388
42715
|
try
|
|
42389
42716
|
{
|
|
42390
|
-
const containerField = xmlElement .getAttribute ("containerField") || node ?.getContainerField ();
|
|
42717
|
+
const containerField = xmlElement .getAttribute ("containerField") || node ?.getContainerField (true);
|
|
42391
42718
|
|
|
42392
42719
|
if (!containerField)
|
|
42393
|
-
|
|
42720
|
+
{
|
|
42721
|
+
console .warn ("Node must have a container field attribute.");
|
|
42722
|
+
return;
|
|
42723
|
+
}
|
|
42394
42724
|
|
|
42395
42725
|
const field = parent .getField (containerField);
|
|
42396
42726
|
|
|
@@ -42408,6 +42738,13 @@ Object .assign (Object .setPrototypeOf (XMLParser .prototype, Parser_X3DParser .
|
|
|
42408
42738
|
catch (error)
|
|
42409
42739
|
{
|
|
42410
42740
|
// console .error (error);
|
|
42741
|
+
|
|
42742
|
+
if (node ?.getType () .includes (Base_X3DConstants .X3DMetadataObject))
|
|
42743
|
+
{
|
|
42744
|
+
xmlElement .setAttribute ("containerField", "metadata");
|
|
42745
|
+
|
|
42746
|
+
this .addNode (xmlElement, node);
|
|
42747
|
+
}
|
|
42411
42748
|
}
|
|
42412
42749
|
},
|
|
42413
42750
|
// Overloaded by HTMLParser.
|
|
@@ -43363,7 +43700,7 @@ const URLs_default_ = URLs;
|
|
|
43363
43700
|
x_ite_Namespace .set ("x_ite/Browser/Networking/URLs", URLs_default_);
|
|
43364
43701
|
/* harmony default export */ const Networking_URLs = (URLs_default_);
|
|
43365
43702
|
;// CONCATENATED MODULE: ./src/standard/Math/Geometry/Triangle3.js
|
|
43366
|
-
/* provided dependency */ var libtess = __webpack_require__(
|
|
43703
|
+
/* provided dependency */ var libtess = __webpack_require__(149);
|
|
43367
43704
|
/*******************************************************************************
|
|
43368
43705
|
*
|
|
43369
43706
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -44293,7 +44630,7 @@ const Box3_default_ = Box3;
|
|
|
44293
44630
|
x_ite_Namespace .set ("standard/Math/Geometry/Box3", Box3_default_);
|
|
44294
44631
|
/* harmony default export */ const Geometry_Box3 = (Box3_default_);
|
|
44295
44632
|
;// CONCATENATED MODULE: ./src/x_ite/Parser/GLTF2Parser.js
|
|
44296
|
-
/* provided dependency */ var GLTF2Parser_$ = __webpack_require__(
|
|
44633
|
+
/* provided dependency */ var GLTF2Parser_$ = __webpack_require__(964);
|
|
44297
44634
|
/*******************************************************************************
|
|
44298
44635
|
*
|
|
44299
44636
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -47099,7 +47436,7 @@ const GLTF2Parser_default_ = GLTF2Parser;
|
|
|
47099
47436
|
x_ite_Namespace .set ("x_ite/Parser/GLTF2Parser", GLTF2Parser_default_);
|
|
47100
47437
|
/* harmony default export */ const Parser_GLTF2Parser = (GLTF2Parser_default_);
|
|
47101
47438
|
;// CONCATENATED MODULE: ./src/x_ite/Parser/GLB2Parser.js
|
|
47102
|
-
/* provided dependency */ var GLB2Parser_$ = __webpack_require__(
|
|
47439
|
+
/* provided dependency */ var GLB2Parser_$ = __webpack_require__(964);
|
|
47103
47440
|
/*******************************************************************************
|
|
47104
47441
|
*
|
|
47105
47442
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -47251,7 +47588,7 @@ const GLB2Parser_default_ = GLB2Parser;
|
|
|
47251
47588
|
x_ite_Namespace .set ("x_ite/Parser/GLB2Parser", GLB2Parser_default_);
|
|
47252
47589
|
/* harmony default export */ const Parser_GLB2Parser = (GLB2Parser_default_);
|
|
47253
47590
|
;// CONCATENATED MODULE: ./src/x_ite/Parser/OBJParser.js
|
|
47254
|
-
/* provided dependency */ var OBJParser_$ = __webpack_require__(
|
|
47591
|
+
/* provided dependency */ var OBJParser_$ = __webpack_require__(964);
|
|
47255
47592
|
/*******************************************************************************
|
|
47256
47593
|
*
|
|
47257
47594
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -50606,8 +50943,8 @@ const MatrixStack_default_ = MatrixStack;
|
|
|
50606
50943
|
x_ite_Namespace .set ("standard/Math/Utility/MatrixStack", MatrixStack_default_);
|
|
50607
50944
|
/* harmony default export */ const Utility_MatrixStack = (MatrixStack_default_);
|
|
50608
50945
|
;// CONCATENATED MODULE: ./src/x_ite/Parser/SVGParser.js
|
|
50609
|
-
/* provided dependency */ var SVGParser_$ = __webpack_require__(
|
|
50610
|
-
/* provided dependency */ var SVGParser_libtess = __webpack_require__(
|
|
50946
|
+
/* provided dependency */ var SVGParser_$ = __webpack_require__(964);
|
|
50947
|
+
/* provided dependency */ var SVGParser_libtess = __webpack_require__(149);
|
|
50611
50948
|
/*******************************************************************************
|
|
50612
50949
|
*
|
|
50613
50950
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -53375,7 +53712,7 @@ const SVGParser_default_ = SVGParser;
|
|
|
53375
53712
|
x_ite_Namespace .set ("x_ite/Parser/SVGParser", SVGParser_default_);
|
|
53376
53713
|
/* harmony default export */ const Parser_SVGParser = (SVGParser_default_);
|
|
53377
53714
|
;// CONCATENATED MODULE: ./src/x_ite/Parser/GoldenGate.js
|
|
53378
|
-
/* provided dependency */ var GoldenGate_$ = __webpack_require__(
|
|
53715
|
+
/* provided dependency */ var GoldenGate_$ = __webpack_require__(964);
|
|
53379
53716
|
/*******************************************************************************
|
|
53380
53717
|
*
|
|
53381
53718
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -54194,7 +54531,7 @@ function TextureBuffer (browser, width, height, float = false)
|
|
|
54194
54531
|
{
|
|
54195
54532
|
const gl = browser .getContext ();
|
|
54196
54533
|
|
|
54197
|
-
this .
|
|
54534
|
+
this .context = gl;
|
|
54198
54535
|
this .width = width;
|
|
54199
54536
|
this .height = height;
|
|
54200
54537
|
|
|
@@ -54293,11 +54630,7 @@ Object .assign (TextureBuffer .prototype,
|
|
|
54293
54630
|
},
|
|
54294
54631
|
readPixels ()
|
|
54295
54632
|
{
|
|
54296
|
-
const
|
|
54297
|
-
gl = this .browser .getContext (),
|
|
54298
|
-
array = this .array,
|
|
54299
|
-
width = this .width,
|
|
54300
|
-
height = this .height;
|
|
54633
|
+
const { context: gl, array, width, height } = this;
|
|
54301
54634
|
|
|
54302
54635
|
gl .readPixels (0, 0, width, height, gl .RGBA, gl .UNSIGNED_BYTE, array);
|
|
54303
54636
|
|
|
@@ -54311,11 +54644,7 @@ Object .assign (TextureBuffer .prototype,
|
|
|
54311
54644
|
|
|
54312
54645
|
return function (projectionMatrix, viewport)
|
|
54313
54646
|
{
|
|
54314
|
-
const
|
|
54315
|
-
gl = this .browser .getContext (),
|
|
54316
|
-
array = this .array,
|
|
54317
|
-
width = this .width,
|
|
54318
|
-
height = this .height;
|
|
54647
|
+
const { context: gl, array, width, height } = this;
|
|
54319
54648
|
|
|
54320
54649
|
gl .readPixels (0, 0, width, height, gl .RGBA, gl .FLOAT, array);
|
|
54321
54650
|
|
|
@@ -54348,7 +54677,7 @@ Object .assign (TextureBuffer .prototype,
|
|
|
54348
54677
|
})(),
|
|
54349
54678
|
bind ()
|
|
54350
54679
|
{
|
|
54351
|
-
const gl = this .
|
|
54680
|
+
const gl = this .context;
|
|
54352
54681
|
|
|
54353
54682
|
this .lastBuffer = gl .getParameter (gl .FRAMEBUFFER_BINDING);
|
|
54354
54683
|
|
|
@@ -54356,13 +54685,13 @@ Object .assign (TextureBuffer .prototype,
|
|
|
54356
54685
|
},
|
|
54357
54686
|
unbind ()
|
|
54358
54687
|
{
|
|
54359
|
-
const gl = this .
|
|
54688
|
+
const gl = this .context;
|
|
54360
54689
|
|
|
54361
54690
|
gl .bindFramebuffer (gl .FRAMEBUFFER, this .lastBuffer);
|
|
54362
54691
|
},
|
|
54363
54692
|
delete ()
|
|
54364
54693
|
{
|
|
54365
|
-
const gl = this .
|
|
54694
|
+
const gl = this .context;
|
|
54366
54695
|
|
|
54367
54696
|
gl .deleteFramebuffer (this .frameBuffer);
|
|
54368
54697
|
gl .deleteTexture (this .colorTexture);
|
|
@@ -55079,10 +55408,13 @@ x_ite_Namespace .set ("standard/Time/StopWatch", StopWatch_default_);
|
|
|
55079
55408
|
|
|
55080
55409
|
|
|
55081
55410
|
|
|
55411
|
+
|
|
55082
55412
|
const DEPTH_BUFFER_SIZE = 16;
|
|
55083
55413
|
|
|
55084
55414
|
function X3DRenderObject (executionContext)
|
|
55085
55415
|
{
|
|
55416
|
+
const browser = executionContext .getBrowser ();
|
|
55417
|
+
|
|
55086
55418
|
this .viewVolumes = [ ];
|
|
55087
55419
|
this .cameraSpaceMatrix = new Utility_MatrixStack (Numbers_Matrix4);
|
|
55088
55420
|
this .viewMatrix = new Utility_MatrixStack (Numbers_Matrix4);
|
|
@@ -55119,17 +55451,7 @@ function X3DRenderObject (executionContext)
|
|
|
55119
55451
|
this .transparentShapes = [ ];
|
|
55120
55452
|
this .transparencySorter = new Algorithms_MergeSort (this .transparentShapes, (a, b) => a .distance < b .distance);
|
|
55121
55453
|
this .speed = 0;
|
|
55122
|
-
|
|
55123
|
-
try
|
|
55124
|
-
{
|
|
55125
|
-
this .depthBuffer = new Rendering_TextureBuffer (executionContext .getBrowser (), DEPTH_BUFFER_SIZE, DEPTH_BUFFER_SIZE, true);
|
|
55126
|
-
}
|
|
55127
|
-
catch (error)
|
|
55128
|
-
{
|
|
55129
|
-
console .error (error);
|
|
55130
|
-
|
|
55131
|
-
this .getDepth = function () { return 0; };
|
|
55132
|
-
}
|
|
55454
|
+
this .depthBuffer = new Rendering_TextureBuffer (browser, DEPTH_BUFFER_SIZE, DEPTH_BUFFER_SIZE, true);
|
|
55133
55455
|
}
|
|
55134
55456
|
|
|
55135
55457
|
Object .assign (X3DRenderObject .prototype,
|
|
@@ -55180,6 +55502,10 @@ Object .assign (X3DRenderObject .prototype,
|
|
|
55180
55502
|
{
|
|
55181
55503
|
return this .cameraSpaceMatrixArray;
|
|
55182
55504
|
},
|
|
55505
|
+
getLogarithmicDepthBuffer ()
|
|
55506
|
+
{
|
|
55507
|
+
return this .logarithmicDepthBuffer;
|
|
55508
|
+
},
|
|
55183
55509
|
getHitRay ()
|
|
55184
55510
|
{
|
|
55185
55511
|
return this .hitRay;
|
|
@@ -55731,9 +56057,6 @@ Object .assign (X3DRenderObject .prototype,
|
|
|
55731
56057
|
|
|
55732
56058
|
// Render all objects
|
|
55733
56059
|
|
|
55734
|
-
gl .depthMask (true);
|
|
55735
|
-
gl .enable (gl .DEPTH_TEST);
|
|
55736
|
-
gl .disable (gl .BLEND);
|
|
55737
56060
|
gl .disable (gl .CULL_FACE);
|
|
55738
56061
|
|
|
55739
56062
|
for (let s = 0; s < numShapes; ++ s)
|
|
@@ -55970,9 +56293,6 @@ Object .assign (X3DRenderObject .prototype,
|
|
|
55970
56293
|
|
|
55971
56294
|
// Render all objects
|
|
55972
56295
|
|
|
55973
|
-
gl .depthMask (true);
|
|
55974
|
-
gl .enable (gl .DEPTH_TEST);
|
|
55975
|
-
gl .disable (gl .BLEND);
|
|
55976
56296
|
gl .disable (gl .CULL_FACE);
|
|
55977
56297
|
|
|
55978
56298
|
for (let s = 0; s < numShapes; ++ s)
|
|
@@ -56017,10 +56337,14 @@ Object .assign (X3DRenderObject .prototype,
|
|
|
56017
56337
|
shadows = globalShadows .at (-1),
|
|
56018
56338
|
headlight = this .getNavigationInfo () ._headlight .getValue (),
|
|
56019
56339
|
numGlobalLights = globalObjects .reduce ((n, c) => n + !!c .lightNode, 0),
|
|
56020
|
-
numGlobalTextureProjectors = globalObjects .reduce ((n, c) => n + !!c .textureProjectorNode, 0)
|
|
56340
|
+
numGlobalTextureProjectors = globalObjects .reduce ((n, c) => n + !!c .textureProjectorNode, 0),
|
|
56341
|
+
oit = browser .getFrameBuffer () .getOrderIndependentTransparency ();
|
|
56342
|
+
|
|
56021
56343
|
|
|
56344
|
+
this .renderTime = Time_Time .now ();
|
|
56022
56345
|
|
|
56023
|
-
this .
|
|
56346
|
+
this .logarithmicDepthBuffer = browser .getBrowserOption ("LogarithmicDepthBuffer")
|
|
56347
|
+
|| this .getViewpoint () .getLogarithmicDepthBuffer ();
|
|
56024
56348
|
|
|
56025
56349
|
|
|
56026
56350
|
// PREPARATIONS
|
|
@@ -56068,17 +56392,14 @@ Object .assign (X3DRenderObject .prototype,
|
|
|
56068
56392
|
// Draw background.
|
|
56069
56393
|
|
|
56070
56394
|
gl .clear (gl .DEPTH_BUFFER_BIT);
|
|
56395
|
+
gl .blendFuncSeparate (gl .SRC_ALPHA, gl .ONE_MINUS_SRC_ALPHA, gl .ONE, gl .ONE_MINUS_SRC_ALPHA);
|
|
56071
56396
|
|
|
56072
56397
|
this .getBackground () .display (gl, this, viewport);
|
|
56073
56398
|
|
|
56074
|
-
// Sorted blend
|
|
56399
|
+
// Sorted blend or order independent transparency
|
|
56075
56400
|
|
|
56076
56401
|
// Render opaque objects first
|
|
56077
56402
|
|
|
56078
|
-
gl .depthMask (true);
|
|
56079
|
-
gl .enable (gl .DEPTH_TEST);
|
|
56080
|
-
gl .disable (gl .BLEND);
|
|
56081
|
-
|
|
56082
56403
|
const opaqueShapes = this .opaqueShapes;
|
|
56083
56404
|
|
|
56084
56405
|
for (let i = 0, length = this .numOpaqueShapes; i < length; ++ i)
|
|
@@ -56097,12 +56418,15 @@ Object .assign (X3DRenderObject .prototype,
|
|
|
56097
56418
|
|
|
56098
56419
|
// Render transparent objects
|
|
56099
56420
|
|
|
56100
|
-
gl .depthMask (false);
|
|
56101
|
-
gl .enable (gl .BLEND);
|
|
56102
|
-
|
|
56103
56421
|
const transparentShapes = this .transparentShapes;
|
|
56104
56422
|
|
|
56105
|
-
|
|
56423
|
+
if (oit)
|
|
56424
|
+
browser .getFrameBuffer () .bindForOrderIndependentTransparency ();
|
|
56425
|
+
else
|
|
56426
|
+
this .transparencySorter .sort (0, this .numTransparentShapes);
|
|
56427
|
+
|
|
56428
|
+
gl .depthMask (false);
|
|
56429
|
+
gl .enable (gl .BLEND);
|
|
56106
56430
|
|
|
56107
56431
|
for (let i = 0, length = this .numTransparentShapes; i < length; ++ i)
|
|
56108
56432
|
{
|
|
@@ -56121,6 +56445,11 @@ Object .assign (X3DRenderObject .prototype,
|
|
|
56121
56445
|
gl .depthMask (true);
|
|
56122
56446
|
gl .disable (gl .BLEND);
|
|
56123
56447
|
|
|
56448
|
+
if (oit)
|
|
56449
|
+
{
|
|
56450
|
+
browser .getFrameBuffer () .compose ();
|
|
56451
|
+
browser .getFrameBuffer () .unbind ();
|
|
56452
|
+
}
|
|
56124
56453
|
|
|
56125
56454
|
// POST DRAW
|
|
56126
56455
|
|
|
@@ -56508,7 +56837,7 @@ Object .assign (Object .setPrototypeOf (BindableList .prototype, Base_X3DBaseNod
|
|
|
56508
56837
|
|
|
56509
56838
|
// Advance updateTime time.
|
|
56510
56839
|
|
|
56511
|
-
this .updateTime =
|
|
56840
|
+
this .updateTime = Time_Time .now ();
|
|
56512
56841
|
},
|
|
56513
56842
|
});
|
|
56514
56843
|
|
|
@@ -58406,10 +58735,11 @@ Object .assign (Object .setPrototypeOf (X3DGeometryNode .prototype, Core_X3DNode
|
|
|
58406
58735
|
display (gl, renderContext)
|
|
58407
58736
|
{
|
|
58408
58737
|
const
|
|
58738
|
+
browser = this .getBrowser (),
|
|
58409
58739
|
appearanceNode = renderContext .appearanceNode,
|
|
58410
58740
|
shaderNode = appearanceNode .getShader (this, renderContext);
|
|
58411
58741
|
|
|
58412
|
-
if (this .solid || !appearanceNode .getBackMaterial () ||
|
|
58742
|
+
if (this .solid || !appearanceNode .getBackMaterial () || browser .getWireframe ())
|
|
58413
58743
|
{
|
|
58414
58744
|
this .displayGeometry (gl, renderContext, appearanceNode, shaderNode, true, true);
|
|
58415
58745
|
}
|
|
@@ -58528,10 +58858,11 @@ Object .assign (Object .setPrototypeOf (X3DGeometryNode .prototype, Core_X3DNode
|
|
|
58528
58858
|
displayParticles (gl, renderContext, particleSystem)
|
|
58529
58859
|
{
|
|
58530
58860
|
const
|
|
58861
|
+
browser = this .getBrowser (),
|
|
58531
58862
|
appearanceNode = renderContext .appearanceNode,
|
|
58532
58863
|
shaderNode = appearanceNode .getShader (this, renderContext);
|
|
58533
58864
|
|
|
58534
|
-
if (this .solid || !appearanceNode .getBackMaterial () ||
|
|
58865
|
+
if (this .solid || !appearanceNode .getBackMaterial () || browser .getWireframe ())
|
|
58535
58866
|
{
|
|
58536
58867
|
this .displayParticlesGeometry (gl, renderContext, appearanceNode, shaderNode, true, true, particleSystem);
|
|
58537
58868
|
}
|
|
@@ -59387,8 +59718,8 @@ Object .assign (Object .setPrototypeOf (X3DBackgroundNode .prototype, Core_X3DBi
|
|
|
59387
59718
|
|
|
59388
59719
|
// Setup context.
|
|
59389
59720
|
|
|
59390
|
-
gl .depthMask (false);
|
|
59391
59721
|
gl .disable (gl .DEPTH_TEST);
|
|
59722
|
+
gl .depthMask (false);
|
|
59392
59723
|
gl .enable (gl .CULL_FACE);
|
|
59393
59724
|
gl .frontFace (gl .CCW);
|
|
59394
59725
|
|
|
@@ -59413,6 +59744,10 @@ Object .assign (Object .setPrototypeOf (X3DBackgroundNode .prototype, Core_X3DBi
|
|
|
59413
59744
|
|
|
59414
59745
|
if (+this .textureBits)
|
|
59415
59746
|
this .drawCube (renderObject);
|
|
59747
|
+
|
|
59748
|
+
gl .depthMask (true);
|
|
59749
|
+
gl .enable (gl .DEPTH_TEST);
|
|
59750
|
+
gl .disable (gl .BLEND);
|
|
59416
59751
|
};
|
|
59417
59752
|
})(),
|
|
59418
59753
|
drawSphere (renderObject)
|
|
@@ -60162,7 +60497,7 @@ const X3DTexture2DNode_default_ = X3DTexture2DNode;
|
|
|
60162
60497
|
x_ite_Namespace .set ("x_ite/Components/Texturing/X3DTexture2DNode", X3DTexture2DNode_default_);
|
|
60163
60498
|
/* harmony default export */ const Texturing_X3DTexture2DNode = (X3DTexture2DNode_default_);
|
|
60164
60499
|
;// CONCATENATED MODULE: ./src/x_ite/Components/Texturing/ImageTexture.js
|
|
60165
|
-
/* provided dependency */ var ImageTexture_$ = __webpack_require__(
|
|
60500
|
+
/* provided dependency */ var ImageTexture_$ = __webpack_require__(964);
|
|
60166
60501
|
/*******************************************************************************
|
|
60167
60502
|
*
|
|
60168
60503
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -60219,6 +60554,7 @@ x_ite_Namespace .set ("x_ite/Components/Texturing/X3DTexture2DNode", X3DTexture2
|
|
|
60219
60554
|
|
|
60220
60555
|
|
|
60221
60556
|
|
|
60557
|
+
|
|
60222
60558
|
function ImageTexture (executionContext)
|
|
60223
60559
|
{
|
|
60224
60560
|
Texturing_X3DTexture2DNode .call (this, executionContext);
|
|
@@ -60273,7 +60609,7 @@ Object .assign (Object .setPrototypeOf (ImageTexture .prototype, Texturing_X3DTe
|
|
|
60273
60609
|
if (this .URL .protocol !== "data:")
|
|
60274
60610
|
{
|
|
60275
60611
|
if (!this .getCache ())
|
|
60276
|
-
this .URL .searchParams .set ("_",
|
|
60612
|
+
this .URL .searchParams .set ("_", Time_Time .now ());
|
|
60277
60613
|
}
|
|
60278
60614
|
|
|
60279
60615
|
this .image .attr ("src", this .URL .href);
|
|
@@ -61168,6 +61504,7 @@ x_ite_Namespace .set ("x_ite/Components/Core/X3DSensorNode", X3DSensorNode_defau
|
|
|
61168
61504
|
|
|
61169
61505
|
|
|
61170
61506
|
|
|
61507
|
+
|
|
61171
61508
|
function X3DTimeDependentNode (executionContext)
|
|
61172
61509
|
{
|
|
61173
61510
|
this .addType (Base_X3DConstants .X3DTimeDependentNode);
|
|
@@ -61236,13 +61573,13 @@ Object .assign (Object .setPrototypeOf (X3DTimeDependentNode .prototype, Core_X3
|
|
|
61236
61573
|
{
|
|
61237
61574
|
this .disabled = false;
|
|
61238
61575
|
|
|
61239
|
-
if (this ._isActive .getValue () && !
|
|
61576
|
+
if (this ._isActive .getValue () && !this ._isPaused .getValue ())
|
|
61240
61577
|
this .real_resume ();
|
|
61241
61578
|
}
|
|
61242
61579
|
}
|
|
61243
61580
|
else
|
|
61244
61581
|
{
|
|
61245
|
-
if (!
|
|
61582
|
+
if (!this .disabled && this ._isActive .getValue () && !this ._isPaused .getValue ())
|
|
61246
61583
|
{
|
|
61247
61584
|
// Only disable if needed, ie. if running!
|
|
61248
61585
|
this .disabled = true;
|
|
@@ -61382,7 +61719,7 @@ Object .assign (Object .setPrototypeOf (X3DTimeDependentNode .prototype, Core_X3
|
|
|
61382
61719
|
},
|
|
61383
61720
|
real_pause ()
|
|
61384
61721
|
{
|
|
61385
|
-
this .pause =
|
|
61722
|
+
this .pause = Time_Time .now ();
|
|
61386
61723
|
|
|
61387
61724
|
this .set_pause ();
|
|
61388
61725
|
|
|
@@ -61403,7 +61740,7 @@ Object .assign (Object .setPrototypeOf (X3DTimeDependentNode .prototype, Core_X3
|
|
|
61403
61740
|
},
|
|
61404
61741
|
real_resume ()
|
|
61405
61742
|
{
|
|
61406
|
-
const interval = (
|
|
61743
|
+
const interval = (Time_Time .now () - this .pause) / 1000;
|
|
61407
61744
|
|
|
61408
61745
|
this .pauseInterval += interval;
|
|
61409
61746
|
|
|
@@ -61574,52 +61911,53 @@ Object .assign (Object .setPrototypeOf (TimeSensor .prototype, Core_X3DSensorNod
|
|
|
61574
61911
|
this ._cycleInterval .addInterest ("set_cycleInterval__", this);
|
|
61575
61912
|
this ._range .addInterest ("set_range__", this);
|
|
61576
61913
|
},
|
|
61577
|
-
setRange (
|
|
61914
|
+
setRange (fraction, firstFraction, lastFraction, offset)
|
|
61578
61915
|
{
|
|
61579
61916
|
const
|
|
61580
61917
|
currentTime = this .getBrowser () .getCurrentTime (),
|
|
61581
61918
|
startTime = this ._startTime .getValue (),
|
|
61582
61919
|
cycleInterval = this ._cycleInterval .getValue ();
|
|
61583
61920
|
|
|
61584
|
-
this .first = firstFraction;
|
|
61585
|
-
this .last = lastFraction;
|
|
61921
|
+
this .first = Math_Algorithm .clamp (firstFraction, 0, 1);
|
|
61922
|
+
this .last = Math_Algorithm .clamp (lastFraction, 0, 1);
|
|
61586
61923
|
this .scale = this .last - this .first;
|
|
61587
61924
|
this .interval = cycleInterval * this .scale;
|
|
61588
|
-
this .
|
|
61589
|
-
this .
|
|
61925
|
+
this .offset = offset && this .interval ? (currentTime - startTime) / this .interval : 0;
|
|
61926
|
+
this .fraction = Math_Algorithm .fract (fraction + this .offset);
|
|
61927
|
+
this .cycle = currentTime - (this .fraction - this .first) * cycleInterval;
|
|
61590
61928
|
},
|
|
61591
61929
|
set_cycleInterval__ ()
|
|
61592
61930
|
{
|
|
61593
|
-
if (this ._isActive .getValue ())
|
|
61594
|
-
|
|
61931
|
+
if (!this ._isActive .getValue ())
|
|
61932
|
+
return;
|
|
61933
|
+
|
|
61934
|
+
this .setRange (this .fraction, this ._range [1], this ._range [2], false);
|
|
61595
61935
|
},
|
|
61596
61936
|
set_range__ ()
|
|
61597
61937
|
{
|
|
61598
|
-
if (this ._isActive .getValue ())
|
|
61599
|
-
|
|
61600
|
-
this .setRange (this ._range [0], this ._range [1], this ._range [2]);
|
|
61938
|
+
if (!this ._isActive .getValue ())
|
|
61939
|
+
return;
|
|
61601
61940
|
|
|
61602
|
-
|
|
61603
|
-
|
|
61604
|
-
|
|
61941
|
+
this .setRange (this ._range [0], this ._range [1], this ._range [2], false);
|
|
61942
|
+
|
|
61943
|
+
if (this ._isPaused .getValue ())
|
|
61944
|
+
return;
|
|
61945
|
+
|
|
61946
|
+
this .set_fraction (this .getBrowser () .getCurrentTime ());
|
|
61605
61947
|
},
|
|
61606
61948
|
set_start ()
|
|
61607
61949
|
{
|
|
61608
|
-
this .setRange (this ._range [0], this ._range [1], this ._range [2]);
|
|
61950
|
+
this .setRange (this ._range [0], this ._range [1], this ._range [2], true);
|
|
61609
61951
|
|
|
61610
|
-
|
|
61611
|
-
|
|
61612
|
-
|
|
61613
|
-
|
|
61614
|
-
|
|
61952
|
+
const time = this .getBrowser () .getCurrentTime ();
|
|
61953
|
+
|
|
61954
|
+
this ._cycleTime = time;
|
|
61955
|
+
this ._fraction_changed = this .fraction;
|
|
61956
|
+
this ._time = time;
|
|
61615
61957
|
},
|
|
61616
61958
|
set_resume (pauseInterval)
|
|
61617
61959
|
{
|
|
61618
|
-
|
|
61619
|
-
currentTime = this .getBrowser () .getCurrentTime (),
|
|
61620
|
-
startTime = this ._startTime .getValue ();
|
|
61621
|
-
|
|
61622
|
-
this .setRange (this .interval ? Math_Algorithm .fract (this .fraction - (currentTime - startTime) / this .interval) : 0, this ._range [1], this ._range [2]);
|
|
61960
|
+
this .setRange (this .fraction, this ._range [1], this ._range [2], false);
|
|
61623
61961
|
},
|
|
61624
61962
|
set_fraction (time)
|
|
61625
61963
|
{
|
|
@@ -63656,6 +63994,7 @@ Object .assign (Object .setPrototypeOf (X3DGroupingNode .prototype, Core_X3DChil
|
|
|
63656
63994
|
}
|
|
63657
63995
|
case Base_X3DConstants .BooleanFilter:
|
|
63658
63996
|
case Base_X3DConstants .BooleanToggle:
|
|
63997
|
+
case Base_X3DConstants .HAnimMotion:
|
|
63659
63998
|
case Base_X3DConstants .NurbsOrientationInterpolator:
|
|
63660
63999
|
case Base_X3DConstants .NurbsPositionInterpolator:
|
|
63661
64000
|
case Base_X3DConstants .NurbsSurfaceInterpolator:
|
|
@@ -63794,6 +64133,7 @@ Object .assign (Object .setPrototypeOf (X3DGroupingNode .prototype, Core_X3DChil
|
|
|
63794
64133
|
}
|
|
63795
64134
|
case Base_X3DConstants .BooleanFilter:
|
|
63796
64135
|
case Base_X3DConstants .BooleanToggle:
|
|
64136
|
+
case Base_X3DConstants .HAnimMotion:
|
|
63797
64137
|
case Base_X3DConstants .NurbsOrientationInterpolator:
|
|
63798
64138
|
case Base_X3DConstants .NurbsPositionInterpolator:
|
|
63799
64139
|
case Base_X3DConstants .NurbsSurfaceInterpolator:
|
|
@@ -64701,7 +65041,7 @@ const X3DWorld_default_ = X3DWorld;
|
|
|
64701
65041
|
x_ite_Namespace .set ("x_ite/Execution/X3DWorld", X3DWorld_default_);
|
|
64702
65042
|
/* harmony default export */ const Execution_X3DWorld = (X3DWorld_default_);
|
|
64703
65043
|
;// CONCATENATED MODULE: ./src/x_ite/InputOutput/FileLoader.js
|
|
64704
|
-
/* provided dependency */ var FileLoader_$ = __webpack_require__(
|
|
65044
|
+
/* provided dependency */ var FileLoader_$ = __webpack_require__(964);
|
|
64705
65045
|
/*******************************************************************************
|
|
64706
65046
|
*
|
|
64707
65047
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -67161,6 +67501,10 @@ Object .assign (Object .setPrototypeOf (X3DPrototypeInstance .prototype, Core_X3
|
|
|
67161
67501
|
protoNode = this [_protoNode],
|
|
67162
67502
|
proto = protoNode .getProtoDeclaration ();
|
|
67163
67503
|
|
|
67504
|
+
// Assign field definitions.
|
|
67505
|
+
|
|
67506
|
+
this [X3DPrototypeInstance_fieldDefinitions] .assign (protoNode .getFieldDefinitions ());
|
|
67507
|
+
|
|
67164
67508
|
// If there is a proto, the externproto is completely loaded.
|
|
67165
67509
|
|
|
67166
67510
|
if (protoNode .isExternProto)
|
|
@@ -67240,10 +67584,6 @@ Object .assign (Object .setPrototypeOf (X3DPrototypeInstance .prototype, Core_X3
|
|
|
67240
67584
|
},
|
|
67241
67585
|
update ()
|
|
67242
67586
|
{
|
|
67243
|
-
// Assign field definitions.
|
|
67244
|
-
|
|
67245
|
-
this [X3DPrototypeInstance_fieldDefinitions] .assign (this [_protoNode] .getFieldDefinitions ());
|
|
67246
|
-
|
|
67247
67587
|
// Remove old fields.
|
|
67248
67588
|
|
|
67249
67589
|
const
|
|
@@ -67257,7 +67597,7 @@ Object .assign (Object .setPrototypeOf (X3DPrototypeInstance .prototype, Core_X3
|
|
|
67257
67597
|
|
|
67258
67598
|
this [_protoFields] = new Map (Array .from (this [_protoNode] .getUserDefinedFields (), f => [f, f .getName ()]));
|
|
67259
67599
|
|
|
67260
|
-
for (const fieldDefinition of this .getFieldDefinitions ())
|
|
67600
|
+
for (const fieldDefinition of this [_protoNode] .getFieldDefinitions ())
|
|
67261
67601
|
this .addPredefinedField (fieldDefinition);
|
|
67262
67602
|
|
|
67263
67603
|
// Reuse old fields, and therefor routes.
|
|
@@ -67273,6 +67613,9 @@ Object .assign (Object .setPrototypeOf (X3DPrototypeInstance .prototype, Core_X3
|
|
|
67273
67613
|
newField = this .getPredefinedFields () .get (protoField .getName ()),
|
|
67274
67614
|
oldField = oldFields .get (oldFieldName);
|
|
67275
67615
|
|
|
67616
|
+
if (!oldField)
|
|
67617
|
+
continue;
|
|
67618
|
+
|
|
67276
67619
|
oldField .addParent (this);
|
|
67277
67620
|
oldField .setAccessType (newField .getAccessType ());
|
|
67278
67621
|
oldField .setName (newField .getName ());
|
|
@@ -67315,7 +67658,7 @@ Object .assign (Object .setPrototypeOf (X3DPrototypeInstance .prototype, Core_X3
|
|
|
67315
67658
|
|
|
67316
67659
|
protoNode ._name_changed .addFieldInterest (this ._typeName_changed);
|
|
67317
67660
|
|
|
67318
|
-
this .construct ();
|
|
67661
|
+
protoNode === oldProtoNode ? this .construct () : this .update ();
|
|
67319
67662
|
},
|
|
67320
67663
|
getBody ()
|
|
67321
67664
|
{
|
|
@@ -79141,9 +79484,7 @@ Object .assign (DirectionalLightContainer .prototype,
|
|
|
79141
79484
|
if (this .shadowBuffer)
|
|
79142
79485
|
{
|
|
79143
79486
|
const textureUnit = this .global
|
|
79144
|
-
? (this .textureUnit = this .textureUnit
|
|
79145
|
-
? this .textureUnit
|
|
79146
|
-
: this .browser .popTexture2DUnit ())
|
|
79487
|
+
? (this .textureUnit = this .textureUnit ?? this .browser .popTexture2DUnit ())
|
|
79147
79488
|
: this .browser .getTexture2DUnit ();
|
|
79148
79489
|
|
|
79149
79490
|
if (textureUnit !== undefined)
|
|
@@ -79633,9 +79974,7 @@ Object .assign (PointLightContainer .prototype,
|
|
|
79633
79974
|
if (this .shadowBuffer)
|
|
79634
79975
|
{
|
|
79635
79976
|
const textureUnit = this .global
|
|
79636
|
-
? (this .textureUnit = this .textureUnit
|
|
79637
|
-
? this .textureUnit
|
|
79638
|
-
: this .browser .popTexture2DUnit ())
|
|
79977
|
+
? (this .textureUnit = this .textureUnit ?? this .browser .popTexture2DUnit ())
|
|
79639
79978
|
: this .browser .getTexture2DUnit ();
|
|
79640
79979
|
|
|
79641
79980
|
if (textureUnit !== undefined)
|
|
@@ -79968,9 +80307,7 @@ Object .assign (SpotLightContainer .prototype,
|
|
|
79968
80307
|
if (this .shadowBuffer)
|
|
79969
80308
|
{
|
|
79970
80309
|
const textureUnit = this .global
|
|
79971
|
-
? (this .textureUnit = this .textureUnit
|
|
79972
|
-
? this .textureUnit
|
|
79973
|
-
: this .browser .popTexture2DUnit ())
|
|
80310
|
+
? (this .textureUnit = this .textureUnit ?? this .browser .popTexture2DUnit ())
|
|
79974
80311
|
: this .browser .getTexture2DUnit ();
|
|
79975
80312
|
|
|
79976
80313
|
if (textureUnit !== undefined)
|
|
@@ -88352,7 +88689,7 @@ const X3DShaderNode_default_ = X3DShaderNode;
|
|
|
88352
88689
|
x_ite_Namespace .set ("x_ite/Components/Shaders/X3DShaderNode", X3DShaderNode_default_);
|
|
88353
88690
|
/* harmony default export */ const Shaders_X3DShaderNode = (X3DShaderNode_default_);
|
|
88354
88691
|
;// CONCATENATED MODULE: ./src/x_ite/Components/Shaders/X3DProgrammableShaderObject.js
|
|
88355
|
-
/* provided dependency */ var X3DProgrammableShaderObject_$ = __webpack_require__(
|
|
88692
|
+
/* provided dependency */ var X3DProgrammableShaderObject_$ = __webpack_require__(964);
|
|
88356
88693
|
/*******************************************************************************
|
|
88357
88694
|
*
|
|
88358
88695
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -88717,7 +89054,7 @@ Object .assign (X3DProgrammableShaderObject .prototype,
|
|
|
88717
89054
|
gl .uniform1i (uniform, browser .getDefaultTexture2DUnit ());
|
|
88718
89055
|
|
|
88719
89056
|
gl .uniform1i (this .x3d_TexCoordRamp, browser .getDefaultTexture2DUnit ());
|
|
88720
|
-
gl .uniform1i (this .
|
|
89057
|
+
gl .uniform1i (this .x3d_JointsTexture, browser .getDefaultTexture2DUnit ());
|
|
88721
89058
|
gl .uniform1i (this .x3d_DisplacementsTexture, browser .getDefaultTexture2DUnit ());
|
|
88722
89059
|
gl .uniform1i (this .x3d_JointMatricesTexture, browser .getDefaultTexture2DUnit ());
|
|
88723
89060
|
},
|
|
@@ -90783,7 +91120,9 @@ struct x3d_LinePropertiesParameters
|
|
|
90783
91120
|
{
|
|
90784
91121
|
mediump int linetype;
|
|
90785
91122
|
mediump float lineStippleScale;
|
|
91123
|
+
#if defined (X3D_STYLE_PROPERTIES_TEXTURE)
|
|
90786
91124
|
sampler2D texture;
|
|
91125
|
+
#endif
|
|
90787
91126
|
};
|
|
90788
91127
|
#endif
|
|
90789
91128
|
|
|
@@ -90795,7 +91134,9 @@ struct x3d_FillPropertiesParameters
|
|
|
90795
91134
|
bool filled;
|
|
90796
91135
|
bool hatched;
|
|
90797
91136
|
mediump vec3 hatchColor;
|
|
91137
|
+
#if defined (X3D_STYLE_PROPERTIES_TEXTURE)
|
|
90798
91138
|
sampler2D texture;
|
|
91139
|
+
#endif
|
|
90799
91140
|
mediump float scale;
|
|
90800
91141
|
};
|
|
90801
91142
|
#endif
|
|
@@ -91769,13 +92110,12 @@ getHatchColor (vec4 color)
|
|
|
91769
92110
|
{
|
|
91770
92111
|
vec4 finalColor = x3d_FillProperties .filled ? color : vec4 (0.0);
|
|
91771
92112
|
|
|
91772
|
-
if (
|
|
91773
|
-
{
|
|
92113
|
+
#if defined (X3D_STYLE_PROPERTIES_TEXTURE)
|
|
91774
92114
|
vec4 hatch = texture2D (x3d_FillProperties .texture, gl_FragCoord .xy / (32.0 * x3d_FillProperties .scale));
|
|
91775
92115
|
|
|
91776
92116
|
hatch .rgb *= x3d_FillProperties .hatchColor;
|
|
91777
92117
|
finalColor = mix (finalColor, hatch, hatch .a);
|
|
91778
|
-
|
|
92118
|
+
#endif
|
|
91779
92119
|
|
|
91780
92120
|
return finalColor;
|
|
91781
92121
|
}
|
|
@@ -93239,7 +93579,12 @@ in vec3 vertex;
|
|
|
93239
93579
|
in float depth;
|
|
93240
93580
|
#endif
|
|
93241
93581
|
|
|
93242
|
-
|
|
93582
|
+
#if defined (X3D_ORDER_INDEPENDENT_TRANSPARENCY)
|
|
93583
|
+
layout(location = 0) out vec4 x3d_FragData0;
|
|
93584
|
+
layout(location = 1) out vec4 x3d_FragData1;
|
|
93585
|
+
#else
|
|
93586
|
+
out vec4 x3d_FragColor;
|
|
93587
|
+
#endif
|
|
93243
93588
|
|
|
93244
93589
|
#pragma X3D include "Texture.glsl"
|
|
93245
93590
|
#pragma X3D include "ClipPlanes.glsl"
|
|
@@ -93251,6 +93596,14 @@ out vec4 x3d_FragColor;
|
|
|
93251
93596
|
vec4
|
|
93252
93597
|
getMaterialColor ();
|
|
93253
93598
|
|
|
93599
|
+
#if defined (X3D_ORDER_INDEPENDENT_TRANSPARENCY)
|
|
93600
|
+
float
|
|
93601
|
+
weight (const in float z, const in float a)
|
|
93602
|
+
{
|
|
93603
|
+
return clamp (pow (min (1.0, a * 10.0) + 0.01, 3.0) * 1e8 * pow (1.0 - z * 0.9, 3.0), 1e-2, 3e3);
|
|
93604
|
+
}
|
|
93605
|
+
#endif
|
|
93606
|
+
|
|
93254
93607
|
void
|
|
93255
93608
|
fragment_main ()
|
|
93256
93609
|
{
|
|
@@ -93293,7 +93646,16 @@ fragment_main ()
|
|
|
93293
93646
|
finalColor .a = 1.0;
|
|
93294
93647
|
#endif
|
|
93295
93648
|
|
|
93296
|
-
|
|
93649
|
+
#if defined (X3D_ORDER_INDEPENDENT_TRANSPARENCY)
|
|
93650
|
+
float w = weight (gl_FragCoord .z, finalColor .a);
|
|
93651
|
+
|
|
93652
|
+
finalColor.rgb *= finalColor .a;
|
|
93653
|
+
|
|
93654
|
+
x3d_FragData0 = vec4 (finalColor .rgb * w, finalColor .a);
|
|
93655
|
+
x3d_FragData1 = vec4 (finalColor .a * w);
|
|
93656
|
+
#else
|
|
93657
|
+
x3d_FragColor = finalColor;
|
|
93658
|
+
#endif
|
|
93297
93659
|
|
|
93298
93660
|
#if defined (X3D_LOGARITHMIC_DEPTH_BUFFER)
|
|
93299
93661
|
//https://outerra.blogspot.com/2013/07/logarithmic-depth-buffer-optimizations.html
|
|
@@ -93316,13 +93678,12 @@ getHatchColor (vec4 color)
|
|
|
93316
93678
|
{
|
|
93317
93679
|
vec4 finalColor = x3d_FillProperties .filled ? color : vec4 (0.0);
|
|
93318
93680
|
|
|
93319
|
-
if (
|
|
93320
|
-
{
|
|
93681
|
+
#if defined (X3D_STYLE_PROPERTIES_TEXTURE)
|
|
93321
93682
|
vec4 hatch = texture (x3d_FillProperties .texture, gl_FragCoord .xy / (32.0 * x3d_FillProperties .scale));
|
|
93322
93683
|
|
|
93323
93684
|
hatch .rgb *= x3d_FillProperties .hatchColor;
|
|
93324
93685
|
finalColor = mix (finalColor, hatch, hatch .a);
|
|
93325
|
-
|
|
93686
|
+
#endif
|
|
93326
93687
|
|
|
93327
93688
|
return finalColor;
|
|
93328
93689
|
}
|
|
@@ -94078,6 +94439,25 @@ getSkinNormal (const in vec3)
|
|
|
94078
94439
|
|
|
94079
94440
|
x_ite_Namespace .set ("assets/shaders/webgl2/include/Skin.glsl", Skin_glsl_default_);
|
|
94080
94441
|
/* harmony default export */ const Skin_glsl = (Skin_glsl_default_);
|
|
94442
|
+
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/include/SpotFactor.glsl.js
|
|
94443
|
+
const include_SpotFactor_glsl_default_ = /* glsl */ `
|
|
94444
|
+
float
|
|
94445
|
+
getSpotFactor (const in float cutOffAngle, const in float beamWidth, const in vec3 L, const in vec3 d)
|
|
94446
|
+
{
|
|
94447
|
+
float spotAngle = acos (clamp (dot (-L, d), -1.0, 1.0));
|
|
94448
|
+
|
|
94449
|
+
if (spotAngle >= cutOffAngle)
|
|
94450
|
+
return 0.0;
|
|
94451
|
+
else if (spotAngle <= beamWidth)
|
|
94452
|
+
return 1.0;
|
|
94453
|
+
|
|
94454
|
+
return (spotAngle - cutOffAngle) / (beamWidth - cutOffAngle);
|
|
94455
|
+
}
|
|
94456
|
+
`;
|
|
94457
|
+
;
|
|
94458
|
+
|
|
94459
|
+
x_ite_Namespace .set ("assets/shaders/webgl2/include/SpotFactor.glsl", include_SpotFactor_glsl_default_);
|
|
94460
|
+
/* harmony default export */ const include_SpotFactor_glsl = (include_SpotFactor_glsl_default_);
|
|
94081
94461
|
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/include/Stipple.glsl.js
|
|
94082
94462
|
const Stipple_glsl_default_ = /* glsl */ `
|
|
94083
94463
|
#if defined (X3D_GEOMETRY_1D) && defined (X3D_STYLE_PROPERTIES)
|
|
@@ -94106,8 +94486,10 @@ stipple ()
|
|
|
94106
94486
|
#endif
|
|
94107
94487
|
#endif
|
|
94108
94488
|
|
|
94109
|
-
if (
|
|
94110
|
-
|
|
94489
|
+
#if defined (X3D_STYLE_PROPERTIES_TEXTURE)
|
|
94490
|
+
if (x3d_LineProperties .linetype == 16)
|
|
94491
|
+
return;
|
|
94492
|
+
|
|
94111
94493
|
int linetype = x3d_LineProperties .linetype;
|
|
94112
94494
|
int height = textureSize (x3d_LineProperties .texture, 0) .y;
|
|
94113
94495
|
float t = 1.0 - float (linetype * 2 + 1) / float (height * 2);
|
|
@@ -94115,7 +94497,7 @@ stipple ()
|
|
|
94115
94497
|
|
|
94116
94498
|
if (alpha != 1.0)
|
|
94117
94499
|
discard;
|
|
94118
|
-
|
|
94500
|
+
#endif
|
|
94119
94501
|
}
|
|
94120
94502
|
|
|
94121
94503
|
#endif
|
|
@@ -94124,25 +94506,6 @@ stipple ()
|
|
|
94124
94506
|
|
|
94125
94507
|
x_ite_Namespace .set ("assets/shaders/webgl2/include/Stipple.glsl", Stipple_glsl_default_);
|
|
94126
94508
|
/* harmony default export */ const Stipple_glsl = (Stipple_glsl_default_);
|
|
94127
|
-
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/include/SpotFactor.glsl.js
|
|
94128
|
-
const include_SpotFactor_glsl_default_ = /* glsl */ `
|
|
94129
|
-
float
|
|
94130
|
-
getSpotFactor (const in float cutOffAngle, const in float beamWidth, const in vec3 L, const in vec3 d)
|
|
94131
|
-
{
|
|
94132
|
-
float spotAngle = acos (clamp (dot (-L, d), -1.0, 1.0));
|
|
94133
|
-
|
|
94134
|
-
if (spotAngle >= cutOffAngle)
|
|
94135
|
-
return 0.0;
|
|
94136
|
-
else if (spotAngle <= beamWidth)
|
|
94137
|
-
return 1.0;
|
|
94138
|
-
|
|
94139
|
-
return (spotAngle - cutOffAngle) / (beamWidth - cutOffAngle);
|
|
94140
|
-
}
|
|
94141
|
-
`;
|
|
94142
|
-
;
|
|
94143
|
-
|
|
94144
|
-
x_ite_Namespace .set ("assets/shaders/webgl2/include/SpotFactor.glsl", include_SpotFactor_glsl_default_);
|
|
94145
|
-
/* harmony default export */ const include_SpotFactor_glsl = (include_SpotFactor_glsl_default_);
|
|
94146
94509
|
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/include/Texture.glsl.js
|
|
94147
94510
|
const include_Texture_glsl_default_ = /* glsl */ `
|
|
94148
94511
|
#if defined (X3D_TEXTURE) || defined (X3D_MATERIAL_TEXTURES)
|
|
@@ -94897,57 +95260,36 @@ main ()
|
|
|
94897
95260
|
|
|
94898
95261
|
x_ite_Namespace .set ("assets/shaders/webgl1/Default.vs", Default_vs_default_);
|
|
94899
95262
|
/* harmony default export */ const Default_vs = (Default_vs_default_);
|
|
94900
|
-
;// CONCATENATED MODULE: ./src/assets/shaders/webgl1/
|
|
94901
|
-
const
|
|
95263
|
+
;// CONCATENATED MODULE: ./src/assets/shaders/webgl1/Depth.fs.js
|
|
95264
|
+
const Depth_fs_default_ = /* glsl */ `
|
|
94902
95265
|
precision highp float;
|
|
94903
95266
|
precision highp int;
|
|
94904
|
-
|
|
94905
|
-
uniform mat4 x3d_ProjectionMatrix;
|
|
94906
|
-
uniform mat4 x3d_ModelViewMatrix;
|
|
94907
|
-
|
|
94908
|
-
attribute vec4 x3d_Vertex;
|
|
94909
|
-
attribute vec3 x3d_Normal;
|
|
94910
|
-
|
|
94911
|
-
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
94912
|
-
attribute vec4 x3d_TexCoord0;
|
|
94913
|
-
#endif
|
|
95267
|
+
precision highp sampler2D;
|
|
94914
95268
|
|
|
94915
95269
|
varying vec3 vertex;
|
|
94916
|
-
varying vec3 normal;
|
|
94917
|
-
|
|
94918
|
-
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
94919
|
-
varying vec4 texCoord0;
|
|
94920
|
-
#endif
|
|
94921
95270
|
|
|
94922
|
-
#pragma X3D include "include/
|
|
95271
|
+
#pragma X3D include "include/ClipPlanes.glsl"
|
|
95272
|
+
#pragma X3D include "include/Point.glsl"
|
|
94923
95273
|
|
|
94924
95274
|
void
|
|
94925
95275
|
main ()
|
|
94926
95276
|
{
|
|
94927
|
-
#if defined (
|
|
94928
|
-
|
|
94929
|
-
gl_PointSize = max (pointSize = getPointSize (vertex), 2.0);
|
|
94930
|
-
#else
|
|
94931
|
-
gl_PointSize = 2.0;
|
|
94932
|
-
#endif
|
|
95277
|
+
#if defined (X3D_CLIP_PLANES)
|
|
95278
|
+
clip ();
|
|
94933
95279
|
#endif
|
|
94934
95280
|
|
|
94935
|
-
|
|
94936
|
-
|
|
94937
|
-
|
|
94938
|
-
normal = x3d_Normal;
|
|
94939
|
-
|
|
94940
|
-
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
94941
|
-
texCoord0 = x3d_TexCoord0;
|
|
95281
|
+
#if defined (X3D_GEOMETRY_0D) && defined (X3D_STYLE_PROPERTIES)
|
|
95282
|
+
if (getPointColor (vec4 (1.0)) .a < 0.5)
|
|
95283
|
+
discard;
|
|
94942
95284
|
#endif
|
|
94943
95285
|
|
|
94944
|
-
|
|
95286
|
+
gl_FragColor = vec4 (gl_FragCoord .z);
|
|
94945
95287
|
}
|
|
94946
95288
|
`;
|
|
94947
95289
|
;
|
|
94948
95290
|
|
|
94949
|
-
x_ite_Namespace .set ("assets/shaders/webgl1/
|
|
94950
|
-
/* harmony default export */ const
|
|
95291
|
+
x_ite_Namespace .set ("assets/shaders/webgl1/Depth.fs", Depth_fs_default_);
|
|
95292
|
+
/* harmony default export */ const Depth_fs = (Depth_fs_default_);
|
|
94951
95293
|
;// CONCATENATED MODULE: ./src/assets/shaders/webgl1/Depth.vs.js
|
|
94952
95294
|
const Depth_vs_default_ = /* glsl */ `
|
|
94953
95295
|
precision highp float;
|
|
@@ -94984,144 +95326,6 @@ main ()
|
|
|
94984
95326
|
|
|
94985
95327
|
x_ite_Namespace .set ("assets/shaders/webgl1/Depth.vs", Depth_vs_default_);
|
|
94986
95328
|
/* harmony default export */ const Depth_vs = (Depth_vs_default_);
|
|
94987
|
-
;// CONCATENATED MODULE: ./src/assets/shaders/webgl1/Gouraud.vs.js
|
|
94988
|
-
const Gouraud_vs_default_ = /* glsl */ `
|
|
94989
|
-
precision highp float;
|
|
94990
|
-
precision highp int;
|
|
94991
|
-
precision highp sampler2D;
|
|
94992
|
-
precision highp samplerCube;
|
|
94993
|
-
|
|
94994
|
-
#pragma X3D include "include/Vertex.glsl"
|
|
94995
|
-
#pragma X3D include "include/Material.glsl"
|
|
94996
|
-
|
|
94997
|
-
varying vec4 frontColor;
|
|
94998
|
-
|
|
94999
|
-
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
95000
|
-
varying vec4 backColor;
|
|
95001
|
-
#endif
|
|
95002
|
-
|
|
95003
|
-
vec4
|
|
95004
|
-
getMaterialColor (const in vec3 N,
|
|
95005
|
-
const in vec3 vertex,
|
|
95006
|
-
const in x3d_MaterialParameters material)
|
|
95007
|
-
{
|
|
95008
|
-
// Get diffuse parameter.
|
|
95009
|
-
|
|
95010
|
-
float alpha = 1.0 - x3d_Material .transparency;
|
|
95011
|
-
|
|
95012
|
-
#if defined (X3D_COLOR_MATERIAL)
|
|
95013
|
-
vec4 diffuseParameter = vec4 (color .rgb, color .a * alpha);
|
|
95014
|
-
#else
|
|
95015
|
-
vec4 diffuseParameter = vec4 (x3d_Material .diffuseColor, alpha);
|
|
95016
|
-
#endif
|
|
95017
|
-
|
|
95018
|
-
// Get material color.
|
|
95019
|
-
|
|
95020
|
-
vec3 ambientColor = diffuseParameter .rgb * material .ambientIntensity;
|
|
95021
|
-
|
|
95022
|
-
#if defined (X3D_LIGHTING)
|
|
95023
|
-
vec3 finalColor = getMaterialColor (vertex, N, ambientColor, diffuseParameter .rgb, material .specularColor, material .shininess);
|
|
95024
|
-
#else
|
|
95025
|
-
vec3 finalColor = vec3 (0.0);
|
|
95026
|
-
#endif
|
|
95027
|
-
|
|
95028
|
-
finalColor += material .emissiveColor;
|
|
95029
|
-
|
|
95030
|
-
return vec4 (finalColor, diffuseParameter .a);
|
|
95031
|
-
}
|
|
95032
|
-
|
|
95033
|
-
void
|
|
95034
|
-
main ()
|
|
95035
|
-
{
|
|
95036
|
-
vertex_main ();
|
|
95037
|
-
|
|
95038
|
-
normal = normalize (normal);
|
|
95039
|
-
frontColor = getMaterialColor (normal, vertex, x3d_Material);
|
|
95040
|
-
|
|
95041
|
-
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
95042
|
-
backColor = getMaterialColor (-normal, vertex, x3d_Material);
|
|
95043
|
-
#endif
|
|
95044
|
-
}
|
|
95045
|
-
`;
|
|
95046
|
-
;
|
|
95047
|
-
|
|
95048
|
-
x_ite_Namespace .set ("assets/shaders/webgl1/Gouraud.vs", Gouraud_vs_default_);
|
|
95049
|
-
/* harmony default export */ const Gouraud_vs = (Gouraud_vs_default_);
|
|
95050
|
-
;// CONCATENATED MODULE: ./src/assets/shaders/webgl1/Pointing.fs.js
|
|
95051
|
-
const Pointing_fs_default_ = /* glsl */ `
|
|
95052
|
-
#extension GL_EXT_draw_buffers : enable
|
|
95053
|
-
|
|
95054
|
-
precision highp float;
|
|
95055
|
-
precision highp int;
|
|
95056
|
-
precision highp sampler2D;
|
|
95057
|
-
|
|
95058
|
-
varying vec3 vertex;
|
|
95059
|
-
varying vec3 normal;
|
|
95060
|
-
|
|
95061
|
-
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
95062
|
-
varying vec4 texCoord0;
|
|
95063
|
-
#else
|
|
95064
|
-
vec4 texCoord0 = vec4 (0.0, 0.0, 0.0, 1.0);
|
|
95065
|
-
#endif
|
|
95066
|
-
|
|
95067
|
-
#pragma X3D include "include/ClipPlanes.glsl"
|
|
95068
|
-
#pragma X3D include "include/Point.glsl"
|
|
95069
|
-
|
|
95070
|
-
uniform float x3d_Id;
|
|
95071
|
-
|
|
95072
|
-
void
|
|
95073
|
-
main ()
|
|
95074
|
-
{
|
|
95075
|
-
#if defined (X3D_CLIP_PLANES)
|
|
95076
|
-
clip ();
|
|
95077
|
-
#endif
|
|
95078
|
-
|
|
95079
|
-
#if defined (X3D_GEOMETRY_0D) && defined (X3D_STYLE_PROPERTIES)
|
|
95080
|
-
if (getPointColor (vec4 (1.0)) .a < 0.5)
|
|
95081
|
-
discard;
|
|
95082
|
-
|
|
95083
|
-
texCoord0 = vec4 (gl_PointCoord .x, 1.0 - gl_PointCoord .y, 0.0, 1.0);
|
|
95084
|
-
#endif
|
|
95085
|
-
|
|
95086
|
-
gl_FragData [0] = vec4 (vertex, x3d_Id);
|
|
95087
|
-
gl_FragData [1] = vec4 (normal, 0.0);
|
|
95088
|
-
gl_FragData [2] = texCoord0;
|
|
95089
|
-
}
|
|
95090
|
-
`;
|
|
95091
|
-
;
|
|
95092
|
-
|
|
95093
|
-
x_ite_Namespace .set ("assets/shaders/webgl1/Pointing.fs", Pointing_fs_default_);
|
|
95094
|
-
/* harmony default export */ const Pointing_fs = (Pointing_fs_default_);
|
|
95095
|
-
;// CONCATENATED MODULE: ./src/assets/shaders/webgl1/Depth.fs.js
|
|
95096
|
-
const Depth_fs_default_ = /* glsl */ `
|
|
95097
|
-
precision highp float;
|
|
95098
|
-
precision highp int;
|
|
95099
|
-
precision highp sampler2D;
|
|
95100
|
-
|
|
95101
|
-
varying vec3 vertex;
|
|
95102
|
-
|
|
95103
|
-
#pragma X3D include "include/ClipPlanes.glsl"
|
|
95104
|
-
#pragma X3D include "include/Point.glsl"
|
|
95105
|
-
|
|
95106
|
-
void
|
|
95107
|
-
main ()
|
|
95108
|
-
{
|
|
95109
|
-
#if defined (X3D_CLIP_PLANES)
|
|
95110
|
-
clip ();
|
|
95111
|
-
#endif
|
|
95112
|
-
|
|
95113
|
-
#if defined (X3D_GEOMETRY_0D) && defined (X3D_STYLE_PROPERTIES)
|
|
95114
|
-
if (getPointColor (vec4 (1.0)) .a < 0.5)
|
|
95115
|
-
discard;
|
|
95116
|
-
#endif
|
|
95117
|
-
|
|
95118
|
-
gl_FragColor = vec4 (gl_FragCoord .z);
|
|
95119
|
-
}
|
|
95120
|
-
`;
|
|
95121
|
-
;
|
|
95122
|
-
|
|
95123
|
-
x_ite_Namespace .set ("assets/shaders/webgl1/Depth.fs", Depth_fs_default_);
|
|
95124
|
-
/* harmony default export */ const Depth_fs = (Depth_fs_default_);
|
|
95125
95329
|
;// CONCATENATED MODULE: ./src/assets/shaders/webgl1/Gouraud.fs.js
|
|
95126
95330
|
const Gouraud_fs_default_ = /* glsl */ `
|
|
95127
95331
|
precision highp float;
|
|
@@ -95167,6 +95371,69 @@ main ()
|
|
|
95167
95371
|
|
|
95168
95372
|
x_ite_Namespace .set ("assets/shaders/webgl1/Gouraud.fs", Gouraud_fs_default_);
|
|
95169
95373
|
/* harmony default export */ const Gouraud_fs = (Gouraud_fs_default_);
|
|
95374
|
+
;// CONCATENATED MODULE: ./src/assets/shaders/webgl1/Gouraud.vs.js
|
|
95375
|
+
const Gouraud_vs_default_ = /* glsl */ `
|
|
95376
|
+
precision highp float;
|
|
95377
|
+
precision highp int;
|
|
95378
|
+
precision highp sampler2D;
|
|
95379
|
+
precision highp samplerCube;
|
|
95380
|
+
|
|
95381
|
+
#pragma X3D include "include/Vertex.glsl"
|
|
95382
|
+
#pragma X3D include "include/Material.glsl"
|
|
95383
|
+
|
|
95384
|
+
varying vec4 frontColor;
|
|
95385
|
+
|
|
95386
|
+
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
95387
|
+
varying vec4 backColor;
|
|
95388
|
+
#endif
|
|
95389
|
+
|
|
95390
|
+
vec4
|
|
95391
|
+
getMaterialColor (const in vec3 N,
|
|
95392
|
+
const in vec3 vertex,
|
|
95393
|
+
const in x3d_MaterialParameters material)
|
|
95394
|
+
{
|
|
95395
|
+
// Get diffuse parameter.
|
|
95396
|
+
|
|
95397
|
+
float alpha = 1.0 - x3d_Material .transparency;
|
|
95398
|
+
|
|
95399
|
+
#if defined (X3D_COLOR_MATERIAL)
|
|
95400
|
+
vec4 diffuseParameter = vec4 (color .rgb, color .a * alpha);
|
|
95401
|
+
#else
|
|
95402
|
+
vec4 diffuseParameter = vec4 (x3d_Material .diffuseColor, alpha);
|
|
95403
|
+
#endif
|
|
95404
|
+
|
|
95405
|
+
// Get material color.
|
|
95406
|
+
|
|
95407
|
+
vec3 ambientColor = diffuseParameter .rgb * material .ambientIntensity;
|
|
95408
|
+
|
|
95409
|
+
#if defined (X3D_LIGHTING)
|
|
95410
|
+
vec3 finalColor = getMaterialColor (vertex, N, ambientColor, diffuseParameter .rgb, material .specularColor, material .shininess);
|
|
95411
|
+
#else
|
|
95412
|
+
vec3 finalColor = vec3 (0.0);
|
|
95413
|
+
#endif
|
|
95414
|
+
|
|
95415
|
+
finalColor += material .emissiveColor;
|
|
95416
|
+
|
|
95417
|
+
return vec4 (finalColor, diffuseParameter .a);
|
|
95418
|
+
}
|
|
95419
|
+
|
|
95420
|
+
void
|
|
95421
|
+
main ()
|
|
95422
|
+
{
|
|
95423
|
+
vertex_main ();
|
|
95424
|
+
|
|
95425
|
+
normal = normalize (normal);
|
|
95426
|
+
frontColor = getMaterialColor (normal, vertex, x3d_Material);
|
|
95427
|
+
|
|
95428
|
+
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
95429
|
+
backColor = getMaterialColor (-normal, vertex, x3d_Material);
|
|
95430
|
+
#endif
|
|
95431
|
+
}
|
|
95432
|
+
`;
|
|
95433
|
+
;
|
|
95434
|
+
|
|
95435
|
+
x_ite_Namespace .set ("assets/shaders/webgl1/Gouraud.vs", Gouraud_vs_default_);
|
|
95436
|
+
/* harmony default export */ const Gouraud_vs = (Gouraud_vs_default_);
|
|
95170
95437
|
;// CONCATENATED MODULE: ./src/assets/shaders/webgl1/PBR.fs.js
|
|
95171
95438
|
const PBR_fs_default_ = /* glsl */ `
|
|
95172
95439
|
|
|
@@ -95754,6 +96021,102 @@ main ()
|
|
|
95754
96021
|
|
|
95755
96022
|
x_ite_Namespace .set ("assets/shaders/webgl1/Phong.fs", Phong_fs_default_);
|
|
95756
96023
|
/* harmony default export */ const Phong_fs = (Phong_fs_default_);
|
|
96024
|
+
;// CONCATENATED MODULE: ./src/assets/shaders/webgl1/Pointing.fs.js
|
|
96025
|
+
const Pointing_fs_default_ = /* glsl */ `
|
|
96026
|
+
#extension GL_EXT_draw_buffers : enable
|
|
96027
|
+
|
|
96028
|
+
precision highp float;
|
|
96029
|
+
precision highp int;
|
|
96030
|
+
precision highp sampler2D;
|
|
96031
|
+
|
|
96032
|
+
varying vec3 vertex;
|
|
96033
|
+
varying vec3 normal;
|
|
96034
|
+
|
|
96035
|
+
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
96036
|
+
varying vec4 texCoord0;
|
|
96037
|
+
#else
|
|
96038
|
+
vec4 texCoord0 = vec4 (0.0, 0.0, 0.0, 1.0);
|
|
96039
|
+
#endif
|
|
96040
|
+
|
|
96041
|
+
#pragma X3D include "include/ClipPlanes.glsl"
|
|
96042
|
+
#pragma X3D include "include/Point.glsl"
|
|
96043
|
+
|
|
96044
|
+
uniform float x3d_Id;
|
|
96045
|
+
|
|
96046
|
+
void
|
|
96047
|
+
main ()
|
|
96048
|
+
{
|
|
96049
|
+
#if defined (X3D_CLIP_PLANES)
|
|
96050
|
+
clip ();
|
|
96051
|
+
#endif
|
|
96052
|
+
|
|
96053
|
+
#if defined (X3D_GEOMETRY_0D) && defined (X3D_STYLE_PROPERTIES)
|
|
96054
|
+
if (getPointColor (vec4 (1.0)) .a < 0.5)
|
|
96055
|
+
discard;
|
|
96056
|
+
|
|
96057
|
+
texCoord0 = vec4 (gl_PointCoord .x, 1.0 - gl_PointCoord .y, 0.0, 1.0);
|
|
96058
|
+
#endif
|
|
96059
|
+
|
|
96060
|
+
gl_FragData [0] = vec4 (vertex, x3d_Id);
|
|
96061
|
+
gl_FragData [1] = vec4 (normal, 0.0);
|
|
96062
|
+
gl_FragData [2] = texCoord0;
|
|
96063
|
+
}
|
|
96064
|
+
`;
|
|
96065
|
+
;
|
|
96066
|
+
|
|
96067
|
+
x_ite_Namespace .set ("assets/shaders/webgl1/Pointing.fs", Pointing_fs_default_);
|
|
96068
|
+
/* harmony default export */ const Pointing_fs = (Pointing_fs_default_);
|
|
96069
|
+
;// CONCATENATED MODULE: ./src/assets/shaders/webgl1/Pointing.vs.js
|
|
96070
|
+
const Pointing_vs_default_ = /* glsl */ `
|
|
96071
|
+
precision highp float;
|
|
96072
|
+
precision highp int;
|
|
96073
|
+
|
|
96074
|
+
uniform mat4 x3d_ProjectionMatrix;
|
|
96075
|
+
uniform mat4 x3d_ModelViewMatrix;
|
|
96076
|
+
|
|
96077
|
+
attribute vec4 x3d_Vertex;
|
|
96078
|
+
attribute vec3 x3d_Normal;
|
|
96079
|
+
|
|
96080
|
+
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
96081
|
+
attribute vec4 x3d_TexCoord0;
|
|
96082
|
+
#endif
|
|
96083
|
+
|
|
96084
|
+
varying vec3 vertex;
|
|
96085
|
+
varying vec3 normal;
|
|
96086
|
+
|
|
96087
|
+
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
96088
|
+
varying vec4 texCoord0;
|
|
96089
|
+
#endif
|
|
96090
|
+
|
|
96091
|
+
#pragma X3D include "include/PointSize.glsl"
|
|
96092
|
+
|
|
96093
|
+
void
|
|
96094
|
+
main ()
|
|
96095
|
+
{
|
|
96096
|
+
#if defined (X3D_GEOMETRY_0D)
|
|
96097
|
+
#if defined (X3D_STYLE_PROPERTIES)
|
|
96098
|
+
gl_PointSize = max (pointSize = getPointSize (vertex), 2.0);
|
|
96099
|
+
#else
|
|
96100
|
+
gl_PointSize = 2.0;
|
|
96101
|
+
#endif
|
|
96102
|
+
#endif
|
|
96103
|
+
|
|
96104
|
+
vec4 position = x3d_ModelViewMatrix * x3d_Vertex;
|
|
96105
|
+
|
|
96106
|
+
vertex = position .xyz;
|
|
96107
|
+
normal = x3d_Normal;
|
|
96108
|
+
|
|
96109
|
+
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
96110
|
+
texCoord0 = x3d_TexCoord0;
|
|
96111
|
+
#endif
|
|
96112
|
+
|
|
96113
|
+
gl_Position = x3d_ProjectionMatrix * position;
|
|
96114
|
+
}
|
|
96115
|
+
`;
|
|
96116
|
+
;
|
|
96117
|
+
|
|
96118
|
+
x_ite_Namespace .set ("assets/shaders/webgl1/Pointing.vs", Pointing_vs_default_);
|
|
96119
|
+
/* harmony default export */ const Pointing_vs = (Pointing_vs_default_);
|
|
95757
96120
|
;// CONCATENATED MODULE: ./src/assets/shaders/webgl1/Unlit.fs.js
|
|
95758
96121
|
const Unlit_fs_default_ = /* glsl */ `
|
|
95759
96122
|
precision highp float;
|
|
@@ -95814,6 +96177,59 @@ main ()
|
|
|
95814
96177
|
|
|
95815
96178
|
x_ite_Namespace .set ("assets/shaders/webgl1/Unlit.fs", Unlit_fs_default_);
|
|
95816
96179
|
/* harmony default export */ const Unlit_fs = (Unlit_fs_default_);
|
|
96180
|
+
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/Compose.fs.js
|
|
96181
|
+
const Compose_fs_default_ = /* glsl */ `#version 300 es
|
|
96182
|
+
|
|
96183
|
+
precision highp float;
|
|
96184
|
+
precision highp int;
|
|
96185
|
+
precision highp sampler2D;
|
|
96186
|
+
|
|
96187
|
+
/* sum(rgb * a), prod(1 - a) */
|
|
96188
|
+
uniform sampler2D x3d_AccumRevealageTexture;
|
|
96189
|
+
|
|
96190
|
+
/* sum(a) */
|
|
96191
|
+
uniform sampler2D x3d_AlphaTexture;
|
|
96192
|
+
|
|
96193
|
+
out vec4 x3d_FragColor;
|
|
96194
|
+
|
|
96195
|
+
void
|
|
96196
|
+
main ()
|
|
96197
|
+
{
|
|
96198
|
+
ivec2 fragCoord = ivec2 (gl_FragCoord .xy);
|
|
96199
|
+
vec4 accum = texelFetch (x3d_AccumRevealageTexture, fragCoord, 0);
|
|
96200
|
+
|
|
96201
|
+
if (accum .a >= 1.0)
|
|
96202
|
+
discard;
|
|
96203
|
+
|
|
96204
|
+
float alpha = texelFetch (x3d_AlphaTexture, fragCoord, 0) .r;
|
|
96205
|
+
float revealage = 1.0 - accum .a;
|
|
96206
|
+
|
|
96207
|
+
x3d_FragColor = vec4 (revealage * accum .rgb / clamp (alpha, 0.001, 50000.0), revealage);
|
|
96208
|
+
}
|
|
96209
|
+
`;
|
|
96210
|
+
;
|
|
96211
|
+
|
|
96212
|
+
x_ite_Namespace .set ("assets/shaders/webgl2/Compose.fs", Compose_fs_default_);
|
|
96213
|
+
/* harmony default export */ const Compose_fs = (Compose_fs_default_);
|
|
96214
|
+
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/Compose.vs.js
|
|
96215
|
+
const Compose_vs_default_ = /* glsl */ `#version 300 es
|
|
96216
|
+
|
|
96217
|
+
precision highp float;
|
|
96218
|
+
precision highp int;
|
|
96219
|
+
precision highp sampler2D;
|
|
96220
|
+
|
|
96221
|
+
layout(location = 0) in vec4 x3d_Vertex;
|
|
96222
|
+
|
|
96223
|
+
void
|
|
96224
|
+
main ()
|
|
96225
|
+
{
|
|
96226
|
+
gl_Position = x3d_Vertex;
|
|
96227
|
+
}
|
|
96228
|
+
`;
|
|
96229
|
+
;
|
|
96230
|
+
|
|
96231
|
+
x_ite_Namespace .set ("assets/shaders/webgl2/Compose.vs", Compose_vs_default_);
|
|
96232
|
+
/* harmony default export */ const Compose_vs = (Compose_vs_default_);
|
|
95817
96233
|
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/Default.vs.js
|
|
95818
96234
|
const webgl2_Default_vs_default_ = /* glsl */ `#version 300 es
|
|
95819
96235
|
|
|
@@ -95835,79 +96251,39 @@ main ()
|
|
|
95835
96251
|
|
|
95836
96252
|
x_ite_Namespace .set ("assets/shaders/webgl2/Default.vs", webgl2_Default_vs_default_);
|
|
95837
96253
|
/* harmony default export */ const webgl2_Default_vs = (webgl2_Default_vs_default_);
|
|
95838
|
-
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/
|
|
95839
|
-
const
|
|
96254
|
+
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/Depth.fs.js
|
|
96255
|
+
const webgl2_Depth_fs_default_ = /* glsl */ `#version 300 es
|
|
95840
96256
|
|
|
95841
96257
|
precision highp float;
|
|
95842
96258
|
precision highp int;
|
|
95843
96259
|
precision highp sampler2D;
|
|
95844
96260
|
|
|
95845
|
-
|
|
95846
|
-
uniform mat4 x3d_ModelViewMatrix;
|
|
95847
|
-
|
|
95848
|
-
in vec4 x3d_Vertex;
|
|
95849
|
-
in vec3 x3d_Normal;
|
|
95850
|
-
|
|
95851
|
-
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
95852
|
-
in vec4 x3d_TexCoord0;
|
|
95853
|
-
#endif
|
|
95854
|
-
|
|
95855
|
-
#if defined (X3D_GEOMETRY_1D) && defined (X3D_STYLE_PROPERTIES)
|
|
95856
|
-
in vec3 x3d_LineStipple;
|
|
95857
|
-
#endif
|
|
95858
|
-
|
|
95859
|
-
out vec3 vertex;
|
|
95860
|
-
out vec3 normal;
|
|
95861
|
-
|
|
95862
|
-
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
95863
|
-
out vec4 texCoord0;
|
|
95864
|
-
#endif
|
|
96261
|
+
in vec3 vertex;
|
|
95865
96262
|
|
|
95866
|
-
|
|
95867
|
-
flat out float lengthSoFar;
|
|
95868
|
-
flat out vec2 startPoint;
|
|
95869
|
-
out vec2 midPoint;
|
|
95870
|
-
#endif
|
|
96263
|
+
out vec4 x3d_FragColor;
|
|
95871
96264
|
|
|
95872
|
-
#pragma X3D include "include/
|
|
95873
|
-
#pragma X3D include "include/
|
|
95874
|
-
#pragma X3D include "include/Particle.glsl"
|
|
95875
|
-
#pragma X3D include "include/PointSize.glsl"
|
|
96265
|
+
#pragma X3D include "include/ClipPlanes.glsl"
|
|
96266
|
+
#pragma X3D include "include/Point.glsl"
|
|
95876
96267
|
|
|
95877
96268
|
void
|
|
95878
96269
|
main ()
|
|
95879
96270
|
{
|
|
95880
|
-
#if defined (
|
|
95881
|
-
|
|
95882
|
-
startPoint = x3d_LineStipple .xy;
|
|
95883
|
-
midPoint = x3d_LineStipple .xy;
|
|
95884
|
-
#endif
|
|
95885
|
-
|
|
95886
|
-
vec4 x3d_TransformedVertex = getParticleVertex (getSkinVertex (x3d_Vertex, vec3 (0.0)));
|
|
95887
|
-
vec4 position = x3d_ModelViewMatrix * x3d_TransformedVertex;
|
|
95888
|
-
|
|
95889
|
-
vertex = position .xyz;
|
|
95890
|
-
normal = x3d_Normal;
|
|
95891
|
-
|
|
95892
|
-
#if defined (X3D_GEOMETRY_0D)
|
|
95893
|
-
#if defined (X3D_STYLE_PROPERTIES)
|
|
95894
|
-
gl_PointSize = max (pointSize = getPointSize (vertex), 2.0);
|
|
95895
|
-
#else
|
|
95896
|
-
gl_PointSize = 2.0;
|
|
95897
|
-
#endif
|
|
96271
|
+
#if defined (X3D_CLIP_PLANES)
|
|
96272
|
+
clip ();
|
|
95898
96273
|
#endif
|
|
95899
96274
|
|
|
95900
|
-
#if
|
|
95901
|
-
|
|
96275
|
+
#if defined (X3D_GEOMETRY_0D) && defined (X3D_STYLE_PROPERTIES)
|
|
96276
|
+
if (getPointColor (vec4 (1.0)) .a < 0.5)
|
|
96277
|
+
discard;
|
|
95902
96278
|
#endif
|
|
95903
96279
|
|
|
95904
|
-
|
|
96280
|
+
x3d_FragColor = vec4 (gl_FragCoord .z);
|
|
95905
96281
|
}
|
|
95906
96282
|
`;
|
|
95907
96283
|
;
|
|
95908
96284
|
|
|
95909
|
-
x_ite_Namespace .set ("assets/shaders/webgl2/
|
|
95910
|
-
/* harmony default export */ const
|
|
96285
|
+
x_ite_Namespace .set ("assets/shaders/webgl2/Depth.fs", webgl2_Depth_fs_default_);
|
|
96286
|
+
/* harmony default export */ const webgl2_Depth_fs = (webgl2_Depth_fs_default_);
|
|
95911
96287
|
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/Depth.vs.js
|
|
95912
96288
|
const webgl2_Depth_vs_default_ = /* glsl */ `#version 300 es
|
|
95913
96289
|
|
|
@@ -95950,6 +96326,53 @@ main ()
|
|
|
95950
96326
|
|
|
95951
96327
|
x_ite_Namespace .set ("assets/shaders/webgl2/Depth.vs", webgl2_Depth_vs_default_);
|
|
95952
96328
|
/* harmony default export */ const webgl2_Depth_vs = (webgl2_Depth_vs_default_);
|
|
96329
|
+
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/Gouraud.fs.js
|
|
96330
|
+
const webgl2_Gouraud_fs_default_ = /* glsl */ `#version 300 es
|
|
96331
|
+
|
|
96332
|
+
precision highp float;
|
|
96333
|
+
precision highp int;
|
|
96334
|
+
precision highp sampler2D;
|
|
96335
|
+
precision highp sampler3D;
|
|
96336
|
+
precision highp samplerCube;
|
|
96337
|
+
|
|
96338
|
+
#pragma X3D include "include/Fragment.glsl"
|
|
96339
|
+
|
|
96340
|
+
in vec4 frontColor;
|
|
96341
|
+
|
|
96342
|
+
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
96343
|
+
in vec4 backColor;
|
|
96344
|
+
#endif
|
|
96345
|
+
|
|
96346
|
+
vec4
|
|
96347
|
+
getMaterialColor ()
|
|
96348
|
+
{
|
|
96349
|
+
#if defined (X3D_GEOMETRY_0D) || defined (X3D_GEOMETRY_1D)
|
|
96350
|
+
vec4 finalColor = frontColor;
|
|
96351
|
+
#else
|
|
96352
|
+
vec4 finalColor = gl_FrontFacing ? frontColor : backColor;
|
|
96353
|
+
#endif
|
|
96354
|
+
|
|
96355
|
+
#if defined (X3D_TEXTURE)
|
|
96356
|
+
finalColor = getTextureColor (finalColor, vec4 (1.0));
|
|
96357
|
+
#endif
|
|
96358
|
+
|
|
96359
|
+
#if defined (X3D_PROJECTIVE_TEXTURE_MAPPING)
|
|
96360
|
+
finalColor = getProjectiveTextureColor (finalColor);
|
|
96361
|
+
#endif
|
|
96362
|
+
|
|
96363
|
+
return finalColor;
|
|
96364
|
+
}
|
|
96365
|
+
|
|
96366
|
+
void
|
|
96367
|
+
main ()
|
|
96368
|
+
{
|
|
96369
|
+
fragment_main ();
|
|
96370
|
+
}
|
|
96371
|
+
`;
|
|
96372
|
+
;
|
|
96373
|
+
|
|
96374
|
+
x_ite_Namespace .set ("assets/shaders/webgl2/Gouraud.fs", webgl2_Gouraud_fs_default_);
|
|
96375
|
+
/* harmony default export */ const webgl2_Gouraud_fs = (webgl2_Gouraud_fs_default_);
|
|
95953
96376
|
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/Gouraud.vs.js
|
|
95954
96377
|
const webgl2_Gouraud_vs_default_ = /* glsl */ `#version 300 es
|
|
95955
96378
|
|
|
@@ -96015,6 +96438,18 @@ main ()
|
|
|
96015
96438
|
|
|
96016
96439
|
x_ite_Namespace .set ("assets/shaders/webgl2/Gouraud.vs", webgl2_Gouraud_vs_default_);
|
|
96017
96440
|
/* harmony default export */ const webgl2_Gouraud_vs = (webgl2_Gouraud_vs_default_);
|
|
96441
|
+
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/LineTransform.fs.js
|
|
96442
|
+
const LineTransform_fs_default_ = /* glsl */ `#version 300 es
|
|
96443
|
+
|
|
96444
|
+
precision highp float;
|
|
96445
|
+
|
|
96446
|
+
void
|
|
96447
|
+
main () { }
|
|
96448
|
+
`;
|
|
96449
|
+
;
|
|
96450
|
+
|
|
96451
|
+
x_ite_Namespace .set ("assets/shaders/webgl2/LineTransform.fs", LineTransform_fs_default_);
|
|
96452
|
+
/* harmony default export */ const LineTransform_fs = (LineTransform_fs_default_);
|
|
96018
96453
|
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/LineTransform.vs.js
|
|
96019
96454
|
const LineTransform_vs_default_ = /* glsl */ `#version 300 es
|
|
96020
96455
|
|
|
@@ -96110,152 +96545,6 @@ main ()
|
|
|
96110
96545
|
|
|
96111
96546
|
x_ite_Namespace .set ("assets/shaders/webgl2/LineTransform.vs", LineTransform_vs_default_);
|
|
96112
96547
|
/* harmony default export */ const LineTransform_vs = (LineTransform_vs_default_);
|
|
96113
|
-
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/Pointing.fs.js
|
|
96114
|
-
const webgl2_Pointing_fs_default_ = /* glsl */ `#version 300 es
|
|
96115
|
-
|
|
96116
|
-
precision highp float;
|
|
96117
|
-
precision highp int;
|
|
96118
|
-
precision highp sampler2D;
|
|
96119
|
-
|
|
96120
|
-
in vec3 vertex;
|
|
96121
|
-
in vec3 normal;
|
|
96122
|
-
in vec4 texCoord;
|
|
96123
|
-
|
|
96124
|
-
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
96125
|
-
in vec4 texCoord0;
|
|
96126
|
-
#else
|
|
96127
|
-
vec4 texCoord0 = vec4 (0.0, 0.0, 0.0, 1.0);
|
|
96128
|
-
#endif
|
|
96129
|
-
|
|
96130
|
-
layout(location = 0) out vec4 x3d_FragData0;
|
|
96131
|
-
layout(location = 1) out vec4 x3d_FragData1;
|
|
96132
|
-
layout(location = 2) out vec4 x3d_FragData2;
|
|
96133
|
-
|
|
96134
|
-
#pragma X3D include "include/ClipPlanes.glsl"
|
|
96135
|
-
#pragma X3D include "include/Point.glsl"
|
|
96136
|
-
#pragma X3D include "Stipple.glsl"
|
|
96137
|
-
|
|
96138
|
-
uniform float x3d_Id;
|
|
96139
|
-
|
|
96140
|
-
void
|
|
96141
|
-
main ()
|
|
96142
|
-
{
|
|
96143
|
-
#if defined (X3D_CLIP_PLANES)
|
|
96144
|
-
clip ();
|
|
96145
|
-
#endif
|
|
96146
|
-
|
|
96147
|
-
#if defined (X3D_GEOMETRY_0D) && defined (X3D_STYLE_PROPERTIES)
|
|
96148
|
-
if (getPointColor (vec4 (1.0)) .a < 0.5)
|
|
96149
|
-
discard;
|
|
96150
|
-
|
|
96151
|
-
texCoord0 = vec4 (gl_PointCoord .x, 1.0 - gl_PointCoord .y, 0.0, 1.0);
|
|
96152
|
-
#endif
|
|
96153
|
-
|
|
96154
|
-
#if defined (X3D_GEOMETRY_1D) && defined (X3D_STYLE_PROPERTIES)
|
|
96155
|
-
stipple ();
|
|
96156
|
-
#endif
|
|
96157
|
-
|
|
96158
|
-
x3d_FragData0 = vec4 (vertex, x3d_Id);
|
|
96159
|
-
x3d_FragData1 = vec4 (normal, 0.0);
|
|
96160
|
-
x3d_FragData2 = texCoord0;
|
|
96161
|
-
}
|
|
96162
|
-
`;
|
|
96163
|
-
;
|
|
96164
|
-
|
|
96165
|
-
x_ite_Namespace .set ("assets/shaders/webgl2/Pointing.fs", webgl2_Pointing_fs_default_);
|
|
96166
|
-
/* harmony default export */ const webgl2_Pointing_fs = (webgl2_Pointing_fs_default_);
|
|
96167
|
-
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/Depth.fs.js
|
|
96168
|
-
const webgl2_Depth_fs_default_ = /* glsl */ `#version 300 es
|
|
96169
|
-
|
|
96170
|
-
precision highp float;
|
|
96171
|
-
precision highp int;
|
|
96172
|
-
precision highp sampler2D;
|
|
96173
|
-
|
|
96174
|
-
in vec3 vertex;
|
|
96175
|
-
|
|
96176
|
-
out vec4 x3d_FragColor;
|
|
96177
|
-
|
|
96178
|
-
#pragma X3D include "include/ClipPlanes.glsl"
|
|
96179
|
-
#pragma X3D include "include/Point.glsl"
|
|
96180
|
-
|
|
96181
|
-
void
|
|
96182
|
-
main ()
|
|
96183
|
-
{
|
|
96184
|
-
#if defined (X3D_CLIP_PLANES)
|
|
96185
|
-
clip ();
|
|
96186
|
-
#endif
|
|
96187
|
-
|
|
96188
|
-
#if defined (X3D_GEOMETRY_0D) && defined (X3D_STYLE_PROPERTIES)
|
|
96189
|
-
if (getPointColor (vec4 (1.0)) .a < 0.5)
|
|
96190
|
-
discard;
|
|
96191
|
-
#endif
|
|
96192
|
-
|
|
96193
|
-
x3d_FragColor = vec4 (gl_FragCoord .z);
|
|
96194
|
-
}
|
|
96195
|
-
`;
|
|
96196
|
-
;
|
|
96197
|
-
|
|
96198
|
-
x_ite_Namespace .set ("assets/shaders/webgl2/Depth.fs", webgl2_Depth_fs_default_);
|
|
96199
|
-
/* harmony default export */ const webgl2_Depth_fs = (webgl2_Depth_fs_default_);
|
|
96200
|
-
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/Gouraud.fs.js
|
|
96201
|
-
const webgl2_Gouraud_fs_default_ = /* glsl */ `#version 300 es
|
|
96202
|
-
|
|
96203
|
-
precision highp float;
|
|
96204
|
-
precision highp int;
|
|
96205
|
-
precision highp sampler2D;
|
|
96206
|
-
precision highp sampler3D;
|
|
96207
|
-
precision highp samplerCube;
|
|
96208
|
-
|
|
96209
|
-
#pragma X3D include "include/Fragment.glsl"
|
|
96210
|
-
|
|
96211
|
-
in vec4 frontColor;
|
|
96212
|
-
|
|
96213
|
-
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
96214
|
-
in vec4 backColor;
|
|
96215
|
-
#endif
|
|
96216
|
-
|
|
96217
|
-
vec4
|
|
96218
|
-
getMaterialColor ()
|
|
96219
|
-
{
|
|
96220
|
-
#if defined (X3D_GEOMETRY_0D) || defined (X3D_GEOMETRY_1D)
|
|
96221
|
-
vec4 finalColor = frontColor;
|
|
96222
|
-
#else
|
|
96223
|
-
vec4 finalColor = gl_FrontFacing ? frontColor : backColor;
|
|
96224
|
-
#endif
|
|
96225
|
-
|
|
96226
|
-
#if defined (X3D_TEXTURE)
|
|
96227
|
-
finalColor = getTextureColor (finalColor, vec4 (1.0));
|
|
96228
|
-
#endif
|
|
96229
|
-
|
|
96230
|
-
#if defined (X3D_PROJECTIVE_TEXTURE_MAPPING)
|
|
96231
|
-
finalColor = getProjectiveTextureColor (finalColor);
|
|
96232
|
-
#endif
|
|
96233
|
-
|
|
96234
|
-
return finalColor;
|
|
96235
|
-
}
|
|
96236
|
-
|
|
96237
|
-
void
|
|
96238
|
-
main ()
|
|
96239
|
-
{
|
|
96240
|
-
fragment_main ();
|
|
96241
|
-
}
|
|
96242
|
-
`;
|
|
96243
|
-
;
|
|
96244
|
-
|
|
96245
|
-
x_ite_Namespace .set ("assets/shaders/webgl2/Gouraud.fs", webgl2_Gouraud_fs_default_);
|
|
96246
|
-
/* harmony default export */ const webgl2_Gouraud_fs = (webgl2_Gouraud_fs_default_);
|
|
96247
|
-
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/LineTransform.fs.js
|
|
96248
|
-
const LineTransform_fs_default_ = /* glsl */ `#version 300 es
|
|
96249
|
-
|
|
96250
|
-
precision highp float;
|
|
96251
|
-
|
|
96252
|
-
void
|
|
96253
|
-
main () { }
|
|
96254
|
-
`;
|
|
96255
|
-
;
|
|
96256
|
-
|
|
96257
|
-
x_ite_Namespace .set ("assets/shaders/webgl2/LineTransform.fs", LineTransform_fs_default_);
|
|
96258
|
-
/* harmony default export */ const LineTransform_fs = (LineTransform_fs_default_);
|
|
96259
96548
|
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/PBR.fs.js
|
|
96260
96549
|
const webgl2_PBR_fs_default_ = /* glsl */ `#version 300 es
|
|
96261
96550
|
|
|
@@ -96864,6 +97153,133 @@ main ()
|
|
|
96864
97153
|
|
|
96865
97154
|
x_ite_Namespace .set ("assets/shaders/webgl2/Phong.fs", webgl2_Phong_fs_default_);
|
|
96866
97155
|
/* harmony default export */ const webgl2_Phong_fs = (webgl2_Phong_fs_default_);
|
|
97156
|
+
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/Pointing.fs.js
|
|
97157
|
+
const webgl2_Pointing_fs_default_ = /* glsl */ `#version 300 es
|
|
97158
|
+
|
|
97159
|
+
precision highp float;
|
|
97160
|
+
precision highp int;
|
|
97161
|
+
precision highp sampler2D;
|
|
97162
|
+
|
|
97163
|
+
in vec3 vertex;
|
|
97164
|
+
in vec3 normal;
|
|
97165
|
+
in vec4 texCoord;
|
|
97166
|
+
|
|
97167
|
+
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
97168
|
+
in vec4 texCoord0;
|
|
97169
|
+
#else
|
|
97170
|
+
vec4 texCoord0 = vec4 (0.0, 0.0, 0.0, 1.0);
|
|
97171
|
+
#endif
|
|
97172
|
+
|
|
97173
|
+
layout(location = 0) out vec4 x3d_FragData0;
|
|
97174
|
+
layout(location = 1) out vec4 x3d_FragData1;
|
|
97175
|
+
layout(location = 2) out vec4 x3d_FragData2;
|
|
97176
|
+
|
|
97177
|
+
#pragma X3D include "include/ClipPlanes.glsl"
|
|
97178
|
+
#pragma X3D include "include/Point.glsl"
|
|
97179
|
+
#pragma X3D include "Stipple.glsl"
|
|
97180
|
+
|
|
97181
|
+
uniform float x3d_Id;
|
|
97182
|
+
|
|
97183
|
+
void
|
|
97184
|
+
main ()
|
|
97185
|
+
{
|
|
97186
|
+
#if defined (X3D_CLIP_PLANES)
|
|
97187
|
+
clip ();
|
|
97188
|
+
#endif
|
|
97189
|
+
|
|
97190
|
+
#if defined (X3D_GEOMETRY_0D) && defined (X3D_STYLE_PROPERTIES)
|
|
97191
|
+
if (getPointColor (vec4 (1.0)) .a < 0.5)
|
|
97192
|
+
discard;
|
|
97193
|
+
|
|
97194
|
+
texCoord0 = vec4 (gl_PointCoord .x, 1.0 - gl_PointCoord .y, 0.0, 1.0);
|
|
97195
|
+
#endif
|
|
97196
|
+
|
|
97197
|
+
#if defined (X3D_GEOMETRY_1D) && defined (X3D_STYLE_PROPERTIES)
|
|
97198
|
+
stipple ();
|
|
97199
|
+
#endif
|
|
97200
|
+
|
|
97201
|
+
x3d_FragData0 = vec4 (vertex, x3d_Id);
|
|
97202
|
+
x3d_FragData1 = vec4 (normal, 0.0);
|
|
97203
|
+
x3d_FragData2 = texCoord0;
|
|
97204
|
+
}
|
|
97205
|
+
`;
|
|
97206
|
+
;
|
|
97207
|
+
|
|
97208
|
+
x_ite_Namespace .set ("assets/shaders/webgl2/Pointing.fs", webgl2_Pointing_fs_default_);
|
|
97209
|
+
/* harmony default export */ const webgl2_Pointing_fs = (webgl2_Pointing_fs_default_);
|
|
97210
|
+
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/Pointing.vs.js
|
|
97211
|
+
const webgl2_Pointing_vs_default_ = /* glsl */ `#version 300 es
|
|
97212
|
+
|
|
97213
|
+
precision highp float;
|
|
97214
|
+
precision highp int;
|
|
97215
|
+
precision highp sampler2D;
|
|
97216
|
+
|
|
97217
|
+
uniform mat4 x3d_ProjectionMatrix;
|
|
97218
|
+
uniform mat4 x3d_ModelViewMatrix;
|
|
97219
|
+
|
|
97220
|
+
in vec4 x3d_Vertex;
|
|
97221
|
+
in vec3 x3d_Normal;
|
|
97222
|
+
|
|
97223
|
+
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
97224
|
+
in vec4 x3d_TexCoord0;
|
|
97225
|
+
#endif
|
|
97226
|
+
|
|
97227
|
+
#if defined (X3D_GEOMETRY_1D) && defined (X3D_STYLE_PROPERTIES)
|
|
97228
|
+
in vec3 x3d_LineStipple;
|
|
97229
|
+
#endif
|
|
97230
|
+
|
|
97231
|
+
out vec3 vertex;
|
|
97232
|
+
out vec3 normal;
|
|
97233
|
+
|
|
97234
|
+
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
97235
|
+
out vec4 texCoord0;
|
|
97236
|
+
#endif
|
|
97237
|
+
|
|
97238
|
+
#if defined (X3D_GEOMETRY_1D) && defined (X3D_STYLE_PROPERTIES)
|
|
97239
|
+
flat out float lengthSoFar;
|
|
97240
|
+
flat out vec2 startPoint;
|
|
97241
|
+
out vec2 midPoint;
|
|
97242
|
+
#endif
|
|
97243
|
+
|
|
97244
|
+
#pragma X3D include "include/Utils.glsl"
|
|
97245
|
+
#pragma X3D include "include/Skin.glsl"
|
|
97246
|
+
#pragma X3D include "include/Particle.glsl"
|
|
97247
|
+
#pragma X3D include "include/PointSize.glsl"
|
|
97248
|
+
|
|
97249
|
+
void
|
|
97250
|
+
main ()
|
|
97251
|
+
{
|
|
97252
|
+
#if defined (X3D_GEOMETRY_1D) && defined (X3D_STYLE_PROPERTIES)
|
|
97253
|
+
lengthSoFar = x3d_LineStipple .z;
|
|
97254
|
+
startPoint = x3d_LineStipple .xy;
|
|
97255
|
+
midPoint = x3d_LineStipple .xy;
|
|
97256
|
+
#endif
|
|
97257
|
+
|
|
97258
|
+
vec4 x3d_TransformedVertex = getParticleVertex (getSkinVertex (x3d_Vertex, vec3 (0.0)));
|
|
97259
|
+
vec4 position = x3d_ModelViewMatrix * x3d_TransformedVertex;
|
|
97260
|
+
|
|
97261
|
+
vertex = position .xyz;
|
|
97262
|
+
normal = x3d_Normal;
|
|
97263
|
+
|
|
97264
|
+
#if defined (X3D_GEOMETRY_0D)
|
|
97265
|
+
#if defined (X3D_STYLE_PROPERTIES)
|
|
97266
|
+
gl_PointSize = max (pointSize = getPointSize (vertex), 2.0);
|
|
97267
|
+
#else
|
|
97268
|
+
gl_PointSize = 2.0;
|
|
97269
|
+
#endif
|
|
97270
|
+
#endif
|
|
97271
|
+
|
|
97272
|
+
#if ! defined (X3D_GEOMETRY_0D) && ! defined (X3D_GEOMETRY_1D)
|
|
97273
|
+
texCoord0 = x3d_TexCoord0;
|
|
97274
|
+
#endif
|
|
97275
|
+
|
|
97276
|
+
gl_Position = x3d_ProjectionMatrix * position;
|
|
97277
|
+
}
|
|
97278
|
+
`;
|
|
97279
|
+
;
|
|
97280
|
+
|
|
97281
|
+
x_ite_Namespace .set ("assets/shaders/webgl2/Pointing.vs", webgl2_Pointing_vs_default_);
|
|
97282
|
+
/* harmony default export */ const webgl2_Pointing_vs = (webgl2_Pointing_vs_default_);
|
|
96867
97283
|
;// CONCATENATED MODULE: ./src/assets/shaders/webgl2/Unlit.fs.js
|
|
96868
97284
|
const webgl2_Unlit_fs_default_ = /* glsl */ `#version 300 es
|
|
96869
97285
|
|
|
@@ -97040,6 +97456,8 @@ x_ite_Namespace .set ("assets/shaders/webgl2/Unlit.fs", webgl2_Unlit_fs_default_
|
|
|
97040
97456
|
|
|
97041
97457
|
|
|
97042
97458
|
|
|
97459
|
+
|
|
97460
|
+
|
|
97043
97461
|
const Shaders = {
|
|
97044
97462
|
includes: {
|
|
97045
97463
|
1: {
|
|
@@ -97073,8 +97491,8 @@ const Shaders = {
|
|
|
97073
97491
|
PointSize: include_PointSize_glsl,
|
|
97074
97492
|
Shadow: include_Shadow_glsl,
|
|
97075
97493
|
Skin: Skin_glsl,
|
|
97076
|
-
Stipple: Stipple_glsl,
|
|
97077
97494
|
SpotFactor: include_SpotFactor_glsl,
|
|
97495
|
+
Stipple: Stipple_glsl,
|
|
97078
97496
|
Texture: include_Texture_glsl,
|
|
97079
97497
|
Utils: Utils_glsl,
|
|
97080
97498
|
Vertex: include_Vertex_glsl,
|
|
@@ -97083,34 +97501,36 @@ const Shaders = {
|
|
|
97083
97501
|
vertex: {
|
|
97084
97502
|
1: {
|
|
97085
97503
|
Default: Default_vs,
|
|
97086
|
-
Pointing: Pointing_vs,
|
|
97087
97504
|
Depth: Depth_vs,
|
|
97088
97505
|
Gouraud: Gouraud_vs,
|
|
97506
|
+
Pointing: Pointing_vs,
|
|
97089
97507
|
},
|
|
97090
97508
|
2: {
|
|
97509
|
+
Compose: Compose_vs,
|
|
97091
97510
|
Default: webgl2_Default_vs,
|
|
97092
|
-
Pointing: webgl2_Pointing_vs,
|
|
97093
97511
|
Depth: webgl2_Depth_vs,
|
|
97094
97512
|
Gouraud: webgl2_Gouraud_vs,
|
|
97095
97513
|
LineTransform: LineTransform_vs,
|
|
97514
|
+
Pointing: webgl2_Pointing_vs,
|
|
97096
97515
|
},
|
|
97097
97516
|
},
|
|
97098
97517
|
fragment: {
|
|
97099
97518
|
1: {
|
|
97100
|
-
Pointing: Pointing_fs,
|
|
97101
97519
|
Depth: Depth_fs,
|
|
97102
97520
|
Gouraud: Gouraud_fs,
|
|
97103
97521
|
PBR: PBR_fs,
|
|
97104
97522
|
Phong: Phong_fs,
|
|
97523
|
+
Pointing: Pointing_fs,
|
|
97105
97524
|
Unlit: Unlit_fs,
|
|
97106
97525
|
},
|
|
97107
97526
|
2: {
|
|
97108
|
-
|
|
97527
|
+
Compose: Compose_fs,
|
|
97109
97528
|
Depth: webgl2_Depth_fs,
|
|
97110
97529
|
Gouraud: webgl2_Gouraud_fs,
|
|
97111
97530
|
LineTransform: LineTransform_fs,
|
|
97112
97531
|
PBR: webgl2_PBR_fs,
|
|
97113
97532
|
Phong: webgl2_Phong_fs,
|
|
97533
|
+
Pointing: webgl2_Pointing_fs,
|
|
97114
97534
|
Unlit: webgl2_Unlit_fs,
|
|
97115
97535
|
},
|
|
97116
97536
|
},
|
|
@@ -97224,7 +97644,7 @@ const ShaderCompiler_default_ = ShaderCompiler;
|
|
|
97224
97644
|
x_ite_Namespace .set ("x_ite/Browser/Shaders/ShaderCompiler", ShaderCompiler_default_);
|
|
97225
97645
|
/* harmony default export */ const Shaders_ShaderCompiler = (ShaderCompiler_default_);
|
|
97226
97646
|
;// CONCATENATED MODULE: ./src/x_ite/Components/Shaders/ShaderPart.js
|
|
97227
|
-
/* provided dependency */ var ShaderPart_$ = __webpack_require__(
|
|
97647
|
+
/* provided dependency */ var ShaderPart_$ = __webpack_require__(964);
|
|
97228
97648
|
/*******************************************************************************
|
|
97229
97649
|
*
|
|
97230
97650
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -97881,7 +98301,7 @@ const X3DAppearanceNode_default_ = X3DAppearanceNode;
|
|
|
97881
98301
|
x_ite_Namespace .set ("x_ite/Components/Shape/X3DAppearanceNode", X3DAppearanceNode_default_);
|
|
97882
98302
|
/* harmony default export */ const Shape_X3DAppearanceNode = (X3DAppearanceNode_default_);
|
|
97883
98303
|
;// CONCATENATED MODULE: ./src/x_ite/Components/Shape/Appearance.js
|
|
97884
|
-
/* provided dependency */ var Appearance_$ = __webpack_require__(
|
|
98304
|
+
/* provided dependency */ var Appearance_$ = __webpack_require__(964);
|
|
97885
98305
|
/*******************************************************************************
|
|
97886
98306
|
*
|
|
97887
98307
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -98428,6 +98848,10 @@ Object .assign (Object .setPrototypeOf (FillProperties .prototype, Shape_X3DAppe
|
|
|
98428
98848
|
// Preload texture.
|
|
98429
98849
|
this .getBrowser () .getHatchStyleTexture (this .hatchStyle);
|
|
98430
98850
|
},
|
|
98851
|
+
getStyleKey ()
|
|
98852
|
+
{
|
|
98853
|
+
return this .hatched ? 2 : 1;
|
|
98854
|
+
},
|
|
98431
98855
|
set_filled__ ()
|
|
98432
98856
|
{
|
|
98433
98857
|
this .filled = this ._filled .getValue ();
|
|
@@ -98608,6 +99032,10 @@ Object .assign (Object .setPrototypeOf (LineProperties .prototype, Shape_X3DAppe
|
|
|
98608
99032
|
// Preload texture.
|
|
98609
99033
|
this .getBrowser () .getLinetypeTexture ();
|
|
98610
99034
|
},
|
|
99035
|
+
getStyleKey ()
|
|
99036
|
+
{
|
|
99037
|
+
return this .applied ? 2 : 1;
|
|
99038
|
+
},
|
|
98611
99039
|
getApplied ()
|
|
98612
99040
|
{
|
|
98613
99041
|
return this .applied;
|
|
@@ -98779,18 +99207,6 @@ function X3DMaterialNode (executionContext)
|
|
|
98779
99207
|
|
|
98780
99208
|
Object .assign (Object .setPrototypeOf (X3DMaterialNode .prototype, Shape_X3DAppearanceChildNode .prototype),
|
|
98781
99209
|
{
|
|
98782
|
-
initialize ()
|
|
98783
|
-
{
|
|
98784
|
-
Shape_X3DAppearanceChildNode .prototype .initialize .call (this);
|
|
98785
|
-
|
|
98786
|
-
this .getBrowser () .getRenderingProperties () ._LogarithmicDepthBuffer .addInterest ("set_logarithmicDepthBuffer__", this);
|
|
98787
|
-
|
|
98788
|
-
this .set_logarithmicDepthBuffer__ ();
|
|
98789
|
-
},
|
|
98790
|
-
set_logarithmicDepthBuffer__ ()
|
|
98791
|
-
{
|
|
98792
|
-
this .logarithmicDepthBuffer = this .getBrowser () .getRenderingProperty ("LogarithmicDepthBuffer");
|
|
98793
|
-
},
|
|
98794
99210
|
setTransparent (value)
|
|
98795
99211
|
{
|
|
98796
99212
|
if (value !== this ._transparent .getValue ())
|
|
@@ -98827,13 +99243,13 @@ Object .assign (Object .setPrototypeOf (X3DMaterialNode .prototype, Shape_X3DApp
|
|
|
98827
99243
|
{
|
|
98828
99244
|
const { renderObject, transparent, shadows, fogNode, shapeNode, appearanceNode, textureNode, humanoidNode, objectsCount } = renderContext;
|
|
98829
99245
|
|
|
98830
|
-
key += this .logarithmicDepthBuffer || renderObject .getViewpoint () .getLogarithmicDepthBuffer () ? 1 : 0;
|
|
98831
99246
|
key += appearanceNode .getNormalizedAlphaMode (transparent);
|
|
98832
99247
|
key += this .getMaterialKey (shadows);
|
|
99248
|
+
key += renderObject .getLogarithmicDepthBuffer () ? 1 : 0;
|
|
98833
99249
|
key += shadows ? 1 : 0;
|
|
98834
99250
|
key += fogNode ?.getFogType () ?? 0;
|
|
98835
99251
|
key += shapeNode .getShapeKey ();
|
|
98836
|
-
key += appearanceNode .getStyleProperties (geometryContext .geometryType)
|
|
99252
|
+
key += appearanceNode .getStyleProperties (geometryContext .geometryType) ?.getStyleKey () ?? 0;
|
|
98837
99253
|
key += appearanceNode .getTextureTransformMapping () .size || 1;
|
|
98838
99254
|
key += geometryContext .textureCoordinateMapping .size || 1;
|
|
98839
99255
|
key += humanoidNode ? 1 : 0;
|
|
@@ -98848,12 +99264,13 @@ Object .assign (Object .setPrototypeOf (X3DMaterialNode .prototype, Shape_X3DApp
|
|
|
98848
99264
|
}
|
|
98849
99265
|
else
|
|
98850
99266
|
{
|
|
99267
|
+
// Rubberband, X3DBackgroundNode
|
|
99268
|
+
|
|
98851
99269
|
const { textureNode, objectsCount } = geometryContext;
|
|
98852
99270
|
|
|
98853
|
-
key += this .logarithmicDepthBuffer ? 1 : 0;
|
|
98854
99271
|
key += geometryContext .alphaMode;
|
|
98855
99272
|
key += this .getMaterialKey (false);
|
|
98856
|
-
key += "
|
|
99273
|
+
key += "00000110";
|
|
98857
99274
|
key += ".";
|
|
98858
99275
|
key += objectsCount [0]; // Clip planes
|
|
98859
99276
|
key += ".";
|
|
@@ -98887,20 +99304,30 @@ Object .assign (Object .setPrototypeOf (X3DMaterialNode .prototype, Shape_X3DApp
|
|
|
98887
99304
|
{
|
|
98888
99305
|
const { renderObject, fogNode, shapeNode, appearanceNode, humanoidNode, objectsCount } = renderContext;
|
|
98889
99306
|
|
|
98890
|
-
if (
|
|
99307
|
+
if (renderObject .getLogarithmicDepthBuffer ())
|
|
98891
99308
|
options .push ("X3D_LOGARITHMIC_DEPTH_BUFFER");
|
|
98892
99309
|
|
|
98893
99310
|
switch (appearanceNode .getNormalizedAlphaMode (renderContext .transparent))
|
|
98894
99311
|
{
|
|
98895
99312
|
case Shape_AlphaMode .OPAQUE:
|
|
99313
|
+
{
|
|
98896
99314
|
options .push ("X3D_ALPHA_MODE_OPAQUE");
|
|
98897
99315
|
break;
|
|
99316
|
+
}
|
|
98898
99317
|
case Shape_AlphaMode .MASK:
|
|
99318
|
+
{
|
|
98899
99319
|
options .push ("X3D_ALPHA_MODE_MASK");
|
|
98900
99320
|
break;
|
|
99321
|
+
}
|
|
98901
99322
|
case Shape_AlphaMode .BLEND:
|
|
99323
|
+
{
|
|
98902
99324
|
options .push ("X3D_ALPHA_MODE_BLEND");
|
|
99325
|
+
|
|
99326
|
+
if (browser .getBrowserOption ("OrderIndependentTransparency"))
|
|
99327
|
+
options .push ("X3D_ORDER_INDEPENDENT_TRANSPARENCY");
|
|
99328
|
+
|
|
98903
99329
|
break;
|
|
99330
|
+
}
|
|
98904
99331
|
}
|
|
98905
99332
|
|
|
98906
99333
|
if (renderContext .shadows)
|
|
@@ -98938,8 +99365,13 @@ Object .assign (Object .setPrototypeOf (X3DMaterialNode .prototype, Shape_X3DApp
|
|
|
98938
99365
|
}
|
|
98939
99366
|
|
|
98940
99367
|
if (appearanceNode .getStyleProperties (geometryContext .geometryType))
|
|
99368
|
+
{
|
|
98941
99369
|
options .push ("X3D_STYLE_PROPERTIES");
|
|
98942
99370
|
|
|
99371
|
+
if (appearanceNode .getStyleProperties (geometryContext .geometryType) .getStyleKey () > 1)
|
|
99372
|
+
options .push ("X3D_STYLE_PROPERTIES_TEXTURE");
|
|
99373
|
+
}
|
|
99374
|
+
|
|
98943
99375
|
if (+this .textureBits)
|
|
98944
99376
|
options .push ("X3D_MATERIAL_TEXTURES");
|
|
98945
99377
|
|
|
@@ -98984,10 +99416,30 @@ Object .assign (Object .setPrototypeOf (X3DMaterialNode .prototype, Shape_X3DApp
|
|
|
98984
99416
|
}
|
|
98985
99417
|
else
|
|
98986
99418
|
{
|
|
98987
|
-
const { textureNode, objectsCount } = geometryContext;
|
|
99419
|
+
const { alphaMode, textureNode, objectsCount } = geometryContext;
|
|
98988
99420
|
|
|
98989
|
-
|
|
98990
|
-
|
|
99421
|
+
switch (alphaMode)
|
|
99422
|
+
{
|
|
99423
|
+
case Shape_AlphaMode .OPAQUE:
|
|
99424
|
+
{
|
|
99425
|
+
options .push ("X3D_ALPHA_MODE_OPAQUE");
|
|
99426
|
+
break;
|
|
99427
|
+
}
|
|
99428
|
+
case Shape_AlphaMode .MASK:
|
|
99429
|
+
{
|
|
99430
|
+
options .push ("X3D_ALPHA_MODE_MASK");
|
|
99431
|
+
break;
|
|
99432
|
+
}
|
|
99433
|
+
case Shape_AlphaMode .BLEND:
|
|
99434
|
+
{
|
|
99435
|
+
options .push ("X3D_ALPHA_MODE_BLEND");
|
|
99436
|
+
|
|
99437
|
+
if (browser .getBrowserOption ("OrderIndependentTransparency"))
|
|
99438
|
+
options .push ("X3D_ORDER_INDEPENDENT_TRANSPARENCY");
|
|
99439
|
+
|
|
99440
|
+
break;
|
|
99441
|
+
}
|
|
99442
|
+
}
|
|
98991
99443
|
|
|
98992
99444
|
if (objectsCount [0])
|
|
98993
99445
|
{
|
|
@@ -100078,6 +100530,10 @@ Object .assign (Object .setPrototypeOf (PointProperties .prototype, Shape_X3DApp
|
|
|
100078
100530
|
this .set_pointSizeMaxValue__ ();
|
|
100079
100531
|
this .set_attenuation__ ();
|
|
100080
100532
|
},
|
|
100533
|
+
getStyleKey ()
|
|
100534
|
+
{
|
|
100535
|
+
return 1;
|
|
100536
|
+
},
|
|
100081
100537
|
set_contentScale__ ()
|
|
100082
100538
|
{
|
|
100083
100539
|
this .set_pointSizeScaleFactor__ ();
|
|
@@ -101574,7 +102030,7 @@ const X3DSoundSourceNode_default_ = X3DSoundSourceNode;
|
|
|
101574
102030
|
x_ite_Namespace .set ("x_ite/Components/Sound/X3DSoundSourceNode", X3DSoundSourceNode_default_);
|
|
101575
102031
|
/* harmony default export */ const Sound_X3DSoundSourceNode = (X3DSoundSourceNode_default_);
|
|
101576
102032
|
;// CONCATENATED MODULE: ./src/x_ite/Components/Sound/AudioClip.js
|
|
101577
|
-
/* provided dependency */ var AudioClip_$ = __webpack_require__(
|
|
102033
|
+
/* provided dependency */ var AudioClip_$ = __webpack_require__(964);
|
|
101578
102034
|
/*******************************************************************************
|
|
101579
102035
|
*
|
|
101580
102036
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -101630,6 +102086,7 @@ x_ite_Namespace .set ("x_ite/Components/Sound/X3DSoundSourceNode", X3DSoundSourc
|
|
|
101630
102086
|
|
|
101631
102087
|
|
|
101632
102088
|
|
|
102089
|
+
|
|
101633
102090
|
function AudioClip (executionContext)
|
|
101634
102091
|
{
|
|
101635
102092
|
Sound_X3DSoundSourceNode .call (this, executionContext);
|
|
@@ -101697,7 +102154,7 @@ Object .assign (Object .setPrototypeOf (AudioClip .prototype, Sound_X3DSoundSour
|
|
|
101697
102154
|
if (this .URL .protocol !== "data:")
|
|
101698
102155
|
{
|
|
101699
102156
|
if (!this .getCache ())
|
|
101700
|
-
this .URL .searchParams .set ("_",
|
|
102157
|
+
this .URL .searchParams .set ("_", Time_Time .now ());
|
|
101701
102158
|
}
|
|
101702
102159
|
|
|
101703
102160
|
this .audio .attr ("src", this .URL .href);
|
|
@@ -104685,8 +105142,8 @@ const GIFMedia_default_ = GifMedia;
|
|
|
104685
105142
|
x_ite_Namespace .set ("x_ite/Browser/Texturing/GIFMedia", GIFMedia_default_);
|
|
104686
105143
|
/* harmony default export */ const GIFMedia = (GIFMedia_default_);
|
|
104687
105144
|
;// CONCATENATED MODULE: ./src/x_ite/Components/Texturing/MovieTexture.js
|
|
104688
|
-
/* provided dependency */ var MovieTexture_$ = __webpack_require__(
|
|
104689
|
-
/* provided dependency */ var SuperGif = __webpack_require__(
|
|
105145
|
+
/* provided dependency */ var MovieTexture_$ = __webpack_require__(964);
|
|
105146
|
+
/* provided dependency */ var SuperGif = __webpack_require__(90);
|
|
104690
105147
|
/*******************************************************************************
|
|
104691
105148
|
*
|
|
104692
105149
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -104745,6 +105202,7 @@ x_ite_Namespace .set ("x_ite/Browser/Texturing/GIFMedia", GIFMedia_default_);
|
|
|
104745
105202
|
|
|
104746
105203
|
|
|
104747
105204
|
|
|
105205
|
+
|
|
104748
105206
|
function MovieTexture (executionContext)
|
|
104749
105207
|
{
|
|
104750
105208
|
Texturing_X3DTexture2DNode .call (this, executionContext);
|
|
@@ -104815,7 +105273,7 @@ Object .assign (Object .setPrototypeOf (MovieTexture .prototype, Texturing_X3DTe
|
|
|
104815
105273
|
if (this .URL .protocol !== "data:")
|
|
104816
105274
|
{
|
|
104817
105275
|
if (!this .getCache ())
|
|
104818
|
-
this .URL .searchParams .set ("_",
|
|
105276
|
+
this .URL .searchParams .set ("_", Time_Time .now ());
|
|
104819
105277
|
}
|
|
104820
105278
|
|
|
104821
105279
|
if (this .URL .pathname .endsWith (".gif"))
|
|
@@ -105851,7 +106309,7 @@ const MultiTextureTransform_default_ = MultiTextureTransform;
|
|
|
105851
106309
|
x_ite_Namespace .set ("x_ite/Components/Texturing/MultiTextureTransform", MultiTextureTransform_default_);
|
|
105852
106310
|
/* harmony default export */ const Texturing_MultiTextureTransform = (MultiTextureTransform_default_);
|
|
105853
106311
|
;// CONCATENATED MODULE: ./src/x_ite/Components/Texturing/PixelTexture.js
|
|
105854
|
-
/* provided dependency */ var PixelTexture_$ = __webpack_require__(
|
|
106312
|
+
/* provided dependency */ var PixelTexture_$ = __webpack_require__(964);
|
|
105855
106313
|
/*******************************************************************************
|
|
105856
106314
|
*
|
|
105857
106315
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -107247,7 +107705,7 @@ x_ite_Namespace .set ("x_ite/Components/Texturing", Texturing_default_);
|
|
|
107247
107705
|
|
|
107248
107706
|
|
|
107249
107707
|
|
|
107250
|
-
const
|
|
107708
|
+
const Components_Time_default_ = {
|
|
107251
107709
|
name: "Time",
|
|
107252
107710
|
concreteNodes:
|
|
107253
107711
|
[
|
|
@@ -107260,8 +107718,8 @@ const Time_default_ = {
|
|
|
107260
107718
|
};
|
|
107261
107719
|
;
|
|
107262
107720
|
|
|
107263
|
-
x_ite_Namespace .set ("x_ite/Components/Time",
|
|
107264
|
-
/* harmony default export */ const
|
|
107721
|
+
x_ite_Namespace .set ("x_ite/Components/Time", Components_Time_default_);
|
|
107722
|
+
/* harmony default export */ const Components_Time = (Components_Time_default_);
|
|
107265
107723
|
;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/Context.js
|
|
107266
107724
|
/*******************************************************************************
|
|
107267
107725
|
*
|
|
@@ -107382,7 +107840,7 @@ const Context =
|
|
|
107382
107840
|
gl = canvas .getContext ("webgl2", { ... options, antialias: false });
|
|
107383
107841
|
|
|
107384
107842
|
if (gl)
|
|
107385
|
-
gl .getVersion =
|
|
107843
|
+
gl .getVersion = () => 2;
|
|
107386
107844
|
}
|
|
107387
107845
|
|
|
107388
107846
|
if (version >= 1 && !gl)
|
|
@@ -107392,7 +107850,7 @@ const Context =
|
|
|
107392
107850
|
|
|
107393
107851
|
if (gl)
|
|
107394
107852
|
{
|
|
107395
|
-
gl .getVersion =
|
|
107853
|
+
gl .getVersion = () => 1;
|
|
107396
107854
|
|
|
107397
107855
|
{
|
|
107398
107856
|
const ext = gl .getExtension ("OES_vertex_array_object");
|
|
@@ -108042,7 +108500,7 @@ const gettext_default_ = gettext;
|
|
|
108042
108500
|
x_ite_Namespace .set ("locale/gettext", gettext_default_);
|
|
108043
108501
|
/* harmony default export */ const locale_gettext = (gettext_default_);
|
|
108044
108502
|
;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/BrowserTimings.js
|
|
108045
|
-
/* provided dependency */ var BrowserTimings_$ = __webpack_require__(
|
|
108503
|
+
/* provided dependency */ var BrowserTimings_$ = __webpack_require__(964);
|
|
108046
108504
|
/*******************************************************************************
|
|
108047
108505
|
*
|
|
108048
108506
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -108472,7 +108930,7 @@ const TextureQuality_default_ = TextureQuality;
|
|
|
108472
108930
|
x_ite_Namespace .set ("x_ite/Browser/Core/TextureQuality", TextureQuality_default_);
|
|
108473
108931
|
/* harmony default export */ const Core_TextureQuality = (TextureQuality_default_);
|
|
108474
108932
|
;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/BrowserOptions.js
|
|
108475
|
-
/* provided dependency */ var BrowserOptions_$ = __webpack_require__(
|
|
108933
|
+
/* provided dependency */ var BrowserOptions_$ = __webpack_require__(964);
|
|
108476
108934
|
/*******************************************************************************
|
|
108477
108935
|
*
|
|
108478
108936
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -108558,27 +109016,29 @@ Object .assign (Object .setPrototypeOf (BrowserOptions .prototype, Base_X3DBaseN
|
|
|
108558
109016
|
Timings: this ._Timings .getValue (),
|
|
108559
109017
|
});
|
|
108560
109018
|
|
|
108561
|
-
this ._Rubberband
|
|
108562
|
-
this ._Antialiased
|
|
108563
|
-
this ._PrimitiveQuality
|
|
108564
|
-
this ._TextureQuality
|
|
108565
|
-
this ._Shading
|
|
108566
|
-
this ._StraightenHorizon
|
|
108567
|
-
this ._AutoUpdate
|
|
108568
|
-
this ._ContentScale
|
|
108569
|
-
this ._LogarithmicDepthBuffer
|
|
108570
|
-
this ._Multisampling
|
|
108571
|
-
this .
|
|
108572
|
-
|
|
108573
|
-
|
|
108574
|
-
this .
|
|
108575
|
-
this .
|
|
108576
|
-
this .
|
|
108577
|
-
this .
|
|
109019
|
+
this ._Rubberband .addInterest ("set_rubberband__", this);
|
|
109020
|
+
this ._Antialiased .addInterest ("set_antialiased__", this);
|
|
109021
|
+
this ._PrimitiveQuality .addInterest ("set_primitiveQuality__", this);
|
|
109022
|
+
this ._TextureQuality .addInterest ("set_textureQuality__", this);
|
|
109023
|
+
this ._Shading .addInterest ("set_shading__", this);
|
|
109024
|
+
this ._StraightenHorizon .addInterest ("set_straightenHorizon__", this);
|
|
109025
|
+
this ._AutoUpdate .addInterest ("set_autoUpdate__", this);
|
|
109026
|
+
this ._ContentScale .addInterest ("set_contentScale__", this);
|
|
109027
|
+
this ._LogarithmicDepthBuffer .addInterest ("set_logarithmicDepthBuffer__", this);
|
|
109028
|
+
this ._Multisampling .addInterest ("set_multisampling__", this);
|
|
109029
|
+
this ._OrderIndependentTransparency .addInterest ("set_orderIndependentTransparency__", this);
|
|
109030
|
+
this ._Timings .addInterest ("set_timings__", this);
|
|
109031
|
+
|
|
109032
|
+
this .set_antialiased__ (this ._Antialiased);
|
|
109033
|
+
this .set_shading__ (this ._Shading);
|
|
109034
|
+
this .set_contentScale__ (this ._ContentScale);
|
|
109035
|
+
this .set_logarithmicDepthBuffer__ (this ._LogarithmicDepthBuffer);
|
|
109036
|
+
this .set_multisampling__ (this ._Multisampling);
|
|
109037
|
+
this .set_orderIndependentTransparency__ (this ._OrderIndependentTransparency);
|
|
108578
109038
|
|
|
108579
|
-
this .
|
|
109039
|
+
this .reset ();
|
|
108580
109040
|
},
|
|
108581
|
-
|
|
109041
|
+
reset: (() =>
|
|
108582
109042
|
{
|
|
108583
109043
|
const attributes = new Set ([
|
|
108584
109044
|
"Antialiased",
|
|
@@ -108589,6 +109049,7 @@ Object .assign (Object .setPrototypeOf (BrowserOptions .prototype, Base_X3DBaseN
|
|
|
108589
109049
|
"Debug",
|
|
108590
109050
|
"Multisampling",
|
|
108591
109051
|
"Notifications",
|
|
109052
|
+
"OrderIndependentTransparency",
|
|
108592
109053
|
"SplashScreen",
|
|
108593
109054
|
]);
|
|
108594
109055
|
|
|
@@ -108722,24 +109183,6 @@ Object .assign (Object .setPrototypeOf (BrowserOptions .prototype, Base_X3DBaseN
|
|
|
108722
109183
|
if (straightenHorizon .getValue ())
|
|
108723
109184
|
this .getBrowser () .getActiveLayer () ?.straightenView ();
|
|
108724
109185
|
},
|
|
108725
|
-
updateContentScale ()
|
|
108726
|
-
{
|
|
108727
|
-
const
|
|
108728
|
-
browser = this .getBrowser (),
|
|
108729
|
-
media = window .matchMedia (`(resolution: ${window .devicePixelRatio}dppx)`),
|
|
108730
|
-
update = this .updateContentScale .bind (this);
|
|
108731
|
-
|
|
108732
|
-
if (this .removeUpdateContentScale)
|
|
108733
|
-
this .removeUpdateContentScale ();
|
|
108734
|
-
|
|
108735
|
-
this .removeUpdateContentScale = function () { media .removeEventListener ("change", update) };
|
|
108736
|
-
|
|
108737
|
-
media .addEventListener ("change", update);
|
|
108738
|
-
|
|
108739
|
-
browser .getRenderingProperties () ._ContentScale = window .devicePixelRatio;
|
|
108740
|
-
|
|
108741
|
-
browser .reshape ();
|
|
108742
|
-
},
|
|
108743
109186
|
set_autoUpdate__ (autoUpdate)
|
|
108744
109187
|
{
|
|
108745
109188
|
const events = ["resize", "scroll", "load"]
|
|
@@ -108788,6 +109231,24 @@ Object .assign (Object .setPrototypeOf (BrowserOptions .prototype, Base_X3DBaseN
|
|
|
108788
109231
|
|
|
108789
109232
|
browser .reshape ();
|
|
108790
109233
|
},
|
|
109234
|
+
updateContentScale ()
|
|
109235
|
+
{
|
|
109236
|
+
const
|
|
109237
|
+
browser = this .getBrowser (),
|
|
109238
|
+
media = window .matchMedia (`(resolution: ${window .devicePixelRatio}dppx)`),
|
|
109239
|
+
update = this .updateContentScale .bind (this);
|
|
109240
|
+
|
|
109241
|
+
if (this .removeUpdateContentScale)
|
|
109242
|
+
this .removeUpdateContentScale ();
|
|
109243
|
+
|
|
109244
|
+
this .removeUpdateContentScale = function () { media .removeEventListener ("change", update) };
|
|
109245
|
+
|
|
109246
|
+
media .addEventListener ("change", update);
|
|
109247
|
+
|
|
109248
|
+
browser .getRenderingProperties () ._ContentScale = window .devicePixelRatio;
|
|
109249
|
+
|
|
109250
|
+
browser .reshape ();
|
|
109251
|
+
},
|
|
108791
109252
|
set_logarithmicDepthBuffer__ (logarithmicDepthBuffer)
|
|
108792
109253
|
{
|
|
108793
109254
|
const
|
|
@@ -108803,8 +109264,15 @@ Object .assign (Object .setPrototypeOf (BrowserOptions .prototype, Base_X3DBaseN
|
|
|
108803
109264
|
samples = Math_Algorithm .clamp (multisampling .getValue (), 0, browser .getMaxSamples ());
|
|
108804
109265
|
|
|
108805
109266
|
browser .getRenderingProperties () ._Multisampling = this ._Antialiased .getValue () ? samples : 0;
|
|
108806
|
-
browser .getRenderingProperties () ._Antialiased =
|
|
109267
|
+
browser .getRenderingProperties () ._Antialiased = samples > 0;
|
|
109268
|
+
|
|
109269
|
+
browser .reshape ();
|
|
109270
|
+
},
|
|
109271
|
+
set_orderIndependentTransparency__ ()
|
|
109272
|
+
{
|
|
109273
|
+
const browser = this .getBrowser ();
|
|
108807
109274
|
|
|
109275
|
+
browser .getShaders () .clear ();
|
|
108808
109276
|
browser .reshape ();
|
|
108809
109277
|
},
|
|
108810
109278
|
set_timings__ (timings)
|
|
@@ -108823,27 +109291,28 @@ Object .defineProperties (BrowserOptions,
|
|
|
108823
109291
|
fieldDefinitions:
|
|
108824
109292
|
{
|
|
108825
109293
|
value: new Base_FieldDefinitionArray ([
|
|
108826
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "SplashScreen",
|
|
108827
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Dashboard",
|
|
108828
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Rubberband",
|
|
108829
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "EnableInlineViewpoints",
|
|
108830
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Antialiased",
|
|
108831
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "TextureQuality",
|
|
108832
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "PrimitiveQuality",
|
|
108833
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "QualityWhenMoving",
|
|
108834
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Shading",
|
|
108835
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "MotionBlur",
|
|
108836
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "AutoUpdate",
|
|
108837
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Cache",
|
|
108838
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "ContentScale",
|
|
108839
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "ContextMenu",
|
|
108840
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Debug",
|
|
108841
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Gravity",
|
|
108842
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "LogarithmicDepthBuffer",
|
|
108843
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Notifications",
|
|
108844
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Multisampling",
|
|
108845
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "
|
|
108846
|
-
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "
|
|
109294
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "SplashScreen", new x_ite_Fields .SFBool (true)),
|
|
109295
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Dashboard", new x_ite_Fields .SFBool (true)),
|
|
109296
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Rubberband", new x_ite_Fields .SFBool (true)),
|
|
109297
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "EnableInlineViewpoints", new x_ite_Fields .SFBool (true)),
|
|
109298
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Antialiased", new x_ite_Fields .SFBool (true)),
|
|
109299
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "TextureQuality", new x_ite_Fields .SFString ("MEDIUM")),
|
|
109300
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "PrimitiveQuality", new x_ite_Fields .SFString ("MEDIUM")),
|
|
109301
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "QualityWhenMoving", new x_ite_Fields .SFString ("SAME")),
|
|
109302
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Shading", new x_ite_Fields .SFString ("GOURAUD")),
|
|
109303
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "MotionBlur", new x_ite_Fields .SFBool ()),
|
|
109304
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "AutoUpdate", new x_ite_Fields .SFBool ()),
|
|
109305
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Cache", new x_ite_Fields .SFBool (true)),
|
|
109306
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "ContentScale", new x_ite_Fields .SFDouble (1)),
|
|
109307
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "ContextMenu", new x_ite_Fields .SFBool (true)),
|
|
109308
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Debug", new x_ite_Fields .SFBool ()),
|
|
109309
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Gravity", new x_ite_Fields .SFDouble (9.80665)),
|
|
109310
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "LogarithmicDepthBuffer", new x_ite_Fields .SFBool ()),
|
|
109311
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Notifications", new x_ite_Fields .SFBool (true)),
|
|
109312
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Multisampling", new x_ite_Fields .SFInt32 (4)),
|
|
109313
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "OrderIndependentTransparency", new x_ite_Fields .SFBool ()),
|
|
109314
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "StraightenHorizon", new x_ite_Fields .SFBool (true)),
|
|
109315
|
+
new Base_X3DFieldDefinition (Base_X3DConstants .inputOutput, "Timings", new x_ite_Fields .SFBool ()),
|
|
108847
109316
|
]),
|
|
108848
109317
|
enumerable: true,
|
|
108849
109318
|
},
|
|
@@ -109053,7 +109522,7 @@ const RenderingProperties_default_ = RenderingProperties;
|
|
|
109053
109522
|
x_ite_Namespace .set ("x_ite/Browser/Core/RenderingProperties", RenderingProperties_default_);
|
|
109054
109523
|
/* harmony default export */ const Core_RenderingProperties = (RenderingProperties_default_);
|
|
109055
109524
|
;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/Notification.js
|
|
109056
|
-
/* provided dependency */ var Notification_$ = __webpack_require__(
|
|
109525
|
+
/* provided dependency */ var Notification_$ = __webpack_require__(964);
|
|
109057
109526
|
/*******************************************************************************
|
|
109058
109527
|
*
|
|
109059
109528
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -109176,8 +109645,8 @@ const Notification_default_ = Notification;
|
|
|
109176
109645
|
x_ite_Namespace .set ("x_ite/Browser/Core/Notification", Notification_default_);
|
|
109177
109646
|
/* harmony default export */ const Core_Notification = (Notification_default_);
|
|
109178
109647
|
;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/ContextMenu.js
|
|
109179
|
-
/* provided dependency */ var jquery_fullscreen = __webpack_require__(
|
|
109180
|
-
/* provided dependency */ var ContextMenu_$ = __webpack_require__(
|
|
109648
|
+
/* provided dependency */ var jquery_fullscreen = __webpack_require__(253);
|
|
109649
|
+
/* provided dependency */ var ContextMenu_$ = __webpack_require__(964);
|
|
109181
109650
|
/*******************************************************************************
|
|
109182
109651
|
*
|
|
109183
109652
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -111259,6 +111728,7 @@ Object .assign (Object .setPrototypeOf (X3DScene .prototype, Execution_X3DExecut
|
|
|
111259
111728
|
|
|
111260
111729
|
generator .string += generator .Indent ();
|
|
111261
111730
|
generator .string += "</X3D>";
|
|
111731
|
+
generator .string += generator .TidyBreak ();
|
|
111262
111732
|
},
|
|
111263
111733
|
toJSONStream (generator)
|
|
111264
111734
|
{
|
|
@@ -111603,6 +112073,7 @@ Object .assign (Object .setPrototypeOf (X3DScene .prototype, Execution_X3DExecut
|
|
|
111603
112073
|
generator .string += generator .DecIndent ();
|
|
111604
112074
|
generator .string += generator .Indent ();
|
|
111605
112075
|
generator .string += '}';
|
|
112076
|
+
generator .string += generator .TidyBreak ();
|
|
111606
112077
|
},
|
|
111607
112078
|
},
|
|
111608
112079
|
{
|
|
@@ -111895,7 +112366,7 @@ const DataStorage_default_ = DataStorage;
|
|
|
111895
112366
|
x_ite_Namespace .set ("standard/Utility/DataStorage", DataStorage_default_);
|
|
111896
112367
|
/* harmony default export */ const Utility_DataStorage = (DataStorage_default_);
|
|
111897
112368
|
;// CONCATENATED MODULE: ./src/x_ite/Browser/Core/X3DCoreContext.js
|
|
111898
|
-
/* provided dependency */ var X3DCoreContext_$ = __webpack_require__(
|
|
112369
|
+
/* provided dependency */ var X3DCoreContext_$ = __webpack_require__(964);
|
|
111899
112370
|
/*******************************************************************************
|
|
111900
112371
|
*
|
|
111901
112372
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -112248,6 +112719,12 @@ Object .assign (X3DCoreContext .prototype,
|
|
|
112248
112719
|
|
|
112249
112720
|
break;
|
|
112250
112721
|
}
|
|
112722
|
+
case "orderIndependentTransparency":
|
|
112723
|
+
case "orderindependenttransparency":
|
|
112724
|
+
{
|
|
112725
|
+
this .setBrowserOption ("OrderIndependentTransparency", this .parseBooleanAttribute (newValue, false));
|
|
112726
|
+
break;
|
|
112727
|
+
}
|
|
112251
112728
|
case "splashScreen":
|
|
112252
112729
|
case "splashscreen":
|
|
112253
112730
|
{
|
|
@@ -113922,8 +114399,8 @@ const X3DViewer_default_ = X3DViewer;
|
|
|
113922
114399
|
x_ite_Namespace .set ("x_ite/Browser/Navigation/X3DViewer", X3DViewer_default_);
|
|
113923
114400
|
/* harmony default export */ const Navigation_X3DViewer = (X3DViewer_default_);
|
|
113924
114401
|
;// CONCATENATED MODULE: ./src/x_ite/Browser/Navigation/ExamineViewer.js
|
|
113925
|
-
/* provided dependency */ var jquery_mousewheel = __webpack_require__(
|
|
113926
|
-
/* provided dependency */ var ExamineViewer_$ = __webpack_require__(
|
|
114402
|
+
/* provided dependency */ var jquery_mousewheel = __webpack_require__(759);
|
|
114403
|
+
/* provided dependency */ var ExamineViewer_$ = __webpack_require__(964);
|
|
113927
114404
|
/*******************************************************************************
|
|
113928
114405
|
*
|
|
113929
114406
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -113983,6 +114460,7 @@ x_ite_Namespace .set ("x_ite/Browser/Navigation/X3DViewer", X3DViewer_default_);
|
|
|
113983
114460
|
|
|
113984
114461
|
|
|
113985
114462
|
|
|
114463
|
+
|
|
113986
114464
|
typeof jquery_mousewheel; // import plugin
|
|
113987
114465
|
|
|
113988
114466
|
const macOS = /Mac OS X/i .test (navigator .userAgent)
|
|
@@ -114090,7 +114568,7 @@ Object .assign (Object .setPrototypeOf (ExamineViewer .prototype, Navigation_X3D
|
|
|
114090
114568
|
if (this .button >= 0)
|
|
114091
114569
|
return;
|
|
114092
114570
|
|
|
114093
|
-
this .pressTime =
|
|
114571
|
+
this .pressTime = Time_Time .now ();
|
|
114094
114572
|
|
|
114095
114573
|
const { x, y } = this .getBrowser () .getPointerFromEvent (event);
|
|
114096
114574
|
|
|
@@ -114173,7 +114651,7 @@ Object .assign (Object .setPrototypeOf (ExamineViewer .prototype, Navigation_X3D
|
|
|
114173
114651
|
|
|
114174
114652
|
this .getBrowser () .setCursor ("DEFAULT");
|
|
114175
114653
|
|
|
114176
|
-
if (Math .abs (this .rotation .angle) > SPIN_ANGLE &&
|
|
114654
|
+
if (Math .abs (this .rotation .angle) > SPIN_ANGLE && Time_Time .now () - this .motionTime < SPIN_RELEASE_TIME)
|
|
114177
114655
|
this .addSpinning (this .rotation);
|
|
114178
114656
|
|
|
114179
114657
|
this ._isActive = false;
|
|
@@ -114227,13 +114705,13 @@ Object .assign (Object .setPrototypeOf (ExamineViewer .prototype, Navigation_X3D
|
|
|
114227
114705
|
|
|
114228
114706
|
this .rotation .setFromToVec (toVector, this .fromVector);
|
|
114229
114707
|
|
|
114230
|
-
if (Math .abs (this .rotation .angle) < SPIN_ANGLE &&
|
|
114708
|
+
if (Math .abs (this .rotation .angle) < SPIN_ANGLE && Time_Time .now () - this .pressTime < MOTION_TIME)
|
|
114231
114709
|
return;
|
|
114232
114710
|
|
|
114233
114711
|
this .addRotate (this .rotation);
|
|
114234
114712
|
|
|
114235
114713
|
this .fromVector .assign (toVector);
|
|
114236
|
-
this .motionTime =
|
|
114714
|
+
this .motionTime = Time_Time .now ();
|
|
114237
114715
|
break;
|
|
114238
114716
|
}
|
|
114239
114717
|
case 1:
|
|
@@ -114795,8 +115273,8 @@ const ExamineViewer_default_ = ExamineViewer;
|
|
|
114795
115273
|
x_ite_Namespace .set ("x_ite/Browser/Navigation/ExamineViewer", ExamineViewer_default_);
|
|
114796
115274
|
/* harmony default export */ const Navigation_ExamineViewer = (ExamineViewer_default_);
|
|
114797
115275
|
;// CONCATENATED MODULE: ./src/x_ite/Browser/Navigation/X3DFlyViewer.js
|
|
114798
|
-
/* provided dependency */ var X3DFlyViewer_jquery_mousewheel = __webpack_require__(
|
|
114799
|
-
/* provided dependency */ var X3DFlyViewer_$ = __webpack_require__(
|
|
115276
|
+
/* provided dependency */ var X3DFlyViewer_jquery_mousewheel = __webpack_require__(759);
|
|
115277
|
+
/* provided dependency */ var X3DFlyViewer_$ = __webpack_require__(964);
|
|
114800
115278
|
/*******************************************************************************
|
|
114801
115279
|
*
|
|
114802
115280
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -114853,6 +115331,7 @@ x_ite_Namespace .set ("x_ite/Browser/Navigation/ExamineViewer", ExamineViewer_de
|
|
|
114853
115331
|
|
|
114854
115332
|
|
|
114855
115333
|
|
|
115334
|
+
|
|
114856
115335
|
typeof X3DFlyViewer_jquery_mousewheel; // import plugin
|
|
114857
115336
|
|
|
114858
115337
|
const X3DFlyViewer_macOS = /Mac OS X/i .test (navigator .userAgent)
|
|
@@ -115216,7 +115695,7 @@ Object .assign (Object .setPrototypeOf (X3DFlyViewer .prototype, Navigation_X3DV
|
|
|
115216
115695
|
const
|
|
115217
115696
|
navigationInfo = this .getNavigationInfo (),
|
|
115218
115697
|
viewpoint = this .getActiveViewpoint (),
|
|
115219
|
-
now =
|
|
115698
|
+
now = Time_Time .now (),
|
|
115220
115699
|
dt = (now - this .startTime) / 1000;
|
|
115221
115700
|
|
|
115222
115701
|
upVector .assign (viewpoint .getUpVector ());
|
|
@@ -115286,7 +115765,7 @@ Object .assign (Object .setPrototypeOf (X3DFlyViewer .prototype, Navigation_X3DV
|
|
|
115286
115765
|
const
|
|
115287
115766
|
navigationInfo = this .getNavigationInfo (),
|
|
115288
115767
|
viewpoint = this .getActiveViewpoint (),
|
|
115289
|
-
now =
|
|
115768
|
+
now = Time_Time .now (),
|
|
115290
115769
|
dt = (now - this .startTime) / 1000,
|
|
115291
115770
|
upVector = viewpoint .getUpVector ();
|
|
115292
115771
|
|
|
@@ -115324,7 +115803,7 @@ Object .assign (Object .setPrototypeOf (X3DFlyViewer .prototype, Navigation_X3DV
|
|
|
115324
115803
|
this .getBrowser () .prepareEvents () .addInterest ("fly", this);
|
|
115325
115804
|
this .getBrowser () .addBrowserEvent ();
|
|
115326
115805
|
|
|
115327
|
-
this .startTime =
|
|
115806
|
+
this .startTime = Time_Time .now ();
|
|
115328
115807
|
},
|
|
115329
115808
|
addPan ()
|
|
115330
115809
|
{
|
|
@@ -115335,7 +115814,7 @@ Object .assign (Object .setPrototypeOf (X3DFlyViewer .prototype, Navigation_X3DV
|
|
|
115335
115814
|
this .getBrowser () .prepareEvents () .addInterest ("pan", this);
|
|
115336
115815
|
this .getBrowser () .addBrowserEvent ();
|
|
115337
115816
|
|
|
115338
|
-
this .startTime =
|
|
115817
|
+
this .startTime = Time_Time .now ();
|
|
115339
115818
|
},
|
|
115340
115819
|
addRoll: (() =>
|
|
115341
115820
|
{
|
|
@@ -115491,6 +115970,8 @@ Object .assign (Object .setPrototypeOf (X3DFlyViewer .prototype, Navigation_X3DV
|
|
|
115491
115970
|
|
|
115492
115971
|
gl .uniform3f (shaderNode .x3d_EmissiveColor, 1, 1, 1);
|
|
115493
115972
|
gl .drawArrays (gl .LINES, 0, this .lineCount);
|
|
115973
|
+
|
|
115974
|
+
gl .enable (gl .DEPTH_TEST);
|
|
115494
115975
|
};
|
|
115495
115976
|
})(),
|
|
115496
115977
|
disconnect ()
|
|
@@ -115766,8 +116247,8 @@ const FlyViewer_default_ = FlyViewer;
|
|
|
115766
116247
|
x_ite_Namespace .set ("x_ite/Browser/Navigation/FlyViewer", FlyViewer_default_);
|
|
115767
116248
|
/* harmony default export */ const Navigation_FlyViewer = (FlyViewer_default_);
|
|
115768
116249
|
;// CONCATENATED MODULE: ./src/x_ite/Browser/Navigation/PlaneViewer.js
|
|
115769
|
-
/* provided dependency */ var PlaneViewer_jquery_mousewheel = __webpack_require__(
|
|
115770
|
-
/* provided dependency */ var PlaneViewer_$ = __webpack_require__(
|
|
116250
|
+
/* provided dependency */ var PlaneViewer_jquery_mousewheel = __webpack_require__(759);
|
|
116251
|
+
/* provided dependency */ var PlaneViewer_$ = __webpack_require__(964);
|
|
115771
116252
|
/*******************************************************************************
|
|
115772
116253
|
*
|
|
115773
116254
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -116098,8 +116579,8 @@ const NoneViewer_default_ = NoneViewer;
|
|
|
116098
116579
|
x_ite_Namespace .set ("x_ite/Browser/Navigation/NoneViewer", NoneViewer_default_);
|
|
116099
116580
|
/* harmony default export */ const Navigation_NoneViewer = (NoneViewer_default_);
|
|
116100
116581
|
;// CONCATENATED MODULE: ./src/x_ite/Browser/Navigation/LookAtViewer.js
|
|
116101
|
-
/* provided dependency */ var LookAtViewer_jquery_mousewheel = __webpack_require__(
|
|
116102
|
-
/* provided dependency */ var LookAtViewer_$ = __webpack_require__(
|
|
116582
|
+
/* provided dependency */ var LookAtViewer_jquery_mousewheel = __webpack_require__(759);
|
|
116583
|
+
/* provided dependency */ var LookAtViewer_$ = __webpack_require__(964);
|
|
116103
116584
|
/*******************************************************************************
|
|
116104
116585
|
*
|
|
116105
116586
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -117238,8 +117719,8 @@ const X3DPickingContext_default_ = X3DPickingContext;
|
|
|
117238
117719
|
x_ite_Namespace .set ("x_ite/Browser/Picking/X3DPickingContext", X3DPickingContext_default_);
|
|
117239
117720
|
/* harmony default export */ const Picking_X3DPickingContext = (X3DPickingContext_default_);
|
|
117240
117721
|
;// CONCATENATED MODULE: ./src/x_ite/Browser/PointingDeviceSensor/PointingDevice.js
|
|
117241
|
-
/* provided dependency */ var PointingDevice_jquery_mousewheel = __webpack_require__(
|
|
117242
|
-
/* provided dependency */ var PointingDevice_$ = __webpack_require__(
|
|
117722
|
+
/* provided dependency */ var PointingDevice_jquery_mousewheel = __webpack_require__(759);
|
|
117723
|
+
/* provided dependency */ var PointingDevice_$ = __webpack_require__(964);
|
|
117243
117724
|
/*******************************************************************************
|
|
117244
117725
|
*
|
|
117245
117726
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -117575,7 +118056,7 @@ function PointingBuffer (browser)
|
|
|
117575
118056
|
{
|
|
117576
118057
|
const gl = browser .getContext ();
|
|
117577
118058
|
|
|
117578
|
-
this .
|
|
118059
|
+
this .context = gl;
|
|
117579
118060
|
this .array = new Float32Array (4);
|
|
117580
118061
|
|
|
117581
118062
|
// Create frame buffer.
|
|
@@ -117650,7 +118131,7 @@ Object .assign (PointingBuffer .prototype,
|
|
|
117650
118131
|
{
|
|
117651
118132
|
bind ()
|
|
117652
118133
|
{
|
|
117653
|
-
const gl = this .
|
|
118134
|
+
const gl = this .context;
|
|
117654
118135
|
|
|
117655
118136
|
this .lastBuffer = gl .getParameter (gl .FRAMEBUFFER_BINDING);
|
|
117656
118137
|
|
|
@@ -117660,15 +118141,13 @@ Object .assign (PointingBuffer .prototype,
|
|
|
117660
118141
|
},
|
|
117661
118142
|
unbind ()
|
|
117662
118143
|
{
|
|
117663
|
-
const gl = this .
|
|
118144
|
+
const gl = this .context;
|
|
117664
118145
|
|
|
117665
118146
|
gl .bindFramebuffer (gl .FRAMEBUFFER, this .lastBuffer);
|
|
117666
118147
|
},
|
|
117667
118148
|
getHit (hit)
|
|
117668
118149
|
{
|
|
117669
|
-
const
|
|
117670
|
-
gl = this .browser .getContext (),
|
|
117671
|
-
array = this .array;
|
|
118150
|
+
const { context: gl, array } = this;
|
|
117672
118151
|
|
|
117673
118152
|
// Id, point
|
|
117674
118153
|
|
|
@@ -117699,7 +118178,7 @@ Object .assign (PointingBuffer .prototype,
|
|
|
117699
118178
|
},
|
|
117700
118179
|
dispose ()
|
|
117701
118180
|
{
|
|
117702
|
-
const gl = this .
|
|
118181
|
+
const gl = this .context;
|
|
117703
118182
|
|
|
117704
118183
|
gl .deleteFramebuffer (this .frameBuffer);
|
|
117705
118184
|
|
|
@@ -118167,21 +118646,24 @@ x_ite_Namespace .set ("x_ite/Browser/PointingDeviceSensor/X3DPointingDeviceSenso
|
|
|
118167
118646
|
*
|
|
118168
118647
|
******************************************************************************/
|
|
118169
118648
|
|
|
118170
|
-
function MultiSampleFrameBuffer (browser, width, height, samples)
|
|
118649
|
+
function MultiSampleFrameBuffer (browser, width, height, samples, oit)
|
|
118171
118650
|
{
|
|
118172
118651
|
const gl = browser .getContext ();
|
|
118173
118652
|
|
|
118174
118653
|
if (gl .getVersion () === 1 || width === 0 || height === 0)
|
|
118175
118654
|
return Fallback;
|
|
118176
118655
|
|
|
118177
|
-
this .
|
|
118178
|
-
this .width
|
|
118179
|
-
this .height
|
|
118180
|
-
this .samples
|
|
118656
|
+
this .context = gl;
|
|
118657
|
+
this .width = width;
|
|
118658
|
+
this .height = height;
|
|
118659
|
+
this .samples = samples;
|
|
118660
|
+
this .oit = oit;
|
|
118661
|
+
this .lastBuffer = [ ];
|
|
118181
118662
|
|
|
118182
118663
|
// Create frame buffer.
|
|
118183
118664
|
|
|
118184
|
-
this .lastBuffer
|
|
118665
|
+
this .lastBuffer .push (gl .getParameter (gl .FRAMEBUFFER_BINDING));
|
|
118666
|
+
|
|
118185
118667
|
this .frameBuffer = gl .createFramebuffer ();
|
|
118186
118668
|
|
|
118187
118669
|
gl .bindFramebuffer (gl .FRAMEBUFFER, this .frameBuffer);
|
|
@@ -118191,7 +118673,12 @@ function MultiSampleFrameBuffer (browser, width, height, samples)
|
|
|
118191
118673
|
this .colorBuffer = gl .createRenderbuffer ();
|
|
118192
118674
|
|
|
118193
118675
|
gl .bindRenderbuffer (gl .RENDERBUFFER, this .colorBuffer);
|
|
118194
|
-
|
|
118676
|
+
|
|
118677
|
+
if (samples)
|
|
118678
|
+
gl .renderbufferStorageMultisample (gl .RENDERBUFFER, samples, gl .RGBA8, width, height);
|
|
118679
|
+
else
|
|
118680
|
+
gl .renderbufferStorage (gl .RENDERBUFFER, gl .RGBA8, width, height);
|
|
118681
|
+
|
|
118195
118682
|
gl .framebufferRenderbuffer (gl .FRAMEBUFFER, gl .COLOR_ATTACHMENT0, gl .RENDERBUFFER, this .colorBuffer);
|
|
118196
118683
|
|
|
118197
118684
|
// Create depth buffer.
|
|
@@ -118199,17 +118686,168 @@ function MultiSampleFrameBuffer (browser, width, height, samples)
|
|
|
118199
118686
|
this .depthBuffer = gl .createRenderbuffer ();
|
|
118200
118687
|
|
|
118201
118688
|
gl .bindRenderbuffer (gl .RENDERBUFFER, this .depthBuffer);
|
|
118202
|
-
gl .renderbufferStorageMultisample (gl .RENDERBUFFER, this .samples, gl .DEPTH_COMPONENT24, width, height);
|
|
118203
|
-
gl .framebufferRenderbuffer (gl .FRAMEBUFFER, gl .DEPTH_ATTACHMENT, gl .RENDERBUFFER, this .depthBuffer);
|
|
118204
118689
|
|
|
118205
|
-
|
|
118690
|
+
if (samples)
|
|
118691
|
+
gl .renderbufferStorageMultisample (gl .RENDERBUFFER, samples, gl .DEPTH_COMPONENT24, width, height);
|
|
118692
|
+
else
|
|
118693
|
+
gl .renderbufferStorage (gl .RENDERBUFFER, gl .DEPTH_COMPONENT24, width, height);
|
|
118206
118694
|
|
|
118207
|
-
gl .
|
|
118695
|
+
gl .framebufferRenderbuffer (gl .FRAMEBUFFER, gl .DEPTH_ATTACHMENT, gl .RENDERBUFFER, this .depthBuffer);
|
|
118696
|
+
|
|
118697
|
+
const status1 = gl .checkFramebufferStatus (gl .FRAMEBUFFER) === gl .FRAMEBUFFER_COMPLETE;
|
|
118698
|
+
|
|
118699
|
+
gl .bindFramebuffer (gl .FRAMEBUFFER, this .lastBuffer .pop ());
|
|
118208
118700
|
|
|
118209
118701
|
// Always check that our frame buffer is ok.
|
|
118210
118702
|
|
|
118211
|
-
if (!
|
|
118703
|
+
if (!status1)
|
|
118212
118704
|
throw new Error ("Couldn't create frame buffer.");
|
|
118705
|
+
|
|
118706
|
+
if (!oit)
|
|
118707
|
+
return;
|
|
118708
|
+
|
|
118709
|
+
// Create oit frame buffer.
|
|
118710
|
+
|
|
118711
|
+
this .lastBuffer .push (gl .getParameter (gl .FRAMEBUFFER_BINDING));
|
|
118712
|
+
|
|
118713
|
+
this .oitFrameBuffer = gl .createFramebuffer ();
|
|
118714
|
+
|
|
118715
|
+
gl .bindFramebuffer (gl .FRAMEBUFFER, this .oitFrameBuffer);
|
|
118716
|
+
|
|
118717
|
+
// Set draw buffers.
|
|
118718
|
+
|
|
118719
|
+
gl .drawBuffers ([
|
|
118720
|
+
gl .COLOR_ATTACHMENT0, // gl_FragData [0]
|
|
118721
|
+
gl .COLOR_ATTACHMENT1, // gl_FragData [1]
|
|
118722
|
+
]);
|
|
118723
|
+
|
|
118724
|
+
if (samples)
|
|
118725
|
+
{
|
|
118726
|
+
// Create accum and revealage buffer.
|
|
118727
|
+
|
|
118728
|
+
this .accumRevealageBuffer = gl .createRenderbuffer ();
|
|
118729
|
+
|
|
118730
|
+
gl .bindRenderbuffer (gl .RENDERBUFFER, this .accumRevealageBuffer);
|
|
118731
|
+
gl .renderbufferStorageMultisample (gl .RENDERBUFFER, samples, gl .RGBA32F, width, height);
|
|
118732
|
+
gl .framebufferRenderbuffer (gl .FRAMEBUFFER, gl .COLOR_ATTACHMENT0, gl .RENDERBUFFER, this .accumRevealageBuffer);
|
|
118733
|
+
|
|
118734
|
+
// Create alpha buffer.
|
|
118735
|
+
|
|
118736
|
+
this .alphaBuffer = gl .createRenderbuffer ();
|
|
118737
|
+
|
|
118738
|
+
gl .bindRenderbuffer (gl .RENDERBUFFER, this .alphaBuffer);
|
|
118739
|
+
gl .renderbufferStorageMultisample (gl .RENDERBUFFER, samples, gl .RGBA32F, width, height);
|
|
118740
|
+
gl .framebufferRenderbuffer (gl .FRAMEBUFFER, gl .COLOR_ATTACHMENT1, gl .RENDERBUFFER, this .alphaBuffer);
|
|
118741
|
+
|
|
118742
|
+
// Add depth buffer.
|
|
118743
|
+
|
|
118744
|
+
gl .framebufferRenderbuffer (gl .FRAMEBUFFER, gl .DEPTH_ATTACHMENT, gl .RENDERBUFFER, this .depthBuffer);
|
|
118745
|
+
|
|
118746
|
+
// Create accum texture buffer.
|
|
118747
|
+
|
|
118748
|
+
this .accumRevealageTextureBuffer = gl .createFramebuffer ();
|
|
118749
|
+
|
|
118750
|
+
gl .bindFramebuffer (gl .FRAMEBUFFER, this .accumRevealageTextureBuffer);
|
|
118751
|
+
|
|
118752
|
+
// Create accum texture.
|
|
118753
|
+
|
|
118754
|
+
this .accumRevealageTexture = gl .createTexture ();
|
|
118755
|
+
|
|
118756
|
+
gl .bindTexture (gl .TEXTURE_2D, this .accumRevealageTexture);
|
|
118757
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_WRAP_S, gl .CLAMP_TO_EDGE);
|
|
118758
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_WRAP_T, gl .CLAMP_TO_EDGE);
|
|
118759
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_MIN_FILTER, gl .NEAREST);
|
|
118760
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_MAG_FILTER, gl .NEAREST);
|
|
118761
|
+
|
|
118762
|
+
gl .texImage2D (gl .TEXTURE_2D, 0, gl .RGBA32F, width, height, 0, gl .RGBA, gl .FLOAT, null);
|
|
118763
|
+
gl .framebufferTexture2D (gl .FRAMEBUFFER, gl .COLOR_ATTACHMENT0, gl .TEXTURE_2D, this .accumRevealageTexture, 0);
|
|
118764
|
+
|
|
118765
|
+
// Create alpha texture buffer.
|
|
118766
|
+
|
|
118767
|
+
this .alphaTextureBuffer = gl .createFramebuffer ();
|
|
118768
|
+
|
|
118769
|
+
gl .bindFramebuffer (gl .FRAMEBUFFER, this .alphaTextureBuffer);
|
|
118770
|
+
|
|
118771
|
+
// Create alpha texture.
|
|
118772
|
+
|
|
118773
|
+
this .alphaTexture = gl .createTexture ();
|
|
118774
|
+
|
|
118775
|
+
gl .bindTexture (gl .TEXTURE_2D, this .alphaTexture);
|
|
118776
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_WRAP_S, gl .CLAMP_TO_EDGE);
|
|
118777
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_WRAP_T, gl .CLAMP_TO_EDGE);
|
|
118778
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_MIN_FILTER, gl .NEAREST);
|
|
118779
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_MAG_FILTER, gl .NEAREST);
|
|
118780
|
+
|
|
118781
|
+
gl .texImage2D (gl .TEXTURE_2D, 0, gl .RGBA32F, width, height, 0, gl .RGBA, gl .FLOAT, null);
|
|
118782
|
+
gl .framebufferTexture2D (gl .FRAMEBUFFER, gl .COLOR_ATTACHMENT0, gl .TEXTURE_2D, this .alphaTexture, 0);
|
|
118783
|
+
}
|
|
118784
|
+
else
|
|
118785
|
+
{
|
|
118786
|
+
// Create accum texture.
|
|
118787
|
+
|
|
118788
|
+
this .accumRevealageTexture = gl .createTexture ();
|
|
118789
|
+
|
|
118790
|
+
gl .bindTexture (gl .TEXTURE_2D, this .accumRevealageTexture);
|
|
118791
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_WRAP_S, gl .CLAMP_TO_EDGE);
|
|
118792
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_WRAP_T, gl .CLAMP_TO_EDGE);
|
|
118793
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_MIN_FILTER, gl .NEAREST);
|
|
118794
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_MAG_FILTER, gl .NEAREST);
|
|
118795
|
+
|
|
118796
|
+
gl .texImage2D (gl .TEXTURE_2D, 0, gl .RGBA32F, width, height, 0, gl .RGBA, gl .FLOAT, null);
|
|
118797
|
+
gl .framebufferTexture2D (gl .FRAMEBUFFER, gl .COLOR_ATTACHMENT0, gl .TEXTURE_2D, this .accumRevealageTexture, 0);
|
|
118798
|
+
|
|
118799
|
+
// Create alpha texture.
|
|
118800
|
+
|
|
118801
|
+
this .alphaTexture = gl .createTexture ();
|
|
118802
|
+
|
|
118803
|
+
gl .bindTexture (gl .TEXTURE_2D, this .alphaTexture);
|
|
118804
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_WRAP_S, gl .CLAMP_TO_EDGE);
|
|
118805
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_WRAP_T, gl .CLAMP_TO_EDGE);
|
|
118806
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_MIN_FILTER, gl .NEAREST);
|
|
118807
|
+
gl .texParameteri (gl .TEXTURE_2D, gl .TEXTURE_MAG_FILTER, gl .NEAREST);
|
|
118808
|
+
|
|
118809
|
+
gl .texImage2D (gl .TEXTURE_2D, 0, gl .RGBA32F, width, height, 0, gl .RGBA, gl .FLOAT, null);
|
|
118810
|
+
gl .framebufferTexture2D (gl .FRAMEBUFFER, gl .COLOR_ATTACHMENT1, gl .TEXTURE_2D, this .alphaTexture, 0);
|
|
118811
|
+
|
|
118812
|
+
// Add depth buffer.
|
|
118813
|
+
|
|
118814
|
+
gl .framebufferRenderbuffer (gl .FRAMEBUFFER, gl .DEPTH_ATTACHMENT, gl .RENDERBUFFER, this .depthBuffer);
|
|
118815
|
+
}
|
|
118816
|
+
|
|
118817
|
+
const status2 = gl .checkFramebufferStatus (gl .FRAMEBUFFER) === gl .FRAMEBUFFER_COMPLETE;
|
|
118818
|
+
|
|
118819
|
+
gl .bindTexture (gl .TEXTURE_2D, null);
|
|
118820
|
+
gl .bindFramebuffer (gl .FRAMEBUFFER, this .lastBuffer .pop ());
|
|
118821
|
+
|
|
118822
|
+
// Always check that our frame buffer is ok.
|
|
118823
|
+
|
|
118824
|
+
if (!status2)
|
|
118825
|
+
throw new Error ("Couldn't create frame buffer.");
|
|
118826
|
+
|
|
118827
|
+
// Get compose shader and texture units.
|
|
118828
|
+
|
|
118829
|
+
this .shaderNode = browser .getComposeShader ();
|
|
118830
|
+
this .program = this .shaderNode .getProgram ();
|
|
118831
|
+
|
|
118832
|
+
gl .useProgram (this .program);
|
|
118833
|
+
|
|
118834
|
+
const
|
|
118835
|
+
accumRevealageTextureUnit = gl .getUniformLocation (this .program, "x3d_AccumRevealageTexture"),
|
|
118836
|
+
alphaTextureUnit = gl .getUniformLocation (this .program, "x3d_AlphaTexture");
|
|
118837
|
+
|
|
118838
|
+
gl .uniform1i (accumRevealageTextureUnit, 0);
|
|
118839
|
+
gl .uniform1i (alphaTextureUnit, 1);
|
|
118840
|
+
|
|
118841
|
+
// Quad for compose pass.
|
|
118842
|
+
|
|
118843
|
+
this .quadArray = gl .createVertexArray ();
|
|
118844
|
+
this .quadBuffer = gl .createBuffer ();
|
|
118845
|
+
|
|
118846
|
+
gl .bindVertexArray (this .quadArray);
|
|
118847
|
+
gl .bindBuffer (gl .ARRAY_BUFFER, this .quadBuffer);
|
|
118848
|
+
gl .bufferData (gl .ARRAY_BUFFER, new Float32Array ([-1, 1, -1, -1, 1, -1, -1, 1, 1, -1, 1, 1]), gl .STATIC_DRAW);
|
|
118849
|
+
gl .vertexAttribPointer (0, 2, gl .FLOAT, false, 0, 0);
|
|
118850
|
+
gl .enableVertexAttribArray (null);
|
|
118213
118851
|
}
|
|
118214
118852
|
|
|
118215
118853
|
Object .assign (MultiSampleFrameBuffer .prototype,
|
|
@@ -118226,42 +118864,118 @@ Object .assign (MultiSampleFrameBuffer .prototype,
|
|
|
118226
118864
|
{
|
|
118227
118865
|
return this .samples;
|
|
118228
118866
|
},
|
|
118867
|
+
getOrderIndependentTransparency ()
|
|
118868
|
+
{
|
|
118869
|
+
return this .oit;
|
|
118870
|
+
},
|
|
118229
118871
|
bind ()
|
|
118230
118872
|
{
|
|
118231
|
-
const gl
|
|
118873
|
+
const { context: gl, lastBuffer, frameBuffer } = this;
|
|
118232
118874
|
|
|
118233
|
-
|
|
118875
|
+
lastBuffer .push (gl .getParameter (gl .FRAMEBUFFER_BINDING));
|
|
118234
118876
|
|
|
118235
|
-
gl .bindFramebuffer (gl .FRAMEBUFFER,
|
|
118877
|
+
gl .bindFramebuffer (gl .FRAMEBUFFER, frameBuffer);
|
|
118878
|
+
|
|
118879
|
+
gl .clearColor (0, 0, 0, 0);
|
|
118880
|
+
gl .clear (gl .COLOR_BUFFER_BIT);
|
|
118236
118881
|
},
|
|
118237
|
-
|
|
118882
|
+
bindForOrderIndependentTransparency ()
|
|
118238
118883
|
{
|
|
118239
|
-
const gl
|
|
118884
|
+
const { context: gl, lastBuffer, oitFrameBuffer } = this;
|
|
118240
118885
|
|
|
118241
|
-
|
|
118886
|
+
lastBuffer .push (gl .getParameter (gl .FRAMEBUFFER_BINDING));
|
|
118887
|
+
|
|
118888
|
+
gl .bindFramebuffer (gl .FRAMEBUFFER, oitFrameBuffer);
|
|
118889
|
+
|
|
118890
|
+
gl .clearColor (0, 0, 0, 1);
|
|
118891
|
+
gl .clear (gl .COLOR_BUFFER_BIT);
|
|
118892
|
+
gl .blendFuncSeparate (gl .ONE, gl .ONE, gl .ZERO, gl .ONE_MINUS_SRC_ALPHA);
|
|
118242
118893
|
},
|
|
118243
118894
|
blit ()
|
|
118244
118895
|
{
|
|
118245
|
-
const gl
|
|
118896
|
+
const { context: gl, width, height, samples } = this;
|
|
118246
118897
|
|
|
118247
118898
|
// Reset viewport before blit, otherwise only last layer size is used.
|
|
118248
|
-
gl .viewport (0, 0,
|
|
118249
|
-
gl .scissor (0, 0,
|
|
118899
|
+
gl .viewport (0, 0, width, height);
|
|
118900
|
+
gl .scissor (0, 0, width, height);
|
|
118250
118901
|
|
|
118251
118902
|
gl .bindFramebuffer (gl .READ_FRAMEBUFFER, this .frameBuffer);
|
|
118252
118903
|
gl .bindFramebuffer (gl .DRAW_FRAMEBUFFER, null);
|
|
118253
118904
|
|
|
118254
|
-
gl .blitFramebuffer (0, 0,
|
|
118255
|
-
0, 0,
|
|
118256
|
-
gl .COLOR_BUFFER_BIT, gl .LINEAR);
|
|
118905
|
+
gl .blitFramebuffer (0, 0, width, height,
|
|
118906
|
+
0, 0, width, height,
|
|
118907
|
+
gl .COLOR_BUFFER_BIT, samples ? gl .LINEAR : gl .NEAREST);
|
|
118908
|
+
},
|
|
118909
|
+
compose ()
|
|
118910
|
+
{
|
|
118911
|
+
const { context: gl, width, height, samples, program } = this;
|
|
118912
|
+
|
|
118913
|
+
// TODO: Combining lights and lights with shadows, can cause feedback loop of texture.
|
|
118914
|
+
// TODO: VolumeRendering shader is not made for OIT.
|
|
118915
|
+
|
|
118916
|
+
// Reset viewport before blit, otherwise only last layer size is used.
|
|
118917
|
+
gl .viewport (0, 0, width, height);
|
|
118918
|
+
gl .scissor (0, 0, width, height);
|
|
118919
|
+
|
|
118920
|
+
if (samples)
|
|
118921
|
+
{
|
|
118922
|
+
gl .bindFramebuffer (gl .READ_FRAMEBUFFER, this .oitFrameBuffer);
|
|
118923
|
+
|
|
118924
|
+
gl .readBuffer (gl .COLOR_ATTACHMENT0);
|
|
118925
|
+
gl .bindFramebuffer (gl .DRAW_FRAMEBUFFER, this .accumRevealageTextureBuffer);
|
|
118926
|
+
|
|
118927
|
+
gl .blitFramebuffer (0, 0, width, height,
|
|
118928
|
+
0, 0, width, height,
|
|
118929
|
+
gl .COLOR_BUFFER_BIT, gl .LINEAR);
|
|
118930
|
+
|
|
118931
|
+
gl .readBuffer (gl .COLOR_ATTACHMENT1);
|
|
118932
|
+
gl .bindFramebuffer (gl .DRAW_FRAMEBUFFER, this .alphaTextureBuffer);
|
|
118933
|
+
|
|
118934
|
+
gl .blitFramebuffer (0, 0, width, height,
|
|
118935
|
+
0, 0, width, height,
|
|
118936
|
+
gl .COLOR_BUFFER_BIT, gl .LINEAR);
|
|
118937
|
+
}
|
|
118938
|
+
|
|
118939
|
+
gl .useProgram (program);
|
|
118940
|
+
gl .activeTexture (gl .TEXTURE0 + 0);
|
|
118941
|
+
gl .bindTexture (gl .TEXTURE_2D, this .accumRevealageTexture);
|
|
118942
|
+
gl .activeTexture (gl .TEXTURE0 + 1);
|
|
118943
|
+
gl .bindTexture (gl .TEXTURE_2D, this .alphaTexture);
|
|
118944
|
+
|
|
118945
|
+
gl .bindFramebuffer (gl .FRAMEBUFFER, this .frameBuffer);
|
|
118946
|
+
gl .disable (gl .DEPTH_TEST);
|
|
118947
|
+
gl .enable (gl .BLEND);
|
|
118948
|
+
gl .blendFunc (gl .ONE, gl .ONE_MINUS_SRC_ALPHA);
|
|
118949
|
+
gl .enable (gl .CULL_FACE);
|
|
118950
|
+
gl .frontFace (gl .CCW);
|
|
118951
|
+
gl .bindVertexArray (this .quadArray);
|
|
118952
|
+
gl .drawArrays (gl .TRIANGLES, 0, 6);
|
|
118953
|
+
gl .disable (gl .BLEND);
|
|
118954
|
+
gl .enable (gl .DEPTH_TEST);
|
|
118955
|
+
},
|
|
118956
|
+
unbind ()
|
|
118957
|
+
{
|
|
118958
|
+
const { context: gl, lastBuffer } = this;
|
|
118959
|
+
|
|
118960
|
+
gl .bindFramebuffer (gl .FRAMEBUFFER, lastBuffer .pop ());
|
|
118257
118961
|
},
|
|
118258
118962
|
dispose ()
|
|
118259
118963
|
{
|
|
118260
|
-
const gl = this .
|
|
118964
|
+
const gl = this .context;
|
|
118261
118965
|
|
|
118262
118966
|
gl .deleteFramebuffer (this .frameBuffer);
|
|
118263
118967
|
gl .deleteRenderbuffer (this .colorBuffer);
|
|
118264
118968
|
gl .deleteRenderbuffer (this .depthBuffer);
|
|
118969
|
+
|
|
118970
|
+
gl .deleteFramebuffer (this .oitFrameBuffer);
|
|
118971
|
+
gl .deleteFramebuffer (this .accumRevealageTextureBuffer);
|
|
118972
|
+
gl .deleteFramebuffer (this .alphaTextureBuffer);
|
|
118973
|
+
gl .deleteRenderbuffer (this .accumRevealageBuffer);
|
|
118974
|
+
gl .deleteRenderbuffer (this .alphaBuffer);
|
|
118975
|
+
gl .deleteTexture (this .accumRevealageTexture);
|
|
118976
|
+
gl .deleteTexture (this .alphaTexture)
|
|
118977
|
+
gl .deleteVertexArray (this .quadArray);
|
|
118978
|
+
gl .deleteBuffer (this .quadBuffer);
|
|
118265
118979
|
},
|
|
118266
118980
|
});
|
|
118267
118981
|
|
|
@@ -118269,9 +118983,12 @@ const Fallback = {
|
|
|
118269
118983
|
getWidth: Function .prototype,
|
|
118270
118984
|
getHeight: Function .prototype,
|
|
118271
118985
|
getSamples: Function .prototype,
|
|
118986
|
+
getOrderIndependentTransparency: Function .prototype,
|
|
118272
118987
|
bind: Function .prototype,
|
|
118273
|
-
|
|
118988
|
+
clear: Function .prototype,
|
|
118274
118989
|
blit: Function .prototype,
|
|
118990
|
+
compose: Function .prototype,
|
|
118991
|
+
unbind: Function .prototype,
|
|
118275
118992
|
dispose: Function .prototype,
|
|
118276
118993
|
};
|
|
118277
118994
|
|
|
@@ -118281,8 +118998,8 @@ const MultiSampleFrameBuffer_default_ = MultiSampleFrameBuffer;
|
|
|
118281
118998
|
x_ite_Namespace .set ("x_ite/Rendering/MultiSampleFrameBuffer", MultiSampleFrameBuffer_default_);
|
|
118282
118999
|
/* harmony default export */ const Rendering_MultiSampleFrameBuffer = (MultiSampleFrameBuffer_default_);
|
|
118283
119000
|
;// CONCATENATED MODULE: ./src/x_ite/Browser/Rendering/X3DRenderingContext.js
|
|
118284
|
-
/* provided dependency */ var X3DRenderingContext_$ = __webpack_require__(
|
|
118285
|
-
/* provided dependency */ var ResizeSensor = __webpack_require__(
|
|
119001
|
+
/* provided dependency */ var X3DRenderingContext_$ = __webpack_require__(964);
|
|
119002
|
+
/* provided dependency */ var ResizeSensor = __webpack_require__(672);
|
|
118286
119003
|
/*******************************************************************************
|
|
118287
119004
|
*
|
|
118288
119005
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -118334,11 +119051,12 @@ x_ite_Namespace .set ("x_ite/Rendering/MultiSampleFrameBuffer", MultiSampleFrame
|
|
|
118334
119051
|
|
|
118335
119052
|
|
|
118336
119053
|
const
|
|
118337
|
-
_viewport
|
|
118338
|
-
_frameBuffer
|
|
118339
|
-
_resizer
|
|
118340
|
-
_localObjects
|
|
118341
|
-
|
|
119054
|
+
_viewport = Symbol (),
|
|
119055
|
+
_frameBuffer = Symbol (),
|
|
119056
|
+
_resizer = Symbol (),
|
|
119057
|
+
_localObjects = Symbol (),
|
|
119058
|
+
_composeShader = Symbol (),
|
|
119059
|
+
_depthShaders = Symbol ();
|
|
118342
119060
|
|
|
118343
119061
|
function X3DRenderingContext ()
|
|
118344
119062
|
{
|
|
@@ -118357,6 +119075,7 @@ Object .assign (X3DRenderingContext .prototype,
|
|
|
118357
119075
|
const gl = this .getContext ();
|
|
118358
119076
|
|
|
118359
119077
|
gl .enable (gl .SCISSOR_TEST);
|
|
119078
|
+
gl .enable (gl .DEPTH_TEST);
|
|
118360
119079
|
gl .depthFunc (gl .LEQUAL);
|
|
118361
119080
|
gl .clearDepth (1);
|
|
118362
119081
|
|
|
@@ -118408,12 +119127,6 @@ Object .assign (X3DRenderingContext .prototype,
|
|
|
118408
119127
|
|
|
118409
119128
|
return gl .getParameter (gl .VERSION);
|
|
118410
119129
|
},
|
|
118411
|
-
getAntialiased ()
|
|
118412
|
-
{
|
|
118413
|
-
const gl = this .getContext ();
|
|
118414
|
-
|
|
118415
|
-
return gl .getParameter (gl .SAMPLES) > 0 || (gl .getVersion () > 1 && this .getRenderingProperty ("Multisampling") > 0);
|
|
118416
|
-
},
|
|
118417
119130
|
getMaxSamples ()
|
|
118418
119131
|
{
|
|
118419
119132
|
const gl = this .getContext ();
|
|
@@ -118451,6 +119164,13 @@ Object .assign (X3DRenderingContext .prototype,
|
|
|
118451
119164
|
{
|
|
118452
119165
|
return this [_frameBuffer];
|
|
118453
119166
|
},
|
|
119167
|
+
getComposeShader ()
|
|
119168
|
+
{
|
|
119169
|
+
if (this [_composeShader])
|
|
119170
|
+
return this [_composeShader];
|
|
119171
|
+
|
|
119172
|
+
return this [_composeShader] = this .createShader ("ComposeShader", "Compose", "Compose");
|
|
119173
|
+
},
|
|
118454
119174
|
getDepthShader (numClipPlanes, shapeNode, humanoidNode)
|
|
118455
119175
|
{
|
|
118456
119176
|
const geometryContext = shapeNode .getGeometryContext ();
|
|
@@ -118516,6 +119236,7 @@ Object .assign (X3DRenderingContext .prototype,
|
|
|
118516
119236
|
$canvas = this .getCanvas (),
|
|
118517
119237
|
contentScale = this .getRenderingProperty ("ContentScale"),
|
|
118518
119238
|
samples = this .getRenderingProperty ("Multisampling"),
|
|
119239
|
+
oit = this .getBrowserOption ("OrderIndependentTransparency"),
|
|
118519
119240
|
width = $canvas .width () * contentScale,
|
|
118520
119241
|
height = $canvas .height () * contentScale,
|
|
118521
119242
|
canvas = $canvas [0];
|
|
@@ -118526,12 +119247,13 @@ Object .assign (X3DRenderingContext .prototype,
|
|
|
118526
119247
|
this [_viewport] [2] = width;
|
|
118527
119248
|
this [_viewport] [3] = height;
|
|
118528
119249
|
|
|
118529
|
-
if (width !== this [_frameBuffer] .getWidth ()
|
|
118530
|
-
height !== this [_frameBuffer] .getHeight ()
|
|
118531
|
-
samples !== this [_frameBuffer] .getSamples ()
|
|
119250
|
+
if (width !== this [_frameBuffer] .getWidth () ||
|
|
119251
|
+
height !== this [_frameBuffer] .getHeight () ||
|
|
119252
|
+
samples !== this [_frameBuffer] .getSamples () ||
|
|
119253
|
+
oit !== this [_frameBuffer] .getOrderIndependentTransparency ())
|
|
118532
119254
|
{
|
|
118533
119255
|
this [_frameBuffer] .dispose ();
|
|
118534
|
-
this [_frameBuffer] = new Rendering_MultiSampleFrameBuffer (this, width, height, samples);
|
|
119256
|
+
this [_frameBuffer] = new Rendering_MultiSampleFrameBuffer (this, width, height, samples, oit);
|
|
118535
119257
|
}
|
|
118536
119258
|
|
|
118537
119259
|
this .addBrowserEvent ();
|
|
@@ -119490,6 +120212,7 @@ x_ite_Namespace .set ("x_ite/Browser/Texturing/X3DTexturingContext", X3DTexturin
|
|
|
119490
120212
|
|
|
119491
120213
|
|
|
119492
120214
|
|
|
120215
|
+
|
|
119493
120216
|
const
|
|
119494
120217
|
_currentTime = Symbol (),
|
|
119495
120218
|
_currentFrameRate = Symbol (),
|
|
@@ -119498,7 +120221,7 @@ const
|
|
|
119498
120221
|
|
|
119499
120222
|
function X3DTimeContext ()
|
|
119500
120223
|
{
|
|
119501
|
-
this [_currentTime] =
|
|
120224
|
+
this [_currentTime] = Time_Time .now () / 1000;
|
|
119502
120225
|
this [_currentFrameRate] = 60;
|
|
119503
120226
|
this [_currentPosition] = new Numbers_Vector3 (0, 0, 0);
|
|
119504
120227
|
this [_currentSpeed] = 0;
|
|
@@ -119525,7 +120248,7 @@ Object .assign (X3DTimeContext .prototype,
|
|
|
119525
120248
|
return function ()
|
|
119526
120249
|
{
|
|
119527
120250
|
const
|
|
119528
|
-
time =
|
|
120251
|
+
time = Time_Time .now () / 1000,
|
|
119529
120252
|
interval = time - this [_currentTime];
|
|
119530
120253
|
|
|
119531
120254
|
this [_currentTime] = time;
|
|
@@ -120263,13 +120986,8 @@ Object .assign (Object .setPrototypeOf (X3DBrowserContext .prototype, Base_X3DBa
|
|
|
120263
120986
|
this .addTaintedField (this ._displayEvents);
|
|
120264
120987
|
this [_processEvents] ();
|
|
120265
120988
|
|
|
120266
|
-
const gl = this .getContext ();
|
|
120267
|
-
|
|
120268
120989
|
this .getFrameBuffer () .bind ();
|
|
120269
120990
|
|
|
120270
|
-
gl .clearColor (0, 0, 0, 0);
|
|
120271
|
-
gl .clear (gl .COLOR_BUFFER_BIT);
|
|
120272
|
-
|
|
120273
120991
|
this [_world] .traverse (Rendering_TraverseType .DISPLAY);
|
|
120274
120992
|
|
|
120275
120993
|
this .getFrameBuffer () .blit ();
|
|
@@ -120500,7 +121218,7 @@ Components .add (Components_Shaders);
|
|
|
120500
121218
|
Components .add (Components_Shape);
|
|
120501
121219
|
Components .add (Components_Sound);
|
|
120502
121220
|
Components .add (Texturing);
|
|
120503
|
-
Components .add (
|
|
121221
|
+
Components .add (Components_Time);
|
|
120504
121222
|
|
|
120505
121223
|
external = true;
|
|
120506
121224
|
|
|
@@ -120510,7 +121228,7 @@ const Components_default_ = Components;
|
|
|
120510
121228
|
x_ite_Namespace .set ("x_ite/Components", Components_default_);
|
|
120511
121229
|
/* harmony default export */ const x_ite_Components = ((/* unused pure expression or super */ null && (Components_default_)));
|
|
120512
121230
|
;// CONCATENATED MODULE: ./src/x_ite/Browser/DOMIntegration.js
|
|
120513
|
-
/* provided dependency */ var DOMIntegration_$ = __webpack_require__(
|
|
121231
|
+
/* provided dependency */ var DOMIntegration_$ = __webpack_require__(964);
|
|
120514
121232
|
/*******************************************************************************
|
|
120515
121233
|
* MIT License
|
|
120516
121234
|
*
|
|
@@ -120872,9 +121590,6 @@ class DOMIntegration
|
|
|
120872
121590
|
return;
|
|
120873
121591
|
|
|
120874
121592
|
field .addInterest ("fieldCallback", this, element);
|
|
120875
|
-
|
|
120876
|
-
if (this .trace)
|
|
120877
|
-
field .addInterest ("fieldTraceCallback", this, element);
|
|
120878
121593
|
}
|
|
120879
121594
|
|
|
120880
121595
|
fieldCallback (element, field)
|
|
@@ -120894,20 +121609,6 @@ class DOMIntegration
|
|
|
120894
121609
|
|
|
120895
121610
|
element .dispatchEvent (event);
|
|
120896
121611
|
}
|
|
120897
|
-
|
|
120898
|
-
fieldTraceCallback (element, field)
|
|
120899
|
-
{
|
|
120900
|
-
const
|
|
120901
|
-
now = Date .now (),
|
|
120902
|
-
timeStamp = node .getBrowser () .getCurrentTime (),
|
|
120903
|
-
dt = now - timeStamp * 1000,
|
|
120904
|
-
node = DOMIntegration_$.data (element, "node");
|
|
120905
|
-
|
|
120906
|
-
console .log ("%f: at %f dt of %s ms %s '%s' %s: %s",
|
|
120907
|
-
now, timeStamp, dt .toFixed (3),
|
|
120908
|
-
node .getTypeName (), node .getName (),
|
|
120909
|
-
field .getName (), field .valueOf ());
|
|
120910
|
-
}
|
|
120911
121612
|
};
|
|
120912
121613
|
|
|
120913
121614
|
const DOMIntegration_default_ = DOMIntegration;
|
|
@@ -120916,7 +121617,7 @@ const DOMIntegration_default_ = DOMIntegration;
|
|
|
120916
121617
|
x_ite_Namespace .set ("x_ite/Browser/DOMIntegration", DOMIntegration_default_);
|
|
120917
121618
|
/* harmony default export */ const Browser_DOMIntegration = (DOMIntegration_default_);
|
|
120918
121619
|
;// CONCATENATED MODULE: ./src/x_ite/Browser/Legacy.js
|
|
120919
|
-
/* provided dependency */ var Legacy_$ = __webpack_require__(
|
|
121620
|
+
/* provided dependency */ var Legacy_$ = __webpack_require__(964);
|
|
120920
121621
|
/*******************************************************************************
|
|
120921
121622
|
*
|
|
120922
121623
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -121747,7 +122448,7 @@ const SupportedProfiles_default_ = SupportedProfiles;
|
|
|
121747
122448
|
x_ite_Namespace .set ("x_ite/Configuration/SupportedProfiles", SupportedProfiles_default_);
|
|
121748
122449
|
/* harmony default export */ const Configuration_SupportedProfiles = (SupportedProfiles_default_);
|
|
121749
122450
|
;// CONCATENATED MODULE: ./src/x_ite/Browser/X3DBrowser.js
|
|
121750
|
-
/* provided dependency */ var X3DBrowser_$ = __webpack_require__(
|
|
122451
|
+
/* provided dependency */ var X3DBrowser_$ = __webpack_require__(964);
|
|
121751
122452
|
/*******************************************************************************
|
|
121752
122453
|
*
|
|
121753
122454
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -121893,7 +122594,7 @@ Object .assign (Object .setPrototypeOf (X3DBrowser .prototype, Browser_X3DBrowse
|
|
|
121893
122594
|
` WebGL version: ${this .getWebGLVersion ()}\n` +
|
|
121894
122595
|
` Shading language: ${this .getShadingLanguageVersion ()}\n` +
|
|
121895
122596
|
` Rendering Properties\n` +
|
|
121896
|
-
` Antialiased: ${this .
|
|
122597
|
+
` Antialiased: ${this .getRenderingProperty ("Antialiased")}\n` +
|
|
121897
122598
|
` Max samples: ${this .getMaxSamples ()}\n` +
|
|
121898
122599
|
` Depth size: ${this .getDepthSize ()} bits\n` +
|
|
121899
122600
|
` Color depth: ${this .getColorDepth ()} bits\n` +
|
|
@@ -122182,7 +122883,6 @@ Object .assign (Object .setPrototypeOf (X3DBrowser .prototype, Browser_X3DBrowse
|
|
|
122182
122883
|
// Replace.
|
|
122183
122884
|
|
|
122184
122885
|
this .setDescription ("");
|
|
122185
|
-
this .getBrowserOptions () .configure ();
|
|
122186
122886
|
this .setBrowserLoading (true);
|
|
122187
122887
|
this ._loadCount .addInterest ("checkLoadCount", this, resolve);
|
|
122188
122888
|
|
|
@@ -122813,98 +123513,9 @@ const X3DBrowser_default_ = X3DBrowser;
|
|
|
122813
123513
|
|
|
122814
123514
|
x_ite_Namespace .set ("x_ite/Browser/X3DBrowser", X3DBrowser_default_);
|
|
122815
123515
|
/* harmony default export */ const Browser_X3DBrowser = (X3DBrowser_default_);
|
|
122816
|
-
;// CONCATENATED MODULE: ./src/standard/Time/MicroTime.js
|
|
122817
|
-
/*******************************************************************************
|
|
122818
|
-
*
|
|
122819
|
-
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
122820
|
-
*
|
|
122821
|
-
* Copyright create3000, Scheffelstraße 31a, Leipzig, Germany 2011 - 2022.
|
|
122822
|
-
*
|
|
122823
|
-
* All rights reserved. Holger Seelig <holger.seelig@yahoo.de>.
|
|
122824
|
-
*
|
|
122825
|
-
* The copyright notice above does not evidence any actual of intended
|
|
122826
|
-
* publication of such source code, and is an unpublished work by create3000.
|
|
122827
|
-
* This material contains CONFIDENTIAL INFORMATION that is the property of
|
|
122828
|
-
* create3000.
|
|
122829
|
-
*
|
|
122830
|
-
* No permission is granted to copy, distribute, or create derivative works from
|
|
122831
|
-
* the contents of this software, in whole or in part, without the prior written
|
|
122832
|
-
* permission of create3000.
|
|
122833
|
-
*
|
|
122834
|
-
* NON-MILITARY USE ONLY
|
|
122835
|
-
*
|
|
122836
|
-
* All create3000 software are effectively free software with a non-military use
|
|
122837
|
-
* restriction. It is free. Well commented source is provided. You may reuse the
|
|
122838
|
-
* source in any way you please with the exception anything that uses it must be
|
|
122839
|
-
* marked to indicate is contains 'non-military use only' components.
|
|
122840
|
-
*
|
|
122841
|
-
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
122842
|
-
*
|
|
122843
|
-
* Copyright 2011 - 2022, Holger Seelig <holger.seelig@yahoo.de>.
|
|
122844
|
-
*
|
|
122845
|
-
* This file is part of the X_ITE Project.
|
|
122846
|
-
*
|
|
122847
|
-
* X_ITE is free software: you can redistribute it and/or modify it under the
|
|
122848
|
-
* terms of the GNU General Public License version 3 only, as published by the
|
|
122849
|
-
* Free Software Foundation.
|
|
122850
|
-
*
|
|
122851
|
-
* X_ITE is distributed in the hope that it will be useful, but WITHOUT ANY
|
|
122852
|
-
* WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
|
|
122853
|
-
* A PARTICULAR PURPOSE. See the GNU General Public License version 3 for more
|
|
122854
|
-
* details (a copy is included in the LICENSE file that accompanied this code).
|
|
122855
|
-
*
|
|
122856
|
-
* You should have received a copy of the GNU General Public License version 3
|
|
122857
|
-
* along with X_ITE. If not, see <https://www.gnu.org/licenses/gpl.html> for a
|
|
122858
|
-
* copy of the GPLv3 License.
|
|
122859
|
-
*
|
|
122860
|
-
* For Silvio, Joy and Adi.
|
|
122861
|
-
*
|
|
122862
|
-
******************************************************************************/
|
|
122863
|
-
|
|
122864
|
-
// Return a pseudo accurate timestamp.
|
|
122865
|
-
|
|
122866
|
-
function microTime (now)
|
|
122867
|
-
{
|
|
122868
|
-
let
|
|
122869
|
-
offset = 0,
|
|
122870
|
-
last = 0;
|
|
122871
|
-
|
|
122872
|
-
return function ()
|
|
122873
|
-
{
|
|
122874
|
-
const current = now .call (this);
|
|
122875
|
-
|
|
122876
|
-
if (current > last)
|
|
122877
|
-
{
|
|
122878
|
-
offset = 0;
|
|
122879
|
-
last = current;
|
|
122880
|
-
|
|
122881
|
-
return current;
|
|
122882
|
-
}
|
|
122883
|
-
else
|
|
122884
|
-
{
|
|
122885
|
-
return last = current + (++ offset / 1000);
|
|
122886
|
-
}
|
|
122887
|
-
};
|
|
122888
|
-
}
|
|
122889
|
-
|
|
122890
|
-
for (const object of [performance, Date])
|
|
122891
|
-
{
|
|
122892
|
-
Object .defineProperty (object, "now",
|
|
122893
|
-
{
|
|
122894
|
-
value: microTime (object .now),
|
|
122895
|
-
configurable: true,
|
|
122896
|
-
writable: true,
|
|
122897
|
-
});
|
|
122898
|
-
}
|
|
122899
|
-
|
|
122900
|
-
const MicroTime_default_ = undefined;
|
|
122901
|
-
;
|
|
122902
|
-
|
|
122903
|
-
x_ite_Namespace .set ("standard/Time/MicroTime", MicroTime_default_);
|
|
122904
|
-
/* harmony default export */ const MicroTime = ((/* unused pure expression or super */ null && (MicroTime_default_)));
|
|
122905
123516
|
;// CONCATENATED MODULE: ./src/lib/jquery.js
|
|
122906
|
-
/* provided dependency */ var jquery_$ = __webpack_require__(
|
|
122907
|
-
/* provided dependency */ var pako = __webpack_require__(
|
|
123517
|
+
/* provided dependency */ var jquery_$ = __webpack_require__(964);
|
|
123518
|
+
/* provided dependency */ var pako = __webpack_require__(931);
|
|
122908
123519
|
Object .assign (jquery_$,
|
|
122909
123520
|
{
|
|
122910
123521
|
decodeText (input)
|
|
@@ -122969,14 +123580,14 @@ const jquery_default_ = jquery_$;
|
|
|
122969
123580
|
x_ite_Namespace .set ("lib/jquery", jquery_default_);
|
|
122970
123581
|
/* harmony default export */ const jquery = ((/* unused pure expression or super */ null && (jquery_default_)));
|
|
122971
123582
|
;// CONCATENATED MODULE: ./src/lib/libtess.js
|
|
122972
|
-
/* provided dependency */ var libtess_libtess = __webpack_require__(
|
|
123583
|
+
/* provided dependency */ var libtess_libtess = __webpack_require__(149);
|
|
122973
123584
|
const libtess_default_ = libtess_libtess;
|
|
122974
123585
|
;
|
|
122975
123586
|
|
|
122976
123587
|
x_ite_Namespace .set ("lib/libtess", libtess_default_);
|
|
122977
123588
|
/* harmony default export */ const lib_libtess = ((/* unused pure expression or super */ null && (libtess_default_)));
|
|
122978
123589
|
;// CONCATENATED MODULE: ./src/x_ite/X3D.js
|
|
122979
|
-
/* provided dependency */ var X3D_$ = __webpack_require__(
|
|
123590
|
+
/* provided dependency */ var X3D_$ = __webpack_require__(964);
|
|
122980
123591
|
/*******************************************************************************
|
|
122981
123592
|
*
|
|
122982
123593
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -123056,7 +123667,6 @@ x_ite_Namespace .set ("lib/libtess", libtess_default_);
|
|
|
123056
123667
|
|
|
123057
123668
|
|
|
123058
123669
|
|
|
123059
|
-
|
|
123060
123670
|
|
|
123061
123671
|
|
|
123062
123672
|
const
|
|
@@ -123233,7 +123843,7 @@ const X3D_default_ = X3D;
|
|
|
123233
123843
|
x_ite_Namespace .set ("x_ite/X3D", X3D_default_);
|
|
123234
123844
|
/* harmony default export */ const x_ite_X3D = (X3D_default_);
|
|
123235
123845
|
;// CONCATENATED MODULE: ./src/x_ite/X3DCanvasElement.js
|
|
123236
|
-
/* provided dependency */ var X3DCanvasElement_$ = __webpack_require__(
|
|
123846
|
+
/* provided dependency */ var X3DCanvasElement_$ = __webpack_require__(964);
|
|
123237
123847
|
/*******************************************************************************
|
|
123238
123848
|
*
|
|
123239
123849
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
@@ -123324,6 +123934,8 @@ class X3DCanvasElement extends HTMLElement
|
|
|
123324
123934
|
"notifications",
|
|
123325
123935
|
"oninitialized",
|
|
123326
123936
|
"onshutdown",
|
|
123937
|
+
"orderIndependentTransparency",
|
|
123938
|
+
"orderindependenttransparency",
|
|
123327
123939
|
"splashScreen",
|
|
123328
123940
|
"splashscreen",
|
|
123329
123941
|
"src",
|
|
@@ -123502,7 +124114,7 @@ x_ite_Namespace .set ("shim", shim_default_);
|
|
|
123502
124114
|
|
|
123503
124115
|
// Assign X3D to global namespace.
|
|
123504
124116
|
|
|
123505
|
-
window [Symbol .for ("X_ITE.X3D-8.
|
|
124117
|
+
window [Symbol .for ("X_ITE.X3D-8.11.0")] = x_ite_X3D;
|
|
123506
124118
|
|
|
123507
124119
|
customElements .define ("x3d-canvas", x_ite_X3DCanvasElement);
|
|
123508
124120
|
|