@vcmap/ui 5.0.0-rc.18 → 5.0.0-rc.21
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/README.md +6 -6
- package/build/build.js +2 -2
- package/build/buildCesium.js +3 -3
- package/build/buildHelpers.js +2 -1
- package/config/base.config.json +0 -4
- package/config/dev.config.json +35 -14
- package/config/www.config.json +4 -0
- package/dist/assets/cesium/Workers/ArcType-ce2e50ab.js +37 -0
- package/dist/assets/cesium/Workers/AttributeCompression-b646d393.js +716 -0
- package/dist/assets/cesium/Workers/AxisAlignedBoundingBox-ff186ccc.js +258 -0
- package/dist/assets/cesium/Workers/BoundingRectangle-be5924f4.js +369 -0
- package/dist/assets/cesium/Workers/BoxGeometry-12eeccaf.js +884 -0
- package/dist/assets/cesium/Workers/Check-666ab1a0.js +290 -0
- package/dist/assets/cesium/Workers/Color-a84038cb.js +2262 -0
- package/dist/assets/cesium/Workers/ComponentDatatype-f7b11d02.js +341 -0
- package/dist/assets/cesium/Workers/CoplanarPolygonGeometryLibrary-3272c1b3.js +132 -0
- package/dist/assets/cesium/Workers/CorridorGeometryLibrary-0170e093.js +498 -0
- package/dist/assets/cesium/Workers/CylinderGeometry-7c5da648.js +467 -0
- package/dist/assets/cesium/Workers/CylinderGeometryLibrary-372c07d8.js +63 -0
- package/dist/assets/cesium/Workers/EllipseGeometry-797d580e.js +1304 -0
- package/dist/assets/cesium/Workers/EllipseGeometryLibrary-2939e1dc.js +366 -0
- package/dist/assets/cesium/Workers/EllipseOutlineGeometry-8b50870f.js +443 -0
- package/dist/assets/cesium/Workers/EllipsoidGeodesic-98c62a56.js +520 -0
- package/dist/assets/cesium/Workers/EllipsoidGeometry-21c0e3a5.js +637 -0
- package/dist/assets/cesium/Workers/EllipsoidOutlineGeometry-eff247c8.js +454 -0
- package/dist/assets/cesium/Workers/EllipsoidRhumbLine-19756602.js +741 -0
- package/dist/assets/cesium/Workers/EllipsoidTangentPlane-214683dc.js +373 -0
- package/dist/assets/cesium/Workers/EncodedCartesian3-81f70735.js +171 -0
- package/dist/assets/cesium/Workers/FrustumGeometry-ac42a6d9.js +2512 -0
- package/dist/assets/cesium/Workers/GeometryAttribute-7d6f1732.js +619 -0
- package/dist/assets/cesium/Workers/GeometryAttributes-f06a2792.js +91 -0
- package/dist/assets/cesium/Workers/GeometryInstance-451dc1cd.js +121 -0
- package/dist/assets/cesium/Workers/GeometryOffsetAttribute-04332ce7.js +16 -0
- package/dist/assets/cesium/Workers/GeometryPipeline-ce4339ed.js +3690 -0
- package/dist/assets/cesium/Workers/IndexDatatype-a55ceaa1.js +200 -0
- package/dist/assets/cesium/Workers/IntersectionTests-f6e6bd8a.js +1836 -0
- package/dist/assets/cesium/Workers/Math-2dbd6b93.js +1330 -0
- package/dist/assets/cesium/Workers/Matrix2-13178034.js +7086 -0
- package/dist/assets/cesium/Workers/Matrix3-315394f6.js +4283 -0
- package/dist/assets/cesium/Workers/OrientedBoundingBox-04920dc7.js +1257 -0
- package/dist/assets/cesium/Workers/Plane-900aa728.js +309 -0
- package/dist/assets/cesium/Workers/PolygonGeometryLibrary-a8680d96.js +1074 -0
- package/dist/assets/cesium/Workers/PolygonPipeline-844aab0a.js +1345 -0
- package/dist/assets/cesium/Workers/PolylinePipeline-32f36d2a.js +573 -0
- package/dist/assets/cesium/Workers/PolylineVolumeGeometryLibrary-a510d657.js +781 -0
- package/dist/assets/cesium/Workers/PrimitivePipeline-ba38434a.js +966 -0
- package/dist/assets/cesium/Workers/RectangleGeometryLibrary-bdba697e.js +280 -0
- package/dist/assets/cesium/Workers/RuntimeError-06c93819.js +68 -0
- package/dist/assets/cesium/Workers/TerrainEncoding-833187da.js +1227 -0
- package/dist/assets/cesium/Workers/Transforms-40229881.js +14696 -0
- package/dist/assets/cesium/Workers/VertexFormat-6b480673.js +312 -0
- package/dist/assets/cesium/Workers/WallGeometryLibrary-919eed92.js +211 -0
- package/dist/assets/cesium/Workers/WebGLConstants-a8cc3e8c.js +620 -0
- package/dist/assets/cesium/Workers/WebMercatorProjection-13a90d41.js +151 -0
- package/dist/assets/cesium/Workers/arrayRemoveDuplicates-c2038105.js +129 -0
- package/dist/assets/cesium/Workers/cesiumWorkerBootstrapper.js +1336 -4
- package/dist/assets/cesium/Workers/combine-ca22a614.js +82 -0
- package/dist/assets/cesium/Workers/combineGeometry.js +17 -25
- package/dist/assets/cesium/Workers/createBoxGeometry.js +12 -25
- package/dist/assets/cesium/Workers/createBoxOutlineGeometry.js +313 -25
- package/dist/assets/cesium/Workers/createCircleGeometry.js +213 -25
- package/dist/assets/cesium/Workers/createCircleOutlineGeometry.js +160 -25
- package/dist/assets/cesium/Workers/createCoplanarPolygonGeometry.js +586 -25
- package/dist/assets/cesium/Workers/createCoplanarPolygonOutlineGeometry.js +236 -25
- package/dist/assets/cesium/Workers/createCorridorGeometry.js +1407 -25
- package/dist/assets/cesium/Workers/createCorridorOutlineGeometry.js +603 -25
- package/dist/assets/cesium/Workers/createCylinderGeometry.js +12 -25
- package/dist/assets/cesium/Workers/createCylinderOutlineGeometry.js +265 -25
- package/dist/assets/cesium/Workers/createEllipseGeometry.js +14 -25
- package/dist/assets/cesium/Workers/createEllipseOutlineGeometry.js +14 -25
- package/dist/assets/cesium/Workers/createEllipsoidGeometry.js +12 -25
- package/dist/assets/cesium/Workers/createEllipsoidOutlineGeometry.js +15 -25
- package/dist/assets/cesium/Workers/createFrustumGeometry.js +12 -25
- package/dist/assets/cesium/Workers/createFrustumOutlineGeometry.js +251 -25
- package/dist/assets/cesium/Workers/createGeometry.js +55 -25
- package/dist/assets/cesium/Workers/createGroundPolylineGeometry.js +2134 -25
- package/dist/assets/cesium/Workers/createPlaneGeometry.js +250 -25
- package/dist/assets/cesium/Workers/createPlaneOutlineGeometry.js +115 -25
- package/dist/assets/cesium/Workers/createPolygonGeometry.js +1420 -25
- package/dist/assets/cesium/Workers/createPolygonOutlineGeometry.js +683 -25
- package/dist/assets/cesium/Workers/createPolylineGeometry.js +571 -25
- package/dist/assets/cesium/Workers/createPolylineVolumeGeometry.js +411 -25
- package/dist/assets/cesium/Workers/createPolylineVolumeOutlineGeometry.js +301 -25
- package/dist/assets/cesium/Workers/createRectangleGeometry.js +1476 -25
- package/dist/assets/cesium/Workers/createRectangleOutlineGeometry.js +535 -25
- package/dist/assets/cesium/Workers/createSimplePolylineGeometry.js +458 -25
- package/dist/assets/cesium/Workers/createSphereGeometry.js +123 -25
- package/dist/assets/cesium/Workers/createSphereOutlineGeometry.js +126 -25
- package/dist/assets/cesium/Workers/createTaskProcessorWorker.js +127 -25
- package/dist/assets/cesium/Workers/createVectorTileClampedPolylines.js +535 -25
- package/dist/assets/cesium/Workers/createVectorTileGeometries.js +445 -25
- package/dist/assets/cesium/Workers/createVectorTilePoints.js +79 -25
- package/dist/assets/cesium/Workers/createVectorTilePolygons.js +406 -25
- package/dist/assets/cesium/Workers/createVectorTilePolylines.js +254 -25
- package/dist/assets/cesium/Workers/createVerticesFromGoogleEarthEnterpriseBuffer.js +640 -25
- package/dist/assets/cesium/Workers/createVerticesFromHeightmap.js +2711 -27
- package/dist/assets/cesium/Workers/createVerticesFromQuantizedTerrainMesh.js +994 -25
- package/dist/assets/cesium/Workers/createWallGeometry.js +623 -25
- package/dist/assets/cesium/Workers/createWallOutlineGeometry.js +432 -25
- package/dist/assets/cesium/Workers/decodeDraco.js +381 -25
- package/dist/assets/cesium/Workers/decodeGoogleEarthEnterprisePacket.js +3687 -25
- package/dist/assets/cesium/Workers/decodeI3S.js +1040 -0
- package/dist/assets/cesium/Workers/defaultValue-0a909f67.js +51 -0
- package/dist/assets/cesium/Workers/package.js +2 -2
- package/dist/assets/cesium/Workers/transcodeKTX2.js +1516 -25
- package/dist/assets/cesium/Workers/transferTypedArrayTest.js +18 -2
- package/dist/assets/cesium/Workers/upsampleQuantizedTerrainMesh.js +1023 -25
- package/dist/assets/{cesium.2f992f.js → cesium.49585c.js} +112161 -108735
- package/dist/assets/cesium.js +1 -1
- package/dist/assets/{core.cb0408.js → core.59d4d1.js} +1616 -1629
- package/dist/assets/core.js +1 -1
- package/dist/assets/{index.bccdf969.js → index.a3861d4e.js} +1 -1
- package/dist/assets/{ol.5e3fd0.js → ol.c1c512.js} +6992 -6972
- package/dist/assets/ol.js +1 -1
- package/dist/assets/ui.80175f.css +1 -0
- package/dist/assets/{ui.08c48f.js → ui.80175f.js} +6121 -6785
- package/dist/assets/ui.js +1 -1
- package/dist/assets/{vue.228ead.js → vue.a08ab1.js} +0 -0
- package/dist/assets/vue.js +2 -2
- package/dist/assets/{vuetify.0b5039.css → vuetify.efc158.css} +0 -0
- package/dist/assets/{vuetify.0b5039.js → vuetify.efc158.js} +1 -1
- package/dist/assets/vuetify.js +2 -2
- package/dist/index.html +1 -1
- package/index.js +2 -1
- package/lib/cesium.js +1 -1
- package/package.json +3 -4
- package/plugins/{simple-graph → @vcmap/simple-graph}/README.md +1 -1
- package/plugins/{simple-graph → @vcmap/simple-graph}/SimpleGraphComponent.vue +0 -0
- package/plugins/{simple-graph → @vcmap/simple-graph}/index.js +0 -0
- package/plugins/{simple-graph → @vcmap/simple-graph}/package.json +0 -0
- package/plugins/{simple-graph → @vcmap/simple-graph}/simpleGraphView.js +0 -0
- package/plugins/@vcmap-show-case/README.md +20 -0
- package/plugins/{buttonExamples/ButtonExamples.vue → @vcmap-show-case/buttons-example/ButtonsExample.vue} +1 -1
- package/plugins/@vcmap-show-case/buttons-example/README.md +4 -0
- package/plugins/{buttonExamples → @vcmap-show-case/buttons-example}/index.js +16 -8
- package/plugins/@vcmap-show-case/buttons-example/package.json +5 -0
- package/plugins/{categoryTest → @vcmap-show-case/category-tester}/Categories.vue +7 -6
- package/plugins/{categoryTest → @vcmap-show-case/category-tester}/Category.vue +4 -3
- package/plugins/@vcmap-show-case/category-tester/README.md +3 -0
- package/plugins/{categoryTest → @vcmap-show-case/category-tester}/index.js +12 -4
- package/plugins/@vcmap-show-case/category-tester/package.json +5 -0
- package/plugins/@vcmap-show-case/config-editor/README.md +3 -0
- package/plugins/{test → @vcmap-show-case/config-editor}/editor.vue +0 -0
- package/plugins/@vcmap-show-case/config-editor/index.js +47 -0
- package/plugins/@vcmap-show-case/config-editor/package.json +5 -0
- package/plugins/@vcmap-show-case/context-menu-tester/README.md +3 -0
- package/plugins/@vcmap-show-case/context-menu-tester/index.js +33 -0
- package/plugins/@vcmap-show-case/context-menu-tester/package.json +5 -0
- package/plugins/{@vcmap/pluginExample/pluginExampleComponent.vue → @vcmap-show-case/form-inputs-example/FormInputsExample.vue} +14 -13
- package/plugins/@vcmap-show-case/form-inputs-example/README.md +4 -0
- package/plugins/@vcmap-show-case/form-inputs-example/config.json +5 -0
- package/plugins/{@vcmap/pluginExample → @vcmap-show-case/form-inputs-example}/exampleActions.js +1 -1
- package/plugins/{@vcmap/pluginExample → @vcmap-show-case/form-inputs-example}/index.js +23 -22
- package/plugins/@vcmap-show-case/form-inputs-example/package.json +5 -0
- package/plugins/{@vcmap/pluginExample → @vcmap-show-case/form-inputs-example}/validation.js +0 -0
- package/plugins/@vcmap-show-case/icons-example/README.md +5 -0
- package/plugins/@vcmap-show-case/icons-example/allIconsComponent.vue +51 -0
- package/plugins/@vcmap-show-case/icons-example/index.js +44 -0
- package/plugins/@vcmap-show-case/icons-example/package.json +5 -0
- package/plugins/{test/testList.vue → @vcmap-show-case/list-example/ListExample.vue} +1 -1
- package/plugins/@vcmap-show-case/list-example/README.md +3 -0
- package/plugins/@vcmap-show-case/list-example/index.js +44 -0
- package/plugins/@vcmap-show-case/list-example/package.json +5 -0
- package/plugins/@vcmap-show-case/notifier-tester/README.md +3 -0
- package/plugins/{notifier → @vcmap-show-case/notifier-tester}/index.js +11 -6
- package/plugins/{notifier → @vcmap-show-case/notifier-tester}/notifierTester.vue +0 -0
- package/plugins/@vcmap-show-case/notifier-tester/package.json +5 -0
- package/plugins/@vcmap-show-case/textfields-example/README.md +3 -0
- package/plugins/{example/mySuperComponent.vue → @vcmap-show-case/textfields-example/TextfieldsExample.vue} +1 -7
- package/plugins/{example → @vcmap-show-case/textfields-example}/index.js +58 -62
- package/plugins/@vcmap-show-case/textfields-example/package.json +5 -0
- package/plugins/@vcmap-show-case/window-tester/README.md +3 -0
- package/plugins/{test/windowManagerExample.vue → @vcmap-show-case/window-tester/WindowExample.vue} +36 -20
- package/plugins/{test → @vcmap-show-case/window-tester}/emptyComponent.vue +8 -3
- package/plugins/@vcmap-show-case/window-tester/index.js +62 -0
- package/plugins/{test → @vcmap-show-case/window-tester}/myCustomHeader.vue +0 -0
- package/plugins/@vcmap-show-case/window-tester/package.json +5 -0
- package/plugins/{test → @vcmap-show-case/window-tester}/toolbox-data.js +9 -9
- package/plugins/{test/vcsContent.vue → @vcmap-show-case/window-tester/windowExampleContent.vue} +1 -5
- package/plugins/@vcmap-show-case/wizard-example/README.md +3 -0
- package/plugins/{wizardExample → @vcmap-show-case/wizard-example}/index.js +12 -6
- package/plugins/@vcmap-show-case/wizard-example/package.json +5 -0
- package/plugins/@vcmap-show-case/wizard-example/wizardExample.vue +95 -0
- package/plugins/package.json +2 -1
- package/src/actions/actionHelper.js +1 -3
- package/src/actions/stateRefAction.js +0 -10
- package/src/application/VcsApp.vue +42 -23
- package/src/application/VcsMap.vue +9 -0
- package/src/components/buttons/VcsActionButtonList.vue +1 -0
- package/src/components/form-inputs-controls/VcsCheckbox.vue +3 -1
- package/src/components/form-inputs-controls/VcsWizard.vue +17 -20
- package/src/components/form-inputs-controls/VcsWizardStep.vue +160 -0
- package/src/{icons → components/icons}/+all.js +0 -0
- package/src/{icons → components/icons}/2DAreaIcon.vue +0 -0
- package/src/{icons → components/icons}/2DDistanceIcon.vue +0 -0
- package/src/{icons → components/icons}/3DAreaIcon.vue +0 -0
- package/src/{icons → components/icons}/3DDistanceIcon.vue +0 -0
- package/src/{icons → components/icons}/3DHeightIcon.vue +0 -0
- package/src/{icons → components/icons}/AngleIcon.vue +0 -0
- package/src/{icons → components/icons}/AssociationsIcon.vue +0 -0
- package/src/{icons → components/icons}/AxisIcon.vue +0 -0
- package/src/{icons → components/icons}/BoundingBoxIcon.vue +0 -0
- package/src/{icons → components/icons}/CheckboxCheckedIcon.vue +0 -0
- package/src/{icons → components/icons}/CheckboxIcon.vue +0 -0
- package/src/{icons → components/icons}/CheckboxIndeterminateIcon.vue +0 -0
- package/src/{icons → components/icons}/CircleIcon.vue +0 -0
- package/src/{icons → components/icons}/ClippingHorizontalIcon.vue +0 -0
- package/src/{icons → components/icons}/ClippingIcon.vue +0 -0
- package/src/{icons → components/icons}/ClippingVerticalIcon.vue +0 -0
- package/src/{icons → components/icons}/ColorPickerIcon.vue +0 -0
- package/src/{icons → components/icons}/ColorSwatchIcon.vue +0 -0
- package/src/{icons → components/icons}/CommentIcon.vue +0 -0
- package/src/{icons → components/icons}/CompassIcon.vue +0 -0
- package/src/{icons → components/icons}/ComponentsIcon.vue +0 -0
- package/src/{icons → components/icons}/ConeIcon.vue +0 -0
- package/src/{icons → components/icons}/DimensionsHouseIcon.vue +0 -0
- package/src/{icons → components/icons}/EditIcon.vue +0 -0
- package/src/{icons → components/icons}/ElevationProfileIcon.vue +0 -0
- package/src/{icons → components/icons}/ExportAreaIcon.vue +0 -0
- package/src/{icons → components/icons}/ExportFlightIcon.vue +0 -0
- package/src/{icons → components/icons}/ExportIcon.vue +0 -0
- package/src/{icons → components/icons}/ExternalLinkIcon.vue +0 -0
- package/src/{icons → components/icons}/EyeIcon.vue +0 -0
- package/src/{icons → components/icons}/FastForwardIcon.vue +0 -0
- package/src/{icons → components/icons}/FilterIcon.vue +0 -0
- package/src/{icons → components/icons}/GlobalTerrainIcon.vue +0 -0
- package/src/{icons → components/icons}/GlobeNatureIcon.vue +0 -0
- package/src/{icons → components/icons}/GroundIcon.vue +0 -0
- package/src/{icons → components/icons}/HealthCareIndustriesIcon.vue +0 -0
- package/src/{icons → components/icons}/HelpIcon.vue +0 -0
- package/src/{icons → components/icons}/HideIcon.vue +0 -0
- package/src/{icons → components/icons}/HomePointIcon.vue +0 -0
- package/src/{icons → components/icons}/HospitalsIcon.vue +0 -0
- package/src/{icons → components/icons}/HouseIcon.vue +0 -0
- package/src/{icons → components/icons}/ImportIcon.vue +0 -0
- package/src/{icons → components/icons}/InfoIcon.vue +0 -0
- package/src/{icons → components/icons}/KebabIcon.vue +0 -0
- package/src/{icons → components/icons}/LabelIcon.vue +0 -0
- package/src/{icons → components/icons}/LayersIcon.vue +0 -0
- package/src/{icons → components/icons}/LegendIcon.vue +0 -0
- package/src/{icons → components/icons}/LineIcon.vue +0 -0
- package/src/{icons → components/icons}/LinkIcon.vue +0 -0
- package/src/{icons → components/icons}/LogoutIcon.vue +0 -0
- package/src/{icons → components/icons}/MapIcon.vue +0 -0
- package/src/{icons → components/icons}/MenuIcon.vue +0 -0
- package/src/{icons → components/icons}/MinusIcon.vue +0 -0
- package/src/{icons → components/icons}/ObjectAttributeIcon.vue +0 -0
- package/src/{icons → components/icons}/ObjectSelectIcon.vue +0 -0
- package/src/{icons → components/icons}/ObliqueViewIcon.vue +0 -0
- package/src/{icons → components/icons}/PdfIcon.vue +0 -0
- package/src/{icons → components/icons}/PedestrianIcon.vue +0 -0
- package/src/{icons → components/icons}/PenIcon.vue +0 -0
- package/src/{icons → components/icons}/PlayCircleIcon.vue +0 -0
- package/src/{icons → components/icons}/PlusIcon.vue +0 -0
- package/src/{icons → components/icons}/PoiIcon.vue +0 -0
- package/src/{icons → components/icons}/PointSelectIcon.vue +0 -0
- package/src/{icons → components/icons}/PolygonIcon.vue +0 -0
- package/src/{icons → components/icons}/PresentationModeIcon.vue +0 -0
- package/src/{icons → components/icons}/ProgressIcon.vue +0 -0
- package/src/{icons → components/icons}/QueryIcon.vue +0 -0
- package/src/{icons → components/icons}/RectangleIcon.vue +0 -0
- package/src/{icons → components/icons}/ReturnIcon.vue +0 -0
- package/src/{icons → components/icons}/RewindIcon.vue +0 -0
- package/src/{icons → components/icons}/RotateLeftIcon.vue +0 -0
- package/src/{icons → components/icons}/RotateRightIcon.vue +0 -0
- package/src/{icons → components/icons}/ScreenshotIcon.vue +0 -0
- package/src/{icons → components/icons}/SearchIcon.vue +0 -0
- package/src/{icons → components/icons}/ShadowIcon.vue +0 -0
- package/src/{icons → components/icons}/ShapesIcon.vue +0 -0
- package/src/{icons → components/icons}/ShareIcon.vue +0 -0
- package/src/{icons → components/icons}/SimpleCircleFilledIcon.vue +0 -0
- package/src/{icons → components/icons}/SimpleCircleHalfFilledIcon.vue +0 -0
- package/src/{icons → components/icons}/SimpleCircleOutlinedIcon.vue +0 -0
- package/src/{icons → components/icons}/SkipNextIcon.vue +0 -0
- package/src/{icons → components/icons}/SkipPreviousIcon.vue +0 -0
- package/src/{icons → components/icons}/SplitViewIcon.vue +0 -0
- package/src/{icons → components/icons}/TerrainBoxIcon.vue +0 -0
- package/src/{icons → components/icons}/TextStyleIcon.vue +0 -0
- package/src/{icons → components/icons}/ThreeDimensionsIcon.vue +0 -0
- package/src/{icons → components/icons}/ToolsIcon.vue +0 -0
- package/src/{icons → components/icons}/TouchIcon.vue +0 -0
- package/src/{icons → components/icons}/TrashCanIcon.vue +0 -0
- package/src/{icons → components/icons}/TriangleIcon.vue +0 -0
- package/src/{icons → components/icons}/TwoDimensionsIcon.vue +0 -0
- package/src/{icons → components/icons}/UploadIcon.vue +0 -0
- package/src/{icons → components/icons}/UserProfileIcon.vue +0 -0
- package/src/{icons → components/icons}/UserShareIcon.vue +0 -0
- package/src/{icons → components/icons}/VideoRecorderIcon.vue +0 -0
- package/src/{icons → components/icons}/ViewpointFlightIcon.vue +0 -0
- package/src/{icons → components/icons}/ViewpointIcon.vue +0 -0
- package/src/{icons → components/icons}/Viewshed360Icon.vue +0 -0
- package/src/{icons → components/icons}/ViewshedConeIcon.vue +0 -0
- package/src/{icons → components/icons}/ViewshedIcon.vue +0 -0
- package/src/{icons → components/icons}/WalkingIcon.vue +0 -0
- package/src/{icons → components/icons}/WallIcon.vue +0 -0
- package/src/{icons → components/icons}/WandIcon.vue +0 -0
- package/src/components/lists/VcsList.vue +21 -12
- package/src/components/lists/VcsTreeviewLeaf.vue +14 -2
- package/src/components/notification/VcsTooltip.vue +1 -1
- package/src/featureInfo/abstractFeatureInfoView.js +1 -1
- package/src/featureInfo/addressBalloonFeatureInfoView.js +1 -1
- package/src/featureInfo/balloonFeatureInfoView.js +1 -1
- package/src/featureInfo/balloonHelper.js +6 -6
- package/src/featureInfo/featureInfo.js +2 -2
- package/src/i18n/de.js +2 -6
- package/src/i18n/en.js +2 -6
- package/src/legend/legendHelper.js +4 -3
- package/src/legend/vcsLegend.vue +21 -2
- package/src/manager/window/WindowComponent.vue +42 -4
- package/src/manager/window/WindowComponentHeader.vue +1 -1
- package/src/manager/window/windowHelper.js +7 -11
- package/src/manager/window/windowManager.js +15 -11
- package/src/navigation/mapNavCompass.vue +13 -7
- package/src/navigation/mapNavigation.vue +66 -4
- package/src/navigation/orientationToolsButton.vue +1 -1
- package/src/navigation/overviewMap.js +26 -10
- package/src/navigation/vcsCompass.vue +4 -73
- package/src/setup.js +1 -1
- package/src/vuePlugins/vuetify.js +1 -1
- package/dist/assets/cesium/Workers/ArcType-c9b2b290.js +0 -25
- package/dist/assets/cesium/Workers/AttributeCompression-7b0f288d.js +0 -25
- package/dist/assets/cesium/Workers/AxisAlignedBoundingBox-d0c22774.js +0 -25
- package/dist/assets/cesium/Workers/BoundingRectangle-201b1a81.js +0 -25
- package/dist/assets/cesium/Workers/BoxGeometry-4985457c.js +0 -25
- package/dist/assets/cesium/Workers/Color-cc8c18b3.js +0 -25
- package/dist/assets/cesium/Workers/ComponentDatatype-0200bf8c.js +0 -25
- package/dist/assets/cesium/Workers/CoplanarPolygonGeometryLibrary-4345acdf.js +0 -25
- package/dist/assets/cesium/Workers/CorridorGeometryLibrary-850a6c35.js +0 -25
- package/dist/assets/cesium/Workers/CylinderGeometry-57a1051a.js +0 -25
- package/dist/assets/cesium/Workers/CylinderGeometryLibrary-62ce5a1f.js +0 -25
- package/dist/assets/cesium/Workers/EllipseGeometry-8627398f.js +0 -25
- package/dist/assets/cesium/Workers/EllipseGeometryLibrary-e5919563.js +0 -25
- package/dist/assets/cesium/Workers/EllipseOutlineGeometry-96fd4ae1.js +0 -25
- package/dist/assets/cesium/Workers/EllipsoidGeodesic-8bfefbff.js +0 -25
- package/dist/assets/cesium/Workers/EllipsoidGeometry-377329b9.js +0 -25
- package/dist/assets/cesium/Workers/EllipsoidOutlineGeometry-e6e16e49.js +0 -25
- package/dist/assets/cesium/Workers/EllipsoidRhumbLine-03528f73.js +0 -25
- package/dist/assets/cesium/Workers/EllipsoidTangentPlane-c080fd1b.js +0 -25
- package/dist/assets/cesium/Workers/EncodedCartesian3-ea0e408f.js +0 -25
- package/dist/assets/cesium/Workers/FrustumGeometry-a8b5d817.js +0 -25
- package/dist/assets/cesium/Workers/GeometryAttribute-8458a8fd.js +0 -25
- package/dist/assets/cesium/Workers/GeometryAttributes-ac0f8485.js +0 -25
- package/dist/assets/cesium/Workers/GeometryInstance-ee3aa3ba.js +0 -25
- package/dist/assets/cesium/Workers/GeometryOffsetAttribute-08ae0c50.js +0 -25
- package/dist/assets/cesium/Workers/GeometryPipeline-33ca229c.js +0 -25
- package/dist/assets/cesium/Workers/IndexDatatype-e713bfd2.js +0 -25
- package/dist/assets/cesium/Workers/IntersectionTests-eb4db8e0.js +0 -25
- package/dist/assets/cesium/Workers/Matrix2-eefef8eb.js +0 -25
- package/dist/assets/cesium/Workers/OrientedBoundingBox-5193f9a2.js +0 -25
- package/dist/assets/cesium/Workers/Plane-b0299683.js +0 -25
- package/dist/assets/cesium/Workers/PolygonGeometryLibrary-b61295f3.js +0 -25
- package/dist/assets/cesium/Workers/PolygonPipeline-eb527514.js +0 -25
- package/dist/assets/cesium/Workers/PolylinePipeline-0f23dd84.js +0 -25
- package/dist/assets/cesium/Workers/PolylineVolumeGeometryLibrary-2d903430.js +0 -25
- package/dist/assets/cesium/Workers/PrimitivePipeline-e2640413.js +0 -25
- package/dist/assets/cesium/Workers/RectangleGeometryLibrary-ae8bf8a5.js +0 -25
- package/dist/assets/cesium/Workers/RuntimeError-5baf5c66.js +0 -25
- package/dist/assets/cesium/Workers/TerrainEncoding-bc10ab54.js +0 -25
- package/dist/assets/cesium/Workers/Transforms-d2e5867e.js +0 -63
- package/dist/assets/cesium/Workers/VertexFormat-5ec0d9ff.js +0 -25
- package/dist/assets/cesium/Workers/WallGeometryLibrary-1a33e416.js +0 -25
- package/dist/assets/cesium/Workers/WebGLConstants-5b50ced1.js +0 -25
- package/dist/assets/cesium/Workers/WebMercatorProjection-cd2f30c2.js +0 -25
- package/dist/assets/cesium/Workers/_commonjsHelpers-bc29abbc.js +0 -25
- package/dist/assets/cesium/Workers/arrayRemoveDuplicates-f13aceb1.js +0 -25
- package/dist/assets/cesium/Workers/combine-7533016d.js +0 -25
- package/dist/assets/cesium/Workers/defaultValue-0c475b81.js +0 -25
- package/dist/assets/cesium/Workers/package.json +0 -1
- package/dist/assets/ui.08c48f.css +0 -1
- package/plugins/@vcmap/pluginExample/config.json +0 -6
- package/plugins/@vcmap/pluginExample/package.json +0 -7
- package/plugins/categoryTest/ItemEditor.vue +0 -13
- package/plugins/test/allIconsComponent.vue +0 -50
- package/plugins/test/index.js +0 -209
- package/plugins/wizardExample/wizardExample.vue +0 -77
- package/src/components/form-inputs-controls/VcsColorPicker.vue +0 -85
@@ -1,25 +1,994 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
1
|
+
define(['./AxisAlignedBoundingBox-ff186ccc', './Matrix2-13178034', './Matrix3-315394f6', './defaultValue-0a909f67', './TerrainEncoding-833187da', './IndexDatatype-a55ceaa1', './Math-2dbd6b93', './Check-666ab1a0', './Transforms-40229881', './WebMercatorProjection-13a90d41', './createTaskProcessorWorker', './RuntimeError-06c93819', './AttributeCompression-b646d393', './ComponentDatatype-f7b11d02', './WebGLConstants-a8cc3e8c', './combine-ca22a614'], (function (AxisAlignedBoundingBox, Matrix2, Matrix3, defaultValue, TerrainEncoding, IndexDatatype, Math$1, Check, Transforms, WebMercatorProjection, createTaskProcessorWorker, RuntimeError, AttributeCompression, ComponentDatatype, WebGLConstants, combine) { 'use strict';
|
2
|
+
|
3
|
+
/**
|
4
|
+
* Provides terrain or other geometry for the surface of an ellipsoid. The surface geometry is
|
5
|
+
* organized into a pyramid of tiles according to a {@link TilingScheme}. This type describes an
|
6
|
+
* interface and is not intended to be instantiated directly.
|
7
|
+
*
|
8
|
+
* @alias TerrainProvider
|
9
|
+
* @constructor
|
10
|
+
*
|
11
|
+
* @see EllipsoidTerrainProvider
|
12
|
+
* @see CesiumTerrainProvider
|
13
|
+
* @see VRTheWorldTerrainProvider
|
14
|
+
* @see GoogleEarthEnterpriseTerrainProvider
|
15
|
+
*/
|
16
|
+
function TerrainProvider() {
|
17
|
+
Check.DeveloperError.throwInstantiationError();
|
18
|
+
}
|
19
|
+
|
20
|
+
Object.defineProperties(TerrainProvider.prototype, {
|
21
|
+
/**
|
22
|
+
* Gets an event that is raised when the terrain provider encounters an asynchronous error.. By subscribing
|
23
|
+
* to the event, you will be notified of the error and can potentially recover from it. Event listeners
|
24
|
+
* are passed an instance of {@link TileProviderError}.
|
25
|
+
* @memberof TerrainProvider.prototype
|
26
|
+
* @type {Event<TerrainProvider.ErrorEvent>}
|
27
|
+
* @readonly
|
28
|
+
*/
|
29
|
+
errorEvent: {
|
30
|
+
get: Check.DeveloperError.throwInstantiationError,
|
31
|
+
},
|
32
|
+
|
33
|
+
/**
|
34
|
+
* Gets the credit to display when this terrain provider is active. Typically this is used to credit
|
35
|
+
* the source of the terrain. This function should
|
36
|
+
* not be called before {@link TerrainProvider#ready} returns true.
|
37
|
+
* @memberof TerrainProvider.prototype
|
38
|
+
* @type {Credit}
|
39
|
+
* @readonly
|
40
|
+
*/
|
41
|
+
credit: {
|
42
|
+
get: Check.DeveloperError.throwInstantiationError,
|
43
|
+
},
|
44
|
+
|
45
|
+
/**
|
46
|
+
* Gets the tiling scheme used by the provider. This function should
|
47
|
+
* not be called before {@link TerrainProvider#ready} returns true.
|
48
|
+
* @memberof TerrainProvider.prototype
|
49
|
+
* @type {TilingScheme}
|
50
|
+
* @readonly
|
51
|
+
*/
|
52
|
+
tilingScheme: {
|
53
|
+
get: Check.DeveloperError.throwInstantiationError,
|
54
|
+
},
|
55
|
+
|
56
|
+
/**
|
57
|
+
* Gets a value indicating whether or not the provider is ready for use.
|
58
|
+
* @memberof TerrainProvider.prototype
|
59
|
+
* @type {Boolean}
|
60
|
+
* @readonly
|
61
|
+
*/
|
62
|
+
ready: {
|
63
|
+
get: Check.DeveloperError.throwInstantiationError,
|
64
|
+
},
|
65
|
+
|
66
|
+
/**
|
67
|
+
* Gets a promise that resolves to true when the provider is ready for use.
|
68
|
+
* @memberof TerrainProvider.prototype
|
69
|
+
* @type {Promise.<Boolean>}
|
70
|
+
* @readonly
|
71
|
+
*/
|
72
|
+
readyPromise: {
|
73
|
+
get: Check.DeveloperError.throwInstantiationError,
|
74
|
+
},
|
75
|
+
|
76
|
+
/**
|
77
|
+
* Gets a value indicating whether or not the provider includes a water mask. The water mask
|
78
|
+
* indicates which areas of the globe are water rather than land, so they can be rendered
|
79
|
+
* as a reflective surface with animated waves. This function should not be
|
80
|
+
* called before {@link TerrainProvider#ready} returns true.
|
81
|
+
* @memberof TerrainProvider.prototype
|
82
|
+
* @type {Boolean}
|
83
|
+
* @readonly
|
84
|
+
*/
|
85
|
+
hasWaterMask: {
|
86
|
+
get: Check.DeveloperError.throwInstantiationError,
|
87
|
+
},
|
88
|
+
|
89
|
+
/**
|
90
|
+
* Gets a value indicating whether or not the requested tiles include vertex normals.
|
91
|
+
* This function should not be called before {@link TerrainProvider#ready} returns true.
|
92
|
+
* @memberof TerrainProvider.prototype
|
93
|
+
* @type {Boolean}
|
94
|
+
* @readonly
|
95
|
+
*/
|
96
|
+
hasVertexNormals: {
|
97
|
+
get: Check.DeveloperError.throwInstantiationError,
|
98
|
+
},
|
99
|
+
|
100
|
+
/**
|
101
|
+
* Gets an object that can be used to determine availability of terrain from this provider, such as
|
102
|
+
* at points and in rectangles. This function should not be called before
|
103
|
+
* {@link TerrainProvider#ready} returns true. This property may be undefined if availability
|
104
|
+
* information is not available.
|
105
|
+
* @memberof TerrainProvider.prototype
|
106
|
+
* @type {TileAvailability}
|
107
|
+
* @readonly
|
108
|
+
*/
|
109
|
+
availability: {
|
110
|
+
get: Check.DeveloperError.throwInstantiationError,
|
111
|
+
},
|
112
|
+
});
|
113
|
+
|
114
|
+
const regularGridIndicesCache = [];
|
115
|
+
|
116
|
+
/**
|
117
|
+
* Gets a list of indices for a triangle mesh representing a regular grid. Calling
|
118
|
+
* this function multiple times with the same grid width and height returns the
|
119
|
+
* same list of indices. The total number of vertices must be less than or equal
|
120
|
+
* to 65536.
|
121
|
+
*
|
122
|
+
* @param {Number} width The number of vertices in the regular grid in the horizontal direction.
|
123
|
+
* @param {Number} height The number of vertices in the regular grid in the vertical direction.
|
124
|
+
* @returns {Uint16Array|Uint32Array} The list of indices. Uint16Array gets returned for 64KB or less and Uint32Array for 4GB or less.
|
125
|
+
*/
|
126
|
+
TerrainProvider.getRegularGridIndices = function (width, height) {
|
127
|
+
//>>includeStart('debug', pragmas.debug);
|
128
|
+
if (width * height >= Math$1.CesiumMath.FOUR_GIGABYTES) {
|
129
|
+
throw new Check.DeveloperError(
|
130
|
+
"The total number of vertices (width * height) must be less than 4,294,967,296."
|
131
|
+
);
|
132
|
+
}
|
133
|
+
//>>includeEnd('debug');
|
134
|
+
|
135
|
+
let byWidth = regularGridIndicesCache[width];
|
136
|
+
if (!defaultValue.defined(byWidth)) {
|
137
|
+
regularGridIndicesCache[width] = byWidth = [];
|
138
|
+
}
|
139
|
+
|
140
|
+
let indices = byWidth[height];
|
141
|
+
if (!defaultValue.defined(indices)) {
|
142
|
+
if (width * height < Math$1.CesiumMath.SIXTY_FOUR_KILOBYTES) {
|
143
|
+
indices = byWidth[height] = new Uint16Array(
|
144
|
+
(width - 1) * (height - 1) * 6
|
145
|
+
);
|
146
|
+
} else {
|
147
|
+
indices = byWidth[height] = new Uint32Array(
|
148
|
+
(width - 1) * (height - 1) * 6
|
149
|
+
);
|
150
|
+
}
|
151
|
+
addRegularGridIndices(width, height, indices, 0);
|
152
|
+
}
|
153
|
+
|
154
|
+
return indices;
|
155
|
+
};
|
156
|
+
|
157
|
+
const regularGridAndEdgeIndicesCache = [];
|
158
|
+
|
159
|
+
/**
|
160
|
+
* @private
|
161
|
+
*/
|
162
|
+
TerrainProvider.getRegularGridIndicesAndEdgeIndices = function (width, height) {
|
163
|
+
//>>includeStart('debug', pragmas.debug);
|
164
|
+
if (width * height >= Math$1.CesiumMath.FOUR_GIGABYTES) {
|
165
|
+
throw new Check.DeveloperError(
|
166
|
+
"The total number of vertices (width * height) must be less than 4,294,967,296."
|
167
|
+
);
|
168
|
+
}
|
169
|
+
//>>includeEnd('debug');
|
170
|
+
|
171
|
+
let byWidth = regularGridAndEdgeIndicesCache[width];
|
172
|
+
if (!defaultValue.defined(byWidth)) {
|
173
|
+
regularGridAndEdgeIndicesCache[width] = byWidth = [];
|
174
|
+
}
|
175
|
+
|
176
|
+
let indicesAndEdges = byWidth[height];
|
177
|
+
if (!defaultValue.defined(indicesAndEdges)) {
|
178
|
+
const indices = TerrainProvider.getRegularGridIndices(width, height);
|
179
|
+
|
180
|
+
const edgeIndices = getEdgeIndices(width, height);
|
181
|
+
const westIndicesSouthToNorth = edgeIndices.westIndicesSouthToNorth;
|
182
|
+
const southIndicesEastToWest = edgeIndices.southIndicesEastToWest;
|
183
|
+
const eastIndicesNorthToSouth = edgeIndices.eastIndicesNorthToSouth;
|
184
|
+
const northIndicesWestToEast = edgeIndices.northIndicesWestToEast;
|
185
|
+
|
186
|
+
indicesAndEdges = byWidth[height] = {
|
187
|
+
indices: indices,
|
188
|
+
westIndicesSouthToNorth: westIndicesSouthToNorth,
|
189
|
+
southIndicesEastToWest: southIndicesEastToWest,
|
190
|
+
eastIndicesNorthToSouth: eastIndicesNorthToSouth,
|
191
|
+
northIndicesWestToEast: northIndicesWestToEast,
|
192
|
+
};
|
193
|
+
}
|
194
|
+
|
195
|
+
return indicesAndEdges;
|
196
|
+
};
|
197
|
+
|
198
|
+
const regularGridAndSkirtAndEdgeIndicesCache = [];
|
199
|
+
|
200
|
+
/**
|
201
|
+
* @private
|
202
|
+
*/
|
203
|
+
TerrainProvider.getRegularGridAndSkirtIndicesAndEdgeIndices = function (
|
204
|
+
width,
|
205
|
+
height
|
206
|
+
) {
|
207
|
+
//>>includeStart('debug', pragmas.debug);
|
208
|
+
if (width * height >= Math$1.CesiumMath.FOUR_GIGABYTES) {
|
209
|
+
throw new Check.DeveloperError(
|
210
|
+
"The total number of vertices (width * height) must be less than 4,294,967,296."
|
211
|
+
);
|
212
|
+
}
|
213
|
+
//>>includeEnd('debug');
|
214
|
+
|
215
|
+
let byWidth = regularGridAndSkirtAndEdgeIndicesCache[width];
|
216
|
+
if (!defaultValue.defined(byWidth)) {
|
217
|
+
regularGridAndSkirtAndEdgeIndicesCache[width] = byWidth = [];
|
218
|
+
}
|
219
|
+
|
220
|
+
let indicesAndEdges = byWidth[height];
|
221
|
+
if (!defaultValue.defined(indicesAndEdges)) {
|
222
|
+
const gridVertexCount = width * height;
|
223
|
+
const gridIndexCount = (width - 1) * (height - 1) * 6;
|
224
|
+
const edgeVertexCount = width * 2 + height * 2;
|
225
|
+
const edgeIndexCount = Math.max(0, edgeVertexCount - 4) * 6;
|
226
|
+
const vertexCount = gridVertexCount + edgeVertexCount;
|
227
|
+
const indexCount = gridIndexCount + edgeIndexCount;
|
228
|
+
|
229
|
+
const edgeIndices = getEdgeIndices(width, height);
|
230
|
+
const westIndicesSouthToNorth = edgeIndices.westIndicesSouthToNorth;
|
231
|
+
const southIndicesEastToWest = edgeIndices.southIndicesEastToWest;
|
232
|
+
const eastIndicesNorthToSouth = edgeIndices.eastIndicesNorthToSouth;
|
233
|
+
const northIndicesWestToEast = edgeIndices.northIndicesWestToEast;
|
234
|
+
|
235
|
+
const indices = IndexDatatype.IndexDatatype.createTypedArray(vertexCount, indexCount);
|
236
|
+
addRegularGridIndices(width, height, indices, 0);
|
237
|
+
TerrainProvider.addSkirtIndices(
|
238
|
+
westIndicesSouthToNorth,
|
239
|
+
southIndicesEastToWest,
|
240
|
+
eastIndicesNorthToSouth,
|
241
|
+
northIndicesWestToEast,
|
242
|
+
gridVertexCount,
|
243
|
+
indices,
|
244
|
+
gridIndexCount
|
245
|
+
);
|
246
|
+
|
247
|
+
indicesAndEdges = byWidth[height] = {
|
248
|
+
indices: indices,
|
249
|
+
westIndicesSouthToNorth: westIndicesSouthToNorth,
|
250
|
+
southIndicesEastToWest: southIndicesEastToWest,
|
251
|
+
eastIndicesNorthToSouth: eastIndicesNorthToSouth,
|
252
|
+
northIndicesWestToEast: northIndicesWestToEast,
|
253
|
+
indexCountWithoutSkirts: gridIndexCount,
|
254
|
+
};
|
255
|
+
}
|
256
|
+
|
257
|
+
return indicesAndEdges;
|
258
|
+
};
|
259
|
+
|
260
|
+
/**
|
261
|
+
* @private
|
262
|
+
*/
|
263
|
+
TerrainProvider.addSkirtIndices = function (
|
264
|
+
westIndicesSouthToNorth,
|
265
|
+
southIndicesEastToWest,
|
266
|
+
eastIndicesNorthToSouth,
|
267
|
+
northIndicesWestToEast,
|
268
|
+
vertexCount,
|
269
|
+
indices,
|
270
|
+
offset
|
271
|
+
) {
|
272
|
+
let vertexIndex = vertexCount;
|
273
|
+
offset = addSkirtIndices(
|
274
|
+
westIndicesSouthToNorth,
|
275
|
+
vertexIndex,
|
276
|
+
indices,
|
277
|
+
offset
|
278
|
+
);
|
279
|
+
vertexIndex += westIndicesSouthToNorth.length;
|
280
|
+
offset = addSkirtIndices(
|
281
|
+
southIndicesEastToWest,
|
282
|
+
vertexIndex,
|
283
|
+
indices,
|
284
|
+
offset
|
285
|
+
);
|
286
|
+
vertexIndex += southIndicesEastToWest.length;
|
287
|
+
offset = addSkirtIndices(
|
288
|
+
eastIndicesNorthToSouth,
|
289
|
+
vertexIndex,
|
290
|
+
indices,
|
291
|
+
offset
|
292
|
+
);
|
293
|
+
vertexIndex += eastIndicesNorthToSouth.length;
|
294
|
+
addSkirtIndices(northIndicesWestToEast, vertexIndex, indices, offset);
|
295
|
+
};
|
296
|
+
|
297
|
+
function getEdgeIndices(width, height) {
|
298
|
+
const westIndicesSouthToNorth = new Array(height);
|
299
|
+
const southIndicesEastToWest = new Array(width);
|
300
|
+
const eastIndicesNorthToSouth = new Array(height);
|
301
|
+
const northIndicesWestToEast = new Array(width);
|
302
|
+
|
303
|
+
let i;
|
304
|
+
for (i = 0; i < width; ++i) {
|
305
|
+
northIndicesWestToEast[i] = i;
|
306
|
+
southIndicesEastToWest[i] = width * height - 1 - i;
|
307
|
+
}
|
308
|
+
|
309
|
+
for (i = 0; i < height; ++i) {
|
310
|
+
eastIndicesNorthToSouth[i] = (i + 1) * width - 1;
|
311
|
+
westIndicesSouthToNorth[i] = (height - i - 1) * width;
|
312
|
+
}
|
313
|
+
|
314
|
+
return {
|
315
|
+
westIndicesSouthToNorth: westIndicesSouthToNorth,
|
316
|
+
southIndicesEastToWest: southIndicesEastToWest,
|
317
|
+
eastIndicesNorthToSouth: eastIndicesNorthToSouth,
|
318
|
+
northIndicesWestToEast: northIndicesWestToEast,
|
319
|
+
};
|
320
|
+
}
|
321
|
+
|
322
|
+
function addRegularGridIndices(width, height, indices, offset) {
|
323
|
+
let index = 0;
|
324
|
+
for (let j = 0; j < height - 1; ++j) {
|
325
|
+
for (let i = 0; i < width - 1; ++i) {
|
326
|
+
const upperLeft = index;
|
327
|
+
const lowerLeft = upperLeft + width;
|
328
|
+
const lowerRight = lowerLeft + 1;
|
329
|
+
const upperRight = upperLeft + 1;
|
330
|
+
|
331
|
+
indices[offset++] = upperLeft;
|
332
|
+
indices[offset++] = lowerLeft;
|
333
|
+
indices[offset++] = upperRight;
|
334
|
+
indices[offset++] = upperRight;
|
335
|
+
indices[offset++] = lowerLeft;
|
336
|
+
indices[offset++] = lowerRight;
|
337
|
+
|
338
|
+
++index;
|
339
|
+
}
|
340
|
+
++index;
|
341
|
+
}
|
342
|
+
}
|
343
|
+
|
344
|
+
function addSkirtIndices(edgeIndices, vertexIndex, indices, offset) {
|
345
|
+
let previousIndex = edgeIndices[0];
|
346
|
+
|
347
|
+
const length = edgeIndices.length;
|
348
|
+
for (let i = 1; i < length; ++i) {
|
349
|
+
const index = edgeIndices[i];
|
350
|
+
|
351
|
+
indices[offset++] = previousIndex;
|
352
|
+
indices[offset++] = index;
|
353
|
+
indices[offset++] = vertexIndex;
|
354
|
+
|
355
|
+
indices[offset++] = vertexIndex;
|
356
|
+
indices[offset++] = index;
|
357
|
+
indices[offset++] = vertexIndex + 1;
|
358
|
+
|
359
|
+
previousIndex = index;
|
360
|
+
++vertexIndex;
|
361
|
+
}
|
362
|
+
|
363
|
+
return offset;
|
364
|
+
}
|
365
|
+
|
366
|
+
/**
|
367
|
+
* Specifies the quality of terrain created from heightmaps. A value of 1.0 will
|
368
|
+
* ensure that adjacent heightmap vertices are separated by no more than
|
369
|
+
* {@link Globe.maximumScreenSpaceError} screen pixels and will probably go very slowly.
|
370
|
+
* A value of 0.5 will cut the estimated level zero geometric error in half, allowing twice the
|
371
|
+
* screen pixels between adjacent heightmap vertices and thus rendering more quickly.
|
372
|
+
* @type {Number}
|
373
|
+
*/
|
374
|
+
TerrainProvider.heightmapTerrainQuality = 0.25;
|
375
|
+
|
376
|
+
/**
|
377
|
+
* Determines an appropriate geometric error estimate when the geometry comes from a heightmap.
|
378
|
+
*
|
379
|
+
* @param {Ellipsoid} ellipsoid The ellipsoid to which the terrain is attached.
|
380
|
+
* @param {Number} tileImageWidth The width, in pixels, of the heightmap associated with a single tile.
|
381
|
+
* @param {Number} numberOfTilesAtLevelZero The number of tiles in the horizontal direction at tile level zero.
|
382
|
+
* @returns {Number} An estimated geometric error.
|
383
|
+
*/
|
384
|
+
TerrainProvider.getEstimatedLevelZeroGeometricErrorForAHeightmap = function (
|
385
|
+
ellipsoid,
|
386
|
+
tileImageWidth,
|
387
|
+
numberOfTilesAtLevelZero
|
388
|
+
) {
|
389
|
+
return (
|
390
|
+
(ellipsoid.maximumRadius *
|
391
|
+
2 *
|
392
|
+
Math.PI *
|
393
|
+
TerrainProvider.heightmapTerrainQuality) /
|
394
|
+
(tileImageWidth * numberOfTilesAtLevelZero)
|
395
|
+
);
|
396
|
+
};
|
397
|
+
|
398
|
+
/**
|
399
|
+
* Requests the geometry for a given tile. This function should not be called before
|
400
|
+
* {@link TerrainProvider#ready} returns true. The result must include terrain data and
|
401
|
+
* may optionally include a water mask and an indication of which child tiles are available.
|
402
|
+
* @function
|
403
|
+
*
|
404
|
+
* @param {Number} x The X coordinate of the tile for which to request geometry.
|
405
|
+
* @param {Number} y The Y coordinate of the tile for which to request geometry.
|
406
|
+
* @param {Number} level The level of the tile for which to request geometry.
|
407
|
+
* @param {Request} [request] The request object. Intended for internal use only.
|
408
|
+
*
|
409
|
+
* @returns {Promise.<TerrainData>|undefined} A promise for the requested geometry. If this method
|
410
|
+
* returns undefined instead of a promise, it is an indication that too many requests are already
|
411
|
+
* pending and the request will be retried later.
|
412
|
+
*/
|
413
|
+
TerrainProvider.prototype.requestTileGeometry =
|
414
|
+
Check.DeveloperError.throwInstantiationError;
|
415
|
+
|
416
|
+
/**
|
417
|
+
* Gets the maximum geometric error allowed in a tile at a given level. This function should not be
|
418
|
+
* called before {@link TerrainProvider#ready} returns true.
|
419
|
+
* @function
|
420
|
+
*
|
421
|
+
* @param {Number} level The tile level for which to get the maximum geometric error.
|
422
|
+
* @returns {Number} The maximum geometric error.
|
423
|
+
*/
|
424
|
+
TerrainProvider.prototype.getLevelMaximumGeometricError =
|
425
|
+
Check.DeveloperError.throwInstantiationError;
|
426
|
+
|
427
|
+
/**
|
428
|
+
* Determines whether data for a tile is available to be loaded.
|
429
|
+
* @function
|
430
|
+
*
|
431
|
+
* @param {Number} x The X coordinate of the tile for which to request geometry.
|
432
|
+
* @param {Number} y The Y coordinate of the tile for which to request geometry.
|
433
|
+
* @param {Number} level The level of the tile for which to request geometry.
|
434
|
+
* @returns {Boolean|undefined} Undefined if not supported by the terrain provider, otherwise true or false.
|
435
|
+
*/
|
436
|
+
TerrainProvider.prototype.getTileDataAvailable =
|
437
|
+
Check.DeveloperError.throwInstantiationError;
|
438
|
+
|
439
|
+
/**
|
440
|
+
* Makes sure we load availability data for a tile
|
441
|
+
* @function
|
442
|
+
*
|
443
|
+
* @param {Number} x The X coordinate of the tile for which to request geometry.
|
444
|
+
* @param {Number} y The Y coordinate of the tile for which to request geometry.
|
445
|
+
* @param {Number} level The level of the tile for which to request geometry.
|
446
|
+
* @returns {undefined|Promise<void>} Undefined if nothing need to be loaded or a Promise that resolves when all required tiles are loaded
|
447
|
+
*/
|
448
|
+
TerrainProvider.prototype.loadTileDataAvailability =
|
449
|
+
Check.DeveloperError.throwInstantiationError;
|
450
|
+
|
451
|
+
/**
|
452
|
+
* A function that is called when an error occurs.
|
453
|
+
* @callback TerrainProvider.ErrorEvent
|
454
|
+
*
|
455
|
+
* @this TerrainProvider
|
456
|
+
* @param {TileProviderError} err An object holding details about the error that occurred.
|
457
|
+
*/
|
458
|
+
|
459
|
+
const maxShort = 32767;
|
460
|
+
|
461
|
+
const cartesian3Scratch = new Matrix3.Cartesian3();
|
462
|
+
const scratchMinimum = new Matrix3.Cartesian3();
|
463
|
+
const scratchMaximum = new Matrix3.Cartesian3();
|
464
|
+
const cartographicScratch = new Matrix3.Cartographic();
|
465
|
+
const toPack = new Matrix2.Cartesian2();
|
466
|
+
|
467
|
+
function createVerticesFromQuantizedTerrainMesh(
|
468
|
+
parameters,
|
469
|
+
transferableObjects
|
470
|
+
) {
|
471
|
+
const quantizedVertices = parameters.quantizedVertices;
|
472
|
+
const quantizedVertexCount = quantizedVertices.length / 3;
|
473
|
+
const octEncodedNormals = parameters.octEncodedNormals;
|
474
|
+
const edgeVertexCount =
|
475
|
+
parameters.westIndices.length +
|
476
|
+
parameters.eastIndices.length +
|
477
|
+
parameters.southIndices.length +
|
478
|
+
parameters.northIndices.length;
|
479
|
+
const includeWebMercatorT = parameters.includeWebMercatorT;
|
480
|
+
|
481
|
+
const exaggeration = parameters.exaggeration;
|
482
|
+
const exaggerationRelativeHeight = parameters.exaggerationRelativeHeight;
|
483
|
+
const hasExaggeration = exaggeration !== 1.0;
|
484
|
+
const includeGeodeticSurfaceNormals = hasExaggeration;
|
485
|
+
|
486
|
+
const rectangle = Matrix2.Rectangle.clone(parameters.rectangle);
|
487
|
+
const west = rectangle.west;
|
488
|
+
const south = rectangle.south;
|
489
|
+
const east = rectangle.east;
|
490
|
+
const north = rectangle.north;
|
491
|
+
|
492
|
+
const ellipsoid = Matrix3.Ellipsoid.clone(parameters.ellipsoid);
|
493
|
+
|
494
|
+
const minimumHeight = parameters.minimumHeight;
|
495
|
+
const maximumHeight = parameters.maximumHeight;
|
496
|
+
|
497
|
+
const center = parameters.relativeToCenter;
|
498
|
+
const fromENU = Transforms.Transforms.eastNorthUpToFixedFrame(center, ellipsoid);
|
499
|
+
const toENU = Matrix2.Matrix4.inverseTransformation(fromENU, new Matrix2.Matrix4());
|
500
|
+
|
501
|
+
let southMercatorY;
|
502
|
+
let oneOverMercatorHeight;
|
503
|
+
if (includeWebMercatorT) {
|
504
|
+
southMercatorY = WebMercatorProjection.WebMercatorProjection.geodeticLatitudeToMercatorAngle(
|
505
|
+
south
|
506
|
+
);
|
507
|
+
oneOverMercatorHeight =
|
508
|
+
1.0 /
|
509
|
+
(WebMercatorProjection.WebMercatorProjection.geodeticLatitudeToMercatorAngle(north) -
|
510
|
+
southMercatorY);
|
511
|
+
}
|
512
|
+
|
513
|
+
const uBuffer = quantizedVertices.subarray(0, quantizedVertexCount);
|
514
|
+
const vBuffer = quantizedVertices.subarray(
|
515
|
+
quantizedVertexCount,
|
516
|
+
2 * quantizedVertexCount
|
517
|
+
);
|
518
|
+
const heightBuffer = quantizedVertices.subarray(
|
519
|
+
quantizedVertexCount * 2,
|
520
|
+
3 * quantizedVertexCount
|
521
|
+
);
|
522
|
+
const hasVertexNormals = defaultValue.defined(octEncodedNormals);
|
523
|
+
|
524
|
+
const uvs = new Array(quantizedVertexCount);
|
525
|
+
const heights = new Array(quantizedVertexCount);
|
526
|
+
const positions = new Array(quantizedVertexCount);
|
527
|
+
const webMercatorTs = includeWebMercatorT
|
528
|
+
? new Array(quantizedVertexCount)
|
529
|
+
: [];
|
530
|
+
const geodeticSurfaceNormals = includeGeodeticSurfaceNormals
|
531
|
+
? new Array(quantizedVertexCount)
|
532
|
+
: [];
|
533
|
+
|
534
|
+
const minimum = scratchMinimum;
|
535
|
+
minimum.x = Number.POSITIVE_INFINITY;
|
536
|
+
minimum.y = Number.POSITIVE_INFINITY;
|
537
|
+
minimum.z = Number.POSITIVE_INFINITY;
|
538
|
+
|
539
|
+
const maximum = scratchMaximum;
|
540
|
+
maximum.x = Number.NEGATIVE_INFINITY;
|
541
|
+
maximum.y = Number.NEGATIVE_INFINITY;
|
542
|
+
maximum.z = Number.NEGATIVE_INFINITY;
|
543
|
+
|
544
|
+
let minLongitude = Number.POSITIVE_INFINITY;
|
545
|
+
let maxLongitude = Number.NEGATIVE_INFINITY;
|
546
|
+
let minLatitude = Number.POSITIVE_INFINITY;
|
547
|
+
let maxLatitude = Number.NEGATIVE_INFINITY;
|
548
|
+
|
549
|
+
for (let i = 0; i < quantizedVertexCount; ++i) {
|
550
|
+
const rawU = uBuffer[i];
|
551
|
+
const rawV = vBuffer[i];
|
552
|
+
|
553
|
+
const u = rawU / maxShort;
|
554
|
+
const v = rawV / maxShort;
|
555
|
+
const height = Math$1.CesiumMath.lerp(
|
556
|
+
minimumHeight,
|
557
|
+
maximumHeight,
|
558
|
+
heightBuffer[i] / maxShort
|
559
|
+
);
|
560
|
+
|
561
|
+
cartographicScratch.longitude = Math$1.CesiumMath.lerp(west, east, u);
|
562
|
+
cartographicScratch.latitude = Math$1.CesiumMath.lerp(south, north, v);
|
563
|
+
cartographicScratch.height = height;
|
564
|
+
|
565
|
+
minLongitude = Math.min(cartographicScratch.longitude, minLongitude);
|
566
|
+
maxLongitude = Math.max(cartographicScratch.longitude, maxLongitude);
|
567
|
+
minLatitude = Math.min(cartographicScratch.latitude, minLatitude);
|
568
|
+
maxLatitude = Math.max(cartographicScratch.latitude, maxLatitude);
|
569
|
+
|
570
|
+
const position = ellipsoid.cartographicToCartesian(cartographicScratch);
|
571
|
+
|
572
|
+
uvs[i] = new Matrix2.Cartesian2(u, v);
|
573
|
+
heights[i] = height;
|
574
|
+
positions[i] = position;
|
575
|
+
|
576
|
+
if (includeWebMercatorT) {
|
577
|
+
webMercatorTs[i] =
|
578
|
+
(WebMercatorProjection.WebMercatorProjection.geodeticLatitudeToMercatorAngle(
|
579
|
+
cartographicScratch.latitude
|
580
|
+
) -
|
581
|
+
southMercatorY) *
|
582
|
+
oneOverMercatorHeight;
|
583
|
+
}
|
584
|
+
|
585
|
+
if (includeGeodeticSurfaceNormals) {
|
586
|
+
geodeticSurfaceNormals[i] = ellipsoid.geodeticSurfaceNormal(position);
|
587
|
+
}
|
588
|
+
|
589
|
+
Matrix2.Matrix4.multiplyByPoint(toENU, position, cartesian3Scratch);
|
590
|
+
|
591
|
+
Matrix3.Cartesian3.minimumByComponent(cartesian3Scratch, minimum, minimum);
|
592
|
+
Matrix3.Cartesian3.maximumByComponent(cartesian3Scratch, maximum, maximum);
|
593
|
+
}
|
594
|
+
|
595
|
+
const westIndicesSouthToNorth = copyAndSort(parameters.westIndices, function (
|
596
|
+
a,
|
597
|
+
b
|
598
|
+
) {
|
599
|
+
return uvs[a].y - uvs[b].y;
|
600
|
+
});
|
601
|
+
const eastIndicesNorthToSouth = copyAndSort(parameters.eastIndices, function (
|
602
|
+
a,
|
603
|
+
b
|
604
|
+
) {
|
605
|
+
return uvs[b].y - uvs[a].y;
|
606
|
+
});
|
607
|
+
const southIndicesEastToWest = copyAndSort(parameters.southIndices, function (
|
608
|
+
a,
|
609
|
+
b
|
610
|
+
) {
|
611
|
+
return uvs[b].x - uvs[a].x;
|
612
|
+
});
|
613
|
+
const northIndicesWestToEast = copyAndSort(parameters.northIndices, function (
|
614
|
+
a,
|
615
|
+
b
|
616
|
+
) {
|
617
|
+
return uvs[a].x - uvs[b].x;
|
618
|
+
});
|
619
|
+
|
620
|
+
let occludeePointInScaledSpace;
|
621
|
+
if (minimumHeight < 0.0) {
|
622
|
+
// Horizon culling point needs to be recomputed since the tile is at least partly under the ellipsoid.
|
623
|
+
const occluder = new TerrainEncoding.EllipsoidalOccluder(ellipsoid);
|
624
|
+
occludeePointInScaledSpace = occluder.computeHorizonCullingPointPossiblyUnderEllipsoid(
|
625
|
+
center,
|
626
|
+
positions,
|
627
|
+
minimumHeight
|
628
|
+
);
|
629
|
+
}
|
630
|
+
|
631
|
+
let hMin = minimumHeight;
|
632
|
+
hMin = Math.min(
|
633
|
+
hMin,
|
634
|
+
findMinMaxSkirts(
|
635
|
+
parameters.westIndices,
|
636
|
+
parameters.westSkirtHeight,
|
637
|
+
heights,
|
638
|
+
uvs,
|
639
|
+
rectangle,
|
640
|
+
ellipsoid,
|
641
|
+
toENU,
|
642
|
+
minimum,
|
643
|
+
maximum
|
644
|
+
)
|
645
|
+
);
|
646
|
+
hMin = Math.min(
|
647
|
+
hMin,
|
648
|
+
findMinMaxSkirts(
|
649
|
+
parameters.southIndices,
|
650
|
+
parameters.southSkirtHeight,
|
651
|
+
heights,
|
652
|
+
uvs,
|
653
|
+
rectangle,
|
654
|
+
ellipsoid,
|
655
|
+
toENU,
|
656
|
+
minimum,
|
657
|
+
maximum
|
658
|
+
)
|
659
|
+
);
|
660
|
+
hMin = Math.min(
|
661
|
+
hMin,
|
662
|
+
findMinMaxSkirts(
|
663
|
+
parameters.eastIndices,
|
664
|
+
parameters.eastSkirtHeight,
|
665
|
+
heights,
|
666
|
+
uvs,
|
667
|
+
rectangle,
|
668
|
+
ellipsoid,
|
669
|
+
toENU,
|
670
|
+
minimum,
|
671
|
+
maximum
|
672
|
+
)
|
673
|
+
);
|
674
|
+
hMin = Math.min(
|
675
|
+
hMin,
|
676
|
+
findMinMaxSkirts(
|
677
|
+
parameters.northIndices,
|
678
|
+
parameters.northSkirtHeight,
|
679
|
+
heights,
|
680
|
+
uvs,
|
681
|
+
rectangle,
|
682
|
+
ellipsoid,
|
683
|
+
toENU,
|
684
|
+
minimum,
|
685
|
+
maximum
|
686
|
+
)
|
687
|
+
);
|
688
|
+
|
689
|
+
const aaBox = new AxisAlignedBoundingBox.AxisAlignedBoundingBox(minimum, maximum, center);
|
690
|
+
const encoding = new TerrainEncoding.TerrainEncoding(
|
691
|
+
center,
|
692
|
+
aaBox,
|
693
|
+
hMin,
|
694
|
+
maximumHeight,
|
695
|
+
fromENU,
|
696
|
+
hasVertexNormals,
|
697
|
+
includeWebMercatorT,
|
698
|
+
includeGeodeticSurfaceNormals,
|
699
|
+
exaggeration,
|
700
|
+
exaggerationRelativeHeight
|
701
|
+
);
|
702
|
+
const vertexStride = encoding.stride;
|
703
|
+
const size =
|
704
|
+
quantizedVertexCount * vertexStride + edgeVertexCount * vertexStride;
|
705
|
+
const vertexBuffer = new Float32Array(size);
|
706
|
+
|
707
|
+
let bufferIndex = 0;
|
708
|
+
for (let j = 0; j < quantizedVertexCount; ++j) {
|
709
|
+
if (hasVertexNormals) {
|
710
|
+
const n = j * 2.0;
|
711
|
+
toPack.x = octEncodedNormals[n];
|
712
|
+
toPack.y = octEncodedNormals[n + 1];
|
713
|
+
}
|
714
|
+
|
715
|
+
bufferIndex = encoding.encode(
|
716
|
+
vertexBuffer,
|
717
|
+
bufferIndex,
|
718
|
+
positions[j],
|
719
|
+
uvs[j],
|
720
|
+
heights[j],
|
721
|
+
toPack,
|
722
|
+
webMercatorTs[j],
|
723
|
+
geodeticSurfaceNormals[j]
|
724
|
+
);
|
725
|
+
}
|
726
|
+
|
727
|
+
const edgeTriangleCount = Math.max(0, (edgeVertexCount - 4) * 2);
|
728
|
+
const indexBufferLength = parameters.indices.length + edgeTriangleCount * 3;
|
729
|
+
const indexBuffer = IndexDatatype.IndexDatatype.createTypedArray(
|
730
|
+
quantizedVertexCount + edgeVertexCount,
|
731
|
+
indexBufferLength
|
732
|
+
);
|
733
|
+
indexBuffer.set(parameters.indices, 0);
|
734
|
+
|
735
|
+
const percentage = 0.0001;
|
736
|
+
const lonOffset = (maxLongitude - minLongitude) * percentage;
|
737
|
+
const latOffset = (maxLatitude - minLatitude) * percentage;
|
738
|
+
const westLongitudeOffset = -lonOffset;
|
739
|
+
const westLatitudeOffset = 0.0;
|
740
|
+
const eastLongitudeOffset = lonOffset;
|
741
|
+
const eastLatitudeOffset = 0.0;
|
742
|
+
const northLongitudeOffset = 0.0;
|
743
|
+
const northLatitudeOffset = latOffset;
|
744
|
+
const southLongitudeOffset = 0.0;
|
745
|
+
const southLatitudeOffset = -latOffset;
|
746
|
+
|
747
|
+
// Add skirts.
|
748
|
+
let vertexBufferIndex = quantizedVertexCount * vertexStride;
|
749
|
+
addSkirt(
|
750
|
+
vertexBuffer,
|
751
|
+
vertexBufferIndex,
|
752
|
+
westIndicesSouthToNorth,
|
753
|
+
encoding,
|
754
|
+
heights,
|
755
|
+
uvs,
|
756
|
+
octEncodedNormals,
|
757
|
+
ellipsoid,
|
758
|
+
rectangle,
|
759
|
+
parameters.westSkirtHeight,
|
760
|
+
southMercatorY,
|
761
|
+
oneOverMercatorHeight,
|
762
|
+
westLongitudeOffset,
|
763
|
+
westLatitudeOffset
|
764
|
+
);
|
765
|
+
vertexBufferIndex += parameters.westIndices.length * vertexStride;
|
766
|
+
addSkirt(
|
767
|
+
vertexBuffer,
|
768
|
+
vertexBufferIndex,
|
769
|
+
southIndicesEastToWest,
|
770
|
+
encoding,
|
771
|
+
heights,
|
772
|
+
uvs,
|
773
|
+
octEncodedNormals,
|
774
|
+
ellipsoid,
|
775
|
+
rectangle,
|
776
|
+
parameters.southSkirtHeight,
|
777
|
+
southMercatorY,
|
778
|
+
oneOverMercatorHeight,
|
779
|
+
southLongitudeOffset,
|
780
|
+
southLatitudeOffset
|
781
|
+
);
|
782
|
+
vertexBufferIndex += parameters.southIndices.length * vertexStride;
|
783
|
+
addSkirt(
|
784
|
+
vertexBuffer,
|
785
|
+
vertexBufferIndex,
|
786
|
+
eastIndicesNorthToSouth,
|
787
|
+
encoding,
|
788
|
+
heights,
|
789
|
+
uvs,
|
790
|
+
octEncodedNormals,
|
791
|
+
ellipsoid,
|
792
|
+
rectangle,
|
793
|
+
parameters.eastSkirtHeight,
|
794
|
+
southMercatorY,
|
795
|
+
oneOverMercatorHeight,
|
796
|
+
eastLongitudeOffset,
|
797
|
+
eastLatitudeOffset
|
798
|
+
);
|
799
|
+
vertexBufferIndex += parameters.eastIndices.length * vertexStride;
|
800
|
+
addSkirt(
|
801
|
+
vertexBuffer,
|
802
|
+
vertexBufferIndex,
|
803
|
+
northIndicesWestToEast,
|
804
|
+
encoding,
|
805
|
+
heights,
|
806
|
+
uvs,
|
807
|
+
octEncodedNormals,
|
808
|
+
ellipsoid,
|
809
|
+
rectangle,
|
810
|
+
parameters.northSkirtHeight,
|
811
|
+
southMercatorY,
|
812
|
+
oneOverMercatorHeight,
|
813
|
+
northLongitudeOffset,
|
814
|
+
northLatitudeOffset
|
815
|
+
);
|
816
|
+
|
817
|
+
TerrainProvider.addSkirtIndices(
|
818
|
+
westIndicesSouthToNorth,
|
819
|
+
southIndicesEastToWest,
|
820
|
+
eastIndicesNorthToSouth,
|
821
|
+
northIndicesWestToEast,
|
822
|
+
quantizedVertexCount,
|
823
|
+
indexBuffer,
|
824
|
+
parameters.indices.length
|
825
|
+
);
|
826
|
+
|
827
|
+
transferableObjects.push(vertexBuffer.buffer, indexBuffer.buffer);
|
828
|
+
|
829
|
+
return {
|
830
|
+
vertices: vertexBuffer.buffer,
|
831
|
+
indices: indexBuffer.buffer,
|
832
|
+
westIndicesSouthToNorth: westIndicesSouthToNorth,
|
833
|
+
southIndicesEastToWest: southIndicesEastToWest,
|
834
|
+
eastIndicesNorthToSouth: eastIndicesNorthToSouth,
|
835
|
+
northIndicesWestToEast: northIndicesWestToEast,
|
836
|
+
vertexStride: vertexStride,
|
837
|
+
center: center,
|
838
|
+
minimumHeight: minimumHeight,
|
839
|
+
maximumHeight: maximumHeight,
|
840
|
+
occludeePointInScaledSpace: occludeePointInScaledSpace,
|
841
|
+
encoding: encoding,
|
842
|
+
indexCountWithoutSkirts: parameters.indices.length,
|
843
|
+
};
|
844
|
+
}
|
845
|
+
|
846
|
+
function findMinMaxSkirts(
|
847
|
+
edgeIndices,
|
848
|
+
edgeHeight,
|
849
|
+
heights,
|
850
|
+
uvs,
|
851
|
+
rectangle,
|
852
|
+
ellipsoid,
|
853
|
+
toENU,
|
854
|
+
minimum,
|
855
|
+
maximum
|
856
|
+
) {
|
857
|
+
let hMin = Number.POSITIVE_INFINITY;
|
858
|
+
|
859
|
+
const north = rectangle.north;
|
860
|
+
const south = rectangle.south;
|
861
|
+
let east = rectangle.east;
|
862
|
+
const west = rectangle.west;
|
863
|
+
|
864
|
+
if (east < west) {
|
865
|
+
east += Math$1.CesiumMath.TWO_PI;
|
866
|
+
}
|
867
|
+
|
868
|
+
const length = edgeIndices.length;
|
869
|
+
for (let i = 0; i < length; ++i) {
|
870
|
+
const index = edgeIndices[i];
|
871
|
+
const h = heights[index];
|
872
|
+
const uv = uvs[index];
|
873
|
+
|
874
|
+
cartographicScratch.longitude = Math$1.CesiumMath.lerp(west, east, uv.x);
|
875
|
+
cartographicScratch.latitude = Math$1.CesiumMath.lerp(south, north, uv.y);
|
876
|
+
cartographicScratch.height = h - edgeHeight;
|
877
|
+
|
878
|
+
const position = ellipsoid.cartographicToCartesian(
|
879
|
+
cartographicScratch,
|
880
|
+
cartesian3Scratch
|
881
|
+
);
|
882
|
+
Matrix2.Matrix4.multiplyByPoint(toENU, position, position);
|
883
|
+
|
884
|
+
Matrix3.Cartesian3.minimumByComponent(position, minimum, minimum);
|
885
|
+
Matrix3.Cartesian3.maximumByComponent(position, maximum, maximum);
|
886
|
+
|
887
|
+
hMin = Math.min(hMin, cartographicScratch.height);
|
888
|
+
}
|
889
|
+
return hMin;
|
890
|
+
}
|
891
|
+
|
892
|
+
function addSkirt(
|
893
|
+
vertexBuffer,
|
894
|
+
vertexBufferIndex,
|
895
|
+
edgeVertices,
|
896
|
+
encoding,
|
897
|
+
heights,
|
898
|
+
uvs,
|
899
|
+
octEncodedNormals,
|
900
|
+
ellipsoid,
|
901
|
+
rectangle,
|
902
|
+
skirtLength,
|
903
|
+
southMercatorY,
|
904
|
+
oneOverMercatorHeight,
|
905
|
+
longitudeOffset,
|
906
|
+
latitudeOffset
|
907
|
+
) {
|
908
|
+
const hasVertexNormals = defaultValue.defined(octEncodedNormals);
|
909
|
+
|
910
|
+
const north = rectangle.north;
|
911
|
+
const south = rectangle.south;
|
912
|
+
let east = rectangle.east;
|
913
|
+
const west = rectangle.west;
|
914
|
+
|
915
|
+
if (east < west) {
|
916
|
+
east += Math$1.CesiumMath.TWO_PI;
|
917
|
+
}
|
918
|
+
|
919
|
+
const length = edgeVertices.length;
|
920
|
+
for (let i = 0; i < length; ++i) {
|
921
|
+
const index = edgeVertices[i];
|
922
|
+
const h = heights[index];
|
923
|
+
const uv = uvs[index];
|
924
|
+
|
925
|
+
cartographicScratch.longitude =
|
926
|
+
Math$1.CesiumMath.lerp(west, east, uv.x) + longitudeOffset;
|
927
|
+
cartographicScratch.latitude =
|
928
|
+
Math$1.CesiumMath.lerp(south, north, uv.y) + latitudeOffset;
|
929
|
+
cartographicScratch.height = h - skirtLength;
|
930
|
+
|
931
|
+
const position = ellipsoid.cartographicToCartesian(
|
932
|
+
cartographicScratch,
|
933
|
+
cartesian3Scratch
|
934
|
+
);
|
935
|
+
|
936
|
+
if (hasVertexNormals) {
|
937
|
+
const n = index * 2.0;
|
938
|
+
toPack.x = octEncodedNormals[n];
|
939
|
+
toPack.y = octEncodedNormals[n + 1];
|
940
|
+
}
|
941
|
+
|
942
|
+
let webMercatorT;
|
943
|
+
if (encoding.hasWebMercatorT) {
|
944
|
+
webMercatorT =
|
945
|
+
(WebMercatorProjection.WebMercatorProjection.geodeticLatitudeToMercatorAngle(
|
946
|
+
cartographicScratch.latitude
|
947
|
+
) -
|
948
|
+
southMercatorY) *
|
949
|
+
oneOverMercatorHeight;
|
950
|
+
}
|
951
|
+
|
952
|
+
let geodeticSurfaceNormal;
|
953
|
+
if (encoding.hasGeodeticSurfaceNormals) {
|
954
|
+
geodeticSurfaceNormal = ellipsoid.geodeticSurfaceNormal(position);
|
955
|
+
}
|
956
|
+
|
957
|
+
vertexBufferIndex = encoding.encode(
|
958
|
+
vertexBuffer,
|
959
|
+
vertexBufferIndex,
|
960
|
+
position,
|
961
|
+
uv,
|
962
|
+
cartographicScratch.height,
|
963
|
+
toPack,
|
964
|
+
webMercatorT,
|
965
|
+
geodeticSurfaceNormal
|
966
|
+
);
|
967
|
+
}
|
968
|
+
}
|
969
|
+
|
970
|
+
function copyAndSort(typedArray, comparator) {
|
971
|
+
let copy;
|
972
|
+
if (typeof typedArray.slice === "function") {
|
973
|
+
copy = typedArray.slice();
|
974
|
+
if (typeof copy.sort !== "function") {
|
975
|
+
// Sliced typed array isn't sortable, so we can't use it.
|
976
|
+
copy = undefined;
|
977
|
+
}
|
978
|
+
}
|
979
|
+
|
980
|
+
if (!defaultValue.defined(copy)) {
|
981
|
+
copy = Array.prototype.slice.call(typedArray);
|
982
|
+
}
|
983
|
+
|
984
|
+
copy.sort(comparator);
|
985
|
+
|
986
|
+
return copy;
|
987
|
+
}
|
988
|
+
var createVerticesFromQuantizedTerrainMesh$1 = createTaskProcessorWorker(
|
989
|
+
createVerticesFromQuantizedTerrainMesh
|
990
|
+
);
|
991
|
+
|
992
|
+
return createVerticesFromQuantizedTerrainMesh$1;
|
993
|
+
|
994
|
+
}));
|