@arcgis/core 4.25.0-next.20220705 → 4.25.0-next.20220708

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (336) hide show
  1. package/TimeExtent.js +1 -1
  2. package/arcade/arcadeCompiler.js +1 -1
  3. package/assets/esri/core/workers/RemoteClient.js +1 -1
  4. package/assets/esri/core/workers/chunks/0703495557b0df6878c5.js +1 -0
  5. package/assets/esri/core/workers/chunks/1570676351a313f1841b.js +1 -0
  6. package/assets/esri/core/workers/chunks/{695f90305478f5024fa7.js → 1ecbf642debc2207b762.js} +1 -1
  7. package/assets/esri/core/workers/chunks/{30dbdf2aa1bc8e61cad4.js → 268e7b46202fc1decf9f.js} +1 -1
  8. package/assets/esri/core/workers/chunks/{47d78b4f7117554acecf.js → 357a27203f5d8fa152de.js} +1 -1
  9. package/assets/esri/core/workers/chunks/35dfba25a9077ab5dbaf.js +982 -0
  10. package/assets/esri/core/workers/chunks/377354a81e402edf3077.js +1 -0
  11. package/assets/esri/core/workers/chunks/3a42d96ea3b59d33bfe8.js +1 -0
  12. package/assets/esri/core/workers/chunks/3a61e4ab83183f5526a7.js +1 -0
  13. package/assets/esri/core/workers/chunks/{3790f0362b6f27ee798b.js → 3ee5e8d00cd3bc47a9fa.js} +1 -1
  14. package/assets/esri/core/workers/chunks/425d1fabc713a598139c.js +1 -0
  15. package/assets/esri/core/workers/chunks/425e16862feccb467191.js +1 -0
  16. package/assets/esri/core/workers/chunks/{bbe51b49fe7093e47306.js → 48c8ac9a22190c2b890c.js} +1 -1
  17. package/assets/esri/core/workers/chunks/4a364bc073fdc7c1b563.js +1 -0
  18. package/assets/esri/core/workers/chunks/4ca6ada7a4ccde5b5a24.js +1 -0
  19. package/assets/esri/core/workers/chunks/{905130ff0118962c8140.js → 61b71b8e028eda10ccab.js} +1 -1
  20. package/assets/esri/core/workers/chunks/{b34cffd5c45d3a8134bc.js → 69f57ad2227e59b323e8.js} +1 -1
  21. package/assets/esri/core/workers/chunks/{290899b47a52f8b28a9c.js → 791220164501a791b2cd.js} +1 -1
  22. package/assets/esri/core/workers/chunks/792b4b0a43b4bbbc14ab.js +1 -0
  23. package/assets/esri/core/workers/chunks/7b32b8e8ebe48ae0dae2.js +1 -0
  24. package/assets/esri/core/workers/chunks/7f00125b02bb7211de43.js +1 -0
  25. package/assets/esri/core/workers/chunks/81074accfce5f109f909.js +1 -0
  26. package/assets/esri/core/workers/chunks/{594d7fdb80ad9cdedb85.js → 823e25dbc70e71257b6e.js} +1 -1
  27. package/assets/esri/core/workers/chunks/92e43e05265dfc8173a0.js +1 -0
  28. package/assets/esri/core/workers/chunks/{40fa9b28ca882a70813a.js → 92f7415c2e40e320addc.js} +1 -1
  29. package/assets/esri/core/workers/chunks/{9520b32d5d53ea9cd0d3.js → 9341e9e1fe0f6800aa44.js} +1 -1
  30. package/assets/esri/core/workers/chunks/95451d6405729a9f50c7.js +1 -0
  31. package/assets/esri/core/workers/chunks/{910a2ffb4328f8ee7a0d.js → 95cb9cd08941c28ebd85.js} +1 -1
  32. package/assets/esri/core/workers/chunks/{97f32af5893c86f6444c.js → 9b9a40b84640f00a1dcb.js} +1 -1
  33. package/assets/esri/core/workers/chunks/{77c6ba5ea85915d9078c.js → ac07c732aca6e67232f8.js} +1 -1
  34. package/assets/esri/core/workers/chunks/ae8e87da97411cff3783.js +1 -0
  35. package/assets/esri/core/workers/chunks/{65161a874595b0a34aa1.js → b312dd3027492007d75e.js} +1 -1
  36. package/assets/esri/core/workers/chunks/{83c9da68d6dbc77f60e5.js → beead2b06c994b4e61af.js} +1 -1
  37. package/assets/esri/core/workers/chunks/{5e20fd8b7c9497f2da1f.js → bfb08d3e2208c6178af9.js} +1 -1
  38. package/assets/esri/core/workers/chunks/{04e5486f0d8d4c6bd8a2.js → c3236a7058e64ea3b939.js} +1 -1
  39. package/assets/esri/core/workers/chunks/c4e9c71be6299c60c539.js +1 -0
  40. package/assets/esri/core/workers/chunks/c705f907ce60a646d9aa.js +1 -0
  41. package/assets/esri/core/workers/chunks/ce6abfafa0171b9c8d81.js +1 -0
  42. package/assets/esri/core/workers/chunks/{08a5c5a33a7c7c6852e5.js → d00b0f8236f1526099d4.js} +1 -1
  43. package/assets/esri/core/workers/chunks/d13951412a57e1af6208.js +1 -0
  44. package/assets/esri/core/workers/chunks/ecaf8f030026e41e1d1a.js +1 -0
  45. package/assets/esri/core/workers/chunks/f328a6cd4b7d8c653fc7.js +1 -0
  46. package/assets/esri/core/workers/chunks/f6a6178d4df029ff010d.js +1 -0
  47. package/assets/esri/core/workers/chunks/fde2301c6cd97a3cfb86.js +1 -0
  48. package/assets/esri/core/workers/chunks/fe84bcdfd9028b5e7ef6.js +1 -0
  49. package/assets/esri/themes/base/widgets/_BasemapLayerList.scss +4 -0
  50. package/assets/esri/themes/base/widgets/_LayerList.scss +4 -0
  51. package/assets/esri/themes/dark/main.css +1 -1
  52. package/assets/esri/themes/light/main.css +1 -1
  53. package/assets/esri/themes/light/view.css +1 -1
  54. package/chunks/CheckerBoard.glsl.js +2 -2
  55. package/chunks/ColorMaterial.glsl.js +9 -9
  56. package/chunks/ComponentShader.glsl.js +33 -33
  57. package/chunks/DefaultMaterial.glsl.js +35 -35
  58. package/chunks/HUDMaterial.glsl.js +11 -11
  59. package/chunks/ImageMaterial.glsl.js +5 -5
  60. package/chunks/LineMarker.glsl.js +17 -17
  61. package/chunks/NativeLine.glsl.js +3 -3
  62. package/chunks/Path.glsl.js +28 -28
  63. package/chunks/Pattern.glsl.js +9 -9
  64. package/chunks/PointRenderer.glsl.js +1 -1
  65. package/chunks/RealisticTree.glsl.js +4 -4
  66. package/chunks/RibbonLine.glsl.js +1 -1
  67. package/chunks/ShadedColorMaterial.glsl.js +1 -1
  68. package/chunks/SimpleAtmosphere.glsl.js +1 -1
  69. package/chunks/Terrain.glsl.js +92 -92
  70. package/chunks/WaterSurface.glsl.js +22 -22
  71. package/chunks/common.js +1 -1
  72. package/chunks/mat2.js +1 -1
  73. package/chunks/mat2d.js +1 -1
  74. package/chunks/mat3.js +1 -1
  75. package/chunks/mat4.js +1 -1
  76. package/chunks/quat.js +1 -1
  77. package/chunks/quat2.js +1 -1
  78. package/chunks/vec2.js +1 -1
  79. package/chunks/vec3.js +1 -1
  80. package/chunks/vec4.js +1 -1
  81. package/core/Message.js +1 -1
  82. package/core/accessorSupport/tracking.js +1 -1
  83. package/core/libs/gl-matrix-2/math/common.js +1 -1
  84. package/core/libs/gl-matrix-2/math/vec2.js +1 -1
  85. package/core/pbf.js +1 -1
  86. package/core/quantity.js +0 -1
  87. package/core/sql/WhereClause.js +1 -1
  88. package/core/urlUtils.js +1 -1
  89. package/geometry/support/scaleUtils.js +1 -1
  90. package/identity/IdentityForm.js +1 -1
  91. package/identity/IdentityModal.js +1 -1
  92. package/identity/OAuthCredential.js +1 -1
  93. package/interfaces.d.ts +3347 -190
  94. package/intl/date.js +1 -1
  95. package/intl/duration.js +1 -1
  96. package/intl/messages.js +1 -1
  97. package/intl/substitute.js +1 -1
  98. package/kernel.js +1 -1
  99. package/layers/ImageryTileLayer.js +1 -1
  100. package/layers/VoxelWasmPerSceneView.js +1 -1
  101. package/layers/mixins/ArcGISImageService.js +1 -1
  102. package/layers/mixins/ImageryTileMixin.js +1 -1
  103. package/layers/support/ControlPointsGeoreference.d.ts +4 -0
  104. package/layers/support/ControlPointsGeoreference.js +5 -0
  105. package/layers/support/CornersGeoreference.js +1 -1
  106. package/layers/support/ElevationSamplerData.js +5 -0
  107. package/layers/support/ElevationTile.js +1 -1
  108. package/layers/support/ExportImageServiceParameters.js +1 -1
  109. package/layers/support/MediaElementBase.js +1 -1
  110. package/layers/support/imageryRendererUtils.js +1 -1
  111. package/layers/support/rasterDatasets/TIFFRaster.js +1 -1
  112. package/package.json +1 -1
  113. package/renderers/support/RasterSymbolizer.js +1 -1
  114. package/request.js +1 -1
  115. package/rest/route/utils.js +1 -1
  116. package/rest/serviceArea.js +1 -1
  117. package/rest/support/ServiceAreaParameters.js +1 -1
  118. package/rest/support/ServiceAreaSolveResult.js +1 -1
  119. package/smartMapping/raster/renderers/classBreaks.js +1 -1
  120. package/smartMapping/raster/renderers/uniqueValue.js +1 -1
  121. package/support/apiKeyUtils.js +1 -1
  122. package/support/requestUtils.js +1 -1
  123. package/support/revision.js +1 -1
  124. package/views/2d/layers/MapNotesLayerView2D.js +1 -1
  125. package/views/2d/navigation/actions/Pinch.js +1 -1
  126. package/views/2d/tiling/TileCache.js +1 -1
  127. package/views/2d/viewpointUtils.js +1 -1
  128. package/views/3d/environment/ChapmanAtmosphereTechnique.js +1 -1
  129. package/views/3d/environment/CloudsCompositionTechnique.js +1 -1
  130. package/views/3d/environment/CloudsTechnique.js +1 -1
  131. package/views/3d/environment/EnvironmentRenderer.js +1 -1
  132. package/views/3d/environment/FogTechnique.js +1 -1
  133. package/views/3d/environment/NoiseTextureAtlasTechnique.js +1 -1
  134. package/views/3d/environment/Precipitation.js +1 -1
  135. package/views/3d/environment/PrecipitationTechnique.js +1 -1
  136. package/views/3d/environment/SimpleAtmosphereTechnique.js +1 -1
  137. package/views/3d/environment/SimpleAtmosphereTechniqueConfiguration.js +1 -1
  138. package/views/3d/environment/StarsTechnique.js +1 -1
  139. package/views/3d/externalRenderers/ExternalRendererStore.js +1 -1
  140. package/views/3d/interactive/Manipulator3D.js +1 -1
  141. package/views/3d/interactive/visualElements/LabelVisualElement.js +1 -1
  142. package/views/3d/interactive/visualElements/ParallelLineVisualElement.js +1 -1
  143. package/views/3d/layers/FeatureLayerViewBase3D.js +1 -1
  144. package/views/3d/layers/FeatureLikeLayerView3D.js +1 -1
  145. package/views/3d/layers/ImageryLayerView3D.js +1 -1
  146. package/views/3d/layers/SceneLayerGraphicsView3D.js +1 -1
  147. package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
  148. package/views/3d/layers/graphics/Graphics3DFeatureProcessor.js +1 -1
  149. package/views/3d/layers/i3s/PointRenderer.js +1 -1
  150. package/views/3d/layers/support/FeatureVisibilityFilter.js +5 -0
  151. package/views/3d/layers/support/HeatmapFeatureProcessor.js +1 -1
  152. package/views/3d/state/ViewStateManager.js +1 -1
  153. package/views/3d/support/LaserlinePathData.js +1 -1
  154. package/views/3d/support/ResourceController.js +1 -1
  155. package/views/3d/terrain/BlendLayersTechnique.js +1 -1
  156. package/views/3d/terrain/ElevationData.js +1 -1
  157. package/views/3d/terrain/GeometryState.js +1 -1
  158. package/views/3d/terrain/OverlayRenderTarget.js +1 -1
  159. package/views/3d/terrain/OverlayRenderer.js +1 -1
  160. package/views/3d/terrain/PatchGeometryFactory.js +1 -1
  161. package/views/3d/terrain/PatchRenderData.js +1 -1
  162. package/views/3d/terrain/RasterColorizerTechnique.js +1 -1
  163. package/views/3d/terrain/TerrainConst.js +1 -1
  164. package/views/3d/terrain/TerrainRenderer.js +1 -1
  165. package/views/3d/terrain/TerrainSurface.js +1 -1
  166. package/views/3d/terrain/Tile.js +1 -1
  167. package/views/3d/terrain/tileUtils.js +1 -1
  168. package/views/3d/webgl-engine/collections/Component/ComponentObjectCollection.js +1 -1
  169. package/views/3d/webgl-engine/collections/Component/Material/ComponentMaterial.js +1 -1
  170. package/views/3d/webgl-engine/collections/Component/Material/ComponentTechnique.js +1 -1
  171. package/views/3d/webgl-engine/collections/Component/Material/ComponentTechniqueConfiguration.js +1 -1
  172. package/views/3d/webgl-engine/collections/Component/Material/shader/ComponentShader.glsl.js +1 -1
  173. package/views/3d/webgl-engine/core/renderPasses/RenderPass.js +1 -1
  174. package/views/3d/webgl-engine/core/renderPasses/RenderPassManager.js +1 -1
  175. package/views/3d/webgl-engine/core/shaderLibrary/ForwardLinearDepth.glsl.js +2 -2
  176. package/views/3d/webgl-engine/core/shaderLibrary/ShaderOutput.js +5 -0
  177. package/views/3d/webgl-engine/core/shaderLibrary/ShaderOutputConfiguration.js +5 -0
  178. package/views/3d/webgl-engine/core/shaderLibrary/Transform.glsl.js +4 -4
  179. package/views/3d/webgl-engine/core/shaderLibrary/attributes/InstancedDoublePrecision.glsl.js +11 -11
  180. package/views/3d/webgl-engine/core/shaderLibrary/attributes/TextureCoordinateAttribute.glsl.js +1 -1
  181. package/views/3d/webgl-engine/core/shaderLibrary/default/DefaultMaterialAuxiliaryPasses.glsl.js +55 -55
  182. package/views/3d/webgl-engine/core/shaderLibrary/output/OutputDepth.glsl.js +3 -3
  183. package/views/3d/webgl-engine/core/shaderLibrary/terrain/Terrain.glsl.js +1 -1
  184. package/views/3d/webgl-engine/core/shaderTechnique/ShaderTechnique.js +1 -1
  185. package/views/3d/webgl-engine/lib/BlendWeightsTechnique.js +1 -1
  186. package/views/3d/webgl-engine/lib/BlurTechnique.js +1 -1
  187. package/views/3d/webgl-engine/lib/Camera.js +1 -1
  188. package/views/3d/webgl-engine/lib/DrapedHeatmapRenderer.js +1 -1
  189. package/views/3d/webgl-engine/lib/EdgeDetectTechnique.js +1 -1
  190. package/views/3d/webgl-engine/lib/GLMaterialRepository.js +1 -1
  191. package/views/3d/webgl-engine/lib/GLMaterials.js +1 -1
  192. package/views/3d/webgl-engine/lib/Material.js +1 -1
  193. package/views/3d/webgl-engine/lib/OffscreenRendering.js +1 -1
  194. package/views/3d/webgl-engine/lib/OrderIndependentTransparency.js +1 -1
  195. package/views/3d/webgl-engine/lib/RenderContext.js +1 -1
  196. package/views/3d/webgl-engine/lib/Renderer.js +1 -1
  197. package/views/3d/webgl-engine/lib/RenderingContext.js +1 -1
  198. package/views/3d/webgl-engine/lib/SSAOTechnique.js +1 -1
  199. package/views/3d/webgl-engine/lib/ShadowAccumulator.js +1 -1
  200. package/views/3d/webgl-engine/lib/ShadowMap.js +1 -1
  201. package/views/3d/webgl-engine/lib/SortedRenderGeometryRenderer.js +1 -1
  202. package/views/3d/webgl-engine/lib/TextureTechnique.js +1 -1
  203. package/views/3d/webgl-engine/lib/TransparencyPassType.js +5 -0
  204. package/views/3d/webgl-engine/lib/basicInterfaces.js +1 -1
  205. package/views/3d/webgl-engine/lib/edgeRendering/EdgeShaderTechnique.js +1 -1
  206. package/views/3d/webgl-engine/lib/lodRendering/LodRenderer.js +1 -1
  207. package/views/3d/webgl-engine/lib/pathGeometryUtils.js +1 -1
  208. package/views/3d/webgl-engine/materials/CheckerBoardMaterial.js +1 -1
  209. package/views/3d/webgl-engine/materials/ColorMaterial.js +1 -1
  210. package/views/3d/webgl-engine/materials/DefaultMaterial.js +1 -1
  211. package/views/3d/webgl-engine/materials/DefaultTechniqueConfiguration.js +1 -1
  212. package/views/3d/webgl-engine/materials/HUDMaterial.js +1 -1
  213. package/views/3d/webgl-engine/materials/HeatmapDensityMaterial.js +1 -1
  214. package/views/3d/webgl-engine/materials/ImageMaterial.js +1 -1
  215. package/views/3d/webgl-engine/materials/LineCalloutMaterial.js +1 -1
  216. package/views/3d/webgl-engine/materials/LineMarkerMaterial.js +1 -1
  217. package/views/3d/webgl-engine/materials/MeasurementArrowMaterial.js +1 -1
  218. package/views/3d/webgl-engine/materials/NativeLineMaterial.js +1 -1
  219. package/views/3d/webgl-engine/materials/PathMaterial.js +1 -1
  220. package/views/3d/webgl-engine/materials/PathTechnique.js +1 -1
  221. package/views/3d/webgl-engine/materials/PatternMaterial.js +1 -1
  222. package/views/3d/webgl-engine/materials/RibbonLineMaterial.js +1 -1
  223. package/views/3d/webgl-engine/materials/ShadedColorMaterial.js +1 -1
  224. package/views/3d/webgl-engine/materials/SlicePlaneMaterial.js +1 -1
  225. package/views/3d/webgl-engine/materials/WaterGLMaterial.js +1 -1
  226. package/views/3d/webgl-engine/materials/WaterMaterial.js +1 -1
  227. package/views/3d/webgl-engine/materials/WaterTechnique.js +1 -1
  228. package/views/3d/webgl-engine/materials/renderers/MergedRenderer.js +1 -1
  229. package/views/3d/webgl-engine/shaders/CheckerBoard.glsl.js +1 -1
  230. package/views/3d/webgl-engine/shaders/CheckerBoardTechnique.js +1 -1
  231. package/views/3d/webgl-engine/shaders/CheckerBoardTechniqueConfiguration.js +1 -1
  232. package/views/3d/webgl-engine/shaders/ColorMaterial.glsl.js +1 -1
  233. package/views/3d/webgl-engine/shaders/ColorMaterialTechnique.js +1 -1
  234. package/views/3d/webgl-engine/shaders/ColorMaterialTechniqueConfiguration.js +1 -1
  235. package/views/3d/webgl-engine/shaders/CompositingTechnique.js +1 -1
  236. package/views/3d/webgl-engine/shaders/DefaultMaterial.glsl.js +1 -1
  237. package/views/3d/webgl-engine/shaders/DefaultMaterialTechnique.js +1 -1
  238. package/views/3d/webgl-engine/shaders/DefaultMaterialTechniqueConfiguration.js +1 -1
  239. package/views/3d/webgl-engine/shaders/HUDMaterial.glsl.js +1 -1
  240. package/views/3d/webgl-engine/shaders/HUDMaterialTechnique.js +1 -1
  241. package/views/3d/webgl-engine/shaders/HUDMaterialTechniqueConfiguration.js +1 -1
  242. package/views/3d/webgl-engine/shaders/HeatmapDensityTechnique.js +1 -1
  243. package/views/3d/webgl-engine/shaders/HeatmapTechnique.js +1 -1
  244. package/views/3d/webgl-engine/shaders/HighlightApplyTechnique.js +1 -1
  245. package/views/3d/webgl-engine/shaders/HighlightBlurTechnique.js +1 -1
  246. package/views/3d/webgl-engine/shaders/HighlightDownsampleTechnique.js +1 -1
  247. package/views/3d/webgl-engine/shaders/ImageMaterial.glsl.js +1 -1
  248. package/views/3d/webgl-engine/shaders/ImageMaterialTechnique.js +1 -1
  249. package/views/3d/webgl-engine/shaders/LaserlinePathTechnique.js +1 -1
  250. package/views/3d/webgl-engine/shaders/LaserlineTechnique.js +1 -1
  251. package/views/3d/webgl-engine/shaders/LineCalloutTechnique.js +1 -1
  252. package/views/3d/webgl-engine/shaders/LineMarker.glsl.js +1 -1
  253. package/views/3d/webgl-engine/shaders/LineMarkerTechnique.js +1 -1
  254. package/views/3d/webgl-engine/shaders/LineMarkerTechniqueConfiguration.js +1 -1
  255. package/views/3d/webgl-engine/shaders/MeasurementArrowTechnique.js +1 -1
  256. package/views/3d/webgl-engine/shaders/NativeLine.glsl.js +1 -1
  257. package/views/3d/webgl-engine/shaders/NativeLineTechnique.js +1 -1
  258. package/views/3d/webgl-engine/shaders/NativeLineTechniqueConfiguration.js +1 -1
  259. package/views/3d/webgl-engine/shaders/Path.glsl.js +1 -1
  260. package/views/3d/webgl-engine/shaders/Pattern.glsl.js +1 -1
  261. package/views/3d/webgl-engine/shaders/PatternTechnique.js +1 -1
  262. package/views/3d/webgl-engine/shaders/PointRenderer.glsl.js +1 -1
  263. package/views/3d/webgl-engine/shaders/PointRendererTechnique.js +1 -1
  264. package/views/3d/webgl-engine/shaders/PointRendererTechniqueConfiguration.js +1 -1
  265. package/views/3d/webgl-engine/shaders/RealisticTree.glsl.js +1 -1
  266. package/views/3d/webgl-engine/shaders/RibbonLine.glsl.js +1 -1
  267. package/views/3d/webgl-engine/shaders/RibbonLineTechnique.js +1 -1
  268. package/views/3d/webgl-engine/shaders/RibbonLineTechniqueConfiguration.js +1 -1
  269. package/views/3d/webgl-engine/shaders/ShadedColorMaterial.glsl.js +1 -1
  270. package/views/3d/webgl-engine/shaders/ShadedColorMaterialTechnique.js +1 -1
  271. package/views/3d/webgl-engine/shaders/ShadowCastAccumulateTechnique.js +1 -1
  272. package/views/3d/webgl-engine/shaders/ShadowCastVisualizeTechnique.js +1 -1
  273. package/views/3d/webgl-engine/shaders/ShadowHighlightTechnique.js +1 -1
  274. package/views/3d/webgl-engine/shaders/SlicePlaneMaterialTechnique.js +1 -1
  275. package/views/3d/webgl-engine/shaders/TerrainTechnique.js +1 -1
  276. package/views/3d/webgl-engine/shaders/TerrainTechniqueConfiguration.js +1 -1
  277. package/views/3d/webgl-engine/shaders/WaterSurface.glsl.js +1 -1
  278. package/views/SceneView.js +1 -1
  279. package/views/draw/support/Reshape.js +1 -1
  280. package/views/interactive/GraphicManipulator.js +1 -1
  281. package/views/interactive/SegmentLabels.js +1 -1
  282. package/views/interactive/coordinateHelper.js +1 -1
  283. package/views/interactive/editGeometry/support/editPlaneUtils.js +1 -1
  284. package/views/interactive/snapping/ParallelLineSnapper.js +1 -1
  285. package/views/interactive/snapping/RightAngleTriangleSnapper.js +1 -1
  286. package/views/interactive/snapping/SnappingConstraint.js +1 -1
  287. package/views/interactive/snapping/SnappingManager.js +1 -1
  288. package/views/interactive/snapping/candidates/ParallelLineSnappingCandidate.js +1 -1
  289. package/views/interactive/snapping/candidates/RightAngleTriangleSnappingCandidate.js +1 -1
  290. package/views/interactive/snapping/snappingUtils.js +1 -1
  291. package/views/interactive/support/viewUtils.js +1 -1
  292. package/views/layers/ImageryTileLayerView.js +1 -1
  293. package/views/support/geometry2dUtils.js +1 -1
  294. package/webscene/Slide.js +1 -1
  295. package/widgets/BasemapLayerList.js +1 -1
  296. package/widgets/ElevationProfile/support/geometryUtils.js +1 -1
  297. package/widgets/ElevationProfile.js +1 -1
  298. package/widgets/LayerList/ListItemPanel.js +1 -1
  299. package/widgets/LayerList.js +1 -1
  300. package/widgets/Widget.js +1 -1
  301. package/widgets/Zoom/ZoomConditions3D.js +1 -1
  302. package/widgets/Zoom/ZoomViewModel.js +1 -1
  303. package/widgets/Zoom.js +1 -1
  304. package/widgets/support/widgetUtils.js +1 -1
  305. package/assets/esri/core/workers/chunks/06a7f58260225f52f8e6.js +0 -1
  306. package/assets/esri/core/workers/chunks/0e00741d35cdbf48e72d.js +0 -1
  307. package/assets/esri/core/workers/chunks/1ebb29ceabc81509646c.js +0 -1
  308. package/assets/esri/core/workers/chunks/24f7a3df08c3a2d3795c.js +0 -1
  309. package/assets/esri/core/workers/chunks/39a754713a48d46618bd.js +0 -1
  310. package/assets/esri/core/workers/chunks/462163f31fa134b7b216.js +0 -1
  311. package/assets/esri/core/workers/chunks/4bfcb7350ca492767a45.js +0 -1
  312. package/assets/esri/core/workers/chunks/5470cb0c3f670957c22c.js +0 -1
  313. package/assets/esri/core/workers/chunks/6889d698a2c796ed1ce6.js +0 -1
  314. package/assets/esri/core/workers/chunks/869310ef4c98542bf9df.js +0 -1
  315. package/assets/esri/core/workers/chunks/8ebaad46e2fe8925e3b0.js +0 -1
  316. package/assets/esri/core/workers/chunks/98c519ac806cc55bc19b.js +0 -1
  317. package/assets/esri/core/workers/chunks/9d07969fbea13aa5b03c.js +0 -1
  318. package/assets/esri/core/workers/chunks/9e6ce879ec0da884b9b8.js +0 -1
  319. package/assets/esri/core/workers/chunks/abd1bd74ba571e39ab5a.js +0 -1
  320. package/assets/esri/core/workers/chunks/b26ea76e3f41b45756e0.js +0 -1
  321. package/assets/esri/core/workers/chunks/c2286d97539066c8549a.js +0 -1
  322. package/assets/esri/core/workers/chunks/c495a66978d67c7e17f3.js +0 -1
  323. package/assets/esri/core/workers/chunks/c7fa92daca3f6e91734e.js +0 -987
  324. package/assets/esri/core/workers/chunks/c9e890b4be9d01c13efe.js +0 -1
  325. package/assets/esri/core/workers/chunks/dda5ea7f8d35e257815c.js +0 -1
  326. package/assets/esri/core/workers/chunks/e153e89c8a15c2f036ef.js +0 -1
  327. package/assets/esri/core/workers/chunks/e201ffcca7321771ee20.js +0 -1
  328. package/assets/esri/core/workers/chunks/e5b5b93e707173a4c883.js +0 -1
  329. package/assets/esri/core/workers/chunks/f7d1f75b6aa3ef566d74.js +0 -1
  330. package/assets/esri/core/workers/chunks/fde9e9683335fa6c8236.js +0 -1
  331. package/core/queryUtils.js +0 -5
  332. package/views/3d/layers/graphics/Graphics3DFilterVisibility.js +0 -5
  333. package/views/3d/layers/support/HeatmapFilterVisibility.js +0 -5
  334. package/views/3d/webgl-engine/core/shaderLibrary/ShaderOutputOptions.js +0 -5
  335. package/views/3d/webgl-engine/core/shaderLibrary/util/HeaderComment.glsl.js +0 -10
  336. package/views/3d/webgl-engine/lib/RenderPass.js +0 -5
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{isSome as s}from"../../../../../core/maybe.js";import{f as a,t as e,g as t}from"../../../../../chunks/mat3.js";import{c as r}from"../../../../../chunks/mat3f64.js";import{c as i}from"../../../../../chunks/mat4.js";import{s as h,c as m}from"../../../../../chunks/vec3.js";import{c as n}from"../../../../../chunks/vec3f64.js";import{MaterialPassParameters as P,ShadowMapPassParameters as o,HighlightPassParameters as _,MaterialSubPass as p,RenderPassIdentifier as l}from"./AllRenderPasses.js";import{RenderPass as A,RenderPassSorting as d}from"./RenderPass.js";import{TwoVectorPosition as c}from"../util/TwoVectorPosition.js";import{union as T}from"../../lib/depthRange.js";import{RenderPass as u}from"../../lib/RenderPass.js";import{RenderSlot as R}from"../../lib/RenderSlot.js";class M{constructor(s,a){this.rctx=s,this.shaderTechniqueRepository=a,this.canRender=!0,this._materialPassParameters=new P,this._shadowPassParameters=new o,this._highlightPassParameters=new _,this._systems=new Set,this._passes={materialOpaque:new A(s,a),materialTransparent:new A(s,a,d.BackToFront),materialIntegratedMesh:new A(s,a),shadowMap:new A(s,a),highlight:new A(s,a),highlightIntegratedMesh:new A(s,a),highlightShadowMap:new A(s,a),defaultShadowMap:new A(s,a)}}register(s){this._systems.add(s)}prepareRender(s){if(0!==this._systems.size){for(const s of Object.values(this._passes))s.prepareSubmit();this._systems.forEach((a=>a.submit(this._passes,s.bindParameters)));for(const s of Object.values(this._passes))s.finishSubmit();this.shaderTechniqueRepository.frameUpdate()}}render(s){if(0!==this._systems.size)switch(this._configure(s),s.bindParameters.slot){case R.OPAQUE_MATERIAL:switch(s.pass){case u.MATERIAL:return this._materialPassParameters.subPass=p.Color,this._passes.materialOpaque.dispatch(this._materialPassParameters,s.bindParameters);case u.MATERIAL_DEPTH:return this._materialPassParameters.subPass=p.Depth,this._passes.materialOpaque.dispatch(this._materialPassParameters,s.bindParameters);case u.MATERIAL_NORMAL:return this._materialPassParameters.subPass=p.Normal,this._passes.materialOpaque.dispatch(this._materialPassParameters,s.bindParameters);case u.MATERIAL_HIGHLIGHT:return this._passes.highlight.dispatch(this._highlightPassParameters,s.bindParameters);case u.MATERIAL_DEPTH_SHADOWMAP_ALL:return this._passes.shadowMap.dispatch(this._shadowPassParameters,s.bindParameters);case u.MATERIAL_DEPTH_SHADOWMAP_HIGHLIGHT:return this._passes.highlightShadowMap.dispatch(this._shadowPassParameters,s.bindParameters);case u.MATERIAL_DEPTH_SHADOWMAP_DEFAULT:return this._passes.defaultShadowMap.dispatch(this._shadowPassParameters,s.bindParameters)}return;case R.TRANSPARENT_MATERIAL:switch(s.pass){case u.MATERIAL:return this._materialPassParameters.subPass=p.Color,this._passes.materialTransparent.dispatch(this._materialPassParameters,s.bindParameters);case u.MATERIAL_ALPHA:return this._materialPassParameters.subPass=p.Alpha,this._passes.materialTransparent.dispatch(this._materialPassParameters,s.bindParameters);case u.MATERIAL_DEPTH:return this._materialPassParameters.subPass=p.Depth,this._passes.materialTransparent.dispatch(this._materialPassParameters,s.bindParameters);case u.MATERIAL_NORMAL:return this._materialPassParameters.subPass=p.Normal,this._passes.materialTransparent.dispatch(this._materialPassParameters,s.bindParameters)}return;case R.INTEGRATED_MESH:switch(s.pass){case u.MATERIAL:return this._materialPassParameters.subPass=p.Color,this._passes.materialIntegratedMesh.dispatch(this._materialPassParameters,s.bindParameters);case u.MATERIAL_DEPTH:return this._materialPassParameters.subPass=p.Depth,this._passes.materialIntegratedMesh.dispatch(this._materialPassParameters,s.bindParameters);case u.MATERIAL_NORMAL:return this._materialPassParameters.subPass=p.Normal,this._passes.materialIntegratedMesh.dispatch(this._materialPassParameters,s.bindParameters);case u.MATERIAL_HIGHLIGHT:return this._passes.highlightIntegratedMesh.dispatch(this._highlightPassParameters,s.bindParameters)}return}}notifyDirty(){this._context.requestRender()}slots(){return[R.OPAQUE_MATERIAL,R.TRANSPARENT_MATERIAL,R.INTEGRATED_MESH]}initializeRenderContext(s){this._context=s}uninitializeRenderContext(){}queryDepthRange(a){const e={near:1/0,far:-1/0};return this._systems.forEach((t=>{const r=t.queryShadowCasterDepthRange(a);s(r)&&T(e,r,e)})),e}_configure(s){const a=s.pass===u.MATERIAL_DEPTH_SHADOWMAP_ALL||s.pass===u.MATERIAL_DEPTH_SHADOWMAP_HIGHLIGHT||s.pass===u.MATERIAL_DEPTH_SHADOWMAP_DEFAULT?this._shadowPassParameters:s.pass===u.MATERIAL_HIGHLIGHT?this._highlightPassParameters:this._materialPassParameters;this._updateParameters(s,a)}_updateParameters(s,r){const n=s.bindParameters.camera,P=n.viewInverseTransposeMatrix;h(E,P[3],P[7],P[11]),I.set(E),m(r.transformWorldFromViewTH,I.high),m(r.transformWorldFromViewTL,I.low),m(r.slicePlaneLocalOrigin,E),a(r.transformViewFromCameraRelativeRS,n.viewMatrix),i(r.transformProjFromView,n.projectionMatrix),r.identifier===l.Material&&(this._materialPassParameters.transparent=s.bindParameters.slot===R.TRANSPARENT_MATERIAL,this._materialPassParameters.integratedMesh=s.bindParameters.slot===R.INTEGRATED_MESH,e(g,r.transformViewFromCameraRelativeRS),t(r.transformNormalViewFromGlobal,g))}get needsHighlight(){return this._passes.highlight.count>0||this._passes.highlightIntegratedMesh.count>0}get needsTransparentPass(){return this._passes.materialTransparent.count>0}}const E=n(),g=r(),I=new c;export{M as RenderPassManager};
5
+ import{isSome as s}from"../../../../../core/maybe.js";import{f as a,t as e,g as t}from"../../../../../chunks/mat3.js";import{c as r}from"../../../../../chunks/mat3f64.js";import{c as i}from"../../../../../chunks/mat4.js";import{s as h,c as m}from"../../../../../chunks/vec3.js";import{c as n}from"../../../../../chunks/vec3f64.js";import{MaterialPassParameters as o,ShadowMapPassParameters as P,HighlightPassParameters as l,MaterialSubPass as p,RenderPassIdentifier as d}from"./AllRenderPasses.js";import{RenderPass as u,RenderPassSorting as c}from"./RenderPass.js";import{ShaderOutput as _}from"../shaderLibrary/ShaderOutput.js";import{TwoVectorPosition as g}from"../util/TwoVectorPosition.js";import{union as w}from"../../lib/depthRange.js";import{RenderSlot as b}from"../../lib/RenderSlot.js";class f{constructor(s,a){this.rctx=s,this.shaderTechniqueRepository=a,this.canRender=!0,this._materialPassParameters=new o,this._shadowPassParameters=new P,this._highlightPassParameters=new l,this._systems=new Set,this._passes={materialOpaque:new u(s,a),materialTransparent:new u(s,a,c.BackToFront),materialIntegratedMesh:new u(s,a),shadowMap:new u(s,a),highlight:new u(s,a),highlightIntegratedMesh:new u(s,a),highlightShadowMap:new u(s,a),defaultShadowMap:new u(s,a)}}register(s){this._systems.add(s)}prepareRender(s){if(0!==this._systems.size){for(const s of Object.values(this._passes))s.prepareSubmit();this._systems.forEach((a=>a.submit(this._passes,s.bindParameters)));for(const s of Object.values(this._passes))s.finishSubmit();this.shaderTechniqueRepository.frameUpdate()}}render(s){if(0!==this._systems.size)switch(this._configure(s),s.bindParameters.slot){case b.OPAQUE_MATERIAL:switch(s.output){case _.Color:return this._materialPassParameters.subPass=p.Color,this._passes.materialOpaque.dispatch(this._materialPassParameters,s.bindParameters);case _.Depth:return this._materialPassParameters.subPass=p.Depth,this._passes.materialOpaque.dispatch(this._materialPassParameters,s.bindParameters);case _.Normal:return this._materialPassParameters.subPass=p.Normal,this._passes.materialOpaque.dispatch(this._materialPassParameters,s.bindParameters);case _.Highlight:return this._passes.highlight.dispatch(this._highlightPassParameters,s.bindParameters);case _.Shadow:return this._passes.shadowMap.dispatch(this._shadowPassParameters,s.bindParameters);case _.ShadowHighlight:return this._passes.highlightShadowMap.dispatch(this._shadowPassParameters,s.bindParameters);case _.ShadowExludeHighlight:return this._passes.defaultShadowMap.dispatch(this._shadowPassParameters,s.bindParameters)}return;case b.TRANSPARENT_MATERIAL:switch(s.output){case _.Color:return this._materialPassParameters.subPass=p.Color,this._passes.materialTransparent.dispatch(this._materialPassParameters,s.bindParameters);case _.Alpha:return this._materialPassParameters.subPass=p.Alpha,this._passes.materialTransparent.dispatch(this._materialPassParameters,s.bindParameters);case _.Depth:return this._materialPassParameters.subPass=p.Depth,this._passes.materialTransparent.dispatch(this._materialPassParameters,s.bindParameters);case _.Normal:return this._materialPassParameters.subPass=p.Normal,this._passes.materialTransparent.dispatch(this._materialPassParameters,s.bindParameters)}return;case b.INTEGRATED_MESH:switch(s.output){case _.Color:return this._materialPassParameters.subPass=p.Color,this._passes.materialIntegratedMesh.dispatch(this._materialPassParameters,s.bindParameters);case _.Depth:return this._materialPassParameters.subPass=p.Depth,this._passes.materialIntegratedMesh.dispatch(this._materialPassParameters,s.bindParameters);case _.Normal:return this._materialPassParameters.subPass=p.Normal,this._passes.materialIntegratedMesh.dispatch(this._materialPassParameters,s.bindParameters);case _.Highlight:return this._passes.highlightIntegratedMesh.dispatch(this._highlightPassParameters,s.bindParameters)}return}}notifyDirty(){this._context.requestRender()}slots(){return[b.OPAQUE_MATERIAL,b.TRANSPARENT_MATERIAL,b.INTEGRATED_MESH]}initializeRenderContext(s){this._context=s}uninitializeRenderContext(){}queryDepthRange(a){const e={near:1/0,far:-1/0};return this._systems.forEach((t=>{const r=t.queryShadowCasterDepthRange(a);s(r)&&w(e,r,e)})),e}_configure(s){const a=s.output===_.Shadow||s.output===_.ShadowHighlight||s.output===_.ShadowExludeHighlight?this._shadowPassParameters:s.output===_.Highlight?this._highlightPassParameters:this._materialPassParameters;this._updateParameters(s,a)}_updateParameters(s,r){const n=s.bindParameters.camera,o=n.viewInverseTransposeMatrix;h(R,o[3],o[7],o[11]),M.set(R),m(r.transformWorldFromViewTH,M.high),m(r.transformWorldFromViewTL,M.low),m(r.slicePlaneLocalOrigin,R),a(r.transformViewFromCameraRelativeRS,n.viewMatrix),i(r.transformProjFromView,n.projectionMatrix),r.identifier===d.Material&&(this._materialPassParameters.transparent=s.bindParameters.slot===b.TRANSPARENT_MATERIAL,this._materialPassParameters.integratedMesh=s.bindParameters.slot===b.INTEGRATED_MESH,e(T,r.transformViewFromCameraRelativeRS),t(r.transformNormalViewFromGlobal,T))}get needsHighlight(){return this._passes.highlight.count>0||this._passes.highlightIntegratedMesh.count>0}get needsTransparentPass(){return this._passes.materialTransparent.count>0}}const R=n(),T=r(),M=new g;export{f as RenderPassManager};
@@ -2,6 +2,6 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{ShaderOutput as e}from"./ShaderOutputOptions.js";import{VertexPosition as r}from"./attributes/VertexPosition.glsl.js";import{Float2PassUniform as a}from"../shaderModules/Float2PassUniform.js";import{glsl as o}from"../shaderModules/interfaces.js";function t(t,i){i.output===e.Color&&i.receiveShadows?(t.varyings.add("linearDepth","float"),t.vertex.code.add(o`void forwardLinearDepth() { linearDepth = gl_Position.w; }`)):i.output===e.Depth||i.output===e.Shadow?(t.include(r,i),t.varyings.add("linearDepth","float"),t.vertex.uniforms.add(new a("nearFar",((e,r)=>r.camera.nearFar))),t.vertex.code.add(o`void forwardLinearDepth() {
5
+ import{ShaderOutput as e}from"./ShaderOutput.js";import{VertexPosition as r}from"./attributes/VertexPosition.glsl.js";import{Float2PassUniform as a}from"../shaderModules/Float2PassUniform.js";import{glsl as o}from"../shaderModules/interfaces.js";function i(i,t){switch(t.output){case e.Color:if(t.receiveShadows)return i.varyings.add("linearDepth","float"),void i.vertex.code.add(o`void forwardLinearDepth() { linearDepth = gl_Position.w; }`);break;case e.Depth:case e.Shadow:case e.ShadowHighlight:case e.ShadowExludeHighlight:return i.include(r,t),i.varyings.add("linearDepth","float"),i.vertex.uniforms.add(new a("nearFar",((e,r)=>r.camera.nearFar))),void i.vertex.code.add(o`void forwardLinearDepth() {
6
6
  linearDepth = (-vPosition_view.z - nearFar[0]) / (nearFar[1] - nearFar[0]);
7
- }`)):t.vertex.code.add(o`void forwardLinearDepth() {}`)}export{t as ForwardLinearDepth};
7
+ }`)}i.vertex.code.add(o`void forwardLinearDepth() {}`)}export{i as ForwardLinearDepth};
@@ -0,0 +1,5 @@
1
+ /*
2
+ All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
+ See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
+ */
5
+ var h;!function(h){h[h.Color=0]="Color",h[h.Depth=1]="Depth",h[h.Normal=2]="Normal",h[h.Shadow=3]="Shadow",h[h.ShadowHighlight=4]="ShadowHighlight",h[h.ShadowExludeHighlight=5]="ShadowExludeHighlight",h[h.Highlight=6]="Highlight",h[h.Alpha=7]="Alpha",h[h.COUNT=8]="COUNT"}(h||(h={}));export{h as ShaderOutput};
@@ -0,0 +1,5 @@
1
+ /*
2
+ All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
+ See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
+ */
5
+ import{ShaderTechniqueConfiguration as e}from"../shaderTechnique/ShaderTechniqueConfiguration.js";class r extends e{}export{r as ShaderOutputConfiguration};
@@ -2,16 +2,16 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{glsl as e}from"../shaderModules/interfaces.js";function r(r,o={hasModelTransformation:!1,linearDepth:!1}){if(o.hasModelTransformation)return o.linearDepth?void r.vertex.code.add(e`vec4 transformPositionWithDepth(mat4 proj, mat4 view, mat4 model, vec3 pos, vec2 nearFar, out float depth) {
5
+ import{glsl as e}from"../shaderModules/interfaces.js";function r(r,o){if(o.hasModelTransformation)return r.vertex.code.add(e`vec4 transformPositionWithDepth(mat4 proj, mat4 view, mat4 model, vec3 pos, vec2 nearFar, out float depth) {
6
6
  vec4 eye = view * (model * vec4(pos, 1.0));
7
7
  depth = (-eye.z - nearFar[0]) / (nearFar[1] - nearFar[0]) ;
8
8
  return proj * eye;
9
- }`):void r.vertex.code.add(e`vec4 transformPosition(mat4 proj, mat4 view, mat4 model, vec3 pos) {
9
+ }`),void r.vertex.code.add(e`vec4 transformPosition(mat4 proj, mat4 view, mat4 model, vec3 pos) {
10
10
  return proj * (view * (model * vec4(pos, 1.0)));
11
- }`);o.linearDepth?r.vertex.code.add(e`vec4 transformPositionWithDepth(mat4 proj, mat4 view, vec3 pos, vec2 nearFar, out float depth) {
11
+ }`);r.vertex.code.add(e`vec4 transformPositionWithDepth(mat4 proj, mat4 view, vec3 pos, vec2 nearFar, out float depth) {
12
12
  vec4 eye = view * vec4(pos, 1.0);
13
13
  depth = (-eye.z - nearFar[0]) / (nearFar[1] - nearFar[0]) ;
14
14
  return proj * eye;
15
- }`):r.vertex.code.add(e`vec4 transformPosition(mat4 proj, mat4 view, vec3 pos) {
15
+ }`),r.vertex.code.add(e`vec4 transformPosition(mat4 proj, mat4 view, vec3 pos) {
16
16
  return proj * (view * vec4(pos, 1.0));
17
17
  }`)}export{r as Transform};
@@ -2,27 +2,27 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{s as e}from"../../../../../../chunks/vec3.js";import{c as r}from"../../../../../../chunks/vec3f64.js";import{ShaderOutput as i}from"../ShaderOutputOptions.js";import{DoublePrecision as o}from"../util/DoublePrecision.glsl.js";import{Float3DrawUniform as n}from"../../shaderModules/Float3DrawUniform.js";import{glsl as a}from"../../shaderModules/interfaces.js";import{Matrix4PassUniform as t}from"../../shaderModules/Matrix4PassUniform.js";import{VertexAttribute as s}from"../../../lib/VertexAttribute.js";import{encodeDoubleHi as c,encodeDoubleLo as d}from"../../../../../webgl/doublePrecisionUtils.js";function m(r,m){m.instanced&&m.instancedDoublePrecision&&(r.attributes.add(s.MODELORIGINHI,"vec3"),r.attributes.add(s.MODELORIGINLO,"vec3"),r.attributes.add(s.MODEL,"mat3"),r.attributes.add(s.MODELNORMAL,"mat3"));const u=r.vertex;m.instancedDoublePrecision&&(u.include(o,m),u.uniforms.add(new n("viewOriginHi",((r,i)=>c(e(l,i.camera.viewInverseTransposeMatrix[3],i.camera.viewInverseTransposeMatrix[7],i.camera.viewInverseTransposeMatrix[11]),l)))),u.uniforms.add(new n("viewOriginLo",((r,i)=>d(e(l,i.camera.viewInverseTransposeMatrix[3],i.camera.viewInverseTransposeMatrix[7],i.camera.viewInverseTransposeMatrix[11]),l))))),u.code.add(a`
5
+ import{_ as e}from"../../../../../../chunks/tslib.es6.js";import{s as r}from"../../../../../../chunks/vec3.js";import{c as i}from"../../../../../../chunks/vec3f64.js";import{ShaderOutput as o}from"../ShaderOutput.js";import{DoublePrecision as n}from"../util/DoublePrecision.glsl.js";import{Float3DrawUniform as a}from"../../shaderModules/Float3DrawUniform.js";import{glsl as s}from"../../shaderModules/interfaces.js";import{Matrix4PassUniform as t}from"../../shaderModules/Matrix4PassUniform.js";import{parameter as c,ShaderTechniqueConfiguration as d}from"../../shaderTechnique/ShaderTechniqueConfiguration.js";import{VertexAttribute as m}from"../../../lib/VertexAttribute.js";import{encodeDoubleHi as l,encodeDoubleLo as u}from"../../../../../webgl/doublePrecisionUtils.js";class v extends d{constructor(){super(...arguments),this.instancedDoublePrecision=!1}}function p(e,i){i.instanced&&i.instancedDoublePrecision&&(e.attributes.add(m.MODELORIGINHI,"vec3"),e.attributes.add(m.MODELORIGINLO,"vec3"),e.attributes.add(m.MODEL,"mat3"),e.attributes.add(m.MODELNORMAL,"mat3"));const c=e.vertex;i.instancedDoublePrecision&&(c.include(n,i),c.uniforms.add(new a("viewOriginHi",((e,i)=>l(r(x,i.camera.viewInverseTransposeMatrix[3],i.camera.viewInverseTransposeMatrix[7],i.camera.viewInverseTransposeMatrix[11]),x)))),c.uniforms.add(new a("viewOriginLo",((e,i)=>u(r(x,i.camera.viewInverseTransposeMatrix[3],i.camera.viewInverseTransposeMatrix[7],i.camera.viewInverseTransposeMatrix[11]),x))))),c.code.add(s`
6
6
  vec3 calculateVPos() {
7
- ${m.instancedDoublePrecision?"return model * localPosition().xyz;":"return localPosition().xyz;"}
7
+ ${i.instancedDoublePrecision?"return model * localPosition().xyz;":"return localPosition().xyz;"}
8
8
  }
9
- `),u.code.add(a`
9
+ `),c.code.add(s`
10
10
  vec3 subtractOrigin(vec3 _pos) {
11
- ${m.instancedDoublePrecision?a`
11
+ ${i.instancedDoublePrecision?s`
12
12
  vec3 originDelta = dpAdd(viewOriginHi, viewOriginLo, -modelOriginHi, -modelOriginLo);
13
13
  return _pos - originDelta;`:"return vpos;"}
14
14
  }
15
- `),u.code.add(a`
15
+ `),c.code.add(s`
16
16
  vec3 dpNormal(vec4 _normal) {
17
- ${m.instancedDoublePrecision?"return normalize(modelNormal * _normal.xyz);":"return normalize(_normal.xyz);"}
17
+ ${i.instancedDoublePrecision?"return normalize(modelNormal * _normal.xyz);":"return normalize(_normal.xyz);"}
18
18
  }
19
- `),m.output===i.Normal&&(u.uniforms.add(new t("viewNormal",((e,r)=>r.camera.viewInverseTransposeMatrix))),u.code.add(a`
19
+ `),i.output===o.Normal&&(c.uniforms.add(new t("viewNormal",((e,r)=>r.camera.viewInverseTransposeMatrix))),c.code.add(s`
20
20
  vec3 dpNormalView(vec4 _normal) {
21
- ${m.instancedDoublePrecision?"return normalize((viewNormal * vec4(modelNormal * _normal.xyz, 1.0)).xyz);":"return normalize((viewNormal * _normal).xyz);"}
21
+ ${i.instancedDoublePrecision?"return normalize((viewNormal * vec4(modelNormal * _normal.xyz, 1.0)).xyz);":"return normalize((viewNormal * _normal).xyz);"}
22
22
  }
23
- `)),m.hasVertexTangents&&u.code.add(a`
23
+ `)),i.hasVertexTangents&&c.code.add(s`
24
24
  vec4 dpTransformVertexTangent(vec4 _tangent) {
25
- ${m.instancedDoublePrecision?"return vec4(modelNormal * _tangent.xyz, _tangent.w);":"return _tangent;"}
25
+ ${i.instancedDoublePrecision?"return vec4(modelNormal * _tangent.xyz, _tangent.w);":"return _tangent;"}
26
26
 
27
27
  }
28
- `)}const l=r();export{m as InstancedDoublePrecision};
28
+ `)}e([c()],v.prototype,"instancedDoublePrecision",void 0);const x=i();export{v as InstancedDoubleConfiguration,p as InstancedDoublePrecision};
@@ -7,4 +7,4 @@ vuv0 = uv0;
7
7
  }`);case o.Atlas:return d.attributes.add(r.UV0,"vec2"),d.varyings.add("vuv0","vec2"),d.attributes.add(r.UVREGION,"vec4"),d.varyings.add("vuvRegion","vec4"),void d.vertex.code.add(t`void forwardTextureCoordinates() {
8
8
  vuv0 = uv0;
9
9
  vuvRegion = uvRegion;
10
- }`);case o.None:return void d.vertex.code.add(t`void forwardTextureCoordinates() {}`);default:e(a.textureCoordinateType);case o.COUNT:return}}!function(e){e[e.None=0]="None",e[e.Default=1]="Default",e[e.Atlas=2]="Atlas",e[e.COUNT=3]="COUNT"}(o||(o={}));export{d as TextureCoordinateAttribute,o as TextureCoordinateAttributeType};
10
+ }`);default:e(a.textureCoordinateType);case o.None:return void d.vertex.code.add(t`void forwardTextureCoordinates() {}`);case o.COUNT:return}}!function(e){e[e.None=0]="None",e[e.Default=1]="Default",e[e.Atlas=2]="Atlas",e[e.COUNT=3]="COUNT"}(o||(o={}));export{d as TextureCoordinateAttribute,o as TextureCoordinateAttributeType};
@@ -2,59 +2,59 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{ShaderOutput as o}from"../ShaderOutputOptions.js";import{SliceDraw as r}from"../Slice.glsl.js";import{Transform as e}from"../Transform.glsl.js";import{NormalAttribute as t,NormalAttributeType as i}from"../attributes/NormalAttribute.glsl.js";import{TextureCoordinateAttribute as a}from"../attributes/TextureCoordinateAttribute.glsl.js";import{VertexNormal as l}from"../attributes/VertexNormal.glsl.js";import{OutputDepth as s}from"../output/OutputDepth.glsl.js";import{OutputHighlight as d}from"../output/OutputHighlight.glsl.js";import{VisualVariables as n}from"../shading/VisualVariables.glsl.js";import{DiscardOrAdjustAlphaPass as u}from"../util/AlphaDiscard.glsl.js";import{addProjViewLocalOrigin as m}from"../util/View.glsl.js";import{Float2PassUniform as p}from"../../shaderModules/Float2PassUniform.js";import{glsl as c}from"../../shaderModules/interfaces.js";import{Texture2DPassUniform as v}from"../../shaderModules/Texture2DPassUniform.js";function f(f,h){const g=f.vertex.code,x=f.fragment.code,j=h.hasModelTransformation;h.output!==o.Depth&&h.output!==o.Shadow||(m(f,h),f.include(e,{linearDepth:!0,hasModelTransformation:j}),f.include(a,h),f.include(n,h),f.include(s,h),f.include(r,h),f.vertex.uniforms.add(new p("nearFar",((o,r)=>r.camera.nearFar))),f.varyings.add("depth","float"),h.hasColorTexture&&f.fragment.uniforms.add(new v("tex",(o=>o.texture))),g.add(c`
6
- void main(void) {
7
- vpos = calculateVPos();
8
- vpos = subtractOrigin(vpos);
9
- vpos = addVerticalOffset(vpos, localOrigin);
10
- gl_Position = transformPositionWithDepth(proj, view, ${j?"model,":""} vpos, nearFar, depth);
11
- forwardTextureCoordinates();
12
- }
13
- `),f.include(u,h),x.add(c`
14
- void main(void) {
15
- discardBySlice(vpos);
16
- ${h.hasColorTexture?c`
17
- vec4 texColor = texture2D(tex, vuv0);
18
- discardOrAdjustAlpha(texColor);`:""}
19
- outputDepth(depth);
20
- }
21
- `)),h.output===o.Normal&&(m(f,h),f.include(e,{linearDepth:!1,hasModelTransformation:j}),f.include(t,h),f.include(l,h),f.include(a,h),f.include(n,h),h.hasColorTexture&&f.fragment.uniforms.add(new v("tex",(o=>o.texture))),f.varyings.add("vPositionView","vec3"),g.add(c`
22
- void main(void) {
23
- vpos = calculateVPos();
24
- vpos = subtractOrigin(vpos);
25
- ${h.normalType===i.Attribute?c`
26
- vNormalWorld = dpNormalView(vvLocalNormal(normalModel()));`:""}
27
- vpos = addVerticalOffset(vpos, localOrigin);
28
- gl_Position = transformPosition(proj, view, ${j?"model,":""} vpos);
29
- forwardTextureCoordinates();
30
- }
31
- `),f.include(r,h),f.include(u,h),x.add(c`
32
- void main() {
33
- discardBySlice(vpos);
34
- ${h.hasColorTexture?c`
35
- vec4 texColor = texture2D(tex, vuv0);
36
- discardOrAdjustAlpha(texColor);`:""}
5
+ import{isSome as o}from"../../../../../../core/maybe.js";import{I as r}from"../../../../../../chunks/mat4f64.js";import{ShaderOutput as e}from"../ShaderOutput.js";import{SliceDraw as t}from"../Slice.glsl.js";import{Transform as i}from"../Transform.glsl.js";import{NormalAttribute as a,NormalAttributeType as s}from"../attributes/NormalAttribute.glsl.js";import{TextureCoordinateAttribute as l}from"../attributes/TextureCoordinateAttribute.glsl.js";import{VertexNormal as d}from"../attributes/VertexNormal.glsl.js";import{OutputDepth as n}from"../output/OutputDepth.glsl.js";import{OutputHighlight as m}from"../output/OutputHighlight.glsl.js";import{VisualVariables as u}from"../shading/VisualVariables.glsl.js";import{DiscardOrAdjustAlphaPass as c}from"../util/AlphaDiscard.glsl.js";import{addProjViewLocalOrigin as p}from"../util/View.glsl.js";import{Float2PassUniform as v}from"../../shaderModules/Float2PassUniform.js";import{glsl as f}from"../../shaderModules/interfaces.js";import{Matrix4PassUniform as g}from"../../shaderModules/Matrix4PassUniform.js";import{Texture2DPassUniform as h}from"../../shaderModules/Texture2DPassUniform.js";function x(x,j){const w=x.vertex.code,C=x.fragment.code,T=j.hasModelTransformation;switch(T&&x.vertex.uniforms.add(new g("model",(e=>o(e.modelTransformation)?e.modelTransformation:r))),j.output){case e.Depth:case e.Shadow:case e.ShadowHighlight:case e.ShadowExludeHighlight:p(x,j),x.include(i,j),x.include(l,j),x.include(u,j),x.include(n,j),x.include(t,j),x.vertex.uniforms.add(new v("nearFar",((o,r)=>r.camera.nearFar))),x.varyings.add("depth","float"),j.hasColorTexture&&x.fragment.uniforms.add(new h("tex",(o=>o.texture))),w.add(f`
6
+ void main(void) {
7
+ vpos = calculateVPos();
8
+ vpos = subtractOrigin(vpos);
9
+ vpos = addVerticalOffset(vpos, localOrigin);
10
+ gl_Position = transformPositionWithDepth(proj, view, ${T?"model,":""} vpos, nearFar, depth);
11
+ forwardTextureCoordinates();
12
+ }
13
+ `),x.include(c,j),C.add(f`
14
+ void main(void) {
15
+ discardBySlice(vpos);
16
+ ${j.hasColorTexture?f`
17
+ vec4 texColor = texture2D(tex, vuv0);
18
+ discardOrAdjustAlpha(texColor);`:""}
19
+ outputDepth(depth);
20
+ }
21
+ `);break;case e.Normal:p(x,j),x.include(i,j),x.include(a,j),x.include(d,j),x.include(l,j),x.include(u,j),j.hasColorTexture&&x.fragment.uniforms.add(new h("tex",(o=>o.texture))),x.varyings.add("vPositionView","vec3"),w.add(f`
22
+ void main(void) {
23
+ vpos = calculateVPos();
24
+ vpos = subtractOrigin(vpos);
25
+ ${j.normalType===s.Attribute?f`
26
+ vNormalWorld = dpNormalView(vvLocalNormal(normalModel()));`:""}
27
+ vpos = addVerticalOffset(vpos, localOrigin);
28
+ gl_Position = transformPosition(proj, view, ${T?"model,":""} vpos);
29
+ forwardTextureCoordinates();
30
+ }
31
+ `),x.include(t,j),x.include(c,j),C.add(f`
32
+ void main() {
33
+ discardBySlice(vpos);
34
+ ${j.hasColorTexture?f`
35
+ vec4 texColor = texture2D(tex, vuv0);
36
+ discardOrAdjustAlpha(texColor);`:""}
37
37
 
38
- ${h.normalType===i.ScreenDerivative?c`
39
- vec3 normal = screenDerivativeNormal(vPositionView);`:c`
40
- vec3 normal = normalize(vNormalWorld);
41
- if (gl_FrontFacing == false) normal = -normal;`}
42
- gl_FragColor = vec4(vec3(0.5) + 0.5 * normal, 1.0);
43
- }
44
- `)),h.output===o.Highlight&&(m(f,h),f.include(e,{linearDepth:!1,hasModelTransformation:j}),f.include(a,h),f.include(n,h),h.hasColorTexture&&f.fragment.uniforms.add(new v("tex",(o=>o.texture))),g.add(c`
45
- void main(void) {
46
- vpos = calculateVPos();
47
- vpos = subtractOrigin(vpos);
48
- vpos = addVerticalOffset(vpos, localOrigin);
49
- gl_Position = transformPosition(proj, view, ${j?"model,":""} vpos);
50
- forwardTextureCoordinates();
51
- }
52
- `),f.include(r,h),f.include(u,h),f.include(d),x.add(c`
53
- void main() {
54
- discardBySlice(vpos);
55
- ${h.hasColorTexture?c`
56
- vec4 texColor = texture2D(tex, vuv0);
57
- discardOrAdjustAlpha(texColor);`:""}
58
- outputHighlight();
59
- }
60
- `))}export{f as DefaultMaterialAuxiliaryPasses};
38
+ ${j.normalType===s.ScreenDerivative?f`
39
+ vec3 normal = screenDerivativeNormal(vPositionView);`:f`
40
+ vec3 normal = normalize(vNormalWorld);
41
+ if (gl_FrontFacing == false) normal = -normal;`}
42
+ gl_FragColor = vec4(vec3(0.5) + 0.5 * normal, 1.0);
43
+ }
44
+ `);break;case e.Highlight:p(x,j),x.include(i,j),x.include(l,j),x.include(u,j),j.hasColorTexture&&x.fragment.uniforms.add(new h("tex",(o=>o.texture))),w.add(f`
45
+ void main(void) {
46
+ vpos = calculateVPos();
47
+ vpos = subtractOrigin(vpos);
48
+ vpos = addVerticalOffset(vpos, localOrigin);
49
+ gl_Position = transformPosition(proj, view, ${T?"model,":""} vpos);
50
+ forwardTextureCoordinates();
51
+ }
52
+ `),x.include(t,j),x.include(c,j),x.include(m),C.add(f`
53
+ void main() {
54
+ discardBySlice(vpos);
55
+ ${j.hasColorTexture?f`
56
+ vec4 texColor = texture2D(tex, vuv0);
57
+ discardOrAdjustAlpha(texColor);`:""}
58
+ outputHighlight();
59
+ }
60
+ `)}}export{x as DefaultMaterialAuxiliaryPasses};
@@ -2,7 +2,7 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{ShaderOutput as t}from"../ShaderOutputOptions.js";import{RgbaFloatEncoding as a}from"../util/RgbaFloatEncoding.glsl.js";import{glsl as o}from"../../shaderModules/interfaces.js";function e(e,l){e.fragment.include(a),l.output===t.Shadow?(e.extensions.add("GL_OES_standard_derivatives"),e.fragment.code.add(o`float _calculateFragDepth(const in float depth) {
5
+ import{ShaderOutput as t}from"../ShaderOutput.js";import{RgbaFloatEncoding as a}from"../util/RgbaFloatEncoding.glsl.js";import{glsl as e}from"../../shaderModules/interfaces.js";function o(o,l){switch(o.fragment.include(a),l.output){case t.Shadow:case t.ShadowHighlight:case t.ShadowExludeHighlight:o.extensions.add("GL_OES_standard_derivatives"),o.fragment.code.add(e`float _calculateFragDepth(const in float depth) {
6
6
  const float SLOPE_SCALE = 2.0;
7
7
  const float BIAS = 2.0 * .000015259;
8
8
  float m = max(abs(dFdx(depth)), abs(dFdy(depth)));
@@ -11,6 +11,6 @@ return clamp(result, .0, .999999);
11
11
  }
12
12
  void outputDepth(float _linearDepth) {
13
13
  gl_FragColor = float2rgba(_calculateFragDepth(_linearDepth));
14
- }`)):l.output===t.Depth&&e.fragment.code.add(o`void outputDepth(float _linearDepth) {
14
+ }`);break;case t.Depth:o.fragment.code.add(e`void outputDepth(float _linearDepth) {
15
15
  gl_FragColor = float2rgba(_linearDepth);
16
- }`)}export{e as OutputDepth};
16
+ }`)}}export{o as OutputDepth};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import"../../../../../../chunks/mat4.js";import"../../../../../../chunks/mat4f64.js";import"../../../../../../chunks/vec3.js";import"../../../../../../chunks/vec3f64.js";import"../../../../terrain/interfaces.js";import"../ShaderOutputOptions.js";import"../Slice.glsl.js";import"../Transform.glsl.js";import"../attributes/VertexTangent.glsl.js";import"../output/OutputDepth.glsl.js";import"../output/OutputHighlight.glsl.js";import"../shading/EvaluateAmbientOcclusion.glsl.js";import"../shading/EvaluateSceneLighting.glsl.js";import"../shading/NormalUtils.glsl.js";import"../shading/PhysicallyBasedRenderingParameters.glsl.js";import"../shading/ReadShadowMap.glsl.js";import"./Overlay.glsl.js";import"./TerrainTexture.glsl.js";import"../util/HeaderComment.glsl.js";import"../../shaderModules/Float2PassUniform.js";import"../../shaderModules/Float3DrawUniform.js";import"../../shaderModules/Float3PassUniform.js";import"../../shaderModules/FloatPassUniform.js";import"../../shaderModules/interfaces.js";import"../../shaderModules/Matrix4DrawUniform.js";import"../../shaderModules/Matrix4PassUniform.js";import"../../shaderModules/ShaderBuilder.js";import"../../shaderModules/Texture2DPassUniform.js";import"../../../lib/VertexAttribute.js";import"../../../lighting/SceneLighting.js";export{T as TerrainPassParameters,b as build}from"../../../../../../chunks/Terrain.glsl.js";
5
+ import"../../../../../../chunks/mat4.js";import"../../../../../../chunks/mat4f64.js";import"../../../../../../chunks/vec3.js";import"../../../../../../chunks/vec3f64.js";import"../../../../terrain/interfaces.js";import"../ShaderOutput.js";import"../Slice.glsl.js";import"../Transform.glsl.js";import"../attributes/VertexTangent.glsl.js";import"../output/OutputDepth.glsl.js";import"../output/OutputHighlight.glsl.js";import"../shading/EvaluateAmbientOcclusion.glsl.js";import"../shading/EvaluateSceneLighting.glsl.js";import"../shading/NormalUtils.glsl.js";import"../shading/PhysicallyBasedRenderingParameters.glsl.js";import"../shading/ReadShadowMap.glsl.js";import"./Overlay.glsl.js";import"./TerrainTexture.glsl.js";import"../../shaderModules/Float2PassUniform.js";import"../../shaderModules/Float3DrawUniform.js";import"../../shaderModules/Float3PassUniform.js";import"../../shaderModules/FloatPassUniform.js";import"../../shaderModules/interfaces.js";import"../../shaderModules/Matrix4DrawUniform.js";import"../../shaderModules/Matrix4PassUniform.js";import"../../shaderModules/ShaderBuilder.js";import"../../shaderModules/Texture2DPassUniform.js";import"../../../lib/VertexAttribute.js";import"../../../lighting/SceneLighting.js";export{T as TerrainPassParameters,b as build}from"../../../../../../chunks/Terrain.glsl.js";
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{disposeMaybe as i}from"../../../../../core/maybe.js";import{PrimitiveType as t}from"../../../../webgl/enums.js";class e{constructor(i,t,e){this.release=e,t&&(this.initializeConfiguration(i,t),this._configuration=t.snapshot()),this._program=this.initializeProgram(i),this._pipeline=this.initializePipeline(i.rctx.capabilities)}destroy(){this._program=i(this._program),this._pipeline=this._configuration=null}reload(t){i(this._program),this._program=this.initializeProgram(t),this._pipeline=this.initializePipeline(t.rctx.capabilities)}get program(){return this._program}get compiled(){return this.program.isCompiled}get key(){return this._configuration.key}get configuration(){return this._configuration}bindPass(i,t){this.program.bindPass(i,t)}bindDraw(i,t,e){this.program.bindDraw(i,t,e),this.program.rebindTextures()}bindPipelineState(i,t=null,e){i.setPipelineState(this.getPipelineState(t,e))}ensureAttributeLocations(i){this.program.assertCompatibleVertexAttributeLocations(i)}get primitiveType(){return t.TRIANGLES}getPipelineState(i,t){return this._pipeline}initializeConfiguration(i,t){}}export{e as ShaderTechnique};
5
+ import{disposeMaybe as i}from"../../../../../core/maybe.js";import{PrimitiveType as t}from"../../../../webgl/enums.js";class e{constructor(i,t,e){this.release=e,this.initializeConfiguration(i,t),this._configuration=t.snapshot(),this._program=this.initializeProgram(i),this._pipeline=this.initializePipeline(i.rctx.capabilities)}destroy(){this._program=i(this._program),this._pipeline=this._configuration=null}reload(t){i(this._program),this._program=this.initializeProgram(t),this._pipeline=this.initializePipeline(t.rctx.capabilities)}get program(){return this._program}get compiled(){return this.program.isCompiled}get key(){return this._configuration.key}get configuration(){return this._configuration}bindPipelineState(i,t=null,e){i.setPipelineState(this.getPipelineState(t,e))}ensureAttributeLocations(i){this.program.assertCompatibleVertexAttributeLocations(i)}get primitiveType(){return t.TRIANGLES}getPipelineState(i,t){return this._pipeline}initializeConfiguration(i,t){}}export{e as ShaderTechnique};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{ReloadableShaderModule as e}from"../core/shaderTechnique/ReloadableShaderModule.js";import{ShaderTechnique as r}from"../core/shaderTechnique/ShaderTechnique.js";import{Default3D as t}from"./DefaultVertexAttributeLocations.js";import{Program as i}from"./Program.js";import{B as o}from"../../../../chunks/BlendWeights.glsl.js";import{makePipelineState as s,defaultColorWriteParams as a}from"../../../webgl/renderState.js";class l extends r{initializeProgram(e){const r=l.shader.get().build();return new i(e.rctx,r,t)}initializePipeline(){return s({colorWrite:a})}}l.shader=new e(o,(()=>import("../shaders/BlendWeights.glsl.js")));export{l as BlendWeightsTechnique};
5
+ import{ReloadableShaderModule as e}from"../core/shaderTechnique/ReloadableShaderModule.js";import{ShaderTechnique as r}from"../core/shaderTechnique/ShaderTechnique.js";import{Default3D as i}from"./DefaultVertexAttributeLocations.js";import{Program as t}from"./Program.js";import{B as o}from"../../../../chunks/BlendWeights.glsl.js";import{makePipelineState as s,defaultColorWriteParams as a}from"../../../webgl/renderState.js";class l extends r{initializeProgram(e){return new t(e.rctx,l.shader.get().build(),i)}initializePipeline(){return s({colorWrite:a})}}l.shader=new e(o,(()=>import("../shaders/BlendWeights.glsl.js")));export{l as BlendWeightsTechnique};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{ReloadableShaderModule as r}from"../core/shaderTechnique/ReloadableShaderModule.js";import{ShaderTechnique as e}from"../core/shaderTechnique/ShaderTechnique.js";import{Default3D as o}from"./DefaultVertexAttributeLocations.js";import{Program as t}from"./Program.js";import{B as i}from"../../../../chunks/Blur.glsl.js";import{makePipelineState as s,defaultColorWriteParams as a}from"../../../webgl/renderState.js";class l extends e{initializeProgram(r){const e=l.shader.get().build();return new t(r.rctx,e,o)}initializePipeline(){return s({colorWrite:a})}}l.shader=new r(i,(()=>import("../shaders/Blur.glsl.js")));export{l as BlurTechnique};
5
+ import{ReloadableShaderModule as r}from"../core/shaderTechnique/ReloadableShaderModule.js";import{ShaderTechnique as e}from"../core/shaderTechnique/ShaderTechnique.js";import{Default3D as i}from"./DefaultVertexAttributeLocations.js";import{Program as o}from"./Program.js";import{B as t}from"../../../../chunks/Blur.glsl.js";import{makePipelineState as s,defaultColorWriteParams as a}from"../../../webgl/renderState.js";class l extends e{initializeProgram(r){return new o(r.rctx,l.shader.get().build(),i)}initializePipeline(){return s({colorWrite:a})}}l.shader=new r(t,(()=>import("../shaders/Blur.glsl.js")));export{l as BlurTechnique};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import t from"../../../../core/Logger.js";import{lerp as i}from"../../../../core/mathUtils.js";import{isSome as e,isNone as r}from"../../../../core/maybe.js";import{createScreenPointArray as s,createRenderScreenPointArray3 as h}from"../../../../core/screenUtils.js";import{c as o,m as n,q as a,a as _,t as p,u}from"../../../../chunks/mat4.js";import{c as v}from"../../../../chunks/mat4f64.js";import{c,k as w}from"../../../../chunks/vec2.js";import{f as d}from"../../../../chunks/vec2f64.js";import{c as l,b as y,i as g,k as m,w as f,e as x,x as D,y as j,g as M,l as T,s as P,f as R,n as F,r as O}from"../../../../chunks/vec3.js";import{c as V,a as I,f as S}from"../../../../chunks/vec3f64.js";import{c as E,g as L,i as b,t as H}from"../../../../chunks/vec4.js";import{f as k,c as B}from"../../../../chunks/vec4f64.js";import{create as G,copy as U,fromMatrix as A}from"../../../../geometry/support/frustum.js";import{create as C}from"../../../../geometry/support/ray.js";import{projectPointSignedLength as z}from"../../../../geometry/support/vector.js";import{ViewingMode as W}from"../../../ViewingMode.js";import{fovd2fovx as X,fovx2fovd as Y,fovd2fovy as q,fovy2fovd as N}from"./Util.js";class J{constructor(t=null,i=null,r=null){this._viewUp=V(),this._viewForward=V(),this._viewRight=V(),this._ray=C(),this._viewport=k(0,0,1,1),this._padding=k(0,0,0,0),this._fov=55/180*Math.PI,this._nearFar=d(1,1e3),this._viewDirty=!0,this._viewMatrix=v(),this._projectionDirty=!0,this._projectionMatrix=v(),this._viewProjectionDirty=!0,this._viewProjectionMatrix=v(),this._viewInverseTransposeMatrixDirty=!0,this._viewInverseTransposeMatrix=v(),this._inverseProjectionDirty=!0,this._inverseProjectionMatrix=null,this._frustumDirty=!0,this._frustum=G(),this._fullViewport=B(),this._pixelRatio=1,this.relativeElevation=0,e(t)&&l(this._ray.origin,t),this._center=e(i)?I(i):V(),this._up=e(r)?I(r):S(0,0,1)}get pixelRatio(){return this._pixelRatio}set pixelRatio(t){this._pixelRatio=t>0?t:1}get eye(){return this._ray.origin}set eye(t){this._compareAndSetView(t,this._ray.origin)}get center(){return this._center}set center(t){this._compareAndSetView(t,this._center)}get ray(){return y(this._ray.direction,this.center,this.eye),this._ray}get up(){return this._up}set up(t){this._compareAndSetView(t,this._up)}get viewMatrix(){return this._ensureViewClean(),this._viewMatrix}set viewMatrix(t){o(this._viewMatrix,t),this._viewDirty=!1,this._viewInverseTransposeMatrixDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0}get viewForward(){return this._ensureViewClean(),this._viewForward}get viewUp(){return this._ensureViewClean(),this._viewUp}get viewRight(){return this._ensureViewClean(),this._viewRight}get nearFar(){return this._nearFar}get near(){return this._nearFar[0]}set near(t){this._nearFar[0]!==t&&(this._nearFar[0]=t,this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0)}get far(){return this._nearFar[1]}set far(t){this._nearFar[1]!==t&&(this._nearFar[1]=t,this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0)}get viewport(){return this._viewport}set viewport(t){this.x=t[0],this.y=t[1],this.width=t[2],this.height=t[3]}get x(){return this._viewport[0]}set x(t){t+=this._padding[it.LEFT],this._viewport[0]!==t&&(this._viewport[0]=t,this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0)}get y(){return this._viewport[1]}set y(t){t+=this._padding[it.BOTTOM],this._viewport[1]!==t&&(this._viewport[1]=t,this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0)}get width(){return this._viewport[2]}set width(t){this._viewport[2]!==t&&(this._viewport[2]=t,this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0)}get height(){return this._viewport[3]}set height(t){this._viewport[3]!==t&&(this._viewport[3]=t,this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0)}get fullWidth(){return this._viewport[2]+this._padding[it.RIGHT]+this._padding[it.LEFT]}set fullWidth(t){this.width=t-(this._padding[it.RIGHT]+this._padding[it.LEFT])}get fullHeight(){return this._viewport[3]+this._padding[it.TOP]+this._padding[it.BOTTOM]}set fullHeight(t){this.height=t-(this._padding[it.TOP]+this._padding[it.BOTTOM])}get fullViewport(){return this._fullViewport[0]=this._viewport[0]-this._padding[it.LEFT],this._fullViewport[1]=this._viewport[1]-this._padding[it.BOTTOM],this._fullViewport[2]=this.fullWidth,this._fullViewport[3]=this.fullHeight,this._fullViewport}get aspect(){return this.width/this.height}get padding(){return this._padding}set padding(t){this._padding[it.TOP]===t[it.TOP]&&this._padding[it.RIGHT]===t[it.RIGHT]&&this._padding[it.BOTTOM]===t[it.BOTTOM]&&this._padding[it.LEFT]===t[it.LEFT]||(this._viewport[0]+=t[it.LEFT]-this._padding[it.LEFT],this._viewport[1]+=t[it.BOTTOM]-this._padding[it.BOTTOM],this._viewport[2]-=t[it.RIGHT]+t[it.LEFT]-(this._padding[it.RIGHT]+this._padding[it.LEFT]),this._viewport[3]-=t[it.TOP]+t[it.BOTTOM]-(this._padding[it.TOP]+this._padding[it.BOTTOM]),E(this._padding,t),this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0)}get viewProjectionMatrix(){return this._viewProjectionDirty&&(n(this._viewProjectionMatrix,this.projectionMatrix,this.viewMatrix),this._viewProjectionDirty=!1),this._viewProjectionMatrix}get projectionMatrix(){if(this._projectionDirty){const t=this.width,i=this.height,e=this.near*Math.tan(this.fovY/2),r=e*this.aspect;a(this._projectionMatrix,-r*(1+2*this._padding[it.LEFT]/t),r*(1+2*this._padding[it.RIGHT]/t),-e*(1+2*this._padding[it.BOTTOM]/i),e*(1+2*this._padding[it.TOP]/i),this.near,this.far),this._projectionDirty=!1}return this._projectionMatrix}get inverseProjectionMatrix(){return r(this._inverseProjectionMatrix)&&(this._inverseProjectionMatrix=v()),this._inverseProjectionDirty&&_(this._inverseProjectionMatrix,this.projectionMatrix),this._inverseProjectionMatrix}set projectionMatrix(t){o(this._projectionMatrix,t),this._projectionDirty=!1,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0}get fov(){return this._fov}set fov(t){this._fov=t,this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0}get fovX(){return X(this._fov,this.width,this.height)}set fovX(t){this._fov=Y(t,this.width,this.height),this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0}get fovY(){return q(this._fov,this.width,this.height)}set fovY(t){this._fov=N(t,this.width,this.height),this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0}get distance(){return g(this._center,this.eye)}get frustum(){return this._recomputeFrustum(),this._frustum}get viewInverseTransposeMatrix(){return(this._viewInverseTransposeMatrixDirty||this._viewDirty)&&(_(this._viewInverseTransposeMatrix,this.viewMatrix),p(this._viewInverseTransposeMatrix,this._viewInverseTransposeMatrix),this._viewInverseTransposeMatrixDirty=!1),this._viewInverseTransposeMatrix}depthNDCToWorld(t){const i=2*t-1;return 2*this.near*this.far/(this.far+this.near-i*(this.far-this.near))}get perRenderPixelRatio(){return Math.tan(this.fovX/2)/(this.width/2)}get perScreenPixelRatio(){return this.perRenderPixelRatio*this._pixelRatio}get aboveGround(){return this.relativeElevation&&this.relativeElevation>=0}copyFrom(t){l(this._ray.origin,t.eye),l(this._center,t.center),l(this._up,t.up),E(this._viewport,t.viewport),E(this._padding,t.padding),c(this._nearFar,t.nearFar),this._fov=t.fov,this.relativeElevation=t.relativeElevation;const i=t;return this._viewDirty=i._viewDirty,this._viewDirty||(o(this._viewMatrix,t.viewMatrix),l(this._viewRight,t.viewRight),l(this._viewUp,t.viewUp),l(this._viewForward,t.viewForward)),i._projectionDirty?this._projectionDirty=!0:(o(this._projectionMatrix,t.projectionMatrix),this._projectionDirty=!1),this._viewProjectionDirty=!0,this._inverseProjectionDirty=!0,this._frustumDirty=i._frustumDirty,this._frustumDirty||(U(this._frustum,t.frustum),this._frustumDirty=!1),i._viewInverseTransposeMatrixDirty?this._viewInverseTransposeMatrixDirty=!0:(o(this._viewInverseTransposeMatrix,t.viewInverseTransposeMatrix),this._viewInverseTransposeMatrixDirty=!1),E(this._fullViewport,t.fullViewport),this._pixelRatio=t.pixelRatio,this}copyViewFrom(t){this.eye=t.eye,this.center=t.center,this.up=t.up}clone(){return(new J).copyFrom(this)}equals(t){return m(this.eye,t.eye)&&m(this._center,t.center)&&m(this._up,t.up)&&L(this._viewport,t.viewport)&&L(this._padding,t.padding)&&w(this._nearFar,t.nearFar)&&this._fov===t.fov&&this._pixelRatio===t.pixelRatio&&this.relativeElevation===t.relativeElevation}almostEquals(t){if(this._pixelRatio!==t.pixelRatio||Math.abs(t.fov-this._fov)>=.001)return!1;const i=5e-4,e=1-1e-10;f(Z,t.eye,t.center),f($,this.eye,this._center);const r=x(Z,$),s=D(Z),h=D($);return r*r>=e*s*h&&j(t.eye,this.eye)<Math.max(s,h)*i*i&&b(t.padding,this._padding)<.5&&b(t.viewport,this._viewport)<.5}computeRenderPixelSizeAt(t){return this.computeRenderPixelSizeAtDist(this._viewDirectionDistance(t))}computeRenderPixelSizeAtDist(t){return t*this.perRenderPixelRatio}computeScreenPixelSizeAt(t){return this.computeScreenPixelSizeAtDist(this._viewDirectionDistance(t))}_viewDirectionDistance(t){return Math.abs(z(this.viewForward,y(Z,t,this.eye)))}computeScreenPixelSizeAtDist(t){return t*this.perScreenPixelRatio}computeDistanceFromRadius(t,i){return t/Math.tan(Math.min(this.fovX,this.fovY)/(2*(i||1)))}getScreenCenter(t=s()){return t[0]=(this.padding[it.LEFT]+this.width/2)/this._pixelRatio,t[1]=(this.padding[it.TOP]+this.height/2)/this._pixelRatio,t}getRenderCenter(t,i=.5,e=.5){return t[0]=this.padding[it.LEFT]+this.width*i,t[1]=this.padding[it.BOTTOM]+this.height*e,t[2]=.5,t}setGLViewport(t){const i=this.viewport,e=this.padding;t.setViewport(i[0]-e[3],i[1]-e[2],i[2]+e[1]+e[3],i[3]+e[0]+e[2])}applyProjection(t,e){t!==K&&l(K,t),K[3]=1,H(K,K,this.projectionMatrix);const r=Math.abs(K[3]);M(K,K,1/r);const s=this.fullViewport;e[0]=i(0,s[0]+s[2],.5+.5*K[0]),e[1]=i(0,s[1]+s[3],.5+.5*K[1]),e[2]=.5*(K[2]+1),e[3]=r}unapplyProjection(t,i){const e=this.fullViewport;K[0]=(t[0]/(e[0]+e[2])*2-1)*t[3],K[1]=(t[1]/(e[1]+e[3])*2-1)*t[3],K[2]=(2*t[2]-1)*t[3],K[3]=t[3],H(K,K,this.inverseProjectionMatrix),i[0]=K[0],i[1]=K[1],i[2]=K[2]}projectToScreen(t,i){this.projectToRenderScreen(t,tt),this.renderToScreen(tt,i)}projectToRenderScreen(t,e){if(K[0]=t[0],K[1]=t[1],K[2]=t[2],K[3]=1,H(K,K,this.viewProjectionMatrix),0===K[3])return null;M(K,K,1/Math.abs(K[3]));const r=this.fullViewport;return"x"in e?(e.x=i(0,r[0]+r[2],.5+.5*K[0]),e.y=i(0,r[1]+r[3],.5+.5*K[1])):(e[0]=i(0,r[0]+r[2],.5+.5*K[0]),e[1]=i(0,r[1]+r[3],.5+.5*K[1]),e.length>2&&(e[2]=.5*(K[2]+1))),e}unprojectFromScreen(t,i){return this.unprojectFromRenderScreen(this.screenToRender(t,tt),i)}unprojectFromRenderScreen(t,i){if(n(Q,this.projectionMatrix,this.viewMatrix),!_(Q,Q))return null;const e=this.fullViewport;return K[0]=2*(t[0]-e[0])/e[2]-1,K[1]=2*(t[1]-e[1])/e[3]-1,K[2]=2*t[2]-1,K[3]=1,H(K,K,Q),0===K[3]?null:(i[0]=K[0]/K[3],i[1]=K[1]/K[3],i[2]=K[2]/K[3],i)}constrainWindowSize(t,i,e,r=e){const s=t*this._pixelRatio,h=i*this._pixelRatio,o=Math.max(s-e/2,0),n=Math.max(this.fullHeight-h-r/2,0),a=-Math.min(s-e/2,0),_=-Math.min(this.fullHeight-h-r/2,0);return[o,n,e-a- -Math.min(this.fullWidth-s-e/2,0),r-_- -Math.min(h-r/2,0)]}computeUp(t){t===W.Global?this._computeUpGlobal():this._computeUpLocal()}screenToRender(t,i){const e=t[0]*this._pixelRatio,r=this.fullHeight-t[1]*this._pixelRatio;return i[0]=e,i[1]=r,i}renderToScreen(t,i){const e=t[0]/this._pixelRatio,r=(this.fullHeight-t[1])/this._pixelRatio;i[0]=e,i[1]=r}_computeUpGlobal(){y(Z,this.center,this.eye);const t=T(this.center);t<1?(P(this._up,0,0,1),this._markViewDirty()):Math.abs(x(Z,this.center))>.9999*T(Z)*t||(R(this._up,Z,this.center),R(this._up,this._up,Z),F(this._up,this._up),this._markViewDirty())}_computeUpLocal(){O(Z,this.eye,this.center),Math.abs(Z[2])<=.9999&&(M(Z,Z,Z[2]),P(this._up,-Z[0],-Z[1],1-Z[2]),F(this._up,this._up),this._markViewDirty())}_compareAndSetView(i,e){"number"==typeof i[0]&&isFinite(i[0])&&"number"==typeof i[1]&&isFinite(i[1])&&"number"==typeof i[2]&&isFinite(i[2])?m(i,e)||(l(e,i),this._markViewDirty()):t.getLogger("esri.views.3d.webgl-engine.lib.Camera").warn("Camera vector contains invalid number, ignoring value")}_markViewDirty(){this._viewDirty=!0,this._frustumDirty=!0,this._viewProjectionDirty=!0}_recomputeFrustum(){this._frustumDirty&&(A(this.viewMatrix,this.projectionMatrix,this._frustum),this._frustumDirty=!1)}_ensureViewClean(){this._viewDirty&&(u(this._viewMatrix,this.eye,this._center,this._up),P(this._viewForward,-this._viewMatrix[2],-this._viewMatrix[6],-this._viewMatrix[10]),P(this._viewUp,this._viewMatrix[1],this._viewMatrix[5],this._viewMatrix[9]),P(this._viewRight,this._viewMatrix[0],this._viewMatrix[4],this._viewMatrix[8]),this._viewDirty=!1,this._viewInverseTransposeMatrixDirty=!0)}}const K=B(),Q=v(),Z=V(),$=V(),tt=h();var it;!function(t){t[t.TOP=0]="TOP",t[t.RIGHT=1]="RIGHT",t[t.BOTTOM=2]="BOTTOM",t[t.LEFT=3]="LEFT"}(it||(it={}));export{J as Camera,it as PaddingSide};
5
+ import t from"../../../../core/Logger.js";import{lerp as i}from"../../../../core/mathUtils.js";import{isSome as e,isNone as r}from"../../../../core/maybe.js";import{createScreenPointArray as s,createRenderScreenPointArray3 as h}from"../../../../core/screenUtils.js";import{c as o,m as n,q as a,a as _,t as p,u}from"../../../../chunks/mat4.js";import{c as v}from"../../../../chunks/mat4f64.js";import{c,m as w}from"../../../../chunks/vec2.js";import{f as d}from"../../../../chunks/vec2f64.js";import{c as l,b as y,i as g,k as m,w as f,e as x,x as D,y as j,g as M,l as T,s as P,f as R,n as F,r as O}from"../../../../chunks/vec3.js";import{c as V,a as I,f as S}from"../../../../chunks/vec3f64.js";import{c as E,g as L,i as b,t as H}from"../../../../chunks/vec4.js";import{f as k,c as B}from"../../../../chunks/vec4f64.js";import{create as G,copy as U,fromMatrix as A}from"../../../../geometry/support/frustum.js";import{create as C}from"../../../../geometry/support/ray.js";import{projectPointSignedLength as z}from"../../../../geometry/support/vector.js";import{ViewingMode as W}from"../../../ViewingMode.js";import{fovd2fovx as X,fovx2fovd as Y,fovd2fovy as q,fovy2fovd as N}from"./Util.js";class J{constructor(t=null,i=null,r=null){this._viewUp=V(),this._viewForward=V(),this._viewRight=V(),this._ray=C(),this._viewport=k(0,0,1,1),this._padding=k(0,0,0,0),this._fov=55/180*Math.PI,this._nearFar=d(1,1e3),this._viewDirty=!0,this._viewMatrix=v(),this._projectionDirty=!0,this._projectionMatrix=v(),this._viewProjectionDirty=!0,this._viewProjectionMatrix=v(),this._viewInverseTransposeMatrixDirty=!0,this._viewInverseTransposeMatrix=v(),this._inverseProjectionDirty=!0,this._inverseProjectionMatrix=null,this._frustumDirty=!0,this._frustum=G(),this._fullViewport=B(),this._pixelRatio=1,this.relativeElevation=0,e(t)&&l(this._ray.origin,t),this._center=e(i)?I(i):V(),this._up=e(r)?I(r):S(0,0,1)}get pixelRatio(){return this._pixelRatio}set pixelRatio(t){this._pixelRatio=t>0?t:1}get eye(){return this._ray.origin}set eye(t){this._compareAndSetView(t,this._ray.origin)}get center(){return this._center}set center(t){this._compareAndSetView(t,this._center)}get ray(){return y(this._ray.direction,this.center,this.eye),this._ray}get up(){return this._up}set up(t){this._compareAndSetView(t,this._up)}get viewMatrix(){return this._ensureViewClean(),this._viewMatrix}set viewMatrix(t){o(this._viewMatrix,t),this._viewDirty=!1,this._viewInverseTransposeMatrixDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0}get viewForward(){return this._ensureViewClean(),this._viewForward}get viewUp(){return this._ensureViewClean(),this._viewUp}get viewRight(){return this._ensureViewClean(),this._viewRight}get nearFar(){return this._nearFar}get near(){return this._nearFar[0]}set near(t){this._nearFar[0]!==t&&(this._nearFar[0]=t,this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0)}get far(){return this._nearFar[1]}set far(t){this._nearFar[1]!==t&&(this._nearFar[1]=t,this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0)}get viewport(){return this._viewport}set viewport(t){this.x=t[0],this.y=t[1],this.width=t[2],this.height=t[3]}get x(){return this._viewport[0]}set x(t){t+=this._padding[it.LEFT],this._viewport[0]!==t&&(this._viewport[0]=t,this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0)}get y(){return this._viewport[1]}set y(t){t+=this._padding[it.BOTTOM],this._viewport[1]!==t&&(this._viewport[1]=t,this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0)}get width(){return this._viewport[2]}set width(t){this._viewport[2]!==t&&(this._viewport[2]=t,this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0)}get height(){return this._viewport[3]}set height(t){this._viewport[3]!==t&&(this._viewport[3]=t,this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0)}get fullWidth(){return this._viewport[2]+this._padding[it.RIGHT]+this._padding[it.LEFT]}set fullWidth(t){this.width=t-(this._padding[it.RIGHT]+this._padding[it.LEFT])}get fullHeight(){return this._viewport[3]+this._padding[it.TOP]+this._padding[it.BOTTOM]}set fullHeight(t){this.height=t-(this._padding[it.TOP]+this._padding[it.BOTTOM])}get fullViewport(){return this._fullViewport[0]=this._viewport[0]-this._padding[it.LEFT],this._fullViewport[1]=this._viewport[1]-this._padding[it.BOTTOM],this._fullViewport[2]=this.fullWidth,this._fullViewport[3]=this.fullHeight,this._fullViewport}get aspect(){return this.width/this.height}get padding(){return this._padding}set padding(t){this._padding[it.TOP]===t[it.TOP]&&this._padding[it.RIGHT]===t[it.RIGHT]&&this._padding[it.BOTTOM]===t[it.BOTTOM]&&this._padding[it.LEFT]===t[it.LEFT]||(this._viewport[0]+=t[it.LEFT]-this._padding[it.LEFT],this._viewport[1]+=t[it.BOTTOM]-this._padding[it.BOTTOM],this._viewport[2]-=t[it.RIGHT]+t[it.LEFT]-(this._padding[it.RIGHT]+this._padding[it.LEFT]),this._viewport[3]-=t[it.TOP]+t[it.BOTTOM]-(this._padding[it.TOP]+this._padding[it.BOTTOM]),E(this._padding,t),this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0)}get viewProjectionMatrix(){return this._viewProjectionDirty&&(n(this._viewProjectionMatrix,this.projectionMatrix,this.viewMatrix),this._viewProjectionDirty=!1),this._viewProjectionMatrix}get projectionMatrix(){if(this._projectionDirty){const t=this.width,i=this.height,e=this.near*Math.tan(this.fovY/2),r=e*this.aspect;a(this._projectionMatrix,-r*(1+2*this._padding[it.LEFT]/t),r*(1+2*this._padding[it.RIGHT]/t),-e*(1+2*this._padding[it.BOTTOM]/i),e*(1+2*this._padding[it.TOP]/i),this.near,this.far),this._projectionDirty=!1}return this._projectionMatrix}get inverseProjectionMatrix(){return r(this._inverseProjectionMatrix)&&(this._inverseProjectionMatrix=v()),this._inverseProjectionDirty&&_(this._inverseProjectionMatrix,this.projectionMatrix),this._inverseProjectionMatrix}set projectionMatrix(t){o(this._projectionMatrix,t),this._projectionDirty=!1,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0}get fov(){return this._fov}set fov(t){this._fov=t,this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0}get fovX(){return X(this._fov,this.width,this.height)}set fovX(t){this._fov=Y(t,this.width,this.height),this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0}get fovY(){return q(this._fov,this.width,this.height)}set fovY(t){this._fov=N(t,this.width,this.height),this._projectionDirty=!0,this._inverseProjectionDirty=!0,this._viewProjectionDirty=!0,this._frustumDirty=!0}get distance(){return g(this._center,this.eye)}get frustum(){return this._recomputeFrustum(),this._frustum}get viewInverseTransposeMatrix(){return(this._viewInverseTransposeMatrixDirty||this._viewDirty)&&(_(this._viewInverseTransposeMatrix,this.viewMatrix),p(this._viewInverseTransposeMatrix,this._viewInverseTransposeMatrix),this._viewInverseTransposeMatrixDirty=!1),this._viewInverseTransposeMatrix}depthNDCToWorld(t){const i=2*t-1;return 2*this.near*this.far/(this.far+this.near-i*(this.far-this.near))}get perRenderPixelRatio(){return Math.tan(this.fovX/2)/(this.width/2)}get perScreenPixelRatio(){return this.perRenderPixelRatio*this._pixelRatio}get aboveGround(){return this.relativeElevation&&this.relativeElevation>=0}copyFrom(t){l(this._ray.origin,t.eye),l(this._center,t.center),l(this._up,t.up),E(this._viewport,t.viewport),E(this._padding,t.padding),c(this._nearFar,t.nearFar),this._fov=t.fov,this.relativeElevation=t.relativeElevation;const i=t;return this._viewDirty=i._viewDirty,this._viewDirty||(o(this._viewMatrix,t.viewMatrix),l(this._viewRight,t.viewRight),l(this._viewUp,t.viewUp),l(this._viewForward,t.viewForward)),i._projectionDirty?this._projectionDirty=!0:(o(this._projectionMatrix,t.projectionMatrix),this._projectionDirty=!1),this._viewProjectionDirty=!0,this._inverseProjectionDirty=!0,this._frustumDirty=i._frustumDirty,this._frustumDirty||(U(this._frustum,t.frustum),this._frustumDirty=!1),i._viewInverseTransposeMatrixDirty?this._viewInverseTransposeMatrixDirty=!0:(o(this._viewInverseTransposeMatrix,t.viewInverseTransposeMatrix),this._viewInverseTransposeMatrixDirty=!1),E(this._fullViewport,t.fullViewport),this._pixelRatio=t.pixelRatio,this}copyViewFrom(t){this.eye=t.eye,this.center=t.center,this.up=t.up}clone(){return(new J).copyFrom(this)}equals(t){return m(this.eye,t.eye)&&m(this._center,t.center)&&m(this._up,t.up)&&L(this._viewport,t.viewport)&&L(this._padding,t.padding)&&w(this._nearFar,t.nearFar)&&this._fov===t.fov&&this._pixelRatio===t.pixelRatio&&this.relativeElevation===t.relativeElevation}almostEquals(t){if(this._pixelRatio!==t.pixelRatio||Math.abs(t.fov-this._fov)>=.001)return!1;const i=5e-4,e=1-1e-10;f(Z,t.eye,t.center),f($,this.eye,this._center);const r=x(Z,$),s=D(Z),h=D($);return r*r>=e*s*h&&j(t.eye,this.eye)<Math.max(s,h)*i*i&&b(t.padding,this._padding)<.5&&b(t.viewport,this._viewport)<.5}computeRenderPixelSizeAt(t){return this.computeRenderPixelSizeAtDist(this._viewDirectionDistance(t))}computeRenderPixelSizeAtDist(t){return t*this.perRenderPixelRatio}computeScreenPixelSizeAt(t){return this.computeScreenPixelSizeAtDist(this._viewDirectionDistance(t))}_viewDirectionDistance(t){return Math.abs(z(this.viewForward,y(Z,t,this.eye)))}computeScreenPixelSizeAtDist(t){return t*this.perScreenPixelRatio}computeDistanceFromRadius(t,i){return t/Math.tan(Math.min(this.fovX,this.fovY)/(2*(i||1)))}getScreenCenter(t=s()){return t[0]=(this.padding[it.LEFT]+this.width/2)/this._pixelRatio,t[1]=(this.padding[it.TOP]+this.height/2)/this._pixelRatio,t}getRenderCenter(t,i=.5,e=.5){return t[0]=this.padding[it.LEFT]+this.width*i,t[1]=this.padding[it.BOTTOM]+this.height*e,t[2]=.5,t}setGLViewport(t){const i=this.viewport,e=this.padding;t.setViewport(i[0]-e[3],i[1]-e[2],i[2]+e[1]+e[3],i[3]+e[0]+e[2])}applyProjection(t,e){t!==K&&l(K,t),K[3]=1,H(K,K,this.projectionMatrix);const r=Math.abs(K[3]);M(K,K,1/r);const s=this.fullViewport;e[0]=i(0,s[0]+s[2],.5+.5*K[0]),e[1]=i(0,s[1]+s[3],.5+.5*K[1]),e[2]=.5*(K[2]+1),e[3]=r}unapplyProjection(t,i){const e=this.fullViewport;K[0]=(t[0]/(e[0]+e[2])*2-1)*t[3],K[1]=(t[1]/(e[1]+e[3])*2-1)*t[3],K[2]=(2*t[2]-1)*t[3],K[3]=t[3],H(K,K,this.inverseProjectionMatrix),i[0]=K[0],i[1]=K[1],i[2]=K[2]}projectToScreen(t,i){this.projectToRenderScreen(t,tt),this.renderToScreen(tt,i)}projectToRenderScreen(t,e){if(K[0]=t[0],K[1]=t[1],K[2]=t[2],K[3]=1,H(K,K,this.viewProjectionMatrix),0===K[3])return null;M(K,K,1/Math.abs(K[3]));const r=this.fullViewport;return"x"in e?(e.x=i(0,r[0]+r[2],.5+.5*K[0]),e.y=i(0,r[1]+r[3],.5+.5*K[1])):(e[0]=i(0,r[0]+r[2],.5+.5*K[0]),e[1]=i(0,r[1]+r[3],.5+.5*K[1]),e.length>2&&(e[2]=.5*(K[2]+1))),e}unprojectFromScreen(t,i){return this.unprojectFromRenderScreen(this.screenToRender(t,tt),i)}unprojectFromRenderScreen(t,i){if(n(Q,this.projectionMatrix,this.viewMatrix),!_(Q,Q))return null;const e=this.fullViewport;return K[0]=2*(t[0]-e[0])/e[2]-1,K[1]=2*(t[1]-e[1])/e[3]-1,K[2]=2*t[2]-1,K[3]=1,H(K,K,Q),0===K[3]?null:(i[0]=K[0]/K[3],i[1]=K[1]/K[3],i[2]=K[2]/K[3],i)}constrainWindowSize(t,i,e,r=e){const s=t*this._pixelRatio,h=i*this._pixelRatio,o=Math.max(s-e/2,0),n=Math.max(this.fullHeight-h-r/2,0),a=-Math.min(s-e/2,0),_=-Math.min(this.fullHeight-h-r/2,0);return[o,n,e-a- -Math.min(this.fullWidth-s-e/2,0),r-_- -Math.min(h-r/2,0)]}computeUp(t){t===W.Global?this._computeUpGlobal():this._computeUpLocal()}screenToRender(t,i){const e=t[0]*this._pixelRatio,r=this.fullHeight-t[1]*this._pixelRatio;return i[0]=e,i[1]=r,i}renderToScreen(t,i){const e=t[0]/this._pixelRatio,r=(this.fullHeight-t[1])/this._pixelRatio;i[0]=e,i[1]=r}_computeUpGlobal(){y(Z,this.center,this.eye);const t=T(this.center);t<1?(P(this._up,0,0,1),this._markViewDirty()):Math.abs(x(Z,this.center))>.9999*T(Z)*t||(R(this._up,Z,this.center),R(this._up,this._up,Z),F(this._up,this._up),this._markViewDirty())}_computeUpLocal(){O(Z,this.eye,this.center),Math.abs(Z[2])<=.9999&&(M(Z,Z,Z[2]),P(this._up,-Z[0],-Z[1],1-Z[2]),F(this._up,this._up),this._markViewDirty())}_compareAndSetView(i,e){"number"==typeof i[0]&&isFinite(i[0])&&"number"==typeof i[1]&&isFinite(i[1])&&"number"==typeof i[2]&&isFinite(i[2])?m(i,e)||(l(e,i),this._markViewDirty()):t.getLogger("esri.views.3d.webgl-engine.lib.Camera").warn("Camera vector contains invalid number, ignoring value")}_markViewDirty(){this._viewDirty=!0,this._frustumDirty=!0,this._viewProjectionDirty=!0}_recomputeFrustum(){this._frustumDirty&&(A(this.viewMatrix,this.projectionMatrix,this._frustum),this._frustumDirty=!1)}_ensureViewClean(){this._viewDirty&&(u(this._viewMatrix,this.eye,this._center,this._up),P(this._viewForward,-this._viewMatrix[2],-this._viewMatrix[6],-this._viewMatrix[10]),P(this._viewUp,this._viewMatrix[1],this._viewMatrix[5],this._viewMatrix[9]),P(this._viewRight,this._viewMatrix[0],this._viewMatrix[4],this._viewMatrix[8]),this._viewDirty=!1,this._viewInverseTransposeMatrixDirty=!0)}}const K=B(),Q=v(),Z=V(),$=V(),tt=h();var it;!function(t){t[t.TOP=0]="TOP",t[t.RIGHT=1]="RIGHT",t[t.BOTTOM=2]="BOTTOM",t[t.LEFT=3]="LEFT"}(it||(it={}));export{J as Camera,it as PaddingSide};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{_ as t}from"../../../../chunks/tslib.es6.js";import{releaseMaybe as e,disposeMaybe as r,isSome as a}from"../../../../core/maybe.js";import{watch as i}from"../../../../core/reactiveUtils.js";import{property as s}from"../../../../core/accessorSupport/decorators/property.js";import"../../../../core/arrayUtils.js";import"../../../../core/has.js";import"../../../../core/accessorSupport/ensureType.js";import{subclass as o}from"../../../../core/accessorSupport/decorators/subclass.js";import{ViewingMode as h}from"../../../ViewingMode.js";import{createQuadVAO as n}from"./glUtil3D.js";import{SortedRenderGeometryRenderer as m}from"./SortedRenderGeometryRenderer.js";import{HeatmapPassParameters as p,HeatmapTechniqueConfiguration as l,HeatmapTechnique as c}from"../shaders/HeatmapTechnique.js";import{TargetType as d,DepthStencilTargetType as u,TextureType as y,TextureWrapMode as _,PixelFormat as g,PixelType as R,TextureSamplingMode as x,ClearBufferBit as f}from"../../../webgl/enums.js";import{FramebufferObject as D}from"../../../webgl/FramebufferObject.js";import{Texture as T}from"../../../webgl/Texture.js";import{vertexCount as w}from"../../../webgl/Util.js";let P=class extends m{constructor(t){super(t),this.pixelRatio=1,this._colorRampData=new Uint8ClampedArray(4),this.type="draped-heatmap",this._heatmapParameters=new p}initialize(){const t={colorTarget:d.TEXTURE,depthStencilTarget:u.NONE,width:0,height:0},e={target:y.TEXTURE_2D,pixelFormat:this.pixelFormat,internalFormat:this.internalFormat,dataType:this.dataType,samplingMode:this.samplingMode,wrapMode:_.CLAMP_TO_EDGE,width:0,height:0};this._densityMap=new D(this.rctx,t,e),this._quad=n(this.rctx);const r=this._colorRampData,a={target:y.TEXTURE_2D,pixelFormat:g.RGBA,dataType:R.UNSIGNED_BYTE,samplingMode:x.LINEAR,wrapMode:_.CLAMP_TO_EDGE,width:r.length/4,height:1};this._colorRamp=new T(this.rctx,a,r);const s=new l;s.usesHalfFloat=this.dataType!==R.FLOAT,this._technique=new c({rctx:this.rctx,viewingMode:h.Local},s),this._heatmapParameters.densityMap=this._densityMap.colorTexture,this.addHandles(i((()=>[this.colorRampData,this.minDensity,this.maxDensity,this.fieldTotal,this.pixelRatio,this.searchRadius]),(()=>this.rendererContext.notifyContentChanged())))}destroy(){this._technique=e(this._technique),this._densityMap=r(this._densityMap),this._quad=r(this._quad),this._colorRamp=r(this._colorRamp)}get searchRadius(){return this._heatmapParameters.searchRadius}set searchRadius(t){t!==this._heatmapParameters.searchRadius&&(this._heatmapParameters.searchRadius=t,this.notifyChange("searchRadius"))}get minDensity(){return this._heatmapParameters.minDensity}set minDensity(t){t!==this._heatmapParameters.minDensity&&(this._heatmapParameters.minDensity=t,this.notifyChange("minDensity"))}get maxDensity(){return this._heatmapParameters.maxDensity}set maxDensity(t){t!==this._heatmapParameters.maxDensity&&(this._heatmapParameters.maxDensity=t,this.notifyChange("maxDensity"))}get fieldTotal(){return this._heatmapParameters.fieldTotal}set fieldTotal(t){this._heatmapParameters.fieldTotal=t,this.notifyChange("fieldTotal")}get colorRampData(){return this._colorRampData}set colorRampData(t){const{colorRamp:e}=this._heatmapParameters;if(a(e)&&t!==this._colorRampData){const r=e.descriptor.width,a=t.length/4;a!==r&&e.resize(a,1),e.setData(t)}this._colorRampData=t}get _colorRamp(){return this._heatmapParameters.colorRamp}set _colorRamp(t){this._heatmapParameters.colorRamp=t}get hasHighlights(){return!1}get hasWater(){return!1}get rendersOccluded(){return!1}render(t,e){const r=this._sortedMaterialRenderers,a=r.length;if(a<1)return;const i=this.rctx.getBoundFramebufferObject(),s=this.rctx.getViewport(),{pixelRatio:o}=this,h=Math.ceil(s.width*o),n=Math.ceil(s.height*o);this._densityMap.resize(h,n),this.rctx.bindFramebuffer(this._densityMap),this.rctx.setViewport(0,0,h,n),this.rctx.clear(f.COLOR_BUFFER_BIT);let m=!1;for(let p=0;p<a;p++){const a=r.getItemAt(p);a.material.shouldRender(t)&&(m=m||a.materialRenderer.render(t.pass,e))}this.rctx.bindFramebuffer(i),this.rctx.setViewport(s.x,s.y,s.width,s.height),m&&(this.rctx.bindVAO(this._quad),this.rctx.useProgram(this._technique.program),this._technique.bindPipelineState(this.rctx),this._technique.bindPass(this._heatmapParameters,t.bindParameters),this.rctx.drawArrays(this._technique.primitiveType,0,w(this._quad,"geometry")))}};t([s()],P.prototype,"searchRadius",null),t([s()],P.prototype,"minDensity",null),t([s()],P.prototype,"maxDensity",null),t([s()],P.prototype,"fieldTotal",null),t([s()],P.prototype,"pixelRatio",void 0),t([s()],P.prototype,"colorRampData",null),t([s({constructOnly:!0})],P.prototype,"dataType",void 0),t([s({constructOnly:!0})],P.prototype,"samplingMode",void 0),t([s({constructOnly:!0})],P.prototype,"pixelFormat",void 0),t([s({constructOnly:!0})],P.prototype,"internalFormat",void 0),t([s()],P.prototype,"_colorRampData",void 0),P=t([o("esri.views.3d.webgl-engine.lib.DrapedHeatmapRenderer")],P);export{P as DrapedHeatmapRenderer};
5
+ import{_ as t}from"../../../../chunks/tslib.es6.js";import{releaseMaybe as e,disposeMaybe as r,isSome as a}from"../../../../core/maybe.js";import{watch as i}from"../../../../core/reactiveUtils.js";import{property as s}from"../../../../core/accessorSupport/decorators/property.js";import"../../../../core/arrayUtils.js";import"../../../../core/has.js";import"../../../../core/accessorSupport/ensureType.js";import{subclass as o}from"../../../../core/accessorSupport/decorators/subclass.js";import{ViewingMode as h}from"../../../ViewingMode.js";import{createQuadVAO as n}from"./glUtil3D.js";import{SortedRenderGeometryRenderer as m}from"./SortedRenderGeometryRenderer.js";import{HeatmapPassParameters as p,HeatmapTechniqueConfiguration as l,HeatmapTechnique as c}from"../shaders/HeatmapTechnique.js";import{TargetType as d,DepthStencilTargetType as u,TextureType as y,TextureWrapMode as _,PixelFormat as g,PixelType as R,TextureSamplingMode as f,ClearBufferBit as x}from"../../../webgl/enums.js";import{FramebufferObject as D}from"../../../webgl/FramebufferObject.js";import{Texture as T}from"../../../webgl/Texture.js";import{vertexCount as w}from"../../../webgl/Util.js";let b=class extends m{constructor(t){super(t),this.pixelRatio=1,this._colorRampData=new Uint8ClampedArray(4),this.type="draped-heatmap",this._heatmapParameters=new p}initialize(){const t={colorTarget:d.TEXTURE,depthStencilTarget:u.NONE,width:0,height:0},e={target:y.TEXTURE_2D,pixelFormat:this.pixelFormat,internalFormat:this.internalFormat,dataType:this.dataType,samplingMode:this.samplingMode,wrapMode:_.CLAMP_TO_EDGE,width:0,height:0};this._densityMap=new D(this.rctx,t,e),this._quad=n(this.rctx);const r=this._colorRampData,a={target:y.TEXTURE_2D,pixelFormat:g.RGBA,dataType:R.UNSIGNED_BYTE,samplingMode:f.LINEAR,wrapMode:_.CLAMP_TO_EDGE,width:r.length/4,height:1};this._colorRamp=new T(this.rctx,a,r);const s=new l;s.usesHalfFloat=this.dataType!==R.FLOAT,this._technique=new c({rctx:this.rctx,viewingMode:h.Local},s),this._heatmapParameters.densityMap=this._densityMap.colorTexture,this.addHandles(i((()=>[this.colorRampData,this.minDensity,this.maxDensity,this.fieldTotal,this.pixelRatio,this.searchRadius]),(()=>this.rendererContext.notifyContentChanged())))}destroy(){this._technique=e(this._technique),this._densityMap=r(this._densityMap),this._quad=r(this._quad),this._colorRamp=r(this._colorRamp)}get searchRadius(){return this._heatmapParameters.searchRadius}set searchRadius(t){t!==this._heatmapParameters.searchRadius&&(this._heatmapParameters.searchRadius=t,this.notifyChange("searchRadius"))}get minDensity(){return this._heatmapParameters.minDensity}set minDensity(t){t!==this._heatmapParameters.minDensity&&(this._heatmapParameters.minDensity=t,this.notifyChange("minDensity"))}get maxDensity(){return this._heatmapParameters.maxDensity}set maxDensity(t){t!==this._heatmapParameters.maxDensity&&(this._heatmapParameters.maxDensity=t,this.notifyChange("maxDensity"))}get fieldTotal(){return this._heatmapParameters.fieldTotal}set fieldTotal(t){this._heatmapParameters.fieldTotal=t,this.notifyChange("fieldTotal")}get colorRampData(){return this._colorRampData}set colorRampData(t){const{colorRamp:e}=this._heatmapParameters;if(a(e)&&t!==this._colorRampData){const r=e.descriptor.width,a=t.length/4;a!==r&&e.resize(a,1),e.setData(t)}this._colorRampData=t}get _colorRamp(){return this._heatmapParameters.colorRamp}set _colorRamp(t){this._heatmapParameters.colorRamp=t}get hasHighlights(){return!1}get hasWater(){return!1}get rendersOccluded(){return!1}render(t,e){const r=this._sortedMaterialRenderers,a=r.length;if(a<1)return;const i=this.rctx.getBoundFramebufferObject(),s=this.rctx.getViewport(),{pixelRatio:o}=this,h=Math.ceil(s.width*o),n=Math.ceil(s.height*o);this._densityMap.resize(h,n),this.rctx.bindFramebuffer(this._densityMap),this.rctx.setViewport(0,0,h,n),this.rctx.clear(x.COLOR_BUFFER_BIT);let m=!1;for(let p=0;p<a;p++){const a=r.getItemAt(p);a.material.shouldRender(t)&&(m=m||a.materialRenderer.render(t.output,e))}this.rctx.bindFramebuffer(i),this.rctx.setViewport(s.x,s.y,s.width,s.height),m&&(this.rctx.bindVAO(this._quad),this.rctx.bindTechnique(this._technique,this._heatmapParameters,t.bindParameters),this.rctx.drawArrays(this._technique.primitiveType,0,w(this._quad,"geometry")))}};t([s()],b.prototype,"searchRadius",null),t([s()],b.prototype,"minDensity",null),t([s()],b.prototype,"maxDensity",null),t([s()],b.prototype,"fieldTotal",null),t([s()],b.prototype,"pixelRatio",void 0),t([s()],b.prototype,"colorRampData",null),t([s({constructOnly:!0})],b.prototype,"dataType",void 0),t([s({constructOnly:!0})],b.prototype,"samplingMode",void 0),t([s({constructOnly:!0})],b.prototype,"pixelFormat",void 0),t([s({constructOnly:!0})],b.prototype,"internalFormat",void 0),t([s()],b.prototype,"_colorRampData",void 0),b=t([o("esri.views.3d.webgl-engine.lib.DrapedHeatmapRenderer")],b);export{b as DrapedHeatmapRenderer};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{ReloadableShaderModule as e}from"../core/shaderTechnique/ReloadableShaderModule.js";import{ShaderTechnique as r}from"../core/shaderTechnique/ShaderTechnique.js";import{Default3D as t}from"./DefaultVertexAttributeLocations.js";import{Program as o}from"./Program.js";import{E as i}from"../../../../chunks/EdgeDetect.glsl.js";import{makePipelineState as s,defaultColorWriteParams as a}from"../../../webgl/renderState.js";class l extends r{initializeProgram(e){const r=l.shader.get().build();return new o(e.rctx,r,t)}initializePipeline(){return s({colorWrite:a})}}l.shader=new e(i,(()=>import("../shaders/EdgeDetect.glsl.js")));export{l as EdgeDetectTechnique};
5
+ import{ReloadableShaderModule as e}from"../core/shaderTechnique/ReloadableShaderModule.js";import{ShaderTechnique as r}from"../core/shaderTechnique/ShaderTechnique.js";import{Default3D as t}from"./DefaultVertexAttributeLocations.js";import{Program as i}from"./Program.js";import{E as o}from"../../../../chunks/EdgeDetect.glsl.js";import{makePipelineState as s,defaultColorWriteParams as a}from"../../../webgl/renderState.js";class l extends r{initializeProgram(e){return new i(e.rctx,l.shader.get().build(),t)}initializePipeline(){return s({colorWrite:a})}}l.shader=new e(o,(()=>import("../shaders/EdgeDetect.glsl.js")));export{l as EdgeDetectTechnique};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import e from"../../../../core/Logger.js";import{isNone as t,isSome as r,disposeMaybe as i}from"../../../../core/maybe.js";import{NestedMap as s}from"../../../../core/NestedMap.js";import{assert as o}from"./Util.js";class a{constructor(e,t,r,i){this._textureRepository=e,this._techniqueRepository=t,this.materialChanged=r,this.requestRender=i,this._id2glMaterialRef=new s}dispose(){this._textureRepository.dispose()}acquire(e,r){this._ownMaterial(e);let i=this._id2glMaterialRef.get(r,e.id);if(t(i)){const t=e.createGLMaterial({material:e,techniqueRep:this._techniqueRepository,textureRep:this._textureRepository,output:r});i=new l(t),this._id2glMaterialRef.set(r,e.id,i)}return i.ref(),i.glMaterial}release(e,t){const s=this._id2glMaterialRef.get(t,e.id);r(s)&&(s.unref(),s.referenced||(i(s.glMaterial),this._id2glMaterialRef.delete(t,e.id)))}_ownMaterial(t){r(t.repository)&&t.repository!==this&&e.getLogger("esri.views.3d.webgl-engine.lib.GLMaterialRepository").error("Material is already owned by a different material repository"),t.repository=this}}class l{constructor(e){this.glMaterial=e,this.refCnt=0}ref(){++this.refCnt}unref(){--this.refCnt,o(this.refCnt>=0)}get referenced(){return this.refCnt>0}}export{a as GLMaterialRepository};
5
+ import e from"../../../../core/Logger.js";import{isNone as t,isSome as r,disposeMaybe as i}from"../../../../core/maybe.js";import{NestedMap as s}from"../../../../core/NestedMap.js";import{assert as o}from"./Util.js";class a{constructor(e,t,r,i){this._textureRepository=e,this._techniqueRepository=t,this.materialChanged=r,this.requestRender=i,this._id2glMaterialRef=new s}dispose(){this._textureRepository.dispose()}acquire(e,r,i){if(this._ownMaterial(e),!e.requiresSlot(r,i))return null;let s=this._id2glMaterialRef.get(i,e.id);if(t(s)){const t=e.createGLMaterial({material:e,techniqueRep:this._techniqueRepository,textureRep:this._textureRepository,output:i});s=new l(t),this._id2glMaterialRef.set(i,e.id,s)}return s.ref(),s.glMaterial}release(e,t){const s=this._id2glMaterialRef.get(t,e.id);r(s)&&(s.unref(),s.referenced||(i(s.glMaterial),this._id2glMaterialRef.delete(t,e.id)))}_ownMaterial(t){r(t.repository)&&t.repository!==this&&e.getLogger("esri.views.3d.webgl-engine.lib.GLMaterialRepository").error("Material is already owned by a different material repository"),t.repository=this}}class l{constructor(e){this.glMaterial=e,this.refCnt=0}ref(){++this.refCnt}unref(){--this.refCnt,o(this.refCnt>=0)}get referenced(){return this.refCnt>0}}export{a as GLMaterialRepository};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{isSome as r}from"../../../../core/maybe.js";import{ShaderOutput as e}from"../core/shaderLibrary/ShaderOutputOptions.js";import{ResourceState as t}from"./basicInterfaces.js";import{RenderPass as s}from"./RenderPass.js";class a{constructor(r,e){this._material=r,this._repository=e,this._map=new Map}destroy(){this._map.forEach(((e,t)=>{r(e)&&this._repository.release(this._material,i(t))}))}load(e,s){this._map.has(s)||this._map.set(s,this._repository.acquire(this._material,i(s)));const a=this._map.get(s);if(r(a)){if(a.ensureResources(e)===t.LOADED)return a;this._repository.requestRender()}return null}}function i(r){switch(r){case s.MATERIAL:return e.Color;case s.MATERIAL_ALPHA:return e.Alpha;case s.MATERIAL_DEPTH:return e.Depth;case s.MATERIAL_NORMAL:return e.Normal;case s.MATERIAL_DEPTH_SHADOWMAP_ALL:return e.Shadow;case s.MATERIAL_HIGHLIGHT:return e.Highlight;case s.MATERIAL_DEPTH_SHADOWMAP_HIGHLIGHT:case s.MATERIAL_DEPTH_SHADOWMAP_DEFAULT:return e.Shadow}}export{a as GLMaterials,i as outputFromPass};
5
+ import{isSome as r}from"../../../../core/maybe.js";import{ResourceState as t}from"./basicInterfaces.js";class e{constructor(r,t){this._material=r,this._repository=t,this._map=new Map}destroy(){this._map.forEach(((t,e)=>{r(t)&&this._repository.release(this._material,e)}))}load(e,s,i){if(!this._material.requiresSlot(s,i))return null;this._map.has(i)||this._map.set(i,this._repository.acquire(this._material,s,i));const a=this._map.get(i);if(r(a)){if(a.ensureResources(e)===t.LOADED)return a;this._repository.requestRender()}return null}}export{e as GLMaterials};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{isSome as e}from"../../../../core/maybe.js";import{NoParameters as r}from"../core/shaderModules/interfaces.js";import{ContentObject as t}from"./ContentObject.js";import{ContentObjectType as s}from"./ContentObjectType.js";import{Default3D as i}from"./DefaultVertexAttributeLocations.js";import{copyParameters as a,updateParameters as n}from"../materials/internal/MaterialUtil.js";class d extends t{constructor(e,r){super(),this.type=s.Material,this.supportsEdges=!1,this._visible=!0,this._renderPriority=0,this._insertOrder=0,this._vertexAttributeLocations=i,this._parameters=a(e,r),this.validateParameters(this._parameters)}dispose(){}get parameters(){return this._parameters}update(e){return!1}setParameters(e,r=!0){n(this._parameters,e)&&(this.validateParameters(this._parameters),r&&this.parametersChanged())}validateParameters(e){}get visible(){return this._visible}set visible(e){e!==this._visible&&(this._visible=e,this.parametersChanged())}shouldRender(e){return this.isVisible()&&this.isVisibleInPass(e.pass)&&0!=(this.renderOccluded&e.renderOccludedMask)}isVisibleInPass(e){return!0}get renderOccluded(){return this.parameters.renderOccluded}get renderPriority(){return this._renderPriority}set renderPriority(e){e!==this._renderPriority&&(this._renderPriority=e,this.parametersChanged())}get insertOrder(){return this._insertOrder}set insertOrder(e){e!==this._insertOrder&&(this._insertOrder=e,this.parametersChanged())}get vertexAttributeLocations(){return this._vertexAttributeLocations}isVisible(){return this._visible}parametersChanged(){e(this.repository)&&this.repository.materialChanged(this)}}var h;!function(e){e[e.Occlude=1]="Occlude",e[e.Transparent=2]="Transparent",e[e.OccludeAndTransparent=4]="OccludeAndTransparent",e[e.OccludeAndTransparentStencil=8]="OccludeAndTransparentStencil",e[e.Opaque=16]="Opaque"}(h||(h={}));class o extends r{constructor(){super(...arguments),this.renderOccluded=h.Occlude}}export{d as Material,o as MaterialParameters,h as RenderOccludedFlag};
5
+ import{isSome as e}from"../../../../core/maybe.js";import{NoParameters as r}from"../core/shaderModules/interfaces.js";import{ContentObject as t}from"./ContentObject.js";import{ContentObjectType as s}from"./ContentObjectType.js";import{Default3D as i}from"./DefaultVertexAttributeLocations.js";import{copyParameters as a,updateParameters as n}from"../materials/internal/MaterialUtil.js";class d extends t{constructor(e,r){super(),this.type=s.Material,this.supportsEdges=!1,this._visible=!0,this._renderPriority=0,this._insertOrder=0,this._vertexAttributeLocations=i,this._parameters=a(e,r),this.validateParameters(this._parameters)}dispose(){}get parameters(){return this._parameters}update(e){return!1}setParameters(e,r=!0){n(this._parameters,e)&&(this.validateParameters(this._parameters),r&&this.parametersChanged())}validateParameters(e){}get visible(){return this._visible}set visible(e){e!==this._visible&&(this._visible=e,this.parametersChanged())}shouldRender(e){return this.isVisible()&&this.isVisibleForOutput(e.output)&&0!=(this.renderOccluded&e.renderOccludedMask)}isVisibleForOutput(e){return!0}get renderOccluded(){return this.parameters.renderOccluded}get renderPriority(){return this._renderPriority}set renderPriority(e){e!==this._renderPriority&&(this._renderPriority=e,this.parametersChanged())}get insertOrder(){return this._insertOrder}set insertOrder(e){e!==this._insertOrder&&(this._insertOrder=e,this.parametersChanged())}get vertexAttributeLocations(){return this._vertexAttributeLocations}isVisible(){return this._visible}parametersChanged(){e(this.repository)&&this.repository.materialChanged(this)}}var o;!function(e){e[e.Occlude=1]="Occlude",e[e.Transparent=2]="Transparent",e[e.OccludeAndTransparent=4]="OccludeAndTransparent",e[e.OccludeAndTransparentStencil=8]="OccludeAndTransparentStencil",e[e.Opaque=16]="Opaque"}(o||(o={}));class h extends r{constructor(){super(...arguments),this.renderOccluded=o.Occlude}}export{d as Material,h as MaterialParameters,o as RenderOccludedFlag};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{isSome as e}from"../../../../core/maybe.js";import{TransparencyPassType as t}from"./basicInterfaces.js";import{RenderTargetHelper as r}from"./RenderTargetHelper.js";import{AlphaMode as i,CompositingFunction as o}from"../shaders/CompositingTechniqueConfiguration.js";import{ContextType as s}from"../../../webgl/context-util.js";import{PixelType as a,SizedPixelFormat as h,PixelFormat as n,TextureSamplingMode as l,ClearBufferBit as g}from"../../../webgl/enums.js";class T{constructor(e,t){this._rctx=e,this._compositingHelper=t,this._mainColorTarget=0,this._dimensions={width:4,height:4},this._needLastFrameColorTexture=!1,this._background={type:"color",color:[0,0,0,1]};const i=e.type===s.WEBGL2;this._renderTargetHelper=new r(e);const o=this._renderTargetHelper;this.mainColorTargets=[o.registerColorTarget({name:"mainColorTarget0"}),o.registerColorTarget({name:"mainColorTarget1"})],this.frontFaceTarget=o.registerColorTarget({name:"frontFaceTarget"});const g=e=>o.registerColorTarget({name:e,dataType:a.FLOAT,internalFormat:i?h.RGBA32F:n.RGBA,samplingMode:l.NEAREST});this.colorFloatTarget=g("colorFloatTarget"),this.alphaFloatTarget=g("alphaFloatTarget"),this.mainDepth=o.registerDepthTarget({name:"mainDepth"}),this.linearDepth=o.registerColorTarget({name:"linearDepth",samplingMode:l.NEAREST}),this.terrainLinearDepth=o.registerColorTarget({name:"terrainLinearDepth"}),this.geometryLinearDepth=o.registerColorTarget({name:"geometryLinearDepth"}),this.normal=o.registerColorTarget({name:"normal"}),this.highlight=o.registerColorTarget({name:"highlight",internalFormat:i?h.RGBA4:n.RGBA,dataType:a.UNSIGNED_SHORT_4_4_4_4}),this.hudVisibility=o.registerColorTarget({name:"hudVisibility",internalFormat:i?h.RGBA4:n.RGBA,dataType:a.UNSIGNED_SHORT_4_4_4_4}),this.tmpColor=o.registerColorTarget({name:"tmpColor"}),this.tmpDepth=o.registerDepthTarget({name:"tmpDepth"}),this.hudColor=o.registerColorTarget({name:"hudColor"})}dispose(){this._renderTargetHelper.dispose()}get width(){return this._dimensions.width}get height(){return this._dimensions.height}set background(e){this._background=e}get background(){return this._background}get currentColorTarget(){return this.mainColorTargets[this._mainColorTarget]}get previousColorTarget(){return this.mainColorTargets[1-this._mainColorTarget]}get framebuffer(){return this.getFramebuffer(this.currentColorTarget,this.mainDepth)}getFramebuffer(e,t){return this._renderTargetHelper.getFramebuffer(this._dimensions,e,t)}get colorTexture(){return this._renderTargetHelper.getAllocatedColorTexture(this.currentColorTarget)}get depthTexture(){return this._renderTargetHelper.getAllocatedDepthTexture(this.mainDepth)}get linearDepthTexture(){return this._renderTargetHelper.getAllocatedColorTexture(this.linearDepth)}get terrainLinearDepthTexture(){return this._renderTargetHelper.getAllocatedColorTexture(this.terrainLinearDepth)}get geometryLinearDepthTexture(){return this._renderTargetHelper.getAllocatedColorTexture(this.geometryLinearDepth)}get lastFrameColorTexture(){return this._renderTargetHelper.getAllocatedColorTexture(this.previousColorTarget)}get normalTexture(){return this._renderTargetHelper.getAllocatedColorTexture(this.normal)}get highlightTexture(){return this._renderTargetHelper.getAllocatedColorTexture(this.highlight)}get hudVisibilityTexture(){return this._getColorTexture(this.hudVisibility)}get tmpColorTexture(){return this._getColorTexture(this.tmpColor)}get hudColorTexture(){return this._getColorTexture(this.hudColor)}get mainColorTexture(){return this._getColorTexture(this.currentColorTarget)}advanceCurrentRenderTarget(){this._mainColorTarget=0===this._mainColorTarget&&this._needLastFrameColorTexture?1:0}initializeFrame(e){const t=this._rctx;this._dimensions.width=e.fullWidth,this._dimensions.height=e.fullHeight,this.bindTarget(this.currentColorTarget,this.mainDepth),t.setClearStencil(0);const r=this._background.color;t.setClearColor(r[0]*r[3],r[1]*r[3],r[2]*r[3],r[3]),t.clearSafe(g.COLOR_BUFFER_BIT|g.DEPTH_BUFFER_BIT|g.STENCIL_BUFFER_BIT)}composite(t){e(this.colorTexture)&&this._compositingHelper.composite(t,this.colorTexture,i.None)}renderTmpAndCompositeToMain(e,t,r,i=!1){this.renderToTargets(e,this.tmpColor,i?this.tmpDepth:this.mainDepth,m),this._compositingHelper.composite(t,this._getColorTexture(this.tmpColor),r)}renderHUDVisibility(e,t=!1){this.renderToTargets(e,this.hudVisibility,t?this.tmpDepth:this.mainDepth,p)}compositeTransparentTerrainOntoHUDVisibility(e){this.renderToTargets((()=>this._compositingHelper.composite(e,this._getColorTexture(this.tmpColor),i.None,1,o.TransparentToHUDVisibility)),this.hudVisibility,this.tmpDepth)}renderOITPass(e,r,i){let o,s;switch(r){case t.Color:o=this.colorFloatTarget,s=[0,0,0,0];break;case t.Alpha:o=this.alphaFloatTarget,s=[1,1,1,1];break;case t.FrontFace:o=this.frontFaceTarget,s=[0,0,0,0]}i?this.renderToTargets(e,o,this.tmpDepth,s,!0,!0):this.renderToTargets(e,o,this.mainDepth,s,!1)}compositeTransparentTerrainOntoMain(e){this.bindFramebuffer(),this._compositingHelper.composite(e,this._getColorTexture(this.tmpColor),i.PremultipliedAlpha)}compositeOccludedOntoMain(e,t){this.bindFramebuffer(),this._compositingHelper.composite(e,this._getColorTexture(this.tmpColor),i.PremultipliedAlpha,t)}compositeTransparentOntoOpaque(e,t){t?(this.bindTarget(this.hudColor,this.tmpDepth),this._rctx.setClearColor(0,0,0,1e-13),this._rctx.clearSafe(g.COLOR_BUFFER_BIT)):this.bindFramebuffer(),this._compositingHelper.compositeTransparent(e,this._getColorTexture(this.colorFloatTarget),this._getColorTexture(this.alphaFloatTarget),this._getColorTexture(this.frontFaceTarget))}bindFramebuffer(){this._rctx.bindFramebuffer(this.framebuffer)}renderDepthDetached(e){this.bindTarget(this.currentColorTarget),e(),this.bindTarget(this.currentColorTarget,this.mainDepth)}disposeTarget(e){this._renderTargetHelper.disposeTargetResource(e)}set needLastFrameColorTexture(e){!e&&this._needLastFrameColorTexture&&(this._mainColorTarget=0,this.disposeTarget(this.mainColorTargets[1])),this._needLastFrameColorTexture=e}get needLastFrameColorTexture(){return this._needLastFrameColorTexture}renderToTargets(e,t,r,i,o=!1,s=!1){const a=this._rctx,h=this.bindTarget(t,r);let n=0;if(i){const e=1e-13,t=Math.max(e,i[3]);a.setClearColor(i[0],i[1],i[2],t),n|=g.COLOR_BUFFER_BIT}return o&&(n|=g.DEPTH_BUFFER_BIT),!1===s?s=0:(!0===s&&(s=255),n|=g.STENCIL_BUFFER_BIT),n&&a.clearSafe(n,s),e(),a.gl.flush(),this.bindTarget(this.currentColorTarget,this.mainDepth),h}bindTarget(e,t){const r=this._renderTargetHelper.getFramebuffer(this._dimensions,e,t);return this._rctx.bindFramebuffer(r),r}_getColorTexture(e){return this._renderTargetHelper.getColorTexture(e,this._dimensions)}get gpuMemoryUsage(){let e=0;return this._renderTargetHelper&&(e+=this._renderTargetHelper.gpuMemoryUsage),e}}const m=[0,0,0,0],p=[0,1,0,1];export{T as OffscreenRendering};
5
+ import{isSome as e}from"../../../../core/maybe.js";import{RenderTargetHelper as t}from"./RenderTargetHelper.js";import{TransparencyPassType as r}from"./TransparencyPassType.js";import{AlphaMode as i,CompositingFunction as o}from"../shaders/CompositingTechniqueConfiguration.js";import{ContextType as s}from"../../../webgl/context-util.js";import{PixelType as a,SizedPixelFormat as h,PixelFormat as n,TextureSamplingMode as l,ClearBufferBit as g}from"../../../webgl/enums.js";class T{constructor(e,r){this._rctx=e,this._compositingHelper=r,this._mainColorTarget=0,this._dimensions={width:4,height:4},this._needLastFrameColorTexture=!1,this._background={type:"color",color:[0,0,0,1]};const i=e.type===s.WEBGL2;this._renderTargetHelper=new t(e);const o=this._renderTargetHelper;this.mainColorTargets=[o.registerColorTarget({name:"mainColorTarget0"}),o.registerColorTarget({name:"mainColorTarget1"})],this.frontFaceTarget=o.registerColorTarget({name:"frontFaceTarget"});const g=e=>o.registerColorTarget({name:e,dataType:a.FLOAT,internalFormat:i?h.RGBA32F:n.RGBA,samplingMode:l.NEAREST});this.colorFloatTarget=g("colorFloatTarget"),this.alphaFloatTarget=g("alphaFloatTarget"),this.mainDepth=o.registerDepthTarget({name:"mainDepth"}),this.linearDepth=o.registerColorTarget({name:"linearDepth",samplingMode:l.NEAREST}),this.terrainLinearDepth=o.registerColorTarget({name:"terrainLinearDepth"}),this.geometryLinearDepth=o.registerColorTarget({name:"geometryLinearDepth"}),this.normal=o.registerColorTarget({name:"normal"}),this.highlight=o.registerColorTarget({name:"highlight",internalFormat:i?h.RGBA4:n.RGBA,dataType:a.UNSIGNED_SHORT_4_4_4_4}),this.hudVisibility=o.registerColorTarget({name:"hudVisibility",internalFormat:i?h.RGBA4:n.RGBA,dataType:a.UNSIGNED_SHORT_4_4_4_4}),this.tmpColor=o.registerColorTarget({name:"tmpColor"}),this.tmpDepth=o.registerDepthTarget({name:"tmpDepth"}),this.hudColor=o.registerColorTarget({name:"hudColor"})}dispose(){this._renderTargetHelper.dispose()}get width(){return this._dimensions.width}get height(){return this._dimensions.height}set background(e){this._background=e}get background(){return this._background}get currentColorTarget(){return this.mainColorTargets[this._mainColorTarget]}get previousColorTarget(){return this.mainColorTargets[1-this._mainColorTarget]}get framebuffer(){return this.getFramebuffer(this.currentColorTarget,this.mainDepth)}getFramebuffer(e,t){return this._renderTargetHelper.getFramebuffer(this._dimensions,e,t)}get colorTexture(){return this._renderTargetHelper.getAllocatedColorTexture(this.currentColorTarget)}get depthTexture(){return this._renderTargetHelper.getAllocatedDepthTexture(this.mainDepth)}get linearDepthTexture(){return this._renderTargetHelper.getAllocatedColorTexture(this.linearDepth)}get terrainLinearDepthTexture(){return this._renderTargetHelper.getAllocatedColorTexture(this.terrainLinearDepth)}get geometryLinearDepthTexture(){return this._renderTargetHelper.getAllocatedColorTexture(this.geometryLinearDepth)}get lastFrameColorTexture(){return this._renderTargetHelper.getAllocatedColorTexture(this.previousColorTarget)}get normalTexture(){return this._renderTargetHelper.getAllocatedColorTexture(this.normal)}get highlightTexture(){return this._renderTargetHelper.getAllocatedColorTexture(this.highlight)}get hudVisibilityTexture(){return this._getColorTexture(this.hudVisibility)}get tmpColorTexture(){return this._getColorTexture(this.tmpColor)}get hudColorTexture(){return this._getColorTexture(this.hudColor)}get mainColorTexture(){return this._getColorTexture(this.currentColorTarget)}advanceCurrentRenderTarget(){this._mainColorTarget=0===this._mainColorTarget&&this._needLastFrameColorTexture?1:0}initializeFrame(e){const t=this._rctx;this._dimensions.width=e.fullWidth,this._dimensions.height=e.fullHeight,this.bindTarget(this.currentColorTarget,this.mainDepth),t.setClearStencil(0);const r=this._background.color;t.setClearColor(r[0]*r[3],r[1]*r[3],r[2]*r[3],r[3]),t.clearSafe(g.COLOR_BUFFER_BIT|g.DEPTH_BUFFER_BIT|g.STENCIL_BUFFER_BIT)}composite(t){e(this.colorTexture)&&this._compositingHelper.composite(t,this.colorTexture,i.None)}renderTmpAndCompositeToMain(e,t,r,i=!1){this.renderToTargets(e,this.tmpColor,i?this.tmpDepth:this.mainDepth,p),this._compositingHelper.composite(t,this._getColorTexture(this.tmpColor),r)}renderHUDVisibility(e,t=!1){this.renderToTargets(e,this.hudVisibility,t?this.tmpDepth:this.mainDepth,m)}compositeTransparentTerrainOntoHUDVisibility(e){this.renderToTargets((()=>this._compositingHelper.composite(e,this._getColorTexture(this.tmpColor),i.None,1,o.TransparentToHUDVisibility)),this.hudVisibility,this.tmpDepth)}renderOITPass(e,t,i){let o,s;switch(t){case r.Color:o=this.colorFloatTarget,s=[0,0,0,0];break;case r.Alpha:o=this.alphaFloatTarget,s=[1,1,1,1];break;case r.FrontFace:o=this.frontFaceTarget,s=[0,0,0,0]}i?this.renderToTargets(e,o,this.tmpDepth,s,!0,!0):this.renderToTargets(e,o,this.mainDepth,s,!1)}compositeTransparentTerrainOntoMain(e){this.bindFramebuffer(),this._compositingHelper.composite(e,this._getColorTexture(this.tmpColor),i.PremultipliedAlpha)}compositeOccludedOntoMain(e,t){this.bindFramebuffer(),this._compositingHelper.composite(e,this._getColorTexture(this.tmpColor),i.PremultipliedAlpha,t)}compositeTransparentOntoOpaque(e,t){t?(this.bindTarget(this.hudColor,this.tmpDepth),this._rctx.setClearColor(0,0,0,1e-13),this._rctx.clearSafe(g.COLOR_BUFFER_BIT)):this.bindFramebuffer(),this._compositingHelper.compositeTransparent(e,this._getColorTexture(this.colorFloatTarget),this._getColorTexture(this.alphaFloatTarget),this._getColorTexture(this.frontFaceTarget))}bindFramebuffer(){this._rctx.bindFramebuffer(this.framebuffer)}renderDepthDetached(e){this.bindTarget(this.currentColorTarget),e(),this.bindTarget(this.currentColorTarget,this.mainDepth)}disposeTarget(e){this._renderTargetHelper.disposeTargetResource(e)}set needLastFrameColorTexture(e){!e&&this._needLastFrameColorTexture&&(this._mainColorTarget=0,this.disposeTarget(this.mainColorTargets[1])),this._needLastFrameColorTexture=e}get needLastFrameColorTexture(){return this._needLastFrameColorTexture}renderToTargets(e,t,r,i,o=!1,s=!1){const a=this._rctx,h=this.bindTarget(t,r);let n=0;if(i){const e=1e-13,t=Math.max(e,i[3]);a.setClearColor(i[0],i[1],i[2],t),n|=g.COLOR_BUFFER_BIT}return o&&(n|=g.DEPTH_BUFFER_BIT),!1===s?s=0:(!0===s&&(s=255),n|=g.STENCIL_BUFFER_BIT),n&&a.clearSafe(n,s),e(),a.gl.flush(),this.bindTarget(this.currentColorTarget,this.mainDepth),h}bindTarget(e,t){const r=this._renderTargetHelper.getFramebuffer(this._dimensions,e,t);return this._rctx.bindFramebuffer(r),r}_getColorTexture(e){return this._renderTargetHelper.getColorTexture(e,this._dimensions)}get gpuMemoryUsage(){let e=0;return this._renderTargetHelper&&(e+=this._renderTargetHelper.gpuMemoryUsage),e}}const p=[0,0,0,0],m=[0,1,0,1];export{T as OffscreenRendering};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{TransparencyPassType as n}from"./basicInterfaces.js";import{BlendFactor as r,CompareFunction as t}from"../../../webgl/enums.js";import{separateBlendingParams as e,simpleBlendingParams as o,defaultDepthWriteParams as u}from"../../../webgl/renderState.js";const c=e(r.SRC_ALPHA,r.ONE,r.ONE_MINUS_SRC_ALPHA,r.ONE_MINUS_SRC_ALPHA),N=o(r.ONE,r.ONE),A=o(r.ZERO,r.ONE_MINUS_SRC_ALPHA);function E(r){return r===n.FrontFace?null:r===n.Alpha?A:N}function S(r){return r===n.FrontFace?u:null}const _=5e5,f={factor:-1,units:-2};function i(n){return n?f:null}function l(r,e=t.LESS){return r===n.NONE||r===n.FrontFace?e:t.LEQUAL}export{f as OITPolygonOffset,_ as OITPolygonOffsetLimit,A as blendingAlpha,N as blendingColor,c as blendingDefault,i as getOITPolygonOffset,E as oitBlending,l as oitDepthTest,S as oitDepthWrite};
5
+ import{TransparencyPassType as n}from"./TransparencyPassType.js";import{BlendFactor as r,CompareFunction as t}from"../../../webgl/enums.js";import{separateBlendingParams as e,simpleBlendingParams as o,defaultDepthWriteParams as u}from"../../../webgl/renderState.js";const c=e(r.SRC_ALPHA,r.ONE,r.ONE_MINUS_SRC_ALPHA,r.ONE_MINUS_SRC_ALPHA),N=o(r.ONE,r.ONE),s=o(r.ZERO,r.ONE_MINUS_SRC_ALPHA);function A(r){return r===n.FrontFace?null:r===n.Alpha?s:N}function E(r){return r===n.FrontFace?u:null}const S=5e5,_={factor:-1,units:-2};function a(n){return n?_:null}function l(r,e=t.LESS){return r===n.NONE||r===n.FrontFace?e:t.LEQUAL}export{_ as OITPolygonOffset,S as OITPolygonOffsetLimit,s as blendingAlpha,N as blendingColor,c as blendingDefault,a as getOITPolygonOffset,A as oitBlending,l as oitDepthTest,E as oitDepthWrite};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.25/esri/copyright.txt for details.
4
4
  */
5
- import{isSome as e}from"../../../../core/maybe.js";import{BindParameters as s}from"./BindParameters.js";import{Camera as r}from"./Camera.js";import{RenderOccludedFlag as t}from"./Material.js";import{RenderPass as a}from"./RenderPass.js";class n{constructor(t,n,c,l=null){this.rctx=t,this.sliceHelper=l,this.lastFrameCamera=new r,this.pass=a.MATERIAL,this.renderOccludedMask=i,this.bindParameters=new s(n,c,e(l)?l.plane:null)}resetRenderOccludedMask(){this.renderOccludedMask=i}get isHighlightPass(){return this.pass===a.MATERIAL_HIGHLIGHT}}class c extends n{constructor(e,s,r,t,a){super(e,r,t,a),this.offscreenRenderingHelper=s,this.sliceHelper=a}}const i=t.Occlude|t.OccludeAndTransparent|t.OccludeAndTransparentStencil;export{n as OverlayRenderContext,c as RenderContext};
5
+ import{isSome as e}from"../../../../core/maybe.js";import{ShaderOutput as r}from"../core/shaderLibrary/ShaderOutput.js";import{BindParameters as s}from"./BindParameters.js";import{Camera as t}from"./Camera.js";import{RenderOccludedFlag as a}from"./Material.js";class c{constructor(a,c,n,l=null){this.rctx=a,this.sliceHelper=l,this.lastFrameCamera=new t,this.output=r.Color,this.renderOccludedMask=i,this.bindParameters=new s(c,n,e(l)?l.plane:null)}resetRenderOccludedMask(){this.renderOccludedMask=i}}class n extends c{constructor(e,r,s,t,a){super(e,s,t,a),this.offscreenRenderingHelper=r,this.sliceHelper=a}}const i=a.Occlude|a.OccludeAndTransparent|a.OccludeAndTransparentStencil;export{c as OverlayRenderContext,n as RenderContext};