@xeokit/xeokit-sdk 2.6.66 → 2.6.67

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (36) hide show
  1. package/{LICENSE.txt → LICENSE} +30 -27
  2. package/README.md +13 -6
  3. package/dist/xeokit-sdk.cjs.js +50236 -25849
  4. package/dist/xeokit-sdk.es.js +50236 -25849
  5. package/dist/xeokit-sdk.es5.js +7977 -4826
  6. package/dist/xeokit-sdk.min.cjs.js +5 -5
  7. package/dist/xeokit-sdk.min.es.js +5 -5
  8. package/dist/xeokit-sdk.min.es5.js +4 -4
  9. package/package.json +34 -32
  10. package/src/plugins/AnnotationsPlugin/Annotation.js +45 -5
  11. package/src/plugins/CityJSONLoaderPlugin/CityJSONLoaderPlugin.js +1 -1
  12. package/src/plugins/GLTFLoaderPlugin/GLTFSceneModelLoader.js +3 -2
  13. package/src/plugins/LASLoaderPlugin/LASLoaderPlugin.js +1 -1
  14. package/src/plugins/XKTLoaderPlugin/XKTLoaderPlugin.js +57 -2
  15. package/src/plugins/XKTLoaderPlugin/parsers/ParserV10.js +6 -0
  16. package/src/plugins/XKTLoaderPlugin/parsers/ParserV11.js +6 -0
  17. package/src/plugins/XKTLoaderPlugin/parsers/ParserV12.js +822 -0
  18. package/src/plugins/XKTLoaderPlugin/parsers/ParserV6.js +6 -0
  19. package/src/plugins/XKTLoaderPlugin/parsers/ParserV7.js +6 -0
  20. package/src/plugins/XKTLoaderPlugin/parsers/ParserV8.js +6 -0
  21. package/src/plugins/XKTLoaderPlugin/parsers/ParserV9.js +6 -0
  22. package/src/{plugins/lib → viewer/scene/libs}/earcut.js +194 -189
  23. package/src/viewer/scene/materials/EmphasisMaterial.js +5 -1
  24. package/src/viewer/scene/math/math.js +6 -2
  25. package/src/viewer/scene/model/SceneModelEntity.js +26 -0
  26. package/src/viewer/scene/model/SceneModelMesh.js +4 -0
  27. package/src/viewer/scene/model/dtx/triangles/DTXTrianglesLayer.js +1 -1
  28. package/src/viewer/scene/model/vbo/batching/triangles/VBOBatchingTrianglesLayer.js +1 -1
  29. package/src/viewer/scene/model/vbo/instancing/triangles/VBOInstancingTrianglesLayer.js +1 -1
  30. package/src/viewer/scene/scene/Scene.js +50 -6
  31. package/src/viewer/scene/sectionCaps/SectionCaps.js +774 -0
  32. package/src/viewer/scene/sectionCaps/index.js +1 -0
  33. package/src/viewer/scene/webgl/Renderer.js +10 -7
  34. package/types/plugins/WebIFCLoaderPlugin/WebIFCLoaderPlugin.d.ts +2 -1
  35. package/types/plugins/XKTLoaderPlugin/XKTLoaderPlugin.d.ts +28 -0
  36. package/types/viewer/scene/models/SceneModelMesh.d.ts +7 -0
@@ -0,0 +1 @@
1
+ export * from "./SectionCaps.js";
@@ -1302,13 +1302,16 @@ const Renderer = function (scene, options) {
1302
1302
 
1303
1303
  const snapRadiusInPixels = snapRadius || 30;
1304
1304
 
1305
- const vertexPickBuffer = renderBufferManager.getRenderBuffer("uniquePickColors-aabs", {
1306
- depthTexture: true,
1307
- size: [
1308
- 2 * snapRadiusInPixels + 1,
1309
- 2 * snapRadiusInPixels + 1,
1310
- ]
1311
- });
1305
+ const vertexPickBuffer = renderBufferManager.getRenderBuffer(
1306
+ `uniquePickColors-aabs-${snapRadiusInPixels}`,
1307
+ {
1308
+ depthTexture: true,
1309
+ size: [
1310
+ 2 * snapRadiusInPixels + 1,
1311
+ 2 * snapRadiusInPixels + 1,
1312
+ ]
1313
+ }
1314
+ );
1312
1315
 
1313
1316
  frameCtx.snapVectorA = [
1314
1317
  canvasPos ? getClipPosX(canvasPos[0] * resolutionScale, gl.drawingBufferWidth) : 0,
@@ -21,12 +21,13 @@ import { ModelStats } from "../index";
21
21
 
22
22
  export declare type WebIFCLoaderPluginConfiguration = {
23
23
  id?: string;
24
- wasmPath: string;
25
24
  objectDefaults?: any;
26
25
  dataSource?: IWebIFCDefaultDataSource;
27
26
  includeTypes?: string[];
28
27
  excludeTypes?: string[];
29
28
  excludeUnclassifiedObjects?: boolean;
29
+ WebIFC: any;
30
+ IfcAPI: any;
30
31
  };
31
32
 
32
33
  export declare type LoadWebIFCModel = {
@@ -11,6 +11,8 @@ export declare type XKTLoaderPluginConfiguration = {
11
11
  includeTypes?: string[];
12
12
  /** When loading metadata, never loads objects that have {@link MetaObject}s with {@link MetaObject.type} values in this list. */
13
13
  excludeTypes?: string[];
14
+ /** When loading metadata, only loads objects that have {@link MetaObject}s with {@link MetaObject.id} values in this list. */
15
+ includeIds?: string[];
14
16
  /** When loading metadata and this is ````true````, will only load {@link Entity}s that have {@link MetaObject}s (that are not excluded). This is useful when we don't want Entitys in the Scene that are not represented within IFC navigation components, such as {@link TreeViewPlugin}. */
15
17
  excludeUnclassifiedObjects?: boolean;
16
18
  /** Indicates whether to enable geometry reuse */
@@ -40,6 +42,8 @@ export declare type LoadXKTModel = {
40
42
  includeTypes?: string[]
41
43
  /** When loading metadata, never loads objects that have {@link MetaObject}s with {@link MetaObject.type} values in this list. */
42
44
  excludeTypes?: string[];
45
+ /** When loading metadata, only loads objects that have {@link MetaObject}s with {@link MetaObject.id} values in this list. */
46
+ includeIds?: string[]
43
47
  /** Whether or not xeokit renders the model with edges emphasized. */
44
48
  edges?: boolean;
45
49
  /** The model's World-space double-precision 3D origin. Use this to position the model within xeokit's World coordinate system, using double-precision coordinates. */
@@ -198,6 +202,30 @@ export declare class XKTLoaderPlugin extends Plugin {
198
202
  */
199
203
  get excludeTypes(): string[];
200
204
 
205
+ /**
206
+ * Sets the whitelist of the specified elements by this XKTLoaderPlugin.
207
+ *
208
+ * When loading models with metadata, causes this XKTLoaderPlugin to only load objects whose ids are in this
209
+ * list. An object's id is indicated by its {@link MetaObject}'s {@link MetaObject#id}.
210
+ *
211
+ * Default value is ````undefined````.
212
+ *
213
+ * @type {String[]}
214
+ */
215
+ set includeIds(arg: string[]);
216
+
217
+ /**
218
+ * Gets the whitelist of the specified elements loaded by this XKTLoaderPlugin.
219
+ *
220
+ * When loading models with metadata, causes this XKTLoaderPlugin to only load objects whose ids are in this
221
+ * list. An object's id is indicated by its {@link MetaObject}'s {@link MetaObject#id}.
222
+ *
223
+ * Default value is ````undefined````.
224
+ *
225
+ * @type {String[]}
226
+ */
227
+ get includeIds(): string[];
228
+
201
229
  /**
202
230
  * Sets whether we load objects that don't have IFC types.
203
231
  *
@@ -65,4 +65,11 @@ export declare class SceneModelMesh {
65
65
  */
66
66
  entity: SceneModelEntity;
67
67
 
68
+ /**
69
+ * Tells whether this SceneModelMesh is a solid or not
70
+ *
71
+ * @type {Boolean}
72
+ */
73
+ isSolid(): boolean;
74
+
68
75
  }