@arcgis/core 5.0.0-next.62 → 5.0.0-next.64
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/Ground.d.ts +2 -1
- package/Ground.js +1 -1
- package/WebDocument2D.js +1 -1
- package/WebLinkChart.js +1 -1
- package/WebMap.d.ts +1 -1
- package/WebMap.js +1 -1
- package/WebScene.d.ts +1 -1
- package/WebScene.js +1 -1
- package/applications/KnowledgeStudio/dataModelVisualization.d.ts +18 -0
- package/applications/KnowledgeStudio/dataModelVisualization.js +5 -0
- package/applications/MapViewer/templateUtils.d.ts +2 -2
- package/applications/Urban/LineImagePattern3D.d.ts +8 -0
- package/applications/Urban/LineImagePattern3D.js +5 -0
- package/applications/Urban/imagePatternUtils.d.ts +23 -0
- package/applications/Urban/imagePatternUtils.js +5 -0
- package/assets/esri/core/libs/libtess/libtess-f32.wasm +0 -0
- package/assets/esri/core/libs/libtess/libtess-f64.wasm +0 -0
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/{61707c22b029c2a7a397.js → 049c125085028ffdd0dd.js} +1 -1
- package/assets/esri/core/workers/chunks/{0bd73a66baea2f52e8a6.js → 07639f406b71bb49ffd6.js} +1 -1
- package/assets/esri/core/workers/chunks/{df0e5570174bf0942d7a.js → 0d9e1ccc3ba8b5ed3287.js} +1 -1
- package/assets/esri/core/workers/chunks/{4404b6f931f681cca342.js → 0e5cd0cf6ab7cb37d723.js} +1 -1
- package/assets/esri/core/workers/chunks/{a624dd283d264dce35a8.js → 0f5693541111fcae0c2f.js} +1 -1
- package/assets/esri/core/workers/chunks/{f56906c443ce8ff68a27.js → 13d61d34e55c80e4ecdf.js} +1 -1
- package/assets/esri/core/workers/chunks/{28b235b56a83c498d73f.js → 168ec8fca2702617a543.js} +1 -1
- package/assets/esri/core/workers/chunks/{831b8282380844a7c4d5.js → 1967239713b58dccfd81.js} +1 -1
- package/assets/esri/core/workers/chunks/1b838638e66e82d76cf3.js +1 -0
- package/assets/esri/core/workers/chunks/{2209550b6510e25da375.js → 226acd251ad7d7ee3b57.js} +1 -1
- package/assets/esri/core/workers/chunks/22dd5cecc7e2d4d0baf8.js +316 -0
- package/assets/esri/core/workers/chunks/2402d305a77fef4694a0.js +1 -0
- package/assets/esri/core/workers/chunks/{893a5ab0c2df9262efd8.js → 251eb6e00f99a816d55c.js} +1 -1
- package/assets/esri/core/workers/chunks/{e47535f795b15608a6cb.js → 27f096c434f049b8df01.js} +1 -1
- package/assets/esri/core/workers/chunks/29b09db309ff75fb3e97.js +1 -0
- package/assets/esri/core/workers/chunks/{bef2a70d382515b3c84e.js → 310f3268582e61cd86da.js} +1 -1
- package/assets/esri/core/workers/chunks/{02cf735176f286a48dd2.js → 3371935a4fd6346d3a17.js} +1 -1
- package/assets/esri/core/workers/chunks/{36d15c35fbbd4dedd5cb.js → 3c3d311b88f5400951ef.js} +1 -1
- package/assets/esri/core/workers/chunks/{cf3a9ead26629f3508b3.js → 3c4f8597f602779174f1.js} +1 -1
- package/assets/esri/core/workers/chunks/43d28c6509c21b8917a8.js +1 -0
- package/assets/esri/core/workers/chunks/{951e3c911a3486b1e609.js → 45b898367b6224dda46f.js} +1 -1
- package/assets/esri/core/workers/chunks/{57302b92e9899cce4ba3.js → 4785cd108e2dec6e1697.js} +1 -1
- package/assets/esri/core/workers/chunks/{153ff2ceefccd946498b.js → 47bfe8dd5d2bac4307ac.js} +1 -1
- package/assets/esri/core/workers/chunks/{2abc205f81f26fc4852b.js → 49a1b7f700b8a42de817.js} +4 -4
- package/assets/esri/core/workers/chunks/4d6d962d25aa836f53ee.js +1 -0
- package/assets/esri/core/workers/chunks/{454c15367cccbf63af7a.js → 4e9a8fce55cad841c731.js} +1 -1
- package/assets/esri/core/workers/chunks/{b93f2bd6429879f92143.js → 536c492fdda30f2f1288.js} +1 -1
- package/assets/esri/core/workers/chunks/5cee6c3ff23fb93f857a.js +1 -0
- package/assets/esri/core/workers/chunks/6035daa65fc3ebf86515.js +1 -0
- package/assets/esri/core/workers/chunks/62b28f73f814413c10fc.js +1 -0
- package/assets/esri/core/workers/chunks/{0bc01d71ed1ab8c3af3c.js → 6599cc702a46f81a5634.js} +1 -1
- package/assets/esri/core/workers/chunks/6925f09d44cc38480d53.js +1 -0
- package/assets/esri/core/workers/chunks/{72e3a48aa365542b0689.js → 6a782e8475bff4d56dbc.js} +1 -1
- package/assets/esri/core/workers/chunks/6ba3c2b9f699d94d62b8.js +1 -0
- package/assets/esri/core/workers/chunks/{f44f358db5c56d5bbc0c.js → 7306b5b66e738a281d83.js} +1 -1
- package/assets/esri/core/workers/chunks/{2da13c2269ab90281143.js → 7694abe44d55dae8872d.js} +1 -1
- package/assets/esri/core/workers/chunks/{2b34a010f76e5f289868.js → 7bf491b468cd74a4166c.js} +1 -1
- package/assets/esri/core/workers/chunks/{05ab54b81c366e98138f.js → 7d8664aeff66e34138bd.js} +1 -1
- package/assets/esri/core/workers/chunks/822ef6a043c7e147b4b6.js +1 -0
- package/assets/esri/core/workers/chunks/878010ca23da0bca9405.js +1 -0
- package/assets/esri/core/workers/chunks/892157696e8f9e38c472.js +1 -0
- package/assets/esri/core/workers/chunks/{d2abfcb0c8bf894c7f72.js → 8dca61f8ba6689379f86.js} +1 -1
- package/assets/esri/core/workers/chunks/{bce81df760f5e34c01d7.js → 964de713042f52d71e42.js} +1 -1
- package/assets/esri/core/workers/chunks/990341f7c47bd656c782.js +1 -0
- package/assets/esri/core/workers/chunks/9d6945cda99d14af83ac.js +1 -0
- package/assets/esri/core/workers/chunks/{5180b15f1a865756a02e.js → a3836f6a93924ee4816e.js} +1 -1
- package/assets/esri/core/workers/chunks/{d13b2ce8a89938b0472b.js → a6dcd13c792b6538ac50.js} +1 -1
- package/assets/esri/core/workers/chunks/{522a6787d9e0f520ac79.js → a893f8db2477cf677ac8.js} +1 -1
- package/assets/esri/core/workers/chunks/{983356eb4fd0a0dcf3fd.js → abc236e99b52be1c83b9.js} +1 -1
- package/assets/esri/core/workers/chunks/{b11c0e80e583f2b7c5de.js → ac83c2999a3d2ffb4356.js} +1 -1
- package/assets/esri/core/workers/chunks/{5873c7b65d0fb04998fb.js → acea42d268b53ceb2bfd.js} +1 -1
- package/assets/esri/core/workers/chunks/{8628bf45a33af786cd49.js → b65fcfde62d49de1fa54.js} +1 -1
- package/assets/esri/core/workers/chunks/ba7f57788847cc0f68df.js +1 -0
- package/assets/esri/core/workers/chunks/{12f700b932a241e59071.js → bcf612eabe7577540953.js} +1 -1
- package/assets/esri/core/workers/chunks/{75e9759290f0f67b2128.js → bf06250be7a7a36306b1.js} +1 -1
- package/assets/esri/core/workers/chunks/c3007b916ba933137709.js +1 -0
- package/assets/esri/core/workers/chunks/c9f868f85d740ee32715.js +1 -0
- package/assets/esri/core/workers/chunks/cc5c1887e6d7079e5fe3.js +1 -0
- package/assets/esri/core/workers/chunks/ce8f075c814a8378c00c.js +1 -0
- package/assets/esri/core/workers/chunks/{f91e63d7842c427c7f72.js → d30cfc5fa302cc08d862.js} +1 -1
- package/assets/esri/core/workers/chunks/d3325ed8d224e2350db7.js +1 -0
- package/assets/esri/core/workers/chunks/{1800994523d7cdfb73af.js → de71db3b0fb947b13c97.js} +1 -1
- package/assets/esri/core/workers/chunks/{ff7df6fb78fa2c0e9247.js → df92239eefff04471a0b.js} +1 -1
- package/assets/esri/core/workers/chunks/e69255e38ff200dda14b.js +1 -0
- package/assets/esri/core/workers/chunks/ee2ca25048a920e43743.js +1 -0
- package/assets/esri/core/workers/chunks/{609919428305d8c8c243.js → f9370830051865a3435b.js} +1 -1
- package/assets/esri/core/workers/chunks/fc00d7278b43df813c54.js +1 -0
- package/assets/esri/themes/base/widgets/_UtilityNetworkAssociations.scss +7 -18
- package/assets/esri/themes/dark/main.css +1 -1
- package/assets/esri/themes/light/main.css +1 -1
- package/assets/esri/themes/light/view.css +1 -1
- package/chunks/RibbonLine.glsl.js +99 -61
- package/chunks/libtess-f32.js +5 -0
- package/chunks/libtess-f64.js +5 -0
- package/config.js +1 -1
- package/core/Version.d.ts +1 -1
- package/core/Version.js +1 -1
- package/core/has.js +1 -1
- package/core/workers/registry.js +1 -1
- package/core/workers/workerFactory.js +1 -1
- package/form/elements/inputs/SwitchInput.d.ts +2 -1
- package/geometry/Mesh.d.ts +2 -1
- package/geometry/Mesh.js +1 -1
- package/geometry/libtess.js +1 -1
- package/geometry/support/MeshVertexAttributes.d.ts +1 -1
- package/geometry/support/MeshVertexAttributes.js +1 -1
- package/geometry/support/meshUtils/convertMeshVertexSpace.js +1 -1
- package/geometry/support/meshUtils/elevation.js +1 -1
- package/geometry/support/meshUtils/loadGLTFMesh.js +1 -1
- package/geometry/support/meshUtils/merge.js +1 -1
- package/geometry/support/meshUtils/primitives.js +1 -1
- package/ground/NavigationConstraint.d.ts +1 -1
- package/ground/NavigationConstraint.js +1 -1
- package/interfaces.d.ts +163 -158
- package/kernel.js +1 -1
- package/layers/BaseElevationLayer.d.ts +1 -1
- package/layers/ElevationLayer.d.ts +1 -1
- package/layers/ElevationLayer.js +1 -1
- package/layers/FeatureLayer.d.ts +1 -5
- package/layers/Layer.d.ts +1 -2
- package/layers/ParquetLayer.js +1 -1
- package/layers/SceneLayer.js +1 -1
- package/layers/knowledgeGraph/dataModelVisualizationUtils.d.ts +11 -0
- package/layers/knowledgeGraph/dataModelVisualizationUtils.js +5 -0
- package/layers/mixins/ArcGISMapService.js +1 -1
- package/layers/mixins/BlendLayer.d.ts +1 -1
- package/layers/orientedImagery/core/coverageUtils.js +1 -1
- package/layers/orientedImagery/transformations/updateElevationUtils.js +1 -1
- package/layers/raster/formats/RasterCodec.js +1 -1
- package/layers/raster/functions/ColormapToRGBFunction.js +1 -1
- package/layers/raster/functions/surfaceUtils.js +1 -1
- package/layers/support/CodedValue.d.ts +1 -1
- package/layers/support/CodedValue.js +1 -1
- package/layers/support/CodedValueDomain.d.ts +2 -1
- package/layers/support/CodedValueDomain.js +1 -1
- package/layers/support/ElevationTileData.d.ts +1 -1
- package/layers/support/ElevationTileData.js +1 -1
- package/layers/support/FeatureReduction.d.ts +1 -1
- package/layers/support/FeatureReduction.js +1 -1
- package/layers/support/FeatureReductionBinning.d.ts +1 -1
- package/layers/support/FeatureReductionBinning.js +1 -1
- package/layers/support/FeatureReductionSelection.d.ts +1 -1
- package/layers/support/FeatureReductionSelection.js +1 -1
- package/layers/support/KMLMapImage.d.ts +1 -1
- package/layers/support/KMLMapImage.js +1 -1
- package/layers/support/ParquetGeometryEncodingBase.d.ts +1 -1
- package/layers/support/ParquetGeometryEncodingBase.js +1 -1
- package/layers/support/ParquetGeometryEncodingLocation.d.ts +1 -1
- package/layers/support/ParquetGeometryEncodingLocation.js +1 -1
- package/layers/support/ParquetGeometryEncodingWkb.d.ts +1 -1
- package/layers/support/ParquetGeometryEncodingWkb.js +1 -1
- package/layers/support/PixelBlock.d.ts +1 -1
- package/layers/support/PixelBlock.js +1 -1
- package/layers/support/SimpleBandStatistics.d.ts +1 -1
- package/layers/support/SimpleBandStatistics.js +1 -1
- package/layers/support/Sublayer.js +1 -1
- package/layers/support/featureLayerUtils.js +1 -1
- package/layers/support/featureReductionUtils.js +1 -1
- package/layers/support/source/DataLayerSource.d.ts +6 -3
- package/layers/support/source/DataLayerSource.js +1 -1
- package/layers/support/source/MapLayerSource.d.ts +1 -1
- package/layers/support/source/MapLayerSource.js +1 -1
- package/layers/support/source/QueryTableDataSource.d.ts +1 -1
- package/layers/support/source/QueryTableDataSource.js +1 -1
- package/layers/support/source/RasterDataSource.d.ts +1 -1
- package/layers/support/source/RasterDataSource.js +1 -1
- package/layers/support/source/TableDataSource.d.ts +1 -1
- package/layers/support/source/TableDataSource.js +1 -1
- package/layers/support/source/types.d.ts +1 -1
- package/layers/types.d.ts +7 -1
- package/package.json +1 -1
- package/popup/content/MediaContent.d.ts +2 -2
- package/popup/content/types.d.ts +9 -0
- package/portal/Portal.d.ts +3 -3
- package/portal/PortalGroup.d.ts +1 -1
- package/portal/PortalItem.d.ts +2 -2
- package/portal/PortalItemResource.d.ts +1 -1
- package/portal/PortalQueryParams.d.ts +1 -1
- package/portal/PortalUser.d.ts +5 -5
- package/portal/schemas/definitions.js +1 -1
- package/portal/support/resourceUtils.d.ts +1 -1
- package/renderers/HeatmapRenderer.d.ts +2 -1
- package/renderers/HeatmapRenderer.js +1 -1
- package/renderers/PieChartRenderer.d.ts +2 -1
- package/renderers/PieChartRenderer.js +1 -1
- package/renderers/support/AuthoringInfo.d.ts +2 -1
- package/renderers/support/AuthoringInfo.js +1 -1
- package/renderers/support/AuthoringInfoClassBreakInfo.d.ts +1 -1
- package/renderers/support/AuthoringInfoClassBreakInfo.js +1 -1
- package/renderers/support/AuthoringInfoFieldInfo.d.ts +3 -2
- package/renderers/support/AuthoringInfoFieldInfo.js +1 -1
- package/renderers/support/DictionaryScriptEvaluator.js +1 -1
- package/renderers/support/HeatmapLegendOptions.d.ts +1 -1
- package/renderers/support/HeatmapLegendOptions.js +1 -1
- package/renderers/support/OthersCategory.d.ts +1 -1
- package/renderers/support/OthersCategory.js +1 -1
- package/rest/featureService/types.d.ts +1 -1
- package/rest/knowledgeGraph/wasmInterface/wasmToDataModelFactories.js +1 -1
- package/rest/support/ArealUnit.d.ts +1 -1
- package/rest/support/BaseImageMeasureResultValue.d.ts +1 -1
- package/rest/support/BaseImageMeasureResultValue.js +1 -1
- package/rest/support/BufferParameters.d.ts +1 -1
- package/rest/support/ClosestFacilityParameters.d.ts +1 -1
- package/rest/support/DataLayer.d.ts +1 -1
- package/rest/support/DensifyParameters.d.ts +1 -1
- package/rest/support/DirectionLine.d.ts +1 -1
- package/rest/support/DirectionPoint.d.ts +1 -1
- package/rest/support/DirectionsString.d.ts +1 -1
- package/rest/support/DistanceParameters.d.ts +1 -1
- package/rest/support/GPMessage.d.ts +1 -1
- package/rest/support/ImageAreaParameters.d.ts +1 -1
- package/rest/support/ImageAreaResult.d.ts +4 -2
- package/rest/support/ImageAreaResult.js +1 -1
- package/rest/support/ImageDistanceResult.d.ts +4 -2
- package/rest/support/ImageDistanceResult.js +1 -1
- package/rest/support/ImageHeightResult.d.ts +2 -1
- package/rest/support/ImageHeightResult.js +1 -1
- package/rest/support/ImageMeasureResultAngleValue.d.ts +3 -2
- package/rest/support/ImageMeasureResultAngleValue.js +1 -1
- package/rest/support/ImageMeasureResultAreaValue.d.ts +3 -2
- package/rest/support/ImageMeasureResultAreaValue.js +1 -1
- package/rest/support/ImageMeasureResultLengthValue.d.ts +4 -3
- package/rest/support/ImageMeasureResultLengthValue.js +1 -1
- package/rest/support/JobInfo.d.ts +1 -1
- package/rest/support/LinearUnit.d.ts +1 -1
- package/rest/support/LocateSetting.d.ts +1 -1
- package/rest/support/NAMessage.d.ts +1 -1
- package/rest/support/NetworkAttribute.d.ts +1 -1
- package/rest/support/OffsetParameters.d.ts +1 -1
- package/rest/support/PointBarrier.d.ts +1 -1
- package/rest/support/PolygonBarrier.d.ts +1 -1
- package/rest/support/PolylineBarrier.d.ts +1 -1
- package/rest/support/RouteParameters.d.ts +1 -1
- package/rest/support/ServiceAreaParameters.d.ts +1 -1
- package/rest/support/Stop.d.ts +1 -1
- package/rest/support/TravelMode.d.ts +1 -1
- package/smartMapping/renderers/pieChart.js +1 -1
- package/smartMapping/renderers/relationship.js +1 -1
- package/smartMapping/renderers/univariateColorSize.js +1 -1
- package/smartMapping/support/adapters/support/utils.js +1 -1
- package/support/revision.js +1 -1
- package/support/tests/meshUtils.js +1 -1
- package/symbols/ExtrudeSymbol3DLayer.d.ts +2 -1
- package/symbols/ExtrudeSymbol3DLayer.js +1 -1
- package/symbols/FillSymbol3DLayer.d.ts +4 -2
- package/symbols/FillSymbol3DLayer.js +1 -1
- package/symbols/IconSymbol3DLayer.d.ts +23 -4
- package/symbols/IconSymbol3DLayer.js +1 -1
- package/symbols/LineSymbol3DLayer.d.ts +2 -1
- package/symbols/LineSymbol3DLayer.js +1 -1
- package/symbols/ObjectSymbol3DLayer.d.ts +6 -3
- package/symbols/ObjectSymbol3DLayer.js +1 -1
- package/symbols/PathSymbol3DLayer.d.ts +2 -1
- package/symbols/PathSymbol3DLayer.js +1 -1
- package/symbols/TextSymbol3DLayer.d.ts +21 -3
- package/symbols/TextSymbol3DLayer.js +1 -1
- package/symbols/patterns/LinePattern3D.js +1 -1
- package/symbols/support/IconSymbol3DLayerResource.d.ts +1 -1
- package/symbols/support/IconSymbol3DLayerResource.js +1 -1
- package/symbols/support/ObjectSymbol3DLayerResource.d.ts +1 -1
- package/symbols/support/ObjectSymbol3DLayerResource.js +1 -1
- package/symbols/support/OccludedVisibility.d.ts +27 -0
- package/symbols/support/Symbol3DAnchorPosition2D.d.ts +1 -1
- package/symbols/support/Symbol3DAnchorPosition2D.js +1 -1
- package/symbols/support/Symbol3DAnchorPosition3D.d.ts +1 -1
- package/symbols/support/Symbol3DAnchorPosition3D.js +1 -1
- package/symbols/support/Symbol3DFillMaterial.d.ts +3 -2
- package/symbols/support/Symbol3DFillMaterial.js +1 -1
- package/symbols/support/Symbol3DHalo.d.ts +1 -1
- package/symbols/support/Symbol3DHalo.js +1 -1
- package/symbols/support/Symbol3DIconOutline.d.ts +1 -1
- package/symbols/support/Symbol3DIconOutline.js +1 -1
- package/symbols/support/Symbol3DMaterial.d.ts +1 -1
- package/symbols/support/Symbol3DMaterial.js +1 -1
- package/symbols/support/Symbol3DOutline.d.ts +1 -1
- package/symbols/support/Symbol3DOutline.js +1 -1
- package/symbols/support/Symbol3DTextBackground.d.ts +1 -1
- package/symbols/support/Symbol3DTextBackground.js +1 -1
- package/symbols/support/previewSymbol3D.js +1 -1
- package/symbols/support/primitives.js +5 -0
- package/symbols/support/types.d.ts +2 -0
- package/symbols/support/utils.js +1 -1
- package/views/2d/analysis/AnalysisView2D.d.ts +2 -2
- package/views/2d/analysis/AnalysisView2D.js +1 -1
- package/views/2d/analysis/AreaMeasurementAnalysisView2D.d.ts +1 -1
- package/views/2d/analysis/AreaMeasurementAnalysisView2D.js +1 -1
- package/views/2d/analysis/DistanceMeasurementAnalysisView2D.d.ts +1 -1
- package/views/2d/analysis/DistanceMeasurementAnalysisView2D.js +1 -1
- package/views/2d/analysis/ElevationProfileAnalysisView2D.d.ts +1 -1
- package/views/2d/analysis/ElevationProfileAnalysisView2D.js +1 -1
- package/views/2d/engine/Bitmap.js +1 -1
- package/views/2d/engine/Container.js +1 -1
- package/views/2d/engine/DisplayObject.js +1 -1
- package/views/2d/engine/brushes.js +1 -1
- package/views/2d/engine/flow/styles/Imagery.js +1 -1
- package/views/2d/engine/vectorTiles/GlyphMosaic.js +1 -1
- package/views/2d/engine/vectorTiles/SpriteMosaic.js +1 -1
- package/views/2d/engine/vectorTiles/TileParser.js +1 -1
- package/views/2d/engine/vectorTiles/VectorTileContainer.js +1 -1
- package/views/2d/engine/vectorTiles/VectorTileRendererHelper3D.js +1 -1
- package/views/2d/engine/vectorTiles/buckets/FillBucket.js +1 -1
- package/views/2d/engine/webgl/AttributeStoreView.js +1 -1
- package/views/2d/engine/webgl/ClipMesh.js +5 -0
- package/views/2d/engine/webgl/GlyphMosaic.js +1 -1
- package/views/2d/engine/webgl/Overlay.js +1 -1
- package/views/2d/engine/webgl/OverlayMultipoint.js +1 -1
- package/views/2d/engine/webgl/SpriteMosaic.js +1 -1
- package/views/2d/engine/webgl/VideoScreenRenderer.js +1 -1
- package/views/2d/engine/webgl/WGLContainer.js +1 -1
- package/views/2d/engine/webgl/animations/store/AnimationStore.js +1 -1
- package/views/2d/engine/webgl/brushes/WGLBrushTileDebugInfo.js +1 -1
- package/views/2d/engine/webgl/effects/highlight/HighlightGradient.js +1 -1
- package/views/2d/engine/webgl/mesh/templates/templateUtils.js +1 -1
- package/views/2d/engine/webgl/meshing/SimpleMesh.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/TestTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/TextureStatisticsTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/animated/AnimatedPolyMeshWriters.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/blend/BlendTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/clip/ClipTechnique.js +5 -0
- package/views/2d/engine/webgl/shaderGraph/techniques/colorize/ColorizeTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/dotDensity/DotDensityResources.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/dotDensity/DotDensityTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/drop-shadow/DropShadowTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/fill/AFillMeshWriter.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/fill/ComplexFillTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/fill/ComplexOutlineFillTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/fill/FillTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/fill/GradientFillTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/fill/OutlineFillTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/fill/PatternFillTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/fill/PatternOutlineFillTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/grid/GridTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/heatmap/HeatmapResources.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/heatmap/HeatmapTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/labels/LabelTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/line/GradientStrokeTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/line/LineTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/line/TexturedLineTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/magnifier/MagnifierTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/markers/MarkerTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/mesh/MeshWriterRegistry.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/opacity/OpacityTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/overlay/OverlayTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/pieChart/PieChartTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/raster/RasterColorizerTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/raster/RasterHighlightTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/raster/processor/textureUtils.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/shaders/ClipShader.js +5 -0
- package/views/2d/engine/webgl/shaderGraph/techniques/text/TextTechnique.js +1 -1
- package/views/2d/engine/webgl/shaderGraph/techniques/videoScreenRenderer/VideoScreenTechnique.js +1 -1
- package/views/2d/engine/webgl/shaders/sources/shaderRepository.js +1 -1
- package/views/2d/engine/webgl/textureUtils.js +1 -1
- package/views/2d/layers/KMLLayerView2D.js +1 -1
- package/views/2d/layers/LayerView2D.js +1 -1
- package/views/2d/layers/MediaLayerView2D.js +1 -1
- package/views/2d/layers/TileLayerView2D.js +1 -1
- package/views/2d/layers/features/FeatureContainer.js +1 -1
- package/views/2d/layers/features/RenderState.js +1 -1
- package/views/2d/webglDeps.js +1 -1
- package/views/3d/analysis/AnalysisView3D.d.ts +2 -2
- package/views/3d/analysis/AnalysisView3D.js +1 -1
- package/views/3d/analysis/AreaMeasurementAnalysisView3D.d.ts +1 -1
- package/views/3d/analysis/AreaMeasurementAnalysisView3D.js +1 -1
- package/views/3d/analysis/DimensionAnalysisView3D.d.ts +1 -1
- package/views/3d/analysis/DimensionAnalysisView3D.js +1 -1
- package/views/3d/analysis/DirectLineMeasurementAnalysisView3D.d.ts +1 -1
- package/views/3d/analysis/DirectLineMeasurementAnalysisView3D.js +1 -1
- package/views/3d/analysis/ElevationProfileAnalysisView3D.d.ts +1 -1
- package/views/3d/analysis/ElevationProfileAnalysisView3D.js +1 -1
- package/views/3d/analysis/LineOfSightAnalysisView3D.d.ts +1 -1
- package/views/3d/analysis/LineOfSightAnalysisView3D.js +1 -1
- package/views/3d/analysis/ShadowCastAnalysisView3D.d.ts +1 -1
- package/views/3d/analysis/ShadowCastAnalysisView3D.js +1 -1
- package/views/3d/analysis/SliceAnalysisView3D.d.ts +1 -1
- package/views/3d/analysis/SliceAnalysisView3D.js +1 -1
- package/views/3d/analysis/ViewshedAnalysisView3D.d.ts +1 -1
- package/views/3d/analysis/ViewshedAnalysisView3D.js +1 -1
- package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementTool.js +1 -1
- package/views/3d/analysis/VolumeMeasurementAnalysisView3D.d.ts +1 -1
- package/views/3d/analysis/VolumeMeasurementAnalysisView3D.js +1 -1
- package/views/3d/constraints/AltitudeConstraint.d.ts +1 -1
- package/views/3d/constraints/AltitudeConstraint.js +1 -1
- package/views/3d/constraints/ClipDistanceConstraint.d.ts +1 -1
- package/views/3d/constraints/ClipDistanceConstraint.js +1 -1
- package/views/3d/constraints/Constraints.d.ts +7 -4
- package/views/3d/constraints/Constraints.js +1 -1
- package/views/3d/constraints/TiltConstraint.d.ts +1 -1
- package/views/3d/constraints/TiltConstraint.js +1 -1
- package/views/3d/environment/LocalAtmosphere.js +1 -1
- package/views/3d/environment/MarsAtmosphere.js +1 -1
- package/views/3d/glTF/internal/Resource.js +1 -1
- package/views/3d/interactive/editingTools/reshape/ReshapeOperation.js +1 -1
- package/views/3d/interactive/editingTools/reshape/reshapeTooltipUtils3D.js +1 -1
- package/views/3d/interactive/visualElements/LineVisualElement.js +1 -1
- package/views/3d/layers/ElevationLayerView3D.js +1 -1
- package/views/3d/layers/IntegratedMesh3DTilesLayerView3D.js +1 -1
- package/views/3d/layers/PointCloudLayerView3D.js +1 -1
- package/views/3d/layers/graphics/Graphics3DIconSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DLineSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/Graphics3DObjectSymbolLayer.js +1 -1
- package/views/3d/layers/graphics/defaultSymbolComplexity.js +1 -1
- package/views/3d/layers/graphics/pipeline/symbolization/IconSymbolLayerRenderer.js +1 -1
- package/views/3d/layers/graphics/pipeline/symbolization/ObjectSymbolLayerRenderer.js +1 -1
- package/views/3d/layers/graphics/pipeline/symbolization/factoryUtils.js +1 -1
- package/views/3d/layers/graphics/wosrLoader.js +1 -1
- package/views/3d/layers/i3s/meshUtils.js +1 -1
- package/views/3d/layers/support/MediaLayerInteractionOptions.d.ts +3 -2
- package/views/3d/layers/support/MediaLayerInteractionOptions.js +1 -1
- package/views/3d/layers/support/MediaLayerInteractionReshapeOptions.d.ts +1 -1
- package/views/3d/layers/support/MediaLayerInteractionReshapeOptions.js +1 -1
- package/views/3d/support/engineContent/marker.js +1 -1
- package/views/3d/support/gaussianSplatting/GaussianSplatFadeTexture.js +1 -1
- package/views/3d/support/gaussianSplatting/GaussianSplatOrderTexture.js +1 -1
- package/views/3d/support/gaussianSplatting/GaussianSplatTextureAtlas.js +1 -1
- package/views/3d/terrain/OverlayRenderer.js +1 -1
- package/views/3d/terrain/TileCompositor.js +1 -1
- package/views/3d/terrain/TileRenderer.js +1 -1
- package/views/3d/webgl/ManagedColorAttachment.d.ts +2 -2
- package/views/3d/webgl/ManagedColorAttachment.js +1 -1
- package/views/3d/webgl/ManagedDepthAttachment.d.ts +2 -2
- package/views/3d/webgl/ManagedDepthAttachment.js +1 -1
- package/views/3d/webgl/ManagedDepthTexture.js +1 -1
- package/views/3d/webgl/ManagedFBO.d.ts +8 -6
- package/views/3d/webgl/ManagedFBO.js +1 -1
- package/views/3d/webgl/ManagedFBOAttachment.d.ts +2 -2
- package/views/3d/webgl/ManagedFBOAttachment.js +1 -1
- package/views/3d/webgl/ManagedFBOResource.d.ts +1 -1
- package/views/3d/webgl/ManagedFBOResource.js +1 -1
- package/views/3d/webgl-engine/collections/Component/IntersectionGeometry.js +1 -1
- package/views/3d/webgl-engine/core/FBOCache.js +1 -1
- package/views/3d/webgl-engine/core/shaderLibrary/shading/LineStipple.glsl.js +55 -23
- package/views/3d/webgl-engine/effects/highlight/Highlight.js +1 -1
- package/views/3d/webgl-engine/effects/magnifier/Magnifier.js +1 -1
- package/views/3d/webgl-engine/effects/smaa/SMAA.js +1 -1
- package/views/3d/webgl-engine/effects/ssao/SSAO.js +1 -1
- package/views/3d/webgl-engine/lib/BasisUtil.js +1 -1
- package/views/3d/webgl-engine/lib/DDSUtil.js +1 -1
- package/views/3d/webgl-engine/lib/DrapedHeatmapRenderer.js +1 -1
- package/views/3d/webgl-engine/lib/GPUPointOcclusionQuery.js +1 -1
- package/views/3d/webgl-engine/lib/ManagedTexture.js +1 -1
- package/views/3d/webgl-engine/lib/TextTextureAtlas.js +1 -1
- package/views/3d/webgl-engine/lib/TextureBackedBuffer/TextureBuffer.js +1 -1
- package/views/3d/webgl-engine/lib/edgeRendering/strokes.js +1 -1
- package/views/3d/webgl-engine/lib/glUtil3D.js +1 -1
- package/views/3d/webgl-engine/materials/RibbonLineMaterial.js +1 -1
- package/views/3d/webgl-engine/materials/internal/WaterTextureRepository.js +1 -1
- package/views/3d/webgl-engine/materials/lineStippleUtils.js +1 -1
- package/views/3d/webgl-engine/materials/stippleTextureRepository.js +1 -1
- package/views/3d/webgl-engine/shaders/RibbonLineTechniqueConfiguration.js +1 -1
- package/views/DOMContainer.d.ts +1 -2
- package/views/MapView.d.ts +10 -15
- package/views/PopupView.d.ts +6 -6
- package/views/SceneView.d.ts +3 -4
- package/views/SceneView.js +1 -1
- package/views/VideoView.js +1 -1
- package/views/View.d.ts +11 -13
- package/views/View2D.d.ts +37 -37
- package/views/analysis/AnalysisView.d.ts +1 -1
- package/views/analysis/AnalysisView.js +1 -1
- package/views/draw/{input/CursorUpdateEvent.d.ts → CursorUpdateEvent.d.ts} +1 -1
- package/views/draw/{input/CursorUpdateEvent.js → CursorUpdateEvent.js} +1 -1
- package/views/draw/{input/DrawCompleteEvent.d.ts → DrawCompleteEvent.d.ts} +1 -1
- package/views/draw/{input/DrawCompleteEvent.js → DrawCompleteEvent.js} +1 -1
- package/views/draw/DrawGraphicTool.js +1 -1
- package/views/draw/MultipointDrawAction.d.ts +4 -4
- package/views/draw/MultipointDrawAction.js +1 -1
- package/views/draw/PointDrawAction.d.ts +2 -2
- package/views/draw/PointDrawAction.js +1 -1
- package/views/draw/PolygonDrawAction.d.ts +4 -4
- package/views/draw/PolygonDrawAction.js +1 -1
- package/views/draw/PolylineDrawAction.d.ts +4 -4
- package/views/draw/PolylineDrawAction.js +1 -1
- package/views/draw/SegmentDrawAction.d.ts +3 -3
- package/views/draw/SegmentDrawAction.js +1 -1
- package/views/draw/{input/VertexAddEvent.d.ts → VertexAddEvent.d.ts} +1 -1
- package/views/draw/{input/VertexAddEvent.js → VertexAddEvent.js} +1 -1
- package/views/draw/{input/VertexRemoveEvent.d.ts → VertexRemoveEvent.d.ts} +1 -1
- package/views/draw/VertexRemoveEvent.js +5 -0
- package/views/draw/support/Reshape.js +1 -1
- package/views/draw/support/reshapeTooltipUtils.js +1 -1
- package/views/draw/support/tooltipUtils.js +1 -1
- package/views/interactive/sketch/Units.d.ts +3 -0
- package/views/layers/HighlightLayerViewMixin.d.ts +1 -3
- package/views/layers/ImageryLayerViewMixin.d.ts +1 -3
- package/views/layers/KMLLayerView.d.ts +1 -1
- package/views/layers/MediaLayerViewMixin.d.ts +3 -2
- package/views/layers/MediaLayerViewMixin.js +1 -1
- package/views/support/GeodesicMeasurementWorker.js +5 -0
- package/views/support/GeodesicMeasurementWorkerHandle.js +5 -0
- package/views/support/HighlightOptions.d.ts +0 -1
- package/views/support/TextureCompressionHelper.js +1 -1
- package/views/support/automaticAreaMeasurementUtils.js +1 -1
- package/views/support/imageReprojection.js +1 -1
- package/views/types.d.ts +1 -1
- package/views/webgl/FramebufferObject.js +1 -1
- package/views/webgl/RenderingContext.js +1 -1
- package/views/webgl/Texture.js +1 -1
- package/views/webgl/rasterUtils.js +1 -1
- package/views/webgl/testSVGPremultipliedAlpha.js +1 -1
- package/views/webgl/textureTracer.js +5 -0
- package/webdoc/support/SlideThumbnail.d.ts +1 -1
- package/webdoc/support/SlideThumbnail.js +1 -1
- package/webmap/Bookmark.d.ts +2 -1
- package/webmap/Bookmark.js +1 -1
- package/webmap/Version.d.ts +2 -2
- package/webmap/Version.js +1 -1
- package/webmap/utils.js +1 -1
- package/webscene/Slide.d.ts +6 -3
- package/webscene/Slide.js +1 -1
- package/webscene/Version.d.ts +2 -2
- package/webscene/Version.js +1 -1
- package/webscene/spec-certification/api.js +1 -1
- package/webscene/support/SlideEnvironment.d.ts +1 -1
- package/webscene/support/SlideEnvironment.js +1 -1
- package/webscene/support/SlideVisibleLayer.d.ts +1 -1
- package/webscene/support/SlideVisibleLayer.js +1 -1
- package/widgets/AreaMeasurement2D/AreaMeasurement2DViewModel.d.ts +1 -1
- package/widgets/AreaMeasurement2D/AreaMeasurement2DViewModel.js +1 -1
- package/widgets/AreaMeasurement3D/AreaMeasurement3DViewModel.d.ts +1 -1
- package/widgets/AreaMeasurement3D/AreaMeasurement3DViewModel.js +1 -1
- package/widgets/BatchAttributeForm/VisibleElements.d.ts +1 -1
- package/widgets/BatchAttributeForm/VisibleElements.js +1 -1
- package/widgets/BatchAttributeForm/inputs/FieldInput.js +1 -1
- package/widgets/BatchAttributeForm.d.ts +2 -1
- package/widgets/BatchAttributeForm.js +1 -1
- package/widgets/Bookmarks/BookmarksViewModel.js +1 -1
- package/widgets/Bookmarks.js +1 -1
- package/widgets/DirectLineMeasurement3D/DirectLineMeasurement3DViewModel.d.ts +1 -1
- package/widgets/DirectLineMeasurement3D/DirectLineMeasurement3DViewModel.js +1 -1
- package/widgets/DistanceMeasurement2D/DistanceMeasurement2DViewModel.d.ts +1 -1
- package/widgets/DistanceMeasurement2D/DistanceMeasurement2DViewModel.js +1 -1
- package/widgets/Editor.js +1 -1
- package/widgets/FeatureTable/ActionColumn.d.ts +1 -1
- package/widgets/FeatureTable/AttachmentsColumn.d.ts +1 -1
- package/widgets/FeatureTable/FeatureTableViewModel.d.ts +2 -2
- package/widgets/FeatureTable/FieldColumn.d.ts +1 -1
- package/widgets/FeatureTable/Grid/Column.d.ts +1 -1
- package/widgets/FeatureTable/support/ColumnTemplateBase.d.ts +1 -1
- package/widgets/FeatureTable/support/FieldColumnTemplate.d.ts +1 -1
- package/widgets/FeatureTable/support/GroupColumnTemplate.d.ts +1 -1
- package/widgets/FeatureTable/support/TableTemplate.d.ts +1 -1
- package/widgets/FeatureTable/support/{interfaces.d.ts → types.d.ts} +1 -1
- package/widgets/FeatureTable.d.ts +2 -2
- package/widgets/LineOfSight/LineOfSightViewModel.d.ts +1 -1
- package/widgets/LineOfSight/LineOfSightViewModel.js +1 -1
- package/widgets/OrientedImageryViewer/adapters/view/SceneViewAdapter.js +1 -1
- package/widgets/PanoramicViewer/support/importUtils.js +1 -1
- package/widgets/Print/PrintViewModel.d.ts +1 -1
- package/widgets/Sketch/CreateToolVisibilityMap.d.ts +1 -1
- package/widgets/Sketch/CreateToolVisibilityMap.js +1 -1
- package/widgets/Sketch/SelectionToolVisibilityMap.d.ts +1 -1
- package/widgets/Sketch/SelectionToolVisibilityMap.js +1 -1
- package/widgets/Sketch/VisibleElements.d.ts +5 -3
- package/widgets/Sketch/VisibleElements.js +1 -1
- package/widgets/Sketch.d.ts +2 -1
- package/widgets/Sketch.js +1 -1
- package/widgets/Slice/SliceViewModel.d.ts +1 -1
- package/widgets/Slice/SliceViewModel.js +1 -1
- package/widgets/UtilityNetworkAssociations.js +1 -1
- package/widgets/support/AnalysisViewModel.d.ts +1 -1
- package/widgets/support/AnalysisViewModel.js +1 -1
- package/widgets/support/InteractiveToolViewModel.d.ts +1 -1
- package/widgets/support/InteractiveToolViewModel.js +1 -1
- package/assets/esri/core/libs/libtess/libtess.wasm +0 -0
- package/assets/esri/core/workers/chunks/00e407d262c49890afa8.js +0 -1
- package/assets/esri/core/workers/chunks/19db60a3b4b09d445bd1.js +0 -1
- package/assets/esri/core/workers/chunks/1e55f152b60145f33b61.js +0 -1
- package/assets/esri/core/workers/chunks/294acaaebfedb05fe81e.js +0 -1
- package/assets/esri/core/workers/chunks/31eda00e6842005d0ec8.js +0 -1
- package/assets/esri/core/workers/chunks/3d49c6427120edc8eac9.js +0 -1
- package/assets/esri/core/workers/chunks/404229f10aef5ac23c87.js +0 -1
- package/assets/esri/core/workers/chunks/4278b35fb6fd578c403e.js +0 -1
- package/assets/esri/core/workers/chunks/46b63a65484b102e9ccb.js +0 -1
- package/assets/esri/core/workers/chunks/4f03d19a70dca6c507be.js +0 -316
- package/assets/esri/core/workers/chunks/5686220aed9a74dbd2b1.js +0 -1
- package/assets/esri/core/workers/chunks/5a2933ae19345b7d5aa7.js +0 -1
- package/assets/esri/core/workers/chunks/5e9fdd4eff7189f45932.js +0 -1
- package/assets/esri/core/workers/chunks/67a45faa80316f43c51b.js +0 -1
- package/assets/esri/core/workers/chunks/68ee11589de0da7fed08.js +0 -1
- package/assets/esri/core/workers/chunks/82ced9254b27707522ef.js +0 -1
- package/assets/esri/core/workers/chunks/bb5373ff7cdad7270095.js +0 -1
- package/assets/esri/core/workers/chunks/bddaa83fcb9fdb1e1856.js +0 -1
- package/assets/esri/core/workers/chunks/d048e4926e78458afa3e.js +0 -1
- package/assets/esri/core/workers/chunks/d199deff988eaefe18b4.js +0 -1
- package/assets/esri/core/workers/chunks/d77f56576a49a998164a.js +0 -1
- package/assets/esri/core/workers/chunks/dae09fb8da0faa6dede4.js +0 -1
- package/assets/esri/core/workers/chunks/e16e88de4e93b0f48b2c.js +0 -1
- package/chunks/libtess-asm.js +0 -5
- package/chunks/libtess.js +0 -5
- package/layers/BlendMode.d.ts +0 -2
- package/layers/LayerListMode.d.ts +0 -2
- package/layers/LayerType.d.ts +0 -2
- package/popup/content/support/mediaInfoTypes.d.ts +0 -7
- package/support/modeUtils.d.ts +0 -2
- package/views/SelectionManager.d.ts +0 -1
- package/views/draw/input/VertexRemoveEvent.js +0 -5
- package/views/webgl/Texture.d.ts +0 -6
- /package/portal/{interfaces.d.ts → types.d.ts} +0 -0
- /package/rest/support/{interfaces.d.ts → types.d.ts} +0 -0
- /package/views/draw/{input/VertexUpdateEvent.js → VertexUpdateEvent.js} +0 -0
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{getBasisTranscoder as e}from"../../../../libs/basisu/BasisUTranscoder.js";import{CompressedTextureFormat as t}from"../../../webgl/enums.js";import
|
|
5
|
+
import{getBasisTranscoder as e}from"../../../../libs/basisu/BasisUTranscoder.js";import{CompressedTextureFormat as t}from"../../../webgl/enums.js";import n from"../../../webgl/Texture.js";import{getFormatBytesPerElement as s}from"../../../webgl/Util.js";let r=null,i=null;async function a(){return null==i&&(i=e(),r=await i),i}function l(e,t){if(null==r)return e.byteLength;const n=new r.BasisFile(new Uint8Array(e)),s=u(n)?o(n.getNumLevels(0),n.getHasAlpha(),n.getImageWidth(0,0),n.getImageHeight(0,0),t):0;return n.close(),n.delete(),s}function g(e,t){if(null==r)return e.byteLength;const n=new r.KTX2File(new Uint8Array(e)),s=c(n)?o(n.getLevels(),n.getHasAlpha(),n.getWidth(),n.getHeight(),t):0;return n.close(),n.delete(),s}function o(e,n,r,i,a){const l=s(n?t.COMPRESSED_RGBA8_ETC2_EAC:t.COMPRESSED_RGB8_ETC2),g=a&&e>1?(4**e-1)/(3*4**(e-1)):1;return Math.ceil(r*i*l*g)}function u(e){return e.getNumImages()>=1&&!e.isUASTC()}function c(e){return e.getFaces()>=1&&e.isETC1S()}async function m(e,t,n){null==r&&(r=await a());const s=new r.BasisFile(new Uint8Array(n));if(!u(s))return null;s.startTranscoding();const i=T(e,t,s.getNumLevels(0),s.getHasAlpha(),s.getImageWidth(0,0),s.getImageHeight(0,0),(e,t)=>s.getImageTranscodedSizeInBytes(0,e,t),(e,t,n)=>s.transcodeImage(n,0,e,t,0,0));return s.close(),s.delete(),i}async function h(e,t,n){null==r&&(r=await a());const s=new r.KTX2File(new Uint8Array(n));if(!c(s))return null;s.startTranscoding();const i=T(e,t,s.getLevels(),s.getHasAlpha(),s.getWidth(),s.getHeight(),(e,t)=>s.getImageTranscodedSizeInBytes(e,0,0,t),(e,t,n)=>s.transcodeImage(n,e,0,0,t,0,-1,-1));return s.close(),s.delete(),i}function T(e,s,r,i,a,l,g,o){const{compressedTextureETC:u,compressedTextureS3TC:c}=e.capabilities,[m,h]=u?i?[1,t.COMPRESSED_RGBA8_ETC2_EAC]:[0,t.COMPRESSED_RGB8_ETC2]:c?i?[3,t.COMPRESSED_RGBA_S3TC_DXT5_EXT]:[2,t.COMPRESSED_RGB_S3TC_DXT1_EXT]:[13,6408],T=s.hasMipmap?r:Math.min(1,r),d=[];for(let t=0;t<T;t++)d.push(new Uint8Array(g(t,m))),o(t,m,d[t]);return s.internalFormat=h,s.hasMipmap=d.length>1,s.samplingMode=s.hasMipmap?9987:9729,s.width=a,s.height=l,new n(e,s,{type:"compressed",levels:d})}export{c as checkKTX2,m as createTextureBasis,h as createTextureKTX2,l as estimateMemoryBasis,g as estimateMemoryKTX2,a as loadBasisTranscoder};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import e from"../../../../core/Logger.js";import{CompressedTextureFormat as t}from"../../../webgl/enums.js";import
|
|
5
|
+
import e from"../../../../core/Logger.js";import{CompressedTextureFormat as t}from"../../../webgl/enums.js";import r from"../../../webgl/Texture.js";const n=()=>e.getLogger("esri.views.3d.webgl-engine.lib.DDSUtil"),o=542327876,a=131072,i=4;function s(e){return e.charCodeAt(0)+(e.charCodeAt(1)<<8)+(e.charCodeAt(2)<<16)+(e.charCodeAt(3)<<24)}function l(e){return String.fromCharCode(255&e,e>>8&255,e>>16&255,e>>24&255)}const u=s("DXT1"),c=s("DXT3"),h=s("DXT5"),m=31,f=0,d=1,p=2,g=3,D=4,C=7,w=20,S=21;function T(e,t,n){const o=b(n,t.hasMipmap??!1);if(null==o)throw new Error("DDS texture data is null");const{textureData:a,internalFormat:i,width:s,height:l}=o;return t.samplingMode=a.levels.length>1?9987:9729,t.hasMipmap=a.levels.length>1,t.internalFormat=i,t.width=s,t.height=l,new r(e,t,a)}function b(e,r){const s=new Int32Array(e.buffer,e.byteOffset,m);if(s[f]!==o)return n().error("Invalid magic number in DDS header"),null;if(!(s[w]&i))return n().error("Unsupported format, must contain a FourCC code"),null;const T=s[S];let b,_;switch(T){case u:b=8,_=t.COMPRESSED_RGB_S3TC_DXT1_EXT;break;case c:b=16,_=t.COMPRESSED_RGBA_S3TC_DXT3_EXT;break;case h:b=16,_=t.COMPRESSED_RGBA_S3TC_DXT5_EXT;break;default:return n().error("Unsupported FourCC code:",l(T)),null}let E=1,x=s[D],M=s[g];(3&x||3&M)&&(n().warn("Rounding up compressed texture size to nearest multiple of 4."),x=x+3&-4,M=M+3&-4);const X=x,A=M;let R,v;s[p]&a&&!1!==r&&(E=Math.max(1,s[C]));let y=e.byteOffset+s[d]+4;const F=[];for(let t=0;t<E;++t)v=(x+3>>2)*(M+3>>2)*b,R=new Uint8Array(e.buffer,y,v),F.push(R),y+=v,x=Math.max(1,x>>1),M=Math.max(1,M>>1);return{textureData:{type:"compressed",levels:F},internalFormat:_,width:X,height:A}}export{T as createDDSTexture,b as createDDSTextureData};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import{disposeMaybe as e}from"../../../../core/maybe.js";import{watch as r}from"../../../../core/reactiveUtils.js";import{property as a,subclass as i}from"../../../../core/accessorSupport/decorators.js";import{createQuadVAO as s}from"./glUtil3D.js";import{SortedRenderGeometryRenderer as o}from"./SortedRenderGeometryRenderer.js";import{HeatmapPassParameters as n,HeatmapTechnique as h}from"../shaders/HeatmapTechnique.js";import{HeatmapTechniqueConfiguration as m}from"../shaders/HeatmapTechniqueConfiguration.js";import{PixelType as p}from"../../../webgl/enums.js";import{FramebufferObject as l}from"../../../webgl/FramebufferObject.js";import
|
|
5
|
+
import{__decorate as t}from"tslib";import{disposeMaybe as e}from"../../../../core/maybe.js";import{watch as r}from"../../../../core/reactiveUtils.js";import{property as a,subclass as i}from"../../../../core/accessorSupport/decorators.js";import{createQuadVAO as s}from"./glUtil3D.js";import{SortedRenderGeometryRenderer as o}from"./SortedRenderGeometryRenderer.js";import{HeatmapPassParameters as n,HeatmapTechnique as h}from"../shaders/HeatmapTechnique.js";import{HeatmapTechniqueConfiguration as m}from"../shaders/HeatmapTechniqueConfiguration.js";import{PixelType as p}from"../../../webgl/enums.js";import{FramebufferObject as l}from"../../../webgl/FramebufferObject.js";import c from"../../../webgl/Texture.js";import{TextureDescriptor as d}from"../../../webgl/TextureDescriptor.js";let u=class extends o{constructor(t){super(t),this.pixelRatio=1,this._colorRampData=new Uint8ClampedArray(4),this.type="draped-heatmap",this._heatmapParameters=new n,this._configuration=new m;const e=new d;e.pixelFormat=t.pixelFormat,e.internalFormat=t.internalFormat,e.dataType=t.dataType,e.samplingMode=t.samplingMode,e.wrapMode=33071;const r=t.rendererContext.rctx;this._densityMap=new l(r,e),this._vao=s(r),this._configuration.usesHalfFloat=t.dataType!==p.FLOAT,t.rendererContext.pluginContext.techniques.precompile(h,this._configuration)}initialize(){const t=this._colorRampData,e=new d(t.length/4,1);e.wrapMode=33071,this._colorRamp=new c(this.rctx,e,t),this._heatmapParameters.densityMap=this._densityMap.colorTexture,this.addHandles(r(()=>[this.colorRampData,this.minDensity,this.maxDensity,this.fieldTotal,this.pixelRatio,this.searchRadius],()=>this.rendererContext.notifyContentChanged()))}destroy(){this._densityMap=e(this._densityMap),this._vao=e(this._vao),this._colorRamp=e(this._colorRamp)}get searchRadius(){return this._heatmapParameters.searchRadius}set searchRadius(t){t!==this._heatmapParameters.searchRadius&&(this._heatmapParameters.searchRadius=t,this.notifyChange("searchRadius"))}get minDensity(){return this._heatmapParameters.minDensity}set minDensity(t){t!==this._heatmapParameters.minDensity&&(this._heatmapParameters.minDensity=t,this.notifyChange("minDensity"))}get maxDensity(){return this._heatmapParameters.maxDensity}set maxDensity(t){t!==this._heatmapParameters.maxDensity&&(this._heatmapParameters.maxDensity=t,this.notifyChange("maxDensity"))}get fieldTotal(){return this._heatmapParameters.fieldTotal}set fieldTotal(t){this._heatmapParameters.fieldTotal=t,this.notifyChange("fieldTotal")}get colorRampData(){return this._colorRampData}set colorRampData(t){const{colorRamp:e}=this._heatmapParameters;if(null!=e&&t!==this._colorRampData){const r=e.descriptor.width,a=t.length/4;a!==r&&e.resize(a,1),e.setData(t)}this._colorRampData=t}get _colorRamp(){return this._heatmapParameters.colorRamp}set _colorRamp(t){this._heatmapParameters.colorRamp=t}get hasHighlights(){return!1}get hasWater(){return!1}render(t){const e=this.sortedRenderers;if(0===e.length)return;const r=this.rctx.getBoundFramebufferObject(),a=this.rctx.getViewport(),{pixelRatio:i}=this,s=Math.ceil(a.width*i),o=Math.ceil(a.height*i);this._densityMap.resize(s,o),this.rctx.bindFramebuffer(this._densityMap),this.rctx.setViewport(0,0,s,o),this.rctx.clear(16384);let n=!1;if(e.forAll(e=>{const r=e.acquireTechniques(t);r&&(e.render(t,r),n=!0)}),this.rctx.bindFramebuffer(r),this.rctx.setViewport(a.x,a.y,a.width,a.height),!n)return;this.rctx.bindVAO(this._vao);const m=this.rendererContext.pluginContext.techniques.get(h,this._configuration);this.rctx.bindTechnique(m,t.bind,this._heatmapParameters),this.rctx.drawArrays(m.primitiveType,0,this._vao.vertexCount("geometry"))}};t([a()],u.prototype,"searchRadius",null),t([a()],u.prototype,"minDensity",null),t([a()],u.prototype,"maxDensity",null),t([a()],u.prototype,"fieldTotal",null),t([a()],u.prototype,"pixelRatio",void 0),t([a()],u.prototype,"colorRampData",null),t([a({constructOnly:!0})],u.prototype,"dataType",void 0),t([a({constructOnly:!0})],u.prototype,"samplingMode",void 0),t([a({constructOnly:!0})],u.prototype,"pixelFormat",void 0),t([a({constructOnly:!0})],u.prototype,"internalFormat",void 0),t([a()],u.prototype,"_colorRampData",void 0),u=t([i("esri.views.3d.webgl-engine.lib.DrapedHeatmapRenderer")],u);export{u as DrapedHeatmapRenderer};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as t}from"tslib";import"../../../../core/has.js";import{disposeMaybe as e,destroyMaybe as i}from"../../../../core/maybe.js";import{property as r,subclass as o}from"../../../../core/accessorSupport/decorators.js";import{multiply as s,fromTranslation as n}from"../../../../core/libs/gl-matrix-2/math/mat4.js";import{create as h}from"../../../../core/libs/gl-matrix-2/factories/mat4f64.js";import{h as u,a}from"../../../../chunks/vec32.js";import{create as p}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{RenderCategory as f}from"../../webgl.js";import{debugFlags as c}from"../../support/debugFlags.js";import{glLayout as _}from"../../support/buffer/glUtil.js";import{newLayout as d}from"../../support/buffer/InterleavedLayout.js";import l from"../../webgl/RenderNode.js";import{Pos2Locations as m}from"./DefaultVertexBufferLayouts.js";import{VertexArrayObject as g}from"./VertexArrayObject.js";import{TaskPriority as x}from"../../../support/Scheduler.js";import{Yield as v}from"../../../support/Yield.js";import{DataType as b,PixelType as w}from"../../../webgl/enums.js";import{makePipelineState as y,defaultColorWrite as P}from"../../../webgl/renderState.js";import{Sync as T}from"../../../webgl/Sync.js";import
|
|
5
|
+
import{__decorate as t}from"tslib";import"../../../../core/has.js";import{disposeMaybe as e,destroyMaybe as i}from"../../../../core/maybe.js";import{property as r,subclass as o}from"../../../../core/accessorSupport/decorators.js";import{multiply as s,fromTranslation as n}from"../../../../core/libs/gl-matrix-2/math/mat4.js";import{create as h}from"../../../../core/libs/gl-matrix-2/factories/mat4f64.js";import{h as u,a}from"../../../../chunks/vec32.js";import{create as p}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{RenderCategory as f}from"../../webgl.js";import{debugFlags as c}from"../../support/debugFlags.js";import{glLayout as _}from"../../support/buffer/glUtil.js";import{newLayout as d}from"../../support/buffer/InterleavedLayout.js";import l from"../../webgl/RenderNode.js";import{Pos2Locations as m}from"./DefaultVertexBufferLayouts.js";import{VertexArrayObject as g}from"./VertexArrayObject.js";import{TaskPriority as x}from"../../../support/Scheduler.js";import{Yield as v}from"../../../support/Yield.js";import{DataType as b,PixelType as w}from"../../../webgl/enums.js";import{makePipelineState as y,defaultColorWrite as P}from"../../../webgl/renderState.js";import{Sync as T}from"../../../webgl/Sync.js";import j from"../../../webgl/Texture.js";import{TextureDescriptor as B}from"../../../webgl/TextureDescriptor.js";import{fromLayout as C}from"../../../webgl/VertexAttributeLocations.js";import{VertexBuffer as E}from"../../../webgl/VertexBuffer.js";let F=class extends l{constructor(t){super(t),this.category=f.COMPOSITE,this._debugVao=null,this._debugVaoLength=0,this.readyToRun=!1,this.done=!0,this._start=!1,this._origin=p(),this._textureWidth=256,this._uploadBuffer=new Float32Array(3*this._textureWidth),this._counter=0,this._width=0,this._height=0,this._pixelBufferSize=0,this._pipeline=y({colorWrite:P}),this._format=0}initialize(){const t=this.view.resourceController.scheduler.registerTask(x.GRAPHICS_CORE,this);this.addHandles(t),this.produces="disabled",this.consumes.required=[this.category],this.formatOverride&&(this._format=this.formatOverride)}destroy(){this._program=e(this._program),this._debugProgram=e(this._debugProgram),this._debugVao=e(this._debugVao);const t=this.gl;this._sync=i(this._sync),this._pixelBuffer&&(t.deleteBuffer(this._pixelBuffer),this._pixelBuffer=null,this._pixelBufferSize=0),this._texture=e(this._texture)}precompile(){this._ensureProgram(this.renderingContext)}render(t){const e=t.find(({name:t})=>t===this.category),i=this.renderingContext,r=this.gl,o=e.getTexture(r.DEPTH_STENCIL_ATTACHMENT),s=this.view.stage?.renderer.fboCache;if(!o||!s||this._sync||!this._start)return e;this._start=!1,this.produces=c.OCCLUSION_QUERY_DEBUG_PIXEL?this.category:"disabled";const n=s.acquire(this._width,this._height,"hud visibility",10);i.bindFramebuffer(n.fbo),i.setPipelineState(this._pipeline);const h=this._ensureProgram(i);return i.useProgram(h),L(h,this.camera,this._origin),i.bindTexture(o,0),h.setUniform1i("depthTex",0),i.bindTexture(this._texture,1),h.setUniform1i("positionTex",1),h.setUniform1i("count",this._counter),i.screen.draw(),this._pixelBuffer||(this._pixelBuffer=r.createBuffer()),0===this._format&&(this._format=6403===r.getParameter(r.IMPLEMENTATION_COLOR_READ_FORMAT)&&r.getParameter(r.IMPLEMENTATION_COLOR_READ_TYPE)===b.FLOAT?6403:6408),this._pixelBufferSize=this._width*this._height*(6403===this._format?4:16),r.bindBuffer(r.PIXEL_PACK_BUFFER,this._pixelBuffer),r.bufferData(r.PIXEL_PACK_BUFFER,this._pixelBufferSize,r.STREAM_READ),r.readPixels(0,0,this._width,this._height,this._format,b.FLOAT,0),this._sync=new T(r),n.release(),setTimeout(()=>this.readyToRun=!0,0),e}runTask(){if(!this._sync)return void(this.readyToRun=!1);try{if(!this._sync.poll())return v}catch(e){return this.readyToRun=!1,void(this._sync=i(this._sync))}this.readyToRun=!1,this._sync=i(this._sync);const t=this.gl;t.bindBuffer(t.PIXEL_PACK_BUFFER,this._pixelBuffer),this._cpuBuffer=new Float32Array(this._width*this._height*(6403===this._format?1:4)),t.getBufferSubData(t.PIXEL_PACK_BUFFER,0,this._cpuBuffer),t.bindBuffer(t.PIXEL_PACK_BUFFER,null),this.done=!0}init(t,e){const i=this._textureWidth;if(this._width=i,this._height=Math.ceil(t/i),this._counter=0,this._texture?.dispose(),0===this._height)return;const r=new B(this._width,this._height);r.pixelFormat=6407,r.dataType=w.FLOAT,r.samplingMode=9728,this._texture=new j(this.renderingContext,r),this.done=!1,u(this._origin,Math.fround(e[0]),Math.fround(e[1]),Math.fround(e[2]))}addPosition(t){const e=this._width;if(this._counter>=e*this._height)return-1;const i=this._counter%e;return a(M,t,this._origin),this._uploadBuffer[3*i+0]=M[0],this._uploadBuffer[3*i+1]=M[1],this._uploadBuffer[3*i+2]=M[2],i===e-1&&this._flush(),this._counter++}start(){if(0===this._width||0===this._height)return;const t=this._width;this._counter%t>0&&this._flush(),this.produces=this.category,this._start=!0,this.requestRender(1)}getOcclusion(t){return this._cpuBuffer?.[6403===this._format?t:4*t]??-1}get usedMemory(){return(this._texture?.usedMemory??0)+this._pixelBufferSize+4*(this._uploadBuffer?.length??0)+4*(this._cpuBuffer?.length??0)}_flush(){const t=this._width,e=Math.floor(this._counter/t);this._texture?.updateData(0,0,e,t,1,this._uploadBuffer)}_ensureProgram(t){return this._program??=t.programCache.acquire(D,O,m),this._program}_ensureDebugProgram(t){return this._debugProgram??=t.programCache.acquire(A,R,V),this._debugProgram}_ensureDebugVao(t,i){if(!this._debugVao||this._debugVaoLength<i){const r=new Float32Array(i);for(let t=0;t<i;t++)r[t]=t;this._debugVao=e(this._debugVao),this._debugVao=new g(t,new E(t,S,r))}return this._debugVao}};t([r()],F.prototype,"category",void 0),t([r()],F.prototype,"formatOverride",void 0),t([r()],F.prototype,"readyToRun",void 0),t([r()],F.prototype,"done",void 0),F=t([o("esri.views.3d.webgl-engine.lib.GPUPointOcclusionQuery")],F);const A="#version 300 es\nprecision highp float;\nprecision highp int;\n\nin highp float componentIndex;\n\nuniform highp mat4 proj;\nuniform highp mat4 view;\n\nuniform highp sampler2D positionTex;\n\nvoid main() {\n int width = textureSize(positionTex, 0).x;\n int u = int(componentIndex) % width;\n int v = int(componentIndex) / width;\n\n vec4 posWorld = vec4(texelFetch(positionTex, ivec2(u, v), 0).rgb, 1.0);\n vec4 posView = view * posWorld;\n vec4 projected = proj * posView;\n\n gl_Position = projected;\n gl_PointSize = 1.0;\n}",R="#version 300 es\nout highp vec4 fragColor;\nuniform lowp vec4 color;\nvoid main() {\n fragColor = color;\n}\n",D="#version 300 es\nprecision highp float;\nin vec2 position;\n\nvoid main() {\n gl_Position = vec4(position, 0.0, 1.0);\n}",O="#version 300 es\nprecision highp float;\nout highp vec4 fragColor;\n\nuniform highp mat4 proj;\nuniform highp mat4 view;\n\nuniform highp int count;\n\nuniform highp sampler2D depthTex;\nuniform highp sampler2D positionTex;\n\nfloat linearizeDepth(float depth) {\n float depthNdc = depth * 2.0 - 1.0;\n float c1 = proj[3][2];\n float c2 = proj[2][2];\n return -c1 / (depthNdc + c2 + 1e-7);\n}\n\nvoid main() {\n int u = int(floor(gl_FragCoord.x));\n int v = int(floor(gl_FragCoord.y));\n if (u + v * textureSize(positionTex, 0).x >= count) {\n fragColor = vec4(-1);\n return;\n }\n vec4 posWorld = vec4(texelFetch(positionTex, ivec2(u, v), 0).rgb, 1.0);\n vec4 posView = view * posWorld;\n vec4 projected = proj * posView;\n\n vec3 clipPos = projected.xyz / projected.w;\n\n if (clipPos.x < -1.0 || clipPos.x > 1.0 || clipPos.y < -1.0 || clipPos.y > 1.0) {\n fragColor = vec4(-1);\n return;\n }\n\n vec3 uvDepth = 0.5 * clipPos + vec3(0.5);\n\n float depth = texture(depthTex, uvDepth.xy).r;\n\n if (uvDepth.z <= depth) {\n fragColor = vec4(0);\n return;\n }\n\n fragColor = vec4(linearizeDepth(depth) - linearizeDepth(uvDepth.z));\n}\n";function L(t,e,i){s(I,e.viewMatrix,n(I,i)),t.setUniformMatrix4fv("view",I),t.setUniformMatrix4fv("proj",e.projectionMatrix)}const M=p(),I=h(),S=_(d().f32("componentIndex")),V=C(S);export{F as GPUPointOcclusionQuery};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import"../../../../core/has.js";import t from"../../../../core/Error.js";import{EventEmitter as e}from"../../../../core/Evented.js";import{disposeMaybe as r,removeMaybe as a}from"../../../../core/maybe.js";import{throwIfAborted as i,onAbort as s,createAbortError as o}from"../../../../core/promiseUtils.js";import{isUint8Array as n,isArrayBuffer as m,isTypedArray as l}from"../../../../core/typedArrayUtil.js";import{generateUID as h}from"../../../../core/uid.js";import{isBlobProtocol as d,isDataProtocol as p}from"../../../../core/urlUtils.js";import{whenVideoPlayable as _}from"../../../../layers/support/videoUtils.js";import{requestImage as u}from"../../../../request/image.js";import{loadImage as c}from"../../../../request/loadImage.js";import{createTextureKTX2 as g,createTextureBasis as x,estimateMemoryKTX2 as y,estimateMemoryBasis as f}from"./BasisUtil.js";import{createDDSTexture as F}from"./DDSUtil.js";import{ensureImageMaxSize as E}from"./textureUtils.js";import{assert as T}from"./Util.js";import
|
|
5
|
+
import"../../../../core/has.js";import t from"../../../../core/Error.js";import{EventEmitter as e}from"../../../../core/Evented.js";import{disposeMaybe as r,removeMaybe as a}from"../../../../core/maybe.js";import{throwIfAborted as i,onAbort as s,createAbortError as o}from"../../../../core/promiseUtils.js";import{isUint8Array as n,isArrayBuffer as m,isTypedArray as l}from"../../../../core/typedArrayUtil.js";import{generateUID as h}from"../../../../core/uid.js";import{isBlobProtocol as d,isDataProtocol as p}from"../../../../core/urlUtils.js";import{whenVideoPlayable as _}from"../../../../layers/support/videoUtils.js";import{requestImage as u}from"../../../../request/image.js";import{loadImage as c}from"../../../../request/loadImage.js";import{createTextureKTX2 as g,createTextureBasis as x,estimateMemoryKTX2 as y,estimateMemoryBasis as f}from"./BasisUtil.js";import{createDDSTexture as F}from"./DDSUtil.js";import{ensureImageMaxSize as E}from"./textureUtils.js";import{assert as T}from"./Util.js";import D from"../../../webgl/Texture.js";import{TextureDescriptor as w}from"../../../webgl/TextureDescriptor.js";import{getFormatComponents as A}from"../../../webgl/Util.js";class M{constructor(t,r){this._data=t,this.id=h(),this.events=new e,this._parameters={...L,...r},this._startPreload(t)}dispose(){this.unload(),this._data=this.update=void 0}_startPreload(t){t instanceof HTMLVideoElement?(this.update=e=>this._update(t,e),this._startPreloadVideoElement(t)):t instanceof HTMLImageElement&&this._startPreloadImageElement(t)}_startPreloadVideoElement(t){if(!(d(t.src)||"auto"===t.preload&&t.crossOrigin)&&(t.preload="auto",t.crossOrigin="anonymous",t.src=t.src,t.paused&&t.autoplay)){const e=[];_(t,t=>e.push(t)).then(()=>{t.play()}).finally(()=>e.forEach(t=>t.remove()))}}_startPreloadImageElement(t){p(t.src)||d(t.src)||t.crossOrigin||(t.crossOrigin="anonymous",t.src=t.src)}_createDescriptor(t){const e=new w;return e.wrapMode=this._parameters.wrap??10497,e.flipped=!this._parameters.noUnpackFlip,e.samplingMode=this._parameters.mipmap?9987:9729,e.hasMipmap=!!this._parameters.mipmap,e.preMultiplyAlpha=!!this._parameters.preMultiplyAlpha,e.maxAnisotropy=this._parameters.maxAnisotropy??(this._parameters.mipmap?t.parameters.maxMaxAnisotropy:1),e.dataType=this._parameters.dataType??e.dataType,e.pixelFormat=this._parameters.pixelFormat??e.pixelFormat,e.internalFormat=this._parameters.internalFormat??e.internalFormat,e}get texture(){return this._texture??this._emptyTexture}get loaded(){return null!=this._texture}get usedMemory(){return this._texture?.usedMemory||v(this._data,this._parameters)}load(t){if(this._loadingPromise)return this._loadingPromise;if(this._texture)return this._texture;const e=this._data;return null==e?(this._texture=new D(t,this._createDescriptor(t),null),this._texture):(this._emptyTexture=t.emptyTexture,this._parameters.reloadable||(this._data=void 0),"string"==typeof e?this._loadFromURL(t,e):e instanceof Image?this._loadFromImageElement(t,e):e instanceof HTMLVideoElement?this._loadFromVideoElement(t,e):e instanceof ImageData||e instanceof HTMLCanvasElement?this._loadFromImage(t,e):n(e)&&"image/vnd-ms.dds"===this._parameters.encoding?this._loadFromDDSData(t,e):m(e)&&"image/vnd-ms.dds"===this._parameters.encoding?this._loadFromDDSData(t,new Uint8Array(e)):(m(e)||n(e))&&"image/ktx2"===this._parameters.encoding?this._loadFromKTX2(t,e):(m(e)||n(e))&&"image/x.basis"===this._parameters.encoding?this._loadFromBasis(t,e):m(e)?this._loadFromPixelData(t,new Uint8Array(e)):l(e)?this._loadFromPixelData(t,e):null)}_update(t,e){return null==this._texture||t.readyState<HTMLMediaElement.HAVE_CURRENT_DATA||e===t.currentTime?e:(this._texture.setData(t),this._texture.descriptor.hasMipmap&&this._texture.generateMipmap(),this._parameters.updateCallback&&this._parameters.updateCallback(),t.currentTime)}_loadFromDDSData(t,e){return this._texture=F(t,this._createDescriptor(t),e),this._emptyTexture=null,this._texture}_loadFromKTX2(t,e){return this._loadAsync(()=>g(t,this._createDescriptor(t),e).then(t=>(this._texture=t,t)))}_loadFromBasis(t,e){return this._loadAsync(()=>x(t,this._createDescriptor(t),e).then(t=>(this._texture=t,t)))}_loadFromPixelData(t,e){T(this._parameters.width>0&&this._parameters.height>0);const r=this._createDescriptor(t);return 6407!==r.pixelFormat&&6408!==r.pixelFormat||(r.compress=this._parameters.compressionOptions),r.width=this._parameters.width??0,r.height=this._parameters.height??0,this._texture=new D(t,r,e),this._texture}_loadFromURL(t,e){return this._loadAsync(async r=>{const a=await u(e,{signal:r});return i(r),this._loadFromImage(t,a)})}_loadFromImageElement(t,e){return e.complete?this._loadFromImage(t,e):this._loadAsync(async r=>{const a=await c(e,e.src,!1,r);return i(r),this._loadFromImage(t,a)})}_loadFromVideoElement(t,e){return e.readyState>=HTMLMediaElement.HAVE_CURRENT_DATA?this._loadFromImage(t,e):this._loadFromVideoElementAsync(t,e)}_loadFromVideoElementAsync(e,r){return this._loadAsync(i=>new Promise((n,m)=>{const l=()=>{r.removeEventListener("loadeddata",h),r.removeEventListener("error",d),a(p)},h=()=>{r.readyState>=HTMLMediaElement.HAVE_CURRENT_DATA&&(l(),n(this._loadFromImage(e,r)))},d=e=>{l(),m(e||new t("texture:load-error","Failed to load video"))};r.addEventListener("loadeddata",h),r.addEventListener("error",d);const p=s(i,()=>d(o()))}))}_loadFromImage(t,e){let r=e;r instanceof HTMLVideoElement||(r=E(r,t.parameters));const a=j(r);this._parameters.width=a.width,this._parameters.height=a.height;const i=this._createDescriptor(t);return i.width=a.width,i.height=a.height,i.compress=this._parameters.compressionOptions,this._texture=new D(t,i,r),this._emptyTexture=null,this.events.emit("loaded"),this._texture}_loadAsync(t){const e=new AbortController;this._loadingController=e;const r=t(e.signal);this._loadingPromise=r;const a=()=>{this._loadingController===e&&(this._loadingController=null),this._loadingPromise===r&&(this._loadingPromise=null),this._emptyTexture=null};return r.then(a,a),r}unload(){if(this._texture=r(this._texture),this._emptyTexture=null,null!=this._loadingController){const t=this._loadingController;this._loadingController=null,this._loadingPromise=null,t.abort()}this.events.emit("unloaded")}get parameters(){return this._parameters}}function v(t,e){if(null==t)return 0;if(m(t)||n(t))return"image/ktx2"===e.encoding?y(t,!!e.mipmap):"image/x.basis"===e.encoding?f(t,!!e.mipmap):t.byteLength;const{width:r,height:a}=t instanceof Image||t instanceof ImageData||t instanceof HTMLCanvasElement||t instanceof HTMLVideoElement?j(t):e,i=e.pixelFormat??6408,s=A(i);return(e.mipmap?4/3:1)*r*a*s||0}function j(t){return t instanceof HTMLVideoElement?{width:t.videoWidth,height:t.videoHeight}:t}const L={wrap:{s:10497,t:10497},mipmap:!0,noUnpackFlip:!1,preMultiplyAlpha:!1};export{M as ManagedTexture};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as e}from"tslib";import t from"../../../../core/Accessor.js";import{EventEmitter as s}from"../../../../core/Evented.js";import"../../../../core/has.js";import{disposeMaybe as i,removeMaybe as r}from"../../../../core/maybe.js";import{generateUID as h}from"../../../../core/uid.js";import{property as n,subclass as a}from"../../../../core/accessorSupport/decorators.js";import{a as o,c as l}from"../../../../chunks/vec42.js";import{ZEROS as _,create as c}from"../../../../core/libs/gl-matrix-2/factories/vec4f64.js";import{textTextureAtlas as d}from"./testUtils.js";import{applyTextureResizeModuloCeil as u}from"./textureUtils.js";import{TaskPriority as m}from"../../../support/Scheduler.js";import{Yield as f}from"../../../support/Yield.js";import
|
|
5
|
+
import{__decorate as e}from"tslib";import t from"../../../../core/Accessor.js";import{EventEmitter as s}from"../../../../core/Evented.js";import"../../../../core/has.js";import{disposeMaybe as i,removeMaybe as r}from"../../../../core/maybe.js";import{generateUID as h}from"../../../../core/uid.js";import{property as n,subclass as a}from"../../../../core/accessorSupport/decorators.js";import{a as o,c as l}from"../../../../chunks/vec42.js";import{ZEROS as _,create as c}from"../../../../core/libs/gl-matrix-2/factories/vec4f64.js";import{textTextureAtlas as d}from"./testUtils.js";import{applyTextureResizeModuloCeil as u}from"./textureUtils.js";import{TaskPriority as m}from"../../../support/Scheduler.js";import{Yield as f}from"../../../support/Yield.js";import p from"../../../webgl/Texture.js";import{TextureDescriptor as x}from"../../../webgl/TextureDescriptor.js";const g=4096;let v=class extends t{constructor(e){super(e),this.id=h(),this.events=new s,this._texture=null,this._atlas=new R(256,256),this._needsRepack=!1,this._canRepack=!0,this._elementsToRender=new Map,this._elements=new Map,this._uvCallbacks=new Map,this.updating=!1}initialize(){this._canvas=document.createElement("canvas"),this._canvas.setAttribute("id","textAtlasCanvas"),this._canvas.setAttribute("style","display:none"),this._ctx=this._canvas.getContext("2d"),this._stage=this.view.stage,this._stage.addTexture(this),this._updateCanvasElementSize(this._atlas),this._reset()}unload(){this._texture=i(this._texture),this._frameWorker=r(this._frameWorker),this.updating=!1,this.events.emit("unloaded")}get loaded(){return null!=this._texture}get texture(){return this._texture}static get maxSize(){return b=d.stableRendering?w:0,[g-w-b,g-w-b-k]}load(e){if(this._texture)return this._texture;const t=new x;return t.wrapMode=33071,t.samplingMode=9987,t.hasMipmap=!0,t.preMultiplyAlpha=!0,t.maxAnisotropy=e.parameters.maxMaxAnisotropy,this._texture=new p(e,t,this._canvas),this._frameWorker=this.view.resourceController.scheduler.registerTask(m.TEXT_TEXTURE_ATLAS,this),this.setDirty(),this._texture}dispose(){this._elements.clear(),this._elementsToRender.clear(),this._frameWorker=r(this._frameWorker),this._texture&&(this._stage.removeTexture(this),this._texture=i(this._texture)),this._canvas.width=0,this._canvas.height=0,this._canvas=null,this._ctx=null}_updateCanvasElementSize(e){this._canvas.width=e.width,this._canvas.height=e.height}_resizeAtlas(e,t){const{width:s,height:i}=this._atlas;s===e&&i===t||(this._atlas.width=e,this._atlas.height=t,this._texture?.resize(e,t),this._texture?.updateData(0,0,0,s,i,this._canvas),this._updateCanvasElementSize(this._atlas),this._elements.forEach(e=>this._uvCallbacks.get(e.textRenderer.key)?.forEach(t=>t(e.uv))),this._reset())}_reset(){this._elementsToRender.clear(),this._atlas.reset(),this._needsRepack=!0,this.setDirty()}_addAtlasElement(e,t,s,i){const r=this._atlas;if(r.width<s||r.height<i)return!1;let h=r.cursors.get(i);if(!h){if(r.height<r.nextY+i)return!1;h=[new T(r.nextY)],r.cursors.set(i,h),r.nextY+=i}let n=h.find(e=>r.width>=e.x+s);if(null==n){if(r.height<r.nextY+i)return!1;n=new T(r.nextY),r.nextY+=i,h.push(n)}return e.setNewPosition(n),this._elements.set(t,e),this._elementsToRender.set(t,e),n.x+=s,!0}_ensureCallbacks(e){const t=this._uvCallbacks.get(e);if(t)return t;const s=new Set;return this._uvCallbacks.set(e,s),s}_addCallback(e,t){this._ensureCallbacks(e).add(t)}_removeCallback(e,t){const s=this._uvCallbacks.get(e);return!(!s?.delete(t)||0!==s.size)&&(this._uvCallbacks.delete(e),!0)}_processAddition(e){const t=e.textRenderer.key;if(this._needsRepack)return void this._elements.set(t,e);const s=this._atlas,i=e.textRenderer.renderedWidth,r=e.textRenderer.renderedHeight,h=i+w,n=r+w+k;if(!this._addAtlasElement(e,t,h,n)){if(this._canRepack)this._reset();else if(s.width<h){const e=u(Math.max(h,1.5*s.width),g);this._resizeAtlas(e,s.height)}else{const e=s.nextY+n,t=u(Math.max(e,1.5*s.height),g);if(t>s.height)this._resizeAtlas(s.width,t);else if(s.width<g){const e=u(1.5*s.width,g);this._resizeAtlas(e,s.height)}}this._elements.set(t,e)}}_renderElement(e){const t=e.commitNewPosition(),s=e.textRenderer;this._ctx.clearRect(t[0]-w,t[1]-w,s.renderedWidth+2*w,s.renderedHeight+2*w),s.render(this._ctx,t[0],t[1]),this._uvCallbacks.get(s.key)?.forEach(t=>t(e.uv))}get readyToRun(){return this.updating}runTask(e){if(null==this._texture)return f;for(;this._needsRepack&&(this._canRepack||this._atlas.height<g&&this._atlas.height<g);){this._canRepack=this._needsRepack=!1;const t=this._elements;this._elements=new Map,t.forEach(e=>this._processAddition(e)),e.madeProgress()}if(this._elementsToRender.size>0){for(const[t,s]of this._elementsToRender){if(e.done)break;this._renderElement(s),this._elementsToRender.delete(t),e.madeProgress()}this._texture.setData(this._canvas)}this.updating=this._elementsToRender.size>0}addText(e,t){const s=e.key;this._addCallback(s,t);let i=this._elements.get(s);return i?o(i.uv,_)||t(i.uv):(i=new y(e),this._processAddition(i),this.setDirty()),{remove:()=>this._removeText(e,t)}}_removeText(e,t){const s=e.key;this._elements.get(s)&&this._removeCallback(s,t)&&(this._elements.delete(s),this._elementsToRender.delete(s),this._canRepack=!0)}setDirty(){this._texture&&(this.updating=!0)}get test(){}get usedMemory(){return(this._texture?.usedMemory??0)+(this._canvas?.width??0)*(this._canvas?.height??0)*4}};e([n({constructOnly:!0})],v.prototype,"view",void 0),e([n({type:Boolean})],v.prototype,"updating",void 0),v=e([a("esri.views.3d.webgl-engine.lib.TextTextureAtlas")],v);const w=2,k=2;class y{constructor(e){this.textRenderer=e,this._uv=c(),this._newPosition=[0,0]}get uv(){if(null==this._xOffset||null==this._yOffset)return _;const{renderedWidth:e,renderedHeight:t}=this.textRenderer;return l(this._uv,this._xOffset,this._yOffset+t,this._xOffset+e,this._yOffset)}setNewPosition(e){this._newPosition[0]=e.x,this._newPosition[1]=e.y}commitNewPosition(){return this._xOffset=this._newPosition[0],this._yOffset=this._newPosition[1],this._newPosition}get xOffset(){return this._xOffset}get yOffset(){return this._yOffset}}class R{constructor(e,t){this.width=e,this.height=t,this.cursors=new Map,this.nextY=0}reset(){this.cursors.clear(),this.nextY=b}}class T{constructor(e){this.y=e,this.x=b}}let b=0;export{v as TextTextureAtlas};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{getMaxItemCount as t,getItemsRectangle as e}from"./TextureBackedBufferUtils.js";import{SizedPixelFormat as r,PixelType as o}from"../../../../webgl/enums.js";import
|
|
5
|
+
import{getMaxItemCount as t,getItemsRectangle as e}from"./TextureBackedBufferUtils.js";import{SizedPixelFormat as r,PixelType as o}from"../../../../webgl/enums.js";import i from"../../../../webgl/Texture.js";import{TextureDescriptor as s}from"../../../../webgl/TextureDescriptor.js";class a{constructor(a,n,u){this.layout=n;const l="number"!=typeof u,m=l?Math.floor(u.byteLength/n.byteStride):u;if(m>t(a,n))throw new Error(`Cannot allocate TextureBuffer for ${m}. Exceeding hardware texture limits`);const{itemCount:h,itemWidth:d,itemHeight:f}=e(m),{texelStride:p,byteStride:c}=this.layout,x=d*p,y=f;this.itemCount=h,this.byteLength=h*c;const w=new s(x,y);w.samplingMode=9728,w.wrapMode=33071,w.internalFormat=r.RGBA8UI,w.pixelFormat=36249,w.dataType=o.UNSIGNED_BYTE,w.isImmutable=!0,w.hasMipmap=!1,this.texture=new i(a,w),l&&this.setSubData(u)}setSubData(t,e=0,r=0,o=Math.floor((t.byteLength-r)/this.layout.byteStride)){if(0===o)return;const{layout:i,texture:s}=this,{texelStride:a,texelByteStride:n}=i,{width:u}=s.descriptor;if(e+o>this.itemCount)throw new Error("Upload range is outside of texture");const l=e*a,m=o*a,h=Math.floor(l/u),d=l%u,f=(u-d)%u,p=m-f,c=Math.floor(p/u),x=p%u,y=0===d?h:h+1;if(0!==d){const e=new i.texelElementArrayConstructor(t,r);s.updateData(0,d,h,f,1,e)}if(c>0){const e=r+f*n,o=new i.texelElementArrayConstructor(t,e);s.updateData(0,0,y,u,c,o)}if(x>0){const e=r+(m-x)*n,o=y+c,a=new i.texelElementArrayConstructor(t,e);s.updateData(0,0,o,x,1,a)}}dispose(){this.texture.dispose()}}export{a as TextureBuffer};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{disposeMaybe as e}from"../../../../../core/maybe.js";import{PixelType as t,SizedPixelFormat as s}from"../../../../webgl/enums.js";import{Texture as r}from"../../../../webgl/Texture.js";import{TextureDescriptor as n}from"../../../../webgl/TextureDescriptor.js";function o(e){const o=c.resolution,l=o/2,u=new Float32Array(o*o),p=o*l,m=c.amplitude,h=o,d=Math.log2(o)+1,f=c.strokes.length;let g=(d-1)*f*h;for(const{distance:t,pressure:s}of c.strokes){let e=t,r=s,n=g;for(let t=0;t<d;t++){0!==t&&(e=i(e,0),r=i(r,1));for(let t=0;t<c.resolution;t++){const s=e[t%e.length],o=r?.[t%r.length]??1;u[n]=s,u[n+p]=o,++n}n-=h*(f+1)}g+=h}const w=new n(o);w.dataType=t.FLOAT,w.pixelFormat=6403,w.internalFormat=s.R16F;const x=new r(e,w,u);return new a(o,m,f,x)}function i(e,t){if(!e)return null;const s=e.length/2,r=l*s,n=new Array(s);let o=0;const i=1===t;for(let l=0;l<e.length;l+=2){const t=(e[l]+e[l+1])/2;n[o++]=i?Math.min(r,1-(1-t)*u):Math.min(r,t*u)}return n}const l=.1,u=.5;class a{constructor(e,t,s,r){this.resolution=e,this.amplitude=t,this.variants=s,this.texture=r}dispose(){this.texture=e(this.texture)}}const c={amplitude:8,resolution:256,strokes:[{distance:[-1.59027,-1.59426,-1.59674,-1.59766,-1.59702,-1.59479,-1.59095,-1.5855,-1.57843,-1.56973,-1.55942,-1.5475,-1.53398,-1.5189,-1.50226,-1.4841,-1.46446,-1.44337,-1.42088,-1.39703,-1.37188,-1.34547,-1.31786,-1.28912,-1.2593,-1.22847,-1.19668,-1.16402,-1.13053,-1.09629,-1.06137,-1.02582,-.98972,-.95313,-.91611,-.87872,-.84102,-.80306,-.76488,-.72654,-.68807,-.64952,-.61092,-.57232,-.53375,-.49527,-.45692,-.41874,-.38078,-.34309,-.3057,-.26867,-.23204,-.19585,-.16015,-.12497,-.09036,-.05634,-.02296,.00977,.04183,.07321,.10389,.13386,.16313,.19169,.21956,.24672,.27321,.299,.32413,.34858,.37237,.3955,.41798,.43981,.461,.48154,.50145,.52073,.53939,.55744,.57488,.5917,.6079,.62347,.63837,.65259,.66609,.67885,.69083,.70201,.71235,.72183,.73042,.73812,.7449,.75076,.7557,.75973,.76284,.76507,.76642,.76692,.76659,.76545,.76352,.76083,.7574,.75324,.74837,.74279,.73652,.72959,.72199,.71377,.70493,.69553,.68558,.67515,.66426,.65298,.64135,.62944,.6173,.60499,.59257,.58008,.56759,.55513,.54275,.5305,.51842,.50654,.4949,.48353,.47246,.4617,.45128,.44121,.43149,.42213,.41313,.40448,.39617,.38818,.3805,.37309,.36594,.35902,.35229,.34572,.33927,.33292,.32663,.32035,.31407,.30774,.30135,.29486,.28824,.28148,.27454,.26739,.26002,.25241,.24454,.23639,.22796,.21922,.21016,.20076,.19098,.18082,.17023,.1592,.14768,.13566,.1231,.10996,.09624,.08188,.06688,.05121,.03485,.01778,0,-.0185,-.03771,-.05763,-.07824,-.09952,-.12144,-.14396,-.16706,-.19069,-.21481,-.23938,-.26436,-.28971,-.31539,-.34136,-.36759,-.39404,-.42067,-.44746,-.47437,-.50136,-.52839,-.55544,-.58248,-.60948,-.63642,-.66329,-.6901,-.71684,-.74352,-.77015,-.79675,-.82332,-.84988,-.87644,-.90301,-.92958,-.95615,-.98272,-1.00926,-1.03575,-1.06217,-1.08847,-1.11463,-1.1406,-1.16633,-1.19178,-1.2169,-1.24164,-1.26595,-1.28979,-1.31312,-1.3359,-1.35809,-1.37963,-1.4005,-1.42064,-1.44,-1.45853,-1.47616,-1.49285,-1.50853,-1.52313,-1.53659,-1.54886,-1.55986,-1.56955,-1.57788,-1.5848],pressure:[-.01365,-.00206,.01025,.02327,.03696,.05129,.06619,.08163,.09755,.11393,.1307,.14784,.16531,.18308,.20111,.21938,.23786,.25651,.2753,.29419,.31315,.33215,.35115,.37015,.38913,.40806,.42694,.44576,.46449,.48313,.50167,.5201,.53839,.55653,.57448,.59222,.60971,.62692,.6438,.66033,.67648,.69221,.70753,.72242,.73688,.75093,.76456,.77779,.79063,.80309,.81517,.82686,.83817,.84911,.85967,.86987,.87972,.88924,.89845,.90734,.91594,.92425,.93229,.94005,.94754,.95475,.96166,.96826,.97451,.9804,.98588,.99092,.99549,.99957,.99685,.99381,.99131,.98936,.98796,.98711,.98681,.98706,.98787,.98923,.99113,.99357,.99654,1,.99607,.99171,.98695,.98181,.97634,.97057,.96452,.95824,.95175,.94506,.93818,.93113,.92389,.91647,.90887,.90109,.89314,.88501,.87672,.86831,.85978,.85119,.84256,.83393,.82533,.8168,.80836,.80002,.79181,.78374,.77582,.7681,.76059,.75331,.74629,.73955,.73311,.72697,.72116,.71568,.71054,.70572,.70121,.697,.69304,.68931,.68576,.68236,.67905,.67582,.67262,.66941,.66619,.66291,.65957,.65613,.65259,.64892,.6451,.6411,.6369,.63248,.62783,.62295,.61783,.61247,.60688,.60104,.59498,.58868,.58216,.57542,.56845,.56125,.5538,.5461,.53813,.52986,.52129,.51239,.50316,.49359,.4837,.47349,.46299,.45223,.44124,.43005,.41869,.40719,.39557,.38386,.37207,.36023,.34836,.33648,.32464,.31287,.30119,.28963,.27822,.26698,.25594,.2451,.23448,.22409,.21391,.20394,.19415,.18452,.17503,.16565,.15636,.14713,.13794,.1288,.11968,.11058,.10151,.09247,.08346,.07447,.06552,.05659,.0477,.03885,.03007,.02137,.01278,.00433,-.00393,-.012,-.01983,-.02738,-.03463,-.04155,-.0481,-.05429,-.0601,-.06553,-.07057,-.07524,-.07954,-.08347,-.08703,-.09022,-.09303,-.09544,-.09744,-.09898,-.10004,-.10059,-.1006,-.10005,-.09892,-.0972,-.09487,-.09192,-.08833,-.08409,-.07918,-.07357,-.06724,-.06019,-.0524,-.04386,-.03455,-.02448]},{distance:[-3.46259,-3.47131,-3.47668,-3.47863,-3.47712,-3.4721,-3.46352,-3.45138,-3.43566,-3.41635,-3.39347,-3.36704,-3.33709,-3.30368,-3.26684,-3.22667,-3.18322,-3.1366,-3.08689,-3.0342,-2.97865,-2.92036,-2.85946,-2.79607,-2.73034,-2.66241,-2.59242,-2.52052,-2.44686,-2.37159,-2.29485,-2.2168,-2.13757,-2.05731,-1.97616,-1.89426,-1.81174,-1.72875,-1.64543,-1.56191,-1.47833,-1.39483,-1.3115,-1.22847,-1.14581,-1.06361,-.98193,-.90083,-.82036,-.74054,-.66141,-.583,-.50532,-.4284,-.35228,-.277,-.20261,-.12916,-.05672,.01463,.08485,.15384,.22153,.28784,.35269,.41602,.47776,.53787,.59629,.653,.70799,.76123,.81274,.86253,.9106,.95698,1.0017,1.04477,1.0862,1.126,1.16415,1.20065,1.23546,1.26857,1.29994,1.32953,1.35731,1.38321,1.40719,1.42921,1.44922,1.46719,1.48309,1.49691,1.50862,1.51825,1.52581,1.53133,1.53486,1.53644,1.53616,1.53409,1.53031,1.52493,1.51803,1.50972,1.50009,1.48924,1.47725,1.46421,1.45019,1.43527,1.4195,1.40295,1.38568,1.36778,1.34929,1.3303,1.31087,1.29108,1.27099,1.25066,1.23018,1.2096,1.18898,1.16838,1.14785,1.12745,1.10721,1.08719,1.06741,1.04791,1.02871,1.00986,.99136,.97324,.95551,.93819,.92127,.90476,.88866,.87296,.85767,.84277,.82823,.81406,.80022,.7867,.77346,.76049,.74774,.73519,.72278,.71049,.69827,.68606,.67381,.66145,.64893,.63618,.62313,.60973,.5959,.5816,.56675,.5513,.53516,.51826,.50053,.4819,.46231,.44169,.42002,.39725,.37336,.34834,.32219,.2949,.2665,.23698,.20638,.17469,.14193,.10809,.07316,.03714,0,-.03827,-.07772,-.11836,-.16022,-.20332,-.24768,-.29332,-.34024,-.38844,-.43788,-.48854,-.54036,-.59329,-.64724,-.70211,-.75782,-.81425,-.87128,-.92881,-.98674,-1.04498,-1.10346,-1.1621,-1.22086,-1.27969,-1.33854,-1.3974,-1.45625,-1.51511,-1.57396,-1.63283,-1.69173,-1.75067,-1.80968,-1.86875,-1.9279,-1.98712,-2.04639,-2.10568,-2.16495,-2.22416,-2.28322,-2.34208,-2.40063,-2.4588,-2.51647,-2.57354,-2.62989,-2.68543,-2.74002,-2.79357,-2.84597,-2.89711,-2.94689,-2.99521,-3.04195,-3.087,-3.13023,-3.17152,-3.21075,-3.24779,-3.28252,-3.3148,-3.34451,-3.37154,-3.39577,-3.41709,-3.43539,-3.45059],pressure:[.87183,.87151,.87129,.87118,.87117,.87128,.87149,.87182,.87225,.8728,.87347,.87424,.87513,.87613,.87723,.87845,.87978,.88122,.88276,.88441,.88616,.88801,.88996,.892,.89414,.89637,.89868,.90108,.90356,.90611,.90874,.91144,.91421,.91704,.91993,.92287,.92587,.92892,.93201,.93514,.93831,.94151,.94474,.94799,.95126,.95456,.95786,.96118,.9645,.96783,.97116,.97448,.9778,.98111,.98441,.9877,.99096,.99421,.99742,.99938,.99622,.9931,.99001,.98697,.98397,.98101,.97811,.97526,.97246,.96972,.96703,.96441,.96185,.95935,.95691,.95455,.95225,.95002,.94786,.94577,.94376,.94182,.93995,.93817,.93646,.93483,.93328,.93181,.93042,.92911,.92788,.92673,.92566,.92467,.92376,.92293,.92217,.92149,.92088,.92034,.91987,.91947,.91913,.91886,.91864,.91849,.91838,.91833,.91834,.91839,.91849,.91863,.91883,.91907,.91935,.91968,.92005,.92046,.92092,.92142,.92195,.92253,.92314,.9238,.92449,.92521,.92598,.92677,.9276,.92847,.92936,.93029,.93125,.93224,.93325,.9343,.93537,.93646,.93758,.93872,.93988,.94106,.94225,.94346,.94469,.94593,.94718,.94844,.94971,.95098,.95226,.95354,.95482,.9561,.95738,.95867,.95995,.96122,.9625,.96377,.96504,.9663,.96757,.96883,.97009,.97135,.97261,.97387,.97513,.9764,.97767,.97895,.98023,.98153,.98284,.98416,.98549,.98684,.98821,.9896,.99101,.99244,.99389,.99537,.99688,.99842,1,.99839,.99675,.99508,.99336,.99161,.98982,.98799,.98613,.98422,.98228,.98029,.97827,.97622,.97414,.97202,.96987,.9677,.96551,.9633,.96107,.95882,.95656,.9543,.95202,.94975,.94747,.94519,.94292,.94065,.93838,.93613,.93388,.93164,.92941,.9272,.92499,.9228,.92062,.91846,.91631,.91418,.91207,.90998,.90792,.90588,.90387,.90189,.89995,.89804,.89617,.89434,.89256,.89083,.88914,.88752,.88595,.88443,.88299,.88161,.8803,.87907,.87791,.87683,.87584,.87494,.87412,.8734,.87278,.87225]},{distance:[.39335,.43437,.47737,.52234,.56923,.61801,.66864,.72109,.7753,.83123,.88882,.94801,1.00875,1.07097,1.13461,1.1996,1.26586,1.33333,1.40193,1.47158,1.54221,1.61373,1.68607,1.75913,1.83284,1.90711,1.98186,2.05699,2.13243,2.20809,2.28387,2.35971,2.4355,2.51117,2.58663,2.66179,2.73658,2.81092,2.88473,2.95792,3.03043,3.10217,3.17308,3.24309,3.31211,3.3801,3.44697,3.51267,3.57712,3.64028,3.70208,3.76247,3.8214,3.87881,3.93467,3.98892,4.04152,4.09244,4.14164,4.18908,4.23474,4.27859,4.32061,4.36077,4.39905,4.43544,4.46992,4.50249,4.53314,4.56185,4.58864,4.61349,4.63642,4.65745,4.67657,4.69381,4.7092,4.72274,4.73447,4.74441,4.75259,4.75903,4.76376,4.76682,4.76822,4.768,4.76618,4.76279,4.75786,4.75142,4.74348,4.73409,4.72326,4.71102,4.69739,4.68241,4.6661,4.64849,4.6296,4.60948,4.58816,4.56567,4.54204,4.51732,4.49154,4.46473,4.43694,4.4082,4.37854,4.348,4.31662,4.28443,4.25145,4.21773,4.1833,4.14819,4.11243,4.07606,4.03912,4.00162,3.96361,3.92512,3.88618,3.84683,3.80708,3.76697,3.72653,3.68579,3.64478,3.60351,3.56202,3.52033,3.47845,3.43642,3.39425,3.35196,3.30957,3.2671,3.22455,3.18196,3.13933,3.09668,3.05402,3.01136,2.96873,2.92613,2.88357,2.84108,2.79865,2.75631,2.71407,2.67195,2.62994,2.58807,2.54634,2.50477,2.46338,2.42216,2.38114,2.34032,2.29971,2.25933,2.21916,2.17923,2.13954,2.10008,2.06087,2.02189,1.98316,1.94468,1.90644,1.86845,1.83069,1.79316,1.75586,1.71877,1.68189,1.6452,1.60868,1.57232,1.53611,1.50004,1.46407,1.4282,1.39241,1.35668,1.321,1.28535,1.24972,1.2141,1.17849,1.14286,1.10723,1.07158,1.03593,1.00028,.96464,.92902,.89344,.85793,.8225,.78719,.75203,.71705,.68231,.64784,.61369,.57991,.54656,.51368,.48134,.44959,.41849,.3881,.35848,.32967,.30174,.27474,.24872,.22373,.19982,.17702,.15539,.13497,.11579,.09791,.08137,.06621,.05248,.04022,.02948,.02029,.01271,.00677,.00252,0,-76e-5,27e-5,.00314,.00788,.01451,.02307,.03357,.04604,.0605,.07697,.09546,.11599,.13858,.16322,.18992,.21869,.24952,.28241,.31735,.35434],pressure:[.95248,.95236,.95228,.95223,.95222,.95224,.95231,.95241,.95256,.95274,.95296,.95322,.95352,.95385,.95423,.95465,.9551,.9556,.95613,.9567,.95731,.95796,.95864,.95936,.96012,.96091,.96173,.96259,.96348,.9644,.96535,.96633,.96734,.96838,.96944,.97053,.97164,.97277,.97393,.9751,.97629,.9775,.97873,.97997,.98122,.98249,.98376,.98505,.98634,.98763,.98893,.99023,.99154,.99284,.99414,.99544,.99673,.99802,.9993,.99942,.99816,.99691,.99568,.99445,.99324,.99205,.99087,.98972,.98858,.98746,.98636,.98528,.98423,.9832,.98219,.98121,.98025,.97931,.9784,.97752,.97666,.97582,.97501,.97423,.97347,.97274,.97203,.97135,.9707,.97007,.96948,.9689,.96836,.96784,.96735,.96689,.96646,.96605,.96567,.96533,.965,.96471,.96445,.96421,.964,.96382,.96367,.96355,.96346,.96339,.96335,.96334,.96336,.9634,.96348,.96358,.9637,.96385,.96403,.96423,.96446,.96471,.96499,.96529,.96561,.96595,.96631,.96669,.96709,.96751,.96795,.9684,.96887,.96935,.96984,.97035,.97087,.9714,.97194,.97249,.97304,.97361,.97418,.97476,.97534,.97592,.97651,.97711,.9777,.9783,.9789,.9795,.9801,.9807,.9813,.9819,.9825,.98309,.98369,.98428,.98486,.98545,.98603,.98661,.98718,.98775,.98832,.98888,.98944,.99,.99056,.99112,.99167,.99223,.99279,.99335,.99392,.99449,.99507,.99565,.99624,.99684,.99745,.99807,.9987,.99934,1,.99933,.99866,.99797,.99727,.99656,.99583,.9951,.99435,.99359,.99283,.99205,.99126,.99046,.98966,.98885,.98803,.9872,.98637,.98554,.9847,.98387,.98303,.98219,.98134,.9805,.97967,.97883,.978,.97717,.97634,.97552,.97471,.97389,.97309,.97229,.9715,.97071,.96993,.96915,.96838,.96762,.96687,.96612,.96539,.96466,.96395,.96324,.96255,.96187,.9612,.96055,.95991,.95929,.95869,.95811,.95754,.957,.95648,.95599,.95552,.95508,.95467,.95428,.95393,.9536,.95331,.95305,.95283,.95264]},{distance:[2.85606,2.86149,2.86432,2.8645,2.862,2.85686,2.84912,2.83886,2.82618,2.81117,2.79393,2.77456,2.75314,2.72975,2.70447,2.67734,2.64844,2.61784,2.58564,2.55196,2.5169,2.48057,2.44305,2.40438,2.36462,2.32383,2.28208,2.23943,2.19591,2.15153,2.10628,2.06016,2.01321,1.96548,1.91702,1.86793,1.8183,1.76829,1.71803,1.66767,1.61737,1.56726,1.51746,1.46803,1.41902,1.37044,1.32228,1.27452,1.22716,1.18023,1.13376,1.08781,1.04244,.99769,.95357,.91003,.86701,.82447,.78238,.74069,.69938,.65836,.61758,.57699,.53656,.49627,.45611,.41611,.37632,.33683,.29776,.25924,.22141,.18441,.14839,.11346,.07972,.04727,.01619,-.01348,-.0417,-.0684,-.09351,-.11698,-.13875,-.1588,-.17713,-.19381,-.20889,-.22242,-.23444,-.24501,-.25421,-.26216,-.26897,-.27473,-.27951,-.28336,-.28631,-.28836,-.28948,-.28963,-.28873,-.28673,-.28355,-.27916,-.27354,-.26673,-.25878,-.2498,-.23992,-.22929,-.21802,-.20623,-.19398,-.18134,-.16836,-.1551,-.14163,-.12809,-.11461,-.1013,-.08826,-.07557,-.06335,-.0517,-.04077,-.03065,-.02143,-.01321,-.00606,0,.00496,.00888,.01181,.01385,.01511,.0157,.01574,.01533,.01458,.01358,.0124,.01112,.00979,.00851,.00738,.0065,.006,.00596,.00646,.00754,.00924,.01161,.01471,.01858,.02323,.02865,.03481,.04169,.0493,.05765,.06677,.07671,.08754,.09934,.11222,.12628,.14159,.15823,.17624,.19561,.21632,.23828,.26142,.28563,.31083,.33696,.36397,.39185,.42057,.4501,.48036,.51125,.54264,.5744,.60646,.63871,.67105,.70337,.73556,.76751,.79918,.83048,.86139,.8919,.92202,.95184,.98144,1.01094,1.04045,1.0701,1.10002,1.13029,1.16103,1.1923,1.22416,1.25664,1.28979,1.32364,1.35824,1.39363,1.42985,1.4669,1.50475,1.54332,1.58252,1.62227,1.6625,1.70312,1.744,1.78501,1.82598,1.8668,1.90734,1.94754,1.98732,2.02666,2.06555,2.10402,2.1421,2.17985,2.2173,2.25448,2.29139,2.328,2.36424,2.4,2.43515,2.46955,2.50309,2.53565,2.56717,2.59761,2.62692,2.65505,2.68191,2.7074,2.73138,2.75375,2.7744,2.79324,2.81017,2.82504,2.83772,2.8481],pressure:[.22758,.23641,.24578,.25568,.26609,.27699,.28835,.30016,.31237,.32495,.33789,.35113,.36466,.37843,.39241,.40658,.4209,.43535,.44989,.4645,.47916,.49385,.50853,.5232,.53784,.55243,.56696,.58141,.59578,.61004,.62419,.63821,.65209,.6658,.67934,.69268,.70582,.71873,.73139,.7438,.75594,.76779,.77935,.79061,.80156,.81221,.82254,.83258,.84231,.85176,.86091,.86978,.87837,.88669,.89473,.9025,.91,.91725,.92425,.931,.93752,.9438,.94985,.95566,.96124,.96658,.97168,.97652,.98109,.98539,.98939,.99309,.99646,.99949,.99783,.99552,.99361,.99209,.99098,.99029,.99003,.99019,.99079,.99181,.99324,.9951,.99735,1,.99698,.99361,.98992,.98592,.98163,.97709,.97231,.96731,.96212,.95676,.95122,.94554,.93973,.93378,.92773,.92157,.91532,.90899,.90258,.89612,.88961,.88308,.87653,.87,.8635,.85705,.85068,.8444,.83823,.83219,.82628,.82052,.81493,.80952,.8043,.79929,.7945,.78994,.78561,.78151,.77765,.77402,.77062,.76742,.76443,.76161,.75896,.75645,.75406,.75175,.74951,.7473,.74511,.74289,.74064,.73833,.73592,.73341,.73078,.728,.72507,.72197,.71869,.71522,.71156,.70769,.70363,.69936,.69489,.69021,.68533,.68023,.67492,.66939,.66363,.65765,.65145,.64501,.63833,.63143,.62428,.61691,.60931,.60148,.59344,.58521,.57679,.5682,.55948,.55063,.54167,.53264,.52354,.51439,.50522,.49603,.48686,.47773,.46865,.45964,.45072,.44192,.43324,.42469,.41629,.40804,.39994,.392,.3842,.37655,.36903,.36164,.35437,.3472,.34012,.33312,.3262,.31933,.31251,.30574,.299,.2923,.28563,.27899,.27239,.26583,.25933,.25288,.24652,.24025,.2341,.22808,.22221,.21653,.21104,.20576,.20072,.19592,.19138,.18712,.18313,.17943,.17602,.17292,.17013,.16766,.16551,.16369,.16222,.1611,.16036,.16001,.16007,.16055,.16148,.16286,.16471,.16705,.16988,.17321,.17706,.18144,.18636,.19182,.19785,.20443,.21158,.2193]},{distance:[-2.31317,-2.3191,-2.32189,-2.32154,-2.31811,-2.31174,-2.30254,-2.29062,-2.27609,-2.25904,-2.23954,-2.21767,-2.19355,-2.16732,-2.13907,-2.10885,-2.07672,-2.04268,-2.00677,-1.96911,-1.92985,-1.88914,-1.84713,-1.80397,-1.75979,-1.71467,-1.66864,-1.62171,-1.57395,-1.52546,-1.47625,-1.42628,-1.3755,-1.32384,-1.27131,-1.218,-1.16408,-1.10972,-1.05508,-1.00031,-.94551,-.89077,-.83615,-.7817,-.72757,-.6739,-.62076,-.56821,-.51625,-.46484,-.41397,-.36366,-.314,-.26506,-.21689,-.16957,-.12316,-.07766,-.03301,.01085,.05399,.09643,.13827,.17967,.22079,.26176,.30265,.34342,.38397,.42414,.46381,.50285,.54115,.57863,.61524,.65093,.6856,.71914,.75153,.78275,.81283,.84182,.86972,.89651,.92208,.94634,.96919,.99052,1.01025,1.02835,1.04484,1.05976,1.07309,1.08479,1.09492,1.1036,1.11096,1.11714,1.12224,1.12627,1.12916,1.13083,1.13125,1.13036,1.12816,1.12466,1.11992,1.11397,1.10677,1.09827,1.08849,1.07746,1.06527,1.05203,1.03786,1.02283,1.00695,.99025,.97279,.9546,.93573,.9163,.8965,.8765,.85647,.83652,.81687,.79775,.77939,.76199,.74568,.73049,.71635,.70316,.69082,.67925,.66834,.65804,.64831,.63911,.63032,.62184,.61363,.60564,.59788,.59036,.58308,.57597,.5689,.56177,.55447,.5469,.53896,.53062,.5219,.51283,.5034,.49355,.48335,.47287,.46223,.45154,.44085,.43012,.41923,.40805,.39648,.38441,.37176,.35849,.34458,.32999,.31461,.29833,.28109,.26288,.2437,.22361,.20265,.18082,.15807,.13434,.1096,.0838,.0569,.02894,0,-.0298,-.0604,-.09173,-.12364,-.15594,-.18843,-.22092,-.25331,-.28559,-.31781,-.35006,-.38244,-.41502,-.44785,-.48098,-.5144,-.54811,-.58218,-.61666,-.65153,-.68677,-.72232,-.75807,-.79397,-.83002,-.86628,-.90281,-.93968,-.97693,-1.01465,-1.05282,-1.09139,-1.13031,-1.16956,-1.20917,-1.24905,-1.28907,-1.32908,-1.36891,-1.40844,-1.44765,-1.48658,-1.52527,-1.56376,-1.60206,-1.64016,-1.67801,-1.71552,-1.75264,-1.78936,-1.8257,-1.86161,-1.89702,-1.93182,-1.96584,-1.99894,-2.03102,-2.06203,-2.0919,-2.12056,-2.14794,-2.17397,-2.19852,-2.22138,-2.24235,-2.26129,-2.27805,-2.29243,-2.30422],pressure:[.9681,.97424,.98046,.98674,.99309,.9995,.99404,.98754,.981,.97444,.96785,.96124,.95462,.94801,.94139,.93479,.92822,.92167,.91515,.90868,.90225,.89589,.88959,.88336,.87722,.87115,.86519,.85932,.85356,.84792,.84239,.83699,.83173,.8266,.82162,.81679,.81211,.80759,.80324,.79906,.79505,.79121,.78756,.78409,.78081,.77771,.77481,.77211,.76959,.76728,.76516,.76324,.76153,.76001,.75869,.75757,.75665,.75593,.7554,.75507,.75493,.75498,.75523,.75565,.75627,.75706,.75803,.75917,.76049,.76197,.76361,.76541,.76737,.76947,.77172,.77409,.7766,.77923,.78198,.78484,.7878,.79086,.79401,.79724,.80055,.80394,.8074,.81092,.8145,.81813,.82182,.82556,.82934,.83317,.83703,.84093,.84487,.84884,.85284,.85687,.86094,.86503,.86915,.87329,.87746,.88166,.88587,.89011,.89436,.89863,.90291,.9072,.91149,.91579,.92009,.92438,.92867,.93295,.9372,.94144,.94566,.94985,.954,.95812,.96219,.96623,.97021,.97415,.97802,.98184,.9856,.9893,.99293,.9965,1,.99657,.9932,.98991,.98668,.98352,.98042,.97738,.9744,.97148,.9686,.96577,.96298,.96023,.95751,.95482,.95214,.94949,.94684,.9442,.94156,.93892,.93627,.93361,.93094,.92825,.92555,.92284,.9201,.91735,.91458,.91179,.90899,.90616,.90332,.90047,.8976,.89472,.89183,.88893,.88603,.88314,.88024,.87735,.87448,.87162,.86878,.86597,.86319,.86044,.85774,.85508,.85247,.84993,.84744,.84503,.84269,.84042,.83825,.83616,.83417,.83227,.83048,.8288,.82724,.82578,.82445,.82324,.82215,.82119,.82037,.81967,.81911,.81868,.81839,.81824,.81823,.81835,.81862,.81903,.81957,.82026,.82109,.82206,.82317,.82443,.82583,.82737,.82906,.83089,.83287,.83499,.83726,.83968,.84223,.84494,.84778,.85077,.8539,.85717,.86058,.86412,.86781,.87163,.87559,.87968,.88391,.88826,.89275,.89737,.90211,.90698,.91198,.91709,.92233,.92768,.93315,.93873,.94441,.95019,.95607,.96205]},{distance:[4.72925,4.81721,4.9037,4.98859,5.07177,5.15311,5.23249,5.3098,5.38491,5.45772,5.52811,5.59598,5.66122,5.72375,5.78346,5.84028,5.8941,5.94486,5.99248,6.03689,6.07803,6.11584,6.15028,6.18128,6.20882,6.23285,6.25336,6.27031,6.28369,6.29348,6.29969,6.3023,6.30133,6.29678,6.28867,6.27703,6.26187,6.24324,6.22116,6.19567,6.16683,6.13468,6.09928,6.06068,6.01896,5.97417,5.92639,5.87569,5.82217,5.76589,5.70696,5.64545,5.58147,5.5151,5.44644,5.37559,5.30265,5.2277,5.15085,5.0722,4.99184,4.90987,4.82639,4.74151,4.65533,4.56794,4.47945,4.38996,4.29959,4.20843,4.11658,4.02416,3.93125,3.83796,3.74437,3.65057,3.55666,3.46272,3.36884,3.27509,3.18155,3.08831,2.99545,2.90303,2.81114,2.71984,2.62922,2.53933,2.45026,2.36207,2.27484,2.18862,2.10349,2.01951,1.93675,1.85528,1.77515,1.69644,1.61919,1.54348,1.46935,1.39685,1.32605,1.25698,1.18967,1.12417,1.06049,.99863,.93862,.88044,.82408,.76953,.71676,.66574,.61644,.56882,.52282,.47841,.43553,.39413,.35414,.31551,.27817,.24206,.20712,.17328,.14048,.10866,.07776,.04772,.01848,-.00999,-.03776,-.06487,-.09134,-.11721,-.14251,-.16725,-.19144,-.21509,-.2382,-.26076,-.28275,-.30416,-.32496,-.34511,-.36459,-.38334,-.40134,-.41852,-.43485,-.45026,-.46471,-.47815,-.49052,-.50179,-.51189,-.52081,-.52849,-.5349,-.54003,-.54383,-.54627,-.54734,-.54702,-.54528,-.54211,-.53752,-.53149,-.52403,-.51515,-.50487,-.4932,-.48015,-.46575,-.45001,-.43297,-.41463,-.39503,-.37419,-.35213,-.32887,-.30443,-.27885,-.25214,-.22432,-.19541,-.16544,-.13442,-.10235,-.06926,-.03514,0,.03616,.07336,.11159,.15088,.19125,.23272,.27531,.31906,.36401,.41019,.45764,.5064,.55651,.60802,.66096,.71538,.77129,.82874,.88776,.94836,1.01056,1.07438,1.13982,1.20687,1.27554,1.34581,1.41766,1.49107,1.56599,1.64239,1.72025,1.79951,1.88013,1.96209,2.04532,2.12979,2.21546,2.30226,2.39017,2.47911,2.56905,2.65991,2.75164,2.84416,2.93742,3.03133,3.12582,3.2208,3.31619,3.41191,3.50785,3.60393,3.70006,3.79612,3.89202,3.98765,4.08291,4.17767,4.27182,4.36525,4.45783,4.54944,4.63995],pressure:[.30942,.30838,.30765,.30724,.30715,.30738,.30795,.30884,.31007,.31164,.31354,.31578,.31837,.32129,.32455,.32815,.33209,.33636,.34097,.34591,.35117,.35675,.36265,.36887,.37539,.38221,.38933,.39674,.40442,.41238,.4206,.42907,.43779,.44675,.45593,.46533,.47493,.48473,.49471,.50486,.51517,.52563,.53623,.54694,.55777,.5687,.57971,.59079,.60194,.61313,.62435,.6356,.64686,.65811,.66935,.68056,.69174,.70286,.71391,.72489,.73579,.74659,.75728,.76785,.7783,.7886,.79876,.80877,.81861,.82827,.83776,.84706,.85617,.86507,.87378,.88227,.89056,.89863,.90649,.91412,.92153,.92872,.93568,.94241,.94892,.95519,.96122,.96702,.97258,.97791,.98299,.98783,.99242,.99677,.99911,.99525,.99164,.98827,.98515,.98228,.97966,.97728,.97514,.97324,.97159,.97017,.96898,.96801,.96727,.96674,.96641,.96629,.96635,.96661,.96703,.96762,.96838,.96928,.97032,.97149,.97279,.9742,.97572,.97734,.97905,.98085,.98273,.98468,.98669,.98877,.99091,.99311,.99535,.99765,1,.9976,.99516,.99267,.99014,.98755,.98491,.98222,.97947,.97666,.97378,.97083,.96781,.96471,.96153,.95826,.9549,.95144,.94787,.9442,.94042,.93651,.93249,.92834,.92407,.91966,.91512,.91045,.90564,.90069,.8956,.89037,.885,.87949,.87384,.86806,.86214,.85608,.84988,.84356,.83711,.83053,.82383,.81702,.81009,.80306,.79594,.78872,.78141,.77403,.76657,.75905,.75148,.74385,.73619,.72849,.72076,.71302,.70526,.69749,.68972,.68195,.67419,.66644,.65871,.65099,.64329,.63561,.62795,.62032,.61271,.60512,.59755,.59001,.58248,.57497,.56749,.56002,.55256,.54512,.5377,.5303,.52291,.51554,.50819,.50087,.49358,.48632,.4791,.47192,.4648,.45773,.45072,.44378,.43692,.43015,.42346,.41687,.41039,.40403,.39779,.39168,.38571,.37989,.37423,.36873,.36342,.35828,.35335,.34862,.34409,.3398,.33573,.3319,.32831,.32498,.32192,.31912,.3166,.31436,.31242,.31077]}]};export{a as StrokesTexture,o as generateStrokesTexture,c as strokesDefinition};
|
|
5
|
+
import{disposeMaybe as e}from"../../../../../core/maybe.js";import{PixelType as t,SizedPixelFormat as s}from"../../../../webgl/enums.js";import r from"../../../../webgl/Texture.js";import{TextureDescriptor as n}from"../../../../webgl/TextureDescriptor.js";function o(e){const o=c.resolution,l=o/2,u=new Float32Array(o*o),p=o*l,m=c.amplitude,h=o,d=Math.log2(o)+1,f=c.strokes.length;let g=(d-1)*f*h;for(const{distance:t,pressure:s}of c.strokes){let e=t,r=s,n=g;for(let t=0;t<d;t++){0!==t&&(e=i(e,0),r=i(r,1));for(let t=0;t<c.resolution;t++){const s=e[t%e.length],o=r?.[t%r.length]??1;u[n]=s,u[n+p]=o,++n}n-=h*(f+1)}g+=h}const w=new n(o);w.dataType=t.FLOAT,w.pixelFormat=6403,w.internalFormat=s.R16F;const x=new r(e,w,u);return new a(o,m,f,x)}function i(e,t){if(!e)return null;const s=e.length/2,r=l*s,n=new Array(s);let o=0;const i=1===t;for(let l=0;l<e.length;l+=2){const t=(e[l]+e[l+1])/2;n[o++]=i?Math.min(r,1-(1-t)*u):Math.min(r,t*u)}return n}const l=.1,u=.5;class a{constructor(e,t,s,r){this.resolution=e,this.amplitude=t,this.variants=s,this.texture=r}dispose(){this.texture=e(this.texture)}}const c={amplitude:8,resolution:256,strokes:[{distance:[-1.59027,-1.59426,-1.59674,-1.59766,-1.59702,-1.59479,-1.59095,-1.5855,-1.57843,-1.56973,-1.55942,-1.5475,-1.53398,-1.5189,-1.50226,-1.4841,-1.46446,-1.44337,-1.42088,-1.39703,-1.37188,-1.34547,-1.31786,-1.28912,-1.2593,-1.22847,-1.19668,-1.16402,-1.13053,-1.09629,-1.06137,-1.02582,-.98972,-.95313,-.91611,-.87872,-.84102,-.80306,-.76488,-.72654,-.68807,-.64952,-.61092,-.57232,-.53375,-.49527,-.45692,-.41874,-.38078,-.34309,-.3057,-.26867,-.23204,-.19585,-.16015,-.12497,-.09036,-.05634,-.02296,.00977,.04183,.07321,.10389,.13386,.16313,.19169,.21956,.24672,.27321,.299,.32413,.34858,.37237,.3955,.41798,.43981,.461,.48154,.50145,.52073,.53939,.55744,.57488,.5917,.6079,.62347,.63837,.65259,.66609,.67885,.69083,.70201,.71235,.72183,.73042,.73812,.7449,.75076,.7557,.75973,.76284,.76507,.76642,.76692,.76659,.76545,.76352,.76083,.7574,.75324,.74837,.74279,.73652,.72959,.72199,.71377,.70493,.69553,.68558,.67515,.66426,.65298,.64135,.62944,.6173,.60499,.59257,.58008,.56759,.55513,.54275,.5305,.51842,.50654,.4949,.48353,.47246,.4617,.45128,.44121,.43149,.42213,.41313,.40448,.39617,.38818,.3805,.37309,.36594,.35902,.35229,.34572,.33927,.33292,.32663,.32035,.31407,.30774,.30135,.29486,.28824,.28148,.27454,.26739,.26002,.25241,.24454,.23639,.22796,.21922,.21016,.20076,.19098,.18082,.17023,.1592,.14768,.13566,.1231,.10996,.09624,.08188,.06688,.05121,.03485,.01778,0,-.0185,-.03771,-.05763,-.07824,-.09952,-.12144,-.14396,-.16706,-.19069,-.21481,-.23938,-.26436,-.28971,-.31539,-.34136,-.36759,-.39404,-.42067,-.44746,-.47437,-.50136,-.52839,-.55544,-.58248,-.60948,-.63642,-.66329,-.6901,-.71684,-.74352,-.77015,-.79675,-.82332,-.84988,-.87644,-.90301,-.92958,-.95615,-.98272,-1.00926,-1.03575,-1.06217,-1.08847,-1.11463,-1.1406,-1.16633,-1.19178,-1.2169,-1.24164,-1.26595,-1.28979,-1.31312,-1.3359,-1.35809,-1.37963,-1.4005,-1.42064,-1.44,-1.45853,-1.47616,-1.49285,-1.50853,-1.52313,-1.53659,-1.54886,-1.55986,-1.56955,-1.57788,-1.5848],pressure:[-.01365,-.00206,.01025,.02327,.03696,.05129,.06619,.08163,.09755,.11393,.1307,.14784,.16531,.18308,.20111,.21938,.23786,.25651,.2753,.29419,.31315,.33215,.35115,.37015,.38913,.40806,.42694,.44576,.46449,.48313,.50167,.5201,.53839,.55653,.57448,.59222,.60971,.62692,.6438,.66033,.67648,.69221,.70753,.72242,.73688,.75093,.76456,.77779,.79063,.80309,.81517,.82686,.83817,.84911,.85967,.86987,.87972,.88924,.89845,.90734,.91594,.92425,.93229,.94005,.94754,.95475,.96166,.96826,.97451,.9804,.98588,.99092,.99549,.99957,.99685,.99381,.99131,.98936,.98796,.98711,.98681,.98706,.98787,.98923,.99113,.99357,.99654,1,.99607,.99171,.98695,.98181,.97634,.97057,.96452,.95824,.95175,.94506,.93818,.93113,.92389,.91647,.90887,.90109,.89314,.88501,.87672,.86831,.85978,.85119,.84256,.83393,.82533,.8168,.80836,.80002,.79181,.78374,.77582,.7681,.76059,.75331,.74629,.73955,.73311,.72697,.72116,.71568,.71054,.70572,.70121,.697,.69304,.68931,.68576,.68236,.67905,.67582,.67262,.66941,.66619,.66291,.65957,.65613,.65259,.64892,.6451,.6411,.6369,.63248,.62783,.62295,.61783,.61247,.60688,.60104,.59498,.58868,.58216,.57542,.56845,.56125,.5538,.5461,.53813,.52986,.52129,.51239,.50316,.49359,.4837,.47349,.46299,.45223,.44124,.43005,.41869,.40719,.39557,.38386,.37207,.36023,.34836,.33648,.32464,.31287,.30119,.28963,.27822,.26698,.25594,.2451,.23448,.22409,.21391,.20394,.19415,.18452,.17503,.16565,.15636,.14713,.13794,.1288,.11968,.11058,.10151,.09247,.08346,.07447,.06552,.05659,.0477,.03885,.03007,.02137,.01278,.00433,-.00393,-.012,-.01983,-.02738,-.03463,-.04155,-.0481,-.05429,-.0601,-.06553,-.07057,-.07524,-.07954,-.08347,-.08703,-.09022,-.09303,-.09544,-.09744,-.09898,-.10004,-.10059,-.1006,-.10005,-.09892,-.0972,-.09487,-.09192,-.08833,-.08409,-.07918,-.07357,-.06724,-.06019,-.0524,-.04386,-.03455,-.02448]},{distance:[-3.46259,-3.47131,-3.47668,-3.47863,-3.47712,-3.4721,-3.46352,-3.45138,-3.43566,-3.41635,-3.39347,-3.36704,-3.33709,-3.30368,-3.26684,-3.22667,-3.18322,-3.1366,-3.08689,-3.0342,-2.97865,-2.92036,-2.85946,-2.79607,-2.73034,-2.66241,-2.59242,-2.52052,-2.44686,-2.37159,-2.29485,-2.2168,-2.13757,-2.05731,-1.97616,-1.89426,-1.81174,-1.72875,-1.64543,-1.56191,-1.47833,-1.39483,-1.3115,-1.22847,-1.14581,-1.06361,-.98193,-.90083,-.82036,-.74054,-.66141,-.583,-.50532,-.4284,-.35228,-.277,-.20261,-.12916,-.05672,.01463,.08485,.15384,.22153,.28784,.35269,.41602,.47776,.53787,.59629,.653,.70799,.76123,.81274,.86253,.9106,.95698,1.0017,1.04477,1.0862,1.126,1.16415,1.20065,1.23546,1.26857,1.29994,1.32953,1.35731,1.38321,1.40719,1.42921,1.44922,1.46719,1.48309,1.49691,1.50862,1.51825,1.52581,1.53133,1.53486,1.53644,1.53616,1.53409,1.53031,1.52493,1.51803,1.50972,1.50009,1.48924,1.47725,1.46421,1.45019,1.43527,1.4195,1.40295,1.38568,1.36778,1.34929,1.3303,1.31087,1.29108,1.27099,1.25066,1.23018,1.2096,1.18898,1.16838,1.14785,1.12745,1.10721,1.08719,1.06741,1.04791,1.02871,1.00986,.99136,.97324,.95551,.93819,.92127,.90476,.88866,.87296,.85767,.84277,.82823,.81406,.80022,.7867,.77346,.76049,.74774,.73519,.72278,.71049,.69827,.68606,.67381,.66145,.64893,.63618,.62313,.60973,.5959,.5816,.56675,.5513,.53516,.51826,.50053,.4819,.46231,.44169,.42002,.39725,.37336,.34834,.32219,.2949,.2665,.23698,.20638,.17469,.14193,.10809,.07316,.03714,0,-.03827,-.07772,-.11836,-.16022,-.20332,-.24768,-.29332,-.34024,-.38844,-.43788,-.48854,-.54036,-.59329,-.64724,-.70211,-.75782,-.81425,-.87128,-.92881,-.98674,-1.04498,-1.10346,-1.1621,-1.22086,-1.27969,-1.33854,-1.3974,-1.45625,-1.51511,-1.57396,-1.63283,-1.69173,-1.75067,-1.80968,-1.86875,-1.9279,-1.98712,-2.04639,-2.10568,-2.16495,-2.22416,-2.28322,-2.34208,-2.40063,-2.4588,-2.51647,-2.57354,-2.62989,-2.68543,-2.74002,-2.79357,-2.84597,-2.89711,-2.94689,-2.99521,-3.04195,-3.087,-3.13023,-3.17152,-3.21075,-3.24779,-3.28252,-3.3148,-3.34451,-3.37154,-3.39577,-3.41709,-3.43539,-3.45059],pressure:[.87183,.87151,.87129,.87118,.87117,.87128,.87149,.87182,.87225,.8728,.87347,.87424,.87513,.87613,.87723,.87845,.87978,.88122,.88276,.88441,.88616,.88801,.88996,.892,.89414,.89637,.89868,.90108,.90356,.90611,.90874,.91144,.91421,.91704,.91993,.92287,.92587,.92892,.93201,.93514,.93831,.94151,.94474,.94799,.95126,.95456,.95786,.96118,.9645,.96783,.97116,.97448,.9778,.98111,.98441,.9877,.99096,.99421,.99742,.99938,.99622,.9931,.99001,.98697,.98397,.98101,.97811,.97526,.97246,.96972,.96703,.96441,.96185,.95935,.95691,.95455,.95225,.95002,.94786,.94577,.94376,.94182,.93995,.93817,.93646,.93483,.93328,.93181,.93042,.92911,.92788,.92673,.92566,.92467,.92376,.92293,.92217,.92149,.92088,.92034,.91987,.91947,.91913,.91886,.91864,.91849,.91838,.91833,.91834,.91839,.91849,.91863,.91883,.91907,.91935,.91968,.92005,.92046,.92092,.92142,.92195,.92253,.92314,.9238,.92449,.92521,.92598,.92677,.9276,.92847,.92936,.93029,.93125,.93224,.93325,.9343,.93537,.93646,.93758,.93872,.93988,.94106,.94225,.94346,.94469,.94593,.94718,.94844,.94971,.95098,.95226,.95354,.95482,.9561,.95738,.95867,.95995,.96122,.9625,.96377,.96504,.9663,.96757,.96883,.97009,.97135,.97261,.97387,.97513,.9764,.97767,.97895,.98023,.98153,.98284,.98416,.98549,.98684,.98821,.9896,.99101,.99244,.99389,.99537,.99688,.99842,1,.99839,.99675,.99508,.99336,.99161,.98982,.98799,.98613,.98422,.98228,.98029,.97827,.97622,.97414,.97202,.96987,.9677,.96551,.9633,.96107,.95882,.95656,.9543,.95202,.94975,.94747,.94519,.94292,.94065,.93838,.93613,.93388,.93164,.92941,.9272,.92499,.9228,.92062,.91846,.91631,.91418,.91207,.90998,.90792,.90588,.90387,.90189,.89995,.89804,.89617,.89434,.89256,.89083,.88914,.88752,.88595,.88443,.88299,.88161,.8803,.87907,.87791,.87683,.87584,.87494,.87412,.8734,.87278,.87225]},{distance:[.39335,.43437,.47737,.52234,.56923,.61801,.66864,.72109,.7753,.83123,.88882,.94801,1.00875,1.07097,1.13461,1.1996,1.26586,1.33333,1.40193,1.47158,1.54221,1.61373,1.68607,1.75913,1.83284,1.90711,1.98186,2.05699,2.13243,2.20809,2.28387,2.35971,2.4355,2.51117,2.58663,2.66179,2.73658,2.81092,2.88473,2.95792,3.03043,3.10217,3.17308,3.24309,3.31211,3.3801,3.44697,3.51267,3.57712,3.64028,3.70208,3.76247,3.8214,3.87881,3.93467,3.98892,4.04152,4.09244,4.14164,4.18908,4.23474,4.27859,4.32061,4.36077,4.39905,4.43544,4.46992,4.50249,4.53314,4.56185,4.58864,4.61349,4.63642,4.65745,4.67657,4.69381,4.7092,4.72274,4.73447,4.74441,4.75259,4.75903,4.76376,4.76682,4.76822,4.768,4.76618,4.76279,4.75786,4.75142,4.74348,4.73409,4.72326,4.71102,4.69739,4.68241,4.6661,4.64849,4.6296,4.60948,4.58816,4.56567,4.54204,4.51732,4.49154,4.46473,4.43694,4.4082,4.37854,4.348,4.31662,4.28443,4.25145,4.21773,4.1833,4.14819,4.11243,4.07606,4.03912,4.00162,3.96361,3.92512,3.88618,3.84683,3.80708,3.76697,3.72653,3.68579,3.64478,3.60351,3.56202,3.52033,3.47845,3.43642,3.39425,3.35196,3.30957,3.2671,3.22455,3.18196,3.13933,3.09668,3.05402,3.01136,2.96873,2.92613,2.88357,2.84108,2.79865,2.75631,2.71407,2.67195,2.62994,2.58807,2.54634,2.50477,2.46338,2.42216,2.38114,2.34032,2.29971,2.25933,2.21916,2.17923,2.13954,2.10008,2.06087,2.02189,1.98316,1.94468,1.90644,1.86845,1.83069,1.79316,1.75586,1.71877,1.68189,1.6452,1.60868,1.57232,1.53611,1.50004,1.46407,1.4282,1.39241,1.35668,1.321,1.28535,1.24972,1.2141,1.17849,1.14286,1.10723,1.07158,1.03593,1.00028,.96464,.92902,.89344,.85793,.8225,.78719,.75203,.71705,.68231,.64784,.61369,.57991,.54656,.51368,.48134,.44959,.41849,.3881,.35848,.32967,.30174,.27474,.24872,.22373,.19982,.17702,.15539,.13497,.11579,.09791,.08137,.06621,.05248,.04022,.02948,.02029,.01271,.00677,.00252,0,-76e-5,27e-5,.00314,.00788,.01451,.02307,.03357,.04604,.0605,.07697,.09546,.11599,.13858,.16322,.18992,.21869,.24952,.28241,.31735,.35434],pressure:[.95248,.95236,.95228,.95223,.95222,.95224,.95231,.95241,.95256,.95274,.95296,.95322,.95352,.95385,.95423,.95465,.9551,.9556,.95613,.9567,.95731,.95796,.95864,.95936,.96012,.96091,.96173,.96259,.96348,.9644,.96535,.96633,.96734,.96838,.96944,.97053,.97164,.97277,.97393,.9751,.97629,.9775,.97873,.97997,.98122,.98249,.98376,.98505,.98634,.98763,.98893,.99023,.99154,.99284,.99414,.99544,.99673,.99802,.9993,.99942,.99816,.99691,.99568,.99445,.99324,.99205,.99087,.98972,.98858,.98746,.98636,.98528,.98423,.9832,.98219,.98121,.98025,.97931,.9784,.97752,.97666,.97582,.97501,.97423,.97347,.97274,.97203,.97135,.9707,.97007,.96948,.9689,.96836,.96784,.96735,.96689,.96646,.96605,.96567,.96533,.965,.96471,.96445,.96421,.964,.96382,.96367,.96355,.96346,.96339,.96335,.96334,.96336,.9634,.96348,.96358,.9637,.96385,.96403,.96423,.96446,.96471,.96499,.96529,.96561,.96595,.96631,.96669,.96709,.96751,.96795,.9684,.96887,.96935,.96984,.97035,.97087,.9714,.97194,.97249,.97304,.97361,.97418,.97476,.97534,.97592,.97651,.97711,.9777,.9783,.9789,.9795,.9801,.9807,.9813,.9819,.9825,.98309,.98369,.98428,.98486,.98545,.98603,.98661,.98718,.98775,.98832,.98888,.98944,.99,.99056,.99112,.99167,.99223,.99279,.99335,.99392,.99449,.99507,.99565,.99624,.99684,.99745,.99807,.9987,.99934,1,.99933,.99866,.99797,.99727,.99656,.99583,.9951,.99435,.99359,.99283,.99205,.99126,.99046,.98966,.98885,.98803,.9872,.98637,.98554,.9847,.98387,.98303,.98219,.98134,.9805,.97967,.97883,.978,.97717,.97634,.97552,.97471,.97389,.97309,.97229,.9715,.97071,.96993,.96915,.96838,.96762,.96687,.96612,.96539,.96466,.96395,.96324,.96255,.96187,.9612,.96055,.95991,.95929,.95869,.95811,.95754,.957,.95648,.95599,.95552,.95508,.95467,.95428,.95393,.9536,.95331,.95305,.95283,.95264]},{distance:[2.85606,2.86149,2.86432,2.8645,2.862,2.85686,2.84912,2.83886,2.82618,2.81117,2.79393,2.77456,2.75314,2.72975,2.70447,2.67734,2.64844,2.61784,2.58564,2.55196,2.5169,2.48057,2.44305,2.40438,2.36462,2.32383,2.28208,2.23943,2.19591,2.15153,2.10628,2.06016,2.01321,1.96548,1.91702,1.86793,1.8183,1.76829,1.71803,1.66767,1.61737,1.56726,1.51746,1.46803,1.41902,1.37044,1.32228,1.27452,1.22716,1.18023,1.13376,1.08781,1.04244,.99769,.95357,.91003,.86701,.82447,.78238,.74069,.69938,.65836,.61758,.57699,.53656,.49627,.45611,.41611,.37632,.33683,.29776,.25924,.22141,.18441,.14839,.11346,.07972,.04727,.01619,-.01348,-.0417,-.0684,-.09351,-.11698,-.13875,-.1588,-.17713,-.19381,-.20889,-.22242,-.23444,-.24501,-.25421,-.26216,-.26897,-.27473,-.27951,-.28336,-.28631,-.28836,-.28948,-.28963,-.28873,-.28673,-.28355,-.27916,-.27354,-.26673,-.25878,-.2498,-.23992,-.22929,-.21802,-.20623,-.19398,-.18134,-.16836,-.1551,-.14163,-.12809,-.11461,-.1013,-.08826,-.07557,-.06335,-.0517,-.04077,-.03065,-.02143,-.01321,-.00606,0,.00496,.00888,.01181,.01385,.01511,.0157,.01574,.01533,.01458,.01358,.0124,.01112,.00979,.00851,.00738,.0065,.006,.00596,.00646,.00754,.00924,.01161,.01471,.01858,.02323,.02865,.03481,.04169,.0493,.05765,.06677,.07671,.08754,.09934,.11222,.12628,.14159,.15823,.17624,.19561,.21632,.23828,.26142,.28563,.31083,.33696,.36397,.39185,.42057,.4501,.48036,.51125,.54264,.5744,.60646,.63871,.67105,.70337,.73556,.76751,.79918,.83048,.86139,.8919,.92202,.95184,.98144,1.01094,1.04045,1.0701,1.10002,1.13029,1.16103,1.1923,1.22416,1.25664,1.28979,1.32364,1.35824,1.39363,1.42985,1.4669,1.50475,1.54332,1.58252,1.62227,1.6625,1.70312,1.744,1.78501,1.82598,1.8668,1.90734,1.94754,1.98732,2.02666,2.06555,2.10402,2.1421,2.17985,2.2173,2.25448,2.29139,2.328,2.36424,2.4,2.43515,2.46955,2.50309,2.53565,2.56717,2.59761,2.62692,2.65505,2.68191,2.7074,2.73138,2.75375,2.7744,2.79324,2.81017,2.82504,2.83772,2.8481],pressure:[.22758,.23641,.24578,.25568,.26609,.27699,.28835,.30016,.31237,.32495,.33789,.35113,.36466,.37843,.39241,.40658,.4209,.43535,.44989,.4645,.47916,.49385,.50853,.5232,.53784,.55243,.56696,.58141,.59578,.61004,.62419,.63821,.65209,.6658,.67934,.69268,.70582,.71873,.73139,.7438,.75594,.76779,.77935,.79061,.80156,.81221,.82254,.83258,.84231,.85176,.86091,.86978,.87837,.88669,.89473,.9025,.91,.91725,.92425,.931,.93752,.9438,.94985,.95566,.96124,.96658,.97168,.97652,.98109,.98539,.98939,.99309,.99646,.99949,.99783,.99552,.99361,.99209,.99098,.99029,.99003,.99019,.99079,.99181,.99324,.9951,.99735,1,.99698,.99361,.98992,.98592,.98163,.97709,.97231,.96731,.96212,.95676,.95122,.94554,.93973,.93378,.92773,.92157,.91532,.90899,.90258,.89612,.88961,.88308,.87653,.87,.8635,.85705,.85068,.8444,.83823,.83219,.82628,.82052,.81493,.80952,.8043,.79929,.7945,.78994,.78561,.78151,.77765,.77402,.77062,.76742,.76443,.76161,.75896,.75645,.75406,.75175,.74951,.7473,.74511,.74289,.74064,.73833,.73592,.73341,.73078,.728,.72507,.72197,.71869,.71522,.71156,.70769,.70363,.69936,.69489,.69021,.68533,.68023,.67492,.66939,.66363,.65765,.65145,.64501,.63833,.63143,.62428,.61691,.60931,.60148,.59344,.58521,.57679,.5682,.55948,.55063,.54167,.53264,.52354,.51439,.50522,.49603,.48686,.47773,.46865,.45964,.45072,.44192,.43324,.42469,.41629,.40804,.39994,.392,.3842,.37655,.36903,.36164,.35437,.3472,.34012,.33312,.3262,.31933,.31251,.30574,.299,.2923,.28563,.27899,.27239,.26583,.25933,.25288,.24652,.24025,.2341,.22808,.22221,.21653,.21104,.20576,.20072,.19592,.19138,.18712,.18313,.17943,.17602,.17292,.17013,.16766,.16551,.16369,.16222,.1611,.16036,.16001,.16007,.16055,.16148,.16286,.16471,.16705,.16988,.17321,.17706,.18144,.18636,.19182,.19785,.20443,.21158,.2193]},{distance:[-2.31317,-2.3191,-2.32189,-2.32154,-2.31811,-2.31174,-2.30254,-2.29062,-2.27609,-2.25904,-2.23954,-2.21767,-2.19355,-2.16732,-2.13907,-2.10885,-2.07672,-2.04268,-2.00677,-1.96911,-1.92985,-1.88914,-1.84713,-1.80397,-1.75979,-1.71467,-1.66864,-1.62171,-1.57395,-1.52546,-1.47625,-1.42628,-1.3755,-1.32384,-1.27131,-1.218,-1.16408,-1.10972,-1.05508,-1.00031,-.94551,-.89077,-.83615,-.7817,-.72757,-.6739,-.62076,-.56821,-.51625,-.46484,-.41397,-.36366,-.314,-.26506,-.21689,-.16957,-.12316,-.07766,-.03301,.01085,.05399,.09643,.13827,.17967,.22079,.26176,.30265,.34342,.38397,.42414,.46381,.50285,.54115,.57863,.61524,.65093,.6856,.71914,.75153,.78275,.81283,.84182,.86972,.89651,.92208,.94634,.96919,.99052,1.01025,1.02835,1.04484,1.05976,1.07309,1.08479,1.09492,1.1036,1.11096,1.11714,1.12224,1.12627,1.12916,1.13083,1.13125,1.13036,1.12816,1.12466,1.11992,1.11397,1.10677,1.09827,1.08849,1.07746,1.06527,1.05203,1.03786,1.02283,1.00695,.99025,.97279,.9546,.93573,.9163,.8965,.8765,.85647,.83652,.81687,.79775,.77939,.76199,.74568,.73049,.71635,.70316,.69082,.67925,.66834,.65804,.64831,.63911,.63032,.62184,.61363,.60564,.59788,.59036,.58308,.57597,.5689,.56177,.55447,.5469,.53896,.53062,.5219,.51283,.5034,.49355,.48335,.47287,.46223,.45154,.44085,.43012,.41923,.40805,.39648,.38441,.37176,.35849,.34458,.32999,.31461,.29833,.28109,.26288,.2437,.22361,.20265,.18082,.15807,.13434,.1096,.0838,.0569,.02894,0,-.0298,-.0604,-.09173,-.12364,-.15594,-.18843,-.22092,-.25331,-.28559,-.31781,-.35006,-.38244,-.41502,-.44785,-.48098,-.5144,-.54811,-.58218,-.61666,-.65153,-.68677,-.72232,-.75807,-.79397,-.83002,-.86628,-.90281,-.93968,-.97693,-1.01465,-1.05282,-1.09139,-1.13031,-1.16956,-1.20917,-1.24905,-1.28907,-1.32908,-1.36891,-1.40844,-1.44765,-1.48658,-1.52527,-1.56376,-1.60206,-1.64016,-1.67801,-1.71552,-1.75264,-1.78936,-1.8257,-1.86161,-1.89702,-1.93182,-1.96584,-1.99894,-2.03102,-2.06203,-2.0919,-2.12056,-2.14794,-2.17397,-2.19852,-2.22138,-2.24235,-2.26129,-2.27805,-2.29243,-2.30422],pressure:[.9681,.97424,.98046,.98674,.99309,.9995,.99404,.98754,.981,.97444,.96785,.96124,.95462,.94801,.94139,.93479,.92822,.92167,.91515,.90868,.90225,.89589,.88959,.88336,.87722,.87115,.86519,.85932,.85356,.84792,.84239,.83699,.83173,.8266,.82162,.81679,.81211,.80759,.80324,.79906,.79505,.79121,.78756,.78409,.78081,.77771,.77481,.77211,.76959,.76728,.76516,.76324,.76153,.76001,.75869,.75757,.75665,.75593,.7554,.75507,.75493,.75498,.75523,.75565,.75627,.75706,.75803,.75917,.76049,.76197,.76361,.76541,.76737,.76947,.77172,.77409,.7766,.77923,.78198,.78484,.7878,.79086,.79401,.79724,.80055,.80394,.8074,.81092,.8145,.81813,.82182,.82556,.82934,.83317,.83703,.84093,.84487,.84884,.85284,.85687,.86094,.86503,.86915,.87329,.87746,.88166,.88587,.89011,.89436,.89863,.90291,.9072,.91149,.91579,.92009,.92438,.92867,.93295,.9372,.94144,.94566,.94985,.954,.95812,.96219,.96623,.97021,.97415,.97802,.98184,.9856,.9893,.99293,.9965,1,.99657,.9932,.98991,.98668,.98352,.98042,.97738,.9744,.97148,.9686,.96577,.96298,.96023,.95751,.95482,.95214,.94949,.94684,.9442,.94156,.93892,.93627,.93361,.93094,.92825,.92555,.92284,.9201,.91735,.91458,.91179,.90899,.90616,.90332,.90047,.8976,.89472,.89183,.88893,.88603,.88314,.88024,.87735,.87448,.87162,.86878,.86597,.86319,.86044,.85774,.85508,.85247,.84993,.84744,.84503,.84269,.84042,.83825,.83616,.83417,.83227,.83048,.8288,.82724,.82578,.82445,.82324,.82215,.82119,.82037,.81967,.81911,.81868,.81839,.81824,.81823,.81835,.81862,.81903,.81957,.82026,.82109,.82206,.82317,.82443,.82583,.82737,.82906,.83089,.83287,.83499,.83726,.83968,.84223,.84494,.84778,.85077,.8539,.85717,.86058,.86412,.86781,.87163,.87559,.87968,.88391,.88826,.89275,.89737,.90211,.90698,.91198,.91709,.92233,.92768,.93315,.93873,.94441,.95019,.95607,.96205]},{distance:[4.72925,4.81721,4.9037,4.98859,5.07177,5.15311,5.23249,5.3098,5.38491,5.45772,5.52811,5.59598,5.66122,5.72375,5.78346,5.84028,5.8941,5.94486,5.99248,6.03689,6.07803,6.11584,6.15028,6.18128,6.20882,6.23285,6.25336,6.27031,6.28369,6.29348,6.29969,6.3023,6.30133,6.29678,6.28867,6.27703,6.26187,6.24324,6.22116,6.19567,6.16683,6.13468,6.09928,6.06068,6.01896,5.97417,5.92639,5.87569,5.82217,5.76589,5.70696,5.64545,5.58147,5.5151,5.44644,5.37559,5.30265,5.2277,5.15085,5.0722,4.99184,4.90987,4.82639,4.74151,4.65533,4.56794,4.47945,4.38996,4.29959,4.20843,4.11658,4.02416,3.93125,3.83796,3.74437,3.65057,3.55666,3.46272,3.36884,3.27509,3.18155,3.08831,2.99545,2.90303,2.81114,2.71984,2.62922,2.53933,2.45026,2.36207,2.27484,2.18862,2.10349,2.01951,1.93675,1.85528,1.77515,1.69644,1.61919,1.54348,1.46935,1.39685,1.32605,1.25698,1.18967,1.12417,1.06049,.99863,.93862,.88044,.82408,.76953,.71676,.66574,.61644,.56882,.52282,.47841,.43553,.39413,.35414,.31551,.27817,.24206,.20712,.17328,.14048,.10866,.07776,.04772,.01848,-.00999,-.03776,-.06487,-.09134,-.11721,-.14251,-.16725,-.19144,-.21509,-.2382,-.26076,-.28275,-.30416,-.32496,-.34511,-.36459,-.38334,-.40134,-.41852,-.43485,-.45026,-.46471,-.47815,-.49052,-.50179,-.51189,-.52081,-.52849,-.5349,-.54003,-.54383,-.54627,-.54734,-.54702,-.54528,-.54211,-.53752,-.53149,-.52403,-.51515,-.50487,-.4932,-.48015,-.46575,-.45001,-.43297,-.41463,-.39503,-.37419,-.35213,-.32887,-.30443,-.27885,-.25214,-.22432,-.19541,-.16544,-.13442,-.10235,-.06926,-.03514,0,.03616,.07336,.11159,.15088,.19125,.23272,.27531,.31906,.36401,.41019,.45764,.5064,.55651,.60802,.66096,.71538,.77129,.82874,.88776,.94836,1.01056,1.07438,1.13982,1.20687,1.27554,1.34581,1.41766,1.49107,1.56599,1.64239,1.72025,1.79951,1.88013,1.96209,2.04532,2.12979,2.21546,2.30226,2.39017,2.47911,2.56905,2.65991,2.75164,2.84416,2.93742,3.03133,3.12582,3.2208,3.31619,3.41191,3.50785,3.60393,3.70006,3.79612,3.89202,3.98765,4.08291,4.17767,4.27182,4.36525,4.45783,4.54944,4.63995],pressure:[.30942,.30838,.30765,.30724,.30715,.30738,.30795,.30884,.31007,.31164,.31354,.31578,.31837,.32129,.32455,.32815,.33209,.33636,.34097,.34591,.35117,.35675,.36265,.36887,.37539,.38221,.38933,.39674,.40442,.41238,.4206,.42907,.43779,.44675,.45593,.46533,.47493,.48473,.49471,.50486,.51517,.52563,.53623,.54694,.55777,.5687,.57971,.59079,.60194,.61313,.62435,.6356,.64686,.65811,.66935,.68056,.69174,.70286,.71391,.72489,.73579,.74659,.75728,.76785,.7783,.7886,.79876,.80877,.81861,.82827,.83776,.84706,.85617,.86507,.87378,.88227,.89056,.89863,.90649,.91412,.92153,.92872,.93568,.94241,.94892,.95519,.96122,.96702,.97258,.97791,.98299,.98783,.99242,.99677,.99911,.99525,.99164,.98827,.98515,.98228,.97966,.97728,.97514,.97324,.97159,.97017,.96898,.96801,.96727,.96674,.96641,.96629,.96635,.96661,.96703,.96762,.96838,.96928,.97032,.97149,.97279,.9742,.97572,.97734,.97905,.98085,.98273,.98468,.98669,.98877,.99091,.99311,.99535,.99765,1,.9976,.99516,.99267,.99014,.98755,.98491,.98222,.97947,.97666,.97378,.97083,.96781,.96471,.96153,.95826,.9549,.95144,.94787,.9442,.94042,.93651,.93249,.92834,.92407,.91966,.91512,.91045,.90564,.90069,.8956,.89037,.885,.87949,.87384,.86806,.86214,.85608,.84988,.84356,.83711,.83053,.82383,.81702,.81009,.80306,.79594,.78872,.78141,.77403,.76657,.75905,.75148,.74385,.73619,.72849,.72076,.71302,.70526,.69749,.68972,.68195,.67419,.66644,.65871,.65099,.64329,.63561,.62795,.62032,.61271,.60512,.59755,.59001,.58248,.57497,.56749,.56002,.55256,.54512,.5377,.5303,.52291,.51554,.50819,.50087,.49358,.48632,.4791,.47192,.4648,.45773,.45072,.44378,.43692,.43015,.42346,.41687,.41039,.40403,.39779,.39168,.38571,.37989,.37423,.36873,.36342,.35828,.35335,.34862,.34409,.3398,.33573,.3319,.32831,.32498,.32192,.31912,.3166,.31436,.31242,.31077]}]};export{a as StrokesTexture,o as generateStrokesTexture,c as strokesDefinition};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{hasNativeFloat16Array as r,makeFloat16Array as e}from"../../../../geometry/support/float16.js";import{Pos2TexF16 as t,Pos2TexF32 as o,Pos2 as n}from"./DefaultVertexBufferLayouts.js";import{VertexArrayObject as f}from"./VertexArrayObject.js";import
|
|
5
|
+
import{hasNativeFloat16Array as r,makeFloat16Array as e}from"../../../../geometry/support/float16.js";import{Pos2TexF16 as t,Pos2TexF32 as o,Pos2 as n}from"./DefaultVertexBufferLayouts.js";import{VertexArrayObject as f}from"./VertexArrayObject.js";import m from"../../../webgl/Texture.js";import{TextureDescriptor as s}from"../../../webgl/TextureDescriptor.js";import{VertexBuffer as u}from"../../../webgl/VertexBuffer.js";function a(m,s=0,a=-1,i=1){const p=1===s,w=p?r?new Float32Array([a,a,0,i,a,0,a,i,0,i,i,0]):new Float32Array([a,a,0,0,i,a,1,0,a,i,0,1,i,i,1,1]):new Float32Array([a,a,i,a,a,i,i,i]);if(p&&r){const r=e(w.buffer);r[10]=r[17]=r[22]=r[23]=1}return new f(m,new u(m,p?r?t:o:n,w))}const i=4;function p(r){const e=new s(i);return e.samplingMode=9728,new m(r,e)}export{p as createEmptyTexture,a as createQuadVAO};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import t from"../../../../core/Logger.js";import{clamp as e}from"../../../../core/mathUtils.js";import{createRenderScreenPointArray3 as i}from"../../../../core/screenUtils.js";import{secondsFromMilliseconds as r,Seconds as s}from"../../../../core/time.js";import{copy as a}from"../../../../core/libs/gl-matrix-2/math/vec2.js";import{h as n,e as o,g as l,j as h,i as c,d as p,b as m,B as u,p as f}from"../../../../chunks/vec32.js";import{create as d}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{c as g}from"../../../../chunks/vec42.js";import{ONES as b,create as _}from"../../../../core/libs/gl-matrix-2/factories/vec4f64.js";import{makeFloat16Array as S}from"../../../../geometry/support/float16.js";import{distance2 as v,fromPoints as P,create as j,closestLineSegmentPoint as E}from"../../../../geometry/support/lineSegment.js";import{fromPoints as w,create as y,signedDistance as T,getNormal as z}from"../../../../geometry/support/plane.js";import{isHighlightOrOLID as A,isColor as C,isDepth as L,isColorHighlightOLIDOrDepth as M,is2DGeometryOutput as O}from"../core/shaderLibrary/ShaderOutput.js";import{olidEnabled as V}from"../effects/geometry/olidUtils.js";import R from"../lib/GLMaterial.js";import{Material as x}from"../lib/Material.js";import{isTranslationMatrix as F}from"../lib/Util.js";import{VisualVariablePassParameters as k}from"./VisualVariablePassParameters.js";import{writeDeltaF16Vector as N}from"./internal/bufferWriterUtils.js";import{r as U}from"../../../../chunks/RibbonLine.glsl.js";import{getLayout as B,RibbonLineTechnique as D}from"../shaders/RibbonLineTechnique.js";import{RibbonLineTechniqueConfiguration as W}from"../shaders/RibbonLineTechniqueConfiguration.js";import{alphaCutoff as J}from"../../../../webscene/support/AlphaCutoff.js";class Y extends x{constructor(t,e){super(t,X),this.produces=new Map([[2,t=>A(t)||C(t)&&8===this.parameters.renderOccluded],[3,t=>L(t)],[11,t=>M(t)&&8===this.parameters.renderOccluded],[12,t=>M(t)&&8===this.parameters.renderOccluded],[4,t=>C(t)&&this.parameters.writeDepth&&8!==this.parameters.renderOccluded],[9,t=>C(t)&&!this.parameters.writeDepth&&8!==this.parameters.renderOccluded],[19,t=>O(t)]]),this._configuration=new W(e)}getConfiguration(t,e){super.getConfiguration(t,e,this._configuration),this._configuration.oitPass=e.oitPass,this._configuration.draped=19===e.slot;const i=null!=this.parameters.stipplePattern&&8!==t;return this._configuration.stippleEnabled=i,this._configuration.stippleOffColorEnabled=i&&null!=this.parameters.stippleOffColor,this._configuration.stipplePreferContinuous=i&&this.parameters.stipplePreferContinuous,this._configuration.hasSlicePlane=this.parameters.hasSlicePlane,this._configuration.roundJoins="round"===this.parameters.join,this._configuration.capType=this.parameters.cap,this._configuration.applyMarkerOffset=null!=this.parameters.markerParameters&&K(this.parameters.markerParameters),this._configuration.hasPolygonOffset=this.parameters.hasPolygonOffset,this._configuration.writeDepth=this.parameters.writeDepth,this._configuration.hasVVSize=this.parameters.hasVVSize,this._configuration.hasVVColor=this.parameters.hasVVColor,this._configuration.hasVVOpacity=this.parameters.hasVVOpacity,this._configuration.innerColorEnabled=this.parameters.innerWidth>0&&null!=this.parameters.innerColor,this._configuration.falloffEnabled=this.parameters.falloff>0,this._configuration.hasOccludees=e.hasOccludees,this._configuration.occluder=8===this.parameters.renderOccluded,this._configuration.terrainDepthTest=e.terrainDepthTest&&C(t),this._configuration.cullAboveTerrain=e.cullAboveTerrain,this._configuration.wireframe=this.parameters.wireframe,this._configuration.animation=this.parameters.animation,this._configuration.emissionSource=this.hasEmissions?1:0,this._configuration.hasScreenSizePerspective=!!this.parameters.screenSizePerspective,this._configuration}get visible(){return this.parameters.color[3]>=J||null!=this.parameters.stipplePattern&&(this.parameters.stippleOffColor?.[3]??0)>J}setParameters(t,e){t.animation=this.parameters.animation,super.setParameters(t,e)}intersectDraped({attributes:t,screenToWorldRatio:i},r,s,a,n){if(!r.options.selectionMode)return;const o=t.get("size");let l=this.parameters.width;if(this.parameters.vvSize){const i=t.get("sizeFeatureAttribute").data[0];Number.isNaN(i)?l*=this.parameters.vvSize.fallback[0]:l*=e(this.parameters.vvSize.offset[0]+i*this.parameters.vvSize.factor[0],this.parameters.vvSize.minSize[0],this.parameters.vvSize.maxSize[0])}else o&&(l*=o.data[0]);const h=s[0],c=s[1],p=(l/2+4)*i;let m=Number.MAX_VALUE,u=0;const f=t.get("position").data,d=I(this.parameters,t)?f.length-2:f.length-5;for(let g=0;g<d;g+=3){const t=f[g],i=f[g+1],r=(g+3)%f.length,s=h-t,a=c-i,n=f[r]-t,o=f[r+1]-i,l=e((n*s+o*a)/(n*n+o*o),0,1),p=n*l-s,d=o*l-a,b=p*p+d*d;b<m&&(m=b,u=g/3)}m<p*p&&a(n.distance,n.normal,u)}intersect(i,r,s,f,d,g){const{options:b,camera:_,rayBegin:S,rayEnd:j}=s;if(!b.selectionMode||!i.visible||!_)return;if(!F(r))return void t.getLogger("esri.views.3d.webgl-engine.materials.RibbonLineMaterial").error("intersection assumes a translation-only matrix");const y=i.attributes,A=y.get("position").data;let C=this.parameters.width;if(this.parameters.vvSize){const t=y.get("sizeFeatureAttribute").data[0];Number.isNaN(t)||(C*=e(this.parameters.vvSize.offset[0]+t*this.parameters.vvSize.factor[0],this.parameters.vvSize.minSize[0],this.parameters.vvSize.maxSize[0]))}else y.has("size")&&(C*=y.get("size").data[0]);const L=et;a(L,s.point);const M=C*_.pixelRatio/2+4*_.pixelRatio;n(mt[0],L[0]-M,L[1]+M,0),n(mt[1],L[0]+M,L[1]+M,0),n(mt[2],L[0]+M,L[1]-M,0),n(mt[3],L[0]-M,L[1]-M,0);for(let t=0;t<4;t++)if(!_.unprojectFromRenderScreen(mt[t],ut[t]))return;w(_.eye,ut[0],ut[1],ft),w(_.eye,ut[1],ut[2],dt),w(_.eye,ut[2],ut[3],gt),w(_.eye,ut[3],ut[0],bt);let O=Number.MAX_VALUE,V=0;const R=I(this.parameters,y)?A.length-2:A.length-5;for(let t=0;t<R;t+=3){Q[0]=A[t]+r[12],Q[1]=A[t+1]+r[13],Q[2]=A[t+2]+r[14];const e=(t+3)%A.length;if(Z[0]=A[e]+r[12],Z[1]=A[e+1]+r[13],Z[2]=A[e+2]+r[14],T(ft,Q)<0&&T(ft,Z)<0||T(dt,Q)<0&&T(dt,Z)<0||T(gt,Q)<0&&T(gt,Z)<0||T(bt,Q)<0&&T(bt,Z)<0)continue;const i=_.projectToRenderScreen(Q,it),s=_.projectToRenderScreen(Z,rt);if(null==i||null==s)continue;if(i[2]<0&&s[2]>0){o($,Q,Z);const t=_.frustum,e=-T(t[4],Q)/l($,z(t[4]));if(h($,$,e),c(Q,Q,$),!_.projectToRenderScreen(Q,i))continue}else if(i[2]>0&&s[2]<0){o($,Z,Q);const t=_.frustum,e=-T(t[4],Z)/l($,z(t[4]));if(h($,$,e),c(Z,Z,$),!_.projectToRenderScreen(Z,s))continue}else if(i[2]<0&&s[2]<0)continue;i[2]=0,s[2]=0;const a=v(P(i,s,nt),L);a<O&&(O=a,p(st,Q),p(at,Z),V=t/3)}if(O<M*M){let t=Number.MAX_VALUE;if(E(P(st,at,nt),P(S,j,ot),tt)){o(tt,tt,S);const e=m(tt);h(tt,tt,1/e),t=e/u(S,j)}g(t,tt,V)}}get hasEmissions(){return this.parameters.emissiveStrength>0}createBufferWriter(){return new G(B(this.parameters),this.parameters)}createGLMaterial(t){return new q(t)}validateParameters(t){"miter"!==t.join&&(t.miterLimit=0),null!=t.markerParameters&&(t.markerScale=t.markerParameters.width/t.width)}update(t){return!!this.parameters.hasAnimation&&(this.setParameters({timeElapsed:r(t.time)},!1),0!==t.dt)}}class q extends R{constructor(){super(...arguments),this._stipplePattern=null}dispose(){super.dispose(),this._stippleTextures?.release(this._stipplePattern),this._stipplePattern=null}beginSlot(t){const e=this._material.parameters.stipplePattern;return this._stipplePattern!==e&&(this._material.setParameters({stippleTexture:this._stippleTextures.swap(e,this._stipplePattern)}),this._stipplePattern=e),this.getTechnique(D,t)}}class X extends k{constructor(){super(...arguments),this.width=0,this.color=b,this.join="miter",this.cap=0,this.miterLimit=5,this.writeDepth=!0,this.hasPolygonOffset=!1,this.stippleTexture=null,this.stipplePreferContinuous=!0,this.markerParameters=null,this.markerScale=1,this.hasSlicePlane=!1,this.vvFastUpdate=!1,this.isClosed=!1,this.falloff=0,this.innerWidth=0,this.wireframe=!1,this.timeElapsed=s(0),this.animation=0,this.animationSpeed=1,this.trailLength=1,this.startTime=s(0),this.endTime=s(1/0),this.emissiveStrength=0}get transparent(){return this.color[3]<1||this.hasAnimation||null!=this.stipplePattern&&(this.stippleOffColor?.[3]??0)<1}get hasAnimation(){return 0!==this.animation}}class G{constructor(t,e){this.layout=t,this._parameters=e;const i=e.stipplePattern?1:0;switch(this._parameters.join){case"miter":case"bevel":this.numJoinSubdivisions=i;break;case"round":this.numJoinSubdivisions=U+i}}_isClosed(t){return I(this._parameters,t)}allocate(t){return this.layout.createBuffer(t)}elementCount(t){const e=2,i=t.get("position").indices.length/2+1,r=this._isClosed(t);let s=r?2:2*e;return s+=((r?i:i-1)-(r?0:1))*(2*this.numJoinSubdivisions+4),s+=2,this._parameters.wireframe&&(s=2+4*(s-2)),s}write(t,e,i,r,s,a){const o=this.layout,l=i.get("position"),h=l.indices,c=l.data.length/3,m=i.get("distanceToStart")?.data;h&&h.length!==2*(c-1)&&console.warn("RibbonLineMaterial does not support indices");const d=o.fields.has("sizeFeatureAttribute");let b=1,_=null;if(d){const t=i.get("sizeFeatureAttribute");1===t.data.length?b=t.data[0]:_=t.data}else b=i.get("size")?.data[0]??1;let v=[1,1,1,1],P=0,j=null;const E=o.fields.has("colorFeatureAttribute");if(E){const t=i.get("colorFeatureAttribute");1===t.data.length?P=t.data[0]:j=t.data}else v=i.get("color")?.data??v;const w=i.get("timeStamps")?.data,y=w&&o.fields.has("timeStamps"),T=o.fields.has("opacityFeatureAttribute");let z=0,A=null;if(T){const t=i.get("opacityFeatureAttribute");1===t.data.length?z=t.data[0]:A=t.data}const C=new Float32Array(s.buffer),L=S(s.buffer),M=new Uint8Array(s.buffer),O=o.stride/4;let R=a*O;const x=R;let F=0;const k=m?(t,e,i)=>F=m[i]:(t,e,i)=>F+=u(t,e),U=C.BYTES_PER_ELEMENT/L.BYTES_PER_ELEMENT,B=4/U,D=V(),W=(t,e,i,s,a,n,o,l)=>{C[R++]=e[0],C[R++]=e[1],C[R++]=e[2],N(t,e,L,R*U),R+=B,N(i,e,L,R*U),R+=B,C[R++]=l;let h=R*U;if(L[h++]=a,L[h++]=n,R=Math.ceil(h/U),E)C[R]=j?.[o]??P;else{const t=Math.min(4*o,v.length-4),e=4*R;M[e]=255*v[t],M[e+1]=255*v[t+1],M[e+2]=255*v[t+2],M[e+3]=255*v[t+3]}if(R++,C[R++]=_?.[o]??b,T&&(C[R++]=A?.[o]??z),D){let t=4*R;r?(M[t++]=r[0],M[t++]=r[1],M[t++]=r[2],M[t++]=r[3]):(M[t++]=0,M[t++]=0,M[t++]=0,M[t++]=0),R=Math.ceil(.25*t)}y&&(h=R*U,L[h++]=s[0],L[h++]=s[1],L[h++]=s[2],L[h++]=s[3],R=Math.ceil(h/U))};R+=O,n(ht,l.data[0],l.data[1],l.data[2]),y&&g(pt,w[0],w[1],w[2],w[3]),t&&f(ht,ht,t);const J=this._isClosed(i);if(J){const e=l.data.length-3;n(lt,l.data[e],l.data[e+1],l.data[e+2]),t&&f(lt,lt,t)}else n(ct,l.data[3],l.data[4],l.data[5]),t&&f(ct,ct,t),W(ht,ht,ct,pt,1,-4,0,0),W(ht,ht,ct,pt,1,4,0,0),p(lt,ht),p(ht,ct),y&&g(pt,w[4],w[5],w[6],w[7]);const Y=J?0:1,q=J?c:c-1;for(let u=Y;u<q;u++){const e=(u+1)%c*3;n(ct,l.data[e],l.data[e+1],l.data[e+2]),t&&f(ct,ct,t),k(lt,ht,u),W(lt,ht,ct,pt,0,-1,u,F),W(lt,ht,ct,pt,0,1,u,F);const i=this.numJoinSubdivisions;for(let t=0;t<i;++t){const e=(t+1)/(i+1);W(lt,ht,ct,pt,e,-1,u,F),W(lt,ht,ct,pt,e,1,u,F)}if(W(lt,ht,ct,pt,1,-2,u,F),W(lt,ht,ct,pt,1,2,u,F),p(lt,ht),p(ht,ct),y){const t=(u+1)%c*4;g(pt,w[t],w[t+1],w[t+2],w[t+3])}}J?(n(ct,l.data[3],l.data[4],l.data[5]),t&&f(ct,ct,t),F=k(lt,ht,q),W(lt,ht,ct,pt,0,-1,Y,F),W(lt,ht,ct,pt,0,1,Y,F)):(F=k(lt,ht,q),W(lt,ht,ht,pt,0,-5,q,F),W(lt,ht,ht,pt,0,5,q,F)),H(C,x+O,C,x,O);return R=H(C,R-O,C,R,O),this._parameters.wireframe&&this._addWireframeVertices(s,x,R,O),null}_addWireframeVertices(t,e,i,r){const s=new Float32Array(t.buffer,i*Float32Array.BYTES_PER_ELEMENT),a=new Float32Array(t.buffer,e*Float32Array.BYTES_PER_ELEMENT,i-e);let n=0;const o=t=>n=H(a,t,s,n,r);for(let l=0;l<a.length-1;l+=2*r)o(l),o(l+2*r),o(l+1*r),o(l+2*r),o(l+1*r),o(l+3*r)}}function H(t,e,i,r,s){for(let a=0;a<s;a++)i[r++]=t[e++];return r}function I(t,e){if(!t.isClosed)return!1;return e.get("position").indices.length>2}function K(t){return 1===t.anchor&&t.hideOnShortSegments&&"begin-end"===t.placement&&t.worldSpace}const Q=d(),Z=d(),$=d(),tt=d(),et=d(),it=i(),rt=i(),st=d(),at=d(),nt=j(),ot=j(),lt=d(),ht=d(),ct=d(),pt=_(),mt=[i(),i(),i(),i()],ut=[d(),d(),d(),d()],ft=y(),dt=y(),gt=y(),bt=y();export{X as Parameters,Y as RibbonLineMaterial};
|
|
5
|
+
import t from"../../../../core/Logger.js";import{clamp as e}from"../../../../core/mathUtils.js";import{createRenderScreenPointArray3 as i}from"../../../../core/screenUtils.js";import{secondsFromMilliseconds as r,Seconds as s}from"../../../../core/time.js";import{copy as a}from"../../../../core/libs/gl-matrix-2/math/vec2.js";import{h as n,e as o,g as l,j as h,i as p,d as c,b as m,B as u,p as f}from"../../../../chunks/vec32.js";import{create as d}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{c as g}from"../../../../chunks/vec42.js";import{ONES as _,create as b}from"../../../../core/libs/gl-matrix-2/factories/vec4f64.js";import{makeFloat16Array as S}from"../../../../geometry/support/float16.js";import{distance2 as P,fromPoints as v,create as w,closestLineSegmentPoint as j}from"../../../../geometry/support/lineSegment.js";import{fromPoints as E,create as y,signedDistance as T,getNormal as z}from"../../../../geometry/support/plane.js";import{isHighlightOrOLID as A,isColor as C,isDepth as L,isColorHighlightOLIDOrDepth as M,is2DGeometryOutput as O}from"../core/shaderLibrary/ShaderOutput.js";import{olidEnabled as V}from"../effects/geometry/olidUtils.js";import x from"../lib/GLMaterial.js";import{Material as R}from"../lib/Material.js";import{isTranslationMatrix as F}from"../lib/Util.js";import{isImagePattern as k}from"./lineStippleUtils.js";import{VisualVariablePassParameters as N}from"./VisualVariablePassParameters.js";import{writeDeltaF16Vector as U}from"./internal/bufferWriterUtils.js";import{r as B}from"../../../../chunks/RibbonLine.glsl.js";import{getLayout as D,RibbonLineTechnique as W}from"../shaders/RibbonLineTechnique.js";import{RibbonLineTechniqueConfiguration as J}from"../shaders/RibbonLineTechniqueConfiguration.js";import{alphaCutoff as I}from"../../../../webscene/support/AlphaCutoff.js";class Y extends R{constructor(t,e){super(t,X),this.produces=new Map([[2,t=>A(t)||C(t)&&8===this.parameters.renderOccluded],[3,t=>L(t)],[11,t=>M(t)&&8===this.parameters.renderOccluded],[12,t=>M(t)&&8===this.parameters.renderOccluded],[4,t=>C(t)&&this.parameters.writeDepth&&8!==this.parameters.renderOccluded],[9,t=>C(t)&&!this.parameters.writeDepth&&8!==this.parameters.renderOccluded],[19,t=>O(t)]]),this._configuration=new J(e)}getConfiguration(t,e){super.getConfiguration(t,e,this._configuration);const i=19===e.slot,r=null!=this.parameters.stipplePattern&&null!=this.parameters.stippleTexture&&8!==t,s=r&&i&&this.parameters.isImagePattern();return this._configuration.oitPass=e.oitPass,this._configuration.draped=i,this._configuration.stippleEnabled=r,this._configuration.stippleOffColorEnabled=r&&null!=this.parameters.stippleOffColor,this._configuration.stipplePreferContinuous=r&&this.parameters.stipplePreferContinuous,this._configuration.hasSlicePlane=this.parameters.hasSlicePlane,this._configuration.roundJoins="round"===this.parameters.join,this._configuration.capType=this.parameters.cap,this._configuration.applyMarkerOffset=null!=this.parameters.markerParameters&&Q(this.parameters.markerParameters),this._configuration.hasPolygonOffset=this.parameters.hasPolygonOffset,this._configuration.writeDepth=this.parameters.writeDepth,this._configuration.hasVVSize=this.parameters.hasVVSize,this._configuration.hasVVColor=this.parameters.hasVVColor,this._configuration.hasVVOpacity=this.parameters.hasVVOpacity,this._configuration.innerColorEnabled=this.parameters.innerWidth>0&&null!=this.parameters.innerColor,this._configuration.falloffEnabled=this.parameters.falloff>0,this._configuration.hasOccludees=e.hasOccludees,this._configuration.occluder=8===this.parameters.renderOccluded,this._configuration.terrainDepthTest=e.terrainDepthTest&&C(t),this._configuration.cullAboveTerrain=e.cullAboveTerrain,this._configuration.wireframe=this.parameters.wireframe,this._configuration.animation=this.parameters.animation,this._configuration.emissionSource=this.hasEmissions?1:0,this._configuration.hasScreenSizePerspective=!!this.parameters.screenSizePerspective&&!s,this._configuration.worldSizedImagePattern=s,this._configuration}get visible(){return this.parameters.color[3]>=I||null!=this.parameters.stipplePattern&&(this.parameters.stippleOffColor?.[3]??0)>I}setParameters(t,e){t.animation=this.parameters.animation,super.setParameters(t,e)}intersectDraped({attributes:t,screenToWorldRatio:i},r,s,a,n){if(!r.options.selectionMode)return;const o=t.get("size");let l=this.parameters.width;if(this.parameters.vvSize){const i=t.get("sizeFeatureAttribute").data[0];Number.isNaN(i)?l*=this.parameters.vvSize.fallback[0]:l*=e(this.parameters.vvSize.offset[0]+i*this.parameters.vvSize.factor[0],this.parameters.vvSize.minSize[0],this.parameters.vvSize.maxSize[0])}else o&&(l*=o.data[0]);const h=s[0],p=s[1],c=(l/2+4)*i;let m=Number.MAX_VALUE,u=0;const f=t.get("position").data,d=K(this.parameters,t)?f.length-2:f.length-5;for(let g=0;g<d;g+=3){const t=f[g],i=f[g+1],r=(g+3)%f.length,s=h-t,a=p-i,n=f[r]-t,o=f[r+1]-i,l=e((n*s+o*a)/(n*n+o*o),0,1),c=n*l-s,d=o*l-a,_=c*c+d*d;_<m&&(m=_,u=g/3)}m<c*c&&a(n.distance,n.normal,u)}intersect(i,r,s,f,d,g){const{options:_,camera:b,rayBegin:S,rayEnd:w}=s;if(!_.selectionMode||!i.visible||!b)return;if(!F(r))return void t.getLogger("esri.views.3d.webgl-engine.materials.RibbonLineMaterial").error("intersection assumes a translation-only matrix");const y=i.attributes,A=y.get("position").data;let C=this.parameters.width;if(this.parameters.vvSize){const t=y.get("sizeFeatureAttribute").data[0];Number.isNaN(t)||(C*=e(this.parameters.vvSize.offset[0]+t*this.parameters.vvSize.factor[0],this.parameters.vvSize.minSize[0],this.parameters.vvSize.maxSize[0]))}else y.has("size")&&(C*=y.get("size").data[0]);const L=it;a(L,s.point);const M=C*b.pixelRatio/2+4*b.pixelRatio;n(ut[0],L[0]-M,L[1]+M,0),n(ut[1],L[0]+M,L[1]+M,0),n(ut[2],L[0]+M,L[1]-M,0),n(ut[3],L[0]-M,L[1]-M,0);for(let t=0;t<4;t++)if(!b.unprojectFromRenderScreen(ut[t],ft[t]))return;E(b.eye,ft[0],ft[1],dt),E(b.eye,ft[1],ft[2],gt),E(b.eye,ft[2],ft[3],_t),E(b.eye,ft[3],ft[0],bt);let O=Number.MAX_VALUE,V=0;const x=K(this.parameters,y)?A.length-2:A.length-5;for(let t=0;t<x;t+=3){Z[0]=A[t]+r[12],Z[1]=A[t+1]+r[13],Z[2]=A[t+2]+r[14];const e=(t+3)%A.length;if($[0]=A[e]+r[12],$[1]=A[e+1]+r[13],$[2]=A[e+2]+r[14],T(dt,Z)<0&&T(dt,$)<0||T(gt,Z)<0&&T(gt,$)<0||T(_t,Z)<0&&T(_t,$)<0||T(bt,Z)<0&&T(bt,$)<0)continue;const i=b.projectToRenderScreen(Z,rt),s=b.projectToRenderScreen($,st);if(null==i||null==s)continue;if(i[2]<0&&s[2]>0){o(tt,Z,$);const t=b.frustum,e=-T(t[4],Z)/l(tt,z(t[4]));if(h(tt,tt,e),p(Z,Z,tt),!b.projectToRenderScreen(Z,i))continue}else if(i[2]>0&&s[2]<0){o(tt,$,Z);const t=b.frustum,e=-T(t[4],$)/l(tt,z(t[4]));if(h(tt,tt,e),p($,$,tt),!b.projectToRenderScreen($,s))continue}else if(i[2]<0&&s[2]<0)continue;i[2]=0,s[2]=0;const a=P(v(i,s,ot),L);a<O&&(O=a,c(at,Z),c(nt,$),V=t/3)}if(O<M*M){let t=Number.MAX_VALUE;if(j(v(at,nt,ot),v(S,w,lt),et)){o(et,et,S);const e=m(et);h(et,et,1/e),t=e/u(S,w)}g(t,et,V)}}get hasEmissions(){return this.parameters.emissiveStrength>0}createBufferWriter(){return new G(D(this.parameters),this.parameters)}createGLMaterial(t){return new q(t)}validateParameters(t){"miter"!==t.join&&(t.miterLimit=0),null!=t.markerParameters&&(t.markerScale=t.markerParameters.width/t.width)}update(t){return!!this.parameters.hasAnimation&&(this.setParameters({timeElapsed:r(t.time)},!1),0!==t.dt)}}class q extends x{constructor(){super(...arguments),this._stipplePattern=null}dispose(){super.dispose(),this._stippleTextures?.release(this._stipplePattern),this._stipplePattern=null}beginSlot(t){const{stipplePattern:e}=this._material.parameters;return this._stipplePattern!==e&&(this._material.setParameters({stippleTexture:this._stippleTextures.swap(e,this._stipplePattern)}),this._stipplePattern=e),this.getTechnique(W,t)}}class X extends N{constructor(){super(...arguments),this._width=0,this.color=_,this.join="miter",this.cap=0,this.miterLimit=5,this.writeDepth=!0,this.hasPolygonOffset=!1,this.stippleTexture=null,this.stipplePreferContinuous=!0,this.markerParameters=null,this.markerScale=1,this.hasSlicePlane=!1,this.vvFastUpdate=!1,this.isClosed=!1,this.falloff=0,this.innerWidth=0,this.wireframe=!1,this.timeElapsed=s(0),this.animation=0,this.animationSpeed=1,this.trailLength=1,this.startTime=s(0),this.endTime=s(1/0),this.emissiveStrength=0}get width(){return this.isImagePattern()?this.stipplePattern.width:this._width}set width(t){this._width=t}get transparent(){return this.color[3]<1||this.hasAnimation||null!=this.stipplePattern&&(this.stippleOffColor?.[3]??0)<1}get hasAnimation(){return 0!==this.animation}isImagePattern(){return k(this.stipplePattern)&&null!=this.stippleTexture}}class G{constructor(t,e){this.layout=t,this._parameters=e;const i=e.stipplePattern?1:0;switch(this._parameters.join){case"miter":case"bevel":this.numJoinSubdivisions=i;break;case"round":this.numJoinSubdivisions=B+i}}_isClosed(t){return K(this._parameters,t)}allocate(t){return this.layout.createBuffer(t)}elementCount(t){const e=2,i=t.get("position").indices.length/2+1,r=this._isClosed(t);let s=r?2:2*e;return s+=((r?i:i-1)-(r?0:1))*(2*this.numJoinSubdivisions+4),s+=2,this._parameters.wireframe&&(s=2+4*(s-2)),s}write(t,e,i,r,s,a){const o=this.layout,l=i.get("position"),h=l.indices,p=l.data.length/3,m=i.get("distanceToStart")?.data;h&&h.length!==2*(p-1)&&console.warn("RibbonLineMaterial does not support indices");const d=o.fields.has("sizeFeatureAttribute");let _=1,b=null;if(d){const t=i.get("sizeFeatureAttribute");1===t.data.length?_=t.data[0]:b=t.data}else _=i.get("size")?.data[0]??1;let P=[1,1,1,1],v=0,w=null;const j=o.fields.has("colorFeatureAttribute");if(j){const t=i.get("colorFeatureAttribute");1===t.data.length?v=t.data[0]:w=t.data}else P=i.get("color")?.data??P;const E=i.get("timeStamps")?.data,y=E&&o.fields.has("timeStamps"),T=o.fields.has("opacityFeatureAttribute");let z=0,A=null;if(T){const t=i.get("opacityFeatureAttribute");1===t.data.length?z=t.data[0]:A=t.data}const C=new Float32Array(s.buffer),L=S(s.buffer),M=new Uint8Array(s.buffer),O=o.stride/4;let x=a*O;const R=x;let F=0;const k=m?(t,e,i)=>F=m[i]:(t,e,i)=>F+=u(t,e),N=C.BYTES_PER_ELEMENT/L.BYTES_PER_ELEMENT,B=4/N,D=V(),W=(t,e,i,s,a,n,o,l)=>{C[x++]=e[0],C[x++]=e[1],C[x++]=e[2],U(t,e,L,x*N),x+=B,U(i,e,L,x*N),x+=B,C[x++]=l;let h=x*N;if(L[h++]=a,L[h++]=n,x=Math.ceil(h/N),j)C[x]=w?.[o]??v;else{const t=Math.min(4*o,P.length-4),e=4*x;M[e]=255*P[t],M[e+1]=255*P[t+1],M[e+2]=255*P[t+2],M[e+3]=255*P[t+3]}if(x++,C[x++]=b?.[o]??_,T&&(C[x++]=A?.[o]??z),D){let t=4*x;r?(M[t++]=r[0],M[t++]=r[1],M[t++]=r[2],M[t++]=r[3]):(M[t++]=0,M[t++]=0,M[t++]=0,M[t++]=0),x=Math.ceil(.25*t)}y&&(h=x*N,L[h++]=s[0],L[h++]=s[1],L[h++]=s[2],L[h++]=s[3],x=Math.ceil(h/N))};x+=O,n(pt,l.data[0],l.data[1],l.data[2]),y&&g(mt,E[0],E[1],E[2],E[3]),t&&f(pt,pt,t);const J=this._isClosed(i);if(J){const e=l.data.length-3;n(ht,l.data[e],l.data[e+1],l.data[e+2]),t&&f(ht,ht,t)}else n(ct,l.data[3],l.data[4],l.data[5]),t&&f(ct,ct,t),W(pt,pt,ct,mt,1,-4,0,0),W(pt,pt,ct,mt,1,4,0,0),c(ht,pt),c(pt,ct),y&&g(mt,E[4],E[5],E[6],E[7]);const I=J?0:1,Y=J?p:p-1;for(let u=I;u<Y;u++){const e=(u+1)%p*3;n(ct,l.data[e],l.data[e+1],l.data[e+2]),t&&f(ct,ct,t),k(ht,pt,u),W(ht,pt,ct,mt,0,-1,u,F),W(ht,pt,ct,mt,0,1,u,F);const i=this.numJoinSubdivisions;for(let t=0;t<i;++t){const e=(t+1)/(i+1);W(ht,pt,ct,mt,e,-1,u,F),W(ht,pt,ct,mt,e,1,u,F)}if(W(ht,pt,ct,mt,1,-2,u,F),W(ht,pt,ct,mt,1,2,u,F),c(ht,pt),c(pt,ct),y){const t=(u+1)%p*4;g(mt,E[t],E[t+1],E[t+2],E[t+3])}}J?(n(ct,l.data[3],l.data[4],l.data[5]),t&&f(ct,ct,t),F=k(ht,pt,Y),W(ht,pt,ct,mt,0,-1,I,F),W(ht,pt,ct,mt,0,1,I,F)):(F=k(ht,pt,Y),W(ht,pt,pt,mt,0,-5,Y,F),W(ht,pt,pt,mt,0,5,Y,F)),H(C,R+O,C,R,O);return x=H(C,x-O,C,x,O),this._parameters.wireframe&&this._addWireframeVertices(s,R,x,O),null}_addWireframeVertices(t,e,i,r){const s=new Float32Array(t.buffer,i*Float32Array.BYTES_PER_ELEMENT),a=new Float32Array(t.buffer,e*Float32Array.BYTES_PER_ELEMENT,i-e);let n=0;const o=t=>n=H(a,t,s,n,r);for(let l=0;l<a.length-1;l+=2*r)o(l),o(l+2*r),o(l+1*r),o(l+2*r),o(l+1*r),o(l+3*r)}}function H(t,e,i,r,s){for(let a=0;a<s;a++)i[r++]=t[e++];return r}function K(t,e){if(!t.isClosed)return!1;return e.get("position").indices.length>2}function Q(t){return 1===t.anchor&&t.hideOnShortSegments&&"begin-end"===t.placement&&t.worldSpace}const Z=d(),$=d(),tt=d(),et=d(),it=d(),rt=i(),st=i(),at=d(),nt=d(),ot=w(),lt=w(),ht=d(),pt=d(),ct=d(),mt=b(),ut=[i(),i(),i(),i()],ft=[d(),d(),d(),d()],dt=y(),gt=y(),_t=y(),bt=y();export{X as Parameters,Y as RibbonLineMaterial};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as e}from"tslib";import{getAssetUrl as s}from"../../../../../assets.js";import r from"../../../../../core/Accessor.js";import{createTask as t}from"../../../../../core/asyncUtils.js";import a from"../../../../../core/Logger.js";import{abortMaybe as o,disposeMaybe as i}from"../../../../../core/maybe.js";import{throwIfAborted as m}from"../../../../../core/promiseUtils.js";import{property as p,subclass as l}from"../../../../../core/accessorSupport/decorators.js";import{requestImage as c}from"../../../../../request/image.js";import{NoParameters as n}from"../../../../webgl/NoParameters.js";import
|
|
5
|
+
import{__decorate as e}from"tslib";import{getAssetUrl as s}from"../../../../../assets.js";import r from"../../../../../core/Accessor.js";import{createTask as t}from"../../../../../core/asyncUtils.js";import a from"../../../../../core/Logger.js";import{abortMaybe as o,disposeMaybe as i}from"../../../../../core/maybe.js";import{throwIfAborted as m}from"../../../../../core/promiseUtils.js";import{property as p,subclass as l}from"../../../../../core/accessorSupport/decorators.js";import{requestImage as c}from"../../../../../request/image.js";import{NoParameters as n}from"../../../../webgl/NoParameters.js";import u from"../../../../webgl/Texture.js";import{TextureDescriptor as h}from"../../../../webgl/TextureDescriptor.js";let g=class extends r{constructor(){super(...arguments),this._passParameters=new w,this._resourcesTask=null}get passParameters(){return this._passParameters}destroy(){this._resourcesTask=o(this._resourcesTask),this._passParameters.waveNormal=i(this._passParameters.waveNormal),this._passParameters.wavePerturbation=i(this._passParameters.wavePerturbation)}get updating(){return!!this._resourcesTask&&!this._resourcesTask.finished}ensureResources(e){return this._resourcesTask||(this._resourcesTask=t(async r=>{await Promise.allSettled([this._loadImageResource(e,s("esri/images/materials/water/normals.jpg"),e=>this._passParameters.waveNormal=e,r),this._loadImageResource(e,s("esri/images/materials/water/perturbation.jpg"),e=>this._passParameters.wavePerturbation=e,r)])})),this._resourcesTask.finished?2:1}async _loadImageResource(e,s,r,t){try{const a=await c(s,{signal:t});m(t);const o=new h(a.width,a.height);o.pixelFormat=6407,o.samplingMode=9987,o.hasMipmap=!0,o.maxAnisotropy=8,r(new u(e,o,a))}catch(o){a.getLogger(this).error("Failed to load water material normal texture.",o)}}};e([p()],g.prototype,"_resourcesTask",void 0),e([p({type:Boolean,readOnly:!0})],g.prototype,"updating",null),g=e([l("esri.views.3d.webgl-engine.materials.internal.WaterTextureRepository")],g);class w extends n{}export{w as WaterTexturePassParameters,g as WaterTextureRepository};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
const
|
|
5
|
+
import"../../../../core/has.js";import{generateUUID as t}from"../../../../core/uuid.js";const o={dash:[4,3],dot:[1,3],"long-dash":[8,3],"short-dash":[4,1],"short-dot":[1,1]},s={dash:o.dash,"dash-dot":[...o.dash,...o.dot],dot:o.dot,"long-dash":o["long-dash"],"long-dash-dot":[...o["long-dash"],...o.dot],"long-dash-dot-dot":[...o["long-dash"],...o.dot,...o.dot],none:null,"short-dash":o["short-dash"],"short-dash-dot":[...o["short-dash"],...o["short-dot"]],"short-dash-dot-dot":[...o["short-dash"],...o["short-dot"],...o["short-dot"]],"short-dot":o["short-dot"],solid:null},d=8;class n{constructor(o,s,d){this.image=o,this.width=s,this.length=d,this.uuid=t()}}function h(t){return null!=t&&"image"in t}function r(t,o){return null==t?t:{pattern:t.slice(),pixelRatio:o}}function l(t){return{pattern:[t,t],pixelRatio:2}}function a(t){switch(t?.type){case"style":return e(t.style);case"image":return new n(t.image,t.width,t.length);case void 0:case null:return null}return null}function e(t){return null!=t?r(s[t],d):null}export{n as ImagePattern,l as createStipplePatternSimple,a as getStipplePatternForLinePattern,e as getStipplePatternForPatternStyle,h as isImagePattern};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{
|
|
5
|
+
import{isImagePattern as t}from"./lineStippleUtils.js";import{ProceduralTextureRepository as e}from"./ProceduralTextureRepository.js";import{PixelType as r,SizedPixelFormat as o}from"../../../webgl/enums.js";import n from"../../../webgl/Texture.js";import{TextureDescriptor as i}from"../../../webgl/TextureDescriptor.js";function a(a,p){return new e(e=>{if(t(e))return s(a,e.image);const{data:p,textureSize:l}=u(e),m=new i(l,1);return m.dataType=r.FLOAT,m.pixelFormat=6403,m.internalFormat=o.R16F,m.wrapMode=10497,new n(a,m,p)},e=>t(e)?`image-${e.uuid}`:`${e.pattern.join(",")}-r${e.pixelRatio}`,p)}function u(t){const e=p(t),r=1/t.pixelRatio,o=l(t),n=[];let i=1;for(const u of e){for(let t=0;t<u;t++){const e=i*(Math.min(t,u-1-t)+.5)*r;n.push(e)}i=-i}const a=Math.round(e[0]/2);return{data:new Float32Array([...n.slice(a),...n.slice(0,a)]),textureSize:o}}function p(t){return t.pattern.map(e=>Math.round(e*t.pixelRatio))}function l(t){if(null==t)return 1;const e=p(t);return Math.floor(e.reduce((t,e)=>t+e))}function s(t,e){const{data:a,width:u,height:p}=e,l=new i(u,p);return l.dataType=r.UNSIGNED_BYTE,l.pixelFormat=6408,l.internalFormat=o.RGBA8,l.wrapMode={s:10497,t:33071},l.hasMipmap=!0,l.samplingMode=9987,new n(t,l,a)}export{l as computeTextureSize,a as createStippleTextureRepository,s as imageToTexture};
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
All material copyright Esri, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
See https://js.arcgis.com/5.0/esri/copyright.txt for details.
|
|
4
4
|
*/
|
|
5
|
-
import{__decorate as
|
|
5
|
+
import{__decorate as t}from"tslib";import{parameter as o}from"../core/shaderTechnique/ShaderTechniqueConfiguration.js";import{DefaultTechniqueConfiguration as e}from"../materials/DefaultTechniqueConfiguration.js";class i extends e{constructor(t){super(),this.spherical=t,this.capType=0,this.emissionSource=0,this.animation=2,this.hasPolygonOffset=!1,this.writeDepth=!1,this.draped=!1,this.stippleEnabled=!1,this.stippleOffColorEnabled=!1,this.stipplePreferContinuous=!0,this.roundJoins=!1,this.applyMarkerOffset=!1,this.hasVVSize=!1,this.hasVVColor=!1,this.hasVVOpacity=!1,this.falloffEnabled=!1,this.innerColorEnabled=!1,this.hasOccludees=!1,this.occluder=!1,this.terrainDepthTest=!1,this.cullAboveTerrain=!1,this.wireframe=!1,this.discardInvisibleFragments=!1,this.hasScreenSizePerspective=!1,this.worldSizedImagePattern=!1,this.textureCoordinateType=0,this.occlusionPass=!1,this.hasVVInstancing=!1,this.hasSliceTranslatedView=!0,this.overlayEnabled=!1,this.snowCover=!1}get hasAnimation(){return 0!==this.animation}}t([o({count:3})],i.prototype,"capType",void 0),t([o({count:8})],i.prototype,"emissionSource",void 0),t([o({count:4})],i.prototype,"animation",void 0),t([o()],i.prototype,"hasPolygonOffset",void 0),t([o()],i.prototype,"writeDepth",void 0),t([o()],i.prototype,"draped",void 0),t([o()],i.prototype,"stippleEnabled",void 0),t([o()],i.prototype,"stippleOffColorEnabled",void 0),t([o()],i.prototype,"stipplePreferContinuous",void 0),t([o()],i.prototype,"roundJoins",void 0),t([o()],i.prototype,"applyMarkerOffset",void 0),t([o()],i.prototype,"hasVVSize",void 0),t([o()],i.prototype,"hasVVColor",void 0),t([o()],i.prototype,"hasVVOpacity",void 0),t([o()],i.prototype,"falloffEnabled",void 0),t([o()],i.prototype,"innerColorEnabled",void 0),t([o()],i.prototype,"hasOccludees",void 0),t([o()],i.prototype,"occluder",void 0),t([o()],i.prototype,"terrainDepthTest",void 0),t([o()],i.prototype,"cullAboveTerrain",void 0),t([o()],i.prototype,"wireframe",void 0),t([o()],i.prototype,"discardInvisibleFragments",void 0),t([o()],i.prototype,"hasScreenSizePerspective",void 0),t([o()],i.prototype,"worldSizedImagePattern",void 0);export{i as RibbonLineTechniqueConfiguration};
|
package/views/DOMContainer.d.ts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import type DefaultUI from "./ui/DefaultUI.js";
|
|
2
|
-
import type { Mode } from "../support/modeUtils.js";
|
|
3
2
|
import type { DefaultUIProperties } from "./ui/DefaultUI.js";
|
|
4
3
|
|
|
5
4
|
export interface DOMContainerProperties extends Partial<Pick<DOMContainer, "aria" | "attributionMode">> {
|
|
@@ -81,7 +80,7 @@ export abstract class DOMContainer {
|
|
|
81
80
|
*
|
|
82
81
|
* @since 5.0
|
|
83
82
|
*/
|
|
84
|
-
accessor attributionMode:
|
|
83
|
+
accessor attributionMode: "dark" | "light" | null | undefined;
|
|
85
84
|
/**
|
|
86
85
|
* The `id` or node representing the DOM element containing the view. This is typically set in the view's constructor.
|
|
87
86
|
*
|
package/views/MapView.d.ts
CHANGED
|
@@ -104,9 +104,9 @@ export interface MapViewProperties extends View2DProperties {}
|
|
|
104
104
|
* >
|
|
105
105
|
* > **Notes**
|
|
106
106
|
* >
|
|
107
|
-
* > If the spatial reference of the [center](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#center), [extent](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#extent) or [viewpoint.targetGeometry](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#viewpoint) set in the constructor does not match the
|
|
107
|
+
* > - If the spatial reference of the [center](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#center), [extent](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#extent) or [viewpoint.targetGeometry](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#viewpoint) set in the constructor does not match the
|
|
108
108
|
* > [spatialReference](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#spatialReference) of the view, then [projectOperator](https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-operators-projectOperator.html) will be loaded dynamically.
|
|
109
|
-
* > At runtime, the [projectOperator](https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-operators-projectOperator.html) must be [loaded](https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-operators-projectOperator.html#load) when
|
|
109
|
+
* > - At runtime, the [projectOperator](https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-operators-projectOperator.html) must be [loaded](https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-operators-projectOperator.html#load) when
|
|
110
110
|
* > setting the [center](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#center), [extent](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#extent) or [viewpoint](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#viewpoint) to a spatial reference that doesn't match the view
|
|
111
111
|
* > [spatial reference](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#spatialReference). You can check if the projectOperator is
|
|
112
112
|
* > loaded prior to setting these properties by calling [isLoaded()](https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-operators-projectOperator.html#isLoaded).
|
|
@@ -165,11 +165,11 @@ export interface MapViewProperties extends View2DProperties {}
|
|
|
165
165
|
*
|
|
166
166
|
* Why doesn't setting [zoom](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#zoom) always work and why is its value `-1`? This section explains how MapView zoom and LODs work.
|
|
167
167
|
* The map's [Map#basemap](https://developers.arcgis.com/javascript/latest/api-reference/esri-Map.html#basemap) defines the MapView's [effectiveLODs](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#constraints) when the view is loaded. A [LOD](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-support-LOD.html) has
|
|
168
|
-
* a [
|
|
168
|
+
* a [scale](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-support-LOD.html#scale) and corresponding [zoom](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-support-LOD.html#level) value which can be used to navigate the map.
|
|
169
169
|
* If the MapView has valid effectiveLODs, the zoom value can be set on the MapView. In this case, the view converts it the corresponding scale, or interpolates it if the zoom is a fractional number.
|
|
170
170
|
*
|
|
171
171
|
* The MapView's [constraints.effectiveLODs](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#constraints) will be `null` if the following statements are true:
|
|
172
|
-
* * The map doesn't have a [
|
|
172
|
+
* * The map doesn't have a [basemap](https://developers.arcgis.com/javascript/latest/api-reference/esri-Map.html#basemap), or
|
|
173
173
|
* * the basemap does not have a [TileInfo](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-support-TileInfo.html),
|
|
174
174
|
* * AND the first layer added to the map does not have a [TileInfo](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-support-TileInfo.html).
|
|
175
175
|
*
|
|
@@ -246,9 +246,6 @@ export interface MapViewProperties extends View2DProperties {}
|
|
|
246
246
|
* is set to `true` (default). To enable zooming in MapView, `view.constraints.snapToZoom` must be set to `false` (default is `true`).
|
|
247
247
|
* Please see [GamepadInputDevice](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-input-gamepad-GamepadInputDevice.html) for supported devices.
|
|
248
248
|
*
|
|
249
|
-
* <details>
|
|
250
|
-
* <summary>Read More</summary>
|
|
251
|
-
*
|
|
252
249
|
* 
|
|
253
250
|
*
|
|
254
251
|
* Gamepad Action | MapView behavior
|
|
@@ -271,15 +268,13 @@ export interface MapViewProperties extends View2DProperties {}
|
|
|
271
268
|
* > [!WARNING]
|
|
272
269
|
* >
|
|
273
270
|
* > **Notes:**
|
|
274
|
-
* >
|
|
275
|
-
* >
|
|
276
|
-
* > Per [W3C Working Draft 29 October 2020](https://www.w3.org/TR/2020/WD-gamepad-20201029/),
|
|
271
|
+
* >
|
|
272
|
+
* > - [Zoom snapping](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-MapView.html#constraints) must be disabled for continuous zooming. In MapView, `snapToZoom` is `true` by default.
|
|
273
|
+
* > - Per [W3C Working Draft 29 October 2020](https://www.w3.org/TR/2020/WD-gamepad-20201029/),
|
|
277
274
|
* > gamepad functionality may not be available on some or all browsers if the web application is hosted on a
|
|
278
275
|
* > [non-secure context](https://developer.mozilla.org/en-US/docs/Web/Security/Secure_Contexts) (e.g. http rather than https).
|
|
279
276
|
* > Future versions of the ArcGIS Maps SDK for JavaScript may explicitly disable gamepad capabilities on non-secure contexts.
|
|
280
277
|
*
|
|
281
|
-
* </details>
|
|
282
|
-
*
|
|
283
278
|
* <span id="handling-events"></span>
|
|
284
279
|
* ## Handling events
|
|
285
280
|
*
|
|
@@ -350,7 +345,7 @@ export default class MapView extends View2D {
|
|
|
350
345
|
* [StreamLayer](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-StreamLayer.html), [SubtypeSublayer](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-support-SubtypeSublayer.html), [VectorTileLayer](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-VectorTileLayer.html), and [WFSLayer](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-WFSLayer.html).
|
|
351
346
|
*
|
|
352
347
|
* The [VectorTileLayer](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-VectorTileLayer.html) hit test result contains an array of objects containing a [graphic](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-types.html#GraphicHit).
|
|
353
|
-
* The graphic returns attributes of a style layer. In addition, the graphic's [
|
|
348
|
+
* The graphic returns attributes of a style layer. In addition, the graphic's [origin](https://developers.arcgis.com/javascript/latest/api-reference/esri-Graphic.html#origin) contains the style layer's
|
|
354
349
|
* [id](https://maplibre.org/maplibre-style-spec/layers/#id) and layer index within the [vector tile style](https://doc.arcgis.com/en/arcgis-online/reference/tile-layers.htm#ESRI_SECTION1_8F68399EB47B48FF9EF46719FCC96978).
|
|
355
350
|
* Spatial information about the actual feature represented in the style layer is returned only if the style layer is a [symbol layer](https://maplibre.org/maplibre-style-spec/layers/#symbol).
|
|
356
351
|
* Otherwise, the graphic's geometry is `null`.
|
|
@@ -358,7 +353,7 @@ export default class MapView extends View2D {
|
|
|
358
353
|
* The [MediaLayer](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-MediaLayer.html) hit test [result](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-types.html#MediaHit) contains all media elements if the hit is made on intersecting elements.
|
|
359
354
|
* The [RouteLayer](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-RouteLayer.html) hit test [result](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-types.html#RouteHit) contains all route elements if the hit is made on intersecting elements.
|
|
360
355
|
*
|
|
361
|
-
* If the [Polygon](https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-Polygon.html) feature's symbol [
|
|
356
|
+
* If the [Polygon](https://developers.arcgis.com/javascript/latest/api-reference/esri-geometry-Polygon.html) feature's symbol [style](https://developers.arcgis.com/javascript/latest/api-reference/esri-symbols-SimpleFillSymbol.html#style) is set to "none", the hitTest method will not
|
|
362
357
|
* return results when the fill is clicked. However, it will return results when the outline is clicked. To get results when clicking the fill, set the
|
|
363
358
|
* [SimpleFillSymbol#color](https://developers.arcgis.com/javascript/latest/api-reference/esri-symbols-SimpleFillSymbol.html#color) to a transparent color instead.
|
|
364
359
|
*
|
|
@@ -366,7 +361,7 @@ export default class MapView extends View2D {
|
|
|
366
361
|
* * At version 4.34, the [ParquetLayer](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-ParquetLayer.html) hit result returns only the topmost feature when the hit occurs on overlapping features in a ParquetLayer.
|
|
367
362
|
* * At version 4.29, [ViewHitTestResult](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-types.html#ViewHitTestResult) returns a result for all style layers from [VectorTileLayers](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-VectorTileLayer.html) that intersect the hit location.
|
|
368
363
|
* In prior releases, only the top most style layer result was returned.
|
|
369
|
-
* The hit test result returns attributes of style layers. The `layerId` and `layerIndex` information of the style layer is now returned in the graphic's [
|
|
364
|
+
* The hit test result returns attributes of style layers. The `layerId` and `layerIndex` information of the style layer is now returned in the graphic's [origin](https://developers.arcgis.com/javascript/latest/api-reference/esri-Graphic.html#origin) property.
|
|
370
365
|
* * At version 4.24, [ViewHitTestResult](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-types.html#ViewHitTestResult) returns an array of objects containing [graphic](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-types.html#GraphicHit), [media element](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-types.html#MediaHit), and [route](https://developers.arcgis.com/javascript/latest/api-reference/esri-views-types.html#RouteHit).
|
|
371
366
|
* * At version 4.23, all hit test features from feature layers are returned in the result. In prior releases, only the top most feature was returned.
|
|
372
367
|
* * At version 4.6, support for [VectorTileLayer](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-VectorTileLayer.html) was added.
|