From 19af8377e80bbaf9ee14a15868d7e64b5baccf35 Mon Sep 17 00:00:00 2001 From: gchoqueux Date: Thu, 23 May 2024 14:30:27 +0200 Subject: [PATCH 1/6] chore(architecture): monorepo structure --- .babelrc | 2 +- .eslintignore | 2 +- .eslintrc.cjs | 4 +- .github/workflows/integration.yml | 47 +- .gitignore | 10 +- Gruntfile.cjs | 2 +- config/concurrently.mjs | 12 + config/threeExamples.mjs | 4 +- docs/config.json | 5 +- examples/3dtiles_25d.html | 4 +- examples/3dtiles_basic.html | 4 +- examples/3dtiles_batch_table.html | 4 +- examples/3dtiles_ion.html | 2 +- examples/3dtiles_pointcloud.html | 4 +- examples/customColorLayerEffect.html | 4 +- examples/effects_postprocessing.html | 2 +- examples/effects_split.html | 4 +- examples/effects_stereo.html | 4 +- examples/entwine_3d_loader.html | 4 +- examples/entwine_simple_loader.html | 4 +- examples/geoid_geoidLayer.html | 4 +- examples/itowns-potree.html | 4 +- examples/laz_dragndrop.html | 2 +- examples/mars.html | 4 +- examples/misc_camera_animation.html | 2 +- examples/misc_camera_traveling.html | 4 +- examples/misc_clamp_ground.html | 4 +- examples/misc_collada.html | 4 +- examples/misc_colorlayer_visibility.html | 2 +- examples/misc_compare_25d_3d.html | 4 +- examples/misc_custom_controls.html | 4 +- examples/misc_custom_label.html | 4 +- examples/misc_georeferenced_images.html | 4 +- examples/misc_instancing.html | 4 +- examples/misc_orthographic_camera.html | 6 +- examples/plugins_drag_n_drop.html | 2 +- examples/plugins_pyramidal_tiff.html | 4 +- examples/plugins_vrt.html | 4 +- examples/potree_25d_map.html | 4 +- examples/potree_3d_map.html | 4 +- examples/source_file_cog.html | 4 +- examples/source_file_from_fetched_data.html | 4 +- examples/source_file_from_format.html | 4 +- examples/source_file_from_methods.html | 4 +- examples/source_file_from_parsed_data.html | 4 +- examples/source_file_geojson_3d.html | 4 +- examples/source_file_geojson_raster.html | 4 +- examples/source_file_geojson_raster_2.html | 4 +- examples/source_file_gpx_3d.html | 2 +- examples/source_file_gpx_raster.html | 4 +- examples/source_file_kml_raster.html | 4 +- examples/source_file_kml_raster_usgs.html | 4 +- examples/source_file_shapefile.html | 4 +- examples/source_stream_wfs_25d.html | 2 +- examples/source_stream_wfs_3d.html | 4 +- examples/source_stream_wfs_raster.html | 4 +- examples/vector_tile_3d_mesh.html | 4 +- examples/vector_tile_3d_mesh_mapbox.html | 4 +- examples/vector_tile_dragndrop.html | 2 +- examples/vector_tile_raster_2d.html | 4 +- examples/vector_tile_raster_3d.html | 4 +- examples/view_25d_map.html | 6 +- examples/view_2d_map.html | 4 +- examples/view_3d_map.html | 6 +- examples/view_3d_map_webxr.html | 2 +- examples/view_3d_mns_map.html | 6 +- examples/view_immersive.html | 4 +- examples/view_multi_25d.html | 2 +- examples/view_multiglobe.html | 2 +- examples/widgets_3dtiles_style.html | 6 +- examples/widgets_minimap.html | 6 +- examples/widgets_navigation.html | 6 +- examples/widgets_scale.html | 6 +- examples/widgets_searchbar.html | 6 +- index.html | 4 +- package-lock.json | 4351 +++++++++-------- package.json | 46 +- packages/Debug/.babelrc | 35 + packages/Debug/.eslintrc.cjs | 7 + packages/Debug/README.md | 7 + packages/Debug/package.json | 33 + .../Debug/src}/3dTilesDebug.js | 5 +- {utils/debug => packages/Debug/src}/Debug.js | 5 +- .../Debug/src}/GeometryDebug.js | 0 {utils/debug => packages/Debug/src}/Main.js | 0 .../debug => packages/Debug/src}/OBBHelper.js | 0 .../Debug/src}/PointCloudDebug.js | 2 +- .../debug => packages/Debug/src}/TileDebug.js | 2 +- .../Debug/src}/charts/ChartConfig.js | 0 .../Debug/src}/charts/ThreeStatsChart.js | 0 .../Debug/src}/charts/TileObjectChart.js | 0 .../Debug/src}/charts/TileVisibilityChart.js | 0 packages/Geodesy/.babelrc | 35 + packages/Geodesy/.eslintrc.cjs | 7 + packages/Geodesy/README.md | 24 + packages/Geodesy/package.json | 38 + .../Geodesy/src}/CoordStars.js | 2 +- .../Geodesy/src}/Coordinates.js | 4 +- .../Geodesy/src}/Crs.js | 0 .../Geodesy/src}/Ellipsoid.js | 2 +- .../Geodesy/src}/Extent.js | 4 +- .../Geodesy/src}/GeoidGrid.js | 4 +- packages/Geodesy/src/Main.js | 9 + .../Geodesy/src}/OrientationUtils.js | 2 +- packages/Geodesy/test/.eslintrc.cjs | 9 + .../Geodesy/test}/unit/coordinate.js | 2 +- {test => packages/Geodesy/test}/unit/crs.js | 2 +- .../Geodesy/test}/unit/ellipsoid.js | 32 +- .../Geodesy/test}/unit/extent.js | 6 +- .../Geodesy/test}/unit/geoidgrid.js | 7 +- .../Geodesy/test}/unit/orientationUtils.js | 4 +- packages/Gui/.babelrc | 35 + packages/Gui/.eslintrc.cjs | 7 + packages/Gui/README.md | 9 + packages/Gui/package.json | 33 + .../gui => packages/Gui/src}/C3DTilesStyle.js | 3 +- {src/Utils/gui => packages/Gui/src}/Main.js | 0 .../Utils/gui => packages/Gui/src}/Minimap.js | 6 +- .../gui => packages/Gui/src}/Navigation.js | 2 +- {src/Utils/gui => packages/Gui/src}/Scale.js | 5 +- .../gui => packages/Gui/src}/Searchbar.js | 2 +- {src/Utils/gui => packages/Gui/src}/Widget.js | 0 packages/Main/.babelrc | 35 + packages/Main/.eslintignore | 14 + packages/Main/.eslintrc.cjs | 6 + packages/Main/clean.cjs | 4 + packages/Main/package.json | 51 + .../Main/src}/Controls/FirstPersonControls.js | 0 .../Main/src}/Controls/FlyControls.js | 0 .../Main/src}/Controls/GlobeControls.js | 3 +- .../Main/src}/Controls/PlanarControls.js | 0 .../Main/src}/Controls/StateControl.js | 0 .../Main/src}/Controls/StreetControls.js | 0 .../Main/src}/Converter/Feature2Mesh.js | 7 +- .../Main/src}/Converter/Feature2Texture.js | 3 +- .../Main/src}/Converter/convertToTile.js | 0 .../Main/src}/Converter/textureConverter.js | 3 +- .../Main/src}/Core/3DTiles/C3DTBatchTable.js | 0 .../C3DTBatchTableHierarchyExtension.js | 0 .../src}/Core/3DTiles/C3DTBoundingVolume.js | 3 +- .../Main/src}/Core/3DTiles/C3DTExtensions.js | 0 .../Main/src}/Core/3DTiles/C3DTFeature.js | 0 .../Main/src}/Core/3DTiles/C3DTilesEnums.js | 0 .../Main/src}/Core/3DTiles/C3DTileset.js | 0 .../3DTiles/utils/BinaryPropertyAccessor.js | 0 .../Main/src}/Core/AnimationPlayer.js | 0 {src => packages/Main/src}/Core/CopcNode.js | 0 .../Main/src}/Core/Deprecated/Undeprecator.js | 0 .../Main/src}/Core/EntwinePointTileNode.js | 0 {src => packages/Main/src}/Core/Feature.js | 4 +- {src => packages/Main/src}/Core/Label.js | 2 +- {src => packages/Main/src}/Core/MainLoop.js | 0 {src => packages/Main/src}/Core/Picking.js | 2 +- .../Main/src}/Core/PointCloudNode.js | 0 {src => packages/Main/src}/Core/PotreeNode.js | 0 .../Main/src}/Core/Prefab/Globe/Atmosphere.js | 4 +- .../Core/Prefab/Globe/BuilderEllipsoidTile.js | 3 +- .../Main/src}/Core/Prefab/Globe/GlobeLayer.js | 4 +- .../Core/Prefab/Globe/Shaders/CloudsFS.glsl | 0 .../Core/Prefab/Globe/Shaders/CloudsVS.glsl | 0 .../Core/Prefab/Globe/Shaders/GlowFS.glsl | 0 .../Core/Prefab/Globe/Shaders/GlowVS.glsl | 0 .../Core/Prefab/Globe/Shaders/groundFS.glsl | 0 .../Core/Prefab/Globe/Shaders/groundVS.glsl | 0 .../src}/Core/Prefab/Globe/Shaders/skyFS.glsl | 0 .../src}/Core/Prefab/Globe/Shaders/skyVS.glsl | 0 .../Main/src}/Core/Prefab/Globe/SkyShader.js | 0 .../Main/src}/Core/Prefab/GlobeView.js | 5 +- .../src}/Core/Prefab/Planar/PlanarLayer.js | 3 +- .../Core/Prefab/Planar/PlanarTileBuilder.js | 3 +- .../Main/src}/Core/Prefab/PlanarView.js | 0 .../Main/src}/Core/Prefab/TileBuilder.js | 0 .../Core/Prefab/computeBufferTileGeometry.js | 0 .../Main/src}/Core/Scheduler/Cache.js | 0 .../Scheduler/CancelledCommandException.js | 0 .../Main/src}/Core/Scheduler/Scheduler.js | 0 {src => packages/Main/src}/Core/Style.js | 2 +- .../itowns_stroke_single_before.css | 0 .../Main/src}/Core/System/Capabilities.js | 0 .../Main/src}/Core/TileGeometry.js | 0 {src => packages/Main/src}/Core/TileMesh.js | 2 +- {src => packages/Main/src}/Core/View.js | 3 +- .../Main/src}/Layer/C3DTilesLayer.js | 0 .../Main/src}/Layer/ColorLayer.js | 0 {src => packages/Main/src}/Layer/CopcLayer.js | 0 .../Main/src}/Layer/ElevationLayer.js | 0 .../Main/src}/Layer/EntwinePointTileLayer.js | 2 +- .../Main/src}/Layer/FeatureGeometryLayer.js | 0 .../Main/src}/Layer/GeoidLayer.js | 0 .../Main/src}/Layer/GeometryLayer.js | 0 {src => packages/Main/src}/Layer/InfoLayer.js | 2 +- .../Main/src}/Layer/LabelLayer.js | 3 +- {src => packages/Main/src}/Layer/Layer.js | 0 .../Main/src}/Layer/LayerUpdateState.js | 0 .../Main/src}/Layer/LayerUpdateStrategy.js | 0 .../Main/src}/Layer/OrientedImageLayer.js | 3 +- .../Main/src}/Layer/PointCloudLayer.js | 0 .../Main/src}/Layer/PotreeLayer.js | 2 +- .../Main/src}/Layer/RasterLayer.js | 0 .../src}/Layer/ReferencingLayerProperties.js | 0 .../Main/src}/Layer/TiledGeometryLayer.js | 0 {src => packages/Main/src}/Main.js | 10 +- {src => packages/Main/src}/MainBundle.js | 0 .../Main/src}/Parser/B3dmParser.js | 0 .../src}/Parser/CameraCalibrationParser.js | 0 .../Main/src}/Parser/GDFParser.js | 3 +- .../Main/src}/Parser/GLTFParser.js | 0 .../Main/src}/Parser/GTXParser.js | 3 +- .../Main/src}/Parser/GeoJsonParser.js | 2 +- .../Main/src}/Parser/GpxParser.js | 0 .../Main/src}/Parser/ISGParser.js | 3 +- .../Main/src}/Parser/KMLParser.js | 0 .../Main/src}/Parser/LASLoader.js | 0 .../Main/src}/Parser/LASParser.js | 0 .../Main/src}/Parser/MapBoxUrlParser.js | 0 .../Main/src}/Parser/PntsParser.js | 0 .../Main/src}/Parser/PotreeBinParser.js | 0 .../Main/src}/Parser/PotreeCinParser.js | 0 .../Main/src}/Parser/ShapefileParser.js | 0 .../Main/src}/Parser/VectorTileParser.js | 3 +- .../Main/src}/Parser/XbilParser.js | 0 .../Parser/deprecated/LegacyGLTFLoader.js | 0 .../Main/src}/Process/3dTilesProcessing.js | 0 .../Main/src}/Process/FeatureProcessing.js | 2 +- .../Process/LayeredMaterialNodeProcessing.js | 0 .../Main/src}/Process/ObjectRemovalHelper.js | 0 .../Main/src}/Process/handlerNodeError.js | 0 .../Main/src}/Provider/3dTilesProvider.js | 0 .../Main/src}/Provider/DataSourceProvider.js | 0 .../Main/src}/Provider/Fetcher.js | 0 .../Main/src}/Provider/PointCloudProvider.js | 2 +- .../Main/src}/Provider/TileProvider.js | 0 .../Main/src}/Provider/URLBuilder.js | 2 +- {src => packages/Main/src}/Renderer/Camera.js | 2 +- {src => packages/Main/src}/Renderer/Color.js | 0 .../Main/src}/Renderer/ColorLayersOrdering.js | 0 .../Main/src}/Renderer/CommonMaterial.js | 0 .../Main/src}/Renderer/Label2DRenderer.js | 0 .../Main/src}/Renderer/LayeredMaterial.js | 0 {src => packages/Main/src}/Renderer/OBB.js | 3 +- .../Main/src}/Renderer/OrientedImageCamera.js | 0 .../src}/Renderer/OrientedImageMaterial.js | 0 .../Main/src}/Renderer/PointsMaterial.js | 0 .../Main/src}/Renderer/RasterTile.js | 2 +- .../Main/src}/Renderer/RenderMode.js | 0 .../Chunk/color_layers_pars_fragment.glsl | 0 .../Shader/Chunk/elevation_pars_vertex.glsl | 0 .../Shader/Chunk/elevation_vertex.glsl | 0 .../Renderer/Shader/Chunk/fog_fragment.glsl | 0 .../Shader/Chunk/fog_pars_fragment.glsl | 0 .../Renderer/Shader/Chunk/geoid_vertex.glsl | 0 .../Shader/Chunk/lighting_fragment.glsl | 0 .../Shader/Chunk/lighting_pars_fragment.glsl | 0 .../Shader/Chunk/mode_depth_fragment.glsl | 0 .../Shader/Chunk/mode_id_fragment.glsl | 0 .../Shader/Chunk/mode_pars_fragment.glsl | 0 .../Shader/Chunk/overlay_fragment.glsl | 0 .../Shader/Chunk/overlay_pars_fragment.glsl | 0 .../src}/Renderer/Shader/Chunk/pitUV.glsl | 0 .../Shader/Chunk/precision_qualifier.glsl | 0 .../projective_texturing_pars_fragment.glsl | 0 .../projective_texturing_pars_vertex.glsl | 0 .../Chunk/projective_texturing_vertex.glsl | 0 .../Main/src}/Renderer/Shader/PointsFS.glsl | 0 .../Main/src}/Renderer/Shader/PointsVS.glsl | 0 .../Renderer/Shader/ProjectiveTextureFS.glsl | 0 .../Renderer/Shader/ProjectiveTextureVS.glsl | 0 .../src}/Renderer/Shader/SampleTestFS.glsl | 0 .../src}/Renderer/Shader/SampleTestVS.glsl | 0 .../Main/src}/Renderer/Shader/ShaderChunk.js | 0 .../Main/src}/Renderer/Shader/ShaderUtils.js | 0 .../Main/src}/Renderer/Shader/TileFS.glsl | 0 .../Main/src}/Renderer/Shader/TileVS.glsl | 0 .../Main/src}/Renderer/SphereHelper.js | 0 {src => packages/Main/src}/Renderer/WebXR.js | 0 .../Main/src}/Renderer/c3DEngine.js | 0 .../Main/src}/Source/C3DTilesGoogleSource.js | 0 .../Main/src}/Source/C3DTilesIonSource.js | 0 .../Main/src}/Source/C3DTilesSource.js | 0 .../Main/src}/Source/CopcSource.js | 2 +- .../src}/Source/EntwinePointTileSource.js | 0 .../Main/src}/Source/FileSource.js | 2 +- .../Main/src}/Source/OrientedImageSource.js | 0 .../Main/src}/Source/PotreeSource.js | 0 {src => packages/Main/src}/Source/Source.js | 3 +- .../Main/src}/Source/TMSSource.js | 3 +- .../Main/src}/Source/VectorTilesSource.js | 0 .../Main/src}/Source/WFSSource.js | 2 +- .../Main/src}/Source/WMSSource.js | 0 .../Main/src}/Source/WMTSSource.js | 0 .../Main/src}/Utils/CameraUtils.js | 3 +- {src => packages/Main/src}/Utils/DEMUtils.js | 2 +- .../Main/src}/Utils/FeaturesUtils.js | 2 +- {src => packages/Main/src}/Utils/Gradients.js | 0 .../Main/src}/Utils/ThreeUtils.js | 0 .../Main/src}/Utils/placeObjectOnGround.js | 2 +- packages/Main/test/.eslintrc.cjs | 9 + .../Main/test}/data/EGM2008_simplified.gdf | 0 .../data/OrientedImage/cameraCalibration.json | 0 .../panoramicsMetaDataParis.geojson | 0 .../data/entwine/ept-hierarchy/0-0-0-0.json | 0 .../Main/test}/data/entwine/ept.json | 0 .../filesource/featCollec_Polygone.geojson | 0 .../data/filesource/feat_Polygone.geojson | 0 .../Main/test}/data/geojson/gpx.geojson | 0 .../Main/test}/data/geojson/holes.geojson | 0 .../test}/data/geojson/holesPoints.geojson | 0 .../Main/test}/data/geojson/map.geojson | 0 .../Main/test}/data/geojson/map_big.geojson | 0 .../Main/test}/data/geojson/map_small.geojson | 0 .../Main/test}/data/geojson/points.geojson | 0 .../Main/test}/data/geojson/simple.geojson | 0 .../Main/test}/data/gltf/box.glb | Bin .../Main/test}/data/mapboxMulti.json | 0 .../Main/test}/data/pbf/multipolygon.pbf | Bin .../Main/test}/data/raf09_simplified.isg | 0 .../Main/test}/data/vectortiles/sprite.json | 0 .../Main/test}/data/vectortiles/style.json | 0 .../Main/test}/data/vectortiles/tilejson.json | 0 {test => packages/Main/test}/unit/3dtiles.js | 7 +- .../Main/test}/unit/3dtilesbatchtable.js | 0 .../test}/unit/3dtilesbatchtablehierarchy.js | 0 .../unit/3dtilesbinarypropertyaccessor.js | 0 .../Main/test}/unit/3dtilesfeature.js | 0 .../Main/test}/unit/3dtilesgetchildren.js | 0 .../Main/test}/unit/3dtileslayerprocess.js | 2 +- .../unit/3dtileslayerprocessbatchtable.js | 2 +- .../Main/test}/unit/3dtileslayerstyle.js | 5 +- .../Main/test}/unit/bootstrap.js | 0 {test => packages/Main/test}/unit/cache.js | 0 {test => packages/Main/test}/unit/camera.js | 2 +- .../Main/test}/unit/cameraUtils.js | 7 +- .../Main/test}/unit/dataSourceProvider.js | 2 +- {test => packages/Main/test}/unit/demutils.js | 3 +- {test => packages/Main/test}/unit/entwine.js | 2 +- {test => packages/Main/test}/unit/feature.js | 2 +- .../Main/test}/unit/feature2mesh.js | 4 +- .../Main/test}/unit/featureUtils.js | 2 +- .../Main/test}/unit/featuregeometrylayer.js | 3 +- .../test}/unit/featuregeometrylayererror.js | 3 +- {test => packages/Main/test}/unit/fetcher.js | 0 .../Main/test}/unit/gdfparser.js | 0 .../Main/test}/unit/geoidlayer.js | 3 +- {test => packages/Main/test}/unit/geojson.js | 5 +- .../Main/test}/unit/geometrylayer.js | 0 .../Main/test}/unit/globecontrol.js | 2 +- .../Main/test}/unit/globeview.js | 3 +- .../Main/test}/unit/gltfparser.js | 0 .../Main/test}/unit/gtxparser.js | 0 .../Main/test}/unit/isgparser.js | 0 {test => packages/Main/test}/unit/label.js | 3 +- .../Main/test}/unit/lasparser.js | 2 +- {test => packages/Main/test}/unit/layer.js | 0 .../Main/test}/unit/layeredmaterial.js | 3 +- .../unit/layeredmaterialnodeprocessing.js | 2 +- .../Main/test}/unit/layerupdatestrategy.js | 2 +- {test => packages/Main/test}/unit/obb.js | 5 +- .../Main/test}/unit/orientedImageCamera.js | 0 .../Main/test}/unit/orientedimagelayer.js | 5 +- .../Main/test}/unit/planarControls.js | 2 +- .../Main/test}/unit/planarView.js | 2 +- .../Main/test}/unit/pnts_parser.js | 0 {test => packages/Main/test}/unit/potree.js | 2 +- .../Main/test}/unit/potreeBinParser.js | 0 .../Main/test}/unit/potreelayerparsing.js | 2 +- .../Main/test}/unit/potreelayerprocessing.js | 0 .../Main/test}/unit/provider_url.js | 2 +- .../Main/test}/unit/scheduler.js | 0 .../Main/test}/unit/shaderchunk.js | 0 {test => packages/Main/test}/unit/source.js | 2 +- .../Main/test}/unit/statecontrol.js | 2 +- {test => packages/Main/test}/unit/style.js | 0 .../Main/test}/unit/threeutils.js | 0 .../Main/test}/unit/tiledGeometryLayer.js | 2 +- {test => packages/Main/test}/unit/tilemesh.js | 2 +- {test => packages/Main/test}/unit/utils.js | 0 .../Main/test}/unit/vectortiles.js | 2 +- {test => packages/Main/test}/unit/view.js | 0 {test => packages/Main/test}/unit/webxr.js | 0 tsconfig.json | 4 +- webpack.config.cjs | 26 +- 381 files changed, 3005 insertions(+), 2505 deletions(-) create mode 100755 config/concurrently.mjs create mode 100644 packages/Debug/.babelrc create mode 100644 packages/Debug/.eslintrc.cjs create mode 100644 packages/Debug/README.md create mode 100644 packages/Debug/package.json rename {utils/debug => packages/Debug/src}/3dTilesDebug.js (95%) rename {utils/debug => packages/Debug/src}/Debug.js (98%) rename {utils/debug => packages/Debug/src}/GeometryDebug.js (100%) rename {utils/debug => packages/Debug/src}/Main.js (100%) rename {utils/debug => packages/Debug/src}/OBBHelper.js (100%) rename {utils/debug => packages/Debug/src}/PointCloudDebug.js (99%) rename {utils/debug => packages/Debug/src}/TileDebug.js (99%) rename {utils/debug => packages/Debug/src}/charts/ChartConfig.js (100%) rename {utils/debug => packages/Debug/src}/charts/ThreeStatsChart.js (100%) rename {utils/debug => packages/Debug/src}/charts/TileObjectChart.js (100%) rename {utils/debug => packages/Debug/src}/charts/TileVisibilityChart.js (100%) create mode 100644 packages/Geodesy/.babelrc create mode 100644 packages/Geodesy/.eslintrc.cjs create mode 100644 packages/Geodesy/README.md create mode 100644 packages/Geodesy/package.json rename {src/Core/Geographic => packages/Geodesy/src}/CoordStars.js (98%) rename {src/Core/Geographic => packages/Geodesy/src}/Coordinates.js (99%) rename {src/Core/Geographic => packages/Geodesy/src}/Crs.js (100%) rename {src/Core/Math => packages/Geodesy/src}/Ellipsoid.js (99%) rename {src/Core/Geographic => packages/Geodesy/src}/Extent.js (99%) rename {src/Core/Geographic => packages/Geodesy/src}/GeoidGrid.js (98%) create mode 100644 packages/Geodesy/src/Main.js rename {src/Utils => packages/Geodesy/src}/OrientationUtils.js (99%) create mode 100644 packages/Geodesy/test/.eslintrc.cjs rename {test => packages/Geodesy/test}/unit/coordinate.js (99%) rename {test => packages/Geodesy/test}/unit/crs.js (98%) rename {test => packages/Geodesy/test}/unit/ellipsoid.js (63%) rename {test => packages/Geodesy/test}/unit/extent.js (99%) rename {test => packages/Geodesy/test}/unit/geoidgrid.js (85%) rename {test => packages/Geodesy/test}/unit/orientationUtils.js (98%) create mode 100644 packages/Gui/.babelrc create mode 100644 packages/Gui/.eslintrc.cjs create mode 100644 packages/Gui/README.md create mode 100644 packages/Gui/package.json rename {src/Utils/gui => packages/Gui/src}/C3DTilesStyle.js (99%) rename {src/Utils/gui => packages/Gui/src}/Main.js (100%) rename {src/Utils/gui => packages/Gui/src}/Minimap.js (97%) rename {src/Utils/gui => packages/Gui/src}/Navigation.js (99%) rename {src/Utils/gui => packages/Gui/src}/Scale.js (96%) rename {src/Utils/gui => packages/Gui/src}/Searchbar.js (99%) rename {src/Utils/gui => packages/Gui/src}/Widget.js (100%) create mode 100644 packages/Main/.babelrc create mode 100644 packages/Main/.eslintignore create mode 100644 packages/Main/.eslintrc.cjs create mode 100644 packages/Main/clean.cjs create mode 100644 packages/Main/package.json rename {src => packages/Main/src}/Controls/FirstPersonControls.js (100%) rename {src => packages/Main/src}/Controls/FlyControls.js (100%) rename {src => packages/Main/src}/Controls/GlobeControls.js (99%) rename {src => packages/Main/src}/Controls/PlanarControls.js (100%) rename {src => packages/Main/src}/Controls/StateControl.js (100%) rename {src => packages/Main/src}/Controls/StreetControls.js (100%) rename {src => packages/Main/src}/Converter/Feature2Mesh.js (98%) rename {src => packages/Main/src}/Converter/Feature2Texture.js (98%) rename {src => packages/Main/src}/Converter/convertToTile.js (100%) rename {src => packages/Main/src}/Converter/textureConverter.js (95%) rename {src => packages/Main/src}/Core/3DTiles/C3DTBatchTable.js (100%) rename {src => packages/Main/src}/Core/3DTiles/C3DTBatchTableHierarchyExtension.js (100%) rename {src => packages/Main/src}/Core/3DTiles/C3DTBoundingVolume.js (98%) rename {src => packages/Main/src}/Core/3DTiles/C3DTExtensions.js (100%) rename {src => packages/Main/src}/Core/3DTiles/C3DTFeature.js (100%) rename {src => packages/Main/src}/Core/3DTiles/C3DTilesEnums.js (100%) rename {src => packages/Main/src}/Core/3DTiles/C3DTileset.js (100%) rename {src => packages/Main/src}/Core/3DTiles/utils/BinaryPropertyAccessor.js (100%) rename {src => packages/Main/src}/Core/AnimationPlayer.js (100%) rename {src => packages/Main/src}/Core/CopcNode.js (100%) rename {src => packages/Main/src}/Core/Deprecated/Undeprecator.js (100%) rename {src => packages/Main/src}/Core/EntwinePointTileNode.js (100%) rename {src => packages/Main/src}/Core/Feature.js (99%) rename {src => packages/Main/src}/Core/Label.js (99%) rename {src => packages/Main/src}/Core/MainLoop.js (100%) rename {src => packages/Main/src}/Core/Picking.js (99%) rename {src => packages/Main/src}/Core/PointCloudNode.js (100%) rename {src => packages/Main/src}/Core/PotreeNode.js (100%) rename {src => packages/Main/src}/Core/Prefab/Globe/Atmosphere.js (98%) rename {src => packages/Main/src}/Core/Prefab/Globe/BuilderEllipsoidTile.js (97%) rename {src => packages/Main/src}/Core/Prefab/Globe/GlobeLayer.js (97%) rename {src => packages/Main/src}/Core/Prefab/Globe/Shaders/CloudsFS.glsl (100%) rename {src => packages/Main/src}/Core/Prefab/Globe/Shaders/CloudsVS.glsl (100%) rename {src => packages/Main/src}/Core/Prefab/Globe/Shaders/GlowFS.glsl (100%) rename {src => packages/Main/src}/Core/Prefab/Globe/Shaders/GlowVS.glsl (100%) rename {src => packages/Main/src}/Core/Prefab/Globe/Shaders/groundFS.glsl (100%) rename {src => packages/Main/src}/Core/Prefab/Globe/Shaders/groundVS.glsl (100%) rename {src => packages/Main/src}/Core/Prefab/Globe/Shaders/skyFS.glsl (100%) rename {src => packages/Main/src}/Core/Prefab/Globe/Shaders/skyVS.glsl (100%) rename {src => packages/Main/src}/Core/Prefab/Globe/SkyShader.js (100%) rename {src => packages/Main/src}/Core/Prefab/GlobeView.js (97%) rename {src => packages/Main/src}/Core/Prefab/Planar/PlanarLayer.js (96%) rename {src => packages/Main/src}/Core/Prefab/Planar/PlanarTileBuilder.js (95%) rename {src => packages/Main/src}/Core/Prefab/PlanarView.js (100%) rename {src => packages/Main/src}/Core/Prefab/TileBuilder.js (100%) rename {src => packages/Main/src}/Core/Prefab/computeBufferTileGeometry.js (100%) rename {src => packages/Main/src}/Core/Scheduler/Cache.js (100%) rename {src => packages/Main/src}/Core/Scheduler/CancelledCommandException.js (100%) rename {src => packages/Main/src}/Core/Scheduler/Scheduler.js (100%) rename {src => packages/Main/src}/Core/Style.js (99%) rename {src => packages/Main/src}/Core/StyleChunk/itowns_stroke_single_before.css (100%) rename {src => packages/Main/src}/Core/System/Capabilities.js (100%) rename {src => packages/Main/src}/Core/TileGeometry.js (100%) rename {src => packages/Main/src}/Core/TileMesh.js (98%) rename {src => packages/Main/src}/Core/View.js (99%) rename {src => packages/Main/src}/Layer/C3DTilesLayer.js (100%) rename {src => packages/Main/src}/Layer/ColorLayer.js (100%) rename {src => packages/Main/src}/Layer/CopcLayer.js (100%) rename {src => packages/Main/src}/Layer/ElevationLayer.js (100%) rename {src => packages/Main/src}/Layer/EntwinePointTileLayer.js (98%) rename {src => packages/Main/src}/Layer/FeatureGeometryLayer.js (100%) rename {src => packages/Main/src}/Layer/GeoidLayer.js (100%) rename {src => packages/Main/src}/Layer/GeometryLayer.js (100%) rename {src => packages/Main/src}/Layer/InfoLayer.js (98%) rename {src => packages/Main/src}/Layer/LabelLayer.js (99%) rename {src => packages/Main/src}/Layer/Layer.js (100%) rename {src => packages/Main/src}/Layer/LayerUpdateState.js (100%) rename {src => packages/Main/src}/Layer/LayerUpdateStrategy.js (100%) rename {src => packages/Main/src}/Layer/OrientedImageLayer.js (98%) rename {src => packages/Main/src}/Layer/PointCloudLayer.js (100%) rename {src => packages/Main/src}/Layer/PotreeLayer.js (98%) rename {src => packages/Main/src}/Layer/RasterLayer.js (100%) rename {src => packages/Main/src}/Layer/ReferencingLayerProperties.js (100%) rename {src => packages/Main/src}/Layer/TiledGeometryLayer.js (100%) rename {src => packages/Main/src}/Main.js (94%) rename {src => packages/Main/src}/MainBundle.js (100%) rename {src => packages/Main/src}/Parser/B3dmParser.js (100%) rename {src => packages/Main/src}/Parser/CameraCalibrationParser.js (100%) rename {src => packages/Main/src}/Parser/GDFParser.js (97%) rename {src => packages/Main/src}/Parser/GLTFParser.js (100%) rename {src => packages/Main/src}/Parser/GTXParser.js (97%) rename {src => packages/Main/src}/Parser/GeoJsonParser.js (99%) rename {src => packages/Main/src}/Parser/GpxParser.js (100%) rename {src => packages/Main/src}/Parser/ISGParser.js (97%) rename {src => packages/Main/src}/Parser/KMLParser.js (100%) rename {src => packages/Main/src}/Parser/LASLoader.js (100%) rename {src => packages/Main/src}/Parser/LASParser.js (100%) rename {src => packages/Main/src}/Parser/MapBoxUrlParser.js (100%) rename {src => packages/Main/src}/Parser/PntsParser.js (100%) rename {src => packages/Main/src}/Parser/PotreeBinParser.js (100%) rename {src => packages/Main/src}/Parser/PotreeCinParser.js (100%) rename {src => packages/Main/src}/Parser/ShapefileParser.js (100%) rename {src => packages/Main/src}/Parser/VectorTileParser.js (98%) rename {src => packages/Main/src}/Parser/XbilParser.js (100%) rename {src => packages/Main/src}/Parser/deprecated/LegacyGLTFLoader.js (100%) rename {src => packages/Main/src}/Process/3dTilesProcessing.js (100%) rename {src => packages/Main/src}/Process/FeatureProcessing.js (98%) rename {src => packages/Main/src}/Process/LayeredMaterialNodeProcessing.js (100%) rename {src => packages/Main/src}/Process/ObjectRemovalHelper.js (100%) rename {src => packages/Main/src}/Process/handlerNodeError.js (100%) rename {src => packages/Main/src}/Provider/3dTilesProvider.js (100%) rename {src => packages/Main/src}/Provider/DataSourceProvider.js (100%) rename {src => packages/Main/src}/Provider/Fetcher.js (100%) rename {src => packages/Main/src}/Provider/PointCloudProvider.js (97%) rename {src => packages/Main/src}/Provider/TileProvider.js (100%) rename {src => packages/Main/src}/Provider/URLBuilder.js (98%) rename {src => packages/Main/src}/Renderer/Camera.js (99%) rename {src => packages/Main/src}/Renderer/Color.js (100%) rename {src => packages/Main/src}/Renderer/ColorLayersOrdering.js (100%) rename {src => packages/Main/src}/Renderer/CommonMaterial.js (100%) rename {src => packages/Main/src}/Renderer/Label2DRenderer.js (100%) rename {src => packages/Main/src}/Renderer/LayeredMaterial.js (100%) rename {src => packages/Main/src}/Renderer/OBB.js (98%) rename {src => packages/Main/src}/Renderer/OrientedImageCamera.js (100%) rename {src => packages/Main/src}/Renderer/OrientedImageMaterial.js (100%) rename {src => packages/Main/src}/Renderer/PointsMaterial.js (100%) rename {src => packages/Main/src}/Renderer/RasterTile.js (99%) rename {src => packages/Main/src}/Renderer/RenderMode.js (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/color_layers_pars_fragment.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/elevation_pars_vertex.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/elevation_vertex.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/fog_fragment.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/fog_pars_fragment.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/geoid_vertex.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/lighting_fragment.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/lighting_pars_fragment.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/mode_depth_fragment.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/mode_id_fragment.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/mode_pars_fragment.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/overlay_fragment.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/overlay_pars_fragment.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/pitUV.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/precision_qualifier.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/projective_texturing_pars_fragment.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/projective_texturing_pars_vertex.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/Chunk/projective_texturing_vertex.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/PointsFS.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/PointsVS.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/ProjectiveTextureFS.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/ProjectiveTextureVS.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/SampleTestFS.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/SampleTestVS.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/ShaderChunk.js (100%) rename {src => packages/Main/src}/Renderer/Shader/ShaderUtils.js (100%) rename {src => packages/Main/src}/Renderer/Shader/TileFS.glsl (100%) rename {src => packages/Main/src}/Renderer/Shader/TileVS.glsl (100%) rename {src => packages/Main/src}/Renderer/SphereHelper.js (100%) rename {src => packages/Main/src}/Renderer/WebXR.js (100%) rename {src => packages/Main/src}/Renderer/c3DEngine.js (100%) rename {src => packages/Main/src}/Source/C3DTilesGoogleSource.js (100%) rename {src => packages/Main/src}/Source/C3DTilesIonSource.js (100%) rename {src => packages/Main/src}/Source/C3DTilesSource.js (100%) rename {src => packages/Main/src}/Source/CopcSource.js (99%) rename {src => packages/Main/src}/Source/EntwinePointTileSource.js (100%) rename {src => packages/Main/src}/Source/FileSource.js (99%) rename {src => packages/Main/src}/Source/OrientedImageSource.js (100%) rename {src => packages/Main/src}/Source/PotreeSource.js (100%) rename {src => packages/Main/src}/Source/Source.js (99%) rename {src => packages/Main/src}/Source/TMSSource.js (98%) rename {src => packages/Main/src}/Source/VectorTilesSource.js (100%) rename {src => packages/Main/src}/Source/WFSSource.js (99%) rename {src => packages/Main/src}/Source/WMSSource.js (100%) rename {src => packages/Main/src}/Source/WMTSSource.js (100%) rename {src => packages/Main/src}/Utils/CameraUtils.js (99%) rename {src => packages/Main/src}/Utils/DEMUtils.js (99%) rename {src => packages/Main/src}/Utils/FeaturesUtils.js (99%) rename {src => packages/Main/src}/Utils/Gradients.js (100%) rename {src => packages/Main/src}/Utils/ThreeUtils.js (100%) rename {src => packages/Main/src}/Utils/placeObjectOnGround.js (99%) create mode 100644 packages/Main/test/.eslintrc.cjs rename {test => packages/Main/test}/data/EGM2008_simplified.gdf (100%) rename {test => packages/Main/test}/data/OrientedImage/cameraCalibration.json (100%) rename {test => packages/Main/test}/data/OrientedImage/panoramicsMetaDataParis.geojson (100%) rename {test => packages/Main/test}/data/entwine/ept-hierarchy/0-0-0-0.json (100%) rename {test => packages/Main/test}/data/entwine/ept.json (100%) rename {test => packages/Main/test}/data/filesource/featCollec_Polygone.geojson (100%) rename {test => packages/Main/test}/data/filesource/feat_Polygone.geojson (100%) rename {test => packages/Main/test}/data/geojson/gpx.geojson (100%) rename {test => packages/Main/test}/data/geojson/holes.geojson (100%) rename {test => packages/Main/test}/data/geojson/holesPoints.geojson (100%) rename {test => packages/Main/test}/data/geojson/map.geojson (100%) rename {test => packages/Main/test}/data/geojson/map_big.geojson (100%) rename {test => packages/Main/test}/data/geojson/map_small.geojson (100%) rename {test => packages/Main/test}/data/geojson/points.geojson (100%) rename {test => packages/Main/test}/data/geojson/simple.geojson (100%) rename {test => packages/Main/test}/data/gltf/box.glb (100%) rename {test => packages/Main/test}/data/mapboxMulti.json (100%) rename {test => packages/Main/test}/data/pbf/multipolygon.pbf (100%) rename {test => packages/Main/test}/data/raf09_simplified.isg (100%) rename {test => packages/Main/test}/data/vectortiles/sprite.json (100%) rename {test => packages/Main/test}/data/vectortiles/style.json (100%) rename {test => packages/Main/test}/data/vectortiles/tilejson.json (100%) rename {test => packages/Main/test}/unit/3dtiles.js (97%) rename {test => packages/Main/test}/unit/3dtilesbatchtable.js (100%) rename {test => packages/Main/test}/unit/3dtilesbatchtablehierarchy.js (100%) rename {test => packages/Main/test}/unit/3dtilesbinarypropertyaccessor.js (100%) rename {test => packages/Main/test}/unit/3dtilesfeature.js (100%) rename {test => packages/Main/test}/unit/3dtilesgetchildren.js (100%) rename {test => packages/Main/test}/unit/3dtileslayerprocess.js (98%) rename {test => packages/Main/test}/unit/3dtileslayerprocessbatchtable.js (98%) rename {test => packages/Main/test}/unit/3dtileslayerstyle.js (94%) rename {test => packages/Main/test}/unit/bootstrap.js (100%) rename {test => packages/Main/test}/unit/cache.js (100%) rename {test => packages/Main/test}/unit/camera.js (97%) rename {test => packages/Main/test}/unit/cameraUtils.js (95%) rename {test => packages/Main/test}/unit/dataSourceProvider.js (99%) rename {test => packages/Main/test}/unit/demutils.js (97%) rename {test => packages/Main/test}/unit/entwine.js (99%) rename {test => packages/Main/test}/unit/feature.js (98%) rename {test => packages/Main/test}/unit/feature2mesh.js (98%) rename {test => packages/Main/test}/unit/featureUtils.js (98%) rename {test => packages/Main/test}/unit/featuregeometrylayer.js (97%) rename {test => packages/Main/test}/unit/featuregeometrylayererror.js (97%) rename {test => packages/Main/test}/unit/fetcher.js (100%) rename {test => packages/Main/test}/unit/gdfparser.js (100%) rename {test => packages/Main/test}/unit/geoidlayer.js (96%) rename {test => packages/Main/test}/unit/geojson.js (97%) rename {test => packages/Main/test}/unit/geometrylayer.js (100%) rename {test => packages/Main/test}/unit/globecontrol.js (99%) rename {test => packages/Main/test}/unit/globeview.js (97%) rename {test => packages/Main/test}/unit/gltfparser.js (100%) rename {test => packages/Main/test}/unit/gtxparser.js (100%) rename {test => packages/Main/test}/unit/isgparser.js (100%) rename {test => packages/Main/test}/unit/label.js (98%) rename {test => packages/Main/test}/unit/lasparser.js (98%) rename {test => packages/Main/test}/unit/layer.js (100%) rename {test => packages/Main/test}/unit/layeredmaterial.js (96%) rename {test => packages/Main/test}/unit/layeredmaterialnodeprocessing.js (99%) rename {test => packages/Main/test}/unit/layerupdatestrategy.js (99%) rename {test => packages/Main/test}/unit/obb.js (93%) rename {test => packages/Main/test}/unit/orientedImageCamera.js (100%) rename {test => packages/Main/test}/unit/orientedimagelayer.js (93%) rename {test => packages/Main/test}/unit/planarControls.js (99%) rename {test => packages/Main/test}/unit/planarView.js (92%) rename {test => packages/Main/test}/unit/pnts_parser.js (100%) rename {test => packages/Main/test}/unit/potree.js (99%) rename {test => packages/Main/test}/unit/potreeBinParser.js (100%) rename {test => packages/Main/test}/unit/potreelayerparsing.js (99%) rename {test => packages/Main/test}/unit/potreelayerprocessing.js (100%) rename {test => packages/Main/test}/unit/provider_url.js (98%) rename {test => packages/Main/test}/unit/scheduler.js (100%) rename {test => packages/Main/test}/unit/shaderchunk.js (100%) rename {test => packages/Main/test}/unit/source.js (99%) rename {test => packages/Main/test}/unit/statecontrol.js (99%) rename {test => packages/Main/test}/unit/style.js (100%) rename {test => packages/Main/test}/unit/threeutils.js (100%) rename {test => packages/Main/test}/unit/tiledGeometryLayer.js (96%) rename {test => packages/Main/test}/unit/tilemesh.js (99%) rename {test => packages/Main/test}/unit/utils.js (100%) rename {test => packages/Main/test}/unit/vectortiles.js (99%) rename {test => packages/Main/test}/unit/view.js (100%) rename {test => packages/Main/test}/unit/webxr.js (100%) diff --git a/.babelrc b/.babelrc index ded830aa4d..1dc35f5415 100644 --- a/.babelrc +++ b/.babelrc @@ -8,7 +8,7 @@ }] ], "plugins": [ - ["module-resolver", { "root": ["./src"] } ], + ["module-resolver", { "root": ["./packages/Main/src"] } ], ["babel-plugin-inline-import", { "extensions": [ ".json", diff --git a/.eslintignore b/.eslintignore index 6f9eb2bf8a..67c7cbe27f 100644 --- a/.eslintignore +++ b/.eslintignore @@ -1,6 +1,6 @@ examples/libs/ examples/layers/ -src/ThreeExtended/ +packages/Main/src/ThreeExtended/ test/hooks.js dist/ node_modules/ diff --git a/.eslintrc.cjs b/.eslintrc.cjs index c2544517f6..b9d1b140bc 100644 --- a/.eslintrc.cjs +++ b/.eslintrc.cjs @@ -1,3 +1,5 @@ +const path = require('path'); + module.exports = { root: true, extends: [ @@ -14,7 +16,7 @@ module.exports = { settings: { 'import/resolver': { webpack: { - config: './webpack.config.cjs', + config: path.resolve(__dirname, './webpack.config.cjs'), }, }, }, diff --git a/.github/workflows/integration.yml b/.github/workflows/integration.yml index c9791bcf3d..819a242b96 100644 --- a/.github/workflows/integration.yml +++ b/.github/workflows/integration.yml @@ -9,7 +9,6 @@ on: - master workflow_dispatch: {} - jobs: # Build bundle, doc and check linter @@ -55,7 +54,7 @@ jobs: with: name: dist-itowns path: | - dist/**/*.js + packages/Main/dist/**/*.js examples buildDocs @@ -81,6 +80,13 @@ jobs: name: Unit and coverage tests needs: build runs-on: ubuntu-latest + strategy: + matrix: + include: + - package: "@itowns/geodesy" + path: "Geodesy" + - package: "itowns" + path: "Main" steps: # Use specific Node.js version @@ -95,17 +101,33 @@ jobs: - name: Install packages run: npm ci - - name: Run unit tests - run: npm run test-with-coverage_lcov + # Transpile + - name: transpile packages + run: npm run transpile - # Code coverage - - name: Coveralls - if: ${{ success() }} - uses: coverallsapp/github-action@master + - name: Test ${{ matrix.package }} + run: npm run test-with-coverage_lcov --workspace ${{ matrix.package}} + - name: Coveralls Parallel + uses: coverallsapp/github-action@v2 with: + format: lcov + base-path: ./packages/${{ matrix.path }} + path-to-lcov: ./packages/${{ matrix.path }}/coverage/lcov.info github-token: ${{ secrets.GITHUB_TOKEN }} + flag-name: run-${{ matrix.package }} + parallel: true - + # Final Code coverage + finish-coverage: + name: finish parallel test unit + needs: unit-and-coverage-tests + runs-on: ubuntu-latest + steps: + - name: Close parallel build + uses: coverallsapp/github-action@v2 + with: + parallel-finished: true + github-token: ${{ secrets.GITHUB_TOKEN }} # Functional tests functional-tests: name: Functional tests @@ -139,7 +161,7 @@ jobs: publish: name: Publish NPM package if: ${{ github.ref == 'refs/heads/master' }} - needs: [unit-and-coverage-tests, functional-tests, check-commit-message] + needs: [finish-coverage, functional-tests] runs-on: ubuntu-latest permissions: # id-token: write permission is required for npm provenance: @@ -196,7 +218,7 @@ jobs: deploy: name: Deploy to itowns.github.io if: ${{ github.ref == 'refs/heads/master' }} - needs: [unit-and-coverage-tests, functional-tests, check-commit-message] + needs: [finish-coverage, functional-tests, check-commit-message] runs-on: ubuntu-latest steps: @@ -207,6 +229,7 @@ jobs: name: dist-itowns # Copy files for deployment + # !!! To change - name: build site run: | mkdir -p itowns/dist @@ -257,7 +280,7 @@ jobs: release: name: Release GitHub if: ${{ github.ref == 'refs/heads/master' && startsWith( github.event.head_commit.message, 'release v' ) }} - needs: [unit-and-coverage-tests, functional-tests, check-commit-message] + needs: [finish-coverage, functional-tests, check-commit-message] runs-on: ubuntu-latest steps: diff --git a/.gitignore b/.gitignore index 5ebc710462..8d8c436ea9 100644 --- a/.gitignore +++ b/.gitignore @@ -3,12 +3,12 @@ # See https://help.github.com/articles/ignoring-files/ for how to configure your environment. # See https://github.com/github/gitignore/tree/master/Global for a list of global ignore rules. -/node_modules/ -/dist/ +**/node_modules/ +**/dist/ /potree/ potree -/lib/ +**/lib/ /docs/out/ -coverage +**/coverage .nyc_output/ -/src/ThreeExtended/ +**/src/ThreeExtended/ diff --git a/Gruntfile.cjs b/Gruntfile.cjs index 81ce8f2ddb..9cbc8bf2d6 100644 --- a/Gruntfile.cjs +++ b/Gruntfile.cjs @@ -4,7 +4,7 @@ module.exports = (grunt) => { pkg: grunt.file.readJSON('package.json'), bump: { options: { - files: ['package.json', 'package-lock.json', 'src/Main.js'], + files: ['package.json', 'package-lock.json', 'src/Main.js', 'packages/**/package.json'], updateConfigs: [], commit: true, commitMessage: 'release v%VERSION%', diff --git a/config/concurrently.mjs b/config/concurrently.mjs new file mode 100755 index 0000000000..3d0530b9c7 --- /dev/null +++ b/config/concurrently.mjs @@ -0,0 +1,12 @@ +import concurrently from 'concurrently'; + +import fs from 'fs'; + +const pck = JSON.parse(fs.readFileSync('package.json', 'utf8')); +const script = process.argv[2]; + +concurrently(pck.workspaces.map(workspace => ({ + command: `npm run ${script} -w ${workspace} --if-present`, + name: `${workspace}`, +}))); + diff --git a/config/threeExamples.mjs b/config/threeExamples.mjs index 9c1107d8a7..35880e94fe 100644 --- a/config/threeExamples.mjs +++ b/config/threeExamples.mjs @@ -1,5 +1,5 @@ export default { - patchedPath: './src/ThreeExtended/', + patchedPath: './packages/Main/src/ThreeExtended/', filesExamples: [ './loaders/GLTFLoader.js', './loaders/DRACOLoader.js', @@ -9,6 +9,6 @@ export default { './utils/WorkerPool.js', './capabilities/WebGL.js', './libs/ktx-parse.module.js', - './libs/zstddec.module.js' + './libs/zstddec.module.js', ], }; diff --git a/docs/config.json b/docs/config.json index 01d7369b9c..8bd664c569 100644 --- a/docs/config.json +++ b/docs/config.json @@ -187,8 +187,9 @@ } }, "source": { - "include": [ "src", "examples/js/plugins" ], - "exclude": [ "src/ThreeExtended" ] + "include": [ "examples/js/plugins", "packages" ], + "exclude": [ "src/ThreeExtended" ], + "excludePattern": "(^|\\/|\\\\)lib" }, "plugins": ["plugins/markdown"] } diff --git a/examples/3dtiles_25d.html b/examples/3dtiles_25d.html index 41cc65ad15..54f9e47654 100644 --- a/examples/3dtiles_25d.html +++ b/examples/3dtiles_25d.html @@ -10,9 +10,9 @@
- + - + - + - + - + - + + diff --git a/examples/3dtiles_pointcloud.html b/examples/3dtiles_pointcloud.html index 25300f0727..3fd9a21a80 100644 --- a/examples/3dtiles_pointcloud.html +++ b/examples/3dtiles_pointcloud.html @@ -20,9 +20,9 @@
- + - + + - + + - - + + - + - + + - + + - + - + + diff --git a/examples/itowns-potree.html b/examples/itowns-potree.html index 5849904458..ff63a3aa63 100644 --- a/examples/itowns-potree.html +++ b/examples/itowns-potree.html @@ -25,8 +25,8 @@ - - + + diff --git a/examples/laz_dragndrop.html b/examples/laz_dragndrop.html index 369b940ac9..70695dec8e 100644 --- a/examples/laz_dragndrop.html +++ b/examples/laz_dragndrop.html @@ -12,7 +12,7 @@
Drag and drop a LAS/LAZ file
- + - + - + + diff --git a/examples/misc_camera_traveling.html b/examples/misc_camera_traveling.html index 3e4c57821f..e22949023b 100644 --- a/examples/misc_camera_traveling.html +++ b/examples/misc_camera_traveling.html @@ -29,9 +29,9 @@
- + - + - + - + - + + diff --git a/examples/misc_colorlayer_visibility.html b/examples/misc_colorlayer_visibility.html index 22129be348..b6f483836d 100644 --- a/examples/misc_colorlayer_visibility.html +++ b/examples/misc_colorlayer_visibility.html @@ -12,7 +12,7 @@
- + - - + + - + + - - + + - - + + - - + + - - + + + - + - - + + - + - + - + - + - + - + - - + + diff --git a/examples/source_file_from_fetched_data.html b/examples/source_file_from_fetched_data.html index 69fa79bc7d..4bcb4c7fe7 100644 --- a/examples/source_file_from_fetched_data.html +++ b/examples/source_file_from_fetched_data.html @@ -11,8 +11,8 @@
- - + + - - + + - - + + - - + + - - + + - - + + - - + + + - - + + - - + + - - + + - + - + + - + - +

Building Information

- + - - + + - + - + + - - + + - + + - + + - + diff --git a/examples/view_3d_map_webxr.html b/examples/view_3d_map_webxr.html index 52dc69e242..4deca645de 100644 --- a/examples/view_3d_map_webxr.html +++ b/examples/view_3d_map_webxr.html @@ -20,7 +20,7 @@ - + - + + - + diff --git a/examples/view_immersive.html b/examples/view_immersive.html index 52edc3b1f8..2599acb6e5 100644 --- a/examples/view_immersive.html +++ b/examples/view_immersive.html @@ -17,10 +17,10 @@
- + - + + + - + + - + - + + - + diff --git a/examples/widgets_navigation.html b/examples/widgets_navigation.html index c96c6552d6..c11d96b9ae 100644 --- a/examples/widgets_navigation.html +++ b/examples/widgets_navigation.html @@ -19,10 +19,10 @@
- - + + - + diff --git a/examples/widgets_scale.html b/examples/widgets_scale.html index 22fd41c12b..695c3b89ef 100644 --- a/examples/widgets_scale.html +++ b/examples/widgets_scale.html @@ -20,10 +20,10 @@
- - + + - + diff --git a/examples/widgets_searchbar.html b/examples/widgets_searchbar.html index 60a6c89627..e12e80bba3 100644 --- a/examples/widgets_searchbar.html +++ b/examples/widgets_searchbar.html @@ -20,10 +20,10 @@
- - + + - + diff --git a/index.html b/index.html index 4ce1c83a4d..6c759eb5f1 100644 --- a/index.html +++ b/index.html @@ -15,8 +15,8 @@
- - + +