x_ite 8.6.9 → 8.6.11
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 +12 -12
- package/build/bin/version.pl +6 -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 +25 -25
- package/dist/assets/components/CubeMapTexturing.min.js +1 -1
- package/dist/assets/components/DIS.js +13 -13
- 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 +40 -58
- package/dist/assets/components/Geospatial.min.js +1 -1
- package/dist/assets/components/HAnim.js +18 -18
- 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 +27 -27
- package/dist/assets/components/Layout.min.js +1 -1
- package/dist/assets/components/NURBS.js +28 -34
- package/dist/assets/components/NURBS.min.js +1 -1
- package/dist/assets/components/ParticleSystems.js +27 -26
- package/dist/assets/components/ParticleSystems.min.js +1 -1
- package/dist/assets/components/Picking.js +19 -19
- package/dist/assets/components/Picking.min.js +1 -1
- package/dist/assets/components/RigidBodyPhysics.js +19 -19
- package/dist/assets/components/RigidBodyPhysics.min.js +1 -1
- package/dist/assets/components/Scripting.js +28 -28
- package/dist/assets/components/Scripting.min.js +1 -1
- package/dist/assets/components/Text.js +24 -24
- 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 +30 -30
- package/dist/assets/components/Texturing3D.min.js +1 -1
- package/dist/assets/components/VolumeRendering.js +19 -19
- 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 +431 -487
- package/dist/x_ite.min.js +1 -1
- package/dist/x_ite.zip +0 -0
- package/docs/_config.yml +1 -1
- package/docs/_posts/getting-started.md +1 -1
- package/docs/laboratory/gltf-sample-viewer.html +4 -2
- package/package.json +1 -1
- package/src/assets/shaders/webgl1/include/Fragment.glsl.js +10 -2
- package/src/assets/shaders/webgl2/include/Fragment.glsl.js +10 -2
- package/src/standard/Math/Algorithm.js +8 -1
- package/src/standard/Utility/BitSet.js +33 -0
- package/src/tests.js +1 -1
- package/src/x_ite/Browser/Core/BrowserTimings.js +7 -1
- package/src/x_ite/Browser/Core/Context.js +5 -3
- package/src/x_ite/Browser/Rendering/GeometryContext.js +2 -0
- package/src/x_ite/Browser/Shape/AlphaMode.js +1 -1
- package/src/x_ite/Browser/VERSION.js +1 -1
- package/src/x_ite/Browser/X3DBrowser.js +2 -2
- package/src/x_ite/Components/EnvironmentalEffects/X3DBackgroundNode.js +115 -139
- package/src/x_ite/Components/EnvironmentalEffects/X3DFogObject.js +1 -1
- package/src/x_ite/Components/Geometry3D/ElevationGrid.js +10 -31
- package/src/x_ite/Components/Geometry3D/IndexedFaceSet.js +3 -6
- package/src/x_ite/Components/Geospatial/GeoElevationGrid.js +7 -25
- package/src/x_ite/Components/Grouping/X3DGroupingNode.js +1 -1
- package/src/x_ite/Components/NURBS/X3DNurbsSurfaceGeometryNode.js +4 -10
- package/src/x_ite/Components/Navigation/X3DViewpointNode.js +0 -10
- package/src/x_ite/Components/ParticleSystems/ParticleSystem.js +4 -3
- package/src/x_ite/Components/Rendering/IndexedLineSet.js +11 -33
- package/src/x_ite/Components/Rendering/LineSet.js +12 -37
- package/src/x_ite/Components/Rendering/PointSet.js +11 -24
- package/src/x_ite/Components/Rendering/X3DComposedGeometryNode.js +14 -39
- package/src/x_ite/Components/RigidBodyPhysics/CollidableShape.js +1 -1
- package/src/x_ite/Components/Shape/Appearance.js +9 -5
- package/src/x_ite/Components/Shape/Material.js +1 -2
- package/src/x_ite/Components/Shape/PhysicalMaterial.js +1 -2
- package/src/x_ite/Components/Shape/TwoSidedMaterial.js +1 -1
- package/src/x_ite/Components/Shape/UnlitMaterial.js +1 -1
- package/src/x_ite/Components/Shape/X3DMaterialNode.js +24 -9
- package/src/x_ite/Components/Shape/X3DShapeNode.js +1 -2
- package/src/x_ite/Components/Texturing/ImageTexture.js +8 -3
- package/src/x_ite/Components/Texturing/X3DTexture2DNode.js +2 -0
- package/src/x_ite/Fields/SFImage.js +9 -9
- package/src/x_ite/Fields/SFInt32.js +2 -2
- package/src/x_ite/Rendering/X3DRenderObject.js +0 -2
- package/src/x_ite.html +1 -1
- package/x_ite.min.html +2 -2
- /package/docs/assets/X3D/{Michroma-Regular.ttf → teaser/Michroma-Regular.ttf} +0 -0
- /package/docs/assets/X3D/{peakpx.jpg → teaser/peakpx.jpg} +0 -0
- /package/docs/assets/X3D/{teaser.x3d → teaser/teaser.x3d} +0 -0
package/dist/x_ite.zip
CHANGED
|
Binary file
|
package/docs/_config.yml
CHANGED
|
@@ -341,10 +341,12 @@ function createList (description, array)
|
|
|
341
341
|
|
|
342
342
|
for (const filename of array)
|
|
343
343
|
{
|
|
344
|
-
const
|
|
344
|
+
const
|
|
345
|
+
match = filename .match (/^([^\/]+)/),
|
|
346
|
+
name = match [1] .replace (/([A-Z]+)/g, " $1") .replace (/\s+/g, " ") .trim ();
|
|
345
347
|
|
|
346
348
|
$("<a></a>")
|
|
347
|
-
.text (
|
|
349
|
+
.text (name)
|
|
348
350
|
.attr ("href", array .server + filename)
|
|
349
351
|
.appendTo ($("<li></li>") .appendTo (list))
|
|
350
352
|
.on ("click", loadURL .bind (null, filename, array .server));
|
package/package.json
CHANGED
|
@@ -114,8 +114,16 @@ fragment_main ()
|
|
|
114
114
|
finalColor .rgb = getFogColor (finalColor .rgb);
|
|
115
115
|
#endif
|
|
116
116
|
|
|
117
|
-
if (
|
|
118
|
-
|
|
117
|
+
#if defined (X3D_ALPHA_MODE_OPAQUE)
|
|
118
|
+
finalColor .a = 1.0;
|
|
119
|
+
#endif
|
|
120
|
+
|
|
121
|
+
#if defined (X3D_ALPHA_MODE_MASK)
|
|
122
|
+
if (finalColor .a < x3d_AlphaCutoff)
|
|
123
|
+
discard;
|
|
124
|
+
|
|
125
|
+
finalColor .a = 1.0;
|
|
126
|
+
#endif
|
|
119
127
|
|
|
120
128
|
gl_FragColor = finalColor;
|
|
121
129
|
|
|
@@ -115,8 +115,16 @@ fragment_main ()
|
|
|
115
115
|
finalColor .rgb = getFogColor (finalColor .rgb);
|
|
116
116
|
#endif
|
|
117
117
|
|
|
118
|
-
if (
|
|
119
|
-
|
|
118
|
+
#if defined (X3D_ALPHA_MODE_OPAQUE)
|
|
119
|
+
finalColor .a = 1.0;
|
|
120
|
+
#endif
|
|
121
|
+
|
|
122
|
+
#if defined (X3D_ALPHA_MODE_MASK)
|
|
123
|
+
if (finalColor .a < x3d_AlphaCutoff)
|
|
124
|
+
discard;
|
|
125
|
+
|
|
126
|
+
finalColor .a = 1.0;
|
|
127
|
+
#endif
|
|
120
128
|
|
|
121
129
|
x3d_FragColor = finalColor;
|
|
122
130
|
|
|
@@ -154,7 +154,14 @@ export default class Algorithm
|
|
|
154
154
|
if (this .isPowerOfTwo (n))
|
|
155
155
|
return n;
|
|
156
156
|
|
|
157
|
-
return 1 << 32 - Math .clz32 (n);
|
|
157
|
+
return 1 << (32 - Math .clz32 (n));
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
static bitCount (n)
|
|
161
|
+
{
|
|
162
|
+
n = n - ((n >>> 1) & 0x55555555);
|
|
163
|
+
n = (n & 0x33333333) + ((n >>> 2) & 0x33333333);
|
|
164
|
+
return ((n + (n >>> 4) & 0xF0F0F0F) * 0x1010101) >>> 24;
|
|
158
165
|
}
|
|
159
166
|
|
|
160
167
|
static cmp (lhs, rhs)
|
|
@@ -45,6 +45,8 @@
|
|
|
45
45
|
*
|
|
46
46
|
******************************************************************************/
|
|
47
47
|
|
|
48
|
+
import Algorithm from "../Math/Algorithm.js";
|
|
49
|
+
|
|
48
50
|
function BitSet (value = 0)
|
|
49
51
|
{
|
|
50
52
|
this .value = value;
|
|
@@ -53,6 +55,21 @@ function BitSet (value = 0)
|
|
|
53
55
|
BitSet .prototype =
|
|
54
56
|
{
|
|
55
57
|
constructor: BitSet,
|
|
58
|
+
[Symbol .iterator]: function* ()
|
|
59
|
+
{
|
|
60
|
+
let
|
|
61
|
+
value = this .value,
|
|
62
|
+
index = 0;
|
|
63
|
+
|
|
64
|
+
while (value)
|
|
65
|
+
{
|
|
66
|
+
if (value & 1)
|
|
67
|
+
yield index;
|
|
68
|
+
|
|
69
|
+
value >>>= 1;
|
|
70
|
+
index += 1;
|
|
71
|
+
}
|
|
72
|
+
},
|
|
56
73
|
get: function (index)
|
|
57
74
|
{
|
|
58
75
|
const mask = 1 << index;
|
|
@@ -72,6 +89,11 @@ BitSet .prototype =
|
|
|
72
89
|
{
|
|
73
90
|
this .value = 0;
|
|
74
91
|
},
|
|
92
|
+
entries: function* ()
|
|
93
|
+
{
|
|
94
|
+
for (const i of this)
|
|
95
|
+
yield [i, i];
|
|
96
|
+
},
|
|
75
97
|
valueOf: function ()
|
|
76
98
|
{
|
|
77
99
|
return this .value;
|
|
@@ -82,4 +104,15 @@ BitSet .prototype =
|
|
|
82
104
|
},
|
|
83
105
|
};
|
|
84
106
|
|
|
107
|
+
BitSet .prototype .keys = BitSet .prototype [Symbol .iterator];
|
|
108
|
+
BitSet .prototype .values = BitSet .prototype [Symbol .iterator];
|
|
109
|
+
|
|
110
|
+
Object .defineProperty (BitSet .prototype, "size",
|
|
111
|
+
{
|
|
112
|
+
get: function ()
|
|
113
|
+
{
|
|
114
|
+
return Algorithm .bitCount (this .value);
|
|
115
|
+
},
|
|
116
|
+
});
|
|
117
|
+
|
|
85
118
|
export default BitSet;
|
package/src/tests.js
CHANGED
|
@@ -14,7 +14,7 @@ const X_ITE_TESTS = [
|
|
|
14
14
|
{ path: "Core/Comment.x3d" },
|
|
15
15
|
{ path: "Core/DataURL.x3d" },
|
|
16
16
|
{ path: "Core/EXPORT.wrl" },
|
|
17
|
-
{ path: "Core/
|
|
17
|
+
{ path: "Core/export.x3d" },
|
|
18
18
|
{ path: "Core/EXPORT.x3dv" },
|
|
19
19
|
{ path: "Core/IMPORT.x3d" },
|
|
20
20
|
{ path: "Core/IMPORT.x3dv" },
|
|
@@ -78,6 +78,8 @@ BrowserTimings .prototype = Object .assign (Object .create (X3DBaseNode .prototy
|
|
|
78
78
|
{
|
|
79
79
|
X3DBaseNode .prototype .initialize .call (this);
|
|
80
80
|
|
|
81
|
+
this .getBrowser () .getBrowserOptions () ._ContextMenu .addInterest ("set_enabled__", this);
|
|
82
|
+
|
|
81
83
|
this .localStorage .addDefaultValues ({ type: "LESS" });
|
|
82
84
|
|
|
83
85
|
this .element = $("<div></div>") .hide () .addClass ("x_ite-private-browser-timings") .appendTo (this .getBrowser () .getSurface ());
|
|
@@ -103,7 +105,11 @@ BrowserTimings .prototype = Object .assign (Object .create (X3DBaseNode .prototy
|
|
|
103
105
|
|
|
104
106
|
this .enabled = enabled;
|
|
105
107
|
|
|
106
|
-
|
|
108
|
+
this .set_enabled__ ();
|
|
109
|
+
},
|
|
110
|
+
set_enabled__: function ()
|
|
111
|
+
{
|
|
112
|
+
if (this .enabled && this .getBrowser () .getBrowserOption ("ContextMenu"))
|
|
107
113
|
{
|
|
108
114
|
this .element .stop (true, true) .fadeIn ();
|
|
109
115
|
this .fps .reset ();
|
|
@@ -193,10 +193,12 @@ const Context =
|
|
|
193
193
|
// Async functions
|
|
194
194
|
|
|
195
195
|
Object .assign (gl, gl .getVersion () === 1
|
|
196
|
-
?
|
|
196
|
+
?
|
|
197
|
+
{
|
|
197
198
|
readPixelsAsync: gl .readPixels,
|
|
198
199
|
}
|
|
199
|
-
:
|
|
200
|
+
:
|
|
201
|
+
{
|
|
200
202
|
clientWaitAsync: function (sync, flags, timeout)
|
|
201
203
|
{
|
|
202
204
|
return new Promise ((resolve, reject) =>
|
|
@@ -225,7 +227,7 @@ const Context =
|
|
|
225
227
|
}
|
|
226
228
|
};
|
|
227
229
|
|
|
228
|
-
check
|
|
230
|
+
setTimeout (check, 0);
|
|
229
231
|
});
|
|
230
232
|
},
|
|
231
233
|
getBufferSubDataAsync: async function (target, buffer, srcByteOffset, dstBuffer, /* optional */ dstOffset, /* optional */ length)
|
|
@@ -46,11 +46,13 @@
|
|
|
46
46
|
******************************************************************************/
|
|
47
47
|
|
|
48
48
|
import X3DGeometryNode from "../../Components/Rendering/X3DGeometryNode.js";
|
|
49
|
+
import AlphaMode from "../Shape/AlphaMode.js";
|
|
49
50
|
|
|
50
51
|
function GeometryContext (options = { })
|
|
51
52
|
{
|
|
52
53
|
Object .assign (this,
|
|
53
54
|
{
|
|
55
|
+
alphaMode: AlphaMode .OPAQUE,
|
|
54
56
|
geometryType: 3,
|
|
55
57
|
hasFogCoords: false,
|
|
56
58
|
colorMaterial: false,
|
|
@@ -186,8 +186,8 @@ X3DBrowser .prototype = Object .assign (Object .create (X3DBrowserContext .proto
|
|
|
186
186
|
},
|
|
187
187
|
getComponent: function (name, level)
|
|
188
188
|
{
|
|
189
|
-
name
|
|
190
|
-
level
|
|
189
|
+
name = String (name);
|
|
190
|
+
level |= 0;
|
|
191
191
|
|
|
192
192
|
const component = SupportedComponents .get (name);
|
|
193
193
|
|