@arcgis/core 6.0.0-next.28 → 6.0.0-next.29
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/arcgisGlobal.d.ts +0 -2
- package/assets/esri/core/workers/RemoteClient.js +1 -1
- package/assets/esri/core/workers/chunks/131185d26343a997495e.js +1 -0
- package/assets/esri/core/workers/chunks/{dbda982485d3fe26c729.js → 13c64087be3b2985a21b.js} +1 -1
- package/assets/esri/core/workers/chunks/144bad0c2415c345736a.js +1 -0
- package/assets/esri/core/workers/chunks/176d0a06ebff5a29dedf.js +1 -0
- package/assets/esri/core/workers/chunks/{b0ca81a07cff25df19d2.js → 176d75e76318bfc25a53.js} +1 -1
- package/assets/esri/core/workers/chunks/18776a130d96879a68b1.js +1 -0
- package/assets/esri/core/workers/chunks/{e35641a3a4da8cfbcf54.js → 189321d88026bd7e6d3e.js} +1 -1
- package/assets/esri/core/workers/chunks/18e7fa4d3e0b1a084cc6.js +1 -0
- package/assets/esri/core/workers/chunks/{1168bc5c9f0a7e1f63a2.js → 1989410a618865f02dec.js} +1 -1
- package/assets/esri/core/workers/chunks/{2c0cb214fedb29487eef.js → 199a7f97916679e0257c.js} +1 -1
- package/assets/esri/core/workers/chunks/1c406ab2bf99ac563316.js +1 -0
- package/assets/esri/core/workers/chunks/1d96fbad881a7d14a950.js +1 -0
- package/assets/esri/core/workers/chunks/{42d44c7d532df5ee70e9.js → 1deca3de77b1a9a07da4.js} +1 -1
- package/assets/esri/core/workers/chunks/{45f826554499c38968c6.js → 1ee4df0fd61440cb5f02.js} +1 -1
- package/assets/esri/core/workers/chunks/22e73501e1435a896826.js +1 -0
- package/assets/esri/core/workers/chunks/25657f70c5f04a4ed978.js +1 -0
- package/assets/esri/core/workers/chunks/276a0b549acf048e8673.js +1 -0
- package/assets/esri/core/workers/chunks/{56e903ccef66cbe18f92.js → 2cd60fd062d954322c1f.js} +1 -1
- package/assets/esri/core/workers/chunks/{ad96132bc89671e595f3.js → 2d3e0e4442dbc6ec6def.js} +1 -1
- package/assets/esri/core/workers/chunks/2de4296590bf9f9e9add.js +1 -0
- package/assets/esri/core/workers/chunks/2f5d014d6a72108b0b3a.js +1 -0
- package/assets/esri/core/workers/chunks/{0363d29fc665d169ebc4.js → 3105336a05f38a95ebea.js} +1 -1
- package/assets/esri/core/workers/chunks/379ef56f6b32494832a6.js +1 -0
- package/assets/esri/core/workers/chunks/3aafdb905c697bc9b1ad.js +1 -0
- package/assets/esri/core/workers/chunks/40c2674dae73f0942751.js +1 -0
- package/assets/esri/core/workers/chunks/418addce122dbb8897b4.js +1 -0
- package/assets/esri/core/workers/chunks/4419732baf3459a80e6d.js +1 -0
- package/assets/esri/core/workers/chunks/4976f5567fc7f1b63d10.js +1 -0
- package/assets/esri/core/workers/chunks/4e17665dd9048c300d87.js +1 -0
- package/assets/esri/core/workers/chunks/5396b6e99a0546a25d19.js +1 -0
- package/assets/esri/core/workers/chunks/53c7510df09b71ab5646.js +1 -0
- package/assets/esri/core/workers/chunks/561c48cb4d49b150765b.js +1 -0
- package/assets/esri/core/workers/chunks/{d90a3bfd45b5ed4092e0.js → 590fe0f56bc4c33a50e7.js} +1 -1
- package/assets/esri/core/workers/chunks/5bb6c255bdc8aa9ba23e.js +1 -0
- package/assets/esri/core/workers/chunks/5f1cb79aec9c4a9b7ddc.js +29 -0
- package/assets/esri/core/workers/chunks/{23a4806b4cdf7cc32e4d.js → 5f787809b74eed7b9a91.js} +1 -1
- package/assets/esri/core/workers/chunks/636e9c4ac1f9ae98f9d1.js +1 -0
- package/assets/esri/core/workers/chunks/654f5441227579d2b6b4.js +1 -0
- package/assets/esri/core/workers/chunks/692f0093c444fcc752b5.js +1 -0
- package/assets/esri/core/workers/chunks/69627b2634da64dd885f.js +1 -0
- package/assets/esri/core/workers/chunks/6a7de221cea4426cb490.js +1 -0
- package/assets/esri/core/workers/chunks/7030a4d0714a35995a58.js +1 -0
- package/assets/esri/core/workers/chunks/72d20d3957d612f86431.js +1 -0
- package/assets/esri/core/workers/chunks/7862abd24fb5c3b12e6b.js +1 -0
- package/assets/esri/core/workers/chunks/7a0b4dc0cda190367a39.js +1 -0
- package/assets/esri/core/workers/chunks/{5eec1c1162779574f46e.js → 7c75a8ee266c36baa902.js} +1 -1
- package/assets/esri/core/workers/chunks/{ab1660f5f8a5268c2fac.js → 84038dd85005fea413eb.js} +1 -1
- package/assets/esri/core/workers/chunks/849f446c718e892f39ce.js +1 -0
- package/assets/esri/core/workers/chunks/{8ac2098ecdc40ad41055.js → 8502274806ea52308822.js} +1 -1
- package/assets/esri/core/workers/chunks/865cebc5c982c040ab6f.js +1 -0
- package/assets/esri/core/workers/chunks/{76196c414e48834f7b92.js → 8f008eedb11685ee2048.js} +1 -1
- package/assets/esri/core/workers/chunks/90d797ab82d4a68ba32f.js +1 -0
- package/assets/esri/core/workers/chunks/9184c947cdefe06bf551.js +1 -0
- package/assets/esri/core/workers/chunks/9976eaa81085c0d17e14.js +1 -0
- package/assets/esri/core/workers/chunks/{177f353ce72133e2eeed.js → 9c2436464b7dfd666678.js} +1 -1
- package/assets/esri/core/workers/chunks/a125650edbed802e419a.js +1 -0
- package/assets/esri/core/workers/chunks/{23fd4de56de352f63e2d.js → a2196a49f89d57a0a1c7.js} +1 -1
- package/assets/esri/core/workers/chunks/ad21757d78e372fa2ed6.js +1 -0
- package/assets/esri/core/workers/chunks/b01688ccc29d33bfc82d.js +1 -0
- package/assets/esri/core/workers/chunks/b5eff28cf482d920b9ea.js +1 -0
- package/assets/esri/core/workers/chunks/{04ecf15524ff3838c01c.js → ba4520ddcb6a49988da6.js} +1 -1
- package/assets/esri/core/workers/chunks/be55771758e4bcef0976.js +1 -0
- package/assets/esri/core/workers/chunks/bead830a677690eeb6fb.js +1 -0
- package/assets/esri/core/workers/chunks/c131e0dd180a4c10e12e.js +1 -0
- package/assets/esri/core/workers/chunks/c1cf3edce15f09648eb4.js +1 -0
- package/assets/esri/core/workers/chunks/c4f78a481f43cfae7b63.js +1 -0
- package/assets/esri/core/workers/chunks/c570b90995c65bbb2e14.js +1 -0
- package/assets/esri/core/workers/chunks/c576bef77e34920af188.js +1 -0
- package/assets/esri/core/workers/chunks/c9feffb9884cfed52c4b.js +1 -0
- package/assets/esri/core/workers/chunks/cc97e4fd0dacad970a23.js +1 -0
- package/assets/esri/core/workers/chunks/ce324dde6d7daea33638.js +1 -0
- package/assets/esri/core/workers/chunks/d1d6154b4af1c9cc497b.js +1 -0
- package/assets/esri/core/workers/chunks/d3c3fb079ad97970f834.js +1 -0
- package/assets/esri/core/workers/chunks/daae21cf77864f3293ef.js +1 -0
- package/assets/esri/core/workers/chunks/dc2f93453dfa40f623ab.js +1 -0
- package/assets/esri/core/workers/chunks/dcf6024dc19428ff2b9d.js +1 -0
- package/assets/esri/core/workers/chunks/dd30b02c5978c1c5f511.js +1 -0
- package/assets/esri/core/workers/chunks/de3f140058aa0b907b65.js +1 -0
- package/assets/esri/core/workers/chunks/df375d1b0dab5ecbd1be.js +1 -0
- package/assets/esri/core/workers/chunks/{ef2c3febcceedc44b3ac.js → dfd4782b11d6fdca0492.js} +1 -1
- package/assets/esri/core/workers/chunks/{48cc58890fddbcf69cef.js → e121d15b883184ee83e7.js} +1 -1
- package/assets/esri/core/workers/chunks/{67e06d606c7fd2064adf.js → e2c6cd8dac01e129ccfe.js} +1 -1
- package/assets/esri/core/workers/chunks/e3b212f8af448ec29eef.js +1 -0
- package/assets/esri/core/workers/chunks/e4042e43f0081fe49f7b.js +1 -0
- package/assets/esri/core/workers/chunks/e480e7d5f40049a2053b.js +1 -0
- package/assets/esri/core/workers/chunks/eaab787a5f2445be5e5a.js +1 -0
- package/assets/esri/core/workers/chunks/edd36a1fc80b1d29907e.js +1 -0
- package/assets/esri/core/workers/chunks/ee0dc906cc7979080329.js +1 -0
- package/assets/esri/core/workers/chunks/f07fb9b3fa30d7ee1681.js +1 -0
- package/assets/esri/core/workers/chunks/f09bc86cd52224febfcb.js +1 -0
- package/assets/esri/core/workers/chunks/{037c67ef5c4398d5954d.js → f2dab9fcd90ce38ae3d1.js} +1 -1
- package/assets/esri/core/workers/chunks/f39c700f3db7db52b522.js +1 -0
- package/assets/esri/core/workers/chunks/f3b4159c0722df8ffe13.js +1 -0
- package/assets/esri/core/workers/chunks/f3dc0bc0e00635855a7a.js +1 -0
- package/assets/esri/core/workers/chunks/f45064066e1ab041a0b2.js +1 -0
- package/assets/esri/core/workers/chunks/{dc7aa0a1eb6c6e361f9f.js → f7398cfd8bbd041bd635.js} +1 -1
- package/assets/esri/core/workers/chunks/f9dc38761b314d33890f.js +1 -0
- package/assets/esri/core/workers/chunks/fe6dcb21570395e46ce8.js +1 -0
- package/assets/esri/core/workers/chunks/{9c4961213ac6ec283dd9.js → fefdd10bdd5a4c8d8ed0.js} +44 -47
- package/assets/esri/core/workers/chunks/ffe49d9e7df081bef4a5.js +1 -0
- package/assets/esri/themes/base/_core.scss +0 -2
- 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/Component.glsl.js +48 -48
- package/chunks/EmissionComposite.glsl.js +1 -1
- package/chunks/Fog.glsl.js +1 -1
- package/chunks/GaussianSplatDepth.glsl.js +15 -7
- package/chunks/GaussianSplatShadow.glsl.js +14 -4
- package/config.d.ts +12 -9
- package/config.js +1 -1
- package/form/FormTemplate.d.ts +1 -1
- package/form/elements/AttachmentElement.d.ts +2 -0
- package/form/elements/FieldElement.d.ts +2 -2
- package/form/elements/FieldElement.js +1 -1
- package/form/elements/RelationshipElement.d.ts +1 -1
- package/form/elements/TextElement.d.ts +2 -2
- package/form/elements/UtilityNetworkAssociationsElement.d.ts +1 -1
- package/form/elements/inputs/inputUtils.js +1 -1
- package/form/elements/inputs/types.d.ts +19 -0
- package/form/elements/inputs.d.ts +3 -2
- package/form/elements/inputs.js +1 -1
- package/interfaces.d.ts +0 -14
- package/kernel.js +1 -1
- package/layers/VideoLayer.d.ts +5 -5
- package/layers/knowledgeGraph/KnowledgeGraphSublayer.js +1 -1
- package/layers/orientedImagery/core/coverageUtils.js +1 -1
- package/layers/orientedImagery/transformations/rotationUtils.js +2 -0
- package/layers/orientedImagery/transformations/utils.js +1 -1
- package/layers/save/parquetLayerUtils.js +1 -1
- package/layers/support/vectorTileLayerLoader.js +1 -1
- package/package.json +2 -2
- package/smartMapping/support/adapters/support/histogramUtils.js +1 -1
- package/views/2d/engine/vectorTiles/TileHandler.js +1 -1
- package/views/2d/engine/vectorTiles/style/GeoJSONVectorTileSource.js +1 -1
- package/views/2d/engine/vectorTiles/style/GeoJSONVectorTileSourceWorker.js +1 -1
- package/views/2d/engine/vectorTiles/style/geoJSONVectorTileUtils.js +2 -0
- package/views/2d/engine/webgl/collisions/LabelMetric.js +1 -1
- package/views/2d/engine/webgl/collisions/LabelStore.js +1 -1
- package/views/2d/layers/VectorTileLayerView2D.js +1 -1
- package/views/2d/layers/features/FeatureContainer.js +1 -1
- package/views/2d/layers/support/visualVariableSimpleUtils.js +1 -1
- package/views/3d/state/controllers/PointToPointAnimationController.js +1 -1
- package/views/3d/support/ResourceController.js +1 -1
- package/views/3d/terrain/TerrainRenderer.js +1 -1
- package/views/3d/terrain/TerrainSurface.js +1 -1
- package/views/3d/terrain/TileAgent.js +1 -1
- package/views/3d/webgl-engine/Stage.js +1 -1
- package/views/3d/webgl-engine/collections/Component/Material/Component.glsl.js +1 -1
- package/views/3d/webgl-engine/core/shaderLibrary/attributes/RibbonVertexPosition.glsl.js +23 -26
- package/views/3d/webgl-engine/core/shaderLibrary/attributes/VertexPosition.glsl.js +18 -21
- package/views/3d/webgl-engine/core/shaderLibrary/attributes/VerticalOffset.glsl.js +5 -5
- package/views/3d/webgl-engine/core/shaderLibrary/shading/ComputeFragmentNormals.glsl.js +10 -12
- package/views/3d/webgl-engine/core/shaderLibrary/shading/EvaluateSceneLighting.glsl.js +22 -25
- package/views/3d/webgl-engine/effects/RenderPluginContext.js +2 -0
- package/views/3d/webgl-engine/effects/fog/Fog.js +1 -1
- package/views/3d/webgl-engine/effects/globalIllumination/GlobalIllumination.js +1 -1
- package/views/3d/webgl-engine/effects/glow/applyEmissiveGlow.glsl.js +3 -3
- package/views/3d/webgl-engine/effects/highlight/Highlight.js +1 -1
- package/views/3d/webgl-engine/lib/GaussianSplatDepthRenderer.js +1 -1
- package/views/3d/webgl-engine/lib/GaussianSplatRenderer.js +1 -1
- package/views/3d/webgl-engine/lib/Renderer.js +1 -1
- package/views/3d/webgl-engine/lib/edgeRendering/EdgeUtil.glsl.js +30 -35
- package/views/3d/webgl-engine/parts/RenderView.js +1 -1
- package/views/3d/webgl-engine/shaders/EmissiveTechniqueConfiguration.js +1 -1
- package/views/3d/webgl-engine/shaders/GaussianSplatPass.glsl.js +62 -53
- package/views/3d/webgl-engine/shaders/GaussianSplatTechniqueConfiguration.js +1 -1
- package/views/VideoView.d.ts +10 -0
- package/views/VideoView.js +1 -1
- package/views/layers/LayerView.d.ts +10 -2
- package/widgets/BatchAttributeForm/inputs/FieldInput.d.ts +2 -2
- package/widgets/Editor/EditorViewModel.d.ts +10 -12
- package/widgets/FeatureTable/FeatureTableViewModel.js +1 -1
- package/widgets/FeatureTable/support/EditableColumnTemplateMixin.js +1 -1
- package/widgets/OrientedImageryViewer/ImageMeasurementWorker.js +1 -1
- package/widgets/OrientedImageryViewer/adapters/sketch/MeasurementAdapter.js +1 -1
- package/widgets/OrientedImageryViewer/adapters/view/SceneViewAdapter.js +1 -1
- package/widgets/OrientedImageryViewer/imageMeasurementUtils.js +1 -1
- package/widgets/OrientedImageryViewer/imageMeasurementWorkerUtils.js +2 -0
- package/widgets/OrientedImageryViewer/services/ImageMeasurementService.js +1 -1
- package/widgets/OrientedImageryViewer/support/superimposeUtils.js +1 -1
- package/widgets/support/iconUtils.js +1 -1
- package/assets/esri/core/workers/chunks/010f57ec7fdbedf78d02.js +0 -1
- package/assets/esri/core/workers/chunks/03f33cb78b5405ab7e23.js +0 -1
- package/assets/esri/core/workers/chunks/0487e1d7a7cecf7c1c25.js +0 -1
- package/assets/esri/core/workers/chunks/09300e74e5b014ce6269.js +0 -1
- package/assets/esri/core/workers/chunks/0d9c4c6c571ce26d356b.js +0 -1
- package/assets/esri/core/workers/chunks/112ed86f812e4400a7e0.js +0 -1
- package/assets/esri/core/workers/chunks/151e5799ede763a03ee2.js +0 -1
- package/assets/esri/core/workers/chunks/173f89c55a5c79ff065b.js +0 -1
- package/assets/esri/core/workers/chunks/2447d2e2a4a3ab8fcf94.js +0 -1
- package/assets/esri/core/workers/chunks/2a36fe3f3f257a779a1b.js +0 -1
- package/assets/esri/core/workers/chunks/2a97268000c6d03ef720.js +0 -1
- package/assets/esri/core/workers/chunks/2cf8172be83b10b11bdc.js +0 -1
- package/assets/esri/core/workers/chunks/2df37a9a95ceebb87a5f.js +0 -1
- package/assets/esri/core/workers/chunks/2e00c155e447e4930442.js +0 -1
- package/assets/esri/core/workers/chunks/2f91fd61019d2a37476d.js +0 -1
- package/assets/esri/core/workers/chunks/30af63b3b750142faadb.js +0 -1
- package/assets/esri/core/workers/chunks/3a47fc97c400fca2c736.js +0 -1
- package/assets/esri/core/workers/chunks/3cd04d23b73beaf79650.js +0 -1
- package/assets/esri/core/workers/chunks/426b4eb500fdfe9df325.js +0 -1
- package/assets/esri/core/workers/chunks/45367aa8e5c5d574de94.js +0 -1
- package/assets/esri/core/workers/chunks/47c97640ec525676918b.js +0 -1
- package/assets/esri/core/workers/chunks/47d074136a7f8e551a9a.js +0 -1
- package/assets/esri/core/workers/chunks/4a6b92ecbb1f1c55cc43.js +0 -1
- package/assets/esri/core/workers/chunks/4cb751dc8d00bdaeb04c.js +0 -1
- package/assets/esri/core/workers/chunks/518ab22f80c3300bcfff.js +0 -1
- package/assets/esri/core/workers/chunks/53ff68d4f9e365fc15cd.js +0 -1
- package/assets/esri/core/workers/chunks/58609bf94f72bc4f1952.js +0 -1
- package/assets/esri/core/workers/chunks/586a929bc037e23857af.js +0 -1
- package/assets/esri/core/workers/chunks/5c7780f804d789cb37f5.js +0 -1
- package/assets/esri/core/workers/chunks/5d76f4d97beee494bbbf.js +0 -1
- package/assets/esri/core/workers/chunks/603fdbbe9534c614928f.js +0 -1
- package/assets/esri/core/workers/chunks/611e3cdf67283c11576f.js +0 -1
- package/assets/esri/core/workers/chunks/6431480ba0fa8c8d487f.js +0 -1
- package/assets/esri/core/workers/chunks/652faf4359ac072c5dde.js +0 -1
- package/assets/esri/core/workers/chunks/65c98f3449044fa4fd79.js +0 -1
- package/assets/esri/core/workers/chunks/6b9961261241fdce0e94.js +0 -1
- package/assets/esri/core/workers/chunks/6dfe96b056bec30068df.js +0 -1
- package/assets/esri/core/workers/chunks/6f897b4e7ddd1dd1672b.js +0 -1
- package/assets/esri/core/workers/chunks/70cc2d79653d66e85b58.js +0 -1
- package/assets/esri/core/workers/chunks/7159d9c36869cd82599e.js +0 -29
- package/assets/esri/core/workers/chunks/7393f63043a1da3d05a6.js +0 -1
- package/assets/esri/core/workers/chunks/7449568eb2305bf2d650.js +0 -1
- package/assets/esri/core/workers/chunks/75d551a449bba61ce238.js +0 -1
- package/assets/esri/core/workers/chunks/76e27e36050a3dd9d249.js +0 -1
- package/assets/esri/core/workers/chunks/76f877e2d2493d56afab.js +0 -1
- package/assets/esri/core/workers/chunks/7748c2886d0122b40eeb.js +0 -1
- package/assets/esri/core/workers/chunks/78643f116677950ea29a.js +0 -1
- package/assets/esri/core/workers/chunks/78fbe330f16bdbdb886e.js +0 -1
- package/assets/esri/core/workers/chunks/7e0f04a5038e2a4f6e4b.js +0 -1
- package/assets/esri/core/workers/chunks/7f16ae01ccd9b6114d1c.js +0 -1
- package/assets/esri/core/workers/chunks/90153b5230b3a4985c14.js +0 -1
- package/assets/esri/core/workers/chunks/9189dfe19a2a2ccd5173.js +0 -1
- package/assets/esri/core/workers/chunks/943a0f140813ee4ab04a.js +0 -1
- package/assets/esri/core/workers/chunks/98be2f621801e230aa01.js +0 -1
- package/assets/esri/core/workers/chunks/99f51d5d9da6e9bfc430.js +0 -1
- package/assets/esri/core/workers/chunks/9aebe876b1a2fb075f9c.js +0 -1
- package/assets/esri/core/workers/chunks/9b6929faf649e81265fb.js +0 -1
- package/assets/esri/core/workers/chunks/9dd48e75b4e8d9811d81.js +0 -1
- package/assets/esri/core/workers/chunks/a163c6005aba3378edaa.js +0 -1
- package/assets/esri/core/workers/chunks/a8286febe371dc186aaa.js +0 -1
- package/assets/esri/core/workers/chunks/acb265a22be5e12f38e5.js +0 -1
- package/assets/esri/core/workers/chunks/b12acf1f694f82e00df9.js +0 -1
- package/assets/esri/core/workers/chunks/b83cef2d3f528726d492.js +0 -1
- package/assets/esri/core/workers/chunks/b9596d862da1ec342cd3.js +0 -1
- package/assets/esri/core/workers/chunks/bc1fcc9c897461e68e29.js +0 -1
- package/assets/esri/core/workers/chunks/bdc221d94300c225665a.js +0 -1
- package/assets/esri/core/workers/chunks/be97a629e2ae4d13ceb3.js +0 -1
- package/assets/esri/core/workers/chunks/bfb39590c548188f5052.js +0 -1
- package/assets/esri/core/workers/chunks/c2318c014e97ba519be8.js +0 -1
- package/assets/esri/core/workers/chunks/c62237c344e341619341.js +0 -1
- package/assets/esri/core/workers/chunks/cdb5c26fed7d9a97db49.js +0 -1
- package/assets/esri/core/workers/chunks/cdf0c7706d3e1221f49b.js +0 -1
- package/assets/esri/core/workers/chunks/cea0db3ee326f60610eb.js +0 -1
- package/assets/esri/core/workers/chunks/d7f2f1708d2a2668676c.js +0 -1
- package/assets/esri/core/workers/chunks/daf9b691817e83a11f3c.js +0 -1
- package/assets/esri/core/workers/chunks/db41490bd39d863305bf.js +0 -1
- package/assets/esri/core/workers/chunks/ddc95cdac6c06fc4794c.js +0 -1
- package/assets/esri/core/workers/chunks/df26ec0b508cf4716e0a.js +0 -1
- package/assets/esri/core/workers/chunks/e11159e3dc3353b27c57.js +0 -1
- package/assets/esri/core/workers/chunks/e4a57a0a9629faafd6c6.js +0 -1
- package/assets/esri/core/workers/chunks/ebc1a2ef3aed8aa29424.js +0 -1
- package/assets/esri/core/workers/chunks/ec1c4d66142b6efb0e8b.js +0 -1
- package/assets/esri/core/workers/chunks/ef12fa3574d4cbf8b084.js +0 -1
- package/assets/esri/core/workers/chunks/f2d56f5c15d5977e1d19.js +0 -1
- package/assets/esri/core/workers/chunks/f7bfa3d33b05b250ce33.js +0 -1
- package/assets/esri/core/workers/chunks/f905f1a1aa4c123cbe83.js +0 -1
- package/assets/esri/core/workers/chunks/fc139f251dc0523074e7.js +0 -1
- package/assets/esri/themes/base/widgets/_VideoPlayer.scss +0 -129
- package/assets/esri/widgets/VideoPlayer/t9n/messages.ar.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.bg.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.bs.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.ca.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.cs.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.da.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.de.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.el.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.en.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.es.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.et.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.fi.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.fr.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.he.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.hr.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.hu.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.id.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.it.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.ja.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.ko.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.lt.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.lv.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.nl.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.no.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.pl.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.pt-BR.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.pt-PT.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.ro.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.ru.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.sk.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.sl.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.sr.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.sv.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.th.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.tr.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.uk.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.vi.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.zh-CN.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.zh-HK.json +0 -1
- package/assets/esri/widgets/VideoPlayer/t9n/messages.zh-TW.json +0 -1
- package/widgets/VideoPlayer/VideoPlayerViewModel.d.ts +0 -232
- package/widgets/VideoPlayer/VideoPlayerViewModel.js +0 -2
- package/widgets/VideoPlayer/components/MetadataSection.js +0 -2
- package/widgets/VideoPlayer/components/PlayerActionsGroup.js +0 -2
- package/widgets/VideoPlayer/components/PlayerControlsGroup.js +0 -2
- package/widgets/VideoPlayer/components/SettingsButton.js +0 -2
- package/widgets/VideoPlayer/css.js +0 -2
- package/widgets/VideoPlayer.d.ts +0 -119
- package/widgets/VideoPlayer.js +0 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3527],{68197(e,t,r){r.d(t,{A:()=>h});var n=r(40876),i=r(4576),a=r(34727),s=r(78888);function o(e){return(0,a.qE)((0,s.Vr)(e),0,255)}function l(e,t){let r=e.toString(16).padStart(2,"0");return t?r.slice(0,1):r}function u(e){return.2126*(0,n.Q6)(e.r)+.7152*(0,n.Q6)(e.g)+.0722*(0,n.Q6)(e.b)}class h{static blendColors(e,t,r,n=new h){return n.r=Math.round(e.r+(t.r-e.r)*r),n.g=Math.round(e.g+(t.g-e.g)*r),n.b=Math.round(e.b+(t.b-e.b)*r),n.a=e.a+(t.a-e.a)*r,n._sanitize()}static fromRgb(e,t){let r=(0,n.lT)(e);return r?h.fromArray(r,t):null}static fromHex(e,t=new h){let r=(0,n.oW)(e);return r?h.fromArray(r,t):null}static fromArray(e,t=new h){return t._set(Number(e[0]),Number(e[1]),Number(e[2]),Number(e[3])),isNaN(t.a)&&(t.a=1),t._sanitize()}static fromString(e,t){let r=(0,n.Eq)(e);return r?h.fromArray(r,t):null}static fromJSON(e){return null==e?void 0:new h([e[0],e[1],e[2],(e[3]??255)/255])}toUnitRGB(){return[this.r/255,this.g/255,this.b/255]}toUnitRGBA(e){return e??=[0,0,0,0],e[0]=this.r/255,e[1]=this.g/255,e[2]=this.b/255,e[3]=null==this.a?1:this.a,e}constructor(e){this.r=255,this.g=255,this.b=255,this.a=1,e&&this.setColor(e)}get isBright(){return this.toYiq()>=127}isLowContrastBlend(e,t=3){let r=e instanceof h?e:new h(e),n=u(this),i=u(r);return(Math.max(n,i)+.05)/(Math.min(n,i)+.05)<t}setColor(e){if("string"==typeof e)h.fromString(e,this);else if((0,i.yc)(e))h.fromArray(e,this);else{let t=e;this._set(t.r??0,t.g??0,t.b??0,t.a??1),e instanceof h||this._sanitize()}return this}toRgb(){return[this.r,this.g,this.b]}toRgba(){return[this.r,this.g,this.b,this.a]}toHex(e){let t=e?.capitalize??!1,r=e?.digits??6,n=3===r||4===r,i=4===r||8===r,a=`#${l(this.r,n)}${l(this.g,n)}${l(this.b,n)}${i?l(Math.round(255*this.a),n):""}`;return t?a.toUpperCase():a}toYiq(){return.299*this.r+.587*this.g+.114*this.b}toCss(e=!1){let t=this.r+", "+this.g+", "+this.b;return e?`rgba(${t}, ${this.a})`:`rgb(${t})`}toString(){return this.toCss(!0)}toJSON(){return this.toArray()}toArray(e=0){let t=o(this.r),r=o(this.g),n=o(this.b);return 0===e||1!==this.a?[t,r,n,o(255*this.a)]:[t,r,n]}clone(){return new h(this.toRgba())}hash(){return this.r<<24|this.g<<16|this.b<<8|255*this.a}equals(e){return null!=e&&e.r===this.r&&e.g===this.g&&e.b===this.b&&e.a===this.a}_sanitize(){return this.r=(0,n.c1)(this.r),this.g=(0,n.c1)(this.g),this.b=(0,n.c1)(this.b),this.a=(0,n.G1)(this.a),this}_set(e,t,r,n){this.r=e,this.g=t,this.b=r,this.a=n}}h.prototype.declaredClass="esri.Color"},40876(e,t,r){r.d(t,{Eq:()=>f,G1:()=>m,Q6:()=>y,TS:()=>a,V6:()=>i,Vm:()=>g,ay:()=>l,c1:()=>p,c4:()=>s,j5:()=>u,lT:()=>c,oW:()=>h,xV:()=>v});const n={transparent:[0,0,0,0],black:[0,0,0,1],silver:[192,192,192,1],gray:[128,128,128,1],white:[255,255,255,1],maroon:[128,0,0,1],red:[255,0,0,1],purple:[128,0,128,1],fuchsia:[255,0,255,1],green:[0,128,0,1],lime:[0,255,0,1],olive:[128,128,0,1],yellow:[255,255,0,1],navy:[0,0,128,1],blue:[0,0,255,1],teal:[0,128,128,1],aqua:[0,255,255,1],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],blanchedalmond:[255,235,205,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],oldlace:[253,245,230,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],rebeccapurple:[102,51,153,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],whitesmoke:[245,245,245,1],yellowgreen:[154,205,50,1]};function i(e){return!!n[e]||!!n[e.toLowerCase()]}function a(e){return n[e]??n[e.toLowerCase()]}function s(e){return[...a(e)]}function o(e,t,r){r<0&&++r,r>1&&--r;let n=6*r;return n<1?e+(t-e)*n:2*r<1?t:3*r<2?e+(t-e)*(2/3-r)*6:e}function l(e,t,r,n=1){let i=(e%360+360)%360/360,a=r<=.5?r*(t+1):r+t-r*t,s=2*r-a;return[Math.round(255*o(s,a,i+1/3)),Math.round(255*o(s,a,i)),Math.round(255*o(s,a,i-1/3)),n]}function u(e){let t=e.length>5,r=t?8:4,n=(1<<r)-1,i=t?1:17,a=t?9===e.length:5===e.length,s=Number("0x"+e.slice(1));if(isNaN(s))return null;let o,l=[0,0,0,1];return a&&(o=s&n,s>>=r,l[3]=i*o/255),o=s&n,s>>=r,l[2]=i*o,o=s&n,s>>=r,l[1]=i*o,o=s&n,s>>=r,l[0]=i*o,l}function h(e){if(!e.startsWith("#")||isNaN(Number(`0x${e.slice(1)}`)))return null;switch(e.length){case 4:case 5:{let t=parseInt(e.slice(1,2),16),r=parseInt(e.slice(2,3),16),n=parseInt(e.slice(3,4),16),i=4===e.length?15:parseInt(e.slice(4),16);return[t+16*t,r+16*r,n+16*n,(i+16*i)/255]}case 7:case 9:return[parseInt(e.slice(1,3),16),parseInt(e.slice(3,5),16),parseInt(e.slice(5,7),16),(7===e.length?255:parseInt(e.slice(7),16))/255];default:return null}}function c(e){let t=e.toLowerCase().match(/^(rgba?|hsla?)\(([\s.\-,%0-9]+)\)/);if(t){let e=t[2].split(/\s*,\s*/),r=t[1];if("rgb"===r&&3===e.length||"rgba"===r&&4===e.length){if(e[0].endsWith("%")){let t=e.map(e=>2.56*parseFloat(e));return 4===e.length&&(t[3]=parseFloat(e[3])),d(t)}return d(e.map(e=>parseFloat(e)))}if("hsl"===r&&3===e.length||"hsla"===r&&4===e.length)return l(parseFloat(e[0]),parseFloat(e[1])/100,parseFloat(e[2])/100,parseFloat(e[3]??"1"))}return null}function d(e){return e[0]=p(e[0]),e[1]=p(e[1]),e[2]=p(e[2]),e[3]=4===e.length?m(e[3]):1,e}function f(e){let t=i(e)?a(e):null;return t??=c(e),t??=h(e),t}function g(e){let t=f(e);return null==t?null:[t[0]/255,t[1]/255,t[2]/255,t[3]]}function m(e){return b(e,0,1)}function p(e){return Math.round(b(e,0,255))}function b(e,t,r){return e=Number(e),isNaN(e)?r:e<t?t:e>r?r:e}const _=1/2.2;function y(e){return e**2.2}function v(e){return e**_}r.d(t,["iw",0,_])},85334(e,t,r){r.d(t,{$:()=>_,IB:()=>o,Iy:()=>S,KV:()=>R,N2:()=>y,RH:()=>E,ZD:()=>v,sn:()=>M});var n=r(68197),i=r(4576),a=r(4718),s=r(34727);function o(e){return"r"in e&&"g"in e&&"b"in e}function l(e){return"h"in e&&"s"in e&&"v"in e}function u(e){return"l"in e&&"a"in e&&"b"in e}function h(e){return"l"in e&&"c"in e&&"h"in e}r(78955),r(91829);const c=[[.4124,.3576,.1805],[.2126,.7152,.0722],[.0193,.1192,.9505]],d=[[3.2406,-1.5372,-.4986],[-.9689,1.8758,.0415],[.0557,-.204,1.057]];function f(e,t){let r,n,i=[];if(e[0].length!==t.length)throw Error("dimensions do not match");let a=e.length,s=e[0].length,o=0;for(r=0;r<a;r++){for(o=0,n=0;n<s;n++)o+=e[r][n]*t[n];i.push(o)}return i}function g(e){let t=[e.r/255,e.g/255,e.b/255].map(e=>e<=.04045?e/12.92:((e+.055)/1.055)**2.4),r=f(c,t);return{x:100*r[0],y:100*r[1],z:100*r[2]}}function m(e){let t=f(d,[e.x/100,e.y/100,e.z/100]).map(e=>{let t=e<=.0031308?12.92*e:1.055*e**(1/2.4)-.055;return Math.min(1,Math.max(t,0))});return{r:Math.round(255*t[0]),g:Math.round(255*t[1]),b:Math.round(255*t[2])}}function p(e){let t=[e.x/95.047,e.y/100,e.z/108.883].map(e=>e>(6/29)**3?e**(1/3):1/3*(29/6)**2*e+4/29);return{l:116*t[1]-16,a:500*(t[0]-t[1]),b:200*(t[1]-t[2])}}function b(e){let t=e.l,r=[(t+16)/116+e.a/500,(t+16)/116,(t+16)/116-e.b/200].map(e=>e>6/29?e**3:3*(6/29)**2*(e-4/29));return{x:95.047*r[0],y:100*r[1],z:108.883*r[2]}}function _(e){return o(e)?e:h(e)?function(e){return m(b(function(e){let t=e.l,r=e.c,n=e.h;return{l:t,a:r*Math.cos(n),b:r*Math.sin(n)}}(e)))}(e):u(e)?function(e){return m(b(e))}(e):function(e){return"x"in e&&"y"in e&&"z"in e}(e)?m(e):l(e)?function(e){let t,r=(e.h+360)%360/60,n=e.s/100,i=e.v/100*255,a=i*n,s=a*(1-Math.abs(r%2-1));switch(Math.floor(r)){case 0:t={r:a,g:s,b:0};break;case 1:t={r:s,g:a,b:0};break;case 2:t={r:0,g:a,b:s};break;case 3:t={r:0,g:s,b:a};break;case 4:t={r:s,g:0,b:a};break;case 5:case 6:t={r:a,g:0,b:s};break;default:t={r:0,g:0,b:0}}return t.r=Math.round(t.r+i-a),t.g=Math.round(t.g+i-a),t.b=Math.round(t.b+i-a),t}(e):e}function y(e){return l(e)?e:function(e){let{r:t,g:r,b:n}=e,i=Math.max(t,r,n),a=i-Math.min(t,r,n),s=i,o=0===a?0:i===t?(r-n)/a%6:i===r?(n-t)/a+2:(t-r)/a+4,l=0===a?0:a/s;return o<0&&(o+=6),o*=60,l*=100,s*=100/255,{h:o,s:l,v:s}}(_(e))}function v(e){return u(e)?e:function(e){return p(g(e))}(_(e))}function E(e){return h(e)?e:function(e){return function(e){let t=e.l,r=e.a,n=e.b,i=Math.sqrt(r*r+n*n),a=Math.atan2(n,r);return a=a>0?a:a+2*Math.PI,{l:t,c:i,h:a}}(p(g(e)))}(_(e))}function R(e){return e[0]??=0,e[1]??=0,e[2]??=0,e}function M(e){return e.length=4,R(e),e[3]??=1,(0,s.qE)(e[3],0,1),e}function S(e,t,r={}){if(0===e.length||t<=0)return[];if(1===(e=e.map(e=>"string"==typeof e?new n.A(e):e)).length||1===t){let r=[],n=e[0];for(let e=0;e<t;e++)r.push(n.clone());return r}if(r.shuffle&&(e=(0,i.k4)((0,a.o8)(e),r.seed)),e.length>=t){let r=[],n=(e.length-1)/(t-1);for(let i=0;i<t;i++){let t=Math.round(i*n);r.push(e[t].clone())}return r}return function(e,t,r={}){let n=[],a=e.length-1,s=Math.ceil((t-e.length)/a);e:for(let i=0;i<a;i++){let a=e[i],o=e[i+1];for(let i=1;i<=s;i++){let l=i/(s+1);if(n.push(x(a,o,l,r)),n.length+e.length===t)break e}}return[...e.map(e=>e.clone()),...(0,i.k4)(n,r.seed??1)]}(e,t,r)}const T=(e,t)=>{let r=Math.floor(10*t())-5;return Math.min(255,Math.max(0,e+r))};function x(e,t,r,a={}){let s=e.r,o=e.g,l=e.b,u=t.r,h=t.g,c=t.b,d=Math.round(s+(u-s)*r),f=Math.round(o+(h-o)*r),g=Math.round(l+(c-l)*r);if(!a.offset)return new n.A([d,f,g]);let m=(0,i.Mo)(a.seed);return new n.A([T(d,m),T(f,m),T(g,m)])}},9093(e,t,r){function n(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}function i(e){return[e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8],e[9],e[10],e[11],e[12],e[13],e[14],e[15]]}r.d(t,{o8:()=>i,vt:()=>n});const a=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:a,clone:i,create:n,fromValues:function(e,t,r,n,i,a,s,o,l,u,h,c,d,f,g,m){return[e,t,r,n,i,a,s,o,l,u,h,c,d,f,g,m]}},Symbol.toStringTag,{value:"Module"})),r.d(t,["zK",0,a])},58083(e,t,r){r.d(t,{$0:()=>b,$h:()=>I,B8:()=>h,C:()=>a,D_:()=>o,N9:()=>y,O7:()=>x,Qw:()=>u,Tl:()=>d,X_:()=>M,e$:()=>g,eL:()=>m,hM:()=>_,hZ:()=>s,hs:()=>f,kN:()=>p,l:()=>S,lw:()=>c,mg:()=>l,o1:()=>T,sC:()=>R,t2:()=>C,t5:()=>A,tZ:()=>O,ut:()=>N});var n=r(51850),i=r(34304);function a(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}function s(e,t,r,n,i,a,s,o,l,u,h,c,d,f,g,m,p){return e[0]=t,e[1]=r,e[2]=n,e[3]=i,e[4]=a,e[5]=s,e[6]=o,e[7]=l,e[8]=u,e[9]=h,e[10]=c,e[11]=d,e[12]=f,e[13]=g,e[14]=m,e[15]=p,e}function o(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function l(e,t){if(e===t){let r=t[1],n=t[2],i=t[3],a=t[6],s=t[7],o=t[11];e[1]=t[4],e[2]=t[8],e[3]=t[12],e[4]=r,e[6]=t[9],e[7]=t[13],e[8]=n,e[9]=a,e[11]=t[14],e[12]=i,e[13]=s,e[14]=o}else e[0]=t[0],e[1]=t[4],e[2]=t[8],e[3]=t[12],e[4]=t[1],e[5]=t[5],e[6]=t[9],e[7]=t[13],e[8]=t[2],e[9]=t[6],e[10]=t[10],e[11]=t[14],e[12]=t[3],e[13]=t[7],e[14]=t[11],e[15]=t[15];return e}function u(e,t){return h(e,t)||o(e),e}function h(e,t){let r=t[0],n=t[1],i=t[2],a=t[3],s=t[4],o=t[5],l=t[6],u=t[7],h=t[8],c=t[9],d=t[10],f=t[11],g=t[12],m=t[13],p=t[14],b=t[15],_=r*o-n*s,y=r*l-i*s,v=r*u-a*s,E=n*l-i*o,R=n*u-a*o,M=i*u-a*l,S=h*m-c*g,T=h*p-d*g,x=h*b-f*g,I=c*p-d*m,A=c*b-f*m,w=d*b-f*p,C=_*w-y*A+v*I+E*x-R*T+M*S;return C?(C=1/C,e[0]=(o*w-l*A+u*I)*C,e[1]=(i*A-n*w-a*I)*C,e[2]=(m*M-p*R+b*E)*C,e[3]=(d*R-c*M-f*E)*C,e[4]=(l*x-s*w-u*T)*C,e[5]=(r*w-i*x+a*T)*C,e[6]=(p*v-g*M-b*y)*C,e[7]=(h*M-d*v+f*y)*C,e[8]=(s*A-o*x+u*S)*C,e[9]=(n*x-r*A-a*S)*C,e[10]=(g*R-m*v+b*_)*C,e[11]=(c*v-h*R-f*_)*C,e[12]=(o*T-s*I-l*S)*C,e[13]=(r*I-n*T+i*S)*C,e[14]=(m*y-g*E-p*_)*C,e[15]=(h*E-c*y+d*_)*C,e):null}function c(e,t,r){let n=t[0],i=t[1],a=t[2],s=t[3],o=t[4],l=t[5],u=t[6],h=t[7],c=t[8],d=t[9],f=t[10],g=t[11],m=t[12],p=t[13],b=t[14],_=t[15],y=r[0],v=r[1],E=r[2],R=r[3];return e[0]=y*n+v*o+E*c+R*m,e[1]=y*i+v*l+E*d+R*p,e[2]=y*a+v*u+E*f+R*b,e[3]=y*s+v*h+E*g+R*_,y=r[4],v=r[5],E=r[6],R=r[7],e[4]=y*n+v*o+E*c+R*m,e[5]=y*i+v*l+E*d+R*p,e[6]=y*a+v*u+E*f+R*b,e[7]=y*s+v*h+E*g+R*_,y=r[8],v=r[9],E=r[10],R=r[11],e[8]=y*n+v*o+E*c+R*m,e[9]=y*i+v*l+E*d+R*p,e[10]=y*a+v*u+E*f+R*b,e[11]=y*s+v*h+E*g+R*_,y=r[12],v=r[13],E=r[14],R=r[15],e[12]=y*n+v*o+E*c+R*m,e[13]=y*i+v*l+E*d+R*p,e[14]=y*a+v*u+E*f+R*b,e[15]=y*s+v*h+E*g+R*_,e}function d(e,t,r){let n=r[0],i=r[1],a=r[2];if(t===e)e[12]=t[0]*n+t[4]*i+t[8]*a+t[12],e[13]=t[1]*n+t[5]*i+t[9]*a+t[13],e[14]=t[2]*n+t[6]*i+t[10]*a+t[14],e[15]=t[3]*n+t[7]*i+t[11]*a+t[15];else{let r=t[0],s=t[1],o=t[2],l=t[3],u=t[4],h=t[5],c=t[6],d=t[7],f=t[8],g=t[9],m=t[10],p=t[11];e[0]=r,e[1]=s,e[2]=o,e[3]=l,e[4]=u,e[5]=h,e[6]=c,e[7]=d,e[8]=f,e[9]=g,e[10]=m,e[11]=p,e[12]=r*n+u*i+f*a+t[12],e[13]=s*n+h*i+g*a+t[13],e[14]=o*n+c*i+m*a+t[14],e[15]=l*n+d*i+p*a+t[15]}return e}function f(e,t,r){let n=r[0],i=r[1],a=r[2];return e[0]=t[0]*n,e[1]=t[1]*n,e[2]=t[2]*n,e[3]=t[3]*n,e[4]=t[4]*i,e[5]=t[5]*i,e[6]=t[6]*i,e[7]=t[7]*i,e[8]=t[8]*a,e[9]=t[9]*a,e[10]=t[10]*a,e[11]=t[11]*a,e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}function g(e,t,r,n){let s=n[0],o=n[1],l=n[2],u=Math.sqrt(s*s+o*o+l*l);if(u<=(0,i.FD)())return void a(e,t);u=1/u,s*=u,o*=u,l*=u;let h=Math.sin(r),c=Math.cos(r),d=1-c,f=t[0],g=t[1],m=t[2],p=t[3],b=t[4],_=t[5],y=t[6],v=t[7],E=t[8],R=t[9],M=t[10],S=t[11],T=s*s*d+c,x=o*s*d+l*h,I=l*s*d-o*h,A=s*o*d-l*h,w=o*o*d+c,C=l*o*d+s*h,N=s*l*d+o*h,O=o*l*d-s*h,L=l*l*d+c;e[0]=f*T+b*x+E*I,e[1]=g*T+_*x+R*I,e[2]=m*T+y*x+M*I,e[3]=p*T+v*x+S*I,e[4]=f*A+b*w+E*C,e[5]=g*A+_*w+R*C,e[6]=m*A+y*w+M*C,e[7]=p*A+v*w+S*C,e[8]=f*N+b*O+E*L,e[9]=g*N+_*O+R*L,e[10]=m*N+y*O+M*L,e[11]=p*N+v*O+S*L,t!==e&&(e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15])}function m(e,t,r){let n=Math.sin(r),i=Math.cos(r),a=t[4],s=t[5],o=t[6],l=t[7],u=t[8],h=t[9],c=t[10],d=t[11];return t!==e&&(e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e[4]=a*i+u*n,e[5]=s*i+h*n,e[6]=o*i+c*n,e[7]=l*i+d*n,e[8]=u*i-a*n,e[9]=h*i-s*n,e[10]=c*i-o*n,e[11]=d*i-l*n,e}function p(e,t){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=t[0],e[13]=t[1],e[14]=t[2],e[15]=1,e}function b(e,t,r){if(0===t)return o(e);let n=r[0],a=r[1],s=r[2],l=Math.sqrt(n*n+a*a+s*s);if(l<=(0,i.FD)())return null;l=1/l,n*=l,a*=l,s*=l;let u=Math.sin(t),h=Math.cos(t),c=1-h;return e[0]=n*n*c+h,e[1]=a*n*c+s*u,e[2]=s*n*c-a*u,e[3]=0,e[4]=n*a*c-s*u,e[5]=a*a*c+h,e[6]=s*a*c+n*u,e[7]=0,e[8]=n*s*c+a*u,e[9]=a*s*c-n*u,e[10]=s*s*c+h,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function _(e,t){let r=Math.sin(t),n=Math.cos(t);return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=n,e[6]=r,e[7]=0,e[8]=0,e[9]=-r,e[10]=n,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function y(e,t){let r=Math.sin(t),n=Math.cos(t);return e[0]=n,e[1]=r,e[2]=0,e[3]=0,e[4]=-r,e[5]=n,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function v(e,t,r){let n=t[0],i=t[1],a=t[2],s=t[3],o=n+n,l=i+i,u=a+a,h=n*o,c=n*l,d=n*u,f=i*l,g=i*u,m=a*u,p=s*o,b=s*l,_=s*u;return e[0]=1-(f+m),e[1]=c+_,e[2]=d-b,e[3]=0,e[4]=c-_,e[5]=1-(h+m),e[6]=g+p,e[7]=0,e[8]=d+b,e[9]=g-p,e[10]=1-(h+f),e[11]=0,e[12]=r[0],e[13]=r[1],e[14]=r[2],e[15]=1,e}const E=(0,n.vt)();function R(e,t){return e[0]=t[12],e[1]=t[13],e[2]=t[14],e}function M(e,t){let r=t[0],n=t[1],i=t[2],a=t[4],s=t[5],o=t[6],l=t[8],u=t[9],h=t[10];return e[0]=Math.sqrt(r*r+n*n+i*i),e[1]=Math.sqrt(a*a+s*s+o*o),e[2]=Math.sqrt(l*l+u*u+h*h),e}function S(e,t){let r=t[0]+t[5]+t[10],n=0;return r>0?(n=2*Math.sqrt(r+1),e[3]=.25*n,e[0]=(t[6]-t[9])/n,e[1]=(t[8]-t[2])/n,e[2]=(t[1]-t[4])/n):t[0]>t[5]&&t[0]>t[10]?(n=2*Math.sqrt(1+t[0]-t[5]-t[10]),e[3]=(t[6]-t[9])/n,e[0]=.25*n,e[1]=(t[1]+t[4])/n,e[2]=(t[8]+t[2])/n):t[5]>t[10]?(n=2*Math.sqrt(1+t[5]-t[0]-t[10]),e[3]=(t[8]-t[2])/n,e[0]=(t[1]+t[4])/n,e[1]=.25*n,e[2]=(t[6]+t[9])/n):(n=2*Math.sqrt(1+t[10]-t[0]-t[5]),e[3]=(t[1]-t[4])/n,e[0]=(t[8]+t[2])/n,e[1]=(t[6]+t[9])/n,e[2]=.25*n),e}function T(e,t,r,n){let i=t[0],a=t[1],s=t[2],o=t[3],l=i+i,u=a+a,h=s+s,c=i*l,d=i*u,f=i*h,g=a*u,m=a*h,p=s*h,b=o*l,_=o*u,y=o*h,v=n[0],E=n[1],R=n[2];return e[0]=(1-(g+p))*v,e[1]=(d+y)*v,e[2]=(f-_)*v,e[3]=0,e[4]=(d-y)*E,e[5]=(1-(c+p))*E,e[6]=(m+b)*E,e[7]=0,e[8]=(f+_)*R,e[9]=(m-b)*R,e[10]=(1-(c+g))*R,e[11]=0,e[12]=r[0],e[13]=r[1],e[14]=r[2],e[15]=1,e}function x(e,t,r,n,i){let a=t[0],s=t[1],o=t[2],l=t[3],u=a+a,h=s+s,c=o+o,d=a*u,f=a*h,g=a*c,m=s*h,p=s*c,b=o*c,_=l*u,y=l*h,v=l*c,E=n[0],R=n[1],M=n[2],S=i[0],T=i[1],x=i[2],I=(1-(m+b))*E,A=(f+v)*E,w=(g-y)*E,C=(f-v)*R,N=(1-(d+b))*R,O=(p+_)*R,L=(g+y)*M,P=(p-_)*M,D=(1-(d+m))*M;return e[0]=I,e[1]=A,e[2]=w,e[3]=0,e[4]=C,e[5]=N,e[6]=O,e[7]=0,e[8]=L,e[9]=P,e[10]=D,e[11]=0,e[12]=r[0]+S-(I*S+C*T+L*x),e[13]=r[1]+T-(A*S+N*T+P*x),e[14]=r[2]+x-(w*S+O*T+D*x),e[15]=1,e}function I(e,t,r,n,i,a,s){let o=1/(r-t),l=1/(i-n),u=1/(a-s);return e[0]=2*a*o,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=2*a*l,e[6]=0,e[7]=0,e[8]=(r+t)*o,e[9]=(i+n)*l,e[10]=(s+a)*u,e[11]=-1,e[12]=0,e[13]=0,e[14]=s*a*2*u,e[15]=0,e}function A(e,t,r,n){let a=t[0],s=t[1],l=t[2],u=a-r[0],h=s-r[1],c=l-r[2],d=(0,i.FD)();if(Math.abs(u)<d&&Math.abs(h)<d&&Math.abs(c)<d)return void o(e);let f=1/Math.sqrt(u*u+h*h+c*c);u*=f,h*=f,c*=f;let g=n[0],m=n[1],p=n[2],b=m*c-p*h,_=p*u-g*c,y=g*h-m*u;f=Math.sqrt(b*b+_*_+y*y),f?(f=1/f,b*=f,_*=f,y*=f):(b=0,_=0,y=0);let v=h*y-c*_,E=c*b-u*y,R=u*_-h*b;f=Math.sqrt(v*v+E*E+R*R),f?(f=1/f,v*=f,E*=f,R*=f):(v=0,E=0,R=0),e[0]=b,e[1]=v,e[2]=u,e[3]=0,e[4]=_,e[5]=E,e[6]=h,e[7]=0,e[8]=y,e[9]=R,e[10]=c,e[11]=0,e[12]=-(b*a+_*s+y*l),e[13]=-(v*a+E*s+R*l),e[14]=-(u*a+h*s+c*l),e[15]=1}function w(e,t,r){return e[0]=t[0]-r[0],e[1]=t[1]-r[1],e[2]=t[2]-r[2],e[3]=t[3]-r[3],e[4]=t[4]-r[4],e[5]=t[5]-r[5],e[6]=t[6]-r[6],e[7]=t[7]-r[7],e[8]=t[8]-r[8],e[9]=t[9]-r[9],e[10]=t[10]-r[10],e[11]=t[11]-r[11],e[12]=t[12]-r[12],e[13]=t[13]-r[13],e[14]=t[14]-r[14],e[15]=t[15]-r[15],e}function C(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]&&e[3]===t[3]&&e[4]===t[4]&&e[5]===t[5]&&e[6]===t[6]&&e[7]===t[7]&&e[8]===t[8]&&e[9]===t[9]&&e[10]===t[10]&&e[11]===t[11]&&e[12]===t[12]&&e[13]===t[13]&&e[14]===t[14]&&e[15]===t[15]}function N(e){let t=(0,i.FD)(),r=e[0],n=e[1],a=e[2],s=e[4],o=e[5],l=e[6],u=e[8],h=e[9],c=e[10];return Math.abs(1-(r*r+s*s+u*u))<=t&&Math.abs(1-(n*n+o*o+h*h))<=t&&Math.abs(1-(a*a+l*l+c*c))<=t}function O(e){return 1===e[0]&&0===e[1]&&0===e[2]&&0===e[4]&&1===e[5]&&0===e[6]&&0===e[8]&&0===e[9]&&1===e[10]}const L=c,P=w;Object.freeze(Object.defineProperty({__proto__:null,add:function(e,t,r){return e[0]=t[0]+r[0],e[1]=t[1]+r[1],e[2]=t[2]+r[2],e[3]=t[3]+r[3],e[4]=t[4]+r[4],e[5]=t[5]+r[5],e[6]=t[6]+r[6],e[7]=t[7]+r[7],e[8]=t[8]+r[8],e[9]=t[9]+r[9],e[10]=t[10]+r[10],e[11]=t[11]+r[11],e[12]=t[12]+r[12],e[13]=t[13]+r[13],e[14]=t[14]+r[14],e[15]=t[15]+r[15],e},adjoint:function(e,t){let r=t[0],n=t[1],i=t[2],a=t[3],s=t[4],o=t[5],l=t[6],u=t[7],h=t[8],c=t[9],d=t[10],f=t[11],g=t[12],m=t[13],p=t[14],b=t[15];return e[0]=o*(d*b-f*p)-c*(l*b-u*p)+m*(l*f-u*d),e[1]=-(n*(d*b-f*p)-c*(i*b-a*p)+m*(i*f-a*d)),e[2]=n*(l*b-u*p)-o*(i*b-a*p)+m*(i*u-a*l),e[3]=-(n*(l*f-u*d)-o*(i*f-a*d)+c*(i*u-a*l)),e[4]=-(s*(d*b-f*p)-h*(l*b-u*p)+g*(l*f-u*d)),e[5]=r*(d*b-f*p)-h*(i*b-a*p)+g*(i*f-a*d),e[6]=-(r*(l*b-u*p)-s*(i*b-a*p)+g*(i*u-a*l)),e[7]=r*(l*f-u*d)-s*(i*f-a*d)+h*(i*u-a*l),e[8]=s*(c*b-f*m)-h*(o*b-u*m)+g*(o*f-u*c),e[9]=-(r*(c*b-f*m)-h*(n*b-a*m)+g*(n*f-a*c)),e[10]=r*(o*b-u*m)-s*(n*b-a*m)+g*(n*u-a*o),e[11]=-(r*(o*f-u*c)-s*(n*f-a*c)+h*(n*u-a*o)),e[12]=-(s*(c*p-d*m)-h*(o*p-l*m)+g*(o*d-l*c)),e[13]=r*(c*p-d*m)-h*(n*p-i*m)+g*(n*d-i*c),e[14]=-(r*(o*p-l*m)-s*(n*p-i*m)+g*(n*l-i*o)),e[15]=r*(o*d-l*c)-s*(n*d-i*c)+h*(n*l-i*o),e},copy:a,determinant:function(e){let t=e[0],r=e[1],n=e[2],i=e[3],a=e[4],s=e[5],o=e[6],l=e[7],u=e[8],h=e[9],c=e[10],d=e[11],f=e[12],g=e[13],m=e[14],p=e[15];return(t*s-r*a)*(c*p-d*m)-(t*o-n*a)*(h*p-d*g)+(t*l-i*a)*(h*m-c*g)+(r*o-n*s)*(u*p-d*f)-(r*l-i*s)*(u*m-c*f)+(n*l-i*o)*(u*g-h*f)},equals:function(e,t){if(e===t)return!0;let r=e[0],n=e[1],a=e[2],s=e[3],o=e[4],l=e[5],u=e[6],h=e[7],c=e[8],d=e[9],f=e[10],g=e[11],m=e[12],p=e[13],b=e[14],_=e[15],y=t[0],v=t[1],E=t[2],R=t[3],M=t[4],S=t[5],T=t[6],x=t[7],I=t[8],A=t[9],w=t[10],C=t[11],N=t[12],O=t[13],L=t[14],P=t[15],D=(0,i.FD)();return Math.abs(r-y)<=D*Math.max(1,Math.abs(r),Math.abs(y))&&Math.abs(n-v)<=D*Math.max(1,Math.abs(n),Math.abs(v))&&Math.abs(a-E)<=D*Math.max(1,Math.abs(a),Math.abs(E))&&Math.abs(s-R)<=D*Math.max(1,Math.abs(s),Math.abs(R))&&Math.abs(o-M)<=D*Math.max(1,Math.abs(o),Math.abs(M))&&Math.abs(l-S)<=D*Math.max(1,Math.abs(l),Math.abs(S))&&Math.abs(u-T)<=D*Math.max(1,Math.abs(u),Math.abs(T))&&Math.abs(h-x)<=D*Math.max(1,Math.abs(h),Math.abs(x))&&Math.abs(c-I)<=D*Math.max(1,Math.abs(c),Math.abs(I))&&Math.abs(d-A)<=D*Math.max(1,Math.abs(d),Math.abs(A))&&Math.abs(f-w)<=D*Math.max(1,Math.abs(f),Math.abs(w))&&Math.abs(g-C)<=D*Math.max(1,Math.abs(g),Math.abs(C))&&Math.abs(m-N)<=D*Math.max(1,Math.abs(m),Math.abs(N))&&Math.abs(p-O)<=D*Math.max(1,Math.abs(p),Math.abs(O))&&Math.abs(b-L)<=D*Math.max(1,Math.abs(b),Math.abs(L))&&Math.abs(_-P)<=D*Math.max(1,Math.abs(_),Math.abs(P))},exactEquals:C,frob:function(e){return Math.sqrt(e[0]**2+e[1]**2+e[2]**2+e[3]**2+e[4]**2+e[5]**2+e[6]**2+e[7]**2+e[8]**2+e[9]**2+e[10]**2+e[11]**2+e[12]**2+e[13]**2+e[14]**2+e[15]**2)},fromQuat:function(e,t){let r=t[0],n=t[1],i=t[2],a=t[3],s=r+r,o=n+n,l=i+i,u=r*s,h=n*s,c=n*o,d=i*s,f=i*o,g=i*l,m=a*s,p=a*o,b=a*l;return e[0]=1-c-g,e[1]=h+b,e[2]=d-p,e[3]=0,e[4]=h-b,e[5]=1-u-g,e[6]=f+m,e[7]=0,e[8]=d+p,e[9]=f-m,e[10]=1-u-c,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},fromQuat2:function(e,t){let r=E,n=-t[0],i=-t[1],a=-t[2],s=t[3],o=t[4],l=t[5],u=t[6],h=t[7],c=n*n+i*i+a*a+s*s;return c>0?(r[0]=2*(o*s+h*n+l*a-u*i)/c,r[1]=2*(l*s+h*i+u*n-o*a)/c,r[2]=2*(u*s+h*a+o*i-l*n)/c):(r[0]=2*(o*s+h*n+l*a-u*i),r[1]=2*(l*s+h*i+u*n-o*a),r[2]=2*(u*s+h*a+o*i-l*n)),v(e,t,r),e},fromRotation:b,fromRotationTranslation:v,fromRotationTranslationScale:T,fromRotationTranslationScaleOrigin:x,fromScaling:function(e,t){return e[0]=t[0],e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=t[1],e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=t[2],e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},fromTranslation:p,fromXRotation:_,fromYRotation:function(e,t){let r=Math.sin(t),n=Math.cos(t);return e[0]=n,e[1]=0,e[2]=-r,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=r,e[9]=0,e[10]=n,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},fromZRotation:y,frustum:I,getRotation:S,getScale:M,getTranslation:R,hasIdentityRotation:O,identity:o,invert:h,invertOrIdentity:u,isOrthoNormal:N,lookAt:A,mul:L,multiply:c,multiplyScalar:function(e,t,r){return e[0]=t[0]*r,e[1]=t[1]*r,e[2]=t[2]*r,e[3]=t[3]*r,e[4]=t[4]*r,e[5]=t[5]*r,e[6]=t[6]*r,e[7]=t[7]*r,e[8]=t[8]*r,e[9]=t[9]*r,e[10]=t[10]*r,e[11]=t[11]*r,e[12]=t[12]*r,e[13]=t[13]*r,e[14]=t[14]*r,e[15]=t[15]*r,e},multiplyScalarAndAdd:function(e,t,r,n){return e[0]=t[0]+r[0]*n,e[1]=t[1]+r[1]*n,e[2]=t[2]+r[2]*n,e[3]=t[3]+r[3]*n,e[4]=t[4]+r[4]*n,e[5]=t[5]+r[5]*n,e[6]=t[6]+r[6]*n,e[7]=t[7]+r[7]*n,e[8]=t[8]+r[8]*n,e[9]=t[9]+r[9]*n,e[10]=t[10]+r[10]*n,e[11]=t[11]+r[11]*n,e[12]=t[12]+r[12]*n,e[13]=t[13]+r[13]*n,e[14]=t[14]+r[14]*n,e[15]=t[15]+r[15]*n,e},ortho:function(e,t,r,n,i,a,s){let o=1/(t-r),l=1/(n-i),u=1/(a-s);return e[0]=-2*o,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=-2*l,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=2*u,e[11]=0,e[12]=(t+r)*o,e[13]=(i+n)*l,e[14]=(s+a)*u,e[15]=1,e},perspective:function(e,t,r,n,i){let a,s=1/Math.tan(t/2);return e[0]=s/r,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=s,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[11]=-1,e[12]=0,e[13]=0,e[15]=0,null!=i&&i!==1/0?(a=1/(n-i),e[10]=(i+n)*a,e[14]=2*i*n*a):(e[10]=-1,e[14]=-2*n),e},perspectiveFromFieldOfView:function(e,t,r,n){let i=Math.tan(t.upDegrees*Math.PI/180),a=Math.tan(t.downDegrees*Math.PI/180),s=Math.tan(t.leftDegrees*Math.PI/180),o=Math.tan(t.rightDegrees*Math.PI/180),l=2/(s+o),u=2/(i+a);return e[0]=l,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=u,e[6]=0,e[7]=0,e[8]=-(s-o)*l*.5,e[9]=(i-a)*u*.5,e[10]=n/(r-n),e[11]=-1,e[12]=0,e[13]=0,e[14]=n*r/(r-n),e[15]=0,e},rotate:g,rotateX:m,rotateY:function(e,t,r){let n=Math.sin(r),i=Math.cos(r),a=t[0],s=t[1],o=t[2],l=t[3],u=t[8],h=t[9],c=t[10],d=t[11];return t!==e&&(e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e[0]=a*i-u*n,e[1]=s*i-h*n,e[2]=o*i-c*n,e[3]=l*i-d*n,e[8]=a*n+u*i,e[9]=s*n+h*i,e[10]=o*n+c*i,e[11]=l*n+d*i,e},rotateZ:function(e,t,r){let n=Math.sin(r),i=Math.cos(r),a=t[0],s=t[1],o=t[2],l=t[3],u=t[4],h=t[5],c=t[6],d=t[7];return t!==e&&(e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e[0]=a*i+u*n,e[1]=s*i+h*n,e[2]=o*i+c*n,e[3]=l*i+d*n,e[4]=u*i-a*n,e[5]=h*i-s*n,e[6]=c*i-o*n,e[7]=d*i-l*n,e},scale:f,set:s,str:function(e){return"mat4("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+", "+e[4]+", "+e[5]+", "+e[6]+", "+e[7]+", "+e[8]+", "+e[9]+", "+e[10]+", "+e[11]+", "+e[12]+", "+e[13]+", "+e[14]+", "+e[15]+")"},sub:P,subtract:w,targetTo:function(e,t,r,n){let i=t[0],a=t[1],s=t[2],o=n[0],l=n[1],u=n[2],h=i-r[0],c=a-r[1],d=s-r[2],f=h*h+c*c+d*d;f>0&&(f=1/Math.sqrt(f),h*=f,c*=f,d*=f);let g=l*d-u*c,m=u*h-o*d,p=o*c-l*h;return f=g*g+m*m+p*p,f>0&&(f=1/Math.sqrt(f),g*=f,m*=f,p*=f),e[0]=g,e[1]=m,e[2]=p,e[3]=0,e[4]=c*p-d*m,e[5]=d*g-h*p,e[6]=h*m-c*g,e[7]=0,e[8]=h,e[9]=c,e[10]=d,e[11]=0,e[12]=i,e[13]=a,e[14]=s,e[15]=1,e},translate:d,transpose:l},Symbol.toStringTag,{value:"Module"}))},90629(e,t,r){r.d(t,{Lz:()=>s,PN:()=>o,cr:()=>l,gs:()=>h,r_:()=>c,tc:()=>u}),r(39829);const n=/^-?(\d+(\.\d+)?)\s*((px)|(pt))?$/i,i=o(1),a=s(1);function s(e){return e?e/72*96:0}function o(e){return e?72*e/96:0}function l(e){if("string"==typeof e){let t=e.match(n);if(t){let r=Number(t[1]),n=t[3]&&t[3].toLowerCase(),i=e.startsWith("-"),a="px"===n?o(r):r;return i?-a:a}return console.warn("screenUtils.toPt: input not recognized!"),null}return e}function u(e=0,t=0){return{x:e,y:t}}function h(e=0,t=0){return[e,t]}function c(e=0,t=0,r=0){return[e,t,r]}r.d(t,["L7",0,a,"ps",0,i])},4197(e,t,r){r.d(t,{Vj:()=>h,cj:()=>u,jh:()=>a,l5:()=>o,yH:()=>l});var n=r(34275),i=r(9093);function a(e){return e<=1024?Array(e).fill(0):new Float64Array(e)}function s(e){return((0,n.iu)(e)?e.byteLength/8:e.length)<=1024?Array.from(e):new Float64Array(e)}function o(e,t,r){return Array.isArray(e)?e.slice(t,t+r):e.subarray(t,t+r)}function l(e,t){if(0===t.length)return s(e);if(0===e.length)return s(t);let r=a(e.length+t.length);for(let t=0;t<e.length;++t)r[t]=e[t];for(let n=0;n<t.length;++n)r[e.length+n]=t[n];return r}function u(e){return[...e]}function h(e){let t=(0,i.vt)();for(let r=0;r<16;++r)t[r]=e[r];return t}},70328(e,t,r){r.d(t,{BI:()=>I,C:()=>s,DC:()=>d,Ej:()=>y,Ie:()=>T,Jt:()=>x,Lu:()=>E,Ne:()=>R,RF:()=>c,TF:()=>b,VL:()=>g,aI:()=>w,fA:()=>o,gE:()=>u,gX:()=>_,hZ:()=>S,iT:()=>f,is:()=>A,pg:()=>v,uJ:()=>p,vI:()=>M,vY:()=>l,vt:()=>a,w1:()=>h,yr:()=>m}),r(35522);var n=r(5443),i=(r(19419),r(4197));function a(e=N){return[e[0],e[1],e[2],e[3],e[4],e[5]]}function s(e,t){for(let r=0;r<6;r++)e[r]=t[r];return e}function o(e,t,r,n,i,s,o=a()){return o[0]=e,o[1]=t,o[2]=r,o[3]=n,o[4]=i,o[5]=s,o}function l(e,t=a()){return function(e,t,r,n=a()){return S(n,C),function(e,t,r=0,n=t.length/3){let i=e[0],a=e[1],s=e[2],o=e[3],l=e[4],u=e[5];for(let e=0;e<n;e++)i=Math.min(i,t[r+3*e]),a=Math.min(a,t[r+3*e+1]),s=Math.min(s,t[r+3*e+2]),o=Math.max(o,t[r+3*e]),l=Math.max(l,t[r+3*e+1]),u=Math.max(u,t[r+3*e+2]);e[0]=i,e[1]=a,e[2]=s,e[3]=o,e[4]=l,e[5]=u}(n,e,t,r),n}(e,0,e.length/3,t)}function u(e,t=(0,i.jh)(24)){let[r,n,a,s,o,l]=e;return t[0]=r,t[1]=n,t[2]=a,t[3]=r,t[4]=n,t[5]=l,t[6]=r,t[7]=o,t[8]=a,t[9]=r,t[10]=o,t[11]=l,t[12]=s,t[13]=n,t[14]=a,t[15]=s,t[16]=n,t[17]=l,t[18]=s,t[19]=o,t[20]=a,t[21]=s,t[22]=o,t[23]=l,t}function h(e,t){return isFinite(e[2])||isFinite(e[5])?new n.A({xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],zmin:e[2],zmax:e[5],spatialReference:t}):new n.A({xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],spatialReference:t})}function c(e,t,r=e){r[0]=Math.min(e[0],t[0]),r[1]=Math.min(e[1],t[1]),r[2]=Math.min(e[2],t[2]),r[3]=Math.max(e[3],t[3]),r[4]=Math.max(e[4],t[4]),r[5]=Math.max(e[5],t[5])}function d(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[3]=Math.max(e[3],t[2]),e[4]=Math.max(e[4],t[3])}function f(e,[t,r,n]){!function(e,t,r,n){e[0]=Math.min(e[0],t),e[1]=Math.min(e[1],r),e[2]=Math.min(e[2],n),e[3]=Math.max(e[3],t),e[4]=Math.max(e[4],r),e[5]=Math.max(e[5],n)}(e,t,r,n)}function g(e){return e[0]>=e[3]?0:e[3]-e[0]}function m(e){return e[1]>=e[4]?0:e[4]-e[1]}function p(e){return e[2]>=e[5]?0:e[5]-e[2]}function b(e){let t=g(e),r=p(e),n=m(e);return t*t+r*r+n*n}function _(e,t=[0,0,0]){return t[0]=e[0]+g(e)/2,t[1]=e[1]+m(e)/2,t[2]=e[2]+p(e)/2,t}function y(e,t=[0,0,0]){return t[0]=g(e),t[1]=m(e),t[2]=p(e),t}function v(e,t){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t}function E(e,t){return t[0]=e[3],t[1]=e[4],t[2]=e[5],t}function R(e,t,r=e){return r[0]=t[0],r[1]=t[1],r[2]=t[2],r!==e&&(r[3]=e[3],r[4]=e[4],r[5]=e[5]),r}function M(e,t,r=e){return r[3]=t[0],r[4]=t[1],r[5]=t[2],r!==e&&(r[0]=e[0],r[1]=e[1],r[2]=e[2]),e}function S(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function T(e){return e?S(e,C):a(C)}function x(e,t){return e[0]=t[0],e[1]=t[1],e[2]=-1/0,e[3]=t[2],e[4]=t[3],e[5]=1/0,e}function I(e,t,r,n,i){return e[0]=t,e[1]=r,e[2]=-1/0,e[3]=n,e[4]=i,e[5]=1/0,e}function A(e){return 6===e.length}function w(e,t,r){if(null==e||null==t)return e===t;if(!A(e)||!A(t))return!1;if(r){for(let n=0;n<e.length;n++)if(!r(e[n],t[n]))return!1}else for(let r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}const C=[1/0,1/0,1/0,-1/0,-1/0,-1/0],N=[0,0,0,0,0,0];a(),r.d(t,["qv",0,C,"v_",0,N])},50498(e,t,r){var n=r(66552),i=r(5443),a=r(91075),s=r(48526),o=r(86738),l=r(39829),u=r(82799);const h=(0,n.O)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon"}),c=(0,n.O)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh"}),d={base:a.A,key:"type",typeMap:{extent:i.A,multipoint:s.A,point:o.A,polyline:u.A,polygon:l.A}},f=new n.J({esriGeometryBezier3Curve:"cubic-bezier",esriGeometryCircularArc:"circular-arc",esriGeometryEllipticArc:"elliptic-arc"},{ignoreUnknown:!0});r.d(t,["Ye",0,c,"gy",0,h,"iI",0,f,"yR",0,d])},49013(e,t,r){r.r(t),r.d(t,{default:()=>pt});var n=r(32198),i=r(4576),a=r(60999),s=r(69540),o=r(49186),l=r(36563),u=r(44208),h=r(53966),c=r(25728),d=r(17676),f=r(36708),g=r(91429),m=r(87024),p=r(4146),b=r(52136),_=r(18768),y=r(69208),v=r(34287),E=r(8303),R=r(25036),M=r(58947),S=r(10873),T=r(10292),x=r(58083),I=r(9093),A=r(35522),w=r(51850),C=r(34727),N=r(49208),O=r(79258);function L(e,t,r,n){let i=n+t;if(i<n/2||r>i)return Number.MAX_VALUE;let a=Math.abs(D*e)+Math.asin(r/i);return a>=Math.PI/2?Number.MAX_VALUE:r/Math.cos(a)}const P=(0,w.vt)(),D=(0,C.kU)(1);var q=r(27993),F=(r(73941),r(16930)),U=r(98764),k=r(4341),Q=r(19419),G=r(11964),V=r(27921),j=r(71351),W=r(44280),Z=r(32114);const z=()=>h.A.getLogger("esri.views.3d.support.geometryUtils.boundedPlane");function B(e=ce){return{plane:(0,V.vt)(e.plane),origin:(0,w.o8)(e.origin),basis1:(0,w.o8)(e.basis1),basis2:(0,w.o8)(e.basis2)}}function $(e,t=B()){return H(e.origin,e.basis1,e.basis2,t)}function H(e,t,r,n=B()){return(0,A.C)(n.origin,e),(0,A.C)(n.basis1,t),(0,A.C)(n.basis2,r),Y(n),function(e,t){Math.abs((0,A.Om)(e.basis1,e.basis2)/((0,A.Bw)(e.basis1)*(0,A.Bw)(e.basis2)))>1e-6&&z().warn(t,"Provided basis vectors are not perpendicular"),Math.abs((0,A.Om)(e.basis1,se(e)))>1e-6&&z().warn(t,"Basis vectors and plane normal are not perpendicular"),Math.abs(-(0,A.Om)(se(e),e.origin)-e.plane[3])>1e-6&&z().warn(t,"Plane offset is not consistent with plane origin")}(n,"fromValues()"),n}function Y(e){(0,V.mR)(e.basis2,e.basis1,e.origin,e.plane)}function K(e,t,r){e!==r&&$(e,r);let n=(0,A.hs)(Z.rq.get(),se(e),t);return(0,A.WQ)(r.origin,r.origin,n),r.plane[3]-=t,r}function X(e,t=B()){let r=(e[2]-e[0])/2,n=(e[3]-e[1])/2;return(0,A.hZ)(t.origin,e[0]+r,e[1]+n,0),(0,A.hZ)(t.basis1,r,0,0),(0,A.hZ)(t.basis2,0,n,0),(0,V.fA)(0,0,1,0,t.plane),t}function J(e,t,r){return!!(0,V.Ui)(e.plane,t,r)&&oe(e,r)}function ee(e,t,r){let n=de.get();he(e,t,n,de.get());let i=1/0;for(let a of pe){let s=ue(e,a,fe.get()),o=Z.rq.get();if((0,V.T7)(n,s,o)){let e=(0,A.oW)(Z.rq.get(),t.origin,o),n=Math.abs((0,C.XM)((0,A.Om)(t.direction,e)));n<i&&(i=n,(0,A.C)(r,o))}}return i===1/0?te(e,t,r):r}function te(e,t,r){if(J(e,t,r))return r;let n=de.get(),i=de.get();he(e,t,n,i);let a=1/0;for(let s of pe){let o=ue(e,s,fe.get()),l=Z.rq.get();if((0,V.gv)(n,o,l)){let e=(0,j.kb)(t,l);if(!(0,V.BX)(i,l))continue;e<a&&(a=e,(0,A.C)(r,l))}}return ie(e,t.origin)<a&&re(e,t.origin,r),r}function re(e,t,r){let n=(0,V._I)(e.plane,t,Z.rq.get()),i=(0,G.H6)(le(e,e.basis1),n,-1,1,Z.rq.get()),a=(0,G.H6)(le(e,e.basis2),n,-1,1,Z.rq.get());return(0,A.Re)(r,(0,A.WQ)(Z.rq.get(),i,a),e.origin),r}function ne(e,t,r){let{origin:n,basis1:i,basis2:a}=e,s=(0,A.Re)(Z.rq.get(),t,n),o=(0,W.gr)(i,s),l=(0,W.gr)(a,s),u=(0,W.gr)(se(e),s);return(0,A.hZ)(r,o,l,u)}function ie(e,t){let r=ne(e,t,Z.rq.get()),{basis1:n,basis2:i}=e,a=(0,A.Bw)(n),s=(0,A.Bw)(i),o=Math.max(Math.abs(r[0])-a,0),l=Math.max(Math.abs(r[1])-s,0),u=r[2];return o*o+l*l+u*u}function ae(e,t){let r=-e.plane[3];return(0,W.gr)(se(e),t)-r}function se(e){return(0,V.Qj)(e.plane)}function oe(e,t){let r=(0,A.Re)(Z.rq.get(),t,e.origin),n=(0,A.m3)(e.basis1),i=(0,A.m3)(e.basis2),a=(0,A.Om)(e.basis1,r),s=(0,A.Om)(e.basis2,r);return-a-n<0&&a-n<0&&-s-i<0&&s-i<0}function le(e,t){let r=fe.get();return(0,A.C)(r.origin,e.origin),(0,A.C)(r.vector,t),r}function ue(e,t,r){let{basis1:n,basis2:i,origin:a}=e,s=(0,A.hs)(Z.rq.get(),n,t.origin[0]),o=(0,A.hs)(Z.rq.get(),i,t.origin[1]);(0,A.WQ)(r.origin,s,o),(0,A.WQ)(r.origin,r.origin,a);let l=(0,A.hs)(Z.rq.get(),n,t.direction[0]),u=(0,A.hs)(Z.rq.get(),i,t.direction[1]);return(0,A.hs)(r.vector,(0,A.WQ)(l,l,u),2),r}function he(e,t,r,n){let i=se(e);(0,V.mR)(i,t.direction,t.origin,r),(0,V.mR)((0,V.Qj)(r),i,t.origin,n)}const ce={plane:(0,V.vt)(),origin:(0,w.fA)(0,0,0),basis1:(0,w.fA)(1,0,0),basis2:(0,w.fA)(0,1,0)},de=new k.I(V.vt),fe=new k.I(G.vt),ge=(0,w.vt)(),me=new k.I(()=>B()),pe=[{origin:[-1,-1],direction:[1,0]},{origin:[1,-1],direction:[0,1]},{origin:[1,1],direction:[-1,0]},{origin:[-1,1],direction:[0,-1]}],be=(0,I.vt)(),_e=(0,I.vt)();Object.freeze(Object.defineProperty({__proto__:null,altitudeAt:ae,axisAt:function(e,t,r,n){return function(e,t,r){switch(t){case 0:(0,A.C)(r,e.basis1),(0,A.S8)(r,r);break;case 1:(0,A.C)(r,e.basis2),(0,A.S8)(r,r);break;case 2:(0,A.C)(r,se(e))}return r}(e,r,n)},cameraFrustumCoverage:function(e,t){return(t-e)/t},closestPoint:te,closestPointOnSilhouette:ee,copy:$,copyWithoutVerify:function(e,t){(0,A.C)(t.origin,e.origin),(0,A.C)(t.basis1,e.basis1),(0,A.C)(t.basis2,e.basis2),(0,V.C)(t.plane,e.plane)},create:B,distance:function(e,t){return Math.sqrt(ie(e,t))},distance2:ie,distanceToSilhouette:function(e,t){let r=-1/0;for(let n of pe){let i=ue(e,n,fe.get()),a=(0,G.kb)(i,t);a>r&&(r=a)}return Math.sqrt(r)},elevate:K,equals:function(e,t){return e===t||null==e&&null==t||null!=e&&null!=t&&(0,A.t2)(e.basis1,t.basis1)&&(0,A.t2)(e.basis2,t.basis2)&&(0,A.t2)(e.origin,t.origin)},extrusionContainsPoint:function(e,t){return(0,V.mN)(e.plane,t)>0&&oe(e,t)},fromAABoundingRect:X,fromValues:H,getExtent:function(e,t){let r=e.basis1[0],n=e.basis2[1],[i,a]=e.origin;return(0,Q.fA)(i-r,a-n,i+r,a+n,t)},intersectRay:J,intersectRayClosestSilhouette:function(e,t,r){if(J(e,t,r))return r;let n=ee(e,t,Z.rq.get());return(0,A.WQ)(r,t.origin,(0,A.hs)(Z.rq.get(),t.direction,(0,A.Io)(t.origin,n)/(0,A.Bw)(t.direction))),r},normal:se,projectPoint:re,projectPointLocal:ne,rotate:function(e,t,r,n){return e!==n&&$(e,n),(0,x.$0)(_e,t,r),(0,A.Z0)(n.basis1,e.basis1,_e),(0,A.Z0)(n.basis2,e.basis2,_e),Y(n),n},setAltitudeAt:function(e,t,r,n){let i=ae(e,t),a=(0,A.hs)(ge,se(e),r-i);return(0,A.WQ)(n,t,a),n},setExtent:function(e,t,r){return X(t,r),K(r,ae(e,e.origin),r),r},transform:function(e,t,r){return e!==r&&$(e,r),(0,x.B8)(be,t),(0,x.mg)(be,be),(0,A.Z0)(r.basis1,e.basis1,be),(0,A.Z0)(r.basis2,e.basis2,be),(0,A.Z0)((0,V.Qj)(r.plane),(0,V.Qj)(e.plane),be),(0,A.Z0)(r.origin,e.origin,t),(0,V.mP)(r.plane,r.plane,r.origin),r},up:ce,updateUnboundedPlane:Y,wrap:function(e,t,r){let n=me.get();return n.origin=e,n.basis1=t,n.basis2=r,n.plane=(0,V.LV)(0,0,0,0),Y(n),n}},Symbol.toStringTag,{value:"Module"}));var ye=r(94008);(0,w.vt)(),(0,w.vt)();var ve=r(89707);class Ee extends ve.H{constructor(e,t){super(NaN,NaN),this.id=e,this.serviceMbsInIndexSR=t,this._serviceMbsInRenderSRElevationAdjusted=new ye.iy(0,0,0,-1),this._serviceMbsInRenderSR=new ye.iy(0,0,0,-1),this._serviceMbsElevationUpdateExtent=null,this._mbsConeInRenderSR=null}get serviceMbsInRenderSRElevationAdjusted(){return this._serviceMbsInRenderSRElevationAdjusted}updateServiceMbsInRenderSRElevationAdjusted(e){return this._serviceMbsInRenderSRElevationAdjusted.copyFrom(e),this._serviceMbsInRenderSRElevationAdjusted}get serviceMbsInRenderSR(){return this._serviceMbsInRenderSR}updateServiceMbsInRenderSR(e){return this._serviceMbsInRenderSR.copyFrom(e),null!=this._serviceMbsElevationUpdateExtent&&(0,Q.Ie)(this._serviceMbsElevationUpdateExtent),this._serviceMbsInRenderSR}get serviceMbsElevationUpdateExtent(){return this._serviceMbsElevationUpdateExtent??=(0,Q.Ie)()}get mbsConeInRenderSR(){return this._mbsConeInRenderSR}updateMbsConeInRenderSR(e){return this._mbsConeInRenderSR=e.clone(),this._mbsConeInRenderSR}invalidateServiceBVsInRenderSR(){this._serviceMbsInRenderSRElevationAdjusted.invalidate(),this._serviceMbsInRenderSR.invalidate(),null!=this._serviceMbsElevationUpdateExtent&&(0,Q.Ie)(this._serviceMbsElevationUpdateExtent),this._mbsConeInRenderSR=null,this.serviceObbInRenderSR?.invalidate()}shareServiceBVsInRenderSRWith(e){this.serviceObbInRenderSR=e.serviceObbInRenderSR,this._serviceMbsInRenderSRElevationAdjusted=e._serviceMbsInRenderSRElevationAdjusted,this._serviceMbsInRenderSR=e._serviceMbsInRenderSR,this._serviceMbsElevationUpdateExtent=e._serviceMbsElevationUpdateExtent??=(0,Q.Ie)(),this._mbsConeInRenderSR=e._mbsConeInRenderSR}}class Re extends Ee{constructor(e,t,r,n,i,a,s,o,l,u,h){super(e,r),this.index=t,this.childCount=n,this.level=i,this.resources=a,this.version=s,this.lodMetric=o,this.maxError=l,this.numFeatures=u,this.failed=!1,this.cacheState=0,this.vertexCount=0,this.memory=0,this.childrenLoaded=0,this.hasModifications=!1,this.imModificationImpact=4,this.elevationAgnosticBoundingVolume=new Me,this.serviceObbInIndexSR=h}invalidateServiceBVsInRenderSR(){super.invalidateServiceBVsInRenderSR(),this.elevationAgnosticBoundingVolume.invalidate()}}class Me{constructor(){this._data=[0,0,0,Me.invalidRadius]}static{this.invalidRadius=-2}invalidate(){this._data[3]=Me.invalidRadius}get valid(){return this._data[3]!==Me.invalidRadius}get radius(){return this._data[3]}getAxis(e){return e[0]=this._data[0],e[1]=this._data[1],e[2]=this._data[2],e}set(e,t){this._data[0]=e[0],this._data[1]=e[1],this._data[2]=e[2],this._data[3]=t}intersectsFrustumConservative(e,t,r){if(!this.valid)return!0;let n=this.getAxis(Se),{center:i,radius:a}=e.boundingSphere,s=a+r;return 1===t?this.radius>Te||function(e,t,r,n){let i=(0,A.Bw)(r);if(i<=n)return!0;let a=(0,A.Om)(e,r);if(a<=0)return-a<=n;let s=(0,C.qE)(a/i,-1,1),o=Math.sqrt(1-s*s),l=(0,C.qE)(n/i,0,1);return o*Math.sqrt(1-l*l)-l*s<=t}(n,this.radius,i,s):function(e,t,r,n){let i=r[0]-e[0],a=r[1]-e[1],s=t+n;return i*i+a*a<=s*s}(n,this.radius,i,s)&&function(e,t,r,n,i){for(let a of i){let i=a[0],s=a[1],o=a[2],l=o>0?r:n;if(i*e[0]+s*e[1]+o*l+a[3]-Math.hypot(i,s)*t>0)return!1}return!0}(n,this.radius,i[2]-s,i[2]+s,e.planes)}}const Se=(0,w.vt)(),Te=.9;var xe=r(25992),Ie=r(66480),Ae=r(57005),we=r(4431),Ce=r(62747),Ne=r(58682),Oe=r(92359);class Le{constructor(e,t,r){this._layer=e,this._descriptor=t,this._options=r,this._subtaskAbortController=new AbortController,this._highest=-1/0,this._signal=AbortSignal.any([r.signal,this._subtaskAbortController.signal]),this._indexSpatialReference=(0,Ie.Rm)(e),this._vertexSpatialReference=(0,Ie.Dd)(e),this._intersectionSpaceSpatialReference=function(e,t){return e?(0,U.lO)(t):t.isGeographic?F.A.PlateCarree:t}(this._indexSpatialReference.isGeographic,this._indexSpatialReference),this._indexToVertexProjector=(0,N.wy)(this._indexSpatialReference,this._vertexSpatialReference),this._vertexToIntersectionSpaceProjector=(0,N.wy)(this._vertexSpatialReference,this._intersectionSpaceSpatialReference),this.frameTask=r.scheduler.registerTask(Oe.W6.ELEVATION_QUERY),this.promise=this._run()}async _run(){let e={stack:[],error:void 0,hasError:!1};try{(0,n.mS)(e,this.frameTask,!1);try{let e=this._descriptor;if("point"!==e.geometry.type)throw new o.A("elevation-query:invalid-geometry","Only point geometries can be used to query elevation");if(null==this._indexToVertexProjector||null==this._vertexToIntersectionSpaceProjector)throw new o.A("integrated-mesh-elevation-query:projection","Failed to create projection for elevation query.");let t=await e.project(this._indexSpatialReference,this._signal);(0,d.Te)(this._signal),t??this._throwSpatialReferenceMismatchError();let r=t.coordinates[0],n=function(e,t,r,n,i){let a=(0,w.fA)(e,t,r),s=(0,w.fA)(e,t,r-1e3),o=(0,w.vt)(),l=(0,w.vt)();return(0,q.F)(a,n,o,i)&&(0,q.F)(s,n,l,i)?(0,j.Cr)(o,l):null}(r.x,r.y,this.getRootRayOriginZ(),this._indexSpatialReference,this._intersectionSpaceSpatialReference);return n??this._throwSpatialReferenceMismatchError(),this._queryRay=n,await this.visitRoot(),(0,d.Te)(this._signal),r.z=this._highest===-1/0?qe:this._highest,t}catch(e){throw this._subtaskAbortController.abort(),e}}catch(t){e.error=t,e.hasError=!0}finally{(0,n.hk)(e)}}_throwSpatialReferenceMismatchError(){throw new o.A("elevation-query:spatial-reference-mismatch",`Cannot query elevation in '${this._descriptor.spatialReference.wkid}' on an elevation service in '${this._indexSpatialReference.wkid}'`)}_intersectsQueryObb(e){let t=this._queryRay,r=new Ae.ab;return e.transform(r,this._indexSpatialReference,this._intersectionSpaceSpatialReference),r.intersectRay(t.origin,t.direction)}intersectsQueryBounds(e){if(null==e)return!0;let t=this._queryRay;if(null!=e.obb)return this._intersectsQueryObb(Ae.ab.fromJSON(e.obb));let r=new ye.iy;return!function(e,t,r,n){if(null==e||null==t||null==n)return!1;let i=(0,N.Tp)(t,n);if(null==i?.projector)return!1;if(i.projector===N.pO)return r.copyFrom(e),!0;let{source:a,dest:s,projector:o}=i;if(3===s.spatialReferenceId){let t=N.w5[a.spatialReferenceId][2];return null!=t&&(t(e.center,0,P,0),(0,N.s7)(P,0,r.center,0),r.radius=L(P[1],e.center[2],e.radius,O.$O.radius),!0)}if(2!==a.spatialReferenceId&&5!==a.spatialReferenceId||11!==s.spatialReferenceId){o(e.center,0,r.center,0);let t=a.metersPerUnit??1,n=s.metersPerUnit??1;r.radius=e.radius*t/n}else{let t=N.w5[a.spatialReferenceId][1],n=N.w5[1][11],i=e.radius;null!=t&&null!=n&&(i=L(e.center[1],e.center[2],e.radius,O.$O.radius)),o(e.center,0,r.center,0),r.radius=i}return!0}(new ye.iy(e.mbs),this._indexSpatialReference,r,this._intersectionSpaceSpatialReference)||r.intersectRay(t)}async _processLeafNode(e){let t=await this._layer.elevationQueryNodeLoader.loadNodeData(e,this._signal);if((0,d.Te)(this._signal),null==t.geometryBuffer||null==t.geometryDescriptor)return;let r=await this.transformNode(e,t);(0,d.Te)(this._signal),null!=r&&await this.frameTask.schedule(()=>{this._highest=this.intersectTransformedGeometry(r,this._highest,this._options.elevationOffset)},this._signal)}async transformNode(e,t){let r=e.serviceMbsInIndexSR;if(null==r)return null;let n=(0,xe.C)(r,0,Fe,this._indexSpatialReference,this._intersectionSpaceSpatialReference),i={context:`i3s-elevation-query-${this._layer.uid}`,geometryBuffer:t.geometryBuffer,geometryData:null,geometryDescriptor:t.geometryDescriptor,layouts:[Ue],globalTrafo:n,geometryElevationOffset:0,mbs:r.toJSON(),obbData:e.serviceObbInIndexSR?.data,elevationOffset:0,planetRadiusInGlobalMode:0,needNormals:!1,computeNormals:!1,normalReferenceFrame:Fe,indexToVertexProjector:this._indexToVertexProjector,vertexToRenderProjector:this._vertexToIntersectionSpaceProjector},a=await this._layer.processElevationQueryGeometry(i,this._signal);return(0,d.Te)(this._signal),a}intersectTransformedGeometry(e,t,r){let n=e.globalTrafo;if(null==(0,x.B8)(ke,n))return t;let i=this._queryRay,a=(0,A.Z0)(Qe,i.origin,ke),s=(0,A.WQ)(Ge,i.origin,i.direction),o=(0,A.Z0)(Ve,s,ke),l=(0,A.jb)(je,o,a),{data:u,indices:h}=e.transformedGeometry.positionData,c=h.length/3,d=t;return(0,Ne.h7)(a,l,0,c,h,u,3,!1,e=>{let t=(0,A.hs)(We,l,e);(0,A.WQ)(t,t,a);let i=(0,A.Z0)(Ze,t,n),s=ze;if((0,q.F)(i,this._intersectionSpaceSpatialReference,s,this._layer.spatialReference)){let e=s[2]+r;d=Math.max(d,e)}}),d}async requestJSON(e){let t=await this._layer.elevationQueryDataRequester.request(e,"json",this._signal);return(0,d.Te)(this._signal),t}}class Pe extends Le{constructor(e,t,r,n){super(e,t,r),this._pendingPages=new Map,this._loadedPages=new Map,this._pageSize=n.pageSize,this._rootIndex=n.rootIndex,this._urlPrefix=n.urlPrefix;let i=this._pageId(this._rootIndex),a=this._rootIndex-i*this._pageSize,s=Ae.ab.fromJSON(n.rootPage.nodes[a].obb);this._rootRayOriginZ=s.centerZ+s.radius+1,this._loadedPages.set(i,n.rootPage)}visitRoot(){return this._visitNode(this._rootIndex)}getRootRayOriginZ(){return this._rootRayOriginZ}_pageId(e){return Math.floor(e/this._pageSize)}getPage(e){let t=this._loadedPages.get(e);if(null!=t)return Promise.resolve(t);let r=this._pendingPages.get(e);if(null!=r)return r;let n=this.requestJSON(`${this._urlPrefix}${e}`);return this._pendingPages.set(e,n),n.then(t=>{this._loadedPages.set(e,t),this._pendingPages.delete(e)},()=>this._pendingPages.delete(e)),n}async _visitNode(e){let t=this._pageId(e),r=await this.getPage(t);(0,d.Te)(this._signal);let n=r.nodes[e-t*this._pageSize],i=Ae.ab.fromJSON(n.obb);if(!this._intersectsQueryObb(i))return;let{children:a}=n;if(null!=a&&a.length>0)return await Promise.all(a.map(e=>this._visitNode(e))),void(0,d.Te)(this._signal);let s=this._createNode(e,n,i);null!=s&&(await this._processLeafNode(s),(0,d.Te)(this._signal))}_createNode(e,t,r){let{mesh:n}=t;if(null==n?.geometry)return null;let i=new ye.iy(r.getCenter((0,w.vt)()),r.radius),{geometry:a,material:s}=n;return new Re(`${e}`,e,i,t.children?.length??0,0,{hasSharedResource:!1,isEmpty:!1,geometry:`${a.resource}`,geometryDefinition:a.definition,materialDefinition:s?.definition??-1},"",0,0,a.featureCount??null,r)}}class De extends Le{constructor(e,t,r,n){super(e,t,r),this._rootNode=n.rootNode,this._urlPrefix=n.urlPrefix}visitRoot(){return this.intersectsQueryBounds(this._rootNode)?this._visitNodeData(this._rootNode,null!=this._rootNode.obb):Promise.resolve()}getRootRayOriginZ(){return this._rootNode.mbs[2]+this._rootNode.mbs[3]+1}_visitNode(e){return this.intersectsQueryBounds(e)?this._visitNodeAsync(e):Promise.resolve()}async _visitNodeAsync(e){let t=await this.requestJSON(`${this._urlPrefix}${e.id}`);(0,d.Te)(this._signal),await this._visitNodeData(t,null!=e.obb),(0,d.Te)(this._signal)}async _visitNodeData(e,t){if(!t&&null!=e.obb&&!this._intersectsQueryObb(Ae.ab.fromJSON(e.obb)))return;let{children:r}=e;if(null!=r&&r.length>0)return await Promise.all(r.map(e=>this._visitNode(e))),void(0,d.Te)(this._signal);let n=this._createNode(e);null!=n&&(await this._processLeafNode(n),(0,d.Te)(this._signal))}_createNode(e){let{geometryData:t,id:r}=e;if(null==t||0===t.length)return null;let n=null==e.obb?null:Ae.ab.fromJSON(e.obb),i=new ye.iy(e.mbs);return new Re(r,0,i,e.children?.length??0,0,{hasSharedResource:null!=e.sharedResource,isEmpty:!1,geometry:r,geometryDefinition:0},e.version??"",0,0,null,n)}}const qe=Number.MAX_VALUE,Fe="none",Ue=(0,we.U)((0,Ce.hH)(new Ce.W7(!1,!1,0))),ke=(0,I.vt)(),Qe=(0,w.vt)(),Ge=(0,w.vt)(),Ve=(0,w.vt)(),je=(0,w.vt)(),We=(0,w.vt)(),Ze=(0,w.vt)(),ze=(0,w.vt)();var Be=r(50805),$e=r(58325),He=r(24212),Ye=r(80215),Ke=r(97159),Xe=r(16215),Je=r(98697),et=r(56507),tt=r(97768),rt=r(50075);class nt{constructor(e,t){this._customParameters=e,this._apiKey=t,this._activeRequests=new Set}isFull(e){return(0,rt._i)(e)}request(e,t,r){let n=new AbortController,i=(0,d.NY)(r,()=>n.abort()),a={...rt.Fz,signal:n.signal,responseType:t,query:{...this._customParameters,token:this._apiKey}},s=(0,et.A)(e,a),o={abortController:n,abortHandle:i};return this._activeRequests.add(o),s.then(({data:e})=>e).finally(()=>{o.abortController=null,o.abortHandle=(0,tt.xt)(o.abortHandle),this._activeRequests.delete(o)})}cancelAll(){this._activeRequests.forEach(e=>{e.abortController=(0,tt.DC)(e.abortController),e.abortHandle=(0,tt.xt)(e.abortHandle)}),this._activeRequests.clear()}}var it=r(4718),at=r(84952),st=r(59418),ot=r(85334);r(91829),r(76200);var lt=r(74810),ut=r(49788);function ht(e){return e.sort((e,t)=>e.encoding-t.encoding)}const ct={ktx2:1,basis:2,dds:4,png:8,jpg:16,"ktx-etc2":32},dt={"image/ktx2":2,"image/x.basis":2,"image/vnd-ms.dds":4,"image/png":8,"image/jpg":16,"image/jpeg":16,"image/ktx":32};class ft{constructor(e,t,r,n,i,a){if(this._requester=t,this._logger=r,this._defaultGeometrySchema=n,this._requiredAttributes=i,this._options=a,this._logLayer=e,this._layerUrl=e.parsedUrl.path,this._geometryDefinitions=e.geometryDefinitions,e.materialDefinitions){let t=e.textureSetDefinitions;this._materialAndTextures=e.materialDefinitions.map(r=>function(e,t,r){let n=new Map,i=(e,t)=>{if(null==e)return-1;let r=n.get(e.id);if(r)return r.usage|=t,r.id;let i=n.size;return n.set(e.id,{id:i,usage:t}),i},a=t.pbrMetallicRoughness,s=a?.baseColorFactor?(0,ot.sn)(a.baseColorFactor):null,o=t.emissiveFactor,l=r&&0===a?.metallicFactor||(0,lt.Jr)({normalTexture:t.normalTexture,emissiveTexture:t.emissiveTexture,emissiveFactor:t.emissiveFactor,occlusionTexture:t.occlusionTexture,metallicRoughnessTexture:a?.metallicRoughnessTexture,metallicFactor:a?.metallicFactor,roughnessFactor:a?.roughnessFactor}),u=l?lt.Bt[0]:a?.metallicFactor??lt.mb[0],h=l?lt.Bt[1]:a?.roughnessFactor??lt.mb[1],c="mask"===t.alphaMode?33:1,d={baseColorFactor:s?[s[0],s[1],s[2],s[3]]:[1,1,1,1],baseColorTextureId:i(a?.baseColorTexture,c),metallicRoughnessTextureId:i(a?.metallicRoughnessTexture,2),metallicFactor:u,roughnessFactor:h},f={alphaMode:t.alphaMode,alphaCutoff:t.alphaCutoff,doubleSided:t.doubleSided,cullFace:"none"===t.cullFace?0:"back"===t.cullFace?2:+("front"===t.cullFace),normalTextureId:i(t.normalTexture,4),emissiveTextureId:i(t.emissiveTexture,16),occlusionTextureId:i(t.occlusionTexture,8),emissiveFactor:o?[o[0],o[1],o[2]]:[0,0,0],metallicRoughness:d,wrapTextures:!1,hasParametersFromSource:l},g=[];return n.forEach(({usage:t},r)=>{let n=null!=e&&e[r]&&e[r].formats,i=n?ht(n.map(({name:e,format:t})=>({name:e,encoding:ct[t]}))):[];g.push({id:r,usage:t,encodings:i})}),{material:f,textures:g}}(t,r,"integrated-mesh"===e.type))}}_loadAttribute(e,t,r){let n=`${this._layerUrl}/nodes/${e.resources.attributes}/attributes/${t.key}/0`;return this._requester.request(n,"array-buffer",r).then(e=>(0,st.m0)(t,e))}async loadAttributes(e,t,r){let n=await Promise.allSettled(t.map(t=>this._loadAttribute(e,t.attributeStorageInfo,r))),i={};for(let r=0;r<t.length;++r){let a=n[r],s=t[r];if("fulfilled"===a.status){let e=a.value;i[s.name]=e}else{let t=a.reason;(0,d.QP)(t),this._logger.error("#loadAttributes",this._logLayer,`Failed to load attributeData for '${s.name}' on node '${e.id}'`,t)}}return i}async loadNodeData(e,t){let r=null!=this._requiredAttributes&&e.resources.attributes?(0,a.Ke)(this.loadAttributes(e,this._requiredAttributes,t)):null,{bufferDefinition:n,bufferIndex:i}=function(e,t){let r={bufferDefinition:null,bufferIndex:0},n=t.resources.geometryDefinition;if(null==e||null==n||n<0)return r;let i=n>=0?e[n].geometryBuffers:null;if(null==i)return r;for(let e=0;e<i.length;e++){let t=i[e];if(null!=t.compressedAttributes){if("draco"===t.compressedAttributes.encoding&&!(0,u.A)("disable-feature:i3s-draco"))return r.bufferIndex=e,r.bufferDefinition=t,r}else r.bufferIndex=e,r.bufferDefinition=i[e]}return r}(this._geometryDefinitions,e),s=!!e.resources.geometry,o=s?(0,a.Ke)(this._loadGeometry(e.resources.geometry,i,t)):null,l=e.resources.hasSharedResource?await this._loadShared(e,t):null,h=e.resources.materialDefinition,c=this._materialAndTextures&&null!=h&&h>=0?this._materialAndTextures[h]:null==l?null:function(e){let t=e?.materialDefinitions?Object.keys(e.materialDefinitions)[0]:null,r=e?.textureDefinitions?Object.keys(e.textureDefinitions)[0]:null,n=t?e.materialDefinitions?.[t]:null,i=r?e.textureDefinitions?.[r]:null,a={alphaMode:"opaque",alphaCutoff:ut.Q,doubleSided:!0,cullFace:0,normalTextureId:-1,emissiveTextureId:-1,occlusionTextureId:-1,emissiveFactor:[0,0,0],metallicRoughness:{baseColorFactor:[.8,.8,.8,1],baseColorTextureId:-1,metallicRoughnessTextureId:-1,metallicFactor:0,roughnessFactor:.6},wrapTextures:!1,hasParametersFromSource:!0};if(null!=n){let e=n.params;e.diffuse&&((0,ot.KV)(e.diffuse),a.metallicRoughness.baseColorFactor=[e.diffuse[0],e.diffuse[1],e.diffuse[2],1]),null!=e.doubleSided&&(a.doubleSided=e.doubleSided,a.cullFace=e.doubleSided?0:2),("none"===e.cullFace||"front"===e.cullFace||"back"===e.cullFace)&&(a.cullFace="none"===e.cullFace?0:"back"===e.cullFace?2:1),e.transparency&&(a.metallicRoughness.baseColorFactor[3]=(0,C.qE)(1-e.transparency,0,1)),(e.useVertexColorAlpha||a.metallicRoughness.baseColorFactor[3]<1)&&(a.alphaMode="blend")}let s=[];if(null!=i){i.wrap&&("repeat"===i.wrap[0]||"repeat"===i.wrap[1])&&(a.wrapTextures=!0);let e=1;"rgba"===i.channels&&(a.alphaMode="blend",e|=32);let t=i.images.length-1,r=i.images[t],n=e=>e?.split("/").pop(),o=Array.isArray(i.encoding)?ht(i.encoding.map((e,t)=>({name:n(r.href[t]),encoding:dt[e]||0}))):[{name:n(r.href),encoding:dt[i.encoding]||0}];s.push({id:0,usage:e,encodings:o}),a.metallicRoughness.baseColorTextureId=0}return{material:a,textures:s}}(l),d=c?.material,f=c?.textures??[],g=`${e.id}`,m=!s&&this._options.loadFeatureData,p=m?await this._loadFeatureData(g,t):null,b=m?function(e){if(!e)return null;for(let t of e.featureData){let e=t.geometries;if(null!=e)for(let r of e)return{featureIds:[t.id],featureDataPosition:t.position,geometries:[r]}}return null}(p):{featureIds:[],geometries:[{type:"ArrayBufferView",params:{material:d}}],featureDataPosition:[0,0,0]},_=null==b?function(e){if(!e)return null;let t=[];for(let r of e.featureData)null!=r.position&&t.push({featureIds:[r.id],featureDataPosition:r.position,geometries:[]});return t}(p):null,y=f.length>0?(0,a.Ke)(this.loadTextures(e,f,t)):null,v=null,E=null;if(o){v=(0,a.QA)(await o);let e=function(e,t){if(!e||!t?.materialDefinitions)return e;let r=Object.keys(t.materialDefinitions)[0];return!t.materialDefinitions[r].params.vertexRegions&&e.vertexAttributes.region&&delete(e=(0,it.o8)(e)).vertexAttributes.region,e}(this._defaultGeometrySchema,l);E=(0,st.qs)(n,e)}let R=y?(0,a.QA)(await y):null,M=r?(0,a.QA)(await r):{},S=M?{attributeData:M,loadedAttributes:this._requiredAttributes}:null;if(null!=b)return{geometryData:b,attributeDataInfo:S,geometryBuffer:v,geometryDescriptor:E,requiredTextures:f,textureData:R};if(null!=_)return{pointData:_,attributeDataInfo:S,geometryBuffer:v,geometryDescriptor:E,requiredTextures:f,textureData:R};throw Error()}static _addAbsoluteHrefTexture(e,t){let r=e.textureDefinitions;if(null!=r)for(let e of Object.keys(r))for(let n of r[e].images)n.hrefConcat=Array.isArray(n.href)?n.href.map(e=>(0,at.s2)(e,t)):(0,at.s2)(n.href,t)}static _fixTextureEncodings(e){let t=e.textureDefinitions;if(null!=t)for(let e in t){let r=t[e];if(Array.isArray(r.encoding))for(let e=0;e<r.encoding.length;e++){let t=r.encoding[e];t.startsWith("data:")&&(r.encoding[e]=t.slice(5))}else{let e=r.encoding;e.startsWith("data:")&&(r.encoding=e.slice(5))}}}async _loadShared(e,t){if(null==e.resources.geometry)return{};let r=`${this._layerUrl}/nodes/${e.resources.geometry}/shared`,n=await this._requester.request(r,"json",t);return ft._fixTextureEncodings(n),ft._addAbsoluteHrefTexture(n,r),n}_loadTexture(e,t,r,n,i){return 4===n||1===n||2===n?this._requester.request(e,"array-buffer",i).then(e=>({id:t,usage:r,data:e,encoding:n})):this._requester.request(e,"image",i).then(e=>({id:t,usage:r,data:e,encoding:n}))}loadTextures(e,t,r){let n=this._options.textureUsageMask;return Promise.all(t.map(t=>{if(0===(t.usage&n))return null;let i=function(e,t){if(null!=t)return e.find(e=>0!==(e.encoding&t))}(t.encodings,this._options.textureEncodings);if(null==i)return this._logger.error("#loadTextures",this._logLayer,`No known encoding for texture found on node ${e.id}`),Promise.reject();let a=e.resources.texture||e.id,s=`${this._layerUrl}/nodes/${a}/textures/${i.name}`;return this._loadTexture(s,t.id,t.usage,i.encoding,r)}))}_loadFeatureData(e,t){let r=`${this._layerUrl}/nodes/${e}/features/0`;return this._requester.request(r,"json",t)}_loadGeometry(e,t,r){let n=`${this._layerUrl}/nodes/${e}/geometries/${t}`;return this._requester.request(n,"array-buffer",r)}}var gt=r(36005);let mt=class extends((0,M.w6)((0,_.b)((0,v.q)((0,E.A)((0,R.j)((0,c.M)((0,y.d)((0,b.p)((0,s.OU)(p.A)))))))))){constructor(...e){super(...e),this.geometryType="mesh",this.operationalLayerType="IntegratedMeshLayer",this.type="integrated-mesh",this.nodePages=null,this.materialDefinitions=null,this.textureSetDefinitions=null,this.geometryDefinitions=null,this.serviceUpdateTimeStamp=null,this.profile="mesh-pyramids",this.modifications=null,this._modificationsSource=null,this.path=null,this.definitionExpression=null,this._elevationQueryAbortController=new AbortController,this._elevationQueryWorkerContext=`i3s-elevation-query-${this.uid}`,this._elevationQueryWorkerHandle=null,this._elevationQueryWorkerSetup=null,this._modificationsGeneration=0}destroy(){this._elevationQueryAbortController.abort();let e=this._elevationQueryWorkerHandle;this._elevationQueryWorkerHandle=null,this._elevationQueryWorkerSetup=null,e?.destroyContextAndSelf(this._elevationQueryWorkerContext),super.destroy()}initialize(){this.addHandles([(0,f.on)(()=>this.modifications,"after-changes",()=>{this.modifications=this.modifications,this._modificationsGeneration++},f.OH),(0,f.wB)(()=>this.modifications,()=>this._modificationsGeneration++,f.OH),(0,f.wB)(()=>this.memoizedElevationQueryDependencies,()=>this._abortElevationQueriesAfterDependencyChange(),f.OH)])}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}readModifications(e,t,r){this._modificationsSource={url:(0,Ke.f)(e,r),context:r}}set elevationInfo(e){(null==e||"absolute-height"===e.mode)&&this._set("elevationInfo",e),this._validateElevationInfo(e)}async load(e){return this.addResolvingPromise(this._doLoad(e)),this}get _elevationQueryWorker(){return this._elevationQueryWorkerHandle??=new Je.Cm((e,t)=>Oe.nu.schedule(e,t))}get memoizedElevationQueryDependencies(){return[this.elevationInfo?.offset,this._modificationsGeneration]}async queryElevation(e,t,r){let s={stack:[],error:void 0,hasError:!1};try{let u=r?.noDataValue??Number.MAX_VALUE,h=this._elevationQueryWorker,c=new AbortController;e.addHandles((0,l.rE)(c),c),(0,n.mS)(s,(0,l.Bf)((0,l.hA)(()=>e.removeHandles(c))),!1);let f=AbortSignal.any([r?.signal,this._elevationQueryAbortController.signal,c.signal].filter(i.Ru));await this.load({signal:f}),(0,d.Te)(f);let g=T.q.fromGeometry(t),m={signal:f,elevationOffset:this.elevationInfo?.offset??0,scheduler:e.resourceController.scheduler};if(null==this._elevationQueryWorkerSetup){let e=this.store?.defaultGeometrySchema;null!=e&&(this._elevationQueryWorkerSetup=(0,a.Ke)(h.setLegacySchema(this._elevationQueryWorkerContext,e)))}let p=await async function(e,t,r){let n=await e.indexInfo;if((0,d.Te)(r.signal),null==n)throw new o.A("integrated-mesh-elevation-query:index-missing","I3S index information is missing.");return"page"===n.type?new Pe(e,t,r,n).promise:new De(e,t,r,n).promise}(this,g,m);(0,d.Te)(f);let b=p.coordinates[0].z===qe;b&&(p.coordinates[0].z=u);let _=await p.project(t.spatialReference,f);(0,d.Te)(f);let y=_??g.clone(),v={geometry:y.export(),noDataValue:u};return r?.returnSampleInfo&&(v.sampleInfo=y.coordinates.map(()=>({demResolution:b?-1:1}))),v}catch(e){s.error=e,s.hasError=!0}finally{(0,n.hk)(s)}}_abortElevationQueriesAfterDependencyChange(){let e=this._elevationQueryAbortController;this._elevationQueryAbortController=new AbortController,e.abort()}async processElevationQueryGeometry(e,t){let r=await this._elevationQueryWorkerSetup;return null!=r&&(0,a.QA)(r),(0,d.Te)(t),this._elevationQueryWorker.invoke(e,t)}async _doLoad(e){let t=e?.signal;try{await this.loadFromPortal({supportedTypes:["Scene Service"]},e)}catch(e){(0,d.QP)(e)}if((0,d.Te)(t),await this._fetchService(t),(0,d.Te)(t),null!=this._modificationsSource){let r=await $e.A.fromUrl(this._modificationsSource.url,this.spatialReference,e);(0,d.Te)(t),this.setAtOrigin("modifications",r,this._modificationsSource.context.origin),this._modificationsSource=null}await this._fetchIndexAndUpdateExtent(this.nodePages,t),(0,d.Te)(t)}beforeSave(){if(null!=this._modificationsSource)return this.load().then(()=>{},()=>{})}async saveAs(e,t){return this._debouncedSaveOperations(1,{...t,getTypeKeywords:()=>this._getTypeKeywords(),portalItemLayerType:"integrated-mesh"},e)}async save(){return this._debouncedSaveOperations(0,{getTypeKeywords:()=>this._getTypeKeywords(),portalItemLayerType:"integrated-mesh"})}get isUsedAsGroundLayer(){return!(0,u.A)("enable-feature:im-as-ground")||(0,Xe.S)(this.parent)||(0,Ye.Q)(this.parent)}get replacesTerrain(){return!1}validateLayer(e){if(e.layerType&&"IntegratedMesh"!==e.layerType)throw new o.A("integrated-mesh-layer:layer-type-not-supported","IntegratedMeshLayer does not support this layer type",{layerType:e.layerType});if(isNaN(this.version.major)||isNaN(this.version.minor))throw new o.A("layer:service-version-not-supported","Service version is not supported.",{serviceVersion:this.version.versionString,supportedVersions:"1.x"});if(this.version.major>1)throw new o.A("layer:service-version-too-new","Service version is too new.",{serviceVersion:this.version.versionString,supportedVersions:"1.x"})}_getTypeKeywords(){return["IntegratedMeshLayer"]}get elevationQueryDataRequester(){return new nt(this.customParameters,this.apiKey)}get elevationQueryNodeLoader(){return new ft(this,this.elevationQueryDataRequester,h.A.getLogger("esri.layers.IntegratedMeshLayer"),this.store?.defaultGeometrySchema,[],{loadFeatureData:!1,textureUsageMask:0})}_validateElevationInfo(e){let t="Integrated mesh layers";(0,He.XF)(h.A.getLogger(this),(0,He.B)(t,"absolute-height",e)),(0,He.XF)(h.A.getLogger(this),(0,He.tW)(t,e))}};(0,n.Cg)([(0,g.MZ)({type:String,readOnly:!0})],mt.prototype,"geometryType",void 0),(0,n.Cg)([(0,g.MZ)({type:["show","hide"]})],mt.prototype,"listMode",void 0),(0,n.Cg)([(0,g.MZ)({type:["IntegratedMeshLayer"]})],mt.prototype,"operationalLayerType",void 0),(0,n.Cg)([(0,g.MZ)({json:{read:!1},readOnly:!0})],mt.prototype,"type",void 0),(0,n.Cg)([(0,g.MZ)({type:Be.W4,readOnly:!0,clonable:!1})],mt.prototype,"nodePages",void 0),(0,n.Cg)([(0,g.MZ)({type:[Be.uV],readOnly:!0,clonable:!1})],mt.prototype,"materialDefinitions",void 0),(0,n.Cg)([(0,g.MZ)({type:[Be.Ot],readOnly:!0,clonable:!1})],mt.prototype,"textureSetDefinitions",void 0),(0,n.Cg)([(0,g.MZ)({type:[Be.L0],readOnly:!0,clonable:!1})],mt.prototype,"geometryDefinitions",void 0),(0,n.Cg)([(0,g.MZ)({readOnly:!0})],mt.prototype,"serviceUpdateTimeStamp",void 0),(0,n.Cg)([(0,g.MZ)({type:$e.A,clonable:e=>e?.clone()??e}),(0,m.P)({origins:["web-scene","portal-item"],type:"resource",prefix:"modifications"})],mt.prototype,"modifications",void 0),(0,n.Cg)([(0,g.MZ)({clonable:e=>e?{...e}:null})],mt.prototype,"_modificationsSource",void 0),(0,n.Cg)([(0,gt.w)(["web-scene","portal-item"],"modifications")],mt.prototype,"readModifications",null),(0,n.Cg)([(0,g.MZ)(S.Yj)],mt.prototype,"elevationInfo",null),(0,n.Cg)([(0,g.MZ)({type:String,json:{origins:{"web-scene":{read:!0,write:!0},"portal-item":{read:!0,write:!0}},read:!1}})],mt.prototype,"path",void 0),(0,n.Cg)([(0,g.MZ)({clonable:!1})],mt.prototype,"_elevationQueryWorker",null),(0,n.Cg)([(0,g.MZ)()],mt.prototype,"_modificationsGeneration",void 0),(0,n.Cg)([(0,g.MZ)()],mt.prototype,"memoizedElevationQueryDependencies",null),(0,n.Cg)([(0,g.MZ)()],mt.prototype,"isUsedAsGroundLayer",null),(0,n.Cg)([(0,g.MZ)()],mt.prototype,"replacesTerrain",null),(0,n.Cg)([(0,g.MZ)({clonable:!1})],mt.prototype,"elevationQueryDataRequester",null),(0,n.Cg)([(0,g.MZ)({clonable:!1})],mt.prototype,"elevationQueryNodeLoader",null),mt=(0,n.Cg)([(0,g.$K)("esri.layers.IntegratedMeshLayer")],mt);const pt=mt},85707(e,t,r){var n=r(32198),i=r(91429),a=r(54239);r.d(t,["a",0,e=>{let t=e,r=class extends t{constructor(){super(...arguments),this.heightModelInfo=null}read(e,t){super.read(e,t),"service"===t?.origin&&2===this.heightModelInfo?.origin&&(this.heightModelInfo.associatedSpatialReference=this.getAtOrigin("spatialReference","service"))}};return(0,n.Cg)([(0,i.MZ)({readOnly:!0,type:a.A})],r.prototype,"heightModelInfo",void 0),r=(0,n.Cg)([(0,i.$K)("esri.layers.mixins.HeightModelInfoMixin")],r),r}])},10292(e,t,r){r.d(t,{q:()=>o});var n=r(48526),i=r(86738),a=r(82799),s=r(99917);class o{constructor(e){this.geometry=e,this.spatialReference=e.spatialReference}export(){return this._exporter(this.coordinates,this.spatialReference)}clone(e){let t=new o(this.geometry);return t.spatialReference=this.spatialReference,t.coordinates=e??this.coordinates.map(e=>e.clone()),t._exporter=this._exporter,t}async project(e,t){if(this.spatialReference.equals(e))return this.clone();await(0,s.initializeProjection)([{source:this.spatialReference,dest:e}],{signal:t});let r=new n.A({spatialReference:this.spatialReference,points:this.coordinates.map(e=>[e.x,e.y])}),i=(0,s.project)(r,e);if(!i)return null;let a=this.coordinates.map((e,t)=>{let r=e.clone(),n=i.points[t];return r.x=n[0],r.y=n[1],r}),o=this.clone(a);return o.spatialReference=e,o}projectSync(e){if(this.spatialReference.equals(e))return this.clone();let t=new n.A({spatialReference:this.spatialReference,points:this.coordinates.map(e=>[e.x,e.y])}),r=(0,s.project)(t,e);if(!r)return null;let i=this.coordinates.map((e,t)=>{let n=e.clone(),i=r.points[t];return n.x=i[0],n.y=i[1],n}),a=this.clone(i);return a.spatialReference=e,a}static fromGeometry(e){let t=new o(e);if(e instanceof o)return t.coordinates=e.coordinates.map(e=>e.clone()),t._exporter=(t,r)=>{let n=e.clone(t);return n.spatialReference=r,n},t;switch(e.type){case"point":{let r=e,{hasZ:n,hasM:a}=r;return t.coordinates=n&&a?[new l(r.x,r.y,r.z,r.m)]:n?[new l(r.x,r.y,r.z)]:a?[new l(r.x,r.y,null,r.m)]:[new l(r.x,r.y)],t._exporter=(t,r)=>e.hasM?new i.A(t[0].x,t[0].y,t[0].z,t[0].m,r):new i.A(t[0].x,t[0].y,t[0].z,r),t}case"multipoint":{let r=e,{hasZ:i,hasM:a}=r;return t.coordinates=i&&a?r.points.map(e=>new l(e[0],e[1],e[2],e[3])):i?r.points.map(e=>new l(e[0],e[1],e[2])):a?r.points.map(e=>new l(e[0],e[1],null,e[2])):r.points.map(e=>new l(e[0],e[1])),t._exporter=(t,r)=>e.hasM?new n.A({points:t.map(e=>[e.x,e.y,e.z??0,e.m??0]),hasZ:!0,hasM:!0,spatialReference:r}):new n.A({points:t.map(e=>[e.x,e.y,e.z??0]),spatialReference:r}),t}case"polyline":{let r=e,n=[],i=[],{hasZ:s,hasM:o}=e,u=0;for(let e of r.paths)if(i.push([u,u+e.length]),u+=e.length,s&&o)for(let t of e)n.push(new l(t[0],t[1],t[2],t[3]));else if(s)for(let t of e)n.push(new l(t[0],t[1],t[2]));else if(o)for(let t of e)n.push(new l(t[0],t[1],null,t[2]));else for(let t of e)n.push(new l(t[0],t[1]));return t.coordinates=n,t._exporter=(t,r)=>{let n=e.hasM?t.map(e=>[e.x,e.y,e.z??0,e.m??0]):t.map(e=>[e.x,e.y,e.z??0]),s=i.map(e=>n.slice(e[0],e[1]));return new a.A({paths:s,hasM:e.hasM,hasZ:!0,spatialReference:r})},t}}}}class l{constructor(e,t,r=null,n=null,i=null,a=null){this.x=e,this.y=t,this.z=r,this.m=n,this.tile=i,this.elevationTile=a}clone(){return new l(this.x,this.y,this.z,this.m)}}},73179(e,t,r){r.d(t,{b:()=>l,h:()=>u});var n=r(4718),i=r(53966),a=r(84952),s=r(60694),o=r(10873);function l(e){let{nonStandardUrlAllowed:t=!1,separator:r}=e??{},a=(0,n.o8)(o.OZ),l=a.json?.write;return"object"==typeof l&&l&&(l.writer=function(e,t,n,i){(0,s.LS)(this,e,r,t,i)}),{...a,set:function(e){if(null==e)return void this._set("url",e);let r=(0,s.HZ)({layer:this,url:e,nonStandardUrlAllowed:t,logger:i.A.getLogger(this)});this._set("url",r.url),null!=r.layerId&&this._set("layerId",r.layerId)}}}function u(e,t){let{separator:r}=t??{},n=(0,a.An)(e.url);return null!=n&&(null==e.dynamicDataSource?null!=e.layerId&&(n.path=(0,a.fj)(n.path,r??"",e.layerId.toString())):n.path=(0,a.fj)(n.path,"dynamicLayer")),n}},89707(e,t,r){r.d(t,{H:()=>n});class n{constructor(e=1/0,t=-1/0){this.minElevation=e,this.maxElevation=t}get elevationRangeValid(){return!Number.isNaN(this.minElevation)}get isEmpty(){return!(this.minElevation<=this.maxElevation)}contains(e){return this.minElevation<=e.minElevation&&this.maxElevation>=e.maxElevation}invalidateElevationRange(){this.minElevation=NaN}initializeEmpty(){this.minElevation=1/0,this.maxElevation=-1/0}expandElevationRange(e){let t=Math.min(this.minElevation,e.minElevation),r=Math.max(this.maxElevation,e.maxElevation),n=t!==this.minElevation||r!==this.maxElevation;return this.minElevation=t,this.maxElevation=r,n}expandElevationRangeValues(e,t){let r=Math.min(this.minElevation,e),n=Math.max(this.maxElevation,t),i=r!==this.minElevation||n!==this.maxElevation;return this.minElevation=r,this.maxElevation=n,i}setElevationRange(e){this.minElevation=e.minElevation,this.maxElevation=e.maxElevation}setElevationRangeValues(e,t){this.minElevation=e,this.maxElevation=t}equals(e){return this.minElevation===e.minElevation&&this.maxElevation===e.maxElevation}}},62747(e,t,r){r.d(t,{W7:()=>a,hH:()=>s});var n=r(1843),i=r(65786);i.Y;class a extends i.Y{constructor(e,t,r){super(),this.hasVertexColors=e,this.hasNormals=t,this.textureCoordinateType=r}}function s(e){let t=(0,n.BP)().vec3f("position");return e.hasNormals&&t.vec2i16("normalCompressed",{glNormalized:!0}),1===e.textureCoordinateType?t.vec2f("uv0"):2===e.textureCoordinateType&&(t.vec2f("uv0"),t.vec4u16("uvRegion",{glNormalized:!0})),e.hasVertexColors&&t.vec4u8("color",{glNormalized:!0}),t.freeze()}},92359(e,t,r){r.d(t,{nu:()=>d,W6:()=>u}),r(4576),r(71511),r(44208),r(53966);var n=r(17676),i=(r(36708),r(44794),r(78659)),a=r(32198),s=r(69622),o=r(91429);let l=class extends s.A{constructor(){super(...arguments),this.SCHEDULER_LOG_SLOW_TASKS=!1,this.FEATURE_SERVICE_SNAPPING_SOURCE_TILE_TREE_SHOW_TILES=!1}};(0,a.Cg)([(0,o.MZ)()],l.prototype,"SCHEDULER_LOG_SLOW_TASKS",void 0),(0,a.Cg)([(0,o.MZ)()],l.prototype,"FEATURE_SERVICE_SNAPPING_SOURCE_TILE_TREE_SHOW_TILES",void 0),l=(0,a.Cg)([(0,o.$K)("esri.views.support.debugFlags")],l),new l,r(49186),Symbol("Yield");const u={RESOURCE_CONTROLLER_IMMEDIATE:"immediate",RESOURCE_CONTROLLER:"schedule",SLIDE:"slide",STREAM_DATA_LOADER:"stream loader",ELEVATION_QUERY:"elevation query",TERRAIN_SURFACE:"terrain",SURFACE_GEOMETRY_UPDATES:"surface geometry updates",LOD_RENDERER:"LoD renderer",GRAPHICS_CORE:"Graphics3D",I3S:"I3S",LYR3D:"Lyr3D",TILES3D:"3DTiles",POINT_CLOUD_LAYER:"point cloud",FEATURE_TILE_FETCHER:"feature fetcher",STREAM_CONTROLLER:"stream controller",SCREEN_POLYGON_INTERSECTION:"screen polygon intersection",OCCLUSION_QUERY:"occlusion query",OVERLAY:"overlay",OVERLAY_RENDERER:"overlay renderer",STAGE:"stage",GRAPHICS_DECONFLICTOR:"graphics deconflictor",FILTER_VISIBILITY:"graphics filter visibility",SCALE_VISIBILITY:"graphics scale visibility",FRUSTUM_VISIBILITY:"graphics frustum visibility",POINT_OF_INTEREST_FREQUENT:"POI frequent",POINT_OF_INTEREST_INFREQUENT:"POI infrequent",LABELER:"labeler",FEATURE_QUERY_ENGINE:"feature query",FEATURE_TILE_TREE:"feature tile tree",FEATURE_TILE_TREE_ACTIVE:"fast feature tile tree",ELEVATION_ALIGNMENT:"elevation alignment",ELEVATION_ALIGNMENT_SCENE:"elevation alignment scene",TEXT_TEXTURE_ATLAS:"text texture atlas",TEXTURE_UNLOAD:"texture unload",LINE_OF_SIGHT_TOOL:"line of sight tool",LINE_OF_SIGHT_TOOL_INTERACTIVE:"interactive line of sight tool",VOLUME_MEASUREMENT:"volume measurement",ELEVATION_PROFILE:"elevation profile",SNAPPING:"snapping",SHADOW_ACCUMULATOR:"shadow accumulator",CLOUDS_GENERATOR:"clouds generator",FLOW_GENERATOR:"flow generator",GAUSSIAN_SPLAT_SORTING:"gaussian splat sorting",GAUSSIAN_SPLAT_TEXTURE_ATLAS:"gaussian splat texture atlas",MAPVIEW_FETCH_QUEUE:"mapview fetch queue",MAPVIEW_LAYERVIEW_UPDATE:"mapview layerview update",MAPVIEW_VECTOR_TILE_PARSING_QUEUE:"mapview vector tile parsing queue",NONE:0,TEST_PRIO:1};new Map([[u.RESOURCE_CONTROLLER_IMMEDIATE,0],[u.RESOURCE_CONTROLLER,4],[u.SLIDE,0],[u.STREAM_DATA_LOADER,0],[u.ELEVATION_QUERY,0],[u.TERRAIN_SURFACE,1],[u.SURFACE_GEOMETRY_UPDATES,1],[u.LOD_RENDERER,2],[u.GRAPHICS_CORE,2],[u.I3S,2],[u.LYR3D,2],[u.TILES3D,3],[u.POINT_CLOUD_LAYER,2],[u.FEATURE_TILE_FETCHER,2],[u.STREAM_CONTROLLER,2],[u.SCREEN_POLYGON_INTERSECTION,0],[u.CLOUDS_GENERATOR,2],[u.OCCLUSION_QUERY,2],[u.OVERLAY,4],[u.OVERLAY_RENDERER,4],[u.STAGE,4],[u.GRAPHICS_DECONFLICTOR,4],[u.FILTER_VISIBILITY,4],[u.SCALE_VISIBILITY,4],[u.FRUSTUM_VISIBILITY,4],[u.POINT_OF_INTEREST_FREQUENT,6],[u.POINT_OF_INTEREST_INFREQUENT,30],[u.LABELER,8],[u.FEATURE_QUERY_ENGINE,8],[u.FEATURE_TILE_TREE,16],[u.FEATURE_TILE_TREE_ACTIVE,0],[u.ELEVATION_ALIGNMENT,12],[u.ELEVATION_ALIGNMENT_SCENE,14],[u.TEXT_TEXTURE_ATLAS,12],[u.TEXTURE_UNLOAD,12],[u.LINE_OF_SIGHT_TOOL,16],[u.LINE_OF_SIGHT_TOOL_INTERACTIVE,0],[u.VOLUME_MEASUREMENT,4],[u.SNAPPING,0],[u.SHADOW_ACCUMULATOR,30],[u.FLOW_GENERATOR,12],[u.GAUSSIAN_SPLAT_SORTING,2],[u.GAUSSIAN_SPLAT_TEXTURE_ATLAS,12],[u.MAPVIEW_FETCH_QUEUE,0],[u.MAPVIEW_LAYERVIEW_UPDATE,2],[u.MAPVIEW_VECTOR_TILE_PARSING_QUEUE,0]]),(0,i.l5)(6.5),(0,i.l5)(1),(0,i.l5)(30),(0,i.l5)(1e3/30),(0,i.l5)(100),Symbol.dispose;const h=new class{constructor(){this._begin=performance?.now()??0,this._budget=0,this._done=!1,this._progressed=!1,this._enabled=!0}run(e){return!this.done&&(!0===e()&&this.madeProgress(),!0)}get done(){return this._done}get budget(){return this._budget}madeProgress(){return this._progressed=!0,this._done=this.elapsed>=this._budget&&this._enabled,this._done}get enabled(){return this._enabled}set enabled(e){this._enabled=e}reset(e){this._begin=this.now(),this._budget=e,this.resetProgress()}get remaining(){return Math.max(this._budget-this.elapsed,0)}now(){return performance.now()}get elapsed(){return this.now()-this._begin}resetProgress(){this._progressed=!1,this._done=!1}get hasProgressed(){return this._progressed}};h.enabled=!1;class c{remove(){}[Symbol.dispose](){this.remove()}processQueue(){}schedule(e,t,r){try{if((0,n.G4)(t)){let e=(0,n.NK)();return r?Promise.resolve(r(e)):Promise.reject(e)}return(0,n.z7)(e(h))}catch(e){return Promise.reject(e)}}reschedule(e,t,r){return this.schedule(e,t,r)}async scheduleGenerator(e,t,r){if((0,n.G4)(t)){let e=(0,n.NK)();if(r)return r(e);throw e}let i=e(h);for(;;){let e=i.next(h),a=(0,n.$X)(e)?await e:e;if((0,n.G4)(t)){let e=(0,n.NK)();if(r){let t=r(e),a=i.return(null);return(0,n.$X)(a)&&await(0,n.QZ)(a),t}let t=i.throw(e);throw(0,n.$X)(t)&&await(0,n.QZ)(t),e}if(a.done)return a.value}}}const d=new c}}]);
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[3527],{68197(e,t,r){r.d(t,{A:()=>h});var n=r(40876),i=r(4576),a=r(34727),s=r(78888);function o(e){return(0,a.qE)((0,s.Vr)(e),0,255)}function l(e,t){let r=e.toString(16).padStart(2,"0");return t?r.slice(0,1):r}function u(e){return.2126*(0,n.Q6)(e.r)+.7152*(0,n.Q6)(e.g)+.0722*(0,n.Q6)(e.b)}class h{static blendColors(e,t,r,n=new h){return n.r=Math.round(e.r+(t.r-e.r)*r),n.g=Math.round(e.g+(t.g-e.g)*r),n.b=Math.round(e.b+(t.b-e.b)*r),n.a=e.a+(t.a-e.a)*r,n._sanitize()}static fromRgb(e,t){let r=(0,n.lT)(e);return r?h.fromArray(r,t):null}static fromHex(e,t=new h){let r=(0,n.oW)(e);return r?h.fromArray(r,t):null}static fromArray(e,t=new h){return t._set(Number(e[0]),Number(e[1]),Number(e[2]),Number(e[3])),isNaN(t.a)&&(t.a=1),t._sanitize()}static fromString(e,t){let r=(0,n.Eq)(e);return r?h.fromArray(r,t):null}static fromJSON(e){return null==e?void 0:new h([e[0],e[1],e[2],(e[3]??255)/255])}toUnitRGB(){return[this.r/255,this.g/255,this.b/255]}toUnitRGBA(e){return e??=[0,0,0,0],e[0]=this.r/255,e[1]=this.g/255,e[2]=this.b/255,e[3]=null==this.a?1:this.a,e}constructor(e){this.r=255,this.g=255,this.b=255,this.a=1,e&&this.setColor(e)}get isBright(){return this.toYiq()>=127}isLowContrastBlend(e,t=3){let r=e instanceof h?e:new h(e),n=u(this),i=u(r);return(Math.max(n,i)+.05)/(Math.min(n,i)+.05)<t}setColor(e){if("string"==typeof e)h.fromString(e,this);else if((0,i.yc)(e))h.fromArray(e,this);else{let t=e;this._set(t.r??0,t.g??0,t.b??0,t.a??1),e instanceof h||this._sanitize()}return this}toRgb(){return[this.r,this.g,this.b]}toRgba(){return[this.r,this.g,this.b,this.a]}toHex(e){let t=e?.capitalize??!1,r=e?.digits??6,n=3===r||4===r,i=4===r||8===r,a=`#${l(this.r,n)}${l(this.g,n)}${l(this.b,n)}${i?l(Math.round(255*this.a),n):""}`;return t?a.toUpperCase():a}toYiq(){return.299*this.r+.587*this.g+.114*this.b}toCss(e=!1){let t=this.r+", "+this.g+", "+this.b;return e?`rgba(${t}, ${this.a})`:`rgb(${t})`}toString(){return this.toCss(!0)}toJSON(){return this.toArray()}toArray(e=0){let t=o(this.r),r=o(this.g),n=o(this.b);return 0===e||1!==this.a?[t,r,n,o(255*this.a)]:[t,r,n]}clone(){return new h(this.toRgba())}hash(){return this.r<<24|this.g<<16|this.b<<8|255*this.a}equals(e){return null!=e&&e.r===this.r&&e.g===this.g&&e.b===this.b&&e.a===this.a}_sanitize(){return this.r=(0,n.c1)(this.r),this.g=(0,n.c1)(this.g),this.b=(0,n.c1)(this.b),this.a=(0,n.G1)(this.a),this}_set(e,t,r,n){this.r=e,this.g=t,this.b=r,this.a=n}}h.prototype.declaredClass="esri.Color"},40876(e,t,r){r.d(t,{Eq:()=>f,G1:()=>m,Q6:()=>y,TS:()=>a,V6:()=>i,Vm:()=>g,ay:()=>l,c1:()=>p,c4:()=>s,j5:()=>u,lT:()=>c,oW:()=>h,xV:()=>v});const n={transparent:[0,0,0,0],black:[0,0,0,1],silver:[192,192,192,1],gray:[128,128,128,1],white:[255,255,255,1],maroon:[128,0,0,1],red:[255,0,0,1],purple:[128,0,128,1],fuchsia:[255,0,255,1],green:[0,128,0,1],lime:[0,255,0,1],olive:[128,128,0,1],yellow:[255,255,0,1],navy:[0,0,128,1],blue:[0,0,255,1],teal:[0,128,128,1],aqua:[0,255,255,1],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],blanchedalmond:[255,235,205,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],oldlace:[253,245,230,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],rebeccapurple:[102,51,153,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],whitesmoke:[245,245,245,1],yellowgreen:[154,205,50,1]};function i(e){return!!n[e]||!!n[e.toLowerCase()]}function a(e){return n[e]??n[e.toLowerCase()]}function s(e){return[...a(e)]}function o(e,t,r){r<0&&++r,r>1&&--r;let n=6*r;return n<1?e+(t-e)*n:2*r<1?t:3*r<2?e+(t-e)*(2/3-r)*6:e}function l(e,t,r,n=1){let i=(e%360+360)%360/360,a=r<=.5?r*(t+1):r+t-r*t,s=2*r-a;return[Math.round(255*o(s,a,i+1/3)),Math.round(255*o(s,a,i)),Math.round(255*o(s,a,i-1/3)),n]}function u(e){let t=e.length>5,r=t?8:4,n=(1<<r)-1,i=t?1:17,a=t?9===e.length:5===e.length,s=Number("0x"+e.slice(1));if(isNaN(s))return null;let o,l=[0,0,0,1];return a&&(o=s&n,s>>=r,l[3]=i*o/255),o=s&n,s>>=r,l[2]=i*o,o=s&n,s>>=r,l[1]=i*o,o=s&n,s>>=r,l[0]=i*o,l}function h(e){if(!e.startsWith("#")||isNaN(Number(`0x${e.slice(1)}`)))return null;switch(e.length){case 4:case 5:{let t=parseInt(e.slice(1,2),16),r=parseInt(e.slice(2,3),16),n=parseInt(e.slice(3,4),16),i=4===e.length?15:parseInt(e.slice(4),16);return[t+16*t,r+16*r,n+16*n,(i+16*i)/255]}case 7:case 9:return[parseInt(e.slice(1,3),16),parseInt(e.slice(3,5),16),parseInt(e.slice(5,7),16),(7===e.length?255:parseInt(e.slice(7),16))/255];default:return null}}function c(e){let t=e.toLowerCase().match(/^(rgba?|hsla?)\(([\s.\-,%0-9]+)\)/);if(t){let e=t[2].split(/\s*,\s*/),r=t[1];if("rgb"===r&&3===e.length||"rgba"===r&&4===e.length){if(e[0].endsWith("%")){let t=e.map(e=>2.56*parseFloat(e));return 4===e.length&&(t[3]=parseFloat(e[3])),d(t)}return d(e.map(e=>parseFloat(e)))}if("hsl"===r&&3===e.length||"hsla"===r&&4===e.length)return l(parseFloat(e[0]),parseFloat(e[1])/100,parseFloat(e[2])/100,parseFloat(e[3]??"1"))}return null}function d(e){return e[0]=p(e[0]),e[1]=p(e[1]),e[2]=p(e[2]),e[3]=4===e.length?m(e[3]):1,e}function f(e){let t=i(e)?a(e):null;return t??=c(e),t??=h(e),t}function g(e){let t=f(e);return null==t?null:[t[0]/255,t[1]/255,t[2]/255,t[3]]}function m(e){return b(e,0,1)}function p(e){return Math.round(b(e,0,255))}function b(e,t,r){return e=Number(e),isNaN(e)?r:e<t?t:e>r?r:e}const _=1/2.2;function y(e){return e**2.2}function v(e){return e**_}r.d(t,["iw",0,_])},85334(e,t,r){r.d(t,{$:()=>_,IB:()=>o,Iy:()=>S,KV:()=>R,N2:()=>y,RH:()=>E,ZD:()=>v,sn:()=>M});var n=r(68197),i=r(4576),a=r(4718),s=r(34727);function o(e){return"r"in e&&"g"in e&&"b"in e}function l(e){return"h"in e&&"s"in e&&"v"in e}function u(e){return"l"in e&&"a"in e&&"b"in e}function h(e){return"l"in e&&"c"in e&&"h"in e}r(78955),r(91829);const c=[[.4124,.3576,.1805],[.2126,.7152,.0722],[.0193,.1192,.9505]],d=[[3.2406,-1.5372,-.4986],[-.9689,1.8758,.0415],[.0557,-.204,1.057]];function f(e,t){let r,n,i=[];if(e[0].length!==t.length)throw Error("dimensions do not match");let a=e.length,s=e[0].length,o=0;for(r=0;r<a;r++){for(o=0,n=0;n<s;n++)o+=e[r][n]*t[n];i.push(o)}return i}function g(e){let t=[e.r/255,e.g/255,e.b/255].map(e=>e<=.04045?e/12.92:((e+.055)/1.055)**2.4),r=f(c,t);return{x:100*r[0],y:100*r[1],z:100*r[2]}}function m(e){let t=f(d,[e.x/100,e.y/100,e.z/100]).map(e=>{let t=e<=.0031308?12.92*e:1.055*e**(1/2.4)-.055;return Math.min(1,Math.max(t,0))});return{r:Math.round(255*t[0]),g:Math.round(255*t[1]),b:Math.round(255*t[2])}}function p(e){let t=[e.x/95.047,e.y/100,e.z/108.883].map(e=>e>(6/29)**3?e**(1/3):1/3*(29/6)**2*e+4/29);return{l:116*t[1]-16,a:500*(t[0]-t[1]),b:200*(t[1]-t[2])}}function b(e){let t=e.l,r=[(t+16)/116+e.a/500,(t+16)/116,(t+16)/116-e.b/200].map(e=>e>6/29?e**3:3*(6/29)**2*(e-4/29));return{x:95.047*r[0],y:100*r[1],z:108.883*r[2]}}function _(e){return o(e)?e:h(e)?function(e){return m(b(function(e){let t=e.l,r=e.c,n=e.h;return{l:t,a:r*Math.cos(n),b:r*Math.sin(n)}}(e)))}(e):u(e)?function(e){return m(b(e))}(e):function(e){return"x"in e&&"y"in e&&"z"in e}(e)?m(e):l(e)?function(e){let t,r=(e.h+360)%360/60,n=e.s/100,i=e.v/100*255,a=i*n,s=a*(1-Math.abs(r%2-1));switch(Math.floor(r)){case 0:t={r:a,g:s,b:0};break;case 1:t={r:s,g:a,b:0};break;case 2:t={r:0,g:a,b:s};break;case 3:t={r:0,g:s,b:a};break;case 4:t={r:s,g:0,b:a};break;case 5:case 6:t={r:a,g:0,b:s};break;default:t={r:0,g:0,b:0}}return t.r=Math.round(t.r+i-a),t.g=Math.round(t.g+i-a),t.b=Math.round(t.b+i-a),t}(e):e}function y(e){return l(e)?e:function(e){let{r:t,g:r,b:n}=e,i=Math.max(t,r,n),a=i-Math.min(t,r,n),s=i,o=0===a?0:i===t?(r-n)/a%6:i===r?(n-t)/a+2:(t-r)/a+4,l=0===a?0:a/s;return o<0&&(o+=6),o*=60,l*=100,s*=100/255,{h:o,s:l,v:s}}(_(e))}function v(e){return u(e)?e:function(e){return p(g(e))}(_(e))}function E(e){return h(e)?e:function(e){return function(e){let t=e.l,r=e.a,n=e.b,i=Math.sqrt(r*r+n*n),a=Math.atan2(n,r);return a=a>0?a:a+2*Math.PI,{l:t,c:i,h:a}}(p(g(e)))}(_(e))}function R(e){return e[0]??=0,e[1]??=0,e[2]??=0,e}function M(e){return e.length=4,R(e),e[3]??=1,(0,s.qE)(e[3],0,1),e}function S(e,t,r={}){if(0===e.length||t<=0)return[];if(1===(e=e.map(e=>"string"==typeof e?new n.A(e):e)).length||1===t){let r=[],n=e[0];for(let e=0;e<t;e++)r.push(n.clone());return r}if(r.shuffle&&(e=(0,i.k4)((0,a.o8)(e),r.seed)),e.length>=t){let r=[],n=(e.length-1)/(t-1);for(let i=0;i<t;i++){let t=Math.round(i*n);r.push(e[t].clone())}return r}return function(e,t,r={}){let n=[],a=e.length-1,s=Math.ceil((t-e.length)/a);e:for(let i=0;i<a;i++){let a=e[i],o=e[i+1];for(let i=1;i<=s;i++){let l=i/(s+1);if(n.push(x(a,o,l,r)),n.length+e.length===t)break e}}return[...e.map(e=>e.clone()),...(0,i.k4)(n,r.seed??1)]}(e,t,r)}const T=(e,t)=>{let r=Math.floor(10*t())-5;return Math.min(255,Math.max(0,e+r))};function x(e,t,r,a={}){let s=e.r,o=e.g,l=e.b,u=t.r,h=t.g,c=t.b,d=Math.round(s+(u-s)*r),f=Math.round(o+(h-o)*r),g=Math.round(l+(c-l)*r);if(!a.offset)return new n.A([d,f,g]);let m=(0,i.Mo)(a.seed);return new n.A([T(d,m),T(f,m),T(g,m)])}},9093(e,t,r){function n(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}function i(e){return[e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8],e[9],e[10],e[11],e[12],e[13],e[14],e[15]]}r.d(t,{o8:()=>i,vt:()=>n});const a=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:a,clone:i,create:n,fromValues:function(e,t,r,n,i,a,s,o,l,u,h,c,d,f,g,m){return[e,t,r,n,i,a,s,o,l,u,h,c,d,f,g,m]}},Symbol.toStringTag,{value:"Module"})),r.d(t,["zK",0,a])},58083(e,t,r){r.d(t,{$0:()=>b,$h:()=>I,B8:()=>h,C:()=>a,D_:()=>o,N9:()=>y,O7:()=>x,Qw:()=>u,Tl:()=>d,X_:()=>M,e$:()=>g,eL:()=>m,hM:()=>_,hZ:()=>s,hs:()=>f,kN:()=>p,l:()=>S,lw:()=>c,mg:()=>l,o1:()=>T,sC:()=>R,t2:()=>C,t5:()=>A,tZ:()=>O,ut:()=>N});var n=r(51850),i=r(34304);function a(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}function s(e,t,r,n,i,a,s,o,l,u,h,c,d,f,g,m,p){return e[0]=t,e[1]=r,e[2]=n,e[3]=i,e[4]=a,e[5]=s,e[6]=o,e[7]=l,e[8]=u,e[9]=h,e[10]=c,e[11]=d,e[12]=f,e[13]=g,e[14]=m,e[15]=p,e}function o(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function l(e,t){if(e===t){let r=t[1],n=t[2],i=t[3],a=t[6],s=t[7],o=t[11];e[1]=t[4],e[2]=t[8],e[3]=t[12],e[4]=r,e[6]=t[9],e[7]=t[13],e[8]=n,e[9]=a,e[11]=t[14],e[12]=i,e[13]=s,e[14]=o}else e[0]=t[0],e[1]=t[4],e[2]=t[8],e[3]=t[12],e[4]=t[1],e[5]=t[5],e[6]=t[9],e[7]=t[13],e[8]=t[2],e[9]=t[6],e[10]=t[10],e[11]=t[14],e[12]=t[3],e[13]=t[7],e[14]=t[11],e[15]=t[15];return e}function u(e,t){return h(e,t)||o(e),e}function h(e,t){let r=t[0],n=t[1],i=t[2],a=t[3],s=t[4],o=t[5],l=t[6],u=t[7],h=t[8],c=t[9],d=t[10],f=t[11],g=t[12],m=t[13],p=t[14],b=t[15],_=r*o-n*s,y=r*l-i*s,v=r*u-a*s,E=n*l-i*o,R=n*u-a*o,M=i*u-a*l,S=h*m-c*g,T=h*p-d*g,x=h*b-f*g,I=c*p-d*m,A=c*b-f*m,w=d*b-f*p,C=_*w-y*A+v*I+E*x-R*T+M*S;return C?(C=1/C,e[0]=(o*w-l*A+u*I)*C,e[1]=(i*A-n*w-a*I)*C,e[2]=(m*M-p*R+b*E)*C,e[3]=(d*R-c*M-f*E)*C,e[4]=(l*x-s*w-u*T)*C,e[5]=(r*w-i*x+a*T)*C,e[6]=(p*v-g*M-b*y)*C,e[7]=(h*M-d*v+f*y)*C,e[8]=(s*A-o*x+u*S)*C,e[9]=(n*x-r*A-a*S)*C,e[10]=(g*R-m*v+b*_)*C,e[11]=(c*v-h*R-f*_)*C,e[12]=(o*T-s*I-l*S)*C,e[13]=(r*I-n*T+i*S)*C,e[14]=(m*y-g*E-p*_)*C,e[15]=(h*E-c*y+d*_)*C,e):null}function c(e,t,r){let n=t[0],i=t[1],a=t[2],s=t[3],o=t[4],l=t[5],u=t[6],h=t[7],c=t[8],d=t[9],f=t[10],g=t[11],m=t[12],p=t[13],b=t[14],_=t[15],y=r[0],v=r[1],E=r[2],R=r[3];return e[0]=y*n+v*o+E*c+R*m,e[1]=y*i+v*l+E*d+R*p,e[2]=y*a+v*u+E*f+R*b,e[3]=y*s+v*h+E*g+R*_,y=r[4],v=r[5],E=r[6],R=r[7],e[4]=y*n+v*o+E*c+R*m,e[5]=y*i+v*l+E*d+R*p,e[6]=y*a+v*u+E*f+R*b,e[7]=y*s+v*h+E*g+R*_,y=r[8],v=r[9],E=r[10],R=r[11],e[8]=y*n+v*o+E*c+R*m,e[9]=y*i+v*l+E*d+R*p,e[10]=y*a+v*u+E*f+R*b,e[11]=y*s+v*h+E*g+R*_,y=r[12],v=r[13],E=r[14],R=r[15],e[12]=y*n+v*o+E*c+R*m,e[13]=y*i+v*l+E*d+R*p,e[14]=y*a+v*u+E*f+R*b,e[15]=y*s+v*h+E*g+R*_,e}function d(e,t,r){let n=r[0],i=r[1],a=r[2];if(t===e)e[12]=t[0]*n+t[4]*i+t[8]*a+t[12],e[13]=t[1]*n+t[5]*i+t[9]*a+t[13],e[14]=t[2]*n+t[6]*i+t[10]*a+t[14],e[15]=t[3]*n+t[7]*i+t[11]*a+t[15];else{let r=t[0],s=t[1],o=t[2],l=t[3],u=t[4],h=t[5],c=t[6],d=t[7],f=t[8],g=t[9],m=t[10],p=t[11];e[0]=r,e[1]=s,e[2]=o,e[3]=l,e[4]=u,e[5]=h,e[6]=c,e[7]=d,e[8]=f,e[9]=g,e[10]=m,e[11]=p,e[12]=r*n+u*i+f*a+t[12],e[13]=s*n+h*i+g*a+t[13],e[14]=o*n+c*i+m*a+t[14],e[15]=l*n+d*i+p*a+t[15]}return e}function f(e,t,r){let n=r[0],i=r[1],a=r[2];return e[0]=t[0]*n,e[1]=t[1]*n,e[2]=t[2]*n,e[3]=t[3]*n,e[4]=t[4]*i,e[5]=t[5]*i,e[6]=t[6]*i,e[7]=t[7]*i,e[8]=t[8]*a,e[9]=t[9]*a,e[10]=t[10]*a,e[11]=t[11]*a,e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}function g(e,t,r,n){let s=n[0],o=n[1],l=n[2],u=Math.sqrt(s*s+o*o+l*l);if(u<=(0,i.FD)())return void a(e,t);u=1/u,s*=u,o*=u,l*=u;let h=Math.sin(r),c=Math.cos(r),d=1-c,f=t[0],g=t[1],m=t[2],p=t[3],b=t[4],_=t[5],y=t[6],v=t[7],E=t[8],R=t[9],M=t[10],S=t[11],T=s*s*d+c,x=o*s*d+l*h,I=l*s*d-o*h,A=s*o*d-l*h,w=o*o*d+c,C=l*o*d+s*h,N=s*l*d+o*h,O=o*l*d-s*h,L=l*l*d+c;e[0]=f*T+b*x+E*I,e[1]=g*T+_*x+R*I,e[2]=m*T+y*x+M*I,e[3]=p*T+v*x+S*I,e[4]=f*A+b*w+E*C,e[5]=g*A+_*w+R*C,e[6]=m*A+y*w+M*C,e[7]=p*A+v*w+S*C,e[8]=f*N+b*O+E*L,e[9]=g*N+_*O+R*L,e[10]=m*N+y*O+M*L,e[11]=p*N+v*O+S*L,t!==e&&(e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15])}function m(e,t,r){let n=Math.sin(r),i=Math.cos(r),a=t[4],s=t[5],o=t[6],l=t[7],u=t[8],h=t[9],c=t[10],d=t[11];return t!==e&&(e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e[4]=a*i+u*n,e[5]=s*i+h*n,e[6]=o*i+c*n,e[7]=l*i+d*n,e[8]=u*i-a*n,e[9]=h*i-s*n,e[10]=c*i-o*n,e[11]=d*i-l*n,e}function p(e,t){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=t[0],e[13]=t[1],e[14]=t[2],e[15]=1,e}function b(e,t,r){if(0===t)return o(e);let n=r[0],a=r[1],s=r[2],l=Math.sqrt(n*n+a*a+s*s);if(l<=(0,i.FD)())return null;l=1/l,n*=l,a*=l,s*=l;let u=Math.sin(t),h=Math.cos(t),c=1-h;return e[0]=n*n*c+h,e[1]=a*n*c+s*u,e[2]=s*n*c-a*u,e[3]=0,e[4]=n*a*c-s*u,e[5]=a*a*c+h,e[6]=s*a*c+n*u,e[7]=0,e[8]=n*s*c+a*u,e[9]=a*s*c-n*u,e[10]=s*s*c+h,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function _(e,t){let r=Math.sin(t),n=Math.cos(t);return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=n,e[6]=r,e[7]=0,e[8]=0,e[9]=-r,e[10]=n,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function y(e,t){let r=Math.sin(t),n=Math.cos(t);return e[0]=n,e[1]=r,e[2]=0,e[3]=0,e[4]=-r,e[5]=n,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function v(e,t,r){let n=t[0],i=t[1],a=t[2],s=t[3],o=n+n,l=i+i,u=a+a,h=n*o,c=n*l,d=n*u,f=i*l,g=i*u,m=a*u,p=s*o,b=s*l,_=s*u;return e[0]=1-(f+m),e[1]=c+_,e[2]=d-b,e[3]=0,e[4]=c-_,e[5]=1-(h+m),e[6]=g+p,e[7]=0,e[8]=d+b,e[9]=g-p,e[10]=1-(h+f),e[11]=0,e[12]=r[0],e[13]=r[1],e[14]=r[2],e[15]=1,e}const E=(0,n.vt)();function R(e,t){return e[0]=t[12],e[1]=t[13],e[2]=t[14],e}function M(e,t){let r=t[0],n=t[1],i=t[2],a=t[4],s=t[5],o=t[6],l=t[8],u=t[9],h=t[10];return e[0]=Math.sqrt(r*r+n*n+i*i),e[1]=Math.sqrt(a*a+s*s+o*o),e[2]=Math.sqrt(l*l+u*u+h*h),e}function S(e,t){let r=t[0]+t[5]+t[10],n=0;return r>0?(n=2*Math.sqrt(r+1),e[3]=.25*n,e[0]=(t[6]-t[9])/n,e[1]=(t[8]-t[2])/n,e[2]=(t[1]-t[4])/n):t[0]>t[5]&&t[0]>t[10]?(n=2*Math.sqrt(1+t[0]-t[5]-t[10]),e[3]=(t[6]-t[9])/n,e[0]=.25*n,e[1]=(t[1]+t[4])/n,e[2]=(t[8]+t[2])/n):t[5]>t[10]?(n=2*Math.sqrt(1+t[5]-t[0]-t[10]),e[3]=(t[8]-t[2])/n,e[0]=(t[1]+t[4])/n,e[1]=.25*n,e[2]=(t[6]+t[9])/n):(n=2*Math.sqrt(1+t[10]-t[0]-t[5]),e[3]=(t[1]-t[4])/n,e[0]=(t[8]+t[2])/n,e[1]=(t[6]+t[9])/n,e[2]=.25*n),e}function T(e,t,r,n){let i=t[0],a=t[1],s=t[2],o=t[3],l=i+i,u=a+a,h=s+s,c=i*l,d=i*u,f=i*h,g=a*u,m=a*h,p=s*h,b=o*l,_=o*u,y=o*h,v=n[0],E=n[1],R=n[2];return e[0]=(1-(g+p))*v,e[1]=(d+y)*v,e[2]=(f-_)*v,e[3]=0,e[4]=(d-y)*E,e[5]=(1-(c+p))*E,e[6]=(m+b)*E,e[7]=0,e[8]=(f+_)*R,e[9]=(m-b)*R,e[10]=(1-(c+g))*R,e[11]=0,e[12]=r[0],e[13]=r[1],e[14]=r[2],e[15]=1,e}function x(e,t,r,n,i){let a=t[0],s=t[1],o=t[2],l=t[3],u=a+a,h=s+s,c=o+o,d=a*u,f=a*h,g=a*c,m=s*h,p=s*c,b=o*c,_=l*u,y=l*h,v=l*c,E=n[0],R=n[1],M=n[2],S=i[0],T=i[1],x=i[2],I=(1-(m+b))*E,A=(f+v)*E,w=(g-y)*E,C=(f-v)*R,N=(1-(d+b))*R,O=(p+_)*R,L=(g+y)*M,P=(p-_)*M,D=(1-(d+m))*M;return e[0]=I,e[1]=A,e[2]=w,e[3]=0,e[4]=C,e[5]=N,e[6]=O,e[7]=0,e[8]=L,e[9]=P,e[10]=D,e[11]=0,e[12]=r[0]+S-(I*S+C*T+L*x),e[13]=r[1]+T-(A*S+N*T+P*x),e[14]=r[2]+x-(w*S+O*T+D*x),e[15]=1,e}function I(e,t,r,n,i,a,s){let o=1/(r-t),l=1/(i-n),u=1/(a-s);return e[0]=2*a*o,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=2*a*l,e[6]=0,e[7]=0,e[8]=(r+t)*o,e[9]=(i+n)*l,e[10]=(s+a)*u,e[11]=-1,e[12]=0,e[13]=0,e[14]=s*a*2*u,e[15]=0,e}function A(e,t,r,n){let a=t[0],s=t[1],l=t[2],u=a-r[0],h=s-r[1],c=l-r[2],d=(0,i.FD)();if(Math.abs(u)<d&&Math.abs(h)<d&&Math.abs(c)<d)return void o(e);let f=1/Math.sqrt(u*u+h*h+c*c);u*=f,h*=f,c*=f;let g=n[0],m=n[1],p=n[2],b=m*c-p*h,_=p*u-g*c,y=g*h-m*u;f=Math.sqrt(b*b+_*_+y*y),f?(f=1/f,b*=f,_*=f,y*=f):(b=0,_=0,y=0);let v=h*y-c*_,E=c*b-u*y,R=u*_-h*b;f=Math.sqrt(v*v+E*E+R*R),f?(f=1/f,v*=f,E*=f,R*=f):(v=0,E=0,R=0),e[0]=b,e[1]=v,e[2]=u,e[3]=0,e[4]=_,e[5]=E,e[6]=h,e[7]=0,e[8]=y,e[9]=R,e[10]=c,e[11]=0,e[12]=-(b*a+_*s+y*l),e[13]=-(v*a+E*s+R*l),e[14]=-(u*a+h*s+c*l),e[15]=1}function w(e,t,r){return e[0]=t[0]-r[0],e[1]=t[1]-r[1],e[2]=t[2]-r[2],e[3]=t[3]-r[3],e[4]=t[4]-r[4],e[5]=t[5]-r[5],e[6]=t[6]-r[6],e[7]=t[7]-r[7],e[8]=t[8]-r[8],e[9]=t[9]-r[9],e[10]=t[10]-r[10],e[11]=t[11]-r[11],e[12]=t[12]-r[12],e[13]=t[13]-r[13],e[14]=t[14]-r[14],e[15]=t[15]-r[15],e}function C(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]&&e[3]===t[3]&&e[4]===t[4]&&e[5]===t[5]&&e[6]===t[6]&&e[7]===t[7]&&e[8]===t[8]&&e[9]===t[9]&&e[10]===t[10]&&e[11]===t[11]&&e[12]===t[12]&&e[13]===t[13]&&e[14]===t[14]&&e[15]===t[15]}function N(e){let t=(0,i.FD)(),r=e[0],n=e[1],a=e[2],s=e[4],o=e[5],l=e[6],u=e[8],h=e[9],c=e[10];return Math.abs(1-(r*r+s*s+u*u))<=t&&Math.abs(1-(n*n+o*o+h*h))<=t&&Math.abs(1-(a*a+l*l+c*c))<=t}function O(e){return 1===e[0]&&0===e[1]&&0===e[2]&&0===e[4]&&1===e[5]&&0===e[6]&&0===e[8]&&0===e[9]&&1===e[10]}const L=c,P=w;Object.freeze(Object.defineProperty({__proto__:null,add:function(e,t,r){return e[0]=t[0]+r[0],e[1]=t[1]+r[1],e[2]=t[2]+r[2],e[3]=t[3]+r[3],e[4]=t[4]+r[4],e[5]=t[5]+r[5],e[6]=t[6]+r[6],e[7]=t[7]+r[7],e[8]=t[8]+r[8],e[9]=t[9]+r[9],e[10]=t[10]+r[10],e[11]=t[11]+r[11],e[12]=t[12]+r[12],e[13]=t[13]+r[13],e[14]=t[14]+r[14],e[15]=t[15]+r[15],e},adjoint:function(e,t){let r=t[0],n=t[1],i=t[2],a=t[3],s=t[4],o=t[5],l=t[6],u=t[7],h=t[8],c=t[9],d=t[10],f=t[11],g=t[12],m=t[13],p=t[14],b=t[15];return e[0]=o*(d*b-f*p)-c*(l*b-u*p)+m*(l*f-u*d),e[1]=-(n*(d*b-f*p)-c*(i*b-a*p)+m*(i*f-a*d)),e[2]=n*(l*b-u*p)-o*(i*b-a*p)+m*(i*u-a*l),e[3]=-(n*(l*f-u*d)-o*(i*f-a*d)+c*(i*u-a*l)),e[4]=-(s*(d*b-f*p)-h*(l*b-u*p)+g*(l*f-u*d)),e[5]=r*(d*b-f*p)-h*(i*b-a*p)+g*(i*f-a*d),e[6]=-(r*(l*b-u*p)-s*(i*b-a*p)+g*(i*u-a*l)),e[7]=r*(l*f-u*d)-s*(i*f-a*d)+h*(i*u-a*l),e[8]=s*(c*b-f*m)-h*(o*b-u*m)+g*(o*f-u*c),e[9]=-(r*(c*b-f*m)-h*(n*b-a*m)+g*(n*f-a*c)),e[10]=r*(o*b-u*m)-s*(n*b-a*m)+g*(n*u-a*o),e[11]=-(r*(o*f-u*c)-s*(n*f-a*c)+h*(n*u-a*o)),e[12]=-(s*(c*p-d*m)-h*(o*p-l*m)+g*(o*d-l*c)),e[13]=r*(c*p-d*m)-h*(n*p-i*m)+g*(n*d-i*c),e[14]=-(r*(o*p-l*m)-s*(n*p-i*m)+g*(n*l-i*o)),e[15]=r*(o*d-l*c)-s*(n*d-i*c)+h*(n*l-i*o),e},copy:a,determinant:function(e){let t=e[0],r=e[1],n=e[2],i=e[3],a=e[4],s=e[5],o=e[6],l=e[7],u=e[8],h=e[9],c=e[10],d=e[11],f=e[12],g=e[13],m=e[14],p=e[15];return(t*s-r*a)*(c*p-d*m)-(t*o-n*a)*(h*p-d*g)+(t*l-i*a)*(h*m-c*g)+(r*o-n*s)*(u*p-d*f)-(r*l-i*s)*(u*m-c*f)+(n*l-i*o)*(u*g-h*f)},equals:function(e,t){if(e===t)return!0;let r=e[0],n=e[1],a=e[2],s=e[3],o=e[4],l=e[5],u=e[6],h=e[7],c=e[8],d=e[9],f=e[10],g=e[11],m=e[12],p=e[13],b=e[14],_=e[15],y=t[0],v=t[1],E=t[2],R=t[3],M=t[4],S=t[5],T=t[6],x=t[7],I=t[8],A=t[9],w=t[10],C=t[11],N=t[12],O=t[13],L=t[14],P=t[15],D=(0,i.FD)();return Math.abs(r-y)<=D*Math.max(1,Math.abs(r),Math.abs(y))&&Math.abs(n-v)<=D*Math.max(1,Math.abs(n),Math.abs(v))&&Math.abs(a-E)<=D*Math.max(1,Math.abs(a),Math.abs(E))&&Math.abs(s-R)<=D*Math.max(1,Math.abs(s),Math.abs(R))&&Math.abs(o-M)<=D*Math.max(1,Math.abs(o),Math.abs(M))&&Math.abs(l-S)<=D*Math.max(1,Math.abs(l),Math.abs(S))&&Math.abs(u-T)<=D*Math.max(1,Math.abs(u),Math.abs(T))&&Math.abs(h-x)<=D*Math.max(1,Math.abs(h),Math.abs(x))&&Math.abs(c-I)<=D*Math.max(1,Math.abs(c),Math.abs(I))&&Math.abs(d-A)<=D*Math.max(1,Math.abs(d),Math.abs(A))&&Math.abs(f-w)<=D*Math.max(1,Math.abs(f),Math.abs(w))&&Math.abs(g-C)<=D*Math.max(1,Math.abs(g),Math.abs(C))&&Math.abs(m-N)<=D*Math.max(1,Math.abs(m),Math.abs(N))&&Math.abs(p-O)<=D*Math.max(1,Math.abs(p),Math.abs(O))&&Math.abs(b-L)<=D*Math.max(1,Math.abs(b),Math.abs(L))&&Math.abs(_-P)<=D*Math.max(1,Math.abs(_),Math.abs(P))},exactEquals:C,frob:function(e){return Math.sqrt(e[0]**2+e[1]**2+e[2]**2+e[3]**2+e[4]**2+e[5]**2+e[6]**2+e[7]**2+e[8]**2+e[9]**2+e[10]**2+e[11]**2+e[12]**2+e[13]**2+e[14]**2+e[15]**2)},fromQuat:function(e,t){let r=t[0],n=t[1],i=t[2],a=t[3],s=r+r,o=n+n,l=i+i,u=r*s,h=n*s,c=n*o,d=i*s,f=i*o,g=i*l,m=a*s,p=a*o,b=a*l;return e[0]=1-c-g,e[1]=h+b,e[2]=d-p,e[3]=0,e[4]=h-b,e[5]=1-u-g,e[6]=f+m,e[7]=0,e[8]=d+p,e[9]=f-m,e[10]=1-u-c,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},fromQuat2:function(e,t){let r=E,n=-t[0],i=-t[1],a=-t[2],s=t[3],o=t[4],l=t[5],u=t[6],h=t[7],c=n*n+i*i+a*a+s*s;return c>0?(r[0]=2*(o*s+h*n+l*a-u*i)/c,r[1]=2*(l*s+h*i+u*n-o*a)/c,r[2]=2*(u*s+h*a+o*i-l*n)/c):(r[0]=2*(o*s+h*n+l*a-u*i),r[1]=2*(l*s+h*i+u*n-o*a),r[2]=2*(u*s+h*a+o*i-l*n)),v(e,t,r),e},fromRotation:b,fromRotationTranslation:v,fromRotationTranslationScale:T,fromRotationTranslationScaleOrigin:x,fromScaling:function(e,t){return e[0]=t[0],e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=t[1],e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=t[2],e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},fromTranslation:p,fromXRotation:_,fromYRotation:function(e,t){let r=Math.sin(t),n=Math.cos(t);return e[0]=n,e[1]=0,e[2]=-r,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=r,e[9]=0,e[10]=n,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e},fromZRotation:y,frustum:I,getRotation:S,getScale:M,getTranslation:R,hasIdentityRotation:O,identity:o,invert:h,invertOrIdentity:u,isOrthoNormal:N,lookAt:A,mul:L,multiply:c,multiplyScalar:function(e,t,r){return e[0]=t[0]*r,e[1]=t[1]*r,e[2]=t[2]*r,e[3]=t[3]*r,e[4]=t[4]*r,e[5]=t[5]*r,e[6]=t[6]*r,e[7]=t[7]*r,e[8]=t[8]*r,e[9]=t[9]*r,e[10]=t[10]*r,e[11]=t[11]*r,e[12]=t[12]*r,e[13]=t[13]*r,e[14]=t[14]*r,e[15]=t[15]*r,e},multiplyScalarAndAdd:function(e,t,r,n){return e[0]=t[0]+r[0]*n,e[1]=t[1]+r[1]*n,e[2]=t[2]+r[2]*n,e[3]=t[3]+r[3]*n,e[4]=t[4]+r[4]*n,e[5]=t[5]+r[5]*n,e[6]=t[6]+r[6]*n,e[7]=t[7]+r[7]*n,e[8]=t[8]+r[8]*n,e[9]=t[9]+r[9]*n,e[10]=t[10]+r[10]*n,e[11]=t[11]+r[11]*n,e[12]=t[12]+r[12]*n,e[13]=t[13]+r[13]*n,e[14]=t[14]+r[14]*n,e[15]=t[15]+r[15]*n,e},ortho:function(e,t,r,n,i,a,s){let o=1/(t-r),l=1/(n-i),u=1/(a-s);return e[0]=-2*o,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=-2*l,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=2*u,e[11]=0,e[12]=(t+r)*o,e[13]=(i+n)*l,e[14]=(s+a)*u,e[15]=1,e},perspective:function(e,t,r,n,i){let a,s=1/Math.tan(t/2);return e[0]=s/r,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=s,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[11]=-1,e[12]=0,e[13]=0,e[15]=0,null!=i&&i!==1/0?(a=1/(n-i),e[10]=(i+n)*a,e[14]=2*i*n*a):(e[10]=-1,e[14]=-2*n),e},perspectiveFromFieldOfView:function(e,t,r,n){let i=Math.tan(t.upDegrees*Math.PI/180),a=Math.tan(t.downDegrees*Math.PI/180),s=Math.tan(t.leftDegrees*Math.PI/180),o=Math.tan(t.rightDegrees*Math.PI/180),l=2/(s+o),u=2/(i+a);return e[0]=l,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=u,e[6]=0,e[7]=0,e[8]=-(s-o)*l*.5,e[9]=(i-a)*u*.5,e[10]=n/(r-n),e[11]=-1,e[12]=0,e[13]=0,e[14]=n*r/(r-n),e[15]=0,e},rotate:g,rotateX:m,rotateY:function(e,t,r){let n=Math.sin(r),i=Math.cos(r),a=t[0],s=t[1],o=t[2],l=t[3],u=t[8],h=t[9],c=t[10],d=t[11];return t!==e&&(e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e[0]=a*i-u*n,e[1]=s*i-h*n,e[2]=o*i-c*n,e[3]=l*i-d*n,e[8]=a*n+u*i,e[9]=s*n+h*i,e[10]=o*n+c*i,e[11]=l*n+d*i,e},rotateZ:function(e,t,r){let n=Math.sin(r),i=Math.cos(r),a=t[0],s=t[1],o=t[2],l=t[3],u=t[4],h=t[5],c=t[6],d=t[7];return t!==e&&(e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e[0]=a*i+u*n,e[1]=s*i+h*n,e[2]=o*i+c*n,e[3]=l*i+d*n,e[4]=u*i-a*n,e[5]=h*i-s*n,e[6]=c*i-o*n,e[7]=d*i-l*n,e},scale:f,set:s,str:function(e){return"mat4("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+", "+e[4]+", "+e[5]+", "+e[6]+", "+e[7]+", "+e[8]+", "+e[9]+", "+e[10]+", "+e[11]+", "+e[12]+", "+e[13]+", "+e[14]+", "+e[15]+")"},sub:P,subtract:w,targetTo:function(e,t,r,n){let i=t[0],a=t[1],s=t[2],o=n[0],l=n[1],u=n[2],h=i-r[0],c=a-r[1],d=s-r[2],f=h*h+c*c+d*d;f>0&&(f=1/Math.sqrt(f),h*=f,c*=f,d*=f);let g=l*d-u*c,m=u*h-o*d,p=o*c-l*h;return f=g*g+m*m+p*p,f>0&&(f=1/Math.sqrt(f),g*=f,m*=f,p*=f),e[0]=g,e[1]=m,e[2]=p,e[3]=0,e[4]=c*p-d*m,e[5]=d*g-h*p,e[6]=h*m-c*g,e[7]=0,e[8]=h,e[9]=c,e[10]=d,e[11]=0,e[12]=i,e[13]=a,e[14]=s,e[15]=1,e},translate:d,transpose:l},Symbol.toStringTag,{value:"Module"}))},90629(e,t,r){r.d(t,{Lz:()=>s,PN:()=>o,cr:()=>l,gs:()=>h,r_:()=>c,tc:()=>u}),r(39829);const n=/^-?(\d+(\.\d+)?)\s*((px)|(pt))?$/i,i=o(1),a=s(1);function s(e){return e?e/72*96:0}function o(e){return e?72*e/96:0}function l(e){if("string"==typeof e){let t=e.match(n);if(t){let r=Number(t[1]),n=t[3]&&t[3].toLowerCase(),i=e.startsWith("-"),a="px"===n?o(r):r;return i?-a:a}return console.warn("screenUtils.toPt: input not recognized!"),null}return e}function u(e=0,t=0){return{x:e,y:t}}function h(e=0,t=0){return[e,t]}function c(e=0,t=0,r=0){return[e,t,r]}r.d(t,["L7",0,a,"ps",0,i])},4197(e,t,r){r.d(t,{Vj:()=>h,cj:()=>u,jh:()=>a,l5:()=>o,yH:()=>l});var n=r(34275),i=r(9093);function a(e){return e<=1024?Array(e).fill(0):new Float64Array(e)}function s(e){return((0,n.iu)(e)?e.byteLength/8:e.length)<=1024?Array.from(e):new Float64Array(e)}function o(e,t,r){return Array.isArray(e)?e.slice(t,t+r):e.subarray(t,t+r)}function l(e,t){if(0===t.length)return s(e);if(0===e.length)return s(t);let r=a(e.length+t.length);for(let t=0;t<e.length;++t)r[t]=e[t];for(let n=0;n<t.length;++n)r[e.length+n]=t[n];return r}function u(e){return[...e]}function h(e){let t=(0,i.vt)();for(let r=0;r<16;++r)t[r]=e[r];return t}},70328(e,t,r){r.d(t,{BI:()=>I,C:()=>s,DC:()=>d,Ej:()=>y,Ie:()=>T,Jt:()=>x,Lu:()=>E,Ne:()=>R,RF:()=>c,TF:()=>b,VL:()=>g,aI:()=>w,fA:()=>o,gE:()=>u,gX:()=>_,hZ:()=>S,iT:()=>f,is:()=>A,pg:()=>v,uJ:()=>p,vI:()=>M,vY:()=>l,vt:()=>a,w1:()=>h,yr:()=>m}),r(35522);var n=r(5443),i=(r(19419),r(4197));function a(e=N){return[e[0],e[1],e[2],e[3],e[4],e[5]]}function s(e,t){for(let r=0;r<6;r++)e[r]=t[r];return e}function o(e,t,r,n,i,s,o=a()){return o[0]=e,o[1]=t,o[2]=r,o[3]=n,o[4]=i,o[5]=s,o}function l(e,t=a()){return function(e,t,r,n=a()){return S(n,C),function(e,t,r=0,n=t.length/3){let i=e[0],a=e[1],s=e[2],o=e[3],l=e[4],u=e[5];for(let e=0;e<n;e++)i=Math.min(i,t[r+3*e]),a=Math.min(a,t[r+3*e+1]),s=Math.min(s,t[r+3*e+2]),o=Math.max(o,t[r+3*e]),l=Math.max(l,t[r+3*e+1]),u=Math.max(u,t[r+3*e+2]);e[0]=i,e[1]=a,e[2]=s,e[3]=o,e[4]=l,e[5]=u}(n,e,t,r),n}(e,0,e.length/3,t)}function u(e,t=(0,i.jh)(24)){let[r,n,a,s,o,l]=e;return t[0]=r,t[1]=n,t[2]=a,t[3]=r,t[4]=n,t[5]=l,t[6]=r,t[7]=o,t[8]=a,t[9]=r,t[10]=o,t[11]=l,t[12]=s,t[13]=n,t[14]=a,t[15]=s,t[16]=n,t[17]=l,t[18]=s,t[19]=o,t[20]=a,t[21]=s,t[22]=o,t[23]=l,t}function h(e,t){return isFinite(e[2])||isFinite(e[5])?new n.A({xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],zmin:e[2],zmax:e[5],spatialReference:t}):new n.A({xmin:e[0],xmax:e[3],ymin:e[1],ymax:e[4],spatialReference:t})}function c(e,t,r=e){r[0]=Math.min(e[0],t[0]),r[1]=Math.min(e[1],t[1]),r[2]=Math.min(e[2],t[2]),r[3]=Math.max(e[3],t[3]),r[4]=Math.max(e[4],t[4]),r[5]=Math.max(e[5],t[5])}function d(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[3]=Math.max(e[3],t[2]),e[4]=Math.max(e[4],t[3])}function f(e,[t,r,n]){!function(e,t,r,n){e[0]=Math.min(e[0],t),e[1]=Math.min(e[1],r),e[2]=Math.min(e[2],n),e[3]=Math.max(e[3],t),e[4]=Math.max(e[4],r),e[5]=Math.max(e[5],n)}(e,t,r,n)}function g(e){return e[0]>=e[3]?0:e[3]-e[0]}function m(e){return e[1]>=e[4]?0:e[4]-e[1]}function p(e){return e[2]>=e[5]?0:e[5]-e[2]}function b(e){let t=g(e),r=p(e),n=m(e);return t*t+r*r+n*n}function _(e,t=[0,0,0]){return t[0]=e[0]+g(e)/2,t[1]=e[1]+m(e)/2,t[2]=e[2]+p(e)/2,t}function y(e,t=[0,0,0]){return t[0]=g(e),t[1]=m(e),t[2]=p(e),t}function v(e,t){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t}function E(e,t){return t[0]=e[3],t[1]=e[4],t[2]=e[5],t}function R(e,t,r=e){return r[0]=t[0],r[1]=t[1],r[2]=t[2],r!==e&&(r[3]=e[3],r[4]=e[4],r[5]=e[5]),r}function M(e,t,r=e){return r[3]=t[0],r[4]=t[1],r[5]=t[2],r!==e&&(r[0]=e[0],r[1]=e[1],r[2]=e[2]),e}function S(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function T(e){return e?S(e,C):a(C)}function x(e,t){return e[0]=t[0],e[1]=t[1],e[2]=-1/0,e[3]=t[2],e[4]=t[3],e[5]=1/0,e}function I(e,t,r,n,i){return e[0]=t,e[1]=r,e[2]=-1/0,e[3]=n,e[4]=i,e[5]=1/0,e}function A(e){return 6===e.length}function w(e,t,r){if(null==e||null==t)return e===t;if(!A(e)||!A(t))return!1;if(r){for(let n=0;n<e.length;n++)if(!r(e[n],t[n]))return!1}else for(let r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}const C=[1/0,1/0,1/0,-1/0,-1/0,-1/0],N=[0,0,0,0,0,0];a(),r.d(t,["qv",0,C,"v_",0,N])},50498(e,t,r){var n=r(66552),i=r(5443),a=r(91075),s=r(48526),o=r(86738),l=r(39829),u=r(82799);const h=(0,n.O)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon"}),c=(0,n.O)()({esriGeometryPoint:"point",esriGeometryMultipoint:"multipoint",esriGeometryPolyline:"polyline",esriGeometryPolygon:"polygon",esriGeometryEnvelope:"extent",mesh:"mesh"}),d={base:a.A,key:"type",typeMap:{extent:i.A,multipoint:s.A,point:o.A,polyline:u.A,polygon:l.A}},f=new n.J({esriGeometryBezier3Curve:"cubic-bezier",esriGeometryCircularArc:"circular-arc",esriGeometryEllipticArc:"elliptic-arc"},{ignoreUnknown:!0});r.d(t,["Ye",0,c,"gy",0,h,"iI",0,f,"yR",0,d])},49013(e,t,r){r.r(t),r.d(t,{default:()=>pt});var n=r(32198),i=r(4576),a=r(60999),s=r(69540),o=r(49186),l=r(36563),u=r(44208),h=r(53966),c=r(25728),d=r(17676),f=r(36708),g=r(91429),m=r(87024),p=r(4146),b=r(52136),_=r(18768),y=r(69208),v=r(34287),E=r(8303),R=r(25036),M=r(58947),S=r(10873),T=r(10292),x=r(58083),I=r(9093),A=r(35522),w=r(51850),C=r(34727),N=r(37539),O=r(79258);function L(e,t,r,n){let i=n+t;if(i<n/2||r>i)return Number.MAX_VALUE;let a=Math.abs(D*e)+Math.asin(r/i);return a>=Math.PI/2?Number.MAX_VALUE:r/Math.cos(a)}const P=(0,w.vt)(),D=(0,C.kU)(1);var q=r(27993),F=(r(73941),r(16930)),U=r(98764),k=r(4341),Q=r(19419),G=r(11964),V=r(27921),j=r(71351),W=r(44280),Z=r(32114);const z=()=>h.A.getLogger("esri.views.3d.support.geometryUtils.boundedPlane");function B(e=ce){return{plane:(0,V.vt)(e.plane),origin:(0,w.o8)(e.origin),basis1:(0,w.o8)(e.basis1),basis2:(0,w.o8)(e.basis2)}}function $(e,t=B()){return H(e.origin,e.basis1,e.basis2,t)}function H(e,t,r,n=B()){return(0,A.C)(n.origin,e),(0,A.C)(n.basis1,t),(0,A.C)(n.basis2,r),Y(n),function(e,t){Math.abs((0,A.Om)(e.basis1,e.basis2)/((0,A.Bw)(e.basis1)*(0,A.Bw)(e.basis2)))>1e-6&&z().warn(t,"Provided basis vectors are not perpendicular"),Math.abs((0,A.Om)(e.basis1,se(e)))>1e-6&&z().warn(t,"Basis vectors and plane normal are not perpendicular"),Math.abs(-(0,A.Om)(se(e),e.origin)-e.plane[3])>1e-6&&z().warn(t,"Plane offset is not consistent with plane origin")}(n,"fromValues()"),n}function Y(e){(0,V.mR)(e.basis2,e.basis1,e.origin,e.plane)}function K(e,t,r){e!==r&&$(e,r);let n=(0,A.hs)(Z.rq.get(),se(e),t);return(0,A.WQ)(r.origin,r.origin,n),r.plane[3]-=t,r}function X(e,t=B()){let r=(e[2]-e[0])/2,n=(e[3]-e[1])/2;return(0,A.hZ)(t.origin,e[0]+r,e[1]+n,0),(0,A.hZ)(t.basis1,r,0,0),(0,A.hZ)(t.basis2,0,n,0),(0,V.fA)(0,0,1,0,t.plane),t}function J(e,t,r){return!!(0,V.Ui)(e.plane,t,r)&&oe(e,r)}function ee(e,t,r){let n=de.get();he(e,t,n,de.get());let i=1/0;for(let a of pe){let s=ue(e,a,fe.get()),o=Z.rq.get();if((0,V.T7)(n,s,o)){let e=(0,A.oW)(Z.rq.get(),t.origin,o),n=Math.abs((0,C.XM)((0,A.Om)(t.direction,e)));n<i&&(i=n,(0,A.C)(r,o))}}return i===1/0?te(e,t,r):r}function te(e,t,r){if(J(e,t,r))return r;let n=de.get(),i=de.get();he(e,t,n,i);let a=1/0;for(let s of pe){let o=ue(e,s,fe.get()),l=Z.rq.get();if((0,V.gv)(n,o,l)){let e=(0,j.kb)(t,l);if(!(0,V.BX)(i,l))continue;e<a&&(a=e,(0,A.C)(r,l))}}return ie(e,t.origin)<a&&re(e,t.origin,r),r}function re(e,t,r){let n=(0,V._I)(e.plane,t,Z.rq.get()),i=(0,G.H6)(le(e,e.basis1),n,-1,1,Z.rq.get()),a=(0,G.H6)(le(e,e.basis2),n,-1,1,Z.rq.get());return(0,A.Re)(r,(0,A.WQ)(Z.rq.get(),i,a),e.origin),r}function ne(e,t,r){let{origin:n,basis1:i,basis2:a}=e,s=(0,A.Re)(Z.rq.get(),t,n),o=(0,W.gr)(i,s),l=(0,W.gr)(a,s),u=(0,W.gr)(se(e),s);return(0,A.hZ)(r,o,l,u)}function ie(e,t){let r=ne(e,t,Z.rq.get()),{basis1:n,basis2:i}=e,a=(0,A.Bw)(n),s=(0,A.Bw)(i),o=Math.max(Math.abs(r[0])-a,0),l=Math.max(Math.abs(r[1])-s,0),u=r[2];return o*o+l*l+u*u}function ae(e,t){let r=-e.plane[3];return(0,W.gr)(se(e),t)-r}function se(e){return(0,V.Qj)(e.plane)}function oe(e,t){let r=(0,A.Re)(Z.rq.get(),t,e.origin),n=(0,A.m3)(e.basis1),i=(0,A.m3)(e.basis2),a=(0,A.Om)(e.basis1,r),s=(0,A.Om)(e.basis2,r);return-a-n<0&&a-n<0&&-s-i<0&&s-i<0}function le(e,t){let r=fe.get();return(0,A.C)(r.origin,e.origin),(0,A.C)(r.vector,t),r}function ue(e,t,r){let{basis1:n,basis2:i,origin:a}=e,s=(0,A.hs)(Z.rq.get(),n,t.origin[0]),o=(0,A.hs)(Z.rq.get(),i,t.origin[1]);(0,A.WQ)(r.origin,s,o),(0,A.WQ)(r.origin,r.origin,a);let l=(0,A.hs)(Z.rq.get(),n,t.direction[0]),u=(0,A.hs)(Z.rq.get(),i,t.direction[1]);return(0,A.hs)(r.vector,(0,A.WQ)(l,l,u),2),r}function he(e,t,r,n){let i=se(e);(0,V.mR)(i,t.direction,t.origin,r),(0,V.mR)((0,V.Qj)(r),i,t.origin,n)}const ce={plane:(0,V.vt)(),origin:(0,w.fA)(0,0,0),basis1:(0,w.fA)(1,0,0),basis2:(0,w.fA)(0,1,0)},de=new k.I(V.vt),fe=new k.I(G.vt),ge=(0,w.vt)(),me=new k.I(()=>B()),pe=[{origin:[-1,-1],direction:[1,0]},{origin:[1,-1],direction:[0,1]},{origin:[1,1],direction:[-1,0]},{origin:[-1,1],direction:[0,-1]}],be=(0,I.vt)(),_e=(0,I.vt)();Object.freeze(Object.defineProperty({__proto__:null,altitudeAt:ae,axisAt:function(e,t,r,n){return function(e,t,r){switch(t){case 0:(0,A.C)(r,e.basis1),(0,A.S8)(r,r);break;case 1:(0,A.C)(r,e.basis2),(0,A.S8)(r,r);break;case 2:(0,A.C)(r,se(e))}return r}(e,r,n)},cameraFrustumCoverage:function(e,t){return(t-e)/t},closestPoint:te,closestPointOnSilhouette:ee,copy:$,copyWithoutVerify:function(e,t){(0,A.C)(t.origin,e.origin),(0,A.C)(t.basis1,e.basis1),(0,A.C)(t.basis2,e.basis2),(0,V.C)(t.plane,e.plane)},create:B,distance:function(e,t){return Math.sqrt(ie(e,t))},distance2:ie,distanceToSilhouette:function(e,t){let r=-1/0;for(let n of pe){let i=ue(e,n,fe.get()),a=(0,G.kb)(i,t);a>r&&(r=a)}return Math.sqrt(r)},elevate:K,equals:function(e,t){return e===t||null==e&&null==t||null!=e&&null!=t&&(0,A.t2)(e.basis1,t.basis1)&&(0,A.t2)(e.basis2,t.basis2)&&(0,A.t2)(e.origin,t.origin)},extrusionContainsPoint:function(e,t){return(0,V.mN)(e.plane,t)>0&&oe(e,t)},fromAABoundingRect:X,fromValues:H,getExtent:function(e,t){let r=e.basis1[0],n=e.basis2[1],[i,a]=e.origin;return(0,Q.fA)(i-r,a-n,i+r,a+n,t)},intersectRay:J,intersectRayClosestSilhouette:function(e,t,r){if(J(e,t,r))return r;let n=ee(e,t,Z.rq.get());return(0,A.WQ)(r,t.origin,(0,A.hs)(Z.rq.get(),t.direction,(0,A.Io)(t.origin,n)/(0,A.Bw)(t.direction))),r},normal:se,projectPoint:re,projectPointLocal:ne,rotate:function(e,t,r,n){return e!==n&&$(e,n),(0,x.$0)(_e,t,r),(0,A.Z0)(n.basis1,e.basis1,_e),(0,A.Z0)(n.basis2,e.basis2,_e),Y(n),n},setAltitudeAt:function(e,t,r,n){let i=ae(e,t),a=(0,A.hs)(ge,se(e),r-i);return(0,A.WQ)(n,t,a),n},setExtent:function(e,t,r){return X(t,r),K(r,ae(e,e.origin),r),r},transform:function(e,t,r){return e!==r&&$(e,r),(0,x.B8)(be,t),(0,x.mg)(be,be),(0,A.Z0)(r.basis1,e.basis1,be),(0,A.Z0)(r.basis2,e.basis2,be),(0,A.Z0)((0,V.Qj)(r.plane),(0,V.Qj)(e.plane),be),(0,A.Z0)(r.origin,e.origin,t),(0,V.mP)(r.plane,r.plane,r.origin),r},up:ce,updateUnboundedPlane:Y,wrap:function(e,t,r){let n=me.get();return n.origin=e,n.basis1=t,n.basis2=r,n.plane=(0,V.LV)(0,0,0,0),Y(n),n}},Symbol.toStringTag,{value:"Module"}));var ye=r(94008);(0,w.vt)(),(0,w.vt)();var ve=r(89707);class Ee extends ve.H{constructor(e,t){super(NaN,NaN),this.id=e,this.serviceMbsInIndexSR=t,this._serviceMbsInRenderSRElevationAdjusted=new ye.iy(0,0,0,-1),this._serviceMbsInRenderSR=new ye.iy(0,0,0,-1),this._serviceMbsElevationUpdateExtent=null,this._mbsConeInRenderSR=null}get serviceMbsInRenderSRElevationAdjusted(){return this._serviceMbsInRenderSRElevationAdjusted}updateServiceMbsInRenderSRElevationAdjusted(e){return this._serviceMbsInRenderSRElevationAdjusted.copyFrom(e),this._serviceMbsInRenderSRElevationAdjusted}get serviceMbsInRenderSR(){return this._serviceMbsInRenderSR}updateServiceMbsInRenderSR(e){return this._serviceMbsInRenderSR.copyFrom(e),null!=this._serviceMbsElevationUpdateExtent&&(0,Q.Ie)(this._serviceMbsElevationUpdateExtent),this._serviceMbsInRenderSR}get serviceMbsElevationUpdateExtent(){return this._serviceMbsElevationUpdateExtent??=(0,Q.Ie)()}get mbsConeInRenderSR(){return this._mbsConeInRenderSR}updateMbsConeInRenderSR(e){return this._mbsConeInRenderSR=e.clone(),this._mbsConeInRenderSR}invalidateServiceBVsInRenderSR(){this._serviceMbsInRenderSRElevationAdjusted.invalidate(),this._serviceMbsInRenderSR.invalidate(),null!=this._serviceMbsElevationUpdateExtent&&(0,Q.Ie)(this._serviceMbsElevationUpdateExtent),this._mbsConeInRenderSR=null,this.serviceObbInRenderSR?.invalidate()}shareServiceBVsInRenderSRWith(e){this.serviceObbInRenderSR=e.serviceObbInRenderSR,this._serviceMbsInRenderSRElevationAdjusted=e._serviceMbsInRenderSRElevationAdjusted,this._serviceMbsInRenderSR=e._serviceMbsInRenderSR,this._serviceMbsElevationUpdateExtent=e._serviceMbsElevationUpdateExtent??=(0,Q.Ie)(),this._mbsConeInRenderSR=e._mbsConeInRenderSR}}class Re extends Ee{constructor(e,t,r,n,i,a,s,o,l,u,h){super(e,r),this.index=t,this.childCount=n,this.level=i,this.resources=a,this.version=s,this.lodMetric=o,this.maxError=l,this.numFeatures=u,this.failed=!1,this.cacheState=0,this.vertexCount=0,this.memory=0,this.childrenLoaded=0,this.hasModifications=!1,this.imModificationImpact=4,this.elevationAgnosticBoundingVolume=new Me,this.serviceObbInIndexSR=h}invalidateServiceBVsInRenderSR(){super.invalidateServiceBVsInRenderSR(),this.elevationAgnosticBoundingVolume.invalidate()}}class Me{constructor(){this._data=[0,0,0,Me.invalidRadius]}static{this.invalidRadius=-2}invalidate(){this._data[3]=Me.invalidRadius}get valid(){return this._data[3]!==Me.invalidRadius}get radius(){return this._data[3]}getAxis(e){return e[0]=this._data[0],e[1]=this._data[1],e[2]=this._data[2],e}set(e,t){this._data[0]=e[0],this._data[1]=e[1],this._data[2]=e[2],this._data[3]=t}intersectsFrustumConservative(e,t,r){if(!this.valid)return!0;let n=this.getAxis(Se),{center:i,radius:a}=e.boundingSphere,s=a+r;return 1===t?this.radius>Te||function(e,t,r,n){let i=(0,A.Bw)(r);if(i<=n)return!0;let a=(0,A.Om)(e,r);if(a<=0)return-a<=n;let s=(0,C.qE)(a/i,-1,1),o=Math.sqrt(1-s*s),l=(0,C.qE)(n/i,0,1);return o*Math.sqrt(1-l*l)-l*s<=t}(n,this.radius,i,s):function(e,t,r,n){let i=r[0]-e[0],a=r[1]-e[1],s=t+n;return i*i+a*a<=s*s}(n,this.radius,i,s)&&function(e,t,r,n,i){for(let a of i){let i=a[0],s=a[1],o=a[2],l=o>0?r:n;if(i*e[0]+s*e[1]+o*l+a[3]-Math.hypot(i,s)*t>0)return!1}return!0}(n,this.radius,i[2]-s,i[2]+s,e.planes)}}const Se=(0,w.vt)(),Te=.9;var xe=r(25992),Ie=r(66480),Ae=r(57005),we=r(4431),Ce=r(62747),Ne=r(58682),Oe=r(92359);class Le{constructor(e,t,r){this._layer=e,this._descriptor=t,this._options=r,this._subtaskAbortController=new AbortController,this._highest=-1/0,this._signal=AbortSignal.any([r.signal,this._subtaskAbortController.signal]),this._indexSpatialReference=(0,Ie.Rm)(e),this._vertexSpatialReference=(0,Ie.Dd)(e),this._intersectionSpaceSpatialReference=function(e,t){return e?(0,U.lO)(t):t.isGeographic?F.A.PlateCarree:t}(this._indexSpatialReference.isGeographic,this._indexSpatialReference),this._indexToVertexProjector=(0,N.wy)(this._indexSpatialReference,this._vertexSpatialReference),this._vertexToIntersectionSpaceProjector=(0,N.wy)(this._vertexSpatialReference,this._intersectionSpaceSpatialReference),this.frameTask=r.scheduler.registerTask(Oe.W6.ELEVATION_QUERY),this.promise=this._run()}async _run(){let e={stack:[],error:void 0,hasError:!1};try{(0,n.mS)(e,this.frameTask,!1);try{let e=this._descriptor;if("point"!==e.geometry.type)throw new o.A("elevation-query:invalid-geometry","Only point geometries can be used to query elevation");if(null==this._indexToVertexProjector||null==this._vertexToIntersectionSpaceProjector)throw new o.A("integrated-mesh-elevation-query:projection","Failed to create projection for elevation query.");let t=await e.project(this._indexSpatialReference,this._signal);(0,d.Te)(this._signal),t??this._throwSpatialReferenceMismatchError();let r=t.coordinates[0],n=function(e,t,r,n,i){let a=(0,w.fA)(e,t,r),s=(0,w.fA)(e,t,r-1e3),o=(0,w.vt)(),l=(0,w.vt)();return(0,q.F)(a,n,o,i)&&(0,q.F)(s,n,l,i)?(0,j.Cr)(o,l):null}(r.x,r.y,this.getRootRayOriginZ(),this._indexSpatialReference,this._intersectionSpaceSpatialReference);return n??this._throwSpatialReferenceMismatchError(),this._queryRay=n,await this.visitRoot(),(0,d.Te)(this._signal),r.z=this._highest===-1/0?qe:this._highest,t}catch(e){throw this._subtaskAbortController.abort(),e}}catch(t){e.error=t,e.hasError=!0}finally{(0,n.hk)(e)}}_throwSpatialReferenceMismatchError(){throw new o.A("elevation-query:spatial-reference-mismatch",`Cannot query elevation in '${this._descriptor.spatialReference.wkid}' on an elevation service in '${this._indexSpatialReference.wkid}'`)}_intersectsQueryObb(e){let t=this._queryRay,r=new Ae.ab;return e.transform(r,this._indexSpatialReference,this._intersectionSpaceSpatialReference),r.intersectRay(t.origin,t.direction)}intersectsQueryBounds(e){if(null==e)return!0;let t=this._queryRay;if(null!=e.obb)return this._intersectsQueryObb(Ae.ab.fromJSON(e.obb));let r=new ye.iy;return!function(e,t,r,n){if(null==e||null==t||null==n)return!1;let i=(0,N.Tp)(t,n);if(null==i?.projector)return!1;if(i.projector===N.pO)return r.copyFrom(e),!0;let{source:a,dest:s,projector:o}=i;if(3===s.spatialReferenceId){let t=N.w5[a.spatialReferenceId][2];return null!=t&&(t(e.center,0,P,0),(0,N.s7)(P,0,r.center,0),r.radius=L(P[1],e.center[2],e.radius,O.$O.radius),!0)}if(2!==a.spatialReferenceId&&5!==a.spatialReferenceId||11!==s.spatialReferenceId){o(e.center,0,r.center,0);let t=a.metersPerUnit??1,n=s.metersPerUnit??1;r.radius=e.radius*t/n}else{let t=N.w5[a.spatialReferenceId][1],n=N.w5[1][11],i=e.radius;null!=t&&null!=n&&(i=L(e.center[1],e.center[2],e.radius,O.$O.radius)),o(e.center,0,r.center,0),r.radius=i}return!0}(new ye.iy(e.mbs),this._indexSpatialReference,r,this._intersectionSpaceSpatialReference)||r.intersectRay(t)}async _processLeafNode(e){let t=await this._layer.elevationQueryNodeLoader.loadNodeData(e,this._signal);if((0,d.Te)(this._signal),null==t.geometryBuffer||null==t.geometryDescriptor)return;let r=await this.transformNode(e,t);(0,d.Te)(this._signal),null!=r&&await this.frameTask.schedule(()=>{this._highest=this.intersectTransformedGeometry(r,this._highest,this._options.elevationOffset)},this._signal)}async transformNode(e,t){let r=e.serviceMbsInIndexSR;if(null==r)return null;let n=(0,xe.C)(r,0,Fe,this._indexSpatialReference,this._intersectionSpaceSpatialReference),i={context:`i3s-elevation-query-${this._layer.uid}`,geometryBuffer:t.geometryBuffer,geometryData:null,geometryDescriptor:t.geometryDescriptor,layouts:[Ue],globalTrafo:n,geometryElevationOffset:0,mbs:r.toJSON(),obbData:e.serviceObbInIndexSR?.data,elevationOffset:0,planetRadiusInGlobalMode:0,needNormals:!1,computeNormals:!1,normalReferenceFrame:Fe,indexToVertexProjector:this._indexToVertexProjector,vertexToRenderProjector:this._vertexToIntersectionSpaceProjector},a=await this._layer.processElevationQueryGeometry(i,this._signal);return(0,d.Te)(this._signal),a}intersectTransformedGeometry(e,t,r){let n=e.globalTrafo;if(null==(0,x.B8)(ke,n))return t;let i=this._queryRay,a=(0,A.Z0)(Qe,i.origin,ke),s=(0,A.WQ)(Ge,i.origin,i.direction),o=(0,A.Z0)(Ve,s,ke),l=(0,A.jb)(je,o,a),{data:u,indices:h}=e.transformedGeometry.positionData,c=h.length/3,d=t;return(0,Ne.h7)(a,l,0,c,h,u,3,!1,e=>{let t=(0,A.hs)(We,l,e);(0,A.WQ)(t,t,a);let i=(0,A.Z0)(Ze,t,n),s=ze;if((0,q.F)(i,this._intersectionSpaceSpatialReference,s,this._layer.spatialReference)){let e=s[2]+r;d=Math.max(d,e)}}),d}async requestJSON(e){let t=await this._layer.elevationQueryDataRequester.request(e,"json",this._signal);return(0,d.Te)(this._signal),t}}class Pe extends Le{constructor(e,t,r,n){super(e,t,r),this._pendingPages=new Map,this._loadedPages=new Map,this._pageSize=n.pageSize,this._rootIndex=n.rootIndex,this._urlPrefix=n.urlPrefix;let i=this._pageId(this._rootIndex),a=this._rootIndex-i*this._pageSize,s=Ae.ab.fromJSON(n.rootPage.nodes[a].obb);this._rootRayOriginZ=s.centerZ+s.radius+1,this._loadedPages.set(i,n.rootPage)}visitRoot(){return this._visitNode(this._rootIndex)}getRootRayOriginZ(){return this._rootRayOriginZ}_pageId(e){return Math.floor(e/this._pageSize)}getPage(e){let t=this._loadedPages.get(e);if(null!=t)return Promise.resolve(t);let r=this._pendingPages.get(e);if(null!=r)return r;let n=this.requestJSON(`${this._urlPrefix}${e}`);return this._pendingPages.set(e,n),n.then(t=>{this._loadedPages.set(e,t),this._pendingPages.delete(e)},()=>this._pendingPages.delete(e)),n}async _visitNode(e){let t=this._pageId(e),r=await this.getPage(t);(0,d.Te)(this._signal);let n=r.nodes[e-t*this._pageSize],i=Ae.ab.fromJSON(n.obb);if(!this._intersectsQueryObb(i))return;let{children:a}=n;if(null!=a&&a.length>0)return await Promise.all(a.map(e=>this._visitNode(e))),void(0,d.Te)(this._signal);let s=this._createNode(e,n,i);null!=s&&(await this._processLeafNode(s),(0,d.Te)(this._signal))}_createNode(e,t,r){let{mesh:n}=t;if(null==n?.geometry)return null;let i=new ye.iy(r.getCenter((0,w.vt)()),r.radius),{geometry:a,material:s}=n;return new Re(`${e}`,e,i,t.children?.length??0,0,{hasSharedResource:!1,isEmpty:!1,geometry:`${a.resource}`,geometryDefinition:a.definition,materialDefinition:s?.definition??-1},"",0,0,a.featureCount??null,r)}}class De extends Le{constructor(e,t,r,n){super(e,t,r),this._rootNode=n.rootNode,this._urlPrefix=n.urlPrefix}visitRoot(){return this.intersectsQueryBounds(this._rootNode)?this._visitNodeData(this._rootNode,null!=this._rootNode.obb):Promise.resolve()}getRootRayOriginZ(){return this._rootNode.mbs[2]+this._rootNode.mbs[3]+1}_visitNode(e){return this.intersectsQueryBounds(e)?this._visitNodeAsync(e):Promise.resolve()}async _visitNodeAsync(e){let t=await this.requestJSON(`${this._urlPrefix}${e.id}`);(0,d.Te)(this._signal),await this._visitNodeData(t,null!=e.obb),(0,d.Te)(this._signal)}async _visitNodeData(e,t){if(!t&&null!=e.obb&&!this._intersectsQueryObb(Ae.ab.fromJSON(e.obb)))return;let{children:r}=e;if(null!=r&&r.length>0)return await Promise.all(r.map(e=>this._visitNode(e))),void(0,d.Te)(this._signal);let n=this._createNode(e);null!=n&&(await this._processLeafNode(n),(0,d.Te)(this._signal))}_createNode(e){let{geometryData:t,id:r}=e;if(null==t||0===t.length)return null;let n=null==e.obb?null:Ae.ab.fromJSON(e.obb),i=new ye.iy(e.mbs);return new Re(r,0,i,e.children?.length??0,0,{hasSharedResource:null!=e.sharedResource,isEmpty:!1,geometry:r,geometryDefinition:0},e.version??"",0,0,null,n)}}const qe=Number.MAX_VALUE,Fe="none",Ue=(0,we.U)((0,Ce.hH)(new Ce.W7(!1,!1,0))),ke=(0,I.vt)(),Qe=(0,w.vt)(),Ge=(0,w.vt)(),Ve=(0,w.vt)(),je=(0,w.vt)(),We=(0,w.vt)(),Ze=(0,w.vt)(),ze=(0,w.vt)();var Be=r(50805),$e=r(58325),He=r(24212),Ye=r(80215),Ke=r(97159),Xe=r(16215),Je=r(98697),et=r(56507),tt=r(97768),rt=r(50075);class nt{constructor(e,t){this._customParameters=e,this._apiKey=t,this._activeRequests=new Set}isFull(e){return(0,rt._i)(e)}request(e,t,r){let n=new AbortController,i=(0,d.NY)(r,()=>n.abort()),a={...rt.Fz,signal:n.signal,responseType:t,query:{...this._customParameters,token:this._apiKey}},s=(0,et.A)(e,a),o={abortController:n,abortHandle:i};return this._activeRequests.add(o),s.then(({data:e})=>e).finally(()=>{o.abortController=null,o.abortHandle=(0,tt.xt)(o.abortHandle),this._activeRequests.delete(o)})}cancelAll(){this._activeRequests.forEach(e=>{e.abortController=(0,tt.DC)(e.abortController),e.abortHandle=(0,tt.xt)(e.abortHandle)}),this._activeRequests.clear()}}var it=r(4718),at=r(84952),st=r(59418),ot=r(85334);r(91829),r(76200);var lt=r(74810),ut=r(49788);function ht(e){return e.sort((e,t)=>e.encoding-t.encoding)}const ct={ktx2:1,basis:2,dds:4,png:8,jpg:16,"ktx-etc2":32},dt={"image/ktx2":2,"image/x.basis":2,"image/vnd-ms.dds":4,"image/png":8,"image/jpg":16,"image/jpeg":16,"image/ktx":32};class ft{constructor(e,t,r,n,i,a){if(this._requester=t,this._logger=r,this._defaultGeometrySchema=n,this._requiredAttributes=i,this._options=a,this._logLayer=e,this._layerUrl=e.parsedUrl.path,this._geometryDefinitions=e.geometryDefinitions,e.materialDefinitions){let t=e.textureSetDefinitions;this._materialAndTextures=e.materialDefinitions.map(r=>function(e,t,r){let n=new Map,i=(e,t)=>{if(null==e)return-1;let r=n.get(e.id);if(r)return r.usage|=t,r.id;let i=n.size;return n.set(e.id,{id:i,usage:t}),i},a=t.pbrMetallicRoughness,s=a?.baseColorFactor?(0,ot.sn)(a.baseColorFactor):null,o=t.emissiveFactor,l=r&&0===a?.metallicFactor||(0,lt.Jr)({normalTexture:t.normalTexture,emissiveTexture:t.emissiveTexture,emissiveFactor:t.emissiveFactor,occlusionTexture:t.occlusionTexture,metallicRoughnessTexture:a?.metallicRoughnessTexture,metallicFactor:a?.metallicFactor,roughnessFactor:a?.roughnessFactor}),u=l?lt.Bt[0]:a?.metallicFactor??lt.mb[0],h=l?lt.Bt[1]:a?.roughnessFactor??lt.mb[1],c="mask"===t.alphaMode?33:1,d={baseColorFactor:s?[s[0],s[1],s[2],s[3]]:[1,1,1,1],baseColorTextureId:i(a?.baseColorTexture,c),metallicRoughnessTextureId:i(a?.metallicRoughnessTexture,2),metallicFactor:u,roughnessFactor:h},f={alphaMode:t.alphaMode,alphaCutoff:t.alphaCutoff,doubleSided:t.doubleSided,cullFace:"none"===t.cullFace?0:"back"===t.cullFace?2:+("front"===t.cullFace),normalTextureId:i(t.normalTexture,4),emissiveTextureId:i(t.emissiveTexture,16),occlusionTextureId:i(t.occlusionTexture,8),emissiveFactor:o?[o[0],o[1],o[2]]:[0,0,0],metallicRoughness:d,wrapTextures:!1,hasParametersFromSource:l},g=[];return n.forEach(({usage:t},r)=>{let n=null!=e&&e[r]&&e[r].formats,i=n?ht(n.map(({name:e,format:t})=>({name:e,encoding:ct[t]}))):[];g.push({id:r,usage:t,encodings:i})}),{material:f,textures:g}}(t,r,"integrated-mesh"===e.type))}}_loadAttribute(e,t,r){let n=`${this._layerUrl}/nodes/${e.resources.attributes}/attributes/${t.key}/0`;return this._requester.request(n,"array-buffer",r).then(e=>(0,st.m0)(t,e))}async loadAttributes(e,t,r){let n=await Promise.allSettled(t.map(t=>this._loadAttribute(e,t.attributeStorageInfo,r))),i={};for(let r=0;r<t.length;++r){let a=n[r],s=t[r];if("fulfilled"===a.status){let e=a.value;i[s.name]=e}else{let t=a.reason;(0,d.QP)(t),this._logger.error("#loadAttributes",this._logLayer,`Failed to load attributeData for '${s.name}' on node '${e.id}'`,t)}}return i}async loadNodeData(e,t){let r=null!=this._requiredAttributes&&e.resources.attributes?(0,a.Ke)(this.loadAttributes(e,this._requiredAttributes,t)):null,{bufferDefinition:n,bufferIndex:i}=function(e,t){let r={bufferDefinition:null,bufferIndex:0},n=t.resources.geometryDefinition;if(null==e||null==n||n<0)return r;let i=n>=0?e[n].geometryBuffers:null;if(null==i)return r;for(let e=0;e<i.length;e++){let t=i[e];if(null!=t.compressedAttributes){if("draco"===t.compressedAttributes.encoding&&!(0,u.A)("disable-feature:i3s-draco"))return r.bufferIndex=e,r.bufferDefinition=t,r}else r.bufferIndex=e,r.bufferDefinition=i[e]}return r}(this._geometryDefinitions,e),s=!!e.resources.geometry,o=s?(0,a.Ke)(this._loadGeometry(e.resources.geometry,i,t)):null,l=e.resources.hasSharedResource?await this._loadShared(e,t):null,h=e.resources.materialDefinition,c=this._materialAndTextures&&null!=h&&h>=0?this._materialAndTextures[h]:null==l?null:function(e){let t=e?.materialDefinitions?Object.keys(e.materialDefinitions)[0]:null,r=e?.textureDefinitions?Object.keys(e.textureDefinitions)[0]:null,n=t?e.materialDefinitions?.[t]:null,i=r?e.textureDefinitions?.[r]:null,a={alphaMode:"opaque",alphaCutoff:ut.Q,doubleSided:!0,cullFace:0,normalTextureId:-1,emissiveTextureId:-1,occlusionTextureId:-1,emissiveFactor:[0,0,0],metallicRoughness:{baseColorFactor:[.8,.8,.8,1],baseColorTextureId:-1,metallicRoughnessTextureId:-1,metallicFactor:0,roughnessFactor:.6},wrapTextures:!1,hasParametersFromSource:!0};if(null!=n){let e=n.params;e.diffuse&&((0,ot.KV)(e.diffuse),a.metallicRoughness.baseColorFactor=[e.diffuse[0],e.diffuse[1],e.diffuse[2],1]),null!=e.doubleSided&&(a.doubleSided=e.doubleSided,a.cullFace=e.doubleSided?0:2),("none"===e.cullFace||"front"===e.cullFace||"back"===e.cullFace)&&(a.cullFace="none"===e.cullFace?0:"back"===e.cullFace?2:1),e.transparency&&(a.metallicRoughness.baseColorFactor[3]=(0,C.qE)(1-e.transparency,0,1)),(e.useVertexColorAlpha||a.metallicRoughness.baseColorFactor[3]<1)&&(a.alphaMode="blend")}let s=[];if(null!=i){i.wrap&&("repeat"===i.wrap[0]||"repeat"===i.wrap[1])&&(a.wrapTextures=!0);let e=1;"rgba"===i.channels&&(a.alphaMode="blend",e|=32);let t=i.images.length-1,r=i.images[t],n=e=>e?.split("/").pop(),o=Array.isArray(i.encoding)?ht(i.encoding.map((e,t)=>({name:n(r.href[t]),encoding:dt[e]||0}))):[{name:n(r.href),encoding:dt[i.encoding]||0}];s.push({id:0,usage:e,encodings:o}),a.metallicRoughness.baseColorTextureId=0}return{material:a,textures:s}}(l),d=c?.material,f=c?.textures??[],g=`${e.id}`,m=!s&&this._options.loadFeatureData,p=m?await this._loadFeatureData(g,t):null,b=m?function(e){if(!e)return null;for(let t of e.featureData){let e=t.geometries;if(null!=e)for(let r of e)return{featureIds:[t.id],featureDataPosition:t.position,geometries:[r]}}return null}(p):{featureIds:[],geometries:[{type:"ArrayBufferView",params:{material:d}}],featureDataPosition:[0,0,0]},_=null==b?function(e){if(!e)return null;let t=[];for(let r of e.featureData)null!=r.position&&t.push({featureIds:[r.id],featureDataPosition:r.position,geometries:[]});return t}(p):null,y=f.length>0?(0,a.Ke)(this.loadTextures(e,f,t)):null,v=null,E=null;if(o){v=(0,a.QA)(await o);let e=function(e,t){if(!e||!t?.materialDefinitions)return e;let r=Object.keys(t.materialDefinitions)[0];return!t.materialDefinitions[r].params.vertexRegions&&e.vertexAttributes.region&&delete(e=(0,it.o8)(e)).vertexAttributes.region,e}(this._defaultGeometrySchema,l);E=(0,st.qs)(n,e)}let R=y?(0,a.QA)(await y):null,M=r?(0,a.QA)(await r):{},S=M?{attributeData:M,loadedAttributes:this._requiredAttributes}:null;if(null!=b)return{geometryData:b,attributeDataInfo:S,geometryBuffer:v,geometryDescriptor:E,requiredTextures:f,textureData:R};if(null!=_)return{pointData:_,attributeDataInfo:S,geometryBuffer:v,geometryDescriptor:E,requiredTextures:f,textureData:R};throw Error()}static _addAbsoluteHrefTexture(e,t){let r=e.textureDefinitions;if(null!=r)for(let e of Object.keys(r))for(let n of r[e].images)n.hrefConcat=Array.isArray(n.href)?n.href.map(e=>(0,at.s2)(e,t)):(0,at.s2)(n.href,t)}static _fixTextureEncodings(e){let t=e.textureDefinitions;if(null!=t)for(let e in t){let r=t[e];if(Array.isArray(r.encoding))for(let e=0;e<r.encoding.length;e++){let t=r.encoding[e];t.startsWith("data:")&&(r.encoding[e]=t.slice(5))}else{let e=r.encoding;e.startsWith("data:")&&(r.encoding=e.slice(5))}}}async _loadShared(e,t){if(null==e.resources.geometry)return{};let r=`${this._layerUrl}/nodes/${e.resources.geometry}/shared`,n=await this._requester.request(r,"json",t);return ft._fixTextureEncodings(n),ft._addAbsoluteHrefTexture(n,r),n}_loadTexture(e,t,r,n,i){return 4===n||1===n||2===n?this._requester.request(e,"array-buffer",i).then(e=>({id:t,usage:r,data:e,encoding:n})):this._requester.request(e,"image",i).then(e=>({id:t,usage:r,data:e,encoding:n}))}loadTextures(e,t,r){let n=this._options.textureUsageMask;return Promise.all(t.map(t=>{if(0===(t.usage&n))return null;let i=function(e,t){if(null!=t)return e.find(e=>0!==(e.encoding&t))}(t.encodings,this._options.textureEncodings);if(null==i)return this._logger.error("#loadTextures",this._logLayer,`No known encoding for texture found on node ${e.id}`),Promise.reject();let a=e.resources.texture||e.id,s=`${this._layerUrl}/nodes/${a}/textures/${i.name}`;return this._loadTexture(s,t.id,t.usage,i.encoding,r)}))}_loadFeatureData(e,t){let r=`${this._layerUrl}/nodes/${e}/features/0`;return this._requester.request(r,"json",t)}_loadGeometry(e,t,r){let n=`${this._layerUrl}/nodes/${e}/geometries/${t}`;return this._requester.request(n,"array-buffer",r)}}var gt=r(36005);let mt=class extends((0,M.w6)((0,_.b)((0,v.q)((0,E.A)((0,R.j)((0,c.M)((0,y.d)((0,b.p)((0,s.OU)(p.A)))))))))){constructor(...e){super(...e),this.geometryType="mesh",this.operationalLayerType="IntegratedMeshLayer",this.type="integrated-mesh",this.nodePages=null,this.materialDefinitions=null,this.textureSetDefinitions=null,this.geometryDefinitions=null,this.serviceUpdateTimeStamp=null,this.profile="mesh-pyramids",this.modifications=null,this._modificationsSource=null,this.path=null,this.definitionExpression=null,this._elevationQueryAbortController=new AbortController,this._elevationQueryWorkerContext=`i3s-elevation-query-${this.uid}`,this._elevationQueryWorkerHandle=null,this._elevationQueryWorkerSetup=null,this._modificationsGeneration=0}destroy(){this._elevationQueryAbortController.abort();let e=this._elevationQueryWorkerHandle;this._elevationQueryWorkerHandle=null,this._elevationQueryWorkerSetup=null,e?.destroyContextAndSelf(this._elevationQueryWorkerContext),super.destroy()}initialize(){this.addHandles([(0,f.on)(()=>this.modifications,"after-changes",()=>{this.modifications=this.modifications,this._modificationsGeneration++},f.OH),(0,f.wB)(()=>this.modifications,()=>this._modificationsGeneration++,f.OH),(0,f.wB)(()=>this.memoizedElevationQueryDependencies,()=>this._abortElevationQueriesAfterDependencyChange(),f.OH)])}normalizeCtorArgs(e,t){return"string"==typeof e?{url:e,...t}:e}readModifications(e,t,r){this._modificationsSource={url:(0,Ke.f)(e,r),context:r}}set elevationInfo(e){(null==e||"absolute-height"===e.mode)&&this._set("elevationInfo",e),this._validateElevationInfo(e)}async load(e){return this.addResolvingPromise(this._doLoad(e)),this}get _elevationQueryWorker(){return this._elevationQueryWorkerHandle??=new Je.Cm((e,t)=>Oe.nu.schedule(e,t))}get memoizedElevationQueryDependencies(){return[this.elevationInfo?.offset,this._modificationsGeneration]}async queryElevation(e,t,r){let s={stack:[],error:void 0,hasError:!1};try{let u=r?.noDataValue??Number.MAX_VALUE,h=this._elevationQueryWorker,c=new AbortController;e.addHandles((0,l.rE)(c),c),(0,n.mS)(s,(0,l.Bf)((0,l.hA)(()=>e.removeHandles(c))),!1);let f=AbortSignal.any([r?.signal,this._elevationQueryAbortController.signal,c.signal].filter(i.Ru));await this.load({signal:f}),(0,d.Te)(f);let g=T.q.fromGeometry(t),m={signal:f,elevationOffset:this.elevationInfo?.offset??0,scheduler:e.resourceController.scheduler};if(null==this._elevationQueryWorkerSetup){let e=this.store?.defaultGeometrySchema;null!=e&&(this._elevationQueryWorkerSetup=(0,a.Ke)(h.setLegacySchema(this._elevationQueryWorkerContext,e)))}let p=await async function(e,t,r){let n=await e.indexInfo;if((0,d.Te)(r.signal),null==n)throw new o.A("integrated-mesh-elevation-query:index-missing","I3S index information is missing.");return"page"===n.type?new Pe(e,t,r,n).promise:new De(e,t,r,n).promise}(this,g,m);(0,d.Te)(f);let b=p.coordinates[0].z===qe;b&&(p.coordinates[0].z=u);let _=await p.project(t.spatialReference,f);(0,d.Te)(f);let y=_??g.clone(),v={geometry:y.export(),noDataValue:u};return r?.returnSampleInfo&&(v.sampleInfo=y.coordinates.map(()=>({demResolution:b?-1:1}))),v}catch(e){s.error=e,s.hasError=!0}finally{(0,n.hk)(s)}}_abortElevationQueriesAfterDependencyChange(){let e=this._elevationQueryAbortController;this._elevationQueryAbortController=new AbortController,e.abort()}async processElevationQueryGeometry(e,t){let r=await this._elevationQueryWorkerSetup;return null!=r&&(0,a.QA)(r),(0,d.Te)(t),this._elevationQueryWorker.invoke(e,t)}async _doLoad(e){let t=e?.signal;try{await this.loadFromPortal({supportedTypes:["Scene Service"]},e)}catch(e){(0,d.QP)(e)}if((0,d.Te)(t),await this._fetchService(t),(0,d.Te)(t),null!=this._modificationsSource){let r=await $e.A.fromUrl(this._modificationsSource.url,this.spatialReference,e);(0,d.Te)(t),this.setAtOrigin("modifications",r,this._modificationsSource.context.origin),this._modificationsSource=null}await this._fetchIndexAndUpdateExtent(this.nodePages,t),(0,d.Te)(t)}beforeSave(){if(null!=this._modificationsSource)return this.load().then(()=>{},()=>{})}async saveAs(e,t){return this._debouncedSaveOperations(1,{...t,getTypeKeywords:()=>this._getTypeKeywords(),portalItemLayerType:"integrated-mesh"},e)}async save(){return this._debouncedSaveOperations(0,{getTypeKeywords:()=>this._getTypeKeywords(),portalItemLayerType:"integrated-mesh"})}get isUsedAsGroundLayer(){return!(0,u.A)("enable-feature:im-as-ground")||(0,Xe.S)(this.parent)||(0,Ye.Q)(this.parent)}get replacesTerrain(){return!1}validateLayer(e){if(e.layerType&&"IntegratedMesh"!==e.layerType)throw new o.A("integrated-mesh-layer:layer-type-not-supported","IntegratedMeshLayer does not support this layer type",{layerType:e.layerType});if(isNaN(this.version.major)||isNaN(this.version.minor))throw new o.A("layer:service-version-not-supported","Service version is not supported.",{serviceVersion:this.version.versionString,supportedVersions:"1.x"});if(this.version.major>1)throw new o.A("layer:service-version-too-new","Service version is too new.",{serviceVersion:this.version.versionString,supportedVersions:"1.x"})}_getTypeKeywords(){return["IntegratedMeshLayer"]}get elevationQueryDataRequester(){return new nt(this.customParameters,this.apiKey)}get elevationQueryNodeLoader(){return new ft(this,this.elevationQueryDataRequester,h.A.getLogger("esri.layers.IntegratedMeshLayer"),this.store?.defaultGeometrySchema,[],{loadFeatureData:!1,textureUsageMask:0})}_validateElevationInfo(e){let t="Integrated mesh layers";(0,He.XF)(h.A.getLogger(this),(0,He.B)(t,"absolute-height",e)),(0,He.XF)(h.A.getLogger(this),(0,He.tW)(t,e))}};(0,n.Cg)([(0,g.MZ)({type:String,readOnly:!0})],mt.prototype,"geometryType",void 0),(0,n.Cg)([(0,g.MZ)({type:["show","hide"]})],mt.prototype,"listMode",void 0),(0,n.Cg)([(0,g.MZ)({type:["IntegratedMeshLayer"]})],mt.prototype,"operationalLayerType",void 0),(0,n.Cg)([(0,g.MZ)({json:{read:!1},readOnly:!0})],mt.prototype,"type",void 0),(0,n.Cg)([(0,g.MZ)({type:Be.W4,readOnly:!0,clonable:!1})],mt.prototype,"nodePages",void 0),(0,n.Cg)([(0,g.MZ)({type:[Be.uV],readOnly:!0,clonable:!1})],mt.prototype,"materialDefinitions",void 0),(0,n.Cg)([(0,g.MZ)({type:[Be.Ot],readOnly:!0,clonable:!1})],mt.prototype,"textureSetDefinitions",void 0),(0,n.Cg)([(0,g.MZ)({type:[Be.L0],readOnly:!0,clonable:!1})],mt.prototype,"geometryDefinitions",void 0),(0,n.Cg)([(0,g.MZ)({readOnly:!0})],mt.prototype,"serviceUpdateTimeStamp",void 0),(0,n.Cg)([(0,g.MZ)({type:$e.A,clonable:e=>e?.clone()??e}),(0,m.P)({origins:["web-scene","portal-item"],type:"resource",prefix:"modifications"})],mt.prototype,"modifications",void 0),(0,n.Cg)([(0,g.MZ)({clonable:e=>e?{...e}:null})],mt.prototype,"_modificationsSource",void 0),(0,n.Cg)([(0,gt.w)(["web-scene","portal-item"],"modifications")],mt.prototype,"readModifications",null),(0,n.Cg)([(0,g.MZ)(S.Yj)],mt.prototype,"elevationInfo",null),(0,n.Cg)([(0,g.MZ)({type:String,json:{origins:{"web-scene":{read:!0,write:!0},"portal-item":{read:!0,write:!0}},read:!1}})],mt.prototype,"path",void 0),(0,n.Cg)([(0,g.MZ)({clonable:!1})],mt.prototype,"_elevationQueryWorker",null),(0,n.Cg)([(0,g.MZ)()],mt.prototype,"_modificationsGeneration",void 0),(0,n.Cg)([(0,g.MZ)()],mt.prototype,"memoizedElevationQueryDependencies",null),(0,n.Cg)([(0,g.MZ)()],mt.prototype,"isUsedAsGroundLayer",null),(0,n.Cg)([(0,g.MZ)()],mt.prototype,"replacesTerrain",null),(0,n.Cg)([(0,g.MZ)({clonable:!1})],mt.prototype,"elevationQueryDataRequester",null),(0,n.Cg)([(0,g.MZ)({clonable:!1})],mt.prototype,"elevationQueryNodeLoader",null),mt=(0,n.Cg)([(0,g.$K)("esri.layers.IntegratedMeshLayer")],mt);const pt=mt},85707(e,t,r){var n=r(32198),i=r(91429),a=r(54239);r.d(t,["a",0,e=>{let t=e,r=class extends t{constructor(){super(...arguments),this.heightModelInfo=null}read(e,t){super.read(e,t),"service"===t?.origin&&2===this.heightModelInfo?.origin&&(this.heightModelInfo.associatedSpatialReference=this.getAtOrigin("spatialReference","service"))}};return(0,n.Cg)([(0,i.MZ)({readOnly:!0,type:a.A})],r.prototype,"heightModelInfo",void 0),r=(0,n.Cg)([(0,i.$K)("esri.layers.mixins.HeightModelInfoMixin")],r),r}])},10292(e,t,r){r.d(t,{q:()=>o});var n=r(48526),i=r(86738),a=r(82799),s=r(99917);class o{constructor(e){this.geometry=e,this.spatialReference=e.spatialReference}export(){return this._exporter(this.coordinates,this.spatialReference)}clone(e){let t=new o(this.geometry);return t.spatialReference=this.spatialReference,t.coordinates=e??this.coordinates.map(e=>e.clone()),t._exporter=this._exporter,t}async project(e,t){if(this.spatialReference.equals(e))return this.clone();await(0,s.initializeProjection)([{source:this.spatialReference,dest:e}],{signal:t});let r=new n.A({spatialReference:this.spatialReference,points:this.coordinates.map(e=>[e.x,e.y])}),i=(0,s.project)(r,e);if(!i)return null;let a=this.coordinates.map((e,t)=>{let r=e.clone(),n=i.points[t];return r.x=n[0],r.y=n[1],r}),o=this.clone(a);return o.spatialReference=e,o}projectSync(e){if(this.spatialReference.equals(e))return this.clone();let t=new n.A({spatialReference:this.spatialReference,points:this.coordinates.map(e=>[e.x,e.y])}),r=(0,s.project)(t,e);if(!r)return null;let i=this.coordinates.map((e,t)=>{let n=e.clone(),i=r.points[t];return n.x=i[0],n.y=i[1],n}),a=this.clone(i);return a.spatialReference=e,a}static fromGeometry(e){let t=new o(e);if(e instanceof o)return t.coordinates=e.coordinates.map(e=>e.clone()),t._exporter=(t,r)=>{let n=e.clone(t);return n.spatialReference=r,n},t;switch(e.type){case"point":{let r=e,{hasZ:n,hasM:a}=r;return t.coordinates=n&&a?[new l(r.x,r.y,r.z,r.m)]:n?[new l(r.x,r.y,r.z)]:a?[new l(r.x,r.y,null,r.m)]:[new l(r.x,r.y)],t._exporter=(t,r)=>e.hasM?new i.A(t[0].x,t[0].y,t[0].z,t[0].m,r):new i.A(t[0].x,t[0].y,t[0].z,r),t}case"multipoint":{let r=e,{hasZ:i,hasM:a}=r;return t.coordinates=i&&a?r.points.map(e=>new l(e[0],e[1],e[2],e[3])):i?r.points.map(e=>new l(e[0],e[1],e[2])):a?r.points.map(e=>new l(e[0],e[1],null,e[2])):r.points.map(e=>new l(e[0],e[1])),t._exporter=(t,r)=>e.hasM?new n.A({points:t.map(e=>[e.x,e.y,e.z??0,e.m??0]),hasZ:!0,hasM:!0,spatialReference:r}):new n.A({points:t.map(e=>[e.x,e.y,e.z??0]),spatialReference:r}),t}case"polyline":{let r=e,n=[],i=[],{hasZ:s,hasM:o}=e,u=0;for(let e of r.paths)if(i.push([u,u+e.length]),u+=e.length,s&&o)for(let t of e)n.push(new l(t[0],t[1],t[2],t[3]));else if(s)for(let t of e)n.push(new l(t[0],t[1],t[2]));else if(o)for(let t of e)n.push(new l(t[0],t[1],null,t[2]));else for(let t of e)n.push(new l(t[0],t[1]));return t.coordinates=n,t._exporter=(t,r)=>{let n=e.hasM?t.map(e=>[e.x,e.y,e.z??0,e.m??0]):t.map(e=>[e.x,e.y,e.z??0]),s=i.map(e=>n.slice(e[0],e[1]));return new a.A({paths:s,hasM:e.hasM,hasZ:!0,spatialReference:r})},t}}}}class l{constructor(e,t,r=null,n=null,i=null,a=null){this.x=e,this.y=t,this.z=r,this.m=n,this.tile=i,this.elevationTile=a}clone(){return new l(this.x,this.y,this.z,this.m)}}},73179(e,t,r){r.d(t,{b:()=>l,h:()=>u});var n=r(4718),i=r(53966),a=r(84952),s=r(60694),o=r(10873);function l(e){let{nonStandardUrlAllowed:t=!1,separator:r}=e??{},a=(0,n.o8)(o.OZ),l=a.json?.write;return"object"==typeof l&&l&&(l.writer=function(e,t,n,i){(0,s.LS)(this,e,r,t,i)}),{...a,set:function(e){if(null==e)return void this._set("url",e);let r=(0,s.HZ)({layer:this,url:e,nonStandardUrlAllowed:t,logger:i.A.getLogger(this)});this._set("url",r.url),null!=r.layerId&&this._set("layerId",r.layerId)}}}function u(e,t){let{separator:r}=t??{},n=(0,a.An)(e.url);return null!=n&&(null==e.dynamicDataSource?null!=e.layerId&&(n.path=(0,a.fj)(n.path,r??"",e.layerId.toString())):n.path=(0,a.fj)(n.path,"dynamicLayer")),n}},89707(e,t,r){r.d(t,{H:()=>n});class n{constructor(e=1/0,t=-1/0){this.minElevation=e,this.maxElevation=t}get elevationRangeValid(){return!Number.isNaN(this.minElevation)}get isEmpty(){return!(this.minElevation<=this.maxElevation)}contains(e){return this.minElevation<=e.minElevation&&this.maxElevation>=e.maxElevation}invalidateElevationRange(){this.minElevation=NaN}initializeEmpty(){this.minElevation=1/0,this.maxElevation=-1/0}expandElevationRange(e){let t=Math.min(this.minElevation,e.minElevation),r=Math.max(this.maxElevation,e.maxElevation),n=t!==this.minElevation||r!==this.maxElevation;return this.minElevation=t,this.maxElevation=r,n}expandElevationRangeValues(e,t){let r=Math.min(this.minElevation,e),n=Math.max(this.maxElevation,t),i=r!==this.minElevation||n!==this.maxElevation;return this.minElevation=r,this.maxElevation=n,i}setElevationRange(e){this.minElevation=e.minElevation,this.maxElevation=e.maxElevation}setElevationRangeValues(e,t){this.minElevation=e,this.maxElevation=t}equals(e){return this.minElevation===e.minElevation&&this.maxElevation===e.maxElevation}}},62747(e,t,r){r.d(t,{W7:()=>a,hH:()=>s});var n=r(1843),i=r(65786);i.Y;class a extends i.Y{constructor(e,t,r){super(),this.hasVertexColors=e,this.hasNormals=t,this.textureCoordinateType=r}}function s(e){let t=(0,n.BP)().vec3f("position");return e.hasNormals&&t.vec2i16("normalCompressed",{glNormalized:!0}),1===e.textureCoordinateType?t.vec2f("uv0"):2===e.textureCoordinateType&&(t.vec2f("uv0"),t.vec4u16("uvRegion",{glNormalized:!0})),e.hasVertexColors&&t.vec4u8("color",{glNormalized:!0}),t.freeze()}},92359(e,t,r){r.d(t,{nu:()=>d,W6:()=>u}),r(4576),r(71511),r(44208),r(53966);var n=r(17676),i=(r(36708),r(44794),r(78659)),a=r(32198),s=r(69622),o=r(91429);let l=class extends s.A{constructor(){super(...arguments),this.SCHEDULER_LOG_SLOW_TASKS=!1,this.FEATURE_SERVICE_SNAPPING_SOURCE_TILE_TREE_SHOW_TILES=!1}};(0,a.Cg)([(0,o.MZ)()],l.prototype,"SCHEDULER_LOG_SLOW_TASKS",void 0),(0,a.Cg)([(0,o.MZ)()],l.prototype,"FEATURE_SERVICE_SNAPPING_SOURCE_TILE_TREE_SHOW_TILES",void 0),l=(0,a.Cg)([(0,o.$K)("esri.views.support.debugFlags")],l),new l,r(49186),Symbol("Yield");const u={RESOURCE_CONTROLLER_IMMEDIATE:"immediate",RESOURCE_CONTROLLER:"schedule",SLIDE:"slide",STREAM_DATA_LOADER:"stream loader",ELEVATION_QUERY:"elevation query",TERRAIN_SURFACE:"terrain",SURFACE_GEOMETRY_UPDATES:"surface geometry updates",LOD_RENDERER:"LoD renderer",GRAPHICS_CORE:"Graphics3D",I3S:"I3S",LYR3D:"Lyr3D",TILES3D:"3DTiles",POINT_CLOUD_LAYER:"point cloud",FEATURE_TILE_FETCHER:"feature fetcher",STREAM_CONTROLLER:"stream controller",SCREEN_POLYGON_INTERSECTION:"screen polygon intersection",OCCLUSION_QUERY:"occlusion query",OVERLAY:"overlay",OVERLAY_RENDERER:"overlay renderer",STAGE:"stage",GRAPHICS_DECONFLICTOR:"graphics deconflictor",FILTER_VISIBILITY:"graphics filter visibility",SCALE_VISIBILITY:"graphics scale visibility",FRUSTUM_VISIBILITY:"graphics frustum visibility",POINT_OF_INTEREST_FREQUENT:"POI frequent",POINT_OF_INTEREST_INFREQUENT:"POI infrequent",LABELER:"labeler",FEATURE_QUERY_ENGINE:"feature query",FEATURE_TILE_TREE:"feature tile tree",FEATURE_TILE_TREE_ACTIVE:"fast feature tile tree",ELEVATION_ALIGNMENT:"elevation alignment",ELEVATION_ALIGNMENT_SCENE:"elevation alignment scene",TEXT_TEXTURE_ATLAS:"text texture atlas",TEXTURE_UNLOAD:"texture unload",LINE_OF_SIGHT_TOOL:"line of sight tool",LINE_OF_SIGHT_TOOL_INTERACTIVE:"interactive line of sight tool",VOLUME_MEASUREMENT:"volume measurement",ELEVATION_PROFILE:"elevation profile",SNAPPING:"snapping",SHADOW_ACCUMULATOR:"shadow accumulator",CLOUDS_GENERATOR:"clouds generator",FLOW_GENERATOR:"flow generator",GAUSSIAN_SPLAT_SORTING:"gaussian splat sorting",GAUSSIAN_SPLAT_TEXTURE_ATLAS:"gaussian splat texture atlas",MAPVIEW_FETCH_QUEUE:"mapview fetch queue",MAPVIEW_LAYERVIEW_UPDATE:"mapview layerview update",MAPVIEW_VECTOR_TILE_PARSING_QUEUE:"mapview vector tile parsing queue",NONE:0,TEST_PRIO:1};new Map([[u.RESOURCE_CONTROLLER_IMMEDIATE,0],[u.RESOURCE_CONTROLLER,4],[u.SLIDE,0],[u.STREAM_DATA_LOADER,0],[u.ELEVATION_QUERY,0],[u.TERRAIN_SURFACE,1],[u.SURFACE_GEOMETRY_UPDATES,1],[u.LOD_RENDERER,2],[u.GRAPHICS_CORE,2],[u.I3S,2],[u.LYR3D,2],[u.TILES3D,3],[u.POINT_CLOUD_LAYER,2],[u.FEATURE_TILE_FETCHER,2],[u.STREAM_CONTROLLER,2],[u.SCREEN_POLYGON_INTERSECTION,0],[u.CLOUDS_GENERATOR,2],[u.OCCLUSION_QUERY,2],[u.OVERLAY,4],[u.OVERLAY_RENDERER,4],[u.STAGE,4],[u.GRAPHICS_DECONFLICTOR,4],[u.FILTER_VISIBILITY,4],[u.SCALE_VISIBILITY,4],[u.FRUSTUM_VISIBILITY,4],[u.POINT_OF_INTEREST_FREQUENT,6],[u.POINT_OF_INTEREST_INFREQUENT,30],[u.LABELER,8],[u.FEATURE_QUERY_ENGINE,8],[u.FEATURE_TILE_TREE,16],[u.FEATURE_TILE_TREE_ACTIVE,0],[u.ELEVATION_ALIGNMENT,12],[u.ELEVATION_ALIGNMENT_SCENE,14],[u.TEXT_TEXTURE_ATLAS,12],[u.TEXTURE_UNLOAD,12],[u.LINE_OF_SIGHT_TOOL,16],[u.LINE_OF_SIGHT_TOOL_INTERACTIVE,0],[u.VOLUME_MEASUREMENT,4],[u.SNAPPING,0],[u.SHADOW_ACCUMULATOR,30],[u.FLOW_GENERATOR,12],[u.GAUSSIAN_SPLAT_SORTING,2],[u.GAUSSIAN_SPLAT_TEXTURE_ATLAS,12],[u.MAPVIEW_FETCH_QUEUE,0],[u.MAPVIEW_LAYERVIEW_UPDATE,2],[u.MAPVIEW_VECTOR_TILE_PARSING_QUEUE,0]]),(0,i.l5)(6.5),(0,i.l5)(1),(0,i.l5)(30),(0,i.l5)(1e3/30),(0,i.l5)(100),Symbol.dispose;const h=new class{constructor(){this._begin=performance?.now()??0,this._budget=0,this._done=!1,this._progressed=!1,this._enabled=!0}run(e){return!this.done&&(!0===e()&&this.madeProgress(),!0)}get done(){return this._done}get budget(){return this._budget}madeProgress(){return this._progressed=!0,this._done=this.elapsed>=this._budget&&this._enabled,this._done}get enabled(){return this._enabled}set enabled(e){this._enabled=e}reset(e){this._begin=this.now(),this._budget=e,this.resetProgress()}get remaining(){return Math.max(this._budget-this.elapsed,0)}now(){return performance.now()}get elapsed(){return this.now()-this._begin}resetProgress(){this._progressed=!1,this._done=!1}get hasProgressed(){return this._progressed}};h.enabled=!1;class c{remove(){}[Symbol.dispose](){this.remove()}processQueue(){}schedule(e,t,r){try{if((0,n.G4)(t)){let e=(0,n.NK)();return r?Promise.resolve(r(e)):Promise.reject(e)}return(0,n.z7)(e(h))}catch(e){return Promise.reject(e)}}reschedule(e,t,r){return this.schedule(e,t,r)}async scheduleGenerator(e,t,r){if((0,n.G4)(t)){let e=(0,n.NK)();if(r)return r(e);throw e}let i=e(h);for(;;){let e=i.next(h),a=(0,n.$X)(e)?await e:e;if((0,n.G4)(t)){let e=(0,n.NK)();if(r){let t=r(e),a=i.return(null);return(0,n.$X)(a)&&await(0,n.QZ)(a),t}let t=i.throw(e);throw(0,n.$X)(t)&&await(0,n.QZ)(t),e}if(a.done)return a.value}}}const d=new c}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkRemoteClient=self.webpackChunkRemoteClient||[]).push([[8595],{82806(e,t,i){var r=i(32198),n=i(56507),l=i(49186),s=i(53966),a=i(91429),o=i(78888),u=i(86738),c=i(16930),h=i(21325),d=i(7548),f=i(23636),p=i(4366),m=i(34930),g=i(99235),y=i(37373),x=i(51927),w=i(60694),R=i(10873),b=i(45617),I=i(33446),v=i(43577),_=i(13868),S=i(22796),C=i(69409),k=i(87045),M=i(12711),T=i(85676),A=i(94359),P=i(22048),F=i(49410),z=i(34606),B=i(51508),D=i(93223),J=i(36005);i.d(t,["b",0,e=>{let t=e,H=class extends t{constructor(...e){super(...e),this._draRasterConfig=null,this._isConstructedFromFunctionRaster=!1,this.bandIds=null,this.copyright=null,this.interpolation=null,this.multidimensionalSubset=null,this.raster=null,this.serviceRasterInfo=null,this.sourceJSON=null,this.spatialReference=null,this.symbolizer=null,this._isConstructedFromFunctionRaster=(0,d.qg)(e[0]?.raster)}destroy(){this._draRasterConfig?.rasterJobHandler?.destroy(),this._shutdownJobHandler()}get fullExtent(){return this.serviceRasterInfo?.extent}set multidimensionalDefinition(e){this._set("multidimensionalDefinition",e),this.updateRenderer()}set rasterFunction(e){"none"===e?.functionName?.toLowerCase()&&(e=void 0),this._set("rasterFunction",e),this.updateRasterFunction()}set url(e){this._set("url",(0,w.Jf)(e,s.A.getLogger(this)))}get renderer(){if("imagery-tile"!==this.type)return this.internalRenderer;let{activePresetRendererName:e,presetRenderers:t}=this;return e?(t?.find(({name:t})=>t===e))?.renderer.clone():this.internalRenderer}set renderer(e){"imagery-tile"===this.type&&(this.activePresetRendererName=null),this.internalRenderer=e}set internalRenderer(e){null==e&&null==this.rasterFunction?this._configDefaultRenderer("override"):(this._set("internalRenderer",e),this.updateRenderer())}readRenderer(e,t,i){let r=t?.layerDefinition?.drawingInfo?.renderer;return(0,A.LF)(r,i)||void 0}async computeStatisticsHistograms(e,t){await this.load(t),e=(0,o.PZ)(P.A,e).clone();let{serviceRasterInfo:i}=this;if(null==i)throw new l.A("imagery-tile-mixin:compute-statistics-histograms","serviceRasterInfo must be specified");let{geometry:r}=e;if(null==r)throw new l.A("imagery-tile-mixin:compute-statistics-histograms","geometry must be specified");let n=r,{spatialReference:s}=i;if(!r.spatialReference.equals(s)){await(0,y.Hh)();let e="extent"===r.type?(0,y._l)(r,s):(0,y.uk)(r,s);if(null==e)throw new l.A("imagery-tile-mixin:compute-statistics-histograms","geometry cannot be projected to the data source");n=e}let a=e.pixelSize??new u.A({x:i.pixelSize.x,y:i.pixelSize.y,spatialReference:s}),{extent:c,width:h,height:d}=(0,m.b7)(i,n,a),f=await this.fetchPixels(c,h,d,{...t,interpolation:"nearest"});if(null==f.pixelBlock)throw new l.A("imagery-tile-mixin:compute-statistics-histograms","failed to fetch pixels");let p=await(0,m.$Q)(f.pixelBlock,c,n),g=this._rasterJobHandler;return g?g.computeStatisticsHistograms({pixelBlock:p},t):(0,x.eH)(p)}normalizeRasterFetchOptions(e){let{multidimensionalInfo:t}=this.serviceRasterInfo??{};if(null==t)return e;let i=(0,p.XU)({rasterInfo:this.raster.rasterInfo,multidimensionalDefinition:e.multidimensionalDefinition||this.multidimensionalDefinition,timeExtent:e.timeExtent??this.timeExtent,multidimensionalSubset:this.multidimensionalSubset});return{...e,multidimensionalDefinition:i,timeExtent:void 0}}async updateRasterFunction(){return!this.loaded||"imagery-tile"!==this.type||!this.rasterFunction&&!this._cachedRasterFunctionJson||JSON.stringify(this.rasterFunction)===JSON.stringify(this._cachedRasterFunctionJson)||(this._cachedRasterFunctionJson=this.rasterFunction?.toJSON(),this._rasterFunctionUpdatePromise=this._updateRasterFunction()),this._rasterFunctionUpdatePromise}async updateRenderer(){let{loaded:e,symbolizer:t,renderer:i}=this;if(!e||!t||!i)return;let{rasterInfo:r}=this.raster,n=(0,p.ct)(r,{multidimensionalDefinition:this.multidimensionalDefinition,multidimensionalSubset:this.multidimensionalSubset})?.name,l=(0,M.m7)(r,n);return this._updateSymbolizer(t,i,n,l)}async applyRenderer(e,t,i){let r=e?.pixelBlock;if(!(null!=r&&r.pixels&&r.pixels.length>0))return null;await this.updateRenderer();let n=this.bandIds??[],{pixelBlock:l}=await this._symbolize({pixelData:e,simpleStretchParams:t,bandIds:n,symbolizer:this.symbolizer},i);return l}getRawDisplayBandIds(){let{bandIds:e,raster:t}=this;if(this.rasterFunction&&(0,d.qg)(t)){let i=t.rasterFunction.rawInputBandIds;e=e?.length&&i?.length&&1!==t.rasterInfo.bandCount?e.map(e=>i[Math.min(e,i.length-1)]):i}return e&&e.length>3&&e.every((e,t)=>e===t)?null:e}getTileUrl(e,t,i){return"RasterTileServer"===this.raster.datasetFormat?`${this.url}/tile/${e}/${t}/${i}`:""}getCompatibleTileInfo(e,t,i=!1){if(!this.loaded||null==t)return null;if(i&&e.equals(this.spatialReference))return this.tileInfo;let r=(0,h.Vp)(e);return k.A.create({size:256,spatialReference:e,origin:r?{x:r.origin[0],y:r.origin[1]}:{x:t.xmin,y:t.ymax}})}getCompatibleFullExtent(e){return this.loaded?(this._compatibleFullExtent?.spatialReference.equals(e)||(this._compatibleFullExtent=this.raster.computeExtent(e)),this._compatibleFullExtent):null}async fetchTile(e,t,i,r={}){if(N(this),r.requestAsImageElement){let l=this.getTileUrl(e,t,i),{data:s}=await(0,n.A)(l,{responseType:"image",query:{...this.refreshParameters,...this.raster.ioConfig.customFetchParameters},signal:r.signal});return s}let{serviceRasterInfo:l}=this;if(null!=l.multidimensionalInfo&&null==(r=this.normalizeRasterFetchOptions(r)).multidimensionalDefinition){let n=r.tileInfo||l.storageInfo.tileInfo,s=this.raster.getTileExtentFromTileInfo(e,t,i,n);if(s)return{extent:s,pixelBlock:null}}return await this._initJobHandler(),await this.updateRasterFunction(),"raster-shaded-relief"===this.renderer?.type&&(r={...r,buffer:{cols:1,rows:1}}),r={...r,refreshParameters:this.refreshParameters},this.raster.fetchTile(e,t,i,r)}async fetchImageBitmapTile(e,t,i,r={}){N(this);let l=this.getTileUrl(e,t,i),{data:s}=await(0,n.A)(l,{responseType:"blob",query:{...this.refreshParameters,...this.raster.ioConfig.customFetchParameters},signal:r?.signal});return(0,I.Cp)(s,e,t,i,r)}async fetchPixels(e,t,i,r={}){if(null!=this.serviceRasterInfo.multidimensionalInfo&&null==(r=this.normalizeRasterFetchOptions(r)).multidimensionalDefinition)return{extent:e,pixelBlock:null};await this._initJobHandler(),await this.updateRasterFunction(),t=Math.round(t),i=Math.round(i);let n=await this.raster.fetchPixels(e,t,i,r);return r.bandIds?.length&&!this.raster.rasterInfo.storageInfo.isBsqTile&&(n.pixelBlock=n.pixelBlock?.extractBands(r.bandIds)),n}async getSamples(e,t){await this.load();let i=(0,o.PZ)(z.A,e).clone();if(i.interpolation&&"nearest"!==i.interpolation)throw new l.A("imagery-tile-mixin:get-samples","only nearest interpolation is currently supported");let r=i.mosaicRule?.multidimensionalDefinition,n={...t,multidimensionalDefinition:r},s=(await this._getSampleLocations(i)).map(e=>this.identify(e,n).then(t=>(t.location=e,t))),a=(await Promise.all(s)).flatMap((e,t)=>this._convertRasterIdentifyResultToSample(e,t));return new B.A({samples:a})}async identify(e,t={}){await this.load();let i=(0,o.PZ)(u.A,e).clone().normalize(),{raster:r,serviceRasterInfo:n}=this;if(null!=n?.multidimensionalInfo&&(!n.hasMultidimensionalTranspose||!(0,p.DY)(t.multidimensionalDefinition)&&!t.transposedVariableName)&&null==(t=this.normalizeRasterFetchOptions(t)).multidimensionalDefinition)return{location:i,value:null};let s,a=this.multidimensionalSubset?.areaOfInterest;if(a&&!a.contains(i))throw new l.A("imagery-tile-mixin:identify","the request cannot be fulfilled when falling outside of the multidimensional subset");if(this.serviceRasterInfo?.storageInfo.isBsqTile){let e=(0,d.qg)(r)?this.getRawDisplayBandIds():this.bandIds;s=e?.length?e:void 0}return r.identify(i,{...t,bandIds:s})}hasStandardTime(){let e=this.serviceRasterInfo?.multidimensionalInfo;if(null==e||"standard-time"!==this.serviceRasterInfo?.dataType)return!1;let t=this.multidimensionalDefinition,i=t?.[0]?.variableName;return e.variables.some(e=>e.name===i&&(!t?.[0].dimensionName||e.dimensions.some(e=>"StdTime"===e.name)))}getStandardTimeValue(e){return new Date((0,p.$E)(e)).toISOString()}getMultidimensionalSubsetVariables(e){let t=e??this.serviceRasterInfo?.multidimensionalInfo;return(0,p.z2)(this.multidimensionalSubset,t)}async getDynamicRangeInputRaster(){if(!this.rasterFunction||!(0,d.qg)(this.raster)||!this._cachedRasterFunctionJson)return null;let e=JSON.stringify(this._cachedRasterFunctionJson);if(this._draRasterConfig?.functionJson===e)return this._draRasterConfig;let t=this.raster.rasterFunction.queryRasterFunction(e=>"Stretch"===e.functionName&&e.functionArguments.dynamicRangeAdjustment);if(!t)return null;let i=t.toJSON(),r=this.raster.primaryRasters.rasters,n=t.functionArguments.raster,l=i.rasterFunctionArguments;if(!n||"object"!=typeof n||!("functionName"in n))return this._draRasterConfig={functionJson:e,raster:r[0],functionArguments:l,rasterJobHandler:this._draRasterConfig?.rasterJobHandler},this._draRasterConfig;let s={raster:r[0]};r.length>1&&r.forEach(e=>s[e.url]=e);let a=(0,g.vt)(n.toJSON(),s),o=new f.A({rasterFunction:a});await o.open();let u=this._draRasterConfig?.rasterJobHandler;try{u||(u=new C.A,await u.initialize()),o.rasterJobHandler=u,await o.syncJobHandler()}catch{}return this._draRasterConfig={functionJson:e,raster:o,functionArguments:l,rasterJobHandler:u},this._draRasterConfig}_configDefaultSettings(){this._configDefaultInterpolation(),this.multidimensionalDefinition||=(0,p.fy)(this.raster.rasterInfo,{multidimensionalSubset:this.multidimensionalSubset}),this.rasterFunction&&(0,d.qg)(this.raster)&&(this._cachedRasterFunctionJson=this.rasterFunction.toJSON()),this._configDefaultRenderer()}async _initJobHandler(){if(!this._rasterJobHandler)return super._initJobHandler().then(async()=>{if(!this._rasterJobHandler)return;N(this);let{raster:e}=this;e.rasterJobHandler!==this._rasterJobHandler&&(e.rasterJobHandler=this._rasterJobHandler,(0,d.qg)(e)&&e.syncJobHandler(),this.rasterFunction&&await this.updateRasterFunction().catch(()=>{}),this.renderer&&this.updateRenderer())}).catch(()=>{})}_shutdownJobHandler(){super._shutdownJobHandler(),this.raster&&(this.raster.rasterJobHandler=null)}async _getSampleLocations(e){let{geometry:t}=e;if("point"===t.type)return[t];let{spatialReference:r,type:n}=t;if("multipoint"===n)return t.points.map(e=>new u.A({x:e[0],y:e[1],spatialReference:r}));if("polyline"===n){let n=t;if(e.sampleCount||e.sampleDistance){let{densifyExecute:r}=await Promise.all([i.e(9187),i.e(8885),i.e(9117),i.e(3299),i.e(4642)]).then(()=>i(88411)),{lengthExecute:l}=await Promise.all([i.e(9187),i.e(8885),i.e(9117),i.e(3299),i.e(2174)]).then(()=>i(965)),s=l(t,{unit:"meters"}),a=Math.min(e.sampleCount||100,1e3),o=e.sampleDistance;o||=s/(a+ +(2===n.paths[0].length)),n=r(t,o,{unit:"meters"})}return n.paths.flatMap(e=>e.map(e=>new u.A({x:e[0],y:e[1],spatialReference:r})))}let l=Math.min(e.sampleCount||100,1e3),s="extent"===t.type,a=s?t:t.extent,o=Math.sqrt(a.width*a.height/l),c=a.height/o,h=a.width/o,{xmin:d,ymax:f}=a,p=[];for(let e=0;e<c;e++)for(let i=0;i<h;i++){let n=new u.A({x:d+(i+.5)*o,y:f-(e+.5)*o,spatialReference:r});(s||t.contains(n))&&p.push(n)}return p}_configDefaultInterpolation(){if(null==this.interpolation){N(this);let{raster:e}=this,t=(0,M.w6)(e.rasterInfo,e.tileType,this.sourceJSON?.defaultResamplingMethod);this._set("interpolation",t)}}_configDefaultRenderer(e="no"){N(this);let{rasterInfo:t}=this.raster,i=(0,p.ct)(t,{multidimensionalDefinition:this.multidimensionalDefinition,multidimensionalSubset:this.multidimensionalSubset})?.name,r=(0,M.I8)({variableName:i,rasterFunctionName:this.rasterFunction?.functionName,presetRenderers:this.presetRenderers});if(!this.bandIds&&t.bandCount>1&&(this.bandIds=r?.bandIds??(0,M.ci)(t)),!this.renderer||"override"===e){let e=(0,M.Mm)(this.raster),n=r?.renderer??(0,M.PD)(t,{bandIds:this.bandIds,variableName:i,rasterFunctionColorRamp:e}),l=t.statistics,s=l&&l.length>0?l[0]:null,a=s?.max??0,o=s?.min??0;"WCSServer"===this.raster.datasetFormat&&"raster-stretch"===n.type&&(a>1e24||o<-1e24)&&(n.dynamicRangeAdjustment=!0,n.customStatistics=null,"none"===n.stretchType&&(n.stretchType="min-max")),this.renderer=n}let n=(0,M.$P)({...this.renderer.toJSON(),variableName:i}),l=(0,M.m7)(t,i);this.symbolizer?(this.symbolizer.rendererJSON=n,this.symbolizer.rasterInfo=l):this.symbolizer=new T.A({rendererJSON:n,rasterInfo:l});let a=this.symbolizer.bind();if(a.success){if("auto"===e){let{colormap:e}=this.raster.rasterInfo,t=this.renderer;if(null!=e&&"raster-colormap"===t.type){let e=(0,M.PD)(this.raster.rasterInfo);JSON.stringify(e)!==JSON.stringify(t)&&this._configDefaultRenderer("override")}else if("raster-stretch"===t.type){let e=this.bandIds?.length,i=t.customStatistics?.length;!t.dynamicRangeAdjustment&&i&&e&&i!==e&&this._configDefaultRenderer("override")}}}else s.A.getLogger(this).warn("imagery-tile-mixin",a.error||"The given renderer is not supported by the layer."),"auto"===e&&this._configDefaultRenderer("override")}async _updateRasterFunction(){if(this._isConstructedFromFunctionRaster&&(0,d.qg)(this.raster)){let e=this.raster.rasterFunction.toJSON();return void(!this.rasterFunction&&e&&this._set("rasterFunction",S.A.fromJSON(e)))}let e,t=this.raster,i=!1;(0,d.qg)(t)?(e=t.primaryRasters.rasters,t=e[0],i=!0):e=[t];let{rasterFunction:r}=this;if(r){let i={raster:t};e.length>1&&e.forEach(e=>i[e.url]=e);let n=(0,g.vt)(r.functionDefinition?.toJSON()??r.toJSON(),i),l=new f.A({rasterFunction:n});l.rasterJobHandler=this._rasterJobHandler,await l.open(),this.raster=l}else this.raster=t,await t.open();if(this._cachedRendererJson=void 0,!i&&!r)return;let{bandIds:n}=this,{bandCount:l}=this.raster.rasterInfo,s=n?.length?n.some(e=>e>=l):l>=3;n&&(s||this.renderer&&"raster-stretch"!==this.renderer.type)&&this._set("bandIds",null),this._configDefaultRenderer("auto")}_convertRasterIdentifyResultToSample(e,t){let{rasterInfo:i}=this.raster,r=i.storageInfo.pyramidScalingFactor**(e.pyramidLevel??0),n=(i.pixelSize.x+i.pixelSize.y)/2*r;if(!e.dataSeries?.length)return[new F.A({location:e.location,pixelValue:e.value,locationId:t,resolution:n})];let l=[];return e.dataSeries.forEach(({value:i,multidimensionalDefinition:r},s)=>{let a={Variables:r[0].variableName,Dimensions:r.flatMap(({dimensionName:e})=>e).join(",")};for(let{dimensionName:e,values:t}of r){a[e]=Array.isArray(t[0])?t[0][0]:t[0];let i=t[t.length-1];a[`${e}_Max`]=Array.isArray(i)?i[i.length-1]:i}let o=new F.A({location:e.location,pixelValue:i,rasterId:s,locationId:t,resolution:n,attributes:a});l.push(o)}),l}};function N(e){if(!e.raster||!e.serviceRasterInfo)throw new l.A("imagery-tile","no raster")}return(0,r.Cg)([(0,a.MZ)({clonable:!1})],H.prototype,"_cachedRasterFunctionJson",void 0),(0,r.Cg)([(0,a.MZ)({clonable:!1})],H.prototype,"_compatibleFullExtent",void 0),(0,r.Cg)([(0,a.MZ)({clonable:!1})],H.prototype,"_draRasterConfig",void 0),(0,r.Cg)([(0,a.MZ)({clonable:!1})],H.prototype,"_isConstructedFromFunctionRaster",void 0),(0,r.Cg)([(0,a.MZ)({clonable:!1})],H.prototype,"_rasterFunctionUpdatePromise",void 0),(0,r.Cg)([(0,a.MZ)({type:[o.jz],json:{write:{overridePolicy(){return{enabled:!this.loaded||"Raster"===this.raster.tileType||"0,1,2"!==this.bandIds?.join(",")}}}}})],H.prototype,"bandIds",void 0),(0,r.Cg)([(0,a.MZ)({json:{origins:{service:{read:{source:"copyrightText"}}}}})],H.prototype,"copyright",void 0),(0,r.Cg)([(0,a.MZ)({json:{read:!1}})],H.prototype,"fullExtent",null),(0,r.Cg)([(0,a.MZ)({json:{write:{overridePolicy(){return{enabled:!this.loaded||"Raster"===this.raster.tileType||"bilinear"!==this.interpolation}}}}}),(0,D.e)(_.SZ)],H.prototype,"interpolation",void 0),(0,r.Cg)([(0,a.MZ)()],H.prototype,"ioConfig",void 0),(0,r.Cg)([(0,a.MZ)({type:[b.A],json:{write:!0}})],H.prototype,"multidimensionalDefinition",null),(0,r.Cg)([(0,a.MZ)({type:v.A,json:{write:!0}})],H.prototype,"multidimensionalSubset",void 0),(0,r.Cg)([(0,a.MZ)()],H.prototype,"raster",void 0),(0,r.Cg)([(0,a.MZ)({type:S.A})],H.prototype,"rasterFunction",null),(0,r.Cg)([(0,a.MZ)({constructOnly:!0})],H.prototype,"serviceRasterInfo",void 0),(0,r.Cg)([(0,a.MZ)()],H.prototype,"sourceJSON",void 0),(0,r.Cg)([(0,a.MZ)({readOnly:!0,type:c.A,json:{read:!1}})],H.prototype,"spatialReference",void 0),(0,r.Cg)([(0,a.MZ)({type:k.A})],H.prototype,"tileInfo",void 0),(0,r.Cg)([(0,a.MZ)(R.OZ)],H.prototype,"url",null),(0,r.Cg)([(0,a.MZ)({types:A.uy})],H.prototype,"renderer",null),(0,r.Cg)([(0,a.MZ)({types:A.uy,json:{name:"layerDefinition.drawingInfo.renderer",write:{overridePolicy(){let e="raster-stretch"===this.renderer?.type&&"none"===this.renderer.stretchType&&!this.renderer.useGamma;return{enabled:!this.loaded||"Raster"===this.raster.tileType||!e}}},origins:{"web-scene":{types:A.Gj,name:"layerDefinition.drawingInfo.renderer",write:{overridePolicy:e=>({enabled:e&&"vector-field"!==e.type})}}}}})],H.prototype,"internalRenderer",null),(0,r.Cg)([(0,J.w)("internalRenderer")],H.prototype,"readRenderer",null),(0,r.Cg)([(0,a.MZ)({clonable:!1})],H.prototype,"symbolizer",void 0),H=(0,r.Cg)([(0,a.$K)("esri.layers.mixins.TiledImagery")],H),H}])},49859(e,t,i){i.d(t,{A:()=>J});var r=i(32198),n=i(56507),l=i(49186),s=i(25482),a=i(53966),o=i(17676),u=i(563),c=i(91429),h=i(78888),d=i(5443),f=i(86738),p=i(16930),m=i(7548),g=i(4366),y=i(37373);const x=new Map,w=new class{constructor(e=15e3,t=5e3,i=-1){this._timer=null,this._cachedBlocks=new Map,this._size=-1,this._duration=e,this._interval=Math.min(e,t),this._size=i}decreaseRefCount(e,t){let i=e+"/"+t,r=this._cachedBlocks;if(r.has(i)){let e=r.get(i);return e.refCount--,e.refCount<=0&&(r.delete(i),e.controller&&e.controller.abort()),e.refCount}return 0}getBlock(e,t){let i=e+"/"+t,r=this._cachedBlocks;if(r.has(i)){let e=r.get(i);return e.ts=Date.now(),e.refCount++,r.delete(i),r.set(i,e),e.block}return null}putBlock(e,t,i,r){let n=this._cachedBlocks,l=e+"/"+t;if(n.has(l)){let e=n.get(l);e.ts=Date.now(),e.refCount++}else n.set(l,{block:i,ts:Date.now(),refCount:1,controller:r});this._trim(),this._updateTimer()}deleteBlock(e,t){let i=this._cachedBlocks,r=e+"/"+t;i.has(r)&&i.delete(r)}updateMaxSize(e){this._size=e,this._trim()}empty(){this._cachedBlocks.clear(),this._clearTimer()}getCurrentSize(){return this._cachedBlocks.size}_updateTimer(){if(null!=this._timer)return;let e=this._cachedBlocks;this._timer=setInterval(()=>{let t=Array.from(e),i=Date.now();for(let r=0;r<t.length&&t[r][1].ts<=i-this._duration;r++)e.delete(t[r][0]);0===e.size&&this._clearTimer()},this._interval)}_trim(){let e=this._cachedBlocks;if(-1===this._size||this._size>=e.size)return;let t=Array.from(e).sort((e,t)=>e[1].refCount-t[1].refCount||e[1].ts-t[1].ts);for(let i=0;i<t.length-this._size;i++)e.delete(t[i][0])}_clearTimer(){null!=this._timer&&(clearInterval(this._timer),this._timer=null)}}(15e3,5e3,100);function R(e,t,i){let r=x.get(e);if(!r)return null==t?w.decreaseRefCount(e,i):0;if(null==t||null==r[t])return w.decreaseRefCount(e,i);let n=r[t]?.cache,l=n?.get(i);if(n&&l){if(l.refCount--,0===l.refCount){n.delete(i);for(let e=0;e<r.length;e++)r[e]?.cache.delete(i);l.controller&&l.controller.abort()}return l.refCount}return 0}function b(e,t,i){let r=x.get(e);if(!r)return null==t?w.getBlock(e,i):null;if(null==t||null==r[t]){for(let e=0;e<r.length;e++){let t=r[e]?.cache.get(i);if(t)return t.refCount++,t.block}return w.getBlock(e,i)}let n=r[t]?.cache.get(i);if(n)return n.refCount++,n.block;for(let e=0;e<r.length;e++){if(e===t||!r[e])continue;let n=r[e]?.cache,l=n?.get(i);if(n&&l)return l.refCount++,n.set(i,l),l.block}return null}function I(e,t,i,r,n=null){let l=x.get(e);if(!l)return void(t??w.putBlock(e,i,r,n));if(null==t||null==l[t])return void w.putBlock(e,i,r,n);let s={refCount:1,block:r,isResolved:!1,isRejected:!1,controller:n};r.then(()=>s.isResolved=!0).catch(()=>s.isRejected=!0),l[t]?.cache.set(i,s)}function v(e,t,i){let r=x.get(e);r?null==t||null==r[t]?w.deleteBlock(e,i):r[t]?.cache.delete(i):t??w.deleteBlock(e,i)}var _=i(94778),S=i(40951),C=i(34930),k=i(47520),M=i(34251),T=i(60694),A=i(10873),P=i(45617),F=i(91806),z=i(20223),B=i(87045);let D=0,J=class extends s.o{constructor(){super(...arguments),this._tileFetchQueue=new u.QueueProcessor({concurrency:32,process:(e,t)=>this.fetchRawTile(e.pyramidLevel,e.row,e.col,{...e.options,signal:t})}),this.datasetName=null,this.datasetFormat=null,this.hasUniqueSourceStorageInfo=!0,this.rasterInfo=null,this.ioConfig={sampling:"closest"},this.rawBlockRegistryIds=[],this.refresh=(0,o.sg)(async e=>{await this._openPromise;let t=await this._refresh(e);return t.dataChanged&&function(e,t){let i=x.get(e);if(i){let e=t.map(e=>i[e]).filter(e=>null!=e);for(let t of e)t&&(Array.from(t.cache.values()).forEach(e=>{!e.isResolved&&!e.isRejected&&e.controller&&e.controller.abort()}),t.cache.clear())}}(this.rasterId,this.rawBlockRegistryIds),t})}normalizeCtorArgs(e){return e?.ioConfig&&(e={...e,ioConfig:{resolution:null,bandIds:null,sampling:"closest",tileInfo:B.A.create(),...e.ioConfig}}),e}get _isGlobalWrappableSource(){let{rasterInfo:e}=this,t=(0,y.FT)(e.spatialReference);return null!=t&&e.extent.width>=t/2}get _hasNoneOrGCSShiftTransform(){let{transform:e}=this.rasterInfo;return null==e||"gcs-shift"===e.type}set rasterJobHandler(e){this._set("rasterJobHandler",e),(0,m.qg)(this)&&this.primaryRasters?.rasters?.forEach(t=>t.rasterJobHandler=e)}get rasterId(){return this.url||"rasterId-"+D++}set url(e){this._set("url",(0,T.Jf)(e,a.A.getLogger(this)))}async open(e){return this._openPromise??=(0,y.Hh)().then(()=>this._open(e)),this._openPromise}async fetchTile(e,t,i,r={}){let n=r.tileInfo||this.rasterInfo.storageInfo.tileInfo,s=this.getTileExtentFromTileInfo(e,t,i,n);if(!s)throw new l.A("imagery-tile:out-of-bounds","Level for fetch tile out of range");return r={noClip:!0,...r},this.fetchPixels(s,n.size[0],n.size[1],r)}async identify(e,t={}){e=(0,h.PZ)(f.A,e).clone().normalize();let{multidimensionalDefinition:i,timeExtent:r}=t,{rasterInfo:n}=this,{hasMultidimensionalTranspose:l,multidimensionalInfo:s}=n,{transposedVariableName:a}=t,o=null!=s&&l&&(null!=r||(0,g.DY)(i));o&&!a&&(a=null!=i&&i.length>0?i[0].variableName??void 0:s.variables[0].name,t={...t,transposedVariableName:a}),t=this._getRequestOptionsWithSliceId(t);let{spatialReference:u,extent:c}=n,{datumTransformation:p}=t,x=(0,y._I)(e,u,p);if(!c.intersects(x))return{location:x,value:null};if(null!=n.transform){let e=n.transform.inverseTransform(x);if(!n.nativeExtent.intersects(e))return{location:e,value:null};x=e}let w=null!=a&&null!=s&&n.hasMultidimensionalTranspose;if((0,m.qg)(this)){let e=this.primaryRasters.rasters[0];if(w)return e.identify(x,t);let{pixelSize:r}=n,l=3*r.x/2,s=3*r.y/2,a=new d.A({xmin:x.x-l,xmax:x.x+l,ymin:x.y-s,ymax:x.y+s,spatialReference:u}),o={interpolation:"nearest",multidimensionalDefinition:i,sliceId:t.sliceId,bandIds:t.bandIds},{pixelBlock:c}=await e.fetchPixels(a,3,3,o),{pixelBlock:h}=await this.fetchPixels(a,3,3,o);if(null==c)return{location:x,value:null};let f,p=!c.mask||c.mask[4]?c.pixels.map(e=>e[4]):null;return null!=h&&(f=!h.mask||h.mask[4]?h.pixels.map(e=>e[4]):void 0),{location:x,value:p,processedValue:f,pyramidLevel:0}}let R=0;if(!w){let{srcResolution:i}=t;if(i)i.spatialReference&&(i=(0,C.T5)(new f.A(i),u)),R=(0,y.t$)(i,n,this.ioConfig.sampling).pyramidLevel;else if(R=await this.computeBestPyramidLevelForLocation(e,t),null==R)return{location:x,value:null}}let b=this.identifyPixelLocation(x,R,null,w);if(null===b)return{location:x,value:null};let{row:I,col:v,rowOffset:_,colOffset:S,blockWidth:k}=b,M=await this._fetchRawTile(R,I,v,t);if(!M?.pixels?.length)return{location:x,value:null};let T=_*k+S;return this._processIdentifyResult(M,{srcLocation:x,position:T,pyramidLevel:R,useTransposedTile:!!w,requestSomeSlices:o,identifyOptions:t})}async fetchPixels(e,t,i,r={}){e=(0,y.Ps)(e),r=this._getRequestOptionsWithSliceId(r);let{_hasNoneOrGCSShiftTransform:n}=this;if(r.requestRawData&&n)return this._fetchPixels(e,t,i,r);let l=(0,y.FT)(e.spatialReference),s=(0,y.OM)(e);if(null==l||0===s||1===s&&this._isGlobalWrappableSource&&n)return this._fetchPixels(e,t,i,r);if(s>=3)return{extent:e,pixelBlock:null};let a=[],{xmin:o,xmax:u}=e,c=Math.round(l/(u-o)*t),h=c-Math.round((l/2-o)/(u-o)*t),f=0,p=[];for(let n=0;n<=s;n++){let m=0===n?o:-l/2,g=n===s?u-l*n:l/2,y=new d.A({xmin:m,xmax:g,ymin:e.ymin,ymax:e.ymax,spatialReference:e.spatialReference}),x=0===n?c-h:n===s?t-f:c;f+=x,p.push(x);let w=r.disableWrapAround&&n>0?null:this._fetchPixels(y,x,i,r);a.push(w)}let m=(await Promise.all(a)).map(e=>e?.pixelBlock),g=null,x={width:t,height:i};return g=this.rasterJobHandler?(await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:m,srcMosaicSize:x,destDimension:null,coefs:null,sampleSpacing:null,interpolation:"nearest",alignmentInfo:null,blockWidths:p},r)).pixelBlock:(0,k.z7)(m,x,{blockWidths:p}),{extent:e,srcExtent:(0,y._l)(e,this.rasterInfo.spatialReference,r.datumTransformation),pixelBlock:g}}async fetchRawPixels(e,t,i,r={}){t={x:Math.floor(t.x),y:Math.floor(t.y)};let n=await this._fetchRawTiles(e,t,i,r),{nativeExtent:l,nativePixelSize:s,storageInfo:a}=this.rasterInfo,o=2**e,u=s.x*o,c=s.y*o,h=new d.A({xmin:l.xmin+u*t.x,xmax:l.xmin+u*(t.x+i.width-1),ymin:l.ymax-c*(t.y+i.height-1),ymax:l.ymax-c*t.y,spatialReference:l.spatialReference});if(!n)return{extent:h,srcExtent:h,pixelBlock:null};let{pixelBlocks:f,mosaicSize:p}=n;if(1===f.length&&null!=f[0]&&f[0].width===i.width&&f[0].height===i.height)return{extent:h,srcExtent:h,pixelBlock:n.pixelBlocks[0]};let m,g=e>0?a.pyramidBlockWidth:a.blockWidth,y=e>0?a.pyramidBlockHeight:a.blockHeight,x={x:t.x%g,y:t.y%y};return m=this.rasterJobHandler?(await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:f,srcMosaicSize:p,destDimension:i,clipOffset:x,clipSize:i,coefs:null,sampleSpacing:null,interpolation:r.interpolation,alignmentInfo:null,blockWidths:null},r)).pixelBlock:(0,k.z7)(f,p,{clipOffset:x,clipSize:i}),{extent:h,srcExtent:h,pixelBlock:m}}fetchRawTile(e,t,i,r){throw new l.A("BaseRaster:read-not-implemented","fetchRawTile() is not implemented")}computeExtent(e){return(0,y._l)(this.rasterInfo.extent,e)}decodePixelBlock(e,t,i){return this.rasterJobHandler?this.rasterJobHandler.decode({data:e,options:t},i):(0,S.D)(e,t,i)}async request(e,t,i=0){let{customFetchParameters:r}=this.ioConfig,{range:l,query:s,headers:a}=t;i=i??t.retryCount??this.ioConfig.retryCount;let o=l?{Range:`bytes=${l.from}-${l.to}`}:null;try{return await(0,n.A)(e,{...t,query:{...s,...r},headers:{...a,...o}})}catch(r){if(i>0)return i--,this.request(e,t,i);throw r}}getSliceIndex(e){let{multidimensionalInfo:t}=this.rasterInfo;return null==t||null==e||0===e.length?null:(0,g.NG)(e,t)}getTileExtentFromTileInfo(e,t,i,r){let n=r.lodAt(e);return n?this.getTileExtent({x:n.resolution,y:n.resolution},t,i,r.origin,r.spatialReference,r.size):null}updateTileInfo(){let{storageInfo:e,spatialReference:t,extent:i,pixelSize:r}=this.rasterInfo,{pyramidResolutions:n}=e;if(!e.tileInfo){let l=[],s=e.maximumPyramidLevel||0,a=(r.x+r.y)/2,o=1/.0254*96*a;for(let e=0;e<=s&&(l.unshift(new F.A({level:s-e,resolution:a,scale:o})),e!==s);e++)if(n){let t=(n[e].x+n[e].y)/2;o*=t/a,a=t}else a*=2,o*=2;let u=new f.A({x:i.xmin,y:i.ymax,spatialReference:t});e.tileInfo=new B.A({origin:u,size:[e.blockWidth,e.blockHeight],spatialReference:t,lods:l}),e.isVirtualTileInfo=!0}}createRemoteDatasetStorageInfo(e,t=512,i=512,r){let{width:n,height:l,nativeExtent:s,pixelSize:a,spatialReference:o}=e,u=new f.A({x:s.xmin,y:s.ymax,spatialReference:o});r??=Math.max(0,Math.round(Math.log(Math.max(n,l))/Math.LN2-8));let c=this.computeBlockBoundary(s,t,i,{x:s.xmin,y:s.ymax},[a],r);e.storageInfo=new z.A({blockWidth:t,blockHeight:i,pyramidBlockWidth:t,pyramidBlockHeight:i,origin:u,firstPyramidLevel:1,maximumPyramidLevel:r,blockBoundary:c})}async computeBestPyramidLevelForLocation(e,t={}){return 0}computeBlockBoundary(e,t,i,r,n,l=0,s=2){if(1===n.length&&l>0){n=[...n];let{x:e,y:t}=n[0];for(let i=0;i<l;i++)e*=s,t*=s,n.push({x:e,y:t})}let a=[],{x:o,y:u}=r;for(let r=0;r<n.length;r++){let{x:l,y:s}=n[r];a.push({minCol:Math.floor((e.xmin-o+.1*l)/t/l),maxCol:Math.floor((e.xmax-o-.1*l)/t/l),minRow:Math.floor((u-e.ymax+.1*s)/i/s),maxRow:Math.floor((u-e.ymin-.1*s)/i/s)})}return a}getPyramidPixelSize(e){let{nativePixelSize:t}=this.rasterInfo,{pyramidResolutions:i,pyramidScalingFactor:r}=this.rasterInfo.storageInfo;if(0===e)return t;if(null!=i&&i.length)return i[e-1];let n=r**e;return{x:t.x*n,y:t.y*n}}identifyPixelLocation(e,t,i,r){let{spatialReference:n,nativeExtent:l,storageInfo:s}=this.rasterInfo,{maximumPyramidLevel:a,origin:o,transposeInfo:u}=s,c=r&&null!=u?u.tileSize[0]:s.blockWidth,h=r&&null!=u?u.tileSize[1]:s.blockHeight,d=(0,y._I)(e,n,i);if(!l.intersects(d)||t<0||t>a)return null;let{x:f,y:p}=this.getPyramidPixelSize(t),m=(o.y-d.y)/p/h,g=(d.x-o.x)/f/c,x=Math.min(h-1,Math.floor((m-Math.floor(m))*h)),w=Math.min(c-1,Math.floor((g-Math.floor(g))*c));return{pyramidLevel:t,row:Math.floor(m),col:Math.floor(g),rowOffset:x,colOffset:w,blockWidth:c,srcLocation:d}}getTileExtent(e,t,i,r,n,l){let[s,a]=l,o=r.x+i*s*e.x,u=o+s*e.x,c=r.y-t*a*e.y,h=c-a*e.y;return new d.A({xmin:o,xmax:u,ymin:h,ymax:c,spatialReference:n})}getBlockWidthHeight(e){return{blockWidth:e>0?this.rasterInfo.storageInfo.pyramidBlockWidth:this.rasterInfo.storageInfo.blockWidth,blockHeight:e>0?this.rasterInfo.storageInfo.pyramidBlockHeight:this.rasterInfo.storageInfo.blockHeight}}isBlockOutside(e,t,i){let r=this.rasterInfo.storageInfo.blockBoundary[e];return!r||r.maxRow<t||r.maxCol<i||r.minRow>t||r.minCol>i}updateImageSpaceRasterInfo(e){let{pixelSize:t}=e,{width:i,height:r}=e,n=p.A.WebMercator;e.spatialReference=n,e.extent=e.nativeExtent=new d.A({xmin:-.5,ymax:.5,xmax:i-.5,ymin:.5-r,spatialReference:n}),e.isPseudoSpatialReference=!0,e.transform=null,e.pixelSize=new f.A({x:1,y:1,spatialReference:n});let{extent:l,storageInfo:s}=e;if(s){s.origin=new f.A({x:l.xmin,y:l.ymax,spatialReference:n});let{pyramidResolutions:i,tileInfo:r}=s;if(i&&i.forEach(e=>{e.x/=t.x,e.y/=t.y}),r){r.origin=s.origin;let t=(e.nativePixelSize.x+e.nativePixelSize.y)/2;r.lods.forEach((e,i)=>{e.resolution=t*2**i,e.scale=96*e.resolution/.0254})}}}async _refresh(e){return{dataChanged:!0}}async _fetchPixels(e,t,i,r={}){let n=(0,y.OM)(e);if(n>=2)return{extent:e,pixelBlock:null};let l=this._getSourceDataInfo(e,t,i,r),{pyramidLevel:s,srcResolution:a,srcWidth:o,srcHeight:u,ul:c}=l,{srcExtent:h}=l;if(0===o||0===u)return{extent:e,srcExtent:h,pixelBlock:null};let{rasterInfo:d}=this,p=d.transform,m="gcs-shift"===p?.type,g=null!=(0,y.FT)(e.spatialReference);(m||!g)&&(n=(0,y.OM)(h,m));let x=await this._fetchRawTiles(s,c,{width:o,height:u,wrapCount:n},r);if(!x)return{extent:e,srcExtent:h,pixelBlock:null};h=x.extent;let w=d.storageInfo,R=s>0?w.pyramidBlockWidth:w.blockWidth,b=s>0?w.pyramidBlockHeight:w.blockHeight,{x:I,y:v}=d.pixelSize;if(s>0){let{pyramidResolutions:e,pyramidScalingFactor:t}=w;if(null!=e&&e[s-1])({x:I,y:v}=e[s-1]);else{let e=t**s;I*=e,v*=e}}let _=d.spatialReference,S=new f.A({x:I,y:v,spatialReference:_}),C=R===o&&b===u&&c.x%R===0&&c.y%b===0,T=new f.A({x:(e.xmax-e.xmin)/t,y:(e.ymax-e.ymin)/i,spatialReference:e.spatialReference}),A=!e.spatialReference.equals(_),P=_.isGeographic?1e-9:1e-4,{datumTransformation:F}=r;if(!A&&C&&1===x.pixelBlocks.length&&R===t&&b===i&&function(e,t,i){return Math.abs(e.x-t.x)<i&&Math.abs(e.y-t.y)<i}(a,T,P))return{extent:e,srcExtent:h,srcTilePixelSize:S,pixelBlock:x.pixelBlocks[0]};let z=g&&null!=(0,y.FT)(h.spatialReference)&&this._hasNoneOrGCSShiftTransform,B=r.requestProjectedLocalDirections&&this.rasterInfo.dataType.startsWith("vector");B&&!this.rasterJobHandler&&await(0,y.Hh)();let D,J=this.rasterJobHandler?await this.rasterJobHandler.getProjectionOffsetGrid({projectedExtent:e,srcBufferExtent:h,pixelSize:T.toJSON(),datumTransformation:F,rasterTransform:p,hasWrapAround:n>0||z,isAdaptive:!1!==this.ioConfig.optimizeProjectionAccuracy,includeGCSGrid:B},r):(0,y.l0)({projectedExtent:e,srcBufferExtent:h,pixelSize:T,datumTransformation:F,rasterTransform:p,hasWrapAround:n>0||z,isAdaptive:!1,includeGCSGrid:B}),H=!r.requestRawData,N={rows:J.spacing[0],cols:J.spacing[1]},O=this._hasNoneOrGCSShiftTransform?this._getRasterTileAlignmentInfo(s,h.xmin):void 0,{pixelBlocks:E,mosaicSize:Z,isPartiallyFilled:L}=x,W=null;if(this.rasterJobHandler){let e=await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:E,srcMosaicSize:Z,destDimension:H?{width:t,height:i}:null,coefs:H?J.coefficients:null,sampleSpacing:H?N:null,projectDirections:B,gcsGrid:B?J.gcsGrid:null,isUV:"vector-uv"===this.rasterInfo.dataType,interpolation:r.interpolation,alignmentInfo:O,blockWidths:null},r);({pixelBlock:D,localNorthDirections:W}=e)}else{let e=(0,k.z7)(E,Z,{alignmentInfo:O});D=H?(0,k.$i)(e,{width:t,height:i},J.coefficients,N,r.interpolation):e,B&&J.gcsGrid&&(W=(0,k.QF)({width:t,height:i},J.gcsGrid),D=(0,M.Y2)(D,this.rasterInfo.dataType,W))}return r.requestRawData||B?{extent:e,srcExtent:h,srcTilePixelSize:S,pixelBlock:D,transformGrid:J,localNorthDirections:W,isPartiallyFilled:L}:{extent:e,srcExtent:e,srcTilePixelSize:S,pixelBlock:D}}async _fetchRawTiles(e,t,i,r){let{origin:n,blockBoundary:l}=this.rasterInfo.storageInfo,{blockWidth:s,blockHeight:a}=this.getBlockWidthHeight(e),{x:o,y:u}=t,{width:c,height:h,wrapCount:f}=i,p=this._getRasterTileAlignmentInfo(e,0);r.buffer&&(o-=r.buffer.cols,u-=r.buffer.rows,c+=2*r.buffer.cols,h+=2*r.buffer.rows);let m=0,g=0,y=0;f&&null!=p&&(({worldColumnCountFromOrigin:g,originColumnOffset:y,rightPadding:m}=p),g*p.blockWidth-m>=o+c&&(m=0));let x=Math.floor(o/s),w=Math.floor(u/a),R=Math.floor((o+c+m-1)/s),b=Math.floor((u+h+m-1)/a),I=l[e];if(!I)return null;let{minRow:v,minCol:_,maxCol:S,maxRow:C}=I;if(0===f&&(b<v||R<_||w>C||x>S))return null;let k=[],M=!1,T=null==this.ioConfig.allowPartialFill?r.allowPartialFill:this.ioConfig.allowPartialFill;for(let t=w;t<=b;t++)for(let i=x;i<=R;i++){let n=i;if(!r.disableWrapAround&&f&&null!=p&&g<=i&&(n=i-g-y),t>=v&&n>=_&&C>=t&&S>=n){let i=this._fetchRawTile(e,t,n,r);T?k.push(new Promise(e=>{i.then(t=>e(t)).catch(()=>{M=!0,e(null)})})):k.push(i)}else k.push(Promise.resolve(null))}if(0===k.length)return null;let A=await Promise.all(k),P={height:(b-w+1)*a,width:(R-x+1)*s},{spatialReference:F}=this.rasterInfo,{x:z,y:B}=this.getPyramidPixelSize(e);return{extent:new d.A({xmin:n.x+x*s*z,xmax:n.x+(R+1)*s*z,ymin:n.y-(b+1)*a*B,ymax:n.y-w*a*B,spatialReference:F}),pixelBlocks:A,mosaicSize:P,isPartiallyFilled:M}}_fetchRawTile(e,t,i,r){let{storageInfo:n}=this.rasterInfo,l=null!=n.transposeInfo&&!!r.transposedVariableName;if(!l){let r=n.blockBoundary[e];if(!r)return Promise.resolve(null);let{minRow:l,minCol:s,maxCol:a,maxRow:o}=r;if(t<l||i<s||t>o||i>a)return Promise.resolve(null)}let s=l?r.transposeVariableName:r.sliceId,a=n.isBsqTile?r.bandIds:null,u=function(e,t,i){let r=[];return null!=t&&r.push(`sliceId=${t}`),null!=i&&r.push(`bandIds=${i.join(",")}`),r.length?`${e}?${r.join("&")}`:e}(this.rasterId,s,a),c=`${e}/${t}/${i}`,h=b(u,r.registryId,c);if(null==h){let l=new AbortController,s=r.bandIds?.slice();if(s?.length&&n.isBsqTile){let n=new Set(s),a=[],o=Array.from(n);for(let n of o)a.push(this._tileFetchQueue.push({pyramidLevel:e,row:t,col:i,options:{...r,bandIds:[n]}},{signal:l.signal}));h=Promise.all(a).then(e=>{if(e.some(e=>null==e))return null;if(o.length!==s.length){let t=[];for(let i of s){let r=e[o.indexOf(i)];t.includes(r)&&(r=r.clone()),t.push(r)}e=t}return this.rasterJobHandler?this.rasterJobHandler.compositeBands({pixelBlocks:e},{signal:l.signal,transferPixelsToWorker:!0}):(0,k.Wy)(e)})}else h=this._tileFetchQueue.push({pyramidLevel:e,row:t,col:i,options:r},{signal:l.signal});I(u,r.registryId,c,h,l),h.catch(()=>v(u,r.registryId,c))}return r.signal&&(0,o.u7)(r,()=>{R(u,r.registryId,c)}),h}_computeMagDirValues(e){let{bandCount:t,dataType:i}=this.rasterInfo;if((2!==t||"vector-magdir"!==i)&&"vector-uv"!==i||2!==e?.length||!e[0]?.length)return null;let r=e[0].length;if("vector-magdir"===i){let t=e[1].map(e=>(e+360)%360);return[e[0],t]}let[n,l]=e,s=[],a=[];for(let e=0;e<r;e++){let[t,i]=(0,M.Lu)([n[e],l[e]]);s.push(t),a.push(i)}return[s,a]}_getRasterTileAlignmentInfo(e,t){return this._rasterTileAlignmentInfo??=(0,y.DO)(this.rasterInfo),null==this._rasterTileAlignmentInfo.pyramidsInfo?null:{startX:t,halfWorldWidth:this._rasterTileAlignmentInfo.halfWorldWidth,hasGCSSShiftTransform:this._rasterTileAlignmentInfo.hasGCSSShiftTransform,...this._rasterTileAlignmentInfo.pyramidsInfo[e]}}_getSourceDataInfo(e,t,i,r={}){let n={datumTransformation:r.datumTransformation,pyramidLevel:0,pyramidResolution:null,srcExtent:null,srcHeight:0,srcResolution:null,srcWidth:0,ul:{x:0,y:0}};r.srcResolution&&(n.srcResolution=r.srcResolution,this._updateSourceDataInfo(e,n));let l=this.rasterInfo.storageInfo.maximumPyramidLevel||0,{srcWidth:s,srcHeight:a,pyramidLevel:o}=n,u=s/t,c=a/i,h=o<l&&u*c>=16,d=o===l&&this._requireTooManySrcTiles(s,a,t,i);if(h||d||0===s||0===a){let s=new f.A({x:(e.xmax-e.xmin)/t,y:(e.ymax-e.ymin)/i,spatialReference:e.spatialReference}),a=(0,y.Wo)(s,this.rasterInfo.spatialReference,e,n.datumTransformation),d=!a||r.srcResolution&&a.x+a.y<r.srcResolution.x+r.srcResolution.y;if(h&&r.srcResolution&&d){let e=Math.round(Math.log(Math.max(u,c))/Math.LN2)-1;if(l-o+3>=e){let t=2**e;a={x:r.srcResolution.x*t,y:r.srcResolution.y*t}}}a&&(n.srcResolution=a,this._updateSourceDataInfo(e,n))}return this._requireTooManySrcTiles(n.srcWidth,n.srcHeight,t,i)&&(n.srcWidth=0,n.srcHeight=0),n}_requireTooManySrcTiles(e,t,i,r){let{tileInfo:n}=this.rasterInfo.storageInfo,l=e/i,s=t/r;return Math.ceil(e/n.size[0])*Math.ceil(t/n.size[1])>=256*Math.max(1,(i+r)/1024)||l>8||s>8}_updateSourceDataInfo(e,t){t.srcWidth=0,t.srcHeight=0;let{rasterInfo:i}=this,r=i.spatialReference,{srcResolution:n,datumTransformation:l}=t,{pyramidLevel:s,pyramidResolution:a,excessiveReading:o}=(0,y.t$)(n,i,this.ioConfig.sampling);if(o)return;let u=t.srcExtent||(0,y._l)(e,r,l);if(null==u)return;let c=i.transform;c&&(u=c.inverseTransform(u)),t.srcExtent=u;let{origin:h}=i.storageInfo,{width:d,height:f,ul:p}=(0,m.$g)(u,h,a,s);t.pyramidLevel=s,t.pyramidResolution=a,t.srcWidth=d,t.srcHeight=f,t.ul=p}_getRequestOptionsWithSliceId(e){return null!=this.rasterInfo.multidimensionalInfo&&null==e.sliceId&&(e={...e,sliceId:this.getSliceIndex(e.multidimensionalDefinition)}),e}_processIdentifyResult(e,t){let{srcLocation:i,position:r,pyramidLevel:n,useTransposedTile:l}=t,s=e.pixels[0].length/e.width/e.height;if(e.mask&&!e.mask[r])return{location:i,value:null};let{multidimensionalInfo:a}=this.rasterInfo;if(null==a||!l){let t=e.pixels.map(e=>e[r]),l={location:i,value:t,pyramidLevel:n},s=this._computeMagDirValues(t.map(e=>[e]));return s?.length&&(l.magdirValue=s.map(e=>e[0])),l}let o=e.pixels.map(e=>e.slice(r*s,r*s+s)),u=this._computeMagDirValues(o),{requestSomeSlices:c,identifyOptions:h}=t,d=(0,g.QW)(a,h.transposedVariableName);if(c){let e=(0,g.xx)(d,h.multidimensionalDefinition,h.timeExtent);o=o.map(t=>e.map(e=>t[e])),u=u?.map(t=>e.map(e=>t[e])),d=e.map(e=>d[e])}let f,p=e.noDataValues||this.rasterInfo.noDataValue,m={pixels:o,pixelType:e.pixelType};return null!=p&&((0,_.Sp)(m,p),f=m.mask),{location:i,value:null,dataSeries:d.map((e,t)=>{let i={value:0===f?.[t]?null:o.map(e=>e[t]),multidimensionalDefinition:e.multidimensionalDefinition.map(e=>new P.A({...e,isSlice:!0}))};return u?.length&&(i.magdirValue=[u[0][t],u[1][t]]),i}),pyramidLevel:n}}};(0,r.Cg)([(0,c.MZ)()],J.prototype,"_rasterTileAlignmentInfo",void 0),(0,r.Cg)([(0,c.MZ)()],J.prototype,"_tileFetchQueue",void 0),(0,r.Cg)([(0,c.MZ)({readOnly:!0})],J.prototype,"_isGlobalWrappableSource",null),(0,r.Cg)([(0,c.MZ)({readOnly:!0})],J.prototype,"_hasNoneOrGCSShiftTransform",null),(0,r.Cg)([(0,c.MZ)()],J.prototype,"_openPromise",void 0),(0,r.Cg)([(0,c.MZ)()],J.prototype,"rasterJobHandler",null),(0,r.Cg)([(0,c.MZ)({readOnly:!0})],J.prototype,"rasterId",null),(0,r.Cg)([(0,c.MZ)(A.OZ)],J.prototype,"url",null),(0,r.Cg)([(0,c.MZ)({type:String,json:{write:!0}})],J.prototype,"datasetName",void 0),(0,r.Cg)([(0,c.MZ)({type:String,json:{write:!0}})],J.prototype,"datasetFormat",void 0),(0,r.Cg)([(0,c.MZ)()],J.prototype,"hasUniqueSourceStorageInfo",void 0),(0,r.Cg)([(0,c.MZ)()],J.prototype,"rasterInfo",void 0),(0,r.Cg)([(0,c.MZ)()],J.prototype,"ioConfig",void 0),(0,r.Cg)([(0,c.MZ)()],J.prototype,"sourceJSON",void 0),(0,r.Cg)([(0,c.MZ)()],J.prototype,"rawBlockRegistryIds",void 0),J=(0,r.Cg)([(0,c.$K)("esri.layers.raster.datasets.BaseRaster")],J)},23636(e,t,i){i.d(t,{A:()=>p});var r=i(32198),n=i(49186),l=i(91429),s=i(5443),a=i(86738),o=i(39829),u=i(49859),c=i(34930),h=i(47520),d=i(37373),f=i(22671);let p=class extends u.A{constructor(){super(...arguments),this.datasetFormat="Function",this.tileType="Raster",this.rasterFunction=null,this._clippingGeometry=new Map}async fetchPixels(e,t,i,r={}){let{rasters:n}=this.primaryRasters,l=!1,{interpolation:s}=r,a=this.rasterFunction.flatWebGLFunctionChain?.hasFocalFunction;!r.requestRawData&&a&&(l=1===n.length&&!r.skipRasterFunction,r={...r,interpolation:"bilinear",requestRawData:l}),r.requestRawData&&n.length>1&&!this.hasUniqueSourceStorageInfo&&(l=!1,r={...r,requestRawData:!1});let o=n.map(n=>n.fetchPixels(e,t,i,r)),u=await Promise.all(o),d=u.map(e=>e.pixelBlock),f=l||r.requestRawData?u.map(e=>e.srcTilePixelSize):void 0;if(r.skipRasterFunction||d.every(e=>null==e))return u[0];let p=u.find(e=>null!=e.pixelBlock)?.extent??e,m=await this._processPixelBlock(d,p,f),{transformGrid:g}=u[0];if(!l||null==m||null==g){let e=r.noClip?null:this.getClippingGeometry(p.spatialReference);return!r.noClip&&null!=m&&e&&(m=await(0,c.$Q)(m,p,e)),{...u[0],pixelBlock:m}}let y,x={rows:g.spacing[0],cols:g.spacing[1]};y=this.rasterJobHandler?(await this.rasterJobHandler.mosaicAndTransform({srcPixelBlocks:[m],srcMosaicSize:{width:m.width,height:m.height},destDimension:{width:t,height:i},coefs:g.coefficients,sampleSpacing:x,projectDirections:!1,gcsGrid:null,isUV:!1,interpolation:s,alignmentInfo:void 0,blockWidths:null},r)).pixelBlock:(0,h.$i)(m,{width:t,height:i},g.coefficients,x,s);let w=r.noClip?null:this.getClippingGeometry(e.spatialReference);return!r.noClip&&null!=y&&null!=w&&(y=await(0,c.$Q)(y,e,w)),{extent:e,srcExtent:u[0].srcExtent,pixelBlock:y,srcTilePixelSize:u[0].srcTilePixelSize}}async processOnePixel(e,t){let{extent:i,pixelBlock:r}=t;if(!r)return null;let{row:n,col:l}=e,{width:a,height:o}=r;if(n<0||n>=o||l<0||l>=a)return null;let{neighborhoodSize:u}=this.rasterFunction,c=Math.max(2,u.rows),d=Math.max(2,u.cols),f=d>>>1,p=c>>>1,m={x:Math.max(0,l-f),y:Math.max(0,n-p)},g=i.width/a,y=i.height/o,x=i.xmin+g*m.x,w=x+g*d,R=i.ymax-y*m.y,b=R-y*c,I=new s.A({xmin:x,ymin:b,xmax:w,ymax:R,spatialReference:i.spatialReference}),v=(0,h.$Q)(r,m,{width:d,height:c});if(null==v)return null;let _=await this.processPixelData({extent:I,pixelBlock:v}),S=(n-m.y)*d+(l-m.x);return _&&0!==_.mask?.[S]?_.pixels.map(e=>e[S]):null}async processPixelData(e){let{extent:t,pixelBlock:i}=e;if(!i)return null;let r=new a.A({x:t.width/i.width,y:t.height/i.height,spatialReference:t.spatialReference});return await this._processPixelBlock([i],t,[r])}getClippingGeometry(e){let t=this._clippingGeometry.get("0");if(!e||!t)return t;let i=function(e){return String(e.wkid??e.wkt??e.wkt2)}(e),r=this._clippingGeometry.get(i);return r??(r=e.equals(t.spatialReference)?t:(0,d.uk)(t,e),this._clippingGeometry.set(i,r)),r}async _open(e){let{rasterFunction:t}=this;t.isRoot=!0,this.primaryRasters?.rasters?.length?t.sourceRasters=this.primaryRasters.rasters:(this.primaryRasters=t.getPrimaryRasters(),this.rasterJobHandler&&this.primaryRasters.rasters?.forEach(e=>e.rasterJobHandler=this.rasterJobHandler));let{rasters:i,rasterIds:r}=this.primaryRasters,l=i.map(t=>t.rasterInfo?void 0:t.open(e));await Promise.all(l);let s=i.map(({rasterInfo:e})=>e),a=t.bind({rasterInfos:s,rasterIds:r});if(t.rawSourceRasterInfos=s,!a.success||0===s.length)throw new n.A("raster-function:open",`cannot bind the function: ${a.error??""}`);let o="Table"===t.functionName?t:t.functionArguments?.raster;"Table"===o?.functionName&&(t.rasterInfo.attributeTable=f.A.fromJSON(o.functionArguments.attributeTableAsRecordSet)),await this.syncJobHandler();let u=s[0];this.hasUniqueSourceStorageInfo=1===s.length||s.slice(1).every(e=>function(e,t){let{storageInfo:i,pixelSize:r,spatialReference:n,extent:l}=e,{storageInfo:s,pixelSize:a,spatialReference:o,extent:u}=t;return r.x===a.x&&r.y===a.y&&n.equals(o)&&l.equals(u)&&i.blockHeight===s.blockHeight&&i.blockWidth===s.blockWidth&&i.maximumPyramidLevel===s.maximumPyramidLevel&&i.firstPyramidLevel===s.firstPyramidLevel&&i.pyramidBlockWidth===s.pyramidBlockWidth&&i.pyramidBlockHeight===s.pyramidBlockHeight&&i.pyramidScalingFactor===s.pyramidScalingFactor}(e,u)),this.set("sourceJSON",i[0].sourceJSON),this.set("rasterInfo",t.rasterInfo),await this._updateClipGeometry()}async syncJobHandler(){return this.rasterJobHandler?.updateRasterFunction(this.rasterFunction)}async _processPixelBlock(e,t,i){let{processParameters:r,primaryRasters:{rasterIds:n}}=this;return this.rasterJobHandler?await this.rasterJobHandler.process({extent:t,primaryPixelBlocks:e,primaryPixelSizes:i,primaryRasterIds:n,parameters:r}):this.rasterFunction.process({extent:t,primaryPixelBlocks:e,primaryPixelSizes:i,primaryRasterIds:n},r)}async _updateClipGeometry(){let e=this.rasterFunction.getClippingGeometries()[0],t=e?.clippingGeometry;if(t&&"inside"===e.clippingType){let{extent:e}=this.rasterInfo,{densifyExecute:r}=await Promise.all([i.e(9187),i.e(8885),i.e(9117),i.e(3299),i.e(4642)]).then(()=>i(88411)),{differenceExecute:n}=await Promise.all([i.e(9187),i.e(8885),i.e(9117),i.e(3299),i.e(7217)]).then(()=>i(93054)),l=r(o.A.fromExtent(e),2*(e.width+e.height)/40);l=(0,d.uk)(l,t.spatialReference),t=n(l,t)}this._clippingGeometry.clear(),t&&this._clippingGeometry.set("0",t)}};(0,r.Cg)([(0,l.MZ)({type:String,json:{write:!0}})],p.prototype,"datasetFormat",void 0),(0,r.Cg)([(0,l.MZ)()],p.prototype,"tileType",void 0),(0,r.Cg)([(0,l.MZ)()],p.prototype,"rasterFunction",void 0),(0,r.Cg)([(0,l.MZ)()],p.prototype,"processParameters",void 0),(0,r.Cg)([(0,l.MZ)()],p.prototype,"primaryRasters",void 0),p=(0,r.Cg)([(0,l.$K)("esri.layers.raster.datasets.FunctionRaster")],p)},330(e,t,i){function r(e,t){if(!e||!t)return[];let i=t;t.includes("/")?(i=t.slice(0,t.indexOf("/")),t=t.slice(t.indexOf("/")+1)):t="";let n=[];if(t){let l=r(e,i);for(let e=0;e<l.length;e++)r(l[e],t).forEach(e=>n.push(e));return n}let l=e.getElementsByTagNameNS("*",i);if(!l||0===l.length)return[];for(let e=0;e<l.length;e++)n.push(l[e]||l.item(e));return n}function n(e,t){if(!e||!t)return null;let i=t;t.includes("/")?(i=t.slice(0,t.indexOf("/")),t=t.slice(t.indexOf("/")+1)):t="";let l=r(e,i);return l.length>0?t?n(l[0],t):l[0]:null}function l(e,t=null){let i,r=t?n(e,t):e;return r?(i=r.textContent||r.nodeValue,i?i.trim():null):null}function s(e,t){let i,n=r(e,t),l=[];for(let e=0;e<n.length;e++)i=n[e].textContent||n[e].nodeValue,i&&(i=i.trim(),""!==i&&l.push(i));return l}function a(e,t=null){return l(e,t)?.split(" ").map(e=>Number(e))??[]}function o(e,t){return s(e,t).map(e=>Number(e))}function u(e,t){let i=l(e,t);return Number(i)}function c(e,t){let i=e?.nodeName?.toLowerCase(),r=t.toLowerCase();return i.slice(i.lastIndexOf(":")+1)===r}function h(e){return e.nodeName.slice(e.nodeName.lastIndexOf(":")+1)}i.d(t,{Dy:()=>s,IC:()=>r,Ui:()=>o,V6:()=>n,g7:()=>c,mX:()=>l,pN:()=>a,v7:()=>u,vv:()=>h})},91806(e,t,i){i.d(t,{A:()=>o});var r,n=i(32198),l=i(25482),s=i(91429),a=i(78888);let o=class extends l.o{static{r=this}constructor(e){super(e),this.cols=null,this.level=0,this.levelValue=null,this.origin=null,this.resolution=0,this.rows=null,this.scale=0}clone(){return new r({cols:this.cols,level:this.level,levelValue:this.levelValue,resolution:this.resolution,rows:this.rows,scale:this.scale})}};(0,n.Cg)([(0,s.MZ)({json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],o.prototype,"cols",void 0),(0,n.Cg)([(0,s.MZ)({type:a.jz,json:{write:!0}})],o.prototype,"level",void 0),(0,n.Cg)([(0,s.MZ)({type:String,json:{write:!0}})],o.prototype,"levelValue",void 0),(0,n.Cg)([(0,s.MZ)({json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],o.prototype,"origin",void 0),(0,n.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],o.prototype,"resolution",void 0),(0,n.Cg)([(0,s.MZ)({json:{write:!0,origins:{"web-document":{read:!1,write:!1},"portal-item":{read:!1,write:!1}}}})],o.prototype,"rows",void 0),(0,n.Cg)([(0,s.MZ)({type:Number,json:{write:!0}})],o.prototype,"scale",void 0),o=r=(0,n.Cg)([(0,s.$K)("esri.layers.support.LOD")],o)},87045(e,t,i){i.d(t,{A:()=>w});var r,n=i(32198),l=i(66552),s=i(25482),a=i(86211),o=i(91429),u=i(78888),c=i(86738),h=i(16930),d=i(21325),f=i(28735),p=i(91806),m=i(72802),g=i(36005),y=i(43937);const x=new l.J({PNG:"png",PNG8:"png8",PNG24:"png24",PNG32:"png32",JPEG:"jpg",JPG:"jpg",DIB:"dib",TIFF:"tiff",EMF:"emf",PS:"ps",PDF:"pdf",GIF:"gif",SVG:"svg",SVGZ:"svgz",Mixed:"mixed",MIXED:"mixed",LERC:"lerc",LERC2D:"lerc2d",RAW:"raw",JPEGPlus:"jpgplus",pbf:"pbf"});let w=class extends s.o{static{r=this}static create(e={}){let{resolutionFactor:t=1,scales:i,size:n=256,spatialReference:l=h.A.WebMercator,numLODs:s=24}=e;if(!(0,d.fn)(l)){let e=[];if(i)for(let t=0;t<i.length;t++){let r=i[t];e.push(new p.A({level:t,scale:r,resolution:r}))}else{let t=5e-4;for(let i=s-1;i>=0;i--)e.unshift(new p.A({level:i,scale:t,resolution:t})),t*=2}return new r({dpi:96,lods:e,origin:new c.A(0,0,l),size:[n,n],spatialReference:l})}let o=(0,d.Vp)(l),u=e.origin?new c.A({x:e.origin.x,y:e.origin.y,spatialReference:l}):o?new c.A({x:o.origin[0],y:o.origin[1],spatialReference:l}):new c.A({x:0,y:0,spatialReference:l}),f=1/(39.37*(0,a.GA)(l)*96),m=[];if(i)for(let e=0;e<i.length;e++){let t=i[e],r=t*f;m.push(new p.A({level:e,scale:t,resolution:r}))}else{let e=(0,d.EA)(l)?512/n*591657527.5917094:256/n*591657527.591555,i=Math.ceil(s/t);m.push(new p.A({level:0,scale:e,resolution:e*f}));for(let r=1;r<i;r++){let i=e/2**t,n=i*f;m.push(new p.A({level:r,scale:i,resolution:n})),e=i}}return new r({dpi:96,lods:m,origin:u,size:[n,n],spatialReference:l})}constructor(e){super(e),this.dpi=96,this.format=null,this.origin=null,this.size=null,this.spatialReference=null}get isWrappable(){let{spatialReference:e,origin:t}=this;if(e&&t){let i=(0,d.Vp)(e);return e.isWrappable&&!!i&&Math.abs(i.origin[0]-t.x)<=i.dx}return!1}readOrigin(e,t){return c.A.fromJSON({spatialReference:t.spatialReference,...e})}set lods(e){let t=0,i=0,r=[],n=this._levelToLOD={};e&&(t=-1/0,i=1/0,e.forEach(e=>{r.push(e.scale),t=e.scale>t?e.scale:t,i=e.scale<i?e.scale:i,n[e.level]=e})),this._set("scales",r),this._set("lods",e),this._initializeUpsampleLevels()}readSize(e,t){return[t.cols,t.rows]}writeSize(e,t){t.cols=e[0],t.rows=e[1]}zoomToScale(e){let t=this.scales;if(e<=0)return t[0];if(e>=t.length-1)return t[t.length-1];let i=Math.floor(e),r=i+1;return t[i]/(t[i]/t[r])**(e-i)}scaleToZoom(e){let t=this.scales,i=t.length-1,r=0;for(;r<i;r++){let i=t[r],n=t[r+1];if(i<=e)return r;if(n===e)return r+1;if(i>e&&n<e)return r+Math.log(i/e)/Math.log(i/n)}return r}tileAt(e,t,i,r){let n,l,s=this.lodAt(e);if(!s)return null;if("number"==typeof t)n=t,l=i;else if((0,d.aI)(t.spatialReference,this.spatialReference))n=t.x,l=t.y,r=i;else{let e=(0,f.Cv)(t,this.spatialReference);if(null==e)return null;n=e.x,l=e.y,r=i}let a=s.resolution*this.size[0],o=s.resolution*this.size[1];return r??=new m.U(0,0,0),r.level=e,r.row=Math.floor((this.origin.y-l)/o+.001),r.col=Math.floor((n-this.origin.x)/a+.001),this.updateTileInfo(r),r}updateTileInfo(e,t=0){if(!("extent"in e))return!1;let i=this.lodAt(e.level);if(!i&&1===t){let t=this.lods[this.lods.length-1];t.level<e.level&&(i=t)}if(!i)return!1;let r=e.level-i.level,n=i.resolution*this.size[0]/2**r,l=i.resolution*this.size[1]/2**r;return e.extent[0]=this.origin.x+e.col*n,e.extent[1]=this.origin.y-(e.row+1)*l,e.extent[2]=e.extent[0]+n,e.extent[3]=e.extent[1]+l,!0}upsampleTile(e){let t=this._upsampleLevels[e.level];return!(!t||-1===t.parentLevel||(e.level=t.parentLevel,e.row=Math.floor(e.row/t.factor+.001),e.col=Math.floor(e.col/t.factor+.001),this.updateTileInfo(e),0))}getTileBounds(e,t){let i=this.lodAt(t.level);if(null==i)return null;let{resolution:r}=i,n=r*this.size[0],l=r*this.size[1];return e[0]=this.origin.x+t.col*n,e[1]=this.origin.y-(t.row+1)*l,e[2]=e[0]+n,e[3]=e[1]+l,e}lodAt(e){return this._levelToLOD?.[e]??null}clone(){return r.fromJSON(this.write({}))}getCompatibleForVTL(e){if(this.size[0]!==this.size[1]||256===this.size[0]&&512===e)return null;let t=(512===this.size[0]&&256===e?-1:0)+ +!!this.spatialReference.isGeographic;if(this.size[0]===e&&0===t)return this;let i=[],n=this.lods.length-t;for(let e=0;e<n;e++){let r=e+t,{scale:n,resolution:l}=r>=0?this.lods[r]:{scale:2*this.lods[0].scale,resolution:2*this.lods[0].resolution};i.push(new p.A({level:e,scale:n,resolution:l}))}return new r({size:[e,e],dpi:this.dpi,format:this.format,compressionQuality:this.compressionQuality,origin:this.origin,spatialReference:this.spatialReference,lods:i})}_initializeUpsampleLevels(){let e=this.lods;this._upsampleLevels=[];let t=null;for(let i=0;i<e.length;i++){let r=e[i];this._upsampleLevels[r.level]={parentLevel:t?t.level:-1,factor:t?t.resolution/r.resolution:0},t=r}}};(0,n.Cg)([(0,o.MZ)({type:Number,json:{write:!0}})],w.prototype,"compressionQuality",void 0),(0,n.Cg)([(0,o.MZ)({type:Number,json:{write:!0}})],w.prototype,"dpi",void 0),(0,n.Cg)([(0,o.MZ)({type:String,json:{read:x.read,write:x.write,origins:{"web-scene":{read:!1,write:!1}}}})],w.prototype,"format",void 0),(0,n.Cg)([(0,o.MZ)({readOnly:!0})],w.prototype,"isWrappable",null),(0,n.Cg)([(0,o.MZ)({type:c.A,json:{write:!0}})],w.prototype,"origin",void 0),(0,n.Cg)([(0,g.w)("origin")],w.prototype,"readOrigin",null),(0,n.Cg)([(0,o.MZ)({type:[p.A],value:null,json:{write:!0}})],w.prototype,"lods",null),(0,n.Cg)([(0,o.MZ)({readOnly:!0})],w.prototype,"scales",void 0),(0,n.Cg)([(0,o.MZ)({cast:e=>Array.isArray(e)?e:"number"==typeof e?[e,e]:[256,256]})],w.prototype,"size",void 0),(0,n.Cg)([(0,g.w)("size",["rows","cols"])],w.prototype,"readSize",null),(0,n.Cg)([(0,y.K)("size",{cols:{type:u.jz},rows:{type:u.jz}})],w.prototype,"writeSize",null),(0,n.Cg)([(0,o.MZ)({type:h.A,json:{write:!0}})],w.prototype,"spatialReference",void 0),w=r=(0,n.Cg)([(0,o.$K)("esri.layers.support.TileInfo")],w)},72802(e,t,i){i.d(t,{U:()=>n});var r=i(19419);class n{constructor(e,t,i,n=(0,r.vt)()){this._level=e,this._row=t,this._col=i,this.extent=n}get id(){return this._id??=`${this.level}/${this.row}/${this.col}`,this._id}get level(){return this._level}set level(e){this._level=e,this._id=null}get row(){return this._row}set row(e){this._row=e,this._id=null}get col(){return this._col}set col(e){this._col=e,this._id=null}toJSON(){return{level:this._level,row:this._row,col:this._col,extent:this.extent}}static fromJSON(e){return new n(e.level,e.row,e.col,e.extent)}}}}]);
|