@inweb/viewer-three 26.9.3 → 26.9.4

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 (46) hide show
  1. package/dist/plugins/components/AxesHelperComponent.js +23 -22
  2. package/dist/plugins/components/AxesHelperComponent.js.map +1 -1
  3. package/dist/plugins/components/AxesHelperComponent.min.js +23 -0
  4. package/dist/plugins/components/AxesHelperComponent.module.js +31 -9
  5. package/dist/plugins/components/AxesHelperComponent.module.js.map +1 -1
  6. package/dist/plugins/components/ExtentsHelperComponent.js +23 -22
  7. package/dist/plugins/components/ExtentsHelperComponent.js.map +1 -1
  8. package/dist/plugins/components/ExtentsHelperComponent.min.js +23 -0
  9. package/dist/plugins/components/ExtentsHelperComponent.module.js +28 -6
  10. package/dist/plugins/components/ExtentsHelperComponent.module.js.map +1 -1
  11. package/dist/plugins/components/LightHelperComponent.js +23 -22
  12. package/dist/plugins/components/LightHelperComponent.js.map +1 -1
  13. package/dist/plugins/components/LightHelperComponent.min.js +23 -0
  14. package/dist/plugins/components/LightHelperComponent.module.js +35 -9
  15. package/dist/plugins/components/LightHelperComponent.module.js.map +1 -1
  16. package/dist/plugins/components/RoomEnvironmentComponent.js +23 -97
  17. package/dist/plugins/components/RoomEnvironmentComponent.js.map +1 -1
  18. package/dist/plugins/components/RoomEnvironmentComponent.min.js +23 -0
  19. package/dist/plugins/components/RoomEnvironmentComponent.module.js +27 -7
  20. package/dist/plugins/components/RoomEnvironmentComponent.module.js.map +1 -1
  21. package/dist/plugins/components/StatsPanelComponent.js +23 -92
  22. package/dist/plugins/components/StatsPanelComponent.js.map +1 -1
  23. package/dist/plugins/components/StatsPanelComponent.min.js +23 -0
  24. package/dist/plugins/components/StatsPanelComponent.module.js +26 -5
  25. package/dist/plugins/components/StatsPanelComponent.module.js.map +1 -1
  26. package/dist/plugins/loaders/GLTFCloudLoader.js +31 -2515
  27. package/dist/plugins/loaders/GLTFCloudLoader.js.map +1 -1
  28. package/dist/plugins/loaders/GLTFCloudLoader.min.js +23 -0
  29. package/dist/plugins/loaders/GLTFCloudLoader.module.js +35 -20
  30. package/dist/plugins/loaders/GLTFCloudLoader.module.js.map +1 -1
  31. package/dist/plugins/loaders/IFCXLoader.js +35 -689
  32. package/dist/plugins/loaders/IFCXLoader.js.map +1 -1
  33. package/dist/plugins/loaders/IFCXLoader.min.js +23 -0
  34. package/dist/plugins/loaders/IFCXLoader.module.js +833 -859
  35. package/dist/plugins/loaders/IFCXLoader.module.js.map +1 -1
  36. package/dist/plugins/loaders/PotreeLoader.js +26 -70
  37. package/dist/plugins/loaders/PotreeLoader.js.map +1 -1
  38. package/dist/plugins/loaders/PotreeLoader.min.js +23 -0
  39. package/dist/plugins/loaders/PotreeLoader.module.js +37 -15
  40. package/dist/plugins/loaders/PotreeLoader.module.js.map +1 -1
  41. package/dist/viewer-three.js +1502 -55140
  42. package/dist/viewer-three.js.map +1 -1
  43. package/dist/viewer-three.min.js +26 -3
  44. package/dist/viewer-three.module.js +3584 -3660
  45. package/dist/viewer-three.module.js.map +1 -1
  46. package/package.json +5 -5
@@ -1,6 +1,28 @@
1
- import { ModelImpl, Loader, loaders } from "@inweb/viewer-three";
1
+ ///////////////////////////////////////////////////////////////////////////////
2
+ // Copyright (C) 2002-2025, Open Design Alliance (the "Alliance").
3
+ // All rights reserved.
4
+ //
5
+ // This software and its documentation and related materials are owned by
6
+ // the Alliance. The software may only be incorporated into application
7
+ // programs owned by members of the Alliance, subject to a signed
8
+ // Membership Agreement and Supplemental Software License Agreement with the
9
+ // Alliance. The structure and organization of this software are the valuable
10
+ // trade secrets of the Alliance and its suppliers. The software is also
11
+ // protected by copyright law and international treaty provisions. Application
12
+ // programs incorporating this software must include the following statement
13
+ // with their copyright notices:
14
+ //
15
+ // This application incorporates Open Design Alliance software pursuant to a
16
+ // license agreement with Open Design Alliance.
17
+ // Open Design Alliance Copyright (C) 2002-2025 by Open Design Alliance.
18
+ // All rights reserved.
19
+ //
20
+ // By use of this software, its documentation or related materials, you
21
+ // acknowledge and accept the above terms.
22
+ ///////////////////////////////////////////////////////////////////////////////
2
23
 
3
- import { Potree, PointColorType, PointSizeType, PointShape } from "potree-core";
24
+ import { ModelImpl, Loader, loaders } from '@inweb/viewer-three';
25
+ import { Potree, PointColorType, PointSizeType, PointShape } from 'potree-core';
4
26
 
5
27
  class PotreeModelImpl extends ModelImpl {
6
28
  getExtents(target) {
@@ -13,16 +35,17 @@ class PotreeFileLoader extends Loader {
13
35
  super();
14
36
  this.updatePointClouds = () => {
15
37
  const result = this.potree.updatePointClouds(this.pointClouds, this.viewer.camera, this.viewer.renderer);
16
- if (result.exceededMaxLoadsToGPU || result.nodeLoadPromises.length > 0) this.viewer.update();
38
+ if (result.exceededMaxLoadsToGPU || result.nodeLoadPromises.length > 0)
39
+ this.viewer.update();
17
40
  };
18
41
  this.viewer = viewer;
19
- this.potree = new Potree;
42
+ this.potree = new Potree();
20
43
  this.pointClouds = [];
21
44
  this.viewer.addEventListener("render", this.updatePointClouds);
22
45
  this.viewer.addEventListener("changecamera", this.updatePointClouds);
23
46
  }
24
47
  dispose() {
25
- this.pointClouds.forEach(pco => pco.dispose());
48
+ this.pointClouds.forEach((pco) => pco.dispose());
26
49
  this.viewer.removeEventListener("render", this.updatePointClouds);
27
50
  this.viewer.removeEventListener("changecamera", this.updatePointClouds);
28
51
  }
@@ -35,16 +58,19 @@ class PotreeFileLoader extends Loader {
35
58
  const baseUrl = path.slice(0, index + 1);
36
59
  const url = path.slice(index + 1);
37
60
  const pco = await this.potree.loadPointCloud(url, baseUrl);
38
- pco.material.size = 1;
61
+ pco.material.size = 1.0;
39
62
  pco.material.shape = 2;
40
63
  pco.material.inputColorEncoding = 1;
41
64
  pco.material.outputColorEncoding = 1;
42
65
  pco.material.pointColorType = PointColorType.RGB;
43
66
  pco.material.pointSizeType = PointSizeType.ADAPTIVE;
44
67
  pco.material.shape = PointShape.CIRCLE;
45
- if (params.position) pco.position.copy(params.position);
46
- if (params.rotation) pco.rotation.copy(params.rotation);
47
- if (params.scale) pco.scale.copy(params.scale);
68
+ if (params.position)
69
+ pco.position.copy(params.position);
70
+ if (params.rotation)
71
+ pco.rotation.copy(params.rotation);
72
+ if (params.scale)
73
+ pco.scale.copy(params.scale);
48
74
  this.pointClouds.push(pco);
49
75
  const modelImpl = new PotreeModelImpl(pco);
50
76
  modelImpl.loader = this;
@@ -55,14 +81,10 @@ class PotreeFileLoader extends Loader {
55
81
  this.viewer.syncOptions();
56
82
  this.viewer.syncOverlay();
57
83
  this.viewer.update();
58
- this.viewer.emitEvent({
59
- type: "databasechunk",
60
- data: pco,
61
- file: file
62
- });
84
+ this.viewer.emitEvent({ type: "databasechunk", data: pco, file });
63
85
  return this;
64
86
  }
65
87
  }
66
88
 
67
- loaders.registerLoader("potree-file", viewer => new PotreeFileLoader(viewer));
89
+ loaders.registerLoader("potree-file", (viewer) => new PotreeFileLoader(viewer));
68
90
  //# sourceMappingURL=PotreeLoader.module.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"PotreeLoader.module.js","sources":["../../../plugins/loaders/Potree/PotreeModelImpl.ts","../../../plugins/loaders/Potree/PotreeFileLoader.ts","../../../plugins/loaders/Potree/index.ts"],"sourcesContent":["///////////////////////////////////////////////////////////////////////////////\n// Copyright (C) 2002-2025, Open Design Alliance (the \"Alliance\").\n// All rights reserved.\n//\n// This software and its documentation and related materials are owned by\n// the Alliance. The software may only be incorporated into application\n// programs owned by members of the Alliance, subject to a signed\n// Membership Agreement and Supplemental Software License Agreement with the\n// Alliance. The structure and organization of this software are the valuable\n// trade secrets of the Alliance and its suppliers. The software is also\n// protected by copyright law and international treaty provisions. Application\n// programs incorporating this software must include the following statement\n// with their copyright notices:\n//\n// This application incorporates Open Design Alliance software pursuant to a\n// license agreement with Open Design Alliance.\n// Open Design Alliance Copyright (C) 2002-2025 by Open Design Alliance.\n// All rights reserved.\n//\n// By use of this software, its documentation or related materials, you\n// acknowledge and accept the above terms.\n///////////////////////////////////////////////////////////////////////////////\n\nimport { Box3 } from \"three\";\nimport { PointCloudOctree } from \"potree-core\";\nimport { ModelImpl } from \"@inweb/viewer-three\";\n\n// Potree model implementation.\n\nexport class PotreeModelImpl extends ModelImpl {\n public pco: PointCloudOctree;\n\n override getExtents(target: Box3): Box3 {\n return target.union(this.pco.pcoGeometry.boundingBox);\n }\n}\n","///////////////////////////////////////////////////////////////////////////////\n// Copyright (C) 2002-2025, Open Design Alliance (the \"Alliance\").\n// All rights reserved.\n//\n// This software and its documentation and related materials are owned by\n// the Alliance. The software may only be incorporated into application\n// programs owned by members of the Alliance, subject to a signed\n// Membership Agreement and Supplemental Software License Agreement with the\n// Alliance. The structure and organization of this software are the valuable\n// trade secrets of the Alliance and its suppliers. The software is also\n// protected by copyright law and international treaty provisions. Application\n// programs incorporating this software must include the following statement\n// with their copyright notices:\n//\n// This application incorporates Open Design Alliance software pursuant to a\n// license agreement with Open Design Alliance.\n// Open Design Alliance Copyright (C) 2002-2025 by Open Design Alliance.\n// All rights reserved.\n//\n// By use of this software, its documentation or related materials, you\n// acknowledge and accept the above terms.\n///////////////////////////////////////////////////////////////////////////////\n\nimport { Euler, Vector3 } from \"three\";\nimport { PointColorType, PointCloudOctree, PointSizeType, PointShape, Potree } from \"potree-core\";\nimport { Loader, Viewer } from \"@inweb/viewer-three\";\n\nimport { PotreeModelImpl } from \"./PotreeModelImpl\";\n\nexport type PotreeLoadParams = {\n path?: string;\n position?: Vector3;\n rotation?: Euler;\n scale?: Vector3;\n};\n\nexport class PotreeFileLoader extends Loader {\n public viewer: Viewer;\n public potree: Potree;\n public pointClouds: PointCloudOctree[];\n\n constructor(viewer: Viewer) {\n super();\n this.viewer = viewer;\n\n this.potree = new Potree();\n this.pointClouds = [];\n\n this.viewer.addEventListener(\"render\", this.updatePointClouds);\n this.viewer.addEventListener(\"changecamera\", this.updatePointClouds);\n }\n\n override dispose() {\n this.pointClouds.forEach((pco) => pco.dispose());\n\n this.viewer.removeEventListener(\"render\", this.updatePointClouds);\n this.viewer.removeEventListener(\"changecamera\", this.updatePointClouds);\n }\n\n override isSupport(file: any, format?: string): boolean {\n return typeof file === \"string\" && /(cloud.js|metadata.json)$/i.test(file);\n }\n\n override async load(file: any, format?: string, params: PotreeLoadParams = {}): Promise<this> {\n const path = (params.path || \"\") + file;\n const index = path.lastIndexOf(\"/\");\n const baseUrl = path.slice(0, index + 1);\n const url = path.slice(index + 1);\n\n const pco = await this.potree.loadPointCloud(url, baseUrl);\n pco.material.size = 1.0;\n pco.material.shape = 2;\n pco.material.inputColorEncoding = 1;\n pco.material.outputColorEncoding = 1;\n pco.material.pointColorType = PointColorType.RGB; // RGB | DEPTH | HEIGHT | POINT_INDEX | LOD | CLASSIFICATION\n pco.material.pointSizeType = PointSizeType.ADAPTIVE; // ADAPTIVE | FIXED\n pco.material.shape = PointShape.CIRCLE; // CIRCLE | SQUARE\n\n if (params.position) pco.position.copy(params.position);\n if (params.rotation) pco.rotation.copy(params.rotation);\n if (params.scale) pco.scale.copy(params.scale);\n\n this.pointClouds.push(pco);\n\n const modelImpl = new PotreeModelImpl(pco);\n modelImpl.loader = this;\n modelImpl.viewer = this.viewer;\n modelImpl.pco = pco;\n\n this.viewer.scene.add(pco);\n this.viewer.models.push(modelImpl);\n\n this.viewer.syncOptions();\n this.viewer.syncOverlay();\n this.viewer.update();\n\n this.viewer.emitEvent({ type: \"databasechunk\", data: pco, file });\n\n return this;\n }\n\n updatePointClouds = () => {\n const result = this.potree.updatePointClouds(this.pointClouds, this.viewer.camera, this.viewer.renderer);\n if (result.exceededMaxLoadsToGPU || result.nodeLoadPromises.length > 0) this.viewer.update();\n };\n}\n","///////////////////////////////////////////////////////////////////////////////\n// Copyright (C) 2002-2025, Open Design Alliance (the \"Alliance\").\n// All rights reserved.\n//\n// This software and its documentation and related materials are owned by\n// the Alliance. The software may only be incorporated into application\n// programs owned by members of the Alliance, subject to a signed\n// Membership Agreement and Supplemental Software License Agreement with the\n// Alliance. The structure and organization of this software are the valuable\n// trade secrets of the Alliance and its suppliers. The software is also\n// protected by copyright law and international treaty provisions. Application\n// programs incorporating this software must include the following statement\n// with their copyright notices:\n//\n// This application incorporates Open Design Alliance software pursuant to a\n// license agreement with Open Design Alliance.\n// Open Design Alliance Copyright (C) 2002-2025 by Open Design Alliance.\n// All rights reserved.\n//\n// By use of this software, its documentation or related materials, you\n// acknowledge and accept the above terms.\n///////////////////////////////////////////////////////////////////////////////\n\nimport { loaders } from \"@inweb/viewer-three\";\n\nimport { PotreeFileLoader } from \"./PotreeFileLoader\";\n\nloaders.registerLoader(\"potree-file\", (viewer: any) => new PotreeFileLoader(viewer));\n"],"names":["PotreeModelImpl","ModelImpl","getExtents","target","union","this","pco","pcoGeometry","boundingBox","PotreeFileLoader","Loader","constructor","viewer","super","updatePointClouds","result","potree","pointClouds","camera","renderer","exceededMaxLoadsToGPU","nodeLoadPromises","length","update","Potree","addEventListener","dispose","forEach","removeEventListener","isSupport","file","format","test","load","params","path","index","lastIndexOf","baseUrl","slice","url","loadPointCloud","material","size","shape","inputColorEncoding","outputColorEncoding","pointColorType","PointColorType","RGB","pointSizeType","PointSizeType","ADAPTIVE","PointShape","CIRCLE","position","copy","rotation","scale","push","modelImpl","loader","scene","add","models","syncOptions","syncOverlay","emitEvent","type","data","loaders","registerLoader"],"mappings":";;;;AA6BM,MAAOA,wBAAwBC;IAG1B,UAAAC,CAAWC;QAClB,OAAOA,OAAOC,MAAMC,KAAKC,IAAIC,YAAYC;AAC3C;;;ACEI,MAAOC,yBAAyBC;IAKpC,WAAAC,CAAYC;QACVC;QA2DFR,KAAAS,oBAAoB;YAClB,MAAMC,SAASV,KAAKW,OAAOF,kBAAkBT,KAAKY,aAAaZ,KAAKO,OAAOM,QAAQb,KAAKO,OAAOO;YAC/F,IAAIJ,OAAOK,yBAAyBL,OAAOM,iBAAiBC,SAAS,GAAGjB,KAAKO,OAAOW;;QA5DpFlB,KAAKO,SAASA;QAEdP,KAAKW,SAAS,IAAIQ;QAClBnB,KA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IAAIzD;QACtBD,KAAKO,OAAOoD,OAAOL,KAAKC;QAExBvD,KAAKO,OAAOqD;QACZ5D,KAAKO,OAAOsD;QACZ7D,KAAKO,OAAOW;QAEZlB,KAAKO,OAAOuD,UAAU;YAAEC,MAAM;YAAiBC,MAAM/D;YAAKwB;;QAE1D,OAAOzB;AACT;;;ACxEFiE,QAAQC,eAAe,eAAgB3D,UAAgB,IAAIH,iBAAiBG"}
1
+ {"version":3,"file":"PotreeLoader.module.js","sources":["../../../plugins/loaders/Potree/PotreeModelImpl.ts","../../../plugins/loaders/Potree/PotreeFileLoader.ts","../../../plugins/loaders/Potree/index.ts"],"sourcesContent":["///////////////////////////////////////////////////////////////////////////////\n// Copyright (C) 2002-2025, Open Design Alliance (the \"Alliance\").\n// All rights reserved.\n//\n// This software and its documentation and related materials are owned by\n// the Alliance. The software may only be incorporated into application\n// programs owned by members of the Alliance, subject to a signed\n// Membership Agreement and Supplemental Software License Agreement with the\n// Alliance. The structure and organization of this software are the valuable\n// trade secrets of the Alliance and its suppliers. The software is also\n// protected by copyright law and international treaty provisions. Application\n// programs incorporating this software must include the following statement\n// with their copyright notices:\n//\n// This application incorporates Open Design Alliance software pursuant to a\n// license agreement with Open Design Alliance.\n// Open Design Alliance Copyright (C) 2002-2025 by Open Design Alliance.\n// All rights reserved.\n//\n// By use of this software, its documentation or related materials, you\n// acknowledge and accept the above terms.\n///////////////////////////////////////////////////////////////////////////////\n\nimport { Box3 } from \"three\";\nimport { PointCloudOctree } from \"potree-core\";\nimport { ModelImpl } from \"@inweb/viewer-three\";\n\n// Potree model implementation.\n\nexport class PotreeModelImpl extends ModelImpl {\n public pco: PointCloudOctree;\n\n override getExtents(target: Box3): Box3 {\n return target.union(this.pco.pcoGeometry.boundingBox);\n }\n}\n","///////////////////////////////////////////////////////////////////////////////\n// Copyright (C) 2002-2025, Open Design Alliance (the \"Alliance\").\n// All rights reserved.\n//\n// This software and its documentation and related materials are owned by\n// the Alliance. The software may only be incorporated into application\n// programs owned by members of the Alliance, subject to a signed\n// Membership Agreement and Supplemental Software License Agreement with the\n// Alliance. The structure and organization of this software are the valuable\n// trade secrets of the Alliance and its suppliers. The software is also\n// protected by copyright law and international treaty provisions. Application\n// programs incorporating this software must include the following statement\n// with their copyright notices:\n//\n// This application incorporates Open Design Alliance software pursuant to a\n// license agreement with Open Design Alliance.\n// Open Design Alliance Copyright (C) 2002-2025 by Open Design Alliance.\n// All rights reserved.\n//\n// By use of this software, its documentation or related materials, you\n// acknowledge and accept the above terms.\n///////////////////////////////////////////////////////////////////////////////\n\nimport { Euler, Vector3 } from \"three\";\nimport { PointColorType, PointCloudOctree, PointSizeType, PointShape, Potree } from \"potree-core\";\nimport { Loader, Viewer } from \"@inweb/viewer-three\";\n\nimport { PotreeModelImpl } from \"./PotreeModelImpl\";\n\nexport type PotreeLoadParams = {\n path?: string;\n position?: Vector3;\n rotation?: Euler;\n scale?: Vector3;\n};\n\nexport class PotreeFileLoader extends Loader {\n public viewer: Viewer;\n public potree: Potree;\n public pointClouds: PointCloudOctree[];\n\n constructor(viewer: Viewer) {\n super();\n this.viewer = viewer;\n\n this.potree = new Potree();\n this.pointClouds = [];\n\n this.viewer.addEventListener(\"render\", this.updatePointClouds);\n this.viewer.addEventListener(\"changecamera\", this.updatePointClouds);\n }\n\n override dispose() {\n this.pointClouds.forEach((pco) => pco.dispose());\n\n this.viewer.removeEventListener(\"render\", this.updatePointClouds);\n this.viewer.removeEventListener(\"changecamera\", this.updatePointClouds);\n }\n\n override isSupport(file: any, format?: string): boolean {\n return typeof file === \"string\" && /(cloud.js|metadata.json)$/i.test(file);\n }\n\n override async load(file: any, format?: string, params: PotreeLoadParams = {}): Promise<this> {\n const path = (params.path || \"\") + file;\n const index = path.lastIndexOf(\"/\");\n const baseUrl = path.slice(0, index + 1);\n const url = path.slice(index + 1);\n\n const pco = await this.potree.loadPointCloud(url, baseUrl);\n pco.material.size = 1.0;\n pco.material.shape = 2;\n pco.material.inputColorEncoding = 1;\n pco.material.outputColorEncoding = 1;\n pco.material.pointColorType = PointColorType.RGB; // RGB | DEPTH | HEIGHT | POINT_INDEX | LOD | CLASSIFICATION\n pco.material.pointSizeType = PointSizeType.ADAPTIVE; // ADAPTIVE | FIXED\n pco.material.shape = PointShape.CIRCLE; // CIRCLE | SQUARE\n\n if (params.position) pco.position.copy(params.position);\n if (params.rotation) pco.rotation.copy(params.rotation);\n if (params.scale) pco.scale.copy(params.scale);\n\n this.pointClouds.push(pco);\n\n const modelImpl = new PotreeModelImpl(pco);\n modelImpl.loader = this;\n modelImpl.viewer = this.viewer;\n modelImpl.pco = pco;\n\n this.viewer.scene.add(pco);\n this.viewer.models.push(modelImpl);\n\n this.viewer.syncOptions();\n this.viewer.syncOverlay();\n this.viewer.update();\n\n this.viewer.emitEvent({ type: \"databasechunk\", data: pco, file });\n\n return this;\n }\n\n updatePointClouds = () => {\n const result = this.potree.updatePointClouds(this.pointClouds, this.viewer.camera, this.viewer.renderer);\n if (result.exceededMaxLoadsToGPU || result.nodeLoadPromises.length > 0) this.viewer.update();\n };\n}\n","///////////////////////////////////////////////////////////////////////////////\n// Copyright (C) 2002-2025, Open Design Alliance (the \"Alliance\").\n// All rights reserved.\n//\n// This software and its documentation and related materials are owned by\n// the Alliance. The software may only be incorporated into application\n// programs owned by members of the Alliance, subject to a signed\n// Membership Agreement and Supplemental Software License Agreement with the\n// Alliance. The structure and organization of this software are the valuable\n// trade secrets of the Alliance and its suppliers. The software is also\n// protected by copyright law and international treaty provisions. Application\n// programs incorporating this software must include the following statement\n// with their copyright notices:\n//\n// This application incorporates Open Design Alliance software pursuant to a\n// license agreement with Open Design Alliance.\n// Open Design Alliance Copyright (C) 2002-2025 by Open Design Alliance.\n// All rights reserved.\n//\n// By use of this software, its documentation or related materials, you\n// acknowledge and accept the above terms.\n///////////////////////////////////////////////////////////////////////////////\n\nimport { loaders } from \"@inweb/viewer-three\";\n\nimport { PotreeFileLoader } from \"./PotreeFileLoader\";\n\nloaders.registerLoader(\"pot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