@xeokit/xeokit-sdk 2.4.0-alpha-48 → 2.4.0-alpha-49
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/dist/xeokit-sdk.cjs.js
CHANGED
|
@@ -62553,7 +62553,7 @@ class Bitmap extends Component {
|
|
|
62553
62553
|
* [[Run this example](http://xeokit.github.io/xeokit-sdk/examples/#LineSet_grid)]
|
|
62554
62554
|
*
|
|
62555
62555
|
* ````javascript
|
|
62556
|
-
* import {Viewer, XKTLoaderPlugin, LineSet, buildGridGeometry} from "
|
|
62556
|
+
* import {Viewer, XKTLoaderPlugin, LineSet, buildGridGeometry} from "https://cdn.jsdelivr.net/npm/@xeokit/xeokit-sdk/dist/xeokit-sdk.es.min.js";
|
|
62557
62557
|
*
|
|
62558
62558
|
* const viewer = new Viewer({
|
|
62559
62559
|
* canvasId: "myCanvas",
|
|
@@ -67710,7 +67710,7 @@ class LightMap extends CubeTexture {
|
|
|
67710
67710
|
* [[Run this example](http://xeokit.github.io/xeokit-sdk/examples/#markers_SpriteMarker)]
|
|
67711
67711
|
*
|
|
67712
67712
|
* ```` javascript
|
|
67713
|
-
* import {Viewer, SpriteMarker } from "
|
|
67713
|
+
* import {Viewer, SpriteMarker } from "./https://cdn.jsdelivr.net/npm/@xeokit/xeokit-sdk/dist/xeokit-sdk.es.min.js";
|
|
67714
67714
|
*
|
|
67715
67715
|
* const viewer = new Viewer({
|
|
67716
67716
|
* canvasId: "myCanvas",
|
|
@@ -103934,7 +103934,7 @@ class Viewer {
|
|
|
103934
103934
|
* [[Run this example](http://xeokit.github.io/xeokit-sdk/examples/#Configs_disableDoublePrecisionAndRAF)]
|
|
103935
103935
|
*
|
|
103936
103936
|
* ````javascript
|
|
103937
|
-
* import {Configs, Viewer, XKTLoaderPlugin} from "
|
|
103937
|
+
* import {Configs, Viewer, XKTLoaderPlugin} from "https://cdn.jsdelivr.net/npm/@xeokit/xeokit-sdk/dist/xeokit-sdk.es.min.js";
|
|
103938
103938
|
*
|
|
103939
103939
|
* // Access xeoit-sdk global configs.
|
|
103940
103940
|
* // We typically set configs only before we create any Viewers.
|
|
@@ -133155,6 +133155,12 @@ function load(viewer, options, inflatedData, sceneModel) {
|
|
|
133155
133155
|
geometryArrays.geometryIndices = indices.subarray(eachGeometryIndicesPortion [geometryIndex], atLastGeometry ? indices.length : eachGeometryIndicesPortion [geometryIndex + 1]);
|
|
133156
133156
|
geometryValid = (geometryArrays.geometryPositions.length > 0 && geometryArrays.geometryIndices.length > 0);
|
|
133157
133157
|
break;
|
|
133158
|
+
case 4:
|
|
133159
|
+
geometryArrays.primitiveName = "line-strip";
|
|
133160
|
+
geometryArrays.geometryPositions = positions.subarray(eachGeometryPositionsPortion [geometryIndex], atLastGeometry ? positions.length : eachGeometryPositionsPortion [geometryIndex + 1]);
|
|
133161
|
+
geometryArrays.geometryIndices = lineStripToLines(indices.subarray(eachGeometryIndicesPortion [geometryIndex], atLastGeometry ? indices.length : eachGeometryIndicesPortion [geometryIndex + 1]));
|
|
133162
|
+
geometryValid = (geometryArrays.geometryPositions.length > 0 && geometryArrays.geometryIndices.length > 0);
|
|
133163
|
+
break;
|
|
133158
133164
|
default:
|
|
133159
133165
|
continue;
|
|
133160
133166
|
}
|
|
@@ -133299,6 +133305,12 @@ function load(viewer, options, inflatedData, sceneModel) {
|
|
|
133299
133305
|
geometryIndices = indices.subarray(eachGeometryIndicesPortion [geometryIndex], atLastGeometry ? indices.length : eachGeometryIndicesPortion [geometryIndex + 1]);
|
|
133300
133306
|
geometryValid = (geometryPositions.length > 0 && geometryIndices.length > 0);
|
|
133301
133307
|
break;
|
|
133308
|
+
case 4:
|
|
133309
|
+
primitiveName = "lines-strip";
|
|
133310
|
+
geometryPositions = positions.subarray(eachGeometryPositionsPortion [geometryIndex], atLastGeometry ? positions.length : eachGeometryPositionsPortion [geometryIndex + 1]);
|
|
133311
|
+
geometryIndices = lineStripToLines(indices.subarray(eachGeometryIndicesPortion [geometryIndex], atLastGeometry ? indices.length : eachGeometryIndicesPortion [geometryIndex + 1]));
|
|
133312
|
+
geometryValid = (geometryPositions.length > 0 && geometryIndices.length > 0);
|
|
133313
|
+
break;
|
|
133302
133314
|
default:
|
|
133303
133315
|
continue;
|
|
133304
133316
|
}
|
|
@@ -133340,6 +133352,18 @@ function load(viewer, options, inflatedData, sceneModel) {
|
|
|
133340
133352
|
}
|
|
133341
133353
|
}
|
|
133342
133354
|
|
|
133355
|
+
function lineStripToLines(lineStrip) {
|
|
133356
|
+
if (lineStrip.length < 2) {
|
|
133357
|
+
return lineStrip;
|
|
133358
|
+
}
|
|
133359
|
+
const lines = [];
|
|
133360
|
+
for (let i = 0; i < lineStrip.length - 1; i++) {
|
|
133361
|
+
lines.push(lineStrip[i]);
|
|
133362
|
+
lines.push(lineStrip[i + 1]);
|
|
133363
|
+
}
|
|
133364
|
+
return lines;
|
|
133365
|
+
}
|
|
133366
|
+
|
|
133343
133367
|
/** @private */
|
|
133344
133368
|
const ParserV10 = {
|
|
133345
133369
|
version: 10,
|
package/dist/xeokit-sdk.es.js
CHANGED
|
@@ -62549,7 +62549,7 @@ class Bitmap extends Component {
|
|
|
62549
62549
|
* [[Run this example](http://xeokit.github.io/xeokit-sdk/examples/#LineSet_grid)]
|
|
62550
62550
|
*
|
|
62551
62551
|
* ````javascript
|
|
62552
|
-
* import {Viewer, XKTLoaderPlugin, LineSet, buildGridGeometry} from "
|
|
62552
|
+
* import {Viewer, XKTLoaderPlugin, LineSet, buildGridGeometry} from "https://cdn.jsdelivr.net/npm/@xeokit/xeokit-sdk/dist/xeokit-sdk.es.min.js";
|
|
62553
62553
|
*
|
|
62554
62554
|
* const viewer = new Viewer({
|
|
62555
62555
|
* canvasId: "myCanvas",
|
|
@@ -67706,7 +67706,7 @@ class LightMap extends CubeTexture {
|
|
|
67706
67706
|
* [[Run this example](http://xeokit.github.io/xeokit-sdk/examples/#markers_SpriteMarker)]
|
|
67707
67707
|
*
|
|
67708
67708
|
* ```` javascript
|
|
67709
|
-
* import {Viewer, SpriteMarker } from "
|
|
67709
|
+
* import {Viewer, SpriteMarker } from "./https://cdn.jsdelivr.net/npm/@xeokit/xeokit-sdk/dist/xeokit-sdk.es.min.js";
|
|
67710
67710
|
*
|
|
67711
67711
|
* const viewer = new Viewer({
|
|
67712
67712
|
* canvasId: "myCanvas",
|
|
@@ -103930,7 +103930,7 @@ class Viewer {
|
|
|
103930
103930
|
* [[Run this example](http://xeokit.github.io/xeokit-sdk/examples/#Configs_disableDoublePrecisionAndRAF)]
|
|
103931
103931
|
*
|
|
103932
103932
|
* ````javascript
|
|
103933
|
-
* import {Configs, Viewer, XKTLoaderPlugin} from "
|
|
103933
|
+
* import {Configs, Viewer, XKTLoaderPlugin} from "https://cdn.jsdelivr.net/npm/@xeokit/xeokit-sdk/dist/xeokit-sdk.es.min.js";
|
|
103934
103934
|
*
|
|
103935
103935
|
* // Access xeoit-sdk global configs.
|
|
103936
103936
|
* // We typically set configs only before we create any Viewers.
|
|
@@ -133151,6 +133151,12 @@ function load(viewer, options, inflatedData, sceneModel) {
|
|
|
133151
133151
|
geometryArrays.geometryIndices = indices.subarray(eachGeometryIndicesPortion [geometryIndex], atLastGeometry ? indices.length : eachGeometryIndicesPortion [geometryIndex + 1]);
|
|
133152
133152
|
geometryValid = (geometryArrays.geometryPositions.length > 0 && geometryArrays.geometryIndices.length > 0);
|
|
133153
133153
|
break;
|
|
133154
|
+
case 4:
|
|
133155
|
+
geometryArrays.primitiveName = "line-strip";
|
|
133156
|
+
geometryArrays.geometryPositions = positions.subarray(eachGeometryPositionsPortion [geometryIndex], atLastGeometry ? positions.length : eachGeometryPositionsPortion [geometryIndex + 1]);
|
|
133157
|
+
geometryArrays.geometryIndices = lineStripToLines(indices.subarray(eachGeometryIndicesPortion [geometryIndex], atLastGeometry ? indices.length : eachGeometryIndicesPortion [geometryIndex + 1]));
|
|
133158
|
+
geometryValid = (geometryArrays.geometryPositions.length > 0 && geometryArrays.geometryIndices.length > 0);
|
|
133159
|
+
break;
|
|
133154
133160
|
default:
|
|
133155
133161
|
continue;
|
|
133156
133162
|
}
|
|
@@ -133295,6 +133301,12 @@ function load(viewer, options, inflatedData, sceneModel) {
|
|
|
133295
133301
|
geometryIndices = indices.subarray(eachGeometryIndicesPortion [geometryIndex], atLastGeometry ? indices.length : eachGeometryIndicesPortion [geometryIndex + 1]);
|
|
133296
133302
|
geometryValid = (geometryPositions.length > 0 && geometryIndices.length > 0);
|
|
133297
133303
|
break;
|
|
133304
|
+
case 4:
|
|
133305
|
+
primitiveName = "lines-strip";
|
|
133306
|
+
geometryPositions = positions.subarray(eachGeometryPositionsPortion [geometryIndex], atLastGeometry ? positions.length : eachGeometryPositionsPortion [geometryIndex + 1]);
|
|
133307
|
+
geometryIndices = lineStripToLines(indices.subarray(eachGeometryIndicesPortion [geometryIndex], atLastGeometry ? indices.length : eachGeometryIndicesPortion [geometryIndex + 1]));
|
|
133308
|
+
geometryValid = (geometryPositions.length > 0 && geometryIndices.length > 0);
|
|
133309
|
+
break;
|
|
133298
133310
|
default:
|
|
133299
133311
|
continue;
|
|
133300
133312
|
}
|
|
@@ -133336,6 +133348,18 @@ function load(viewer, options, inflatedData, sceneModel) {
|
|
|
133336
133348
|
}
|
|
133337
133349
|
}
|
|
133338
133350
|
|
|
133351
|
+
function lineStripToLines(lineStrip) {
|
|
133352
|
+
if (lineStrip.length < 2) {
|
|
133353
|
+
return lineStrip;
|
|
133354
|
+
}
|
|
133355
|
+
const lines = [];
|
|
133356
|
+
for (let i = 0; i < lineStrip.length - 1; i++) {
|
|
133357
|
+
lines.push(lineStrip[i]);
|
|
133358
|
+
lines.push(lineStrip[i + 1]);
|
|
133359
|
+
}
|
|
133360
|
+
return lines;
|
|
133361
|
+
}
|
|
133362
|
+
|
|
133339
133363
|
/** @private */
|
|
133340
133364
|
const ParserV10 = {
|
|
133341
133365
|
version: 10,
|