@arcgis/core 5.1.0-next.64 → 5.1.0-next.66

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 (802) hide show
  1. package/Camera.d.ts +1 -1
  2. package/Ground.d.ts +7 -7
  3. package/PopupTemplate.d.ts +8 -8
  4. package/WebDocument2D.js +1 -1
  5. package/WebScene.d.ts +1 -1
  6. package/WebScene.js +1 -1
  7. package/analysis/AreaMeasurementAnalysis.d.ts +1 -1
  8. package/analysis/DirectLineMeasurementAnalysis.d.ts +1 -1
  9. package/analysis/LengthDimension.d.ts +4 -4
  10. package/analysis/ShadowCastAnalysis.d.ts +3 -3
  11. package/analysis/SliceAnalysis.d.ts +1 -1
  12. package/analysis/SlicePlane.d.ts +1 -1
  13. package/applications/Components/featureUtils.d.ts +24 -0
  14. package/applications/Components/featureUtils.js +1 -1
  15. package/applications/KnowledgeStudio/generalSdkInternalAccess.d.ts +11 -1
  16. package/applications/KnowledgeStudio/generalSdkInternalAccess.js +1 -1
  17. package/applications/WebEditor/drawToolZSnapping.d.ts +17 -0
  18. package/applications/WebEditor/drawToolZSnapping.js +2 -0
  19. package/arcade/Dictionary.js +1 -1
  20. package/arcade/Feature.js +1 -1
  21. package/arcade/Pixel.js +1 -1
  22. package/arcade/Voxel.js +1 -1
  23. package/arcade/geometry/wkt.js +1 -1
  24. package/assets/esri/core/workers/RemoteClient.js +1 -1
  25. package/assets/esri/core/workers/chunks/01be1315c60810651783.js +1 -0
  26. package/assets/esri/core/workers/chunks/02e8fc598ee09cf1b678.js +1 -0
  27. package/assets/esri/core/workers/chunks/0d650b0d090a425c9c18.js +1 -0
  28. package/assets/esri/core/workers/chunks/0e90e9ea1ad587eb3495.js +1 -0
  29. package/assets/esri/core/workers/chunks/0f196ec93925dfefc69a.js +1 -0
  30. package/assets/esri/core/workers/chunks/12294f8c32c34788b6de.js +1 -0
  31. package/assets/esri/core/workers/chunks/13a8346abe5509167578.js +1 -0
  32. package/assets/esri/core/workers/chunks/1515824f11ef5ab95378.js +1 -0
  33. package/assets/esri/core/workers/chunks/151c2766a4cacc6adbd6.js +1 -0
  34. package/assets/esri/core/workers/chunks/155f57fe9886ef322e2a.js +1 -0
  35. package/assets/esri/core/workers/chunks/170f4d83555d238e365b.js +1 -0
  36. package/assets/esri/core/workers/chunks/171cca726a763c770469.js +1 -0
  37. package/assets/esri/core/workers/chunks/17445fd8048966617d49.js +1 -0
  38. package/assets/esri/core/workers/chunks/1761dc5799850ca7b66c.js +1 -0
  39. package/assets/esri/core/workers/chunks/17d54e77001ccb48a258.js +1 -0
  40. package/assets/esri/core/workers/chunks/19afacc9a741038e4bfb.js +1 -0
  41. package/assets/esri/core/workers/chunks/1d8777266fb1c5cfca55.js +1 -0
  42. package/assets/esri/core/workers/chunks/1f16bc8c02d8c4b2f693.js +1 -0
  43. package/assets/esri/core/workers/chunks/1f76c06af4682c85bc21.js +1 -0
  44. package/assets/esri/core/workers/chunks/{9eef3cd5f519c8ae88c0.js → 205e957ffd7e95f530f7.js} +1 -1
  45. package/assets/esri/core/workers/chunks/{fa6e1ad099b43a6f5501.js → 21a8e2a11ffacc226e2b.js} +1 -1
  46. package/assets/esri/core/workers/chunks/{811b378fa5bf8a4d3d66.js → 224461c1d9755966d0b6.js} +1 -1
  47. package/assets/esri/core/workers/chunks/27262083d37fe623ca9c.js +1 -0
  48. package/assets/esri/core/workers/chunks/2a3145a595d19391bb8a.js +1 -0
  49. package/assets/esri/core/workers/chunks/2a65bbe6c63c384cbf5f.js +1 -0
  50. package/assets/esri/core/workers/chunks/2fa69ca3ba8c442dd7d6.js +1 -0
  51. package/assets/esri/core/workers/chunks/314140e2e9b813191907.js +1 -0
  52. package/assets/esri/core/workers/chunks/32e22d6eee9fed1f70b0.js +1 -0
  53. package/assets/esri/core/workers/chunks/{af40e2e6eaf3d2226812.js → 3464a38e758c687a28d4.js} +1 -1
  54. package/assets/esri/core/workers/chunks/38816f95e801f1c5bbad.js +1 -0
  55. package/assets/esri/core/workers/chunks/3f8e8f83ebda07d29ca8.js +1 -0
  56. package/assets/esri/core/workers/chunks/41396724040180d2537f.js +1 -0
  57. package/assets/esri/core/workers/chunks/{66baacbef23291eab853.js → 413d2fa54508e6f42c74.js} +1 -1
  58. package/assets/esri/core/workers/chunks/{32e9e92bbbd000fbbaf7.js → 4141a3a93732996601e8.js} +2 -2
  59. package/assets/esri/core/workers/chunks/41e59d75ccb51a238739.js +1 -0
  60. package/assets/esri/core/workers/chunks/44016e1176629c36bc11.js +1 -0
  61. package/assets/esri/core/workers/chunks/468c70e5fdb61dfaad80.js +1 -0
  62. package/assets/esri/core/workers/chunks/4d069a0ebadb9c53b550.js +1 -0
  63. package/assets/esri/core/workers/chunks/4e7b084f7104deea1ddb.js +1 -0
  64. package/assets/esri/core/workers/chunks/{9c72127de7afcbaafbaf.js → 51852ef71ac04954fdae.js} +1 -1
  65. package/assets/esri/core/workers/chunks/549a51dedcc49f366e53.js +1 -0
  66. package/assets/esri/core/workers/chunks/{42e084704dea6e4135b6.js → 54c0306082d30d59cba2.js} +1 -1
  67. package/assets/esri/core/workers/chunks/56036327e721f9c42b33.js +1 -0
  68. package/assets/esri/core/workers/chunks/57cdd5d4ae073d5ca725.js +1 -0
  69. package/assets/esri/core/workers/chunks/5b9257c5359fa05f4f28.js +1 -0
  70. package/assets/esri/core/workers/chunks/5d574079f0e96e883aab.js +1 -0
  71. package/assets/esri/core/workers/chunks/5d967bcf71c05ddb1ab6.js +1 -0
  72. package/assets/esri/core/workers/chunks/5fccb372b4d5ee2f64cc.js +1 -0
  73. package/assets/esri/core/workers/chunks/61778185d702da468b00.js +1 -0
  74. package/assets/esri/core/workers/chunks/61794a861a9209b72622.js +1 -0
  75. package/assets/esri/core/workers/chunks/61b49cdaf288f36f9288.js +1 -0
  76. package/assets/esri/core/workers/chunks/{8ea67b502f9355dab7e9.js → 621ea864e2774f160d1c.js} +1 -1
  77. package/assets/esri/core/workers/chunks/{9d289cee96e7c7fe1029.js → 62a2da0ffc67f98445c1.js} +1 -1
  78. package/assets/esri/core/workers/chunks/{254898b41cabe313b6ce.js → 62d96b012c2d6f601863.js} +1 -1
  79. package/assets/esri/core/workers/chunks/644dd906bee3ef465ec0.js +1 -0
  80. package/assets/esri/core/workers/chunks/66692d6edc1bd96645e2.js +1 -0
  81. package/assets/esri/core/workers/chunks/679086351352756b33c9.js +1 -0
  82. package/assets/esri/core/workers/chunks/681e97ebbf9c69c410c6.js +1 -0
  83. package/assets/esri/core/workers/chunks/69520cad347947b09f21.js +1 -0
  84. package/assets/esri/core/workers/chunks/{c86b15f6a18880f921cd.js → 6a567755b67c06d16f21.js} +1 -1
  85. package/assets/esri/core/workers/chunks/{fdf4c1f202cfddf0f226.js → 6d11ec355e5474b2968b.js} +1 -1
  86. package/assets/esri/core/workers/chunks/6e7bb6d3e739527116a4.js +1 -0
  87. package/assets/esri/core/workers/chunks/751f3cfb000045ac78bb.js +1 -0
  88. package/assets/esri/core/workers/chunks/{64ad6130de549083caba.js → 789357e0f79823f145dd.js} +1 -1
  89. package/assets/esri/core/workers/chunks/{b6d94cbd1c5adad2f247.js → 78fbfc03d9b827c3f767.js} +1 -1
  90. package/assets/esri/core/workers/chunks/79df97e3f5975b42dc4d.js +1 -0
  91. package/assets/esri/core/workers/chunks/{25e4568a3ff76f48ac5e.js → 7a56c836c89a8b978800.js} +1 -1
  92. package/assets/esri/core/workers/chunks/7e97684e851274efd11f.js +1 -0
  93. package/assets/esri/core/workers/chunks/7e9b790fe01b89acdf6d.js +1 -0
  94. package/assets/esri/core/workers/chunks/7fb9a5bc22d7581f1d20.js +1 -0
  95. package/assets/esri/core/workers/chunks/{5c1abb46b9937a050c32.js → 7ffcd308087c35adda04.js} +1 -1
  96. package/assets/esri/core/workers/chunks/84eb889b9cce35dac2e5.js +1 -0
  97. package/assets/esri/core/workers/chunks/891d97d0da6361d63679.js +1 -0
  98. package/assets/esri/core/workers/chunks/8a0f254d45d00b293479.js +1 -0
  99. package/assets/esri/core/workers/chunks/8ede12f54b215c52cf3c.js +1 -0
  100. package/assets/esri/core/workers/chunks/8fed6becd107d2ed9bbd.js +1 -0
  101. package/assets/esri/core/workers/chunks/90cef6f96df7dc27db39.js +1 -0
  102. package/assets/esri/core/workers/chunks/921c30b7f4dfc3e018d9.js +1 -0
  103. package/assets/esri/core/workers/chunks/927773ed23b1fc245bf7.js +1 -0
  104. package/assets/esri/core/workers/chunks/{b056b4c79bcd542dd1d2.js → 9622a83b29acb768fcb5.js} +1 -1
  105. package/assets/esri/core/workers/chunks/97062996e1e4196cfa7c.js +1 -0
  106. package/assets/esri/core/workers/chunks/97210bcb5e3cf3ac961b.js +1 -0
  107. package/assets/esri/core/workers/chunks/{f550fc8c078ebd47d7a3.js → 97e15e66e55d9149fd48.js} +1 -1
  108. package/assets/esri/core/workers/chunks/9c819ebdc98ed8b6afcf.js +1 -0
  109. package/assets/esri/core/workers/chunks/9dfd00972c12a4adc15d.js +1 -0
  110. package/assets/esri/core/workers/chunks/9fab410b9fa668dc498b.js +1 -0
  111. package/assets/esri/core/workers/chunks/a118de5a163ae42bee60.js +1 -0
  112. package/assets/esri/core/workers/chunks/a4b6fdbc995be03d2afb.js +1 -0
  113. package/assets/esri/core/workers/chunks/a59db907ec1e31002100.js +1 -0
  114. package/assets/esri/core/workers/chunks/a5b395e518e4c5fc95d0.js +1414 -0
  115. package/assets/esri/core/workers/chunks/a5d9dbb1fef8c4465943.js +1 -0
  116. package/assets/esri/core/workers/chunks/{62c2757f5dc4aaca2df8.js → a73e8b80760dc88f926f.js} +1 -1
  117. package/assets/esri/core/workers/chunks/a96692514dcaa50340dd.js +1 -0
  118. package/assets/esri/core/workers/chunks/b4fb4484fa39eede1f62.js +1 -0
  119. package/assets/esri/core/workers/chunks/b50a42a9f96515beb929.js +1 -0
  120. package/assets/esri/core/workers/chunks/b8acb6c2538053c01cc6.js +1 -0
  121. package/assets/esri/core/workers/chunks/b8bf3e8b8b870f69f231.js +1 -0
  122. package/assets/esri/core/workers/chunks/b8e85b7d5eed6e7c79b5.js +1 -0
  123. package/assets/esri/core/workers/chunks/{fd629a3ab558adf52617.js → bc2c7cb99e227ddbd3a6.js} +1 -1
  124. package/assets/esri/core/workers/chunks/bc85bb82cfcbc216fa31.js +1 -0
  125. package/assets/esri/core/workers/chunks/{354351ab3fc79dedf9a8.js → bcb8a25438c66815e37a.js} +1 -1
  126. package/assets/esri/core/workers/chunks/be1e4c3ec53fc92a26f1.js +1 -0
  127. package/assets/esri/core/workers/chunks/be4d13088a557b7de4b1.js +1 -0
  128. package/assets/esri/core/workers/chunks/bf758d57091fa534c1f8.js +1 -0
  129. package/assets/esri/core/workers/chunks/bfd516c37fb717e14d71.js +1 -0
  130. package/assets/esri/core/workers/chunks/c22945637a40355fbe61.js +1 -0
  131. package/assets/esri/core/workers/chunks/c25a58d9f94aaa96957d.js +1 -0
  132. package/assets/esri/core/workers/chunks/c4e936879c6cb25cf586.js +1 -0
  133. package/assets/esri/core/workers/chunks/c6a43f748dbf8bac4bb5.js +1 -0
  134. package/assets/esri/core/workers/chunks/cb9185ed31109781fe59.js +1 -0
  135. package/assets/esri/core/workers/chunks/d21fdd67477800101f3b.js +1 -0
  136. package/assets/esri/core/workers/chunks/d264aed5dbe09e34040f.js +1 -0
  137. package/assets/esri/core/workers/chunks/d315098b038a96084ff5.js +1 -0
  138. package/assets/esri/core/workers/chunks/d4465fd3319d0b6a26cc.js +1 -0
  139. package/assets/esri/core/workers/chunks/{13eb0162d95b4d27389c.js → d598d08dbf2796742e8c.js} +1 -1
  140. package/assets/esri/core/workers/chunks/d5c7ebfd5c2ca635a7a8.js +1 -0
  141. package/assets/esri/core/workers/chunks/{d4368e281c12fa7c17c5.js → d635f97b7b82a37482d6.js} +1 -1
  142. package/assets/esri/core/workers/chunks/d7b92bd9198dd3b27eb5.js +1 -0
  143. package/assets/esri/core/workers/chunks/d83ac66478a419e08af6.js +1 -0
  144. package/assets/esri/core/workers/chunks/d8dde0d1759e009b8373.js +1 -0
  145. package/assets/esri/core/workers/chunks/d94dfb2ce31e59b3306b.js +1 -0
  146. package/assets/esri/core/workers/chunks/{8166ad6bbd7d7a8f91cf.js → deddf6ae4498a3d0d0e5.js} +1 -1
  147. package/assets/esri/core/workers/chunks/{45f1e682668cffc00b44.js → e0df7554b1679168663d.js} +1 -1
  148. package/assets/esri/core/workers/chunks/e0fcb5fa0e9f21fde2b6.js +1 -0
  149. package/assets/esri/core/workers/chunks/e305ced975d885c28e7e.js +1 -0
  150. package/assets/esri/core/workers/chunks/e3c60b7df2740e600066.js +1 -0
  151. package/assets/esri/core/workers/chunks/e611cd03eee4fae7c413.js +1 -0
  152. package/assets/esri/core/workers/chunks/e64a92b6f4075616f40f.js +1 -0
  153. package/assets/esri/core/workers/chunks/e78b442417f6a903b9b1.js +1 -0
  154. package/assets/esri/core/workers/chunks/{ba72989749543122a6fe.js → e9f2b573f482718306e6.js} +1 -1
  155. package/assets/esri/core/workers/chunks/ea6d3b7c7d720aa7bc94.js +1 -0
  156. package/assets/esri/core/workers/chunks/eab1b45ab5a802e29f8c.js +1 -0
  157. package/assets/esri/core/workers/chunks/eb7392799a01c2a8497a.js +1 -0
  158. package/assets/esri/core/workers/chunks/{c17c3453d014dc73fe0b.js → ef013a77950c1902de11.js} +1 -1
  159. package/assets/esri/core/workers/chunks/ef0fe4e1a9e960a74c60.js +1 -0
  160. package/assets/esri/core/workers/chunks/efbbcf467b2a27a92b85.js +1 -0
  161. package/assets/esri/core/workers/chunks/f201edf9b68717a6106d.js +1 -0
  162. package/assets/esri/core/workers/chunks/f43a63094190d2074cd0.js +1 -0
  163. package/assets/esri/core/workers/chunks/f59f1db572be1f19887f.js +1 -0
  164. package/assets/esri/core/workers/chunks/{dc07dc1cd30edc0c4193.js → f62e42659b406435573d.js} +1 -1
  165. package/assets/esri/core/workers/chunks/fa160a2a5dc9f5a7c34b.js +1 -0
  166. package/assets/esri/core/workers/chunks/fa7ae035472540999721.js +1 -0
  167. package/assets/esri/core/workers/chunks/fe3b42eadcdd9ba54f05.js +1 -0
  168. package/assets/esri/core/workers/chunks/fee31d9297648219375d.js +1 -0
  169. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_ar.json +1 -1
  170. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_bg.json +1 -1
  171. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_bs.json +1 -1
  172. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_ca.json +1 -1
  173. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_cs.json +1 -1
  174. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_da.json +1 -1
  175. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_de.json +1 -1
  176. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_el.json +1 -1
  177. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_es.json +1 -1
  178. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_et.json +1 -1
  179. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_fi.json +1 -1
  180. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_fr.json +1 -1
  181. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_he.json +1 -1
  182. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_hr.json +1 -1
  183. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_hu.json +1 -1
  184. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_id.json +1 -1
  185. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_it.json +1 -1
  186. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_ja.json +1 -1
  187. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_ko.json +1 -1
  188. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_lt.json +1 -1
  189. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_lv.json +1 -1
  190. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_nl.json +1 -1
  191. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_no.json +1 -1
  192. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_pl.json +1 -1
  193. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_pt-BR.json +1 -1
  194. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_pt-PT.json +1 -1
  195. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_ro.json +1 -1
  196. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_ru.json +1 -1
  197. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_sk.json +1 -1
  198. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_sl.json +1 -1
  199. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_sr.json +1 -1
  200. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_sv.json +1 -1
  201. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_th.json +1 -1
  202. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_tr.json +1 -1
  203. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_uk.json +1 -1
  204. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_vi.json +1 -1
  205. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_zh-CN.json +1 -1
  206. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_zh-HK.json +1 -1
  207. package/assets/esri/views/interactive/tooltip/t9n/Tooltip_zh-TW.json +1 -1
  208. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ar.json +1 -1
  209. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_bg.json +1 -1
  210. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_bs.json +1 -1
  211. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ca.json +1 -1
  212. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_cs.json +1 -1
  213. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_da.json +1 -1
  214. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_de.json +1 -1
  215. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_el.json +1 -1
  216. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_es.json +1 -1
  217. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_et.json +1 -1
  218. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_fi.json +1 -1
  219. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_fr.json +1 -1
  220. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_he.json +1 -1
  221. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_hr.json +1 -1
  222. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_hu.json +1 -1
  223. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_id.json +1 -1
  224. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_it.json +1 -1
  225. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ja.json +1 -1
  226. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ko.json +1 -1
  227. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_lt.json +1 -1
  228. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_lv.json +1 -1
  229. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_nl.json +1 -1
  230. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_no.json +1 -1
  231. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_pl.json +1 -1
  232. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_pt-BR.json +1 -1
  233. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_pt-PT.json +1 -1
  234. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ro.json +1 -1
  235. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_ru.json +1 -1
  236. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_sk.json +1 -1
  237. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_sl.json +1 -1
  238. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_sr.json +1 -1
  239. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_sv.json +1 -1
  240. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_th.json +1 -1
  241. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_tr.json +1 -1
  242. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_uk.json +1 -1
  243. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_vi.json +1 -1
  244. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_zh-CN.json +1 -1
  245. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_zh-HK.json +1 -1
  246. package/assets/esri/widgets/FeatureTable/t9n/FeatureTable_zh-TW.json +1 -1
  247. package/chunks/ComponentShader.glsl.js +1 -1
  248. package/chunks/DefaultMaterial.glsl.js +1 -1
  249. package/chunks/GaussianSplat.glsl.js +14 -2
  250. package/chunks/OITDim.glsl.js +3 -2
  251. package/chunks/Path.glsl.js +1 -1
  252. package/chunks/RealisticTree.glsl.js +1 -1
  253. package/chunks/ShadowCastAccumulate.glsl.js +2 -2
  254. package/chunks/ShadowHighlight.glsl.js +3 -3
  255. package/chunks/ShadowHighlightBuffer.glsl.js +1 -1
  256. package/chunks/Terrain.glsl.js +1 -1
  257. package/chunks/Water.glsl.js +1 -1
  258. package/config.js +1 -1
  259. package/core/timeUtils.js +1 -1
  260. package/core/workers/Connection.js +1 -1
  261. package/effects/FocusAreas.d.ts +1 -1
  262. package/form/elements/FieldElement.d.ts +3 -3
  263. package/form/elements/GroupElement.d.ts +1 -1
  264. package/form/elements/TextElement.d.ts +1 -1
  265. package/form/elements/inputs/ComboBoxInput.d.ts +1 -1
  266. package/form/elements/inputs/DateTimeOffsetPickerInput.d.ts +1 -1
  267. package/form/elements/inputs/DateTimeOffsetPickerInput.js +1 -1
  268. package/form/elements/inputs/Input.d.ts +1 -1
  269. package/form/elements/inputs/RadioButtonsInput.d.ts +1 -1
  270. package/form/elements/inputs/SwitchInput.d.ts +1 -1
  271. package/form/elements/inputs/inputUtils.js +1 -1
  272. package/form/elements/inputs.js +1 -1
  273. package/geometry/Mesh.d.ts +7 -7
  274. package/geometry/operators/alphaShapeOperator.d.ts +1 -1
  275. package/geometry/operators/areaOperator.d.ts +1 -1
  276. package/geometry/operators/bufferOperator.d.ts +1 -1
  277. package/geometry/operators/centroidOperator.d.ts +1 -1
  278. package/geometry/operators/clipOperator.d.ts +1 -1
  279. package/geometry/operators/containsOperator.d.ts +1 -1
  280. package/geometry/operators/convexHullOperator.d.ts +1 -1
  281. package/geometry/operators/crossesOperator.d.ts +1 -1
  282. package/geometry/operators/cutOperator.d.ts +1 -1
  283. package/geometry/operators/densifyOperator.d.ts +1 -1
  284. package/geometry/operators/differenceOperator.d.ts +1 -1
  285. package/geometry/operators/disjointOperator.d.ts +1 -1
  286. package/geometry/operators/distanceOperator.d.ts +1 -1
  287. package/geometry/operators/generalizeOperator.d.ts +1 -1
  288. package/geometry/operators/geodesicProximityOperator.d.ts +1 -1
  289. package/geometry/operators/geodeticDistanceOperator.d.ts +1 -1
  290. package/geometry/operators/geodeticUtilsOperator.d.ts +2 -2
  291. package/geometry/operators/graphicBufferOperator.d.ts +1 -1
  292. package/geometry/operators/intersectionOperator.d.ts +1 -1
  293. package/geometry/operators/intersectsOperator.d.ts +1 -1
  294. package/geometry/operators/isNearOperator.d.ts +1 -1
  295. package/geometry/operators/lengthOperator.d.ts +1 -1
  296. package/geometry/operators/locateBetweenOperator.d.ts +1 -1
  297. package/geometry/operators/multiPartToSinglePartOperator.d.ts +1 -1
  298. package/geometry/operators/offsetOperator.d.ts +5 -5
  299. package/geometry/operators/overlapsOperator.d.ts +1 -1
  300. package/geometry/operators/proximityOperator.d.ts +1 -1
  301. package/geometry/operators/simplifyOGCOperator.d.ts +1 -1
  302. package/geometry/operators/simplifyOperator.d.ts +1 -1
  303. package/geometry/operators/support/Transformation.d.ts +6 -6
  304. package/geometry/operators/symmetricDifferenceOperator.d.ts +1 -1
  305. package/geometry/operators/touchesOperator.d.ts +1 -1
  306. package/geometry/operators/unionOperator.d.ts +1 -1
  307. package/geometry/operators/withinOperator.d.ts +1 -1
  308. package/geometry/support/MeshMaterialMetallicRoughness.d.ts +1 -1
  309. package/geometry/support/spatialReferenceUtils.js +1 -1
  310. package/geometry/support/vcsData.js +2 -0
  311. package/geometry/support/vcsLookup.js +2 -0
  312. package/interfaces.d.ts +4 -2
  313. package/intl.js +1 -1
  314. package/kernel.js +1 -1
  315. package/layers/BuildingSceneLayer.d.ts +4 -4
  316. package/layers/CSVLayer.d.ts +2 -2
  317. package/layers/CatalogLayer.d.ts +2 -2
  318. package/layers/ElevationLayer.d.ts +1 -1
  319. package/layers/FeatureLayer.d.ts +9 -2
  320. package/layers/FeatureLayer.js +1 -1
  321. package/layers/GeoJSONLayer.d.ts +2 -2
  322. package/layers/GeoRSSLayer.d.ts +1 -1
  323. package/layers/GraphicsLayer.d.ts +2 -2
  324. package/layers/ImageryLayer.d.ts +3 -3
  325. package/layers/ImageryTileLayer.d.ts +2 -2
  326. package/layers/IntegratedMesh3DTilesLayer.d.ts +6 -6
  327. package/layers/IntegratedMeshLayer.d.ts +7 -7
  328. package/layers/MapImageLayer.d.ts +1 -1
  329. package/layers/MediaLayer.d.ts +1 -1
  330. package/layers/OGCFeatureLayer.d.ts +2 -2
  331. package/layers/PointCloudLayer.d.ts +1 -1
  332. package/layers/SceneLayer.d.ts +9 -9
  333. package/layers/StreamLayer.d.ts +2 -2
  334. package/layers/SubtypeGroupLayer.js +1 -1
  335. package/layers/VectorTileLayer.d.ts +2 -2
  336. package/layers/VideoLayer.d.ts +1 -1
  337. package/layers/VoxelLayer.d.ts +8 -8
  338. package/layers/VoxelWasmPerSceneView.js +1 -1
  339. package/layers/WFSLayer.d.ts +6 -6
  340. package/layers/catalog/CatalogFootprintLayer.d.ts +1 -1
  341. package/layers/graphics/data/AttributesBuilder.js +1 -1
  342. package/layers/graphics/sources/geojson/GeoJSONSourceWorker.js +1 -1
  343. package/layers/graphics/sources/support/MemorySourceWorker.js +1 -1
  344. package/layers/mixins/ArcGISImageService.js +1 -1
  345. package/layers/mixins/BlendLayer.d.ts +6 -6
  346. package/layers/pointCloudFilters/PointCloudReturnFilter.d.ts +1 -1
  347. package/layers/pointCloudFilters/PointCloudValueFilter.d.ts +1 -1
  348. package/layers/support/DimensionalDefinition.d.ts +2 -2
  349. package/layers/support/FeatureEffect.d.ts +4 -4
  350. package/layers/support/FeatureFilter.d.ts +17 -17
  351. package/layers/support/FeatureReductionBinning.d.ts +1 -1
  352. package/layers/support/FeatureReductionCluster.d.ts +9 -9
  353. package/layers/support/FeatureReductionSelection.d.ts +1 -1
  354. package/layers/support/LabelClass.d.ts +2 -2
  355. package/layers/support/RasterFunction.d.ts +1 -1
  356. package/layers/support/SceneFilter.d.ts +2 -2
  357. package/layers/support/SceneModification.d.ts +3 -3
  358. package/layers/support/SymbolLayerDrawing.d.ts +15 -0
  359. package/layers/support/SymbolLayerDrawing.js +2 -0
  360. package/layers/support/capabilities.js +1 -1
  361. package/layers/support/featureLayerUtils.js +1 -1
  362. package/layers/support/serviceCapabilitiesUtils.js +1 -1
  363. package/layers/types.d.ts +6 -0
  364. package/networks/support/jsonTypes.d.ts +36 -11
  365. package/package.json +4 -4
  366. package/popup/Feature.d.ts +20 -10
  367. package/popup/Feature.js +1 -1
  368. package/popup/Features.d.ts +82 -227
  369. package/popup/Features.js +1 -1
  370. package/popup/content/AttachmentsContent.d.ts +1 -1
  371. package/popup/content/BarChartMediaInfo.d.ts +1 -1
  372. package/popup/content/ColumnChartMediaInfo.d.ts +1 -1
  373. package/popup/content/FieldsContent.d.ts +1 -1
  374. package/popup/content/ImageMediaInfo.d.ts +1 -1
  375. package/popup/content/LineChartMediaInfo.d.ts +1 -1
  376. package/popup/content/MediaContent.d.ts +1 -1
  377. package/popup/content/PieChartMediaInfo.d.ts +1 -1
  378. package/popup/content/RelationshipContent.d.ts +1 -1
  379. package/popup/content/TextContent.d.ts +1 -1
  380. package/popup/support/FeatureAbilities.d.ts +45 -9
  381. package/popup/support/featureUtils.js +1 -1
  382. package/popup/types.d.ts +126 -8
  383. package/portal/schemas/definitions.js +1 -1
  384. package/renderers/ClassBreaksRenderer.d.ts +1 -1
  385. package/renderers/DictionaryRenderer.d.ts +1 -1
  386. package/renderers/DotDensityRenderer.d.ts +3 -3
  387. package/renderers/FlowRenderer.d.ts +5 -5
  388. package/renderers/HeatmapRenderer.d.ts +3 -3
  389. package/renderers/PieChartRenderer.d.ts +1 -1
  390. package/renderers/RasterShadedReliefRenderer.d.ts +1 -1
  391. package/renderers/Renderer.d.ts +4 -4
  392. package/renderers/SimpleRenderer.d.ts +2 -2
  393. package/renderers/UniqueValueRenderer.d.ts +2 -2
  394. package/renderers/VectorFieldRenderer.d.ts +1 -1
  395. package/renderers/mixins/VisualVariablesMixin.d.ts +12 -12
  396. package/renderers/visualVariables/ColorVariable.d.ts +1 -1
  397. package/renderers/visualVariables/OpacityVariable.d.ts +1 -1
  398. package/renderers/visualVariables/RotationVariable.d.ts +1 -1
  399. package/renderers/visualVariables/SizeVariable.d.ts +1 -1
  400. package/renderers/visualVariables/VisualVariable.d.ts +1 -1
  401. package/rest/query/support/AttachmentInfo.d.ts +1 -1
  402. package/rest/support/AttributeBinsQuery.d.ts +8 -8
  403. package/rest/support/AutoIntervalBinParameters.d.ts +1 -1
  404. package/rest/support/DateBinParameters.d.ts +1 -1
  405. package/rest/support/FixedBoundariesBinParameters.d.ts +1 -1
  406. package/rest/support/FixedIntervalBinParameters.d.ts +1 -1
  407. package/rest/support/Query.d.ts +8 -8
  408. package/rest/support/TopFeaturesQuery.d.ts +8 -8
  409. package/smartMapping/labels/clusters.d.ts +1 -1
  410. package/smartMapping/popup/clusters.d.ts +2 -2
  411. package/smartMapping/popup/templates.d.ts +1 -1
  412. package/smartMapping/raster/renderers/flow.d.ts +2 -2
  413. package/smartMapping/renderers/color.d.ts +12 -12
  414. package/smartMapping/renderers/predominance.d.ts +3 -3
  415. package/smartMapping/renderers/relationship.d.ts +15 -15
  416. package/smartMapping/renderers/univariateColorSize.d.ts +4 -4
  417. package/smartMapping/statistics/support/utils.js +1 -1
  418. package/smartMapping/support/adapters/support/utils.js +1 -1
  419. package/smartMapping/symbology/color.d.ts +4 -4
  420. package/smartMapping/symbology/flow.d.ts +2 -2
  421. package/smartMapping/symbology/types.d.ts +18 -18
  422. package/support/actions/ActionButton.d.ts +1 -1
  423. package/support/basemapDefinitions.js +1 -1
  424. package/support/revision.js +1 -1
  425. package/symbols/CIMSymbol.d.ts +1 -1
  426. package/symbols/ExtrudeSymbol3DLayer.d.ts +1 -1
  427. package/symbols/FillSymbol3DLayer.d.ts +3 -3
  428. package/symbols/IconSymbol3DLayer.d.ts +1 -1
  429. package/symbols/LabelSymbol3D.d.ts +2 -2
  430. package/symbols/LineStyleMarker3D.d.ts +7 -7
  431. package/symbols/LineSymbol3D.d.ts +2 -2
  432. package/symbols/LineSymbol3DLayer.d.ts +7 -7
  433. package/symbols/LineSymbolMarker.d.ts +6 -6
  434. package/symbols/MarkerSymbol.d.ts +1 -1
  435. package/symbols/MeshSymbol3D.d.ts +2 -2
  436. package/symbols/ObjectSymbol3DLayer.d.ts +1 -1
  437. package/symbols/PathSymbol3DLayer.d.ts +14 -14
  438. package/symbols/PictureFillSymbol.d.ts +1 -1
  439. package/symbols/PictureMarkerSymbol.d.ts +1 -1
  440. package/symbols/PointSymbol3D.d.ts +3 -3
  441. package/symbols/PolygonSymbol3D.d.ts +5 -5
  442. package/symbols/SimpleFillSymbol.d.ts +8 -8
  443. package/symbols/SimpleLineSymbol.d.ts +20 -20
  444. package/symbols/SimpleMarkerSymbol.d.ts +7 -7
  445. package/symbols/Symbol3DLayer.d.ts +16 -16
  446. package/symbols/TextSymbol.d.ts +1 -1
  447. package/symbols/TextSymbol3DLayer.d.ts +1 -1
  448. package/symbols/WaterSymbol3DLayer.d.ts +3 -3
  449. package/symbols/WebStyleSymbol.d.ts +12 -12
  450. package/symbols/callouts/Callout3D.d.ts +1 -1
  451. package/symbols/callouts/LineCallout3D.d.ts +3 -3
  452. package/symbols/cim/cimAnalyzer.js +1 -1
  453. package/symbols/cim/types.d.ts +29 -23
  454. package/symbols/edges/Edges3D.d.ts +1 -1
  455. package/symbols/edges/SolidEdges3D.d.ts +1 -1
  456. package/symbols/patterns/LineStylePattern3D.d.ts +11 -11
  457. package/symbols/patterns/StylePattern3D.d.ts +8 -8
  458. package/symbols/support/ElevationInfo.d.ts +2 -2
  459. package/symbols/support/IconSymbol3DLayerResource.d.ts +6 -6
  460. package/symbols/support/ObjectSymbol3DLayerResource.d.ts +7 -7
  461. package/symbols/support/Symbol3DEmissive.d.ts +2 -2
  462. package/symbols/support/Symbol3DVerticalOffset.d.ts +2 -2
  463. package/views/2d/engine/Stage.js +1 -1
  464. package/views/2d/engine/flow/FlowStrategy.js +1 -1
  465. package/views/2d/engine/flow/styles/Imagery.js +1 -1
  466. package/views/2d/engine/flow/styles/Particles.js +1 -1
  467. package/views/2d/engine/flow/styles/Stack.js +1 -1
  468. package/views/2d/engine/flow/styles/Streamlines.js +1 -1
  469. package/views/2d/engine/vectorTiles/VTLPainter3D.js +1 -1
  470. package/views/2d/engine/vectorTiles/style/StyleLayer.js +1 -1
  471. package/views/2d/engine/webgl/AttributeStoreView.js +1 -1
  472. package/views/2d/engine/webgl/FeatureDisplayList.js +1 -1
  473. package/views/2d/engine/webgl/Painter.js +1 -1
  474. package/views/2d/engine/webgl/VideoScreenRenderer.js +1 -1
  475. package/views/2d/engine/webgl/effects/FeatureEffect.js +1 -1
  476. package/views/2d/engine/webgl/effects/HighlightEffect.js +1 -1
  477. package/views/2d/engine/webgl/effects/highlight/HighlightSurfaces.js +1 -1
  478. package/views/2d/engine/webgl/shaderGraph/techniques/FeatureInstanceStore.js +1 -1
  479. package/views/2d/engine/webgl/shaderGraph/techniques/GraphicInstanceStore.js +1 -1
  480. package/views/2d/engine/webgl/shaderGraph/techniques/TextureStatisticsTechnique.js +1 -1
  481. package/views/2d/engine/webgl/shaderGraph/techniques/blend/BlendTechnique.js +1 -1
  482. package/views/2d/engine/webgl/shaderGraph/techniques/bloom/BloomTechnique.js +1 -1
  483. package/views/2d/engine/webgl/shaderGraph/techniques/blur/BlurTechnique.js +1 -1
  484. package/views/2d/engine/webgl/shaderGraph/techniques/dotDensity/DotDensityResources.js +1 -1
  485. package/views/2d/engine/webgl/shaderGraph/techniques/dotDensity/DotDensityTechnique.js +1 -1
  486. package/views/2d/engine/webgl/shaderGraph/techniques/drop-shadow/DropShadowTechnique.js +1 -1
  487. package/views/2d/engine/webgl/shaderGraph/techniques/heatmap/HeatmapResources.js +1 -1
  488. package/views/2d/engine/webgl/shaderGraph/techniques/heatmap/HeatmapTechnique.js +1 -1
  489. package/views/2d/engine/webgl/shaderGraph/techniques/raster/RasterColorizerTechnique.js +1 -1
  490. package/views/2d/engine/webgl/shaderGraph/techniques/raster/RasterHighlightTechnique.js +1 -1
  491. package/views/2d/engine/webgl/shaderGraph/techniques/raster/processor/BaseRasterProcessorTechnique.js +1 -1
  492. package/views/2d/engine/webgl/shaderGraph/techniques/raster/processor/textureUtils.js +1 -1
  493. package/views/2d/engine/webgl/shaders/sources/shaderRepository.js +1 -1
  494. package/views/2d/layers/BaseLayerViewGL2D.d.ts +2 -2
  495. package/views/2d/layers/BaseLayerViewGL2D.js +1 -1
  496. package/views/2d/layers/ImageryTileLayerView2D.js +1 -1
  497. package/views/2d/layers/features/FeatureContainer.js +1 -1
  498. package/views/2d/layers/features/layerAdapters/FeatureLayerAdapter.js +1 -1
  499. package/views/2d/layers/features/layerAdapters/SubtypeGroupLayerAdapter.js +1 -1
  500. package/views/2d/layers/features/schema/processor/SimpleProcessorSchema.js +1 -1
  501. package/views/2d/layers/features/schema/processor/symbols/ComplexSymbolSchema.js +1 -1
  502. package/views/2d/layers/imagery/BaseImageryTileSubView2D.js +1 -1
  503. package/views/2d/layers/support/DisplayGL.js +1 -1
  504. package/views/2d/types.d.ts +3 -3
  505. package/views/3d/FocusAreasView.js +1 -1
  506. package/views/3d/analysis/Slice/sliceToolUtils.js +1 -1
  507. package/views/3d/analysis/Viewshed/ViewshedSubTool.js +1 -1
  508. package/views/3d/analysis/Viewshed/ViewshedTool.js +1 -1
  509. package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillController.js +1 -1
  510. package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillVisualization.js +1 -1
  511. package/views/3d/environment/CloudyWeather.d.ts +1 -1
  512. package/views/3d/environment/Environment.d.ts +4 -4
  513. package/views/3d/environment/FoggyWeather.d.ts +1 -1
  514. package/views/3d/environment/RainyWeather.d.ts +1 -1
  515. package/views/3d/environment/SnowyWeather.d.ts +1 -1
  516. package/views/3d/environment/SunLighting.d.ts +1 -1
  517. package/views/3d/environment/SunnyWeather.d.ts +1 -1
  518. package/views/3d/environment/VirtualLighting.d.ts +1 -1
  519. package/views/3d/layers/GaussianSplatLayerView3D.js +1 -1
  520. package/views/3d/layers/graphics/extrudeUtils.js +1 -1
  521. package/views/3d/support/gaussianSplatting/GaussianSplatIntersectionHandler.js +1 -1
  522. package/views/3d/support/gaussianSplatting/GaussianSplatTextureAtlas.js +1 -1
  523. package/views/3d/support/gaussianSplatting/GaussianTile.js +1 -1
  524. package/views/3d/support/renderInfoUtils/polygon.js +1 -1
  525. package/views/3d/terrain/support/MultiSizeFramebuffer.js +1 -1
  526. package/views/3d/webgl/ManagedFBO.js +1 -1
  527. package/views/3d/webgl/RenderNode.d.ts +2 -2
  528. package/views/3d/webgl-engine/core/FBOCache.js +1 -1
  529. package/views/3d/webgl-engine/core/renderPasses/RenderPassManager.js +1 -1
  530. package/views/3d/webgl-engine/core/shaderLibrary/shading/ReadShadowMap.glsl.js +18 -5
  531. package/views/3d/webgl-engine/core/shaderLibrary/shading/ShadowmapFiltering.glsl.js +2 -2
  532. package/views/3d/webgl-engine/core/shaderLibrary/shading/calculateUVZShadow.glsl.js +2 -2
  533. package/views/3d/webgl-engine/core/shaderLibrary/shading/calculateUVZShadowFromDepth.glsl.js +1 -1
  534. package/views/3d/webgl-engine/effects/RenderPluginManager.js +1 -1
  535. package/views/3d/webgl-engine/effects/clouds/CloudsRenderer.js +1 -1
  536. package/views/3d/webgl-engine/effects/clouds/NoiseTextureAtlas.js +1 -1
  537. package/views/3d/webgl-engine/effects/debug/RenderNodeVisualizerNode.js +1 -1
  538. package/views/3d/webgl-engine/effects/focusArea/FocusAreaMaskNode.js +1 -1
  539. package/views/3d/webgl-engine/effects/highlight/Highlight.js +1 -1
  540. package/views/3d/webgl-engine/effects/transparency/OITBlend.js +1 -1
  541. package/views/3d/webgl-engine/effects/transparency/OITDim.glsl.js +1 -1
  542. package/views/3d/webgl-engine/effects/transparency/OITDimTechniqueConfiguration.js +2 -0
  543. package/views/3d/webgl-engine/lib/CutFillComputationRenderNode.js +1 -1
  544. package/views/3d/webgl-engine/lib/CutFillVisualizationRenderNode.js +1 -1
  545. package/views/3d/webgl-engine/lib/DrapedHeatmapRenderer.js +1 -1
  546. package/views/3d/webgl-engine/lib/GaussianSplatRenderNode.js +1 -1
  547. package/views/3d/webgl-engine/lib/Renderer.js +1 -1
  548. package/views/3d/webgl-engine/materials/PolygonOffset.js +1 -1
  549. package/views/3d/webgl-engine/shaders/GaussianSplat.glsl.js +1 -1
  550. package/views/3d/webgl-engine/shaders/GaussianSplatTechniqueConfiguration.js +1 -1
  551. package/views/3d/webgl-engine/shaders/ShadowCastAccumulate.glsl.js +1 -1
  552. package/views/3d/webgl.d.ts +1 -1
  553. package/views/Magnifier.d.ts +3 -3
  554. package/views/MapView.d.ts +7 -7
  555. package/views/SceneView.d.ts +16 -16
  556. package/views/View.d.ts +17 -3
  557. package/views/View.js +1 -1
  558. package/views/draw/DrawTool.js +1 -1
  559. package/views/draw/support/InteractiveHandle.js +1 -1
  560. package/views/draw/support/Reshape.js +1 -1
  561. package/views/draw/support/drawUtils.js +1 -1
  562. package/views/draw/support/reshapeTooltipUtils.js +1 -1
  563. package/views/draw/support/types.d.ts +9 -1
  564. package/views/interactive/sketch/SketchLabelOptions.d.ts +1 -1
  565. package/views/interactive/sketch/SketchTooltipOptions.d.ts +1 -1
  566. package/views/interactive/snapping/SnappingOptions.d.ts +7 -7
  567. package/views/layers/FeatureLikeLayerView.js +1 -1
  568. package/views/layers/LineOfSightLayerView.d.ts +3 -2
  569. package/views/support/HighlightOptions.d.ts +1 -1
  570. package/views/support/imageReprojection.js +1 -1
  571. package/views/types.d.ts +59 -2
  572. package/views/ui/DefaultUI.d.ts +2 -2
  573. package/views/webgl/FramebufferObject.js +1 -1
  574. package/views/webgl/RenderingContext.js +1 -1
  575. package/views/webgl/Texture.js +1 -1
  576. package/views/webgl/testFloatBufferBlend.js +1 -1
  577. package/views/webgl/testSVGPremultipliedAlpha.js +1 -1
  578. package/webscene/Environment.d.ts +10 -10
  579. package/webscene/Glow.d.ts +1 -1
  580. package/webscene/background/ColorBackground.d.ts +1 -1
  581. package/widgets/AreaMeasurement2D.d.ts +1 -1
  582. package/widgets/AreaMeasurement3D.d.ts +2 -2
  583. package/widgets/Attachments.d.ts +1 -1
  584. package/widgets/Attribution.d.ts +1 -1
  585. package/widgets/BasemapGallery.d.ts +1 -1
  586. package/widgets/BasemapLayerList.d.ts +3 -3
  587. package/widgets/BasemapToggle.d.ts +1 -1
  588. package/widgets/BatchAttributeForm/BatchAttributeFormViewModel.js +1 -1
  589. package/widgets/BatchAttributeForm/expressions/ExpressionsManager.js +1 -1
  590. package/widgets/BatchAttributeForm/inputs/FieldInput.js +1 -1
  591. package/widgets/Bookmarks/BookmarksVisibleElements.d.ts +1 -1
  592. package/widgets/Bookmarks.d.ts +2 -2
  593. package/widgets/BuildingExplorer.d.ts +1 -1
  594. package/widgets/CatalogLayerList.d.ts +3 -3
  595. package/widgets/Compass.d.ts +2 -2
  596. package/widgets/CoordinateConversion.d.ts +1 -1
  597. package/widgets/Daylight.d.ts +5 -5
  598. package/widgets/DirectLineMeasurement3D.d.ts +2 -2
  599. package/widgets/Directions.d.ts +4 -4
  600. package/widgets/DistanceMeasurement2D.d.ts +1 -1
  601. package/widgets/Editor/CreateFeaturesWorkflow.d.ts +1 -1
  602. package/widgets/Editor/CreateFeaturesWorkflow.js +1 -1
  603. package/widgets/Editor/UpdateFeatureWorkflow.js +1 -1
  604. package/widgets/Editor/UpdateFeaturesWorkflow.js +1 -1
  605. package/widgets/Editor/UpdateWorkflow.js +1 -1
  606. package/widgets/Editor/Workflow.js +1 -1
  607. package/widgets/Editor.d.ts +8 -8
  608. package/widgets/ElevationProfile/ElevationProfileLineGround.d.ts +1 -1
  609. package/widgets/ElevationProfile/ElevationProfileLineInput.d.ts +1 -1
  610. package/widgets/ElevationProfile/ElevationProfileLineView.d.ts +1 -1
  611. package/widgets/ElevationProfile.d.ts +3 -3
  612. package/widgets/Expand.d.ts +1 -1
  613. package/widgets/Feature/FeatureViewModel.d.ts +14 -4
  614. package/widgets/Feature/FeatureViewModel.js +1 -1
  615. package/widgets/FeatureForm/FieldInput.js +1 -1
  616. package/widgets/FeatureForm.d.ts +1 -1
  617. package/widgets/FeatureTable/ActionColumn.d.ts +2 -2
  618. package/widgets/FeatureTable/AttachmentsColumn.d.ts +1 -1
  619. package/widgets/FeatureTable/FeatureTableViewModel.d.ts +3 -3
  620. package/widgets/FeatureTable/Grid/GroupColumn.d.ts +1 -1
  621. package/widgets/FeatureTable/RelationshipColumn.d.ts +1 -1
  622. package/widgets/FeatureTable/VisibleElements.d.ts +1 -1
  623. package/widgets/FeatureTable.d.ts +10 -10
  624. package/widgets/FeatureTemplates/FeatureTemplatesViewModel.d.ts +5 -5
  625. package/widgets/FeatureTemplates.d.ts +8 -8
  626. package/widgets/Features/FeaturesViewModel.d.ts +18 -7
  627. package/widgets/Features/FeaturesViewModel.js +1 -1
  628. package/widgets/Features/FeaturesVisibleElements.d.ts +2 -2
  629. package/widgets/Features.d.ts +1 -1
  630. package/widgets/Features.js +1 -1
  631. package/widgets/FloorFilter/FloorFilterViewModel.js +1 -1
  632. package/widgets/FloorFilter.d.ts +2 -2
  633. package/widgets/Histogram.d.ts +2 -2
  634. package/widgets/HistogramRangeSlider.d.ts +1 -1
  635. package/widgets/Home.d.ts +1 -1
  636. package/widgets/LayerList/ListItemPanel.d.ts +1 -1
  637. package/widgets/LayerList.d.ts +4 -4
  638. package/widgets/Legend.d.ts +8 -8
  639. package/widgets/LineOfSight.d.ts +1 -1
  640. package/widgets/Locate.d.ts +2 -2
  641. package/widgets/Measurement.d.ts +1 -1
  642. package/widgets/NavigationToggle/NavigationToggleViewModel.d.ts +1 -1
  643. package/widgets/NavigationToggle.d.ts +3 -3
  644. package/widgets/Popup/PopupViewModel.d.ts +2 -1
  645. package/widgets/Popup/PopupViewModel.js +1 -1
  646. package/widgets/Popup/PopupVisibleElements.d.ts +2 -2
  647. package/widgets/Popup.d.ts +18 -9
  648. package/widgets/Popup.js +1 -1
  649. package/widgets/Print/CustomTemplate.d.ts +1 -1
  650. package/widgets/Print/TemplateOptions.d.ts +4 -4
  651. package/widgets/ScaleRangeSlider.d.ts +1 -1
  652. package/widgets/Search/SearchViewModel.d.ts +4 -4
  653. package/widgets/Search.d.ts +5 -5
  654. package/widgets/ShadowCast.d.ts +3 -3
  655. package/widgets/Sketch/SketchViewModel.d.ts +39 -39
  656. package/widgets/Sketch.d.ts +43 -43
  657. package/widgets/Slice.d.ts +2 -2
  658. package/widgets/Slider/SliderViewModel.d.ts +2 -2
  659. package/widgets/Slider.d.ts +9 -9
  660. package/widgets/Swipe/SwipeViewModel.d.ts +1 -1
  661. package/widgets/Swipe.d.ts +2 -2
  662. package/widgets/TableList/ListItemPanel.d.ts +1 -1
  663. package/widgets/TableList.d.ts +1 -1
  664. package/widgets/TimeSlider/TimeSliderViewModel.d.ts +10 -10
  665. package/widgets/TimeSlider/TimeSliderViewModel.js +1 -1
  666. package/widgets/TimeSlider/types.d.ts +1 -1
  667. package/widgets/TimeSlider.d.ts +13 -13
  668. package/widgets/Track.d.ts +2 -2
  669. package/widgets/UtilityNetworkAssociations.d.ts +3 -3
  670. package/widgets/UtilityNetworkTrace/UtilityNetworkTraceFeature.js +1 -1
  671. package/widgets/UtilityNetworkTrace.d.ts +4 -4
  672. package/widgets/UtilityNetworkValidateTopology.d.ts +1 -1
  673. package/widgets/ValuePicker.d.ts +5 -5
  674. package/widgets/VideoPlayer.d.ts +1 -1
  675. package/widgets/smartMapping/ClassedColorSlider.d.ts +1 -1
  676. package/widgets/smartMapping/ClassedSizeSlider.d.ts +1 -1
  677. package/widgets/smartMapping/ColorSizeSlider.d.ts +2 -2
  678. package/widgets/smartMapping/ColorSlider.d.ts +1 -1
  679. package/widgets/smartMapping/HeatmapSlider.d.ts +1 -1
  680. package/widgets/smartMapping/OpacitySlider.d.ts +1 -1
  681. package/widgets/smartMapping/SizeSlider.d.ts +1 -1
  682. package/widgets/smartMapping/SmartMappingSliderBase.d.ts +4 -4
  683. package/widgets/smartMapping/SmartMappingSliderViewModel.d.ts +6 -6
  684. package/widgets/support/GridControls.d.ts +1 -1
  685. package/widgets/support/SnappingControls/VisibleElements.d.ts +1 -1
  686. package/widgets/support/SnappingControls.d.ts +6 -6
  687. package/assets/esri/core/workers/chunks/02aaeaa988e9e7d65a7f.js +0 -1
  688. package/assets/esri/core/workers/chunks/05c8d2c0362af4511d86.js +0 -1
  689. package/assets/esri/core/workers/chunks/06868e4f52de9d918255.js +0 -1
  690. package/assets/esri/core/workers/chunks/06c0b93e276cfc1fb7ac.js +0 -1
  691. package/assets/esri/core/workers/chunks/0888baa99c9007ad63bc.js +0 -1
  692. package/assets/esri/core/workers/chunks/0de66f13e84830a654fb.js +0 -1
  693. package/assets/esri/core/workers/chunks/0f597c690e5c60fe944b.js +0 -1
  694. package/assets/esri/core/workers/chunks/0f8736242544f9e9a57a.js +0 -1
  695. package/assets/esri/core/workers/chunks/0ff12fe9e358100668d9.js +0 -1
  696. package/assets/esri/core/workers/chunks/11a8541f3909f9ffb000.js +0 -1
  697. package/assets/esri/core/workers/chunks/13a009229c96ecb7b04f.js +0 -1
  698. package/assets/esri/core/workers/chunks/185f59f90070d5d6ac94.js +0 -1
  699. package/assets/esri/core/workers/chunks/190bc75254bc0542a6be.js +0 -1
  700. package/assets/esri/core/workers/chunks/1af247c86d1c4ae8fef3.js +0 -1
  701. package/assets/esri/core/workers/chunks/2339465190c9d5ede25f.js +0 -1
  702. package/assets/esri/core/workers/chunks/23eb204d3cb818adea32.js +0 -1
  703. package/assets/esri/core/workers/chunks/241ef4a1bea20b49d812.js +0 -1
  704. package/assets/esri/core/workers/chunks/2669a7195f1de21a9cf3.js +0 -1
  705. package/assets/esri/core/workers/chunks/2a2d5f9ea42cb2eee9c6.js +0 -1
  706. package/assets/esri/core/workers/chunks/2a7e7a497823e9f05aa3.js +0 -1
  707. package/assets/esri/core/workers/chunks/2aaeaf022af8493281dc.js +0 -1
  708. package/assets/esri/core/workers/chunks/2d92ba11781a3cfc3a78.js +0 -1
  709. package/assets/esri/core/workers/chunks/31e0bfc2cab055aebf9a.js +0 -1
  710. package/assets/esri/core/workers/chunks/32360a55d1836b2a737e.js +0 -1
  711. package/assets/esri/core/workers/chunks/330da3828eefd8d72d3f.js +0 -1
  712. package/assets/esri/core/workers/chunks/34acecd7a314fed12335.js +0 -1
  713. package/assets/esri/core/workers/chunks/34fe4570eef9e73839b8.js +0 -1
  714. package/assets/esri/core/workers/chunks/368b4c0a5eecbb06feac.js +0 -1
  715. package/assets/esri/core/workers/chunks/37729578a7c4cf15eded.js +0 -1
  716. package/assets/esri/core/workers/chunks/3af1e2f0b3d30c58d0c2.js +0 -1
  717. package/assets/esri/core/workers/chunks/3c155efd5768003a91eb.js +0 -1
  718. package/assets/esri/core/workers/chunks/3d4bb59ab2f644f4d675.js +0 -1
  719. package/assets/esri/core/workers/chunks/3f0d9fdd8c37605dd85d.js +0 -1
  720. package/assets/esri/core/workers/chunks/48eca6f51112ba80bd3b.js +0 -1
  721. package/assets/esri/core/workers/chunks/4b5737021a149aa786af.js +0 -1
  722. package/assets/esri/core/workers/chunks/55214e1d9f3d98fa7ed9.js +0 -1
  723. package/assets/esri/core/workers/chunks/55a0b69cf034ac32fc25.js +0 -1
  724. package/assets/esri/core/workers/chunks/576a1784e93c5406e657.js +0 -1
  725. package/assets/esri/core/workers/chunks/59289867cce97da74e39.js +0 -1
  726. package/assets/esri/core/workers/chunks/5a6d6082c5bcb1a80eda.js +0 -1
  727. package/assets/esri/core/workers/chunks/5a9620cb66c8e64e4668.js +0 -1
  728. package/assets/esri/core/workers/chunks/5c6e5f22450dd0583074.js +0 -1
  729. package/assets/esri/core/workers/chunks/5eeb6d3a7b815d41621e.js +0 -1
  730. package/assets/esri/core/workers/chunks/5f06a57b4f7d7de16bbf.js +0 -1
  731. package/assets/esri/core/workers/chunks/5f2e246ffcbdedea4de5.js +0 -1
  732. package/assets/esri/core/workers/chunks/5ff41f43e57be0557541.js +0 -1414
  733. package/assets/esri/core/workers/chunks/6b32b3f98872771ff81e.js +0 -1
  734. package/assets/esri/core/workers/chunks/6be9d00839002f24fafd.js +0 -1
  735. package/assets/esri/core/workers/chunks/6c72dbd5275bffde1583.js +0 -1
  736. package/assets/esri/core/workers/chunks/6c886f19875291d02407.js +0 -1
  737. package/assets/esri/core/workers/chunks/75f7c1f600c4051bc905.js +0 -1
  738. package/assets/esri/core/workers/chunks/77f6659e400064d38130.js +0 -1
  739. package/assets/esri/core/workers/chunks/78c7eace6ec3fa5c7413.js +0 -1
  740. package/assets/esri/core/workers/chunks/7cee28575fd57430cf02.js +0 -1
  741. package/assets/esri/core/workers/chunks/82e0691995d821137d5f.js +0 -1
  742. package/assets/esri/core/workers/chunks/8435b6bf356959009b76.js +0 -1
  743. package/assets/esri/core/workers/chunks/8677865189081e0b83bc.js +0 -1
  744. package/assets/esri/core/workers/chunks/86f70bd786d6d57fde69.js +0 -1
  745. package/assets/esri/core/workers/chunks/8878ab87ef7961fafae8.js +0 -1
  746. package/assets/esri/core/workers/chunks/8a893f23827769d42092.js +0 -1
  747. package/assets/esri/core/workers/chunks/8d1d0c3f0532aa98487d.js +0 -1
  748. package/assets/esri/core/workers/chunks/8e68b4628e9616356c34.js +0 -1
  749. package/assets/esri/core/workers/chunks/8edae79554843dd77ada.js +0 -1
  750. package/assets/esri/core/workers/chunks/9032c040b214b5af775b.js +0 -1
  751. package/assets/esri/core/workers/chunks/909ef35fa33be2b6da41.js +0 -1
  752. package/assets/esri/core/workers/chunks/90b7acc70adba193b215.js +0 -1
  753. package/assets/esri/core/workers/chunks/91718795fc4ca6516ac7.js +0 -1
  754. package/assets/esri/core/workers/chunks/92d4e962284e13ba2fc5.js +0 -1
  755. package/assets/esri/core/workers/chunks/94f80c46ccf5e19038b8.js +0 -1
  756. package/assets/esri/core/workers/chunks/979c2f52b6d6e1e8241b.js +0 -1
  757. package/assets/esri/core/workers/chunks/97f10efb0fe05bedcebd.js +0 -1
  758. package/assets/esri/core/workers/chunks/98f5bf1b91f3696b2fce.js +0 -1
  759. package/assets/esri/core/workers/chunks/9c52d4b54dfdb69dee29.js +0 -1
  760. package/assets/esri/core/workers/chunks/9de8149ae0a0726a4ab2.js +0 -1
  761. package/assets/esri/core/workers/chunks/9def5d17b94e5db71883.js +0 -1
  762. package/assets/esri/core/workers/chunks/9f272445c285ee9abb7b.js +0 -1
  763. package/assets/esri/core/workers/chunks/a10be7eb05a007fff1ed.js +0 -1
  764. package/assets/esri/core/workers/chunks/a32c87b89567a9fd1efc.js +0 -1
  765. package/assets/esri/core/workers/chunks/a3b29eca5807978fb2a3.js +0 -1
  766. package/assets/esri/core/workers/chunks/a446dff865332268625a.js +0 -1
  767. package/assets/esri/core/workers/chunks/a5bf2718c02a0e645013.js +0 -1
  768. package/assets/esri/core/workers/chunks/a6d166058e3025bb280e.js +0 -1
  769. package/assets/esri/core/workers/chunks/a8e111a5cfd6151d5dbb.js +0 -1
  770. package/assets/esri/core/workers/chunks/aed45f7e7eee154a21b8.js +0 -1
  771. package/assets/esri/core/workers/chunks/af3bd661b355eed3da21.js +0 -1
  772. package/assets/esri/core/workers/chunks/b0f2ce61d3cad413898e.js +0 -1
  773. package/assets/esri/core/workers/chunks/b2b77598048818c957b7.js +0 -1
  774. package/assets/esri/core/workers/chunks/b744b950999b92393e37.js +0 -1
  775. package/assets/esri/core/workers/chunks/b75165880704efccc47c.js +0 -1
  776. package/assets/esri/core/workers/chunks/ba9e107edc2027238be3.js +0 -1
  777. package/assets/esri/core/workers/chunks/bc3b22dc08c147b8d425.js +0 -1
  778. package/assets/esri/core/workers/chunks/c08e9914deb1dc62bc0f.js +0 -1
  779. package/assets/esri/core/workers/chunks/c0bb53d8d58ad18334d3.js +0 -1
  780. package/assets/esri/core/workers/chunks/c0d453f93af2d4a6ce64.js +0 -1
  781. package/assets/esri/core/workers/chunks/c9a42d86185a0ad35dd1.js +0 -1
  782. package/assets/esri/core/workers/chunks/cbb50415f7de8746ee1a.js +0 -1
  783. package/assets/esri/core/workers/chunks/d23dd7da45a7aa341540.js +0 -1
  784. package/assets/esri/core/workers/chunks/d2801df3fa44dee15ec8.js +0 -1
  785. package/assets/esri/core/workers/chunks/d53b31c9056f82831bc0.js +0 -1
  786. package/assets/esri/core/workers/chunks/d626e08d23330d84413b.js +0 -1
  787. package/assets/esri/core/workers/chunks/db6e03fe8dd316f5005f.js +0 -1
  788. package/assets/esri/core/workers/chunks/de79645e559a2d1ffa67.js +0 -1
  789. package/assets/esri/core/workers/chunks/e2779965db231fb666a5.js +0 -1
  790. package/assets/esri/core/workers/chunks/e4e2f059c52674dcae5b.js +0 -1
  791. package/assets/esri/core/workers/chunks/ec21311584e4fb13e510.js +0 -1
  792. package/assets/esri/core/workers/chunks/eca45cd479f7fd28ca6e.js +0 -1
  793. package/assets/esri/core/workers/chunks/ee8cd91c27e9cdfc3b2e.js +0 -1
  794. package/assets/esri/core/workers/chunks/efdd75896ca53eb6242f.js +0 -1
  795. package/assets/esri/core/workers/chunks/f1c348cf2a1e35da9b20.js +0 -1
  796. package/assets/esri/core/workers/chunks/f4053e4e2d6e678db48a.js +0 -1
  797. package/assets/esri/core/workers/chunks/f4d577ff61da7964e08a.js +0 -1
  798. package/assets/esri/core/workers/chunks/f7da652f8dab57677cc3.js +0 -1
  799. package/assets/esri/core/workers/chunks/fe92f54e45fd21ccd75f.js +0 -1
  800. package/assets/esri/core/workers/chunks/fee1d873127dca02459f.js +0 -1
  801. package/assets/esri/core/workers/chunks/ff31936236dd9b1acb24.js +0 -1
  802. /package/assets/esri/core/workers/chunks/{32e9e92bbbd000fbbaf7.js.LICENSE.txt → 4141a3a93732996601e8.js.LICENSE.txt} +0 -0
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{__decorate as e}from"tslib";import{volumeMeasurementConfiguration as t}from"../../../../analysis/VolumeMeasurement/volumeMeasurementConfiguration.js";import r from"../../../../core/Accessor.js";import o from"../../../../core/Logger.js";import{debounce as i}from"../../../../core/promiseUtils.js";import{createVolume as n}from"../../../../core/quantity.js";import{whenOnce as s,watch as a,syncAndInitial as l}from"../../../../core/reactiveUtils.js";import{property as u,subclass as p}from"../../../../core/accessorSupport/decorators.js";import{e as m}from"../../../../chunks/earcut.js";import{create as c}from"../../../../core/libs/gl-matrix-2/factories/mat4f64.js";import{scaleAndAdd as d,sqrDist as h}from"../../../../core/libs/gl-matrix-2/math/vec3.js";import{fromValues as g,clone as f,create as y}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{UpdatingHandles as _}from"../../../../core/support/UpdatingHandles.js";import v from"../../../../geometry/Multipoint.js";import{projectOrLoad as w}from"../../../../geometry/projectionUtils.js";import{e as j}from"../../../../chunks/containsOperator.js";import{e as R}from"../../../../chunks/convexHullOperator.js";import{e as b}from"../../../../chunks/simplifyOperator.js";import{e as E}from"../../../../chunks/unionOperator.js";import{computeTranslationToOriginAndRotation as C}from"../../../../geometry/projection/computeTranslationToOriginAndRotation.js";import{projectBoundingRect as x}from"../../../../geometry/projection/projectBoundingRect.js";import{fromExtent as T,intersects as G,create as L,empty as O}from"../../../../geometry/support/aaBoundingRect.js";import{newDoubleArray as D}from"../../../../geometry/support/DoubleArray.js";import{t as I}from"../../../../chunks/vec3.js";import H from"../../../../symbols/support/ElevationInfo.js";import{logFailedGeometryProjectionError as M}from"../support/projectionUtils.js";import{VolumeMeasurementCutFillComputation as P}from"./VolumeMeasurementCutFillComputation.js";import{VolumeMeasurementInsufficientDataError as V,VolumeMeasurementPerimeterTooLargeError as U,VolumeMeasurementUnsupportedCoordinateSystemError as N,VolumeMeasurementUnsupportedLayerTransparencyError as k}from"./volumeMeasurementErrors.js";import{VolumeMeasurementRawResult as A}from"./VolumeMeasurementRawResult.js";import S from"./VolumeMeasurementResult.js";import{ElevationContext as F}from"../../layers/graphics/ElevationContext.js";import{getElevationAtPoint as W}from"../../support/ElevationProvider.js";import{polygonToRenderInfo as z}from"../../support/renderInfoUtils/polygonDeprecated.js";import{IteratorPreorder as q}from"../../terrain/tileUtils.js";import{CutFillComputationRenderNode as B,TargetGeometryRenderInfo as Z}from"../../webgl-engine/lib/CutFillComputationRenderNode.js";import{isIntegratedMeshLayerView as J}from"../../../support/layerViewUtils.js";import{MeasurementWorkerHandle as K}from"../../../support/MeasurementWorkerHandle.js";let Q=class extends r{constructor(e){super(e),this._measurementWorkerHandle=new K,this._getElevationProvider=()=>this.view.elevationProvider,this.depthExtremaPositions=null,this._updatingHandles=new _,this._rawResult=null,this._sufficientDataCoverage=!0,this._tileIterator=new q,this._intersectingObbs=[],this._intersectingTiles=[],this._debouncedUpdate=i(async(e,t,r,o)=>{if(!this._computationRenderNode.done)return;const{renderCoordsHelper:i}=this.view,n=new P({extent:t,localOrigin:r,renderCoordsHelper:i});this._computationRenderNode.update(n,o),this._determineDataCoverage(n);const[a]=await Promise.allSettled([this._measurementWorkerHandle.areaHorizontal(e,{returnLength:!0}),s(()=>this._computationRenderNode.done).then(()=>{this._updateDepthExtremaPositions(n,this._computationRenderNode.getResult())})]);if(this.error)return void(this._rawResult=null);const l=this._computationRenderNode.getResult();this._updateResult(n,l,"fulfilled"===a.status?a.value:null)}),this._determineDataCoverage=e=>{const{elevationAlignedGeometry:t}=this,{frustum:r}=this._computationRenderNode,{cameraDimensions:o}=e;t&&r&&(this._intersectingObbs.length=0,this._imLayerViewsAffectingMeasurement.forEach(e=>{this._findIntersectingObbs(e,r)}),this._intersectingObbs.length?this._sufficientDataCoverage=this._sufficientIntegratedMeshCoverage(t,o):(this._findIntersectingTerrainTiles(t),this._sufficientDataCoverage=this._sufficientTerrainCoverage(o)))}}initialize(){const e=this.view;this._computationRenderNode=new B({view:e}),this.addHandles([this._createElevationUpdateHandle(),a(()=>({projectedGeometry:this._projectedGeometry,localOrigin:this._localOrigin,targetGeometryRenderInfos:this._targetGeometryRenderInfos}),({projectedGeometry:e,localOrigin:t,targetGeometryRenderInfos:r})=>{const o=e?.extent;if(!(e&&o&&t&&r))return this._rawResult=null,void(this._sufficientDataCoverage=!0);this._updatingHandles.consumePromise(this._debouncedUpdate(e,o,t,r))},l)])}destroy(){this._updatingHandles.destroy(),this._computationRenderNode.destroy(),this._measurementWorkerHandle.destroy()}get _projectedGeometry(){const e=this.analysis.geometry;if(!e||!this.analysis.valid)return null;const t=b(e),r=w(t,this.view.spatialReference);return r.pending?(this._updatingHandles.consumePromise(r.pending),null):(t&&!r.geometry&&M(this.analysis,e.spatialReference,o.getLogger(this)),r.geometry)}get _localOrigin(){const e=this._projectedGeometry?.extent;return e?g(e.center.x,e.center.y,0):null}get elevationAlignedGeometry(){const e=this._projectedGeometry;if(!e)return null;const t=e.clone();return X(this._getElevationProvider(),t),t}get targetGeometry(){const{elevationAlignedGeometry:e}=this;if(!e)return null;const t=this.analysis.measureType,{effectiveTargetElevation:r}=this.analysisViewData;if("stockpile"===t||null==r)return e;const o=e.clone();return o.rings.forEach(e=>e.forEach(e=>e[2]=r)),o}get _targetGeometryRenderInfos(){const e=this.targetGeometry,t=this._projectedGeometry?.extent,r=this._localOrigin;if(!e||!t||!r)return null;const{elevationProvider:o,renderCoordsHelper:i}=this.view,n=z(e,o,i,F.fromElevationInfo(new H({mode:"absolute-height"}))),{polygons:s}=n;return s.map(e=>{const o=m(e.position,e.holeIndices,3),n=D(3*e.count),s=c(),a=c();return C(t.spatialReference,r,s,i.spatialReference),a[12]=-s[12],a[13]=-s[13],a[14]=-s[14],I(n,e.position,a),new Z(n,o)})}get updating(){return this._computationRenderNode.updating||this._updatingHandles.updating}get result(){const e=this._rawResult,{volume:t,area:r,length:o}=this.analysisViewData.effectiveDisplayUnits;return e?new S({measureType:this.analysis.measureType,rawResult:e,volumeUnit:t,areaUnit:r,lengthUnit:o}):null}get error(){return this._unsupportedCoordinateSystemError??this._unsupportedLayerTransparencyError??this._perimeterTooLargeError??this._insufficientDataError}get _imLayerViewsAffectingMeasurement(){return this.view.allLayerViews.filter(e=>J(e)).filter(e=>e.visible&&!e.suspended)}get _insufficientDataError(){return this._sufficientDataCoverage?null:new V}get _perimeterTooLargeError(){return this._perimeterTooLargeLocalError??this._perimeterTooLargeGlobalError}get _perimeterTooLargeLocalError(){const{spatialReference:e,state:{isLocal:r}}=this.view;if(!r||!e.isWebMercator)return null;const o=this._perimeter,{maxPerimeterLocalWebMercator:i}=t;return null!=o&&o>i?new U:null}get _perimeterTooLargeGlobalError(){if(!this.view.state.isGlobal)return null;const e=this._perimeter,{maxPerimeterGlobal:r}=t;return null!=e&&e>r?new U:null}get _unsupportedCoordinateSystemError(){return this.view.state.isLocal&&this.view.spatialReference.isGeographic?new N:null}get _unsupportedLayerTransparencyError(){return this.view.map.ground&&this.view.map.ground.opacity<1?new k:null}get _perimeter(){if(!this._targetGeometryRenderInfos)return null;let e=null;for(const t of this._targetGeometryRenderInfos){const r=$(ee(t.positions));e=r?Math.max(e??0,r):e}return null!=e?e/this.view.renderCoordsHelper.unitInMeters:null}_createElevationUpdateHandle(){const e=e=>{const t=this._projectedGeometry?.extent;"ground"===e.context&&t&&(x(e.extent,e.spatialReference,re,this.view.spatialReference),T(t,oe),G(re,oe)&&(this._getElevationProvider=()=>this.view.elevationProvider))};return this.view.elevationProvider.on("elevation-change",t=>e(t))}_updateResult(e,t,r){const{unitInMeters:o}=this.view.renderCoordsHelper,{dimensions:{width:i,height:s},cameraNearFar:{near:a,far:l}}=e,u=i/t.width*(s/t.height),p=Y(t.cut.totalDepth,a,l)*u,m=Y(t.fill.totalDepth,a,l)*u,c=o**3;this._rawResult=new A({cutVolume:n(Math.abs(p*c),"cubic-meters"),fillVolume:n(m*c,"cubic-meters"),area:r?.area,perimeter:r?.length})}_updateDepthExtremaPositions(e,t){const{dimensions:{width:r,height:o},cameraNearFar:{near:i,far:n},cameraPositionRenderSpace:s,northVector:a,eastVector:l,upVector:u}=e,p=e=>{const{depthExtremum:p,depthExtremumCoords:[m,c],totalDepth:h}=e,g=f(s);return 0!==h&&(d(g,g,l,r*(m/t.width-.5)),d(g,g,a,o*(c/t.height-.5))),d(g,g,u,-Y(p,i,n)),g};this.depthExtremaPositions={cut:p(t.cut),fill:p(t.fill)}}_findIntersectingObbs(e,t){const r=this._intersectingObbs;"integrated-mesh-3d"===e.type&&e.getVisibleNodes().forEach(o=>{e.isNodeLoaded(o.index)&&o.geometryObbInRenderSR?.intersectsFrustum(t)&&r.push(o.geometryObbInRenderSR)}),"integrated-mesh-3dtiles"===e.type&&e.forEachVisibleComponentObject(({obb:e})=>{e.intersectsFrustum(t)&&r.push(e)})}_sufficientIntegratedMeshCoverage(e,t){const{renderCoordsHelper:r,spatialReference:o}=this.view,i=[],n=new v({spatialReference:o});if(this._intersectingObbs.forEach(e=>{if(te(e.radius,t)&&(e.getCorners(ne),n.points.length=0,ne.forEach(e=>{const t=r.fromRenderCoords(e,se,o);t&&n.addPoint([t[0],t[1]])}),n.points.length)){const e=R(n);"polygon"===e?.type&&i.push(e)}}),!i.length)return!1;const s=E(i);return!!s&&j(s,e)}_findIntersectingTerrainTiles(e){const{basemapTerrain:t}=this.view;if(this._intersectingTiles.length=0,!e.extent)return;T(e.extent,ie);const r=this._tileIterator;r.reset(t.rootTiles);for(let o=r.next();o;o=r.next())o.intersectsExtent(ie)?o.rendered&&this._intersectingTiles.push(o):r.skipSubtree()}_sufficientTerrainCoverage(e){const{basemapTerrain:{tilingScheme:t}}=this.view;if(!this._intersectingTiles.length)return!1;const r=256/t.pixelSize;return this._intersectingTiles.every(t=>te(t.radius*r,e))}};function X(e,t){t.hasZ=!0,t.rings.forEach(t=>t.forEach(t=>t[2]=W(e,t,"ground")??0))}function Y(e,t,r){return e*(r-t)+t}function $(e){if(!e)return null;let t=null,r=null,o=0;for(const i of e)t||(t=[i[0],i[1],i[2]??0]),r?o+=h(r,i):r=[0,0,0],r[0]=i[0],r[1]=i[1],r[2]=i[2];return t&&r&&(o+=h(r,t)),Math.sqrt(o)}function*ee(e){const t=y();for(let r=0;r<e.length;r+=3)t[0]=e[r],t[1]=e[r+1],t[2]=e[r+2],yield t}e([u()],Q.prototype,"_projectedGeometry",null),e([u()],Q.prototype,"_localOrigin",null),e([u()],Q.prototype,"_getElevationProvider",void 0),e([u()],Q.prototype,"elevationAlignedGeometry",null),e([u()],Q.prototype,"targetGeometry",null),e([u()],Q.prototype,"_targetGeometryRenderInfos",null),e([u({constructOnly:!0})],Q.prototype,"analysis",void 0),e([u({constructOnly:!0})],Q.prototype,"analysisViewData",void 0),e([u({constructOnly:!0})],Q.prototype,"view",void 0),e([u()],Q.prototype,"updating",null),e([u()],Q.prototype,"result",null),e([u()],Q.prototype,"depthExtremaPositions",void 0),e([u()],Q.prototype,"error",null),e([u()],Q.prototype,"_imLayerViewsAffectingMeasurement",null),e([u()],Q.prototype,"_insufficientDataError",null),e([u()],Q.prototype,"_perimeterTooLargeError",null),e([u()],Q.prototype,"_perimeterTooLargeLocalError",null),e([u()],Q.prototype,"_perimeterTooLargeGlobalError",null),e([u()],Q.prototype,"_unsupportedCoordinateSystemError",null),e([u()],Q.prototype,"_unsupportedLayerTransparencyError",null),e([u()],Q.prototype,"_perimeter",null),e([u()],Q.prototype,"_computationRenderNode",void 0),e([u({readOnly:!0})],Q.prototype,"_updatingHandles",void 0),e([u()],Q.prototype,"_rawResult",void 0),e([u()],Q.prototype,"_sufficientDataCoverage",void 0),Q=e([p("esri.views.3d.analysis.VolumeMeasurement.VolumeMeasurementCutFillController")],Q);const te=(e,t)=>e<(t.width+t.height)/2,re=O(),oe=O(),ie=L(),ne=new Array(8).fill(0).map(()=>y()),se=y();export{Q as VolumeMeasurementCutFillController};
2
+ import{__decorate as e}from"tslib";import{volumeMeasurementConfiguration as t}from"../../../../analysis/VolumeMeasurement/volumeMeasurementConfiguration.js";import r from"../../../../core/Accessor.js";import o from"../../../../core/Logger.js";import{debounce as i}from"../../../../core/promiseUtils.js";import{createVolume as n}from"../../../../core/quantity.js";import{whenOnce as s,watch as a,syncAndInitial as l}from"../../../../core/reactiveUtils.js";import{property as u,subclass as p}from"../../../../core/accessorSupport/decorators.js";import{create as m}from"../../../../core/libs/gl-matrix-2/factories/mat4f64.js";import{sqrDist as c}from"../../../../core/libs/gl-matrix-2/math/vec2.js";import{create as d}from"../../../../core/libs/gl-matrix-2/factories/vec2f64.js";import{scaleAndAdd as h}from"../../../../core/libs/gl-matrix-2/math/vec3.js";import{fromValues as g,clone as f,create as y}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{UpdatingHandles as _}from"../../../../core/support/UpdatingHandles.js";import v from"../../../../geometry/Multipoint.js";import{projectOrLoad as w}from"../../../../geometry/projectionUtils.js";import{e as j}from"../../../../chunks/containsOperator.js";import{e as E}from"../../../../chunks/convexHullOperator.js";import{e as b}from"../../../../chunks/simplifyOperator.js";import{e as R}from"../../../../chunks/unionOperator.js";import{computeTranslationToOriginAndRotation as x}from"../../../../geometry/projection/computeTranslationToOriginAndRotation.js";import{projectBoundingRect as C}from"../../../../geometry/projection/projectBoundingRect.js";import{fromExtent as T,intersects as G,create as L,empty as O}from"../../../../geometry/support/aaBoundingRect.js";import{isClockwise as D}from"../../../../geometry/support/coordsUtils.js";import{newDoubleArray as P}from"../../../../geometry/support/DoubleArray.js";import{t as H}from"../../../../chunks/vec3.js";import M from"../../../../symbols/support/ElevationInfo.js";import{logFailedGeometryProjectionError as V}from"../support/projectionUtils.js";import{VolumeMeasurementCutFillComputation as I}from"./VolumeMeasurementCutFillComputation.js";import{VolumeMeasurementInsufficientDataError as U,VolumeMeasurementPerimeterTooLargeError as N,VolumeMeasurementUnsupportedCoordinateSystemError as k,VolumeMeasurementUnsupportedLayerTransparencyError as A}from"./volumeMeasurementErrors.js";import{VolumeMeasurementRawResult as F}from"./VolumeMeasurementRawResult.js";import S from"./VolumeMeasurementResult.js";import{ElevationContext as W}from"../../layers/graphics/ElevationContext.js";import{getElevationAtPoint as z}from"../../support/ElevationProvider.js";import{polygonToRenderInfoElevationAligned as q}from"../../support/renderInfoUtils/polygon.js";import{IteratorPreorder as B}from"../../terrain/tileUtils.js";import{CutFillComputationRenderNode as Z,TargetGeometryRenderInfo as J}from"../../webgl-engine/lib/CutFillComputationRenderNode.js";import{isIntegratedMeshLayerView as K}from"../../../support/layerViewUtils.js";import{MeasurementWorkerHandle as Q}from"../../../support/MeasurementWorkerHandle.js";let X=class extends r{constructor(e){super(e),this._measurementWorkerHandle=new Q,this._getElevationProvider=()=>this.view.elevationProvider,this.depthExtremaPositions=null,this._updatingHandles=new _,this._rawResult=null,this._sufficientDataCoverage=!0,this._tileIterator=new B,this._intersectingObbs=[],this._intersectingTiles=[],this._debouncedUpdate=i(async(e,t,r,o)=>{if(!this._computationRenderNode.done)return;const{renderCoordsHelper:i}=this.view,n=new I({extent:t,localOrigin:r,renderCoordsHelper:i});this._computationRenderNode.update(n,o),this._determineDataCoverage(n);const[a]=await Promise.allSettled([this._measurementWorkerHandle.areaHorizontal(e,{returnLength:!0}),s(()=>this._computationRenderNode.done).then(()=>{this._updateDepthExtremaPositions(n,this._computationRenderNode.getResult())})]);if(this.error)return void(this._rawResult=null);const l=this._computationRenderNode.getResult();this._updateResult(n,l,"fulfilled"===a.status?a.value:null)}),this._determineDataCoverage=e=>{const{elevationAlignedGeometry:t}=this,{frustum:r}=this._computationRenderNode,{cameraDimensions:o}=e;t&&r&&(this._intersectingObbs.length=0,this._imLayerViewsAffectingMeasurement.forEach(e=>{this._findIntersectingObbs(e,r)}),this._intersectingObbs.length?this._sufficientDataCoverage=this._sufficientIntegratedMeshCoverage(t,o):(this._findIntersectingTerrainTiles(t),this._sufficientDataCoverage=this._sufficientTerrainCoverage(o)))}}initialize(){const e=this.view;this._computationRenderNode=new Z({view:e}),this.addHandles([this._createElevationUpdateHandle(),a(()=>({projectedGeometry:this._projectedGeometry,localOrigin:this._localOrigin,targetGeometryRenderInfo:this._targetGeometryRenderInfo}),({projectedGeometry:e,localOrigin:t,targetGeometryRenderInfo:r})=>{const o=e?.extent;if(!(e&&o&&t&&r))return this._rawResult=null,void(this._sufficientDataCoverage=!0);this._updatingHandles.consumePromise(this._debouncedUpdate(e,o,t,r))},l)])}destroy(){this._updatingHandles.destroy(),this._computationRenderNode.destroy(),this._measurementWorkerHandle.destroy()}get _projectedGeometry(){const e=this.analysis.geometry;if(!e||!this.analysis.valid)return null;const t=b(e),r=w(t,this.view.spatialReference);return r.pending?(this._updatingHandles.consumePromise(r.pending),null):(t&&!r.geometry&&V(this.analysis,e.spatialReference,o.getLogger(this)),r.geometry)}get _localOrigin(){const e=this._projectedGeometry?.extent;return e?g(e.center.x,e.center.y,0):null}get elevationAlignedGeometry(){const e=this._projectedGeometry;if(!e)return null;const t=e.clone();return Y(this._getElevationProvider(),t),t}get targetGeometry(){const{elevationAlignedGeometry:e}=this;if(!e)return null;const t=this.analysis.measureType,{effectiveTargetElevation:r}=this.analysisViewData;if("stockpile"===t||null==r)return e;const o=e.clone();return o.rings.forEach(e=>e.forEach(e=>e[2]=r)),o}get _targetGeometryRenderInfo(){const e=this.targetGeometry,t=this._projectedGeometry?.extent,r=this._localOrigin;if(!e||!t||!r)return null;const{elevationProvider:o,renderCoordsHelper:i}=this.view,n=q(e,o,i,W.fromElevationInfo(new M({mode:"absolute-height"})));if(null==n)return null;const{positions:s,polygonIndices:a,vertexCount:l}=n,u=P(3*l),p=m(),c=m();return x(t.spatialReference,r,p,i.spatialReference),c[12]=-p[12],c[13]=-p[13],c[14]=-p[14],H(u,s,c),new J(u,a)}get updating(){return this._computationRenderNode.updating||this._updatingHandles.updating}get result(){const e=this._rawResult,{volume:t,area:r,length:o}=this.analysisViewData.effectiveDisplayUnits;return e?new S({measureType:this.analysis.measureType,rawResult:e,volumeUnit:t,areaUnit:r,lengthUnit:o}):null}get error(){return this._unsupportedCoordinateSystemError??this._unsupportedLayerTransparencyError??this._perimeterTooLargeError??this._insufficientDataError}get _imLayerViewsAffectingMeasurement(){return this.view.allLayerViews.filter(e=>K(e)).filter(e=>e.visible&&!e.suspended)}get _insufficientDataError(){return this._sufficientDataCoverage?null:new U}get _perimeterTooLargeError(){return this._perimeterTooLargeLocalError??this._perimeterTooLargeGlobalError}get _perimeterTooLargeLocalError(){const{spatialReference:e,state:{isLocal:r}}=this.view;if(!r||!e.isWebMercator)return null;const o=this._perimeterForError,{maxPerimeterLocalWebMercator:i}=t;return null!=o&&o>i?new N:null}get _perimeterTooLargeGlobalError(){if(!this.view.state.isGlobal)return null;const e=this._perimeterForError,{maxPerimeterGlobal:r}=t;return null!=e&&e>r?new N:null}get _unsupportedCoordinateSystemError(){return this.view.state.isLocal&&this.view.spatialReference.isGeographic?new k:null}get _unsupportedLayerTransparencyError(){return this.view.map.ground&&this.view.map.ground.opacity<1?new A:null}get _perimeterForError(){const{targetGeometry:e}=this;if(null==e)return null;let t=null;for(const r of e.rings){if(!D(r))continue;const e=ee(te(r));t=e?Math.max(t??0,e):t}return null!=t?t*e.spatialReference.metersPerUnit:null}_createElevationUpdateHandle(){const e=e=>{const t=this._projectedGeometry?.extent;"ground"===e.context&&t&&(C(e.extent,e.spatialReference,oe,this.view.spatialReference),T(t,ie),G(oe,ie)&&(this._getElevationProvider=()=>this.view.elevationProvider))};return this.view.elevationProvider.on("elevation-change",t=>e(t))}_updateResult(e,t,r){const{unitInMeters:o}=this.view.renderCoordsHelper,{dimensions:{width:i,height:s},cameraNearFar:{near:a,far:l}}=e,u=i/t.width*(s/t.height),p=$(t.cut.totalDepth,a,l)*u,m=$(t.fill.totalDepth,a,l)*u,c=o**3;this._rawResult=new F({cutVolume:n(Math.abs(p*c),"cubic-meters"),fillVolume:n(m*c,"cubic-meters"),area:r?.area,perimeter:r?.length})}_updateDepthExtremaPositions(e,t){const{dimensions:{width:r,height:o},cameraNearFar:{near:i,far:n},cameraPositionRenderSpace:s,northVector:a,eastVector:l,upVector:u}=e,p=e=>{const{depthExtremum:p,depthExtremumCoords:[m,c],totalDepth:d}=e,g=f(s);return 0!==d&&(h(g,g,l,r*(m/t.width-.5)),h(g,g,a,o*(c/t.height-.5))),h(g,g,u,-$(p,i,n)),g};this.depthExtremaPositions={cut:p(t.cut),fill:p(t.fill)}}_findIntersectingObbs(e,t){const r=this._intersectingObbs;"integrated-mesh-3d"===e.type&&e.getVisibleNodes().forEach(o=>{e.isNodeLoaded(o.index)&&o.geometryObbInRenderSR?.intersectsFrustum(t)&&r.push(o.geometryObbInRenderSR)}),"integrated-mesh-3dtiles"===e.type&&e.forEachVisibleComponentObject(({obb:e})=>{e.intersectsFrustum(t)&&r.push(e)})}_sufficientIntegratedMeshCoverage(e,t){const{renderCoordsHelper:r,spatialReference:o}=this.view,i=[],n=new v({spatialReference:o});if(this._intersectingObbs.forEach(e=>{if(re(e.radius,t)&&(e.getCorners(se),n.points.length=0,se.forEach(e=>{const t=r.fromRenderCoords(e,ae,o);t&&n.addPoint([t[0],t[1]])}),n.points.length)){const e=E(n);"polygon"===e?.type&&i.push(e)}}),!i.length)return!1;const s=R(i);return!!s&&j(s,e)}_findIntersectingTerrainTiles(e){const{basemapTerrain:t}=this.view;if(this._intersectingTiles.length=0,!e.extent)return;T(e.extent,ne);const r=this._tileIterator;r.reset(t.rootTiles);for(let o=r.next();o;o=r.next())o.intersectsExtent(ne)?o.rendered&&this._intersectingTiles.push(o):r.skipSubtree()}_sufficientTerrainCoverage(e){const{basemapTerrain:{tilingScheme:t}}=this.view;if(!this._intersectingTiles.length)return!1;const r=256/t.pixelSize;return this._intersectingTiles.every(t=>re(t.radius*r,e))}};function Y(e,t){t.hasZ=!0,t.rings.forEach(t=>t.forEach(t=>t[2]=z(e,t,"ground")??0))}function $(e,t,r){return e*(r-t)+t}function ee(e){if(!e)return null;let t=null,r=null,o=0;for(const i of e)t||(t=[i[0],i[1]]),r?o+=c(r,i):r=[0,0],r[0]=i[0],r[1]=i[1];return t&&r&&(o+=c(r,t)),Math.sqrt(o)}function*te(e){const t=d();for(let r=0;r<e.length;r++)t[0]=e[r][0],t[1]=e[r][1],yield t}e([u()],X.prototype,"_projectedGeometry",null),e([u()],X.prototype,"_localOrigin",null),e([u()],X.prototype,"_getElevationProvider",void 0),e([u()],X.prototype,"elevationAlignedGeometry",null),e([u()],X.prototype,"targetGeometry",null),e([u()],X.prototype,"_targetGeometryRenderInfo",null),e([u({constructOnly:!0})],X.prototype,"analysis",void 0),e([u({constructOnly:!0})],X.prototype,"analysisViewData",void 0),e([u({constructOnly:!0})],X.prototype,"view",void 0),e([u()],X.prototype,"updating",null),e([u()],X.prototype,"result",null),e([u()],X.prototype,"depthExtremaPositions",void 0),e([u()],X.prototype,"error",null),e([u()],X.prototype,"_imLayerViewsAffectingMeasurement",null),e([u()],X.prototype,"_insufficientDataError",null),e([u()],X.prototype,"_perimeterTooLargeError",null),e([u()],X.prototype,"_perimeterTooLargeLocalError",null),e([u()],X.prototype,"_perimeterTooLargeGlobalError",null),e([u()],X.prototype,"_unsupportedCoordinateSystemError",null),e([u()],X.prototype,"_unsupportedLayerTransparencyError",null),e([u()],X.prototype,"_perimeterForError",null),e([u()],X.prototype,"_computationRenderNode",void 0),e([u({readOnly:!0})],X.prototype,"_updatingHandles",void 0),e([u()],X.prototype,"_rawResult",void 0),e([u()],X.prototype,"_sufficientDataCoverage",void 0),X=e([p("esri.views.3d.analysis.VolumeMeasurement.VolumeMeasurementCutFillController")],X);const re=(e,t)=>e<(t.width+t.height)/2,oe=O(),ie=O(),ne=L(),se=new Array(8).fill(0).map(()=>y()),ae=y();export{X as VolumeMeasurementCutFillController};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{__decorate as e}from"tslib";import{onLocaleChange as t,substitute as i,fetchMessageBundle as s}from"../../../../intl.js";import{volumeMeasurementConfiguration as o}from"../../../../analysis/VolumeMeasurement/volumeMeasurementConfiguration.js";import r from"../../../../core/Accessor.js";import{equals as n}from"../../../../core/arrayUtils.js";import{cyclicalPI as l}from"../../../../core/Cyclical.js";import{destroyMaybe as a}from"../../../../core/maybe.js";import{formatDecimal as c,preferredVolumePrecision as u}from"../../../../core/quantityFormatUtils.js";import{watch as m,initial as d}from"../../../../core/reactiveUtils.js";import{adaptiveVolumeUnit as h}from"../../../../core/units.js";import{property as p,subclass as g}from"../../../../core/accessorSupport/decorators.js";import{e as y}from"../../../../chunks/earcut.js";import{create as _}from"../../../../core/libs/gl-matrix-2/factories/mat4f64.js";import{set as f,normalize as v,subtract as j,cross as L,dot as b}from"../../../../core/libs/gl-matrix-2/math/vec3.js";import{create as C,fromValues as w}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{computeTranslationToOriginAndRotation as P}from"../../../../geometry/projection/computeTranslationToOriginAndRotation.js";import{newDoubleArray as G}from"../../../../geometry/support/DoubleArray.js";import{newIndexArray as V}from"../../../../geometry/support/Indices.js";import{angleAroundAxis as x}from"../../../../geometry/support/vector.js";import{t as D}from"../../../../chunks/vec3.js";import O from"../../../../symbols/support/ElevationInfo.js";import{LabelVisualElement as R}from"../../interactive/visualElements/LabelVisualElement.js";import{LineVisualElement as A}from"../../interactive/visualElements/LineVisualElement.js";import{OutlineVisualElement as M}from"../../interactive/visualElements/OutlineVisualElement.js";import{EuclideanSegment as F}from"../../interactive/visualElements/support/Segment.js";import{ElevationContext as E}from"../../layers/graphics/ElevationContext.js";import{extrudePolygon as U}from"../../layers/graphics/extrudeUtilsDeprecated.js";import{polygonToRenderInfo as S}from"../../support/renderInfoUtils/polygonDeprecated.js";import{CutFillVisualizationRenderNode as N,VolumeGeometry as B}from"../../webgl-engine/lib/CutFillVisualizationRenderNode.js";import{createStipplePatternSimple as H}from"../../webgl-engine/materials/lineStippleUtils.js";let T=class extends r{get visible(){return this.analysisViewData.visible&&null!=this.analysisViewData.elevationAlignedGeometry&&null!=this.analysisViewData.targetGeometry}get updating(){return this.loadingMessages}get hasUnsupportedError(){const{error:e}=this.analysisViewData;return!!e&&["unsupported-coordinate-system","unsupported-layer-transparency"].includes(e.name)}get _extrusionHeights(){const{renderCoordsHelper:e}=this.view,{depthExtremaPositions:t,targetGeometry:i}=this.analysisViewData,{targetElevationRange:s}=o;if(!i||!t)return{cut:s,fill:-s};let r=-1/0;for(const o of i.rings)for(const e of o)r=Math.max(r,e[2]);const n=1,l=e.getAltitude(t.fill);return{cut:s,fill:Math.min(l-r,0)-n}}constructor(e){super(e),this.unitsMessages=null,this.messages=null,this.loadingMessages=!0,this._elevationContext=E.fromElevationInfo(new O({mode:"absolute-height"})),this._projectionLines=[]}initialize(){const{view:e}=this,i={view:e,isDecoration:!0},s=o,r={...i,width:s.geometryOutlineWidth};this._elevationAlignedGeometry=new M({...r,isDraped:!0,color:s.geometryOutlineColor.toUnitRGBA()}),this._targetGeometry=new M(r);const n={...i,attached:!0,width:s.projectionLineWidth,renderOccluded:4,polygonOffset:3},l={...n,stipplePattern:H(s.projectionLineStippleSize)},a=s.cutProjectionLineColor.toUnitRGBA(),c=s.fillProjectionLineColor.toUnitRGBA();this._cutProjectionLines=new A({...n,color:a}),this._occludedCutProjectionLines=new A({...l,color:a}),this._fillProjectionLines=new A({...n,color:c,renderOccluded:8}),this._occludedFillProjectionLines=new A({...l,color:c});const u={...i,attached:!0};this._cutVolumeLabel=new R({...u,distance:s.labelDistance}),this._fillVolumeLabel=new R({...u,distance:-s.labelDistance}),this._renderNode=new N({view:e,cutColor:s.cutColor,fillColor:s.fillColor,borderColor:s.geometryOutlineColor}),this.addHandles([m(()=>({elevationAlignedGeometry:this.analysisViewData.elevationAlignedGeometry,targetGeometry:this.analysisViewData.targetGeometry}),({elevationAlignedGeometry:e,targetGeometry:t})=>{this._elevationAlignedGeometry.geometry=e,this._targetGeometry.geometry=t},d),m(()=>({interactive:this.analysisViewData.interactive,measureType:this.analysis.measureType,visible:this.visible}),({visible:e,interactive:t,measureType:i})=>{this._elevationAlignedGeometry.visible=e&&!t,this._targetGeometry.visible=e&&"cut-fill"===i,this._renderNode.measureType=i},d),m(()=>({elevationAlignedGeometry:this.analysisViewData.elevationAlignedGeometry,targetGeometry:this.analysisViewData.targetGeometry,visible:this.visible}),({elevationAlignedGeometry:e,targetGeometry:t,visible:i})=>this._updateProjectionLines(e,t,i),d),m(()=>({interactive:this.analysisViewData.interactive,accentColor:this.view.effectiveTheme.accentColor,hasResult:!!this.analysisViewData.result}),({interactive:e,accentColor:t,hasResult:i})=>{this._updateColors(e,t,i)},d),m(()=>[this.analysisViewData.targetGeometry,this._extrusionHeights],()=>this._updateCutFillGeometry(),d),m(()=>this.visible&&this.view.state.camera.aboveGround&&!this.hasUnsupportedError,e=>this._updateCutFillVisibility(e),d),m(()=>{const{messages:e,unitsMessages:t,visible:i,analysisViewData:s}=this;return{depthExtremaPositions:s.depthExtremaPositions,effectiveDisplayUnits:s.effectiveDisplayUnits,messages:e,unitsMessages:t,result:s.result,visible:i&&!!s.result}},e=>this._updateLabels(e)),m(()=>this.view.state.camera,e=>this._updateProjectionLineOcclusion(e),d),t(()=>this._updateMessageBundle())]),this._updateMessageBundle()}destroy(){this._elevationAlignedGeometry=a(this._elevationAlignedGeometry),this._targetGeometry=a(this._targetGeometry),this._cutProjectionLines=a(this._cutProjectionLines),this._occludedCutProjectionLines=a(this._occludedCutProjectionLines),this._fillProjectionLines=a(this._fillProjectionLines),this._occludedFillProjectionLines=a(this._occludedFillProjectionLines),this._cutVolumeLabel=a(this._cutVolumeLabel),this._fillVolumeLabel=a(this._fillVolumeLabel),this._renderNode.destroy()}_updateProjectionLines(e,t,i){if(this._cutProjectionLines.visible=i,this._occludedCutProjectionLines.visible=i,this._fillProjectionLines.visible=i,this._occludedFillProjectionLines.visible=i,!e||!t)return;const{renderCoordsHelper:s}=this.view,o=[],r=[],l=[],a=[],c=[],u=e.spatialReference;for(let m=0;m<e.rings.length;m++){const i=e.rings[m],d=i.length>1&&n(i[0],i[i.length-1]),h=i.length-(d?1:0),p=[];for(let e=0;e<h;++e){const o=i[e],r=f(C(),o[0],o[1],o[2]);s.toRenderCoords(r,u,r);const n=t.rings[m][e],l=f(C(),n[0],n[1],n[2]);s.toRenderCoords(l,u,l);const a=new F(r,l);p.push(a)}const g=this.view.state.camera;for(let s=0;s<p.length;++s){const i=p[s],n=p[0===s?p.length-1:s-1],u=p[s===p.length-1?0:s+1],d=e.rings[m][s],h=t.rings[m][s],y=d[2]>h[2],_=new I(i,n,u,y);o.push(_),_.updateOccluded(g);const f=_.isOccluded;y?(f?l:r).push(i):(f?c:a).push(i)}}this._projectionLines=o,this._cutProjectionLines.setGeometryFromSegments(r),this._occludedCutProjectionLines.setGeometryFromSegments(l),this._fillProjectionLines.setGeometryFromSegments(a),this._occludedFillProjectionLines.setGeometryFromSegments(c)}_updateProjectionLineOcclusion(e){const t=[],i=[],s=[],o=[];let r=!1,n=!1;for(const l of this._projectionLines){l.updateOccluded(e)&&(r||=l.isCut,n||=!l.isCut);const a=l.isOccluded;(l.isCut?a?i:t:a?o:s).push(l.segment)}n&&(this._fillProjectionLines.setGeometryFromSegments(s),this._occludedFillProjectionLines.setGeometryFromSegments(o)),r&&(this._cutProjectionLines.setGeometryFromSegments(t),this._occludedCutProjectionLines.setGeometryFromSegments(i))}_updateColors(e,t,i){const{geometryOutlineColor:s,cutColor:r,fillColor:n,cutColorMuted:l,fillColorMuted:a,cutProjectionLineColor:c,fillProjectionLineColor:u}=o;if(this._renderNode.cutColor=i?r:l,this._renderNode.fillColor=i?n:a,e){const e=t.toUnitRGBA();this._targetGeometry.color=e,this._cutProjectionLines.color=e,this._occludedCutProjectionLines.color=e,this._fillProjectionLines.color=e,this._occludedFillProjectionLines.color=e,this._renderNode.borderColor=t}else{this._targetGeometry.color=s.toUnitRGBA();const e=(i?c:l).toUnitRGBA();this._cutProjectionLines.color=e,this._occludedCutProjectionLines.color=e;const t=(i?u:a).toUnitRGBA();this._fillProjectionLines.color=t,this._occludedFillProjectionLines.color=t,this._renderNode.borderColor=s}}_updateLabels(e){const{effectiveDisplayUnits:t,depthExtremaPositions:s,messages:o,unitsMessages:r,result:n,visible:l}=e;if(this._cutVolumeLabel.visible=l,this._fillVolumeLabel.visible=l,this._cutVolumeLabel.geometry=s?{type:"point",point:s.cut}:null,this._fillVolumeLabel.geometry=s?{type:"point",point:s.fill}:null,null==n||null==o||null==r)return this._cutVolumeLabel.text="-",void(this._fillVolumeLabel.text="-");const a=t.volume,c=i(o.labels.cut,{volume:z(r,n.cutVolume,a)}),u=i(o.labels.fill,{volume:z(r,n.fillVolume,a)});this._cutVolumeLabel.text=c,this._fillVolumeLabel.text=u}_updateCutFillVisibility(e){e?this._renderNode.enable():this._renderNode.disable()}_updateCutFillGeometry(){const{renderCoordsHelper:e}=this.view,{targetGeometry:t}=this.analysisViewData,{cut:i,fill:s}=this._extrusionHeights;if(!t?.extent)return;const{center:o}=t.extent,r=w(o.x,o.y,0),n=C();e.toRenderCoords(r,t.spatialReference,n);const l=this._getExtrudedVolumes(t,i,r,n),a=this._getExtrudedVolumes(t,s,r,n);this._renderNode.updateGeometries(l,a,n)}_getExtrudedVolumes(e,t,i,s){const{renderCoordsHelper:o,spatialReference:r,elevationProvider:n}=this.view,l=C(),a=1===o.viewingMode;o.worldUpAtPosition(s,l);const c=S(e,n,o,this._elevationContext),{polygons:u,mapPositions:m,position:d}=c;return u.map(e=>{const s=e.count,n=y(e.mapPositions,e.holeIndices,3),c=n.length,u=6*s,h=V(u+c),p=V(c),g=G(3*u),f=G(3*u);U(d,m,n,e,g,null,f,null,h,p,t,l,a);const v=_(),j=_();if(P(r,i,v,o.spatialReference),j[12]=-v[12],j[13]=-v[13],j[14]=-v[14],D(g,g,j),"stockpile"===this.analysis.measureType)for(let t=0;t<f.length;t+=3)f[t]=l[0],f[t+1]=l[1],f[t+2]=l[2];return new B(g,p,h,f)})}async _updateMessageBundle(){this.loadingMessages=!0;try{this.unitsMessages=await s("esri/core/t9n/Units"),this.messages=await s("esri/views/3d/analysis/VolumeMeasurement/t9n/VolumeMeasurementAnalysis")}finally{this.loadingMessages=!1}}};function z(e,t,i){if(!t||!e)return null;const s=h(t.value,t.unit,i),o=u(s);return c(e,t,s,o)}e([p({constructOnly:!0})],T.prototype,"view",void 0),e([p({constructOnly:!0})],T.prototype,"analysis",void 0),e([p({constructOnly:!0})],T.prototype,"analysisViewData",void 0),e([p()],T.prototype,"unitsMessages",void 0),e([p()],T.prototype,"messages",void 0),e([p()],T.prototype,"loadingMessages",void 0),e([p({readOnly:!0})],T.prototype,"visible",null),e([p()],T.prototype,"updating",null),e([p()],T.prototype,"hasUnsupportedError",null),e([p()],T.prototype,"_extrusionHeights",null),T=e([g("esri.views.3d.analysis.VolumeMeasurement.VolumeMeasurementCutFillVisualization")],T);class I{constructor(e,t,i,s){this.segment=e,this.previous=t,this.next=i,this.isCut=s,this._isOccluded=!1,this._n1=C(),this._n2=C();const o=v(k,j(k,e.endRenderSpace,e.startRenderSpace));v(this._n1,L(this._n1,o,v(W,j(W,t.startRenderSpace,e.startRenderSpace)))),v(this._n2,L(this._n2,o,v(W,j(W,e.startRenderSpace,i.startRenderSpace)))),this._isConvex=l.normalize(x(this._n1,this._n2,o))<0}get isOccluded(){return this._isOccluded}updateOccluded(e){j(k,this.segment.startRenderSpace,e.eye);const t=b(this._n1,k)<0,i=b(this._n2,k)<0,s=this._isOccluded;return this._isOccluded=this._isConvex?t&&i:t||i,this._isOccluded!==s}}const k=C(),W=C();export{T as VolumeMeasurementCutFillVisualization};
2
+ import{__decorate as e}from"tslib";import{onLocaleChange as t,substitute as i,fetchMessageBundle as s}from"../../../../intl.js";import{volumeMeasurementConfiguration as o}from"../../../../analysis/VolumeMeasurement/volumeMeasurementConfiguration.js";import r from"../../../../core/Accessor.js";import{equals as n}from"../../../../core/arrayUtils.js";import{cyclicalPI as l}from"../../../../core/Cyclical.js";import{destroyMaybe as a}from"../../../../core/maybe.js";import{formatDecimal as c,preferredVolumePrecision as u}from"../../../../core/quantityFormatUtils.js";import{watch as d,initial as m}from"../../../../core/reactiveUtils.js";import{adaptiveVolumeUnit as h}from"../../../../core/units.js";import{property as p,subclass as g}from"../../../../core/accessorSupport/decorators.js";import{create as y}from"../../../../core/libs/gl-matrix-2/factories/mat4f64.js";import{set as _,normalize as f,subtract as v,cross as j,dot as L}from"../../../../core/libs/gl-matrix-2/math/vec3.js";import{create as b,fromValues as C}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{computeTranslationToOriginAndRotation as w}from"../../../../geometry/projection/computeTranslationToOriginAndRotation.js";import{angleAroundAxis as G}from"../../../../geometry/support/vector.js";import{t as V}from"../../../../chunks/vec3.js";import P from"../../../../symbols/support/ElevationInfo.js";import{LabelVisualElement as x}from"../../interactive/visualElements/LabelVisualElement.js";import{LineVisualElement as R}from"../../interactive/visualElements/LineVisualElement.js";import{OutlineVisualElement as O}from"../../interactive/visualElements/OutlineVisualElement.js";import{EuclideanSegment as M}from"../../interactive/visualElements/support/Segment.js";import{ElevationContext as A}from"../../layers/graphics/ElevationContext.js";import{extrudePolygon as D}from"../../layers/graphics/extrudeUtils.js";import{polygonToRenderInfoElevationAligned as F}from"../../support/renderInfoUtils/polygon.js";import{CutFillVisualizationRenderNode as E,VolumeGeometry as U}from"../../webgl-engine/lib/CutFillVisualizationRenderNode.js";import{createStipplePatternSimple as S}from"../../webgl-engine/materials/lineStippleUtils.js";let N=class extends r{get visible(){return this.analysisViewData.visible&&null!=this.analysisViewData.elevationAlignedGeometry&&null!=this.analysisViewData.targetGeometry}get updating(){return this.loadingMessages}get hasUnsupportedError(){const{error:e}=this.analysisViewData;return!!e&&["unsupported-coordinate-system","unsupported-layer-transparency"].includes(e.name)}get _extrusionHeights(){const{renderCoordsHelper:e}=this.view,{depthExtremaPositions:t,targetGeometry:i}=this.analysisViewData,{targetElevationRange:s}=o;if(!i||!t)return{cut:s,fill:-s};let r=-1/0;for(const o of i.rings)for(const e of o)r=Math.max(r,e[2]);const n=1,l=e.getAltitude(t.fill);return{cut:s,fill:Math.min(l-r,0)-n}}constructor(e){super(e),this.unitsMessages=null,this.messages=null,this.loadingMessages=!0,this._elevationContext=A.fromElevationInfo(new P({mode:"absolute-height"})),this._projectionLines=[]}initialize(){const{view:e}=this,i={view:e,isDecoration:!0},s=o,r={...i,width:s.geometryOutlineWidth};this._elevationAlignedGeometry=new O({...r,isDraped:!0,color:s.geometryOutlineColor.toUnitRGBA()}),this._targetGeometry=new O(r);const n={...i,attached:!0,width:s.projectionLineWidth,renderOccluded:4,polygonOffset:3},l={...n,stipplePattern:S(s.projectionLineStippleSize)},a=s.cutProjectionLineColor.toUnitRGBA(),c=s.fillProjectionLineColor.toUnitRGBA();this._cutProjectionLines=new R({...n,color:a}),this._occludedCutProjectionLines=new R({...l,color:a}),this._fillProjectionLines=new R({...n,color:c,renderOccluded:8}),this._occludedFillProjectionLines=new R({...l,color:c});const u={...i,attached:!0};this._cutVolumeLabel=new x({...u,distance:s.labelDistance}),this._fillVolumeLabel=new x({...u,distance:-s.labelDistance}),this._renderNode=new E({view:e,cutColor:s.cutColor,fillColor:s.fillColor,borderColor:s.geometryOutlineColor}),this.addHandles([d(()=>({elevationAlignedGeometry:this.analysisViewData.elevationAlignedGeometry,targetGeometry:this.analysisViewData.targetGeometry}),({elevationAlignedGeometry:e,targetGeometry:t})=>{this._elevationAlignedGeometry.geometry=e,this._targetGeometry.geometry=t},m),d(()=>({interactive:this.analysisViewData.interactive,measureType:this.analysis.measureType,visible:this.visible}),({visible:e,interactive:t,measureType:i})=>{this._elevationAlignedGeometry.visible=e&&!t,this._targetGeometry.visible=e&&"cut-fill"===i,this._renderNode.measureType=i},m),d(()=>({elevationAlignedGeometry:this.analysisViewData.elevationAlignedGeometry,targetGeometry:this.analysisViewData.targetGeometry,visible:this.visible}),({elevationAlignedGeometry:e,targetGeometry:t,visible:i})=>this._updateProjectionLines(e,t,i),m),d(()=>({interactive:this.analysisViewData.interactive,accentColor:this.view.effectiveTheme.accentColor,hasResult:!!this.analysisViewData.result}),({interactive:e,accentColor:t,hasResult:i})=>{this._updateColors(e,t,i)},m),d(()=>[this.analysisViewData.targetGeometry,this._extrusionHeights,this._polygonRenderInfo],()=>this._updateCutFillGeometry(),m),d(()=>this.visible&&this.view.state.camera.aboveGround&&!this.hasUnsupportedError,e=>this._updateCutFillVisibility(e),m),d(()=>{const{messages:e,unitsMessages:t,visible:i,analysisViewData:s}=this;return{depthExtremaPositions:s.depthExtremaPositions,effectiveDisplayUnits:s.effectiveDisplayUnits,messages:e,unitsMessages:t,result:s.result,visible:i&&!!s.result}},e=>this._updateLabels(e)),d(()=>this.view.state.camera,e=>this._updateProjectionLineOcclusion(e),m),t(()=>this._updateMessageBundle())]),this._updateMessageBundle()}destroy(){this._elevationAlignedGeometry=a(this._elevationAlignedGeometry),this._targetGeometry=a(this._targetGeometry),this._cutProjectionLines=a(this._cutProjectionLines),this._occludedCutProjectionLines=a(this._occludedCutProjectionLines),this._fillProjectionLines=a(this._fillProjectionLines),this._occludedFillProjectionLines=a(this._occludedFillProjectionLines),this._cutVolumeLabel=a(this._cutVolumeLabel),this._fillVolumeLabel=a(this._fillVolumeLabel),this._renderNode.destroy()}_updateProjectionLines(e,t,i){if(this._cutProjectionLines.visible=i,this._occludedCutProjectionLines.visible=i,this._fillProjectionLines.visible=i,this._occludedFillProjectionLines.visible=i,!e||!t)return;const{renderCoordsHelper:s}=this.view,o=[],r=[],l=[],a=[],c=[],u=e.spatialReference;for(let d=0;d<e.rings.length;d++){const i=e.rings[d],m=i.length>1&&n(i[0],i[i.length-1]),h=i.length-(m?1:0),p=[];for(let e=0;e<h;++e){const o=i[e],r=_(b(),o[0],o[1],o[2]);s.toRenderCoords(r,u,r);const n=t.rings[d][e],l=_(b(),n[0],n[1],n[2]);s.toRenderCoords(l,u,l);const a=new M(r,l);p.push(a)}const g=this.view.state.camera;for(let e=0;e<p.length;++e){const s=p[e],n=p[0===e?p.length-1:e-1],u=p[e===p.length-1?0:e+1],m=i[e],h=t.rings[d][e],y=m[2]>h[2],_=new H(s,n,u,y);o.push(_),_.updateOccluded(g);const f=_.isOccluded;y?(f?l:r).push(s):(f?c:a).push(s)}}this._projectionLines=o,this._cutProjectionLines.setGeometryFromSegments(r),this._occludedCutProjectionLines.setGeometryFromSegments(l),this._fillProjectionLines.setGeometryFromSegments(a),this._occludedFillProjectionLines.setGeometryFromSegments(c)}_updateProjectionLineOcclusion(e){const t=[],i=[],s=[],o=[];let r=!1,n=!1;for(const l of this._projectionLines){l.updateOccluded(e)&&(r||=l.isCut,n||=!l.isCut);const a=l.isOccluded;(l.isCut?a?i:t:a?o:s).push(l.segment)}n&&(this._fillProjectionLines.setGeometryFromSegments(s),this._occludedFillProjectionLines.setGeometryFromSegments(o)),r&&(this._cutProjectionLines.setGeometryFromSegments(t),this._occludedCutProjectionLines.setGeometryFromSegments(i))}_updateColors(e,t,i){const{geometryOutlineColor:s,cutColor:r,fillColor:n,cutColorMuted:l,fillColorMuted:a,cutProjectionLineColor:c,fillProjectionLineColor:u}=o;if(this._renderNode.cutColor=i?r:l,this._renderNode.fillColor=i?n:a,e){const e=t.toUnitRGBA();this._targetGeometry.color=e,this._cutProjectionLines.color=e,this._occludedCutProjectionLines.color=e,this._fillProjectionLines.color=e,this._occludedFillProjectionLines.color=e,this._renderNode.borderColor=t}else{this._targetGeometry.color=s.toUnitRGBA();const e=(i?c:l).toUnitRGBA();this._cutProjectionLines.color=e,this._occludedCutProjectionLines.color=e;const t=(i?u:a).toUnitRGBA();this._fillProjectionLines.color=t,this._occludedFillProjectionLines.color=t,this._renderNode.borderColor=s}}_updateLabels(e){const{effectiveDisplayUnits:t,depthExtremaPositions:s,messages:o,unitsMessages:r,result:n,visible:l}=e;if(this._cutVolumeLabel.visible=l,this._fillVolumeLabel.visible=l,this._cutVolumeLabel.geometry=s?{type:"point",point:s.cut}:null,this._fillVolumeLabel.geometry=s?{type:"point",point:s.fill}:null,null==n||null==o||null==r)return this._cutVolumeLabel.text="-",void(this._fillVolumeLabel.text="-");const a=t.volume,c=i(o.labels.cut,{volume:B(r,n.cutVolume,a)}),u=i(o.labels.fill,{volume:B(r,n.fillVolume,a)});this._cutVolumeLabel.text=c,this._fillVolumeLabel.text=u}_updateCutFillVisibility(e){e?this._renderNode.enable():this._renderNode.disable()}get _polygonRenderInfo(){const{renderCoordsHelper:e,elevationProvider:t}=this.view,{targetGeometry:i}=this.analysisViewData;return null==i?null:F(i,t,e,this._elevationContext,{outlineOutput:"tessellated-indices"})}_updateCutFillGeometry(){const{renderCoordsHelper:e}=this.view,{targetGeometry:t}=this.analysisViewData,{cut:i,fill:s}=this._extrusionHeights;if(!t?.extent)return;const{center:o}=t.extent,r=C(o.x,o.y,0),n=b();e.toRenderCoords(r,t.spatialReference,n);const l=this._getExtrudedVolume(i,r,n),a=this._getExtrudedVolume(s,r,n);null!=l&&null!=a&&this._renderNode.updateGeometries(l,a,n)}_getExtrudedVolume(e,t,i){const{renderCoordsHelper:s,spatialReference:o}=this.view,r=b(),n=1===s.viewingMode;s.worldUpAtPosition(i,r);const{_polygonRenderInfo:l}=this;if(null==l)return null;const a=D(l,{height:e,worldUp:r,spherical:n,requireElevation:!1,requireNormals:!0,requireSizes:!1});if(null==a)return null;const c=y(),u=y();if(w(o,t,c,s.spatialReference),u[12]=-c[12],u[13]=-c[13],u[14]=-c[14],V(a.vertices,a.vertices,u),"stockpile"===this.analysis.measureType)for(let d=0;d<a.normals.length;d+=3)a.normals[d]=r[0],a.normals[d+1]=r[1],a.normals[d+2]=r[2];return new U(a.vertices,a.bottomIndices,a.indices,a.normals)}async _updateMessageBundle(){this.loadingMessages=!0;try{this.unitsMessages=await s("esri/core/t9n/Units"),this.messages=await s("esri/views/3d/analysis/VolumeMeasurement/t9n/VolumeMeasurementAnalysis")}finally{this.loadingMessages=!1}}};function B(e,t,i){if(!t||!e)return null;const s=h(t.value,t.unit,i),o=u(s);return c(e,t,s,o)}e([p({constructOnly:!0})],N.prototype,"view",void 0),e([p({constructOnly:!0})],N.prototype,"analysis",void 0),e([p({constructOnly:!0})],N.prototype,"analysisViewData",void 0),e([p()],N.prototype,"unitsMessages",void 0),e([p()],N.prototype,"messages",void 0),e([p()],N.prototype,"loadingMessages",void 0),e([p({readOnly:!0})],N.prototype,"visible",null),e([p()],N.prototype,"updating",null),e([p()],N.prototype,"hasUnsupportedError",null),e([p()],N.prototype,"_extrusionHeights",null),e([p()],N.prototype,"_polygonRenderInfo",null),N=e([g("esri.views.3d.analysis.VolumeMeasurement.VolumeMeasurementCutFillVisualization")],N);class H{constructor(e,t,i,s){this.segment=e,this.previous=t,this.next=i,this.isCut=s,this._isOccluded=!1,this._n1=b(),this._n2=b();const o=f(I,v(I,e.endRenderSpace,e.startRenderSpace));f(this._n1,j(this._n1,o,f(T,v(T,t.startRenderSpace,e.startRenderSpace)))),f(this._n2,j(this._n2,o,f(T,v(T,e.startRenderSpace,i.startRenderSpace)))),this._isConvex=l.normalize(G(this._n1,this._n2,o))<0}get isOccluded(){return this._isOccluded}updateOccluded(e){v(I,this.segment.startRenderSpace,e.eye);const t=L(this._n1,I)<0,i=L(this._n2,I)<0,s=this._isOccluded;return this._isOccluded=this._isConvex?t&&i:t||i,this._isOccluded!==s}}const I=b(),T=b();export{N as VolumeMeasurementCutFillVisualization};
@@ -5,7 +5,7 @@ export interface CloudyWeatherProperties extends Partial<Pick<CloudyWeather, "cl
5
5
  /**
6
6
  * The CloudyWeather class allows you to change the weather conditions in the scene to cloudy weather.
7
7
  *
8
- * ![scene-atmosphere](https://developers.arcgis.com/javascript/latest/assets/references/core/views/scene-weather-cloudy.png)
8
+ * ![scene-atmosphere](https://developers.arcgis.com/javascript/latest/assets/references/core/views/scene-weather-cloudy.avif)
9
9
  *
10
10
  * Example:
11
11
  * ```js
@@ -11,8 +11,8 @@ export interface EnvironmentProperties extends WebSceneEnvironmentProperties {
11
11
  *
12
12
  * Known Value | Example
13
13
  * ------------|---------
14
- * [SunLighting](https://developers.arcgis.com/javascript/latest/references/core/views/3d/environment/SunLighting/) | ![scene-sun-lighting](https://developers.arcgis.com/javascript/latest/assets/references/core/views/SunLighting.jpg)
15
- * [VirtualLighting](https://developers.arcgis.com/javascript/latest/references/core/views/3d/environment/VirtualLighting/) | ![scene-virtual-lighting](https://developers.arcgis.com/javascript/latest/assets/references/core/views/VirtualLighting.jpg)
14
+ * [SunLighting](https://developers.arcgis.com/javascript/latest/references/core/views/3d/environment/SunLighting/) | ![scene-sun-lighting](https://developers.arcgis.com/javascript/latest/assets/references/core/views/SunLighting.avif)
15
+ * [VirtualLighting](https://developers.arcgis.com/javascript/latest/references/core/views/3d/environment/VirtualLighting/) | ![scene-virtual-lighting](https://developers.arcgis.com/javascript/latest/assets/references/core/views/VirtualLighting.avif)
16
16
  *
17
17
  * @since 5.0
18
18
  */
@@ -28,8 +28,8 @@ export default class Environment extends WebSceneEnvironment {
28
28
  *
29
29
  * Known Value | Example
30
30
  * ------------|---------
31
- * [SunLighting](https://developers.arcgis.com/javascript/latest/references/core/views/3d/environment/SunLighting/) | ![scene-sun-lighting](https://developers.arcgis.com/javascript/latest/assets/references/core/views/SunLighting.jpg)
32
- * [VirtualLighting](https://developers.arcgis.com/javascript/latest/references/core/views/3d/environment/VirtualLighting/) | ![scene-virtual-lighting](https://developers.arcgis.com/javascript/latest/assets/references/core/views/VirtualLighting.jpg)
31
+ * [SunLighting](https://developers.arcgis.com/javascript/latest/references/core/views/3d/environment/SunLighting/) | ![scene-sun-lighting](https://developers.arcgis.com/javascript/latest/assets/references/core/views/SunLighting.avif)
32
+ * [VirtualLighting](https://developers.arcgis.com/javascript/latest/references/core/views/3d/environment/VirtualLighting/) | ![scene-virtual-lighting](https://developers.arcgis.com/javascript/latest/assets/references/core/views/VirtualLighting.avif)
33
33
  *
34
34
  * @since 5.0
35
35
  */
@@ -5,7 +5,7 @@ export interface FoggyWeatherProperties extends Partial<Pick<FoggyWeather, "fogS
5
5
  /**
6
6
  * The FoggyWeather class allows you to change the weather conditions in the scene to foggy weather.
7
7
  *
8
- * ![scene-atmosphere](https://developers.arcgis.com/javascript/latest/assets/references/core/views/scene-weather-foggy.png)
8
+ * ![scene-atmosphere](https://developers.arcgis.com/javascript/latest/assets/references/core/views/scene-weather-foggy.avif)
9
9
  *
10
10
  * Example:
11
11
  * ```js
@@ -5,7 +5,7 @@ export interface RainyWeatherProperties extends Partial<Pick<RainyWeather, "clou
5
5
  /**
6
6
  * The RainyWeather class allows you to change the weather conditions in the scene to rainy weather.
7
7
  *
8
- * ![scene-atmosphere](https://developers.arcgis.com/javascript/latest/assets/references/core/views/scene-weather-rainy.png)
8
+ * ![scene-atmosphere](https://developers.arcgis.com/javascript/latest/assets/references/core/views/scene-weather-rainy.avif)
9
9
  *
10
10
  * Example:
11
11
  * ```js
@@ -5,7 +5,7 @@ export interface SnowyWeatherProperties extends Partial<Pick<SnowyWeather, "clou
5
5
  /**
6
6
  * The SnowyWeather class allows you to change the weather conditions in the scene to snowy weather.
7
7
  *
8
- * ![scene-atmosphere](https://developers.arcgis.com/javascript/latest/assets/references/core/views/scene-weather-snowy.png)
8
+ * ![scene-atmosphere](https://developers.arcgis.com/javascript/latest/assets/references/core/views/scene-weather-snowy.avif)
9
9
  *
10
10
  * Example:
11
11
  * ```js
@@ -16,7 +16,7 @@ export interface SunLightingProperties extends WebSceneSunLightingProperties, Pa
16
16
  /**
17
17
  * The SunLighting class allows you to change the lighting in the scene to sunlight. The position of the light is set to the sun's location.
18
18
  *
19
- * ![scene-lightings](https://developers.arcgis.com/javascript/latest/assets/references/core/views/virtualLightCombined.png)
19
+ * ![scene-lightings](https://developers.arcgis.com/javascript/latest/assets/references/core/views/virtualLightCombined.avif)
20
20
  *
21
21
  * Example:
22
22
  * ```js
@@ -5,7 +5,7 @@ export interface SunnyWeatherProperties extends Partial<Pick<SunnyWeather, "clou
5
5
  /**
6
6
  * The SunnyWeather class allows you to change the weather conditions in the scene to sunny weather.
7
7
  *
8
- * ![scene-atmosphere](https://developers.arcgis.com/javascript/latest/assets/references/core/views/scene-weather-sunny.png)
8
+ * ![scene-atmosphere](https://developers.arcgis.com/javascript/latest/assets/references/core/views/scene-weather-sunny.avif)
9
9
  *
10
10
  * Example:
11
11
  * ```js
@@ -8,7 +8,7 @@ export interface VirtualLightingProperties extends WebSceneVirtualLightingProper
8
8
  * The VirtualLighting class allows you to change the lighting in the scene to virtual light. The position of the light
9
9
  * follows the camera and has a slight top-right offset in respect to the camera.
10
10
  *
11
- * ![scene-lightings](https://developers.arcgis.com/javascript/latest/assets/references/core/views/virtualLightCombined.png)
11
+ * ![scene-lightings](https://developers.arcgis.com/javascript/latest/assets/references/core/views/virtualLightCombined.avif)
12
12
  *
13
13
  * Example:
14
14
  * ```js
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{__decorate as e}from"tslib";import"../../../core/has.js";import t from"../../../core/Logger.js";import{removeMaybe as i}from"../../../core/maybe.js";import{watch as s,initial as a}from"../../../core/reactiveUtils.js";import{unitFromRESTJSON as r,convertUnit as n}from"../../../core/units.js";import{property as l,subclass as o}from"../../../core/accessorSupport/decorators.js";import{fromValues as h}from"../../../core/libs/gl-matrix-2/factories/quatf64.js";import{getReferenceEllipsoid as d}from"../../../geometry/ellipsoidUtils.js";import u from"../../../geometry/HeightModelInfo.js";import{create as c}from"../../../geometry/support/aaBoundingBox.js";import{isCompatible as p}from"../../../geometry/support/heightModelInfoUtils.js";import{isPlateCarree as m,isWebMercator as f,equals as g,isGeographic as _}from"../../../geometry/support/spatialReferenceUtils.js";import y from"../../../geometry/support/WKIDUnitConversion.js";import{getHeightModelInfoFromVCS as w}from"../../../layers/support/tiles3DUtils.js";import{getElevationOffsetInMeters as v}from"../../../support/elevationInfoUtils.js";import{getMetersPerUnit as S}from"../../../symbols/support/unitConversionUtils.js";import{GaussianSplatLayerViewPerformanceInfo as C}from"./GaussianSplatLayerViewPerformanceInfo.js";import{LayerView3D as b}from"./LayerView3D.js";import{addLayerViewToWasm as x,getLyr3DWasm as I,removeLayerViewFromWasm as H}from"./Lyr3DWasm.js";import{LayerElevationProvider as M}from"./i3s/LayerElevationProvider.js";import{ElevationRange as A}from"../support/ElevationRange.js";import{projectToBoundingBox as T}from"../support/extentUtils.js";import{Obb as E}from"../support/orientedBoundingBox.js";import{splatPageSizeInU32 as F,elementsPerSplatPage as P,packedGaussianSizeInU32 as j,splatPageSizeInU32WithoutHeader as O,gaussiansPerSplatPage as U,splatAtlasTextureWidth as G}from"../support/gaussianSplatting/GaussianSplatAtlasPages.js";import{GaussianSplatDataStore as R}from"../support/gaussianSplatting/GaussianSplatDataStore.js";import{GaussianSplatFadeHelper as V}from"../support/gaussianSplatting/GaussianSplatFadeHelper.js";import{GaussianSplatIntersectionHandler as L}from"../support/gaussianSplatting/GaussianSplatIntersectionHandler.js";import{GaussianTile as B}from"../support/gaussianSplatting/GaussianTile.js";import{GaussianSplatRenderNode as k}from"../webgl-engine/lib/GaussianSplatRenderNode.js";import D from"../../layers/LayerView.js";import{spatialReferenceIncompatibleError as N,isInEffectiveScaleRange as z}from"../../support/layerViewUtils.js";import{TaskPriority as q}from"../../support/Scheduler.js";const W=()=>t.getLogger("esri.views.3d.layers.GaussianSplatLayerView3D");let $=class extends(b(D)){constructor(e){super(e),this.type="gaussian-splat-3d",this.ignoresMemoryFactor=!1,this._tileHandles=new Map,this._pageBuffer=new Uint32Array(F),this._tmpTilesWithChangedVisibility=new Array,this._currentLyr3dVisibilityChange=0,this._tileFadeInsAwaitingInitialSort=new Map,this._tileFadeOutsAwaitingInitialSort=new Map,this._tmpSortedTileHandles=new Set,this._wasmLayerId=-1,this._metersPerVCSUnit=1,this._usedMemory=0,this._cacheMemory=0,this._useEsriCrs=!1,this.fullExtentInLocalViewSpatialReference=null,this._suspendedHandle=null,this._conversionBuffer=new ArrayBuffer(4),this._u32View=new Uint32Array(this._conversionBuffer),this._f32View=new Float32Array(this._conversionBuffer);const t=e.view.resourceController;this._memCache=t.memoryController.newCache(`GaussianSplat-${this.uid}`,e=>this._deleteTile(e)),this._frameTask=t.scheduler.registerTask(q.GAUSSIAN_SPLAT_TEXTURE_ATLAS)}get _clippingBox(){if(!this.view?.clippingArea)return null;const e=c();return T(this.view.clippingArea,e,this.view.renderSpatialReference)?e:null}get clippingBox(){return this._renderNode?.clippingBox??null}initialize(){if(!this._canProjectWithoutEngine())throw N("layer",this.layer.spatialReference.wkid,this.view.renderSpatialReference?.wkid);const e=x(this).then(e=>{this._wasmLayerId=e,this._renderNode=new k({view:this.view,layerView:this}),this.data=new R(this._renderNode,(e,t)=>this._onSortComplete(e,t)),this.fadeHelper=new V(this),this._intersectionHandler=new L(this),this.view.sceneIntersectionHelper.addIntersectionHandler(this._intersectionHandler),this._elevationProvider=new M({view:this.view,layerElevationSource:this,intersectionHandler:this._intersectionHandler}),this.view.elevationProvider.register(2,this._elevationProvider),this.addHandles([s(()=>this.layer.elevationInfo,e=>this._elevationInfoChanged(e)),s(()=>this.slicePlaneEnabled,e=>this._slicePlaneEnabledChanged(e),a)]),this._suspendedHandle=s(()=>this.suspended,e=>this._wasm?.setEnabled(this,!e),a),this.addHandles([s(()=>this._clippingBox,e=>this._renderNode.clippingBox=e,a)]),this.setMaximumGaussianCount(this.view.qualitySettings.gaussianSplat.maximumNumberOfGaussians)});this.addHandles([s(()=>this.view.qualitySettings.fadeDuration,e=>{this.fadeHelper.onFadeDurationChanged(e),this.data.fadingTexture.updateTexture(this.data.textureAtlas.pageAllocator.pageCount)}),s(()=>this.view.qualitySettings.gaussianSplat.maximumNumberOfGaussians,e=>this.setMaximumGaussianCount(e*this.view.quality)),s(()=>this.view.quality,e=>this.setMaximumGaussianCount(this.view.qualitySettings.gaussianSplat.maximumNumberOfGaussians*e))]),this.addResolvingPromise(e)}get wasmLayerId(){return this._wasmLayerId}get metersPerVCSUnit(){return this._metersPerVCSUnit}get tileHandles(){return this._tileHandles}get _wasm(){return I(this.view)}get usedMemory(){return this._usedMemory}get cachedMemory(){return this._cacheMemory}get unloadedMemory(){return 0}get useEsriCrs(){return this._useEsriCrs}get elevationProvider(){return this._elevationProvider}get elevationOffset(){return v(this.layer.elevationInfo)}get elevationRange(){const e=this.fullExtent;return e?.zmin&&e?.zmax?new A(e.zmin,e.zmax):null}getElevationRange(e){return this._intersectionHandler.getElevationRange(e)}get fullExtent(){return this.layer.fullExtent}get visibleAtCurrentScale(){return z(this.layer.effectiveScaleRange,this.view.scale)}isUpdating(){const e=this._wasm;return!(this._wasmLayerId<0||null==e)&&(e.isUpdating(this._wasmLayerId)||this.data.updating||this.fadeHelper.updating)}updatingFlagChanged(){this.notifyChange("updating")}async createRenderable(e){const t=e.meshData;if(null==t.data)throw new Error("meshData.data undefined");if(t.desc=JSON.parse(t.desc),null==t.desc)throw new Error("meshData.desc undefined");const i=t.desc.prims[0],s=i.vertexCount,a=i.atrbs[0].view,r=i.atrbs[0].view.byteCount,n=i.atrbs[0].view.byteOffset;let l=null;if("U32"!==a.type)return W().warnOnce("unexpected meshData.data format"),{memUsageBytes:0,numGaussians:0};l=new Uint32Array(t.data.buffer,n,r/4);const o=this.extractHeader(l),u=Math.ceil(s/U),c=new Uint32Array(s),p=new Array;let m=!1,f=0;const g=async e=>{for(;f<u&&!e.done&&!m;f++){let t=this.data.textureAtlas.requestPage();if(null===t&&(this._freeInvisibleTiles(),t=this.data.textureAtlas.requestPage()),null!==t){p.push(t);const i=s-f*U,a=Math.min(i,U),r=f*U;for(let e=0;e<a;e++)c[e+r]=e+P*t;const n=f*O;this._pageBuffer.set(l.subarray(n,n+a*j)),this._pageBuffer.set(o.packedHeader,O);const h=t*P,d=h%G,u=Math.floor(h/G);this.data.textureAtlas.update(d,u,this._pageBuffer),e.madeProgress()}else m=!0}f<u&&!m&&await this._frameTask.schedule(g)};if(await this._frameTask.schedule(g),m)return W().warnOnce("ran out of gaussian splat memory"),{memUsageBytes:0,numGaussians:0};const _=new Float32Array(3*s),y=new Float32Array(s),w=2.048,v=o.tileOrigin.x*w,S=o.tileOrigin.y*w,C=o.tileOrigin.z*w,b=o.invPosScale;let x=null;if(t.desc.obb){const e=t.desc.obb.quaternion;x=new E(t.desc.obb.center,t.desc.obb.halfSize,h(...e))}x||(W().warnOnce("encountered tile without a bounding box"),x=new E);const I=x.centerX,H=x.centerY,M=x.centerZ,T=new A,F=this.view.state.isGlobal,R=F?d(this.view.spatialReference).radius:0;let V=0,L=0,k=0;const D=async e=>{for(;k<s&&!e.done;k++){const t=k*j,{rawX:i,rawY:s,rawZ:a}=this._extractGaussianPosition(l,t),r=this._extractGaussianSphericalScale(l,t),n=i*b+v,o=s*b+S,h=a*b+C;_[V]=n-I,_[V+1]=o-H,_[V+2]=h-M;const d=F?Math.sqrt(n*n+o*o+h*h)-R:h;T.expandElevationRangeValues(d,d),y[k]=r*r,L=Math.max(L,r),V+=3,e.madeProgress()}k<s&&await this._frameTask.schedule(D)};await this._frameTask.schedule(D);const{fullExtent:N}=this.layer;N?.hasZ&&N.zmax&&N.zmin&&(T.minElevation=Math.max(T.minElevation,N.zmin),T.maxElevation=Math.min(T.maxElevation,N.zmax));const z=new B(e.handle,x,c,p,_,y,s,L,T);return this._memCache.put(`${z.handle}`,z),this._tileHandles.set(e.handle,z),this._cacheMemory+=z.usedMemory,{memUsageBytes:z.usedMemory,numGaussians:s}}_extractGaussianPosition(e,t){const i=e[t+1];return{rawX:16383&i,rawY:i>>>14&16383,rawZ:i>>>28&15|(1023&e[t+2])<<4}}_extractGaussianSphericalScale(e,t){const i=e[t+2],s=i>>>10&255,a=i>>>18&255,r=i>>>26&63|(3&e[t+3])<<6,n=Math.exp(s/16-10),l=Math.exp(a/16-10),o=Math.exp(r/16-10);return Math.max(n,l,o)}freeRenderable(e){this._tileFadeInsAwaitingInitialSort.delete(e),this._tileFadeOutsAwaitingInitialSort.delete(e);const t=this._tileHandles.get(e);t&&(0!==t.lifecycleState?(this.fadeHelper.onTileDiscarded(t),this._usedMemory-=t.usedMemory):this._cacheMemory-=t.usedMemory,this._intersectionHandler.removeTile(t),t.pageIds.forEach(e=>this.data.textureAtlas.freePage(e)),this.freeObject(t),this._tileHandles.delete(e)),this.updateGaussians()}freeObject(e){this._memCache.pop(`${e.handle}`)}notifyTileObbsChanged(e){this._elevationProvider&&this._elevationProvider.notifyObjectsChangedFunctional(t=>{for(const i of e)t(i.obb)})}setRenderableVisibility(e,t,i){const s=this._currentLyr3dVisibilityChange+1;let a=!1;for(let r=0;r<i;r++){const i=this._tileHandles.get(e[r]);if(!i)continue;const n=t[r]?this._prepareTileFadeIn(i,s):this._prepareTileFadeOut(i,s);a||=n}a&&(this._currentLyr3dVisibilityChange=s,this.updateGaussians())}_prepareTileFadeIn(e,t){const i=this._tileFadeOutsAwaitingInitialSort.delete(e.handle);return 2===e.lifecycleState?(this.fadeHelper.fadeTile(e,0),i):this._tileFadeInsAwaitingInitialSort.get(e.handle)!==t?(0===e.lifecycleState&&this._popTileFromCache(e),e.lifecycleState=1,this._tileFadeInsAwaitingInitialSort.set(e.handle,t),!0):i}_prepareTileFadeOut(e,t){const i=this._tileFadeInsAwaitingInitialSort.delete(e.handle);return i&&1===e.lifecycleState&&(this.moveTileToCache(e),e.lifecycleState=0),2!==e.lifecycleState?i:this._tileFadeOutsAwaitingInitialSort.get(e.handle)!==t?(this._tileFadeOutsAwaitingInitialSort.set(e.handle,t),!0):i}_onSortComplete(e,t){const i=this._tmpTilesWithChangedVisibility;i.length=0;const s=this._tmpSortedTileHandles;s.clear();for(let r=0;r<e.length;r++){const t=e[r];s.add(t.handle)}let a=this._triggerFadeIns(t,s,i);a=this._triggerFadeOuts(t,i),s.clear(),i.length>0&&this.notifyTileObbsChanged(i),a&&this.updateGaussians()}_triggerFadeIns(e,t,i){let s=!1;for(const[a,r]of this._tileFadeInsAwaitingInitialSort){if(r>e||!t.has(a))continue;const n=this._tileHandles.get(a);if(!n){this._tileFadeInsAwaitingInitialSort.delete(a);continue}const l=0===n.lifecycleState;2!==n.lifecycleState&&(n.lifecycleState=2,l&&this._popTileFromCache(n),i.push(n),s=!0),this.fadeHelper.fadeTile(n,0),this._tileFadeInsAwaitingInitialSort.delete(a)}return s}_triggerFadeOuts(e,t){let i=!1;for(const[s,a]of this._tileFadeOutsAwaitingInitialSort){if(a>e)continue;const r=this._tileHandles.get(s);if(r){const e=2===r.lifecycleState;this.fadeHelper.fadeTile(r,1),e&&0===r.lifecycleState&&(t.push(r),i=!0)}this._tileFadeOutsAwaitingInitialSort.delete(s)}return i}_popTileFromCache(e){this._usedMemory+=e.usedMemory,this._cacheMemory-=e.usedMemory,this._intersectionHandler.addTile(e),this._memCache.pop(`${e.handle}`)}moveTileToCache(e){this._usedMemory-=e.usedMemory,this._cacheMemory+=e.usedMemory,this._intersectionHandler.removeTile(e),this._memCache.put(`${e.handle}`,e)}destroy(){H(this),this._suspendedHandle&&(this._suspendedHandle=i(this._suspendedHandle)),this._intersectionHandler&&(this.view.sceneIntersectionHelper.removeIntersectionHandler(this._intersectionHandler),this._intersectionHandler=null),this._elevationProvider&&this.view.elevationProvider&&(this._elevationProvider.notifyObjectsChangedFunctional(e=>{for(const t of this._tileHandles.values())e(t.obb)}),this.view.elevationProvider.unregister(this._elevationProvider),this._elevationProvider=null),this._frameTask.remove(),this._renderNode.destroy(),this.data.destroy(),this._memCache.destroy()}_canProjectWithoutEngine(){if(1===this.view.state.viewingMode)return!0;if(m(this.view.renderSpatialReference)||f(this.view.renderSpatialReference))return!0;if(this.layer.esriCrsSpatialReference&&g(this.layer.esriCrsSpatialReference,this.view.renderSpatialReference)){if(115700===this.layer.esriCrsSpatialReference.vcsWkid)return!1;let e=w(this.layer.esriCrsSpatialReference);if(!e){const t=this.layer.esriCrsSpatialReference;let i="meters";!_(t)&&t.wkid&&-1!==t.wkid&&(i=r(y.units[y[t.wkid]])),i&&(e=new u({heightModel:"gravity-related-height",heightUnit:i}))}const t=this.view.heightModelInfo;return this._useEsriCrs=0===p(e,t,!1),this._useEsriCrs&&(e&&(this._metersPerVCSUnit=n(1,e.heightUnit,"meters")),this.fullExtentInLocalViewSpatialReference=this.layer.esriCrsFullExtent),this._useEsriCrs}return!1}_elevationInfoChanged(e){if(e?.offset)if(this._useEsriCrs){const t=S(e?.unit)/this._metersPerVCSUnit,i=e?.offset??0;this._wasm?.setLayerOffset(this,i*t)}else this._wasm?.setLayerOffset(this,v(e));else this._wasm?.setLayerOffset(this,0)}_slicePlaneEnabledChanged(e){this._renderNode&&(this._renderNode.slicePlaneEnabled=e),this._intersectionHandler&&(this._intersectionHandler.slicePlaneEnabled=e)}updateGaussians(){const e=new Array;for(const t of this._tileHandles.values())0!==t.lifecycleState&&e.push(t);this.data.updateGaussianVisibility(e,this._currentLyr3dVisibilityChange),this.notifyChange("updating")}setMaximumGaussianCount(e){this._wasm?.setMaximumGaussianSplatCount(e)}_freeInvisibleTiles(){for(const e of this._tileHandles.values())0===e.lifecycleState&&this._deleteTile(e)}extractHeader(e){const t=e.length-4,i=this.reinterpretU32AsFloat(e[t]),s=this.reinterpretU32AsFloat(e[t+1]),a=this.reinterpretU32AsFloat(e[t+2]),r=1/(1<<(255&e[t+3]));return{packedHeader:e.subarray(t,t+4),tileOrigin:{x:i,y:s,z:a},invPosScale:r}}_deleteTile(e){this._wasm?.onRenderableEvicted(this,e.handle,e.usedMemory),this.freeRenderable(e.handle)}reinterpretU32AsFloat(e){return this._u32View[0]=e,this._f32View[0]}get performanceInfo(){let e=0,t=0;return this._tileHandles.forEach(i=>{0===i.lifecycleState?t++:e++}),new C(this.usedMemory,e,t,this.cachedMemory)}get test(){}};e([l()],$.prototype,"layer",void 0),e([l({readOnly:!0})],$.prototype,"_clippingBox",null),e([l()],$.prototype,"elevationOffset",null),e([l({readOnly:!0})],$.prototype,"visibleAtCurrentScale",null),e([l()],$.prototype,"fullExtentInLocalViewSpatialReference",void 0),$=e([o("esri.views.3d.layers.GaussianSplatLayerView3D")],$);const X=$;export{X as default};
2
+ import{__decorate as e}from"tslib";import"../../../core/has.js";import t from"../../../core/Logger.js";import{removeMaybe as i}from"../../../core/maybe.js";import{watch as s,initial as a}from"../../../core/reactiveUtils.js";import{unitFromRESTJSON as r,convertUnit as n}from"../../../core/units.js";import{property as l,subclass as o}from"../../../core/accessorSupport/decorators.js";import{fromValues as h}from"../../../core/libs/gl-matrix-2/factories/quatf64.js";import{getReferenceEllipsoid as d}from"../../../geometry/ellipsoidUtils.js";import u from"../../../geometry/HeightModelInfo.js";import{create as c}from"../../../geometry/support/aaBoundingBox.js";import{isCompatible as p}from"../../../geometry/support/heightModelInfoUtils.js";import{isPlateCarree as m,isWebMercator as f,equals as g,isGeographic as _}from"../../../geometry/support/spatialReferenceUtils.js";import y from"../../../geometry/support/WKIDUnitConversion.js";import{getHeightModelInfoFromVCS as w}from"../../../layers/support/tiles3DUtils.js";import{getElevationOffsetInMeters as v}from"../../../support/elevationInfoUtils.js";import{getMetersPerUnit as S}from"../../../symbols/support/unitConversionUtils.js";import{GaussianSplatLayerViewPerformanceInfo as C}from"./GaussianSplatLayerViewPerformanceInfo.js";import{LayerView3D as b}from"./LayerView3D.js";import{addLayerViewToWasm as x,getLyr3DWasm as I,removeLayerViewFromWasm as H}from"./Lyr3DWasm.js";import{LayerElevationProvider as M}from"./i3s/LayerElevationProvider.js";import{ElevationRange as A}from"../support/ElevationRange.js";import{projectToBoundingBox as T}from"../support/extentUtils.js";import{Obb as P}from"../support/orientedBoundingBox.js";import{splatPageSizeInU32 as E,elementsPerSplatPage as F,packedGaussianSizeInU32 as j,splatPageSizeInU32WithoutHeader as O,gaussiansPerSplatPage as U,splatAtlasTextureWidth as G}from"../support/gaussianSplatting/GaussianSplatAtlasPages.js";import{GaussianSplatDataStore as R}from"../support/gaussianSplatting/GaussianSplatDataStore.js";import{GaussianSplatFadeHelper as V}from"../support/gaussianSplatting/GaussianSplatFadeHelper.js";import{GaussianSplatIntersectionHandler as L}from"../support/gaussianSplatting/GaussianSplatIntersectionHandler.js";import{GaussianTile as B}from"../support/gaussianSplatting/GaussianTile.js";import{GaussianSplatRenderNode as k}from"../webgl-engine/lib/GaussianSplatRenderNode.js";import D from"../../layers/LayerView.js";import{spatialReferenceIncompatibleError as N,isInEffectiveScaleRange as z}from"../../support/layerViewUtils.js";import{TaskPriority as q}from"../../support/Scheduler.js";const W=()=>t.getLogger("esri.views.3d.layers.GaussianSplatLayerView3D");let $=class extends(b(D)){constructor(e){super(e),this.type="gaussian-splat-3d",this.ignoresMemoryFactor=!1,this._tileHandles=new Map,this._pageBuffer=new Uint32Array(E),this._tmpTilesWithChangedVisibility=new Array,this._currentLyr3dVisibilityChange=0,this._tileFadeInsAwaitingInitialSort=new Map,this._tileFadeOutsAwaitingInitialSort=new Map,this._tmpSortedTileHandles=new Set,this._wasmLayerId=-1,this._metersPerVCSUnit=1,this._usedMemory=0,this._cacheMemory=0,this._useEsriCrs=!1,this.fullExtentInLocalViewSpatialReference=null,this._suspendedHandle=null,this._conversionBuffer=new ArrayBuffer(4),this._u32View=new Uint32Array(this._conversionBuffer),this._f32View=new Float32Array(this._conversionBuffer);const t=e.view.resourceController;this._memCache=t.memoryController.newCache(`GaussianSplat-${this.uid}`,e=>this._deleteTile(e)),this._frameTask=t.scheduler.registerTask(q.GAUSSIAN_SPLAT_TEXTURE_ATLAS)}get _clippingBox(){if(!this.view?.clippingArea)return null;const e=c();return T(this.view.clippingArea,e,this.view.renderSpatialReference)?e:null}get clippingBox(){return this._renderNode?.clippingBox??null}initialize(){if(!this._canProjectWithoutEngine())throw N("layer",this.layer.spatialReference.wkid,this.view.renderSpatialReference?.wkid);const e=x(this).then(e=>{this._wasmLayerId=e,this._renderNode=new k({view:this.view,layerView:this}),this.data=new R(this._renderNode,(e,t)=>this._onSortComplete(e,t)),this.fadeHelper=new V(this),this._intersectionHandler=new L(this),this.view.sceneIntersectionHelper.addIntersectionHandler(this._intersectionHandler),this._elevationProvider=new M({view:this.view,layerElevationSource:this,intersectionHandler:this._intersectionHandler}),this.view.elevationProvider.register(2,this._elevationProvider),this.addHandles([s(()=>this.layer.elevationInfo,e=>this._elevationInfoChanged(e)),s(()=>this.slicePlaneEnabled,e=>this._slicePlaneEnabledChanged(e),a)]),this._suspendedHandle=s(()=>this.suspended,e=>this._wasm?.setEnabled(this,!e),a),this.addHandles([s(()=>this._clippingBox,e=>this._renderNode.clippingBox=e,a)]),this.setMaximumGaussianCount(this.view.qualitySettings.gaussianSplat.maximumNumberOfGaussians)});this.addHandles([s(()=>this.view.qualitySettings.fadeDuration,e=>{this.fadeHelper.onFadeDurationChanged(e),this.data.fadingTexture.updateTexture(this.data.textureAtlas.pageAllocator.pageCount)}),s(()=>this.view.qualitySettings.gaussianSplat.maximumNumberOfGaussians,e=>this.setMaximumGaussianCount(e*this.view.quality)),s(()=>this.view.quality,e=>this.setMaximumGaussianCount(this.view.qualitySettings.gaussianSplat.maximumNumberOfGaussians*e))]),this.addResolvingPromise(e)}get wasmLayerId(){return this._wasmLayerId}get metersPerVCSUnit(){return this._metersPerVCSUnit}get tileHandles(){return this._tileHandles}get _wasm(){return I(this.view)}get usedMemory(){return this._usedMemory}get cachedMemory(){return this._cacheMemory}get unloadedMemory(){return 0}get useEsriCrs(){return this._useEsriCrs}get elevationProvider(){return this._elevationProvider}get elevationOffset(){return v(this.layer.elevationInfo)}get elevationRange(){const e=this.fullExtent;return e?.zmin&&e?.zmax?new A(e.zmin,e.zmax):null}getElevationRange(e){return this._intersectionHandler.getElevationRange(e)}get fullExtent(){return this.layer.fullExtent}get visibleAtCurrentScale(){return z(this.layer.effectiveScaleRange,this.view.scale)}isUpdating(){const e=this._wasm;return!(this._wasmLayerId<0||null==e)&&(e.isUpdating(this._wasmLayerId)||this.data.updating||this.fadeHelper.updating)}updatingFlagChanged(){this.notifyChange("updating")}async createRenderable(e){const t=e.meshData;if(null==t.data)throw new Error("meshData.data undefined");if(t.desc=JSON.parse(t.desc),null==t.desc)throw new Error("meshData.desc undefined");const i=t.desc.prims[0],s=i.vertexCount,a=i.atrbs[0].view,r=i.atrbs[0].view.byteCount,n=i.atrbs[0].view.byteOffset;let l=null;if("U32"!==a.type)return W().warnOnce("unexpected meshData.data format"),{memUsageBytes:0,numGaussians:0};l=new Uint32Array(t.data.buffer,n,r/4);const o=this.extractHeader(l),u=Math.ceil(s/U),c=new Uint32Array(s),p=new Array;let m=!1,f=0;const g=async e=>{for(;f<u&&!e.done&&!m;f++){let t=this.data.textureAtlas.requestPage();if(null===t&&(this._freeInvisibleTiles(),t=this.data.textureAtlas.requestPage()),null!==t){p.push(t);const i=s-f*U,a=Math.min(i,U),r=f*U;for(let e=0;e<a;e++)c[e+r]=e+F*t;const n=f*O;this._pageBuffer.set(l.subarray(n,n+a*j)),this._pageBuffer.set(o.packedHeader,O);const h=t*F,d=h%G,u=Math.floor(h/G);this.data.textureAtlas.update(d,u,this._pageBuffer),e.madeProgress()}else m=!0}f<u&&!m&&await this._frameTask.schedule(g)};if(await this._frameTask.schedule(g),m)return W().warnOnce("ran out of gaussian splat memory"),{memUsageBytes:0,numGaussians:0};const _=new Float32Array(3*s),y=new Uint32Array(s),w=new Uint32Array(s),v=2.048,S=o.tileOrigin.x*v,C=o.tileOrigin.y*v,b=o.tileOrigin.z*v,x=o.invPosScale;let I=null;if(t.desc.obb){const e=t.desc.obb.quaternion;I=new P(t.desc.obb.center,t.desc.obb.halfSize,h(...e))}I||(W().warnOnce("encountered tile without a bounding box"),I=new P);const H=I.centerX,M=I.centerY,T=I.centerZ,E=new A,R=this.view.state.isGlobal,V=R?d(this.view.spatialReference).radius:0;let L=0,k=0,D=0;const N=async e=>{for(;D<s&&!e.done;D++){const t=D*j,{rawX:i,rawY:s,rawZ:a}=this._extractGaussianPosition(l,t),r=l[t],n=this._extractGaussianPackedScaleCode(l,t),o=this._extractGaussianSphericalScale(n),h=i*x+S,d=s*x+C,u=a*x+b;_[L]=h-H,_[L+1]=d-M,_[L+2]=u-T;const c=R?Math.sqrt(h*h+d*d+u*u)-V:u;E.expandElevationRangeValues(c,c),y[D]=r,w[D]=n;const p=o*o;k=Math.max(k,p),L+=3,e.madeProgress()}D<s&&await this._frameTask.schedule(N)};await this._frameTask.schedule(N);const{fullExtent:z}=this.layer;z?.hasZ&&z.zmax&&z.zmin&&(E.minElevation=Math.max(E.minElevation,z.zmin),E.maxElevation=Math.min(E.maxElevation,z.zmax));const q=new B(e.handle,I,c,p,_,y,w,s,k,E);return this._memCache.put(`${q.handle}`,q),this._tileHandles.set(e.handle,q),this._cacheMemory+=q.usedMemory,{memUsageBytes:q.usedMemory,numGaussians:s}}_extractGaussianPosition(e,t){const i=e[t+1];return{rawX:16383&i,rawY:i>>>14&16383,rawZ:i>>>28&15|(1023&e[t+2])<<4}}_extractGaussianPackedScaleCode(e,t){const i=e[t+2];return i>>>10&255|(i>>>18&255)<<8|(i>>>26&63|(3&e[t+3])<<6)<<16}_extractGaussianSphericalScale(e){const t=255&e,i=e>>>8&255,s=e>>>16&255,a=Math.exp(t/16-10),r=Math.exp(i/16-10),n=Math.exp(s/16-10);return Math.max(a,r,n)}freeRenderable(e){this._tileFadeInsAwaitingInitialSort.delete(e),this._tileFadeOutsAwaitingInitialSort.delete(e);const t=this._tileHandles.get(e);if(t){0!==t.lifecycleState?(this.fadeHelper.onTileDiscarded(t),this._usedMemory-=t.usedMemory,this._intersectionHandler.removeTile(t)):this._cacheMemory-=t.usedMemory,t.pageIds.forEach(e=>this.data.textureAtlas.freePage(e)),this.freeObject(t),this._tileHandles.delete(e)}this.updateGaussians()}freeObject(e){this._memCache.pop(`${e.handle}`)}notifyTileObbsChanged(e){this._elevationProvider&&this._elevationProvider.notifyObjectsChangedFunctional(t=>{for(const i of e)t(i.obb)})}setRenderableVisibility(e,t,i){const s=this._currentLyr3dVisibilityChange+1;let a=!1;for(let r=0;r<i;r++){const i=this._tileHandles.get(e[r]);if(!i)continue;const n=t[r]?this._prepareTileFadeIn(i,s):this._prepareTileFadeOut(i,s);a||=n}a&&(this._currentLyr3dVisibilityChange=s,this.updateGaussians())}_prepareTileFadeIn(e,t){const i=this._tileFadeOutsAwaitingInitialSort.delete(e.handle);return 2===e.lifecycleState?(this.fadeHelper.fadeTile(e,0),i):this._tileFadeInsAwaitingInitialSort.get(e.handle)!==t?(0===e.lifecycleState&&this._popTileFromCache(e),e.lifecycleState=1,this._tileFadeInsAwaitingInitialSort.set(e.handle,t),!0):i}_prepareTileFadeOut(e,t){const i=this._tileFadeInsAwaitingInitialSort.delete(e.handle);return i&&1===e.lifecycleState&&(this.moveTileToCache(e),e.lifecycleState=0),2!==e.lifecycleState?i:this._tileFadeOutsAwaitingInitialSort.get(e.handle)!==t?(this._tileFadeOutsAwaitingInitialSort.set(e.handle,t),!0):i}_onSortComplete(e,t){const i=this._tmpTilesWithChangedVisibility;i.length=0;const s=this._tmpSortedTileHandles;s.clear();for(let r=0;r<e.length;r++){const t=e[r];s.add(t.handle)}let a=this._triggerFadeIns(t,s,i);a=this._triggerFadeOuts(t,i),s.clear(),i.length>0&&this.notifyTileObbsChanged(i),a&&this.updateGaussians()}_triggerFadeIns(e,t,i){let s=!1;for(const[a,r]of this._tileFadeInsAwaitingInitialSort){if(r>e||!t.has(a))continue;const n=this._tileHandles.get(a);if(!n){this._tileFadeInsAwaitingInitialSort.delete(a);continue}const l=0===n.lifecycleState;2!==n.lifecycleState&&(n.lifecycleState=2,l&&this._popTileFromCache(n),i.push(n),s=!0),this.fadeHelper.fadeTile(n,0),this._tileFadeInsAwaitingInitialSort.delete(a)}return s}_triggerFadeOuts(e,t){let i=!1;for(const[s,a]of this._tileFadeOutsAwaitingInitialSort){if(a>e)continue;const r=this._tileHandles.get(s);if(r){const e=2===r.lifecycleState;this.fadeHelper.fadeTile(r,1),e&&0===r.lifecycleState&&(t.push(r),i=!0)}this._tileFadeOutsAwaitingInitialSort.delete(s)}return i}_popTileFromCache(e){this._usedMemory+=e.usedMemory,this._cacheMemory-=e.usedMemory,this._intersectionHandler.addTile(e),this._memCache.pop(`${e.handle}`)}moveTileToCache(e){this._usedMemory-=e.usedMemory,this._cacheMemory+=e.usedMemory,this._intersectionHandler.removeTile(e),this._memCache.put(`${e.handle}`,e)}destroy(){H(this),this._suspendedHandle&&(this._suspendedHandle=i(this._suspendedHandle)),this._intersectionHandler&&(this.view.sceneIntersectionHelper.removeIntersectionHandler(this._intersectionHandler),this._intersectionHandler=null),this._elevationProvider&&this.view.elevationProvider&&(this._elevationProvider.notifyObjectsChangedFunctional(e=>{for(const t of this._tileHandles.values())e(t.obb)}),this.view.elevationProvider.unregister(this._elevationProvider),this._elevationProvider=null),this._frameTask.remove(),this._renderNode.destroy(),this.data.destroy(),this._memCache.destroy()}_canProjectWithoutEngine(){if(1===this.view.state.viewingMode)return!0;if(m(this.view.renderSpatialReference)||f(this.view.renderSpatialReference))return!0;if(this.layer.esriCrsSpatialReference&&g(this.layer.esriCrsSpatialReference,this.view.renderSpatialReference)){if(115700===this.layer.esriCrsSpatialReference.vcsWkid)return!1;let e=w(this.layer.esriCrsSpatialReference);if(!e){const t=this.layer.esriCrsSpatialReference;let i="meters";!_(t)&&t.wkid&&-1!==t.wkid&&(i=r(y.units[y[t.wkid]])),i&&(e=new u({heightModel:"gravity-related-height",heightUnit:i}))}const t=this.view.heightModelInfo;return this._useEsriCrs=0===p(e,t,!1),this._useEsriCrs&&(e&&(this._metersPerVCSUnit=n(1,e.heightUnit,"meters")),this.fullExtentInLocalViewSpatialReference=this.layer.esriCrsFullExtent),this._useEsriCrs}return!1}_elevationInfoChanged(e){if(e?.offset)if(this._useEsriCrs){const t=S(e?.unit)/this._metersPerVCSUnit,i=e?.offset??0;this._wasm?.setLayerOffset(this,i*t)}else this._wasm?.setLayerOffset(this,v(e));else this._wasm?.setLayerOffset(this,0)}_slicePlaneEnabledChanged(e){this._renderNode&&(this._renderNode.slicePlaneEnabled=e),this._intersectionHandler&&(this._intersectionHandler.slicePlaneEnabled=e)}updateGaussians(){const e=new Array;for(const t of this._tileHandles.values())0!==t.lifecycleState&&e.push(t);this.data.updateGaussianVisibility(e,this._currentLyr3dVisibilityChange),this.notifyChange("updating")}setMaximumGaussianCount(e){this._wasm?.setMaximumGaussianSplatCount(e)}_freeInvisibleTiles(){for(const e of this._tileHandles.values())0===e.lifecycleState&&this._deleteTile(e)}extractHeader(e){const t=e.length-4,i=this.reinterpretU32AsFloat(e[t]),s=this.reinterpretU32AsFloat(e[t+1]),a=this.reinterpretU32AsFloat(e[t+2]),r=1/(1<<(255&e[t+3]));return{packedHeader:e.subarray(t,t+4),tileOrigin:{x:i,y:s,z:a},invPosScale:r}}_deleteTile(e){this._wasm?.onRenderableEvicted(this,e.handle,e.usedMemory),this.freeRenderable(e.handle)}reinterpretU32AsFloat(e){return this._u32View[0]=e,this._f32View[0]}get performanceInfo(){let e=0,t=0;return this._tileHandles.forEach(i=>{0===i.lifecycleState?t++:e++}),new C(this.usedMemory,e,t,this.cachedMemory)}get test(){}};e([l()],$.prototype,"layer",void 0),e([l({readOnly:!0})],$.prototype,"_clippingBox",null),e([l()],$.prototype,"elevationOffset",null),e([l({readOnly:!0})],$.prototype,"visibleAtCurrentScale",null),e([l()],$.prototype,"fullExtentInLocalViewSpatialReference",void 0),$=e([o("esri.views.3d.layers.GaussianSplatLayerView3D")],$);const X=$;export{X as default};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{copy as o,normalize as t,set as e,subtract as n,cross as l}from"../../../../core/libs/gl-matrix-2/math/vec3.js";import{create as i}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{newDoubleArray as r}from"../../../../geometry/support/DoubleArray.js";import{newIndexArray as s}from"../../../../geometry/support/Indices.js";function c(e,n){const{worldUp:l,height:i,spherical:c,requireElevation:m,requireNormals:p,requireSizes:f}=n,d=e.vertexCount,a=e.outlineSegmentCount,g=3*(2*d+4*a),v=r(g),h=s(6*a+e.polygonIndexCount),b=s(e.polygonIndexCount),{positions:j,mapPositions:C,polygonIndices:q,outline:z}=e;if("tessellated-indices"!==z.output)return null;const S=z.outlineIndices;o(x,l);const w=m?r(g):void 0,A=p?r(g):void 0,D=f?r(g):void 0,E=q.length/3,N=i>0?1:-1;let P=0,U=0,k=d;for(let o=0;o<d;++o){const o=j[P],e=j[P+1],n=j[P+2];c&&(x[0]=o,x[1]=e,x[2]=n,t(x,x));const l=3*U;v[l+0]=o,v[l+1]=e,v[l+2]=n;const r=C[P+0],s=C[P+1],u=C[P+2];null!=w&&(w[l+0]=r,w[l+1]=s,w[l+2]=u),null!=A&&(A[l+0]=-N*x[0],A[l+1]=-N*x[1],A[l+2]=-N*x[2]),null!=D&&(D[U]=0);const m=3*k;v[m+0]=o+i*x[0],v[m+1]=e+i*x[1],v[m+2]=n+i*x[2],null!=w&&(w[m+0]=r,w[m+1]=s,w[m+2]=u),null!=D&&(D[k]=i),P+=3,U+=1,k+=1}let B=2*d,F=0;for(let o=0;o<S.length;++o){const t=S[o],e=t.length-1;e<=1||(u(v,w,D,A,t,e,d,B,h,F,i),B+=4*e,F+=2*e)}let G=0,H=0,J=3*F;const K=i<0?I:y,L=i<0?y:I;for(let o=0;o<E;++o)b[H]=q[G+K[0]],b[H+1]=q[G+K[1]],b[H+2]=q[G+K[2]],h[J]=q[G+L[0]]+d,h[J+1]=q[G+L[1]]+d,h[J+2]=q[G+L[2]]+d,H+=3,J+=3,G+=3;return{vertices:v,indices:h,bottomIndices:b,elevation:w,normals:A,sizes:D}}function u(o,t,e,n,l,i,r,s,c,u,d){t??=[],e??=[],n??=[];let a=s,g=s+1,v=s+2*i,h=s+2*i+1,x=3*u;for(let y=0;y<i;++y){const i=l[y],s=l[y+1],u=i+r,I=s+r;let b=i,j=s,C=u,q=I;d<0&&(b=I,j=s,C=u,q=i),m(o,b,j,C,f),p(o,t,n,e,f,a,b),p(o,t,n,e,f,g,j),p(o,t,n,e,f,v,C),p(o,t,n,e,f,h,q),c[x]=a,c[x+1]=v,c[x+2]=h,c[x+3]=a,c[x+4]=h,c[x+5]=g,x+=6,a+=2,g+=2,v+=2,h+=2}}function m(o,i,r,s,c){i*=3,r*=3,s*=3,e(d,o[i++],o[i++],o[i++]),e(a,o[r++],o[r++],o[r++]),e(g,o[s++],o[s++],o[s++]),n(v,a,d),n(h,g,d),l(c,h,v),t(c,c)}function p(o,t,e,n,l,i,r){n[i]=n[r],r*=3,o[i*=3]=o[r],o[i+1]=o[r+1],o[i+2]=o[r+2],t[i]=t[r],t[i+1]=t[r+1],t[i+2]=t[r+2],e[i]=l[0],e[i+1]=l[1],e[i+2]=l[2]}const f=i(),d=i(),a=i(),g=i(),v=i(),h=i(),x=i(),y=[0,2,1],I=[0,1,2];export{c as extrudePolygon};
2
+ import{copy as o,normalize as t,set as n,subtract as e,cross as i}from"../../../../core/libs/gl-matrix-2/math/vec3.js";import{create as l}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{newDoubleArray as s}from"../../../../geometry/support/DoubleArray.js";import{newIndexArray as r}from"../../../../geometry/support/Indices.js";function c(n,e){const{worldUp:i,height:l,spherical:c,requireElevation:m,requireNormals:p,requireSizes:f}=e,a=n.vertexCount,d=n.outlineSegmentCount,g=3*(2*a+4*d),v=s(g),h=r(6*d+n.polygonIndexCount),b=r(n.polygonIndexCount);if(m&&!("mapPositions"in n))return null;const{positions:j,polygonIndices:C,outline:q}=n,P="mapPositions"in n?n.mapPositions:j;if("tessellated-indices"!==q.output)return null;const z=q.outlineIndices;o(x,i);const S=m?s(g):void 0,w=p?s(g):void 0,A=f?s(g):void 0,D=C.length/3,E=l>0?1:-1;let N=0,U=0,k=a;for(let o=0;o<a;++o){const o=j[N],n=j[N+1],e=j[N+2];c&&(x[0]=o,x[1]=n,x[2]=e,t(x,x));const i=3*U;v[i+0]=o,v[i+1]=n,v[i+2]=e;const s=P[N+0],r=P[N+1],u=P[N+2];null!=S&&(S[i+0]=s,S[i+1]=r,S[i+2]=u),null!=w&&(w[i+0]=-E*x[0],w[i+1]=-E*x[1],w[i+2]=-E*x[2]),null!=A&&(A[U]=0);const m=3*k;v[m+0]=o+l*x[0],v[m+1]=n+l*x[1],v[m+2]=e+l*x[2],null!=S&&(S[m+0]=s,S[m+1]=r,S[m+2]=u),null!=A&&(A[k]=l),N+=3,U+=1,k+=1}let B=2*a,F=0;for(let o=0;o<z.length;++o){const t=z[o],n=t.length-1;n<=1||(u(v,S,A,w,t,n,a,B,h,F,l),B+=4*n,F+=2*n)}let G=0,H=0,J=3*F;const K=l<0?I:y,L=l<0?y:I;for(let o=0;o<D;++o)b[H]=C[G+K[0]],b[H+1]=C[G+K[1]],b[H+2]=C[G+K[2]],h[J]=C[G+L[0]]+a,h[J+1]=C[G+L[1]]+a,h[J+2]=C[G+L[2]]+a,H+=3,J+=3,G+=3;return{vertices:v,indices:h,bottomIndices:b,elevation:S,normals:w,sizes:A}}function u(o,t,n,e,i,l,s,r,c,u,a){t??=[],n??=[],e??=[];let d=r,g=r+1,v=r+2*l,h=r+2*l+1,x=3*u;for(let y=0;y<l;++y){const l=i[y],r=i[y+1],u=l+s,I=r+s;let b=l,j=r,C=u,q=I;a<0&&(b=I,j=r,C=u,q=l),m(o,b,j,C,f),p(o,t,e,n,f,d,b),p(o,t,e,n,f,g,j),p(o,t,e,n,f,v,C),p(o,t,e,n,f,h,q),c[x]=d,c[x+1]=v,c[x+2]=h,c[x+3]=d,c[x+4]=h,c[x+5]=g,x+=6,d+=2,g+=2,v+=2,h+=2}}function m(o,l,s,r,c){l*=3,s*=3,r*=3,n(a,o[l++],o[l++],o[l++]),n(d,o[s++],o[s++],o[s++]),n(g,o[r++],o[r++],o[r++]),e(v,d,a),e(h,g,a),i(c,h,v),t(c,c)}function p(o,t,n,e,i,l,s){e[l]=e[s],s*=3,o[l*=3]=o[s],o[l+1]=o[s+1],o[l+2]=o[s+2],t[l]=t[s],t[l+1]=t[s+1],t[l+2]=t[s+2],n[l]=i[0],n[l+1]=i[1],n[l+2]=i[2]}const f=l(),a=l(),d=l(),g=l(),v=l(),h=l(),x=l(),y=[0,2,1],I=[0,1,2];export{c as extrudePolygon};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{subtract as t,length as e,scale as i,negate as n,dot as s,set as o}from"../../../../core/libs/gl-matrix-2/math/vec3.js";import{create as r,fromValues as l}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{set as c}from"../../../../core/libs/gl-matrix-2/math/vec4.js";import{project as a}from"../../../../geometry/projectionUtils.js";import{intersects as u,contains as d}from"../../../../geometry/support/aaBoundingBox.js";import{fromExtent as m}from"../../../../geometry/support/aaBoundingRect.js";import{create as p}from"../../../../geometry/support/plane.js";import{fromPoints as f}from"../../../../geometry/support/ray.js";import{GaussianSplatTarget as h}from"../../layers/i3s/Intersector.js";import{createTileBVH as g}from"../../layers/support/Tiles3DBVH.js";import{ElevationRange as y}from"../ElevationRange.js";import{IntersectorResult as v}from"../../webgl-engine/lib/IntersectorResult.js";class w{constructor(t){this.layerView=t,this.type=0,this.slicePlaneEnabled=!1,this.isGround=!1,this.intersectionNormal=r(),this.intersectionRayDir=r(),this.intersectionPlane=p(),this.layerViewUid=t.uid;const e=t.view.viewingMode,i=t.layer.fullExtent,n=(i?a(i,t.view.renderSpatialReference):void 0)??t.view.extent,s=m(n);this._bvh=g(e,s)}destroy(){this._bvh.destroy()}addTile(t){this._bvh.addTile(t)}removeTile(t){this._bvh.removeTile(t)}intersect(r,a,m,p,g,y){const{intersectionRayDir:w,intersectionPlane:x,layerViewUid:R,intersectionNormal:V}=this,B=f(m,p);t(w,p,m);const E=1/e(w);i(w,w,E),n(V,w),c(x,w[0],w[1],w[2],-s(w,m));const P=new j,T=new j,U=r.options.store,_=2===U,D=0!==U,I=_?new Array:null,S=(t,e,i,n,s)=>(t.point=t.point?o(t.point,i,n,s):l(i,n,s),t.dist=e,t.normal=V,t.layerViewUid=R,t),q=m[0],C=m[1],N=m[2],X=w[0],Y=w[1],Z=w[2],A=this.layerView.clippingBox,G=t=>{const{relativePositions:e,squaredScales:i,gaussianCount:n,obb:s}=t,o=s.centerX,r=s.centerY,l=s.centerZ,c=A[0],u=A[1],d=A[2],f=A[3],h=A[4],g=A[5];for(let y=0,v=0;y<n;y++,v+=3){const t=e[v]+o,n=e[v+1]+r,s=e[v+2]+l;if(t<c||n<u||s<d||t>f||n>h||s>g)continue;const w=t-q,b=n-C,x=s-N,R=w*X+b*Y+x*Z;if(R<0)continue;if(w*w+b*b+x*x-R*R>i[y])continue;const V=R*E;if((a?.(m,p,V)??!0)&&((null==P.dist||V<P.dist)&&S(P,V,t,n,s),D&&(null==T.dist||V>T.dist)&&S(T,V,t,n,s),_)){const e=new j;I.push(S(e,V,t,n,s))}}},H=t=>{const{relativePositions:e,squaredScales:i,gaussianCount:n,obb:s}=t,o=s.centerX,r=s.centerY,l=s.centerZ,c=q-o,u=C-r,d=N-l;for(let f=0,h=0;f<n;f++,h+=3){const t=e[h]-c,n=e[h+1]-u,s=e[h+2]-d,o=t*X+n*Y+s*Z;if(o<0)continue;if(t*t+n*n+s*s-o*o>i[f])continue;const r=o*E;if(!(a?.(m,p,r)??!0))continue;const l=t+q,g=n+C,y=s+N;if((null==P.dist||r<P.dist)&&S(P,r,l,g,y),D&&(null==T.dist||r>T.dist)&&S(T,r,l,g,y),_){const t=new j;I.push(S(t,r,l,g,y))}}},M=(t,e)=>{const{min:i,max:n}=t.obb.signedDistanceRangePlane(x);if(n<0)return;const s=i*E;if(D||null==P.dist||!(P.dist<s)){if(null!=P.dist&&null!=T.dist){const t=n*E;if(P.dist<s&&T.dist>t)return}e?G(t):H(t)}},k=t=>{M(t,!1)},z=t=>{const e=t.boundingBox;null!=e&&u(e,A)&&M(t,!d(A,e))};this._bvh.forEachTileIntersectingRay(m,p,null!=A?z:k,y);const F=(t,e)=>{const{layerViewUid:i}=e,n=new h(e.point,i);t.set(0,n,e.dist,e.normal)};if(b(P)){const t=r.results.min;(null==t.distance||P.dist<t.distance)&&F(t,P)}if(b(T)&&0!==r.options.store){const t=r.results.max;(null==t.distance||T.dist>t.distance)&&F(t,T)}if(_&&I?.length)for(const t of I){const e=new v(B);F(e,t),r.results.all.push(e)}}getElevationRange(t){return this._bvh.getElevationRangeIntersectingSphere(t)??new y(0,0)}}function b(t){return null!=t.dist&&null!=t.point}class j{constructor(){this.point=null,this.dist=null,this.normal=null,this.layerViewUid=""}}export{w as GaussianSplatIntersectionHandler};
2
+ import{subtract as t,length as i,scale as e,negate as s,dot as n,transformQuatValues as o,set as r}from"../../../../core/libs/gl-matrix-2/math/vec3.js";import{create as l,fromValues as a}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{set as c}from"../../../../core/libs/gl-matrix-2/math/vec4.js";import{project as u}from"../../../../geometry/projectionUtils.js";import{intersects as d,contains as p}from"../../../../geometry/support/aaBoundingBox.js";import{fromExtent as m}from"../../../../geometry/support/aaBoundingRect.js";import{create as h}from"../../../../geometry/support/plane.js";import{fromPoints as f}from"../../../../geometry/support/ray.js";import{GaussianSplatTarget as g}from"../../layers/i3s/Intersector.js";import{createTileBVH as y}from"../../layers/support/Tiles3DBVH.js";import{ElevationRange as b}from"../ElevationRange.js";import{IntersectorResult as w}from"../../webgl-engine/lib/IntersectorResult.js";class v{constructor(t){this.layerView=t,this.type=0,this.slicePlaneEnabled=!1,this.isGround=!1,this._ellipsoidLocalRayOrigin=l(),this._ellipsoidLocalRayDir=l(),this.intersectionNormal=l(),this.intersectionRayDir=l(),this.intersectionPlane=h(),this.layerViewUid=t.uid;const i=t.view.viewingMode,e=t.layer.fullExtent,s=(e?u(e,t.view.renderSpatialReference):void 0)??t.view.extent,n=m(s);this._bvh=y(i,n)}destroy(){this._bvh.destroy()}addTile(t){this._bvh.addTile(t)}removeTile(t){this._bvh.removeTile(t)}intersect(o,l,u,m,h,y){const{intersectionRayDir:b,intersectionPlane:v,layerViewUid:_,intersectionNormal:j}=this,E=f(u,m);t(b,m,u);const S=1/i(b);e(b,b,S),s(j,b),c(v,b[0],b[1],b[2],-n(b,u));const V=new x,k=new x,T=o.options.store,B=0===T,D=!B,P=2===T,U=P?new Array:null,M=(t,i,e,s,n)=>(t.point=t.point?r(t.point,e,s,n):a(e,s,n),t.dist=i,t.normal=j,t.layerViewUid=_,t),G=u[0],I=u[1],L=u[2],q=b[0],A=b[1],C=b[2],N=this.layerView.clippingBox,O=t=>{const{relativePositions:i,packedRotations:e,packedScales:s,gaussianCount:n,obb:o,maxScaleSquared:r}=t,a=o.centerX,c=o.centerY,d=o.centerZ,p=N[0],h=N[1],f=N[2],g=N[3],y=N[4],b=N[5];for(let w=0,v=0;w<n;w++,v+=3){const t=i[v]+a,n=i[v+1]+c,o=i[v+2]+d;if(t<p||n<h||o<f||t>g||n>y||o>b)continue;const R=t-G,_=n-I,j=o-L,E=R*q+_*A+j*C;if(E<0)continue;if(R*R+_*_+j*j-E*E>r)continue;const T=E*S;if(B&&null!=V.dist&&T>=V.dist)continue;if((l?.(u,m,T)??!0)&&(this._intersectsGaussianEllipsoid(R,_,j,q,A,C,e[w],s[w])&&((null==V.dist||T<V.dist)&&M(V,T,t,n,o),D&&(null==k.dist||T>k.dist)&&M(k,T,t,n,o),P))){const i=new x;U.push(M(i,T,t,n,o))}}},X=t=>{const{relativePositions:i,packedRotations:e,packedScales:s,gaussianCount:n,obb:o,maxScaleSquared:r}=t,a=o.centerX,c=o.centerY,d=o.centerZ,p=G-a,h=I-c,f=L-d;for(let g=0,y=0;g<n;g++,y+=3){const t=i[y]-p,n=i[y+1]-h,o=i[y+2]-f,a=t*q+n*A+o*C;if(a<0)continue;if(t*t+n*n+o*o-a*a>r)continue;const c=a*S;if(B&&null!=V.dist&&c>=V.dist)continue;if(!(l?.(u,m,c)??!0))continue;if(!this._intersectsGaussianEllipsoid(t,n,o,q,A,C,e[g],s[g]))continue;const d=t+G,b=n+I,w=o+L;if((null==V.dist||c<V.dist)&&M(V,c,d,b,w),D&&(null==k.dist||c>k.dist)&&M(k,c,d,b,w),P){const t=new x;U.push(M(t,c,d,b,w))}}},Y=(t,i)=>{const{min:e,max:s}=t.obb.signedDistanceRangePlane(v);if(s<0)return;const n=e*S;if(!(B&&null!=V.dist&&V.dist<n)){if(null!=V.dist&&null!=k.dist){const t=s*S;if(V.dist<n&&k.dist>t)return}i?O(t):X(t)}},Z=t=>{Y(t,!1)},F=t=>{const i=t.boundingBox;null!=i&&d(i,N)&&Y(t,!p(N,i))};this._bvh.forEachTileIntersectingRay(u,m,null!=N?F:Z,y);const H=(t,i)=>{const{layerViewUid:e}=i,s=new g(i.point,e);t.set(0,s,i.dist,i.normal)};if(R(V)){const t=o.results.min;(null==t.distance||V.dist<t.distance)&&H(t,V)}if(R(k)&&D){const t=o.results.max;(null==t.distance||k.dist>t.distance)&&H(t,k)}if(P&&U?.length)for(const t of U){const i=new w(E);H(i,t),o.results.all.push(i)}}_intersectsGaussianEllipsoid(t,i,e,s,n,r,l,a){const c=l>>>30,u=1023&l,d=l>>>10&1023,p=l>>>20&1023,m=(u&_)*j*(1-2*(u>>>9&1)),h=(d&_)*j*(1-2*(d>>>9&1)),f=(p&_)*j*(1-2*(p>>>9&1));let g,y,b,w;const v=m*m+h*h+f*f,R=Math.sqrt(Math.max(0,1-v));switch(c){case 0:g=R,y=f,b=h,w=m;break;case 1:g=f,y=R,b=h,w=m;break;case 2:g=f,y=h,b=R,w=m;break;default:g=f,y=h,b=m,w=R}const x=this._ellipsoidLocalRayOrigin;x[0]=-t,x[1]=-i,x[2]=-e,o(x,x,-g,-y,-b,w);const E=this._ellipsoidLocalRayDir;E[0]=s,E[1]=n,E[2]=r,o(E,E,-g,-y,-b,w);const V=S[255&a],k=S[a>>>8&255],T=S[a>>>16],B=x[0]*V,D=x[1]*k,P=x[2]*T,U=B*B+D*D+P*P;if(U<=1)return!0;const M=E[0]*V,G=E[1]*k,I=E[2]*T,L=B*M+D*G+P*I;return!(L>0)&&L*L>=(M*M+G*G+I*I)*(U-1)}getElevationRange(t){return this._bvh.getElevationRangeIntersectingSphere(t)??new b(0,0)}}function R(t){return null!=t.dist&&null!=t.point}class x{constructor(){this.point=null,this.dist=null,this.normal=null,this.layerViewUid=""}}const _=511,j=Math.SQRT1_2/_,E=3,S=(()=>{const t=new Float64Array(256);for(let i=0;i<t.length;i++)t[i]=Math.exp(10-i/16)/E;return t})();export{v as GaussianSplatIntersectionHandler};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{reallocGrowthFactor as t}from"../../../../core/arrayUtils.js";import"../../../webgl/BufferObject.js";import{FramebufferObject as e}from"../../../webgl/FramebufferObject.js";import"../../../webgl/Program.js";import"../../../../core/has.js";import"../../../webgl/Renderbuffer.js";import r from"../../../webgl/Texture.js";import"../../../../core/Logger.js";import{PixelType as s,SizedPixelFormat as a}from"../../../webgl/enums.js";import"../../../webgl/Util.js";import{initialSplatAtlasTextureHeight as i,GaussianSplatAtlasPages as l,splatAtlasTextureWidth as o,elementsPerSplatPage as h}from"./GaussianSplatAtlasPages.js";import{TextureDescriptor as u}from"../../../webgl/TextureDescriptor.js";class p{constructor(t,e,r){this._splatAtlasTextureHeight=i,this.texture=null,this._rctx=t,this._fboCache=r,this.pageAllocator=new l,this._cache=e.newCache("gaussian texture cache",t=>t.dispose())}ensureTextureAtlas(){if(this.texture?.hasWebGLTextureObject)return;this.texture=null;const t=this._cache.pop("splatTextureAtlas");if(t)return void(this.texture=t);const e=new u;e.height=this._splatAtlasTextureHeight,e.width=o,e.pixelFormat=36249,e.dataType=s.UNSIGNED_INT,e.internalFormat=a.RGBA32UI,e.samplingMode=9728,e.wrapMode=33071,e.isImmutable=!0,this.texture=new r(this._rctx,e),this._updatePageAllocator()}grow(){if(!this.texture)return this.ensureTextureAtlas(),!1;const r=Math.floor(this._splatAtlasTextureHeight*t);if(r*o>this._rctx.parameters.maxPreferredTexturePixels)return!1;const s=new e(this._rctx,this.texture),a=this._fboCache.acquire(o,r,"gaussian splat atlas resize",11);return this._rctx.blitFramebuffer(s,a.fbo,16384,9728,0,0,o,this._splatAtlasTextureHeight,0,0,o,this._splatAtlasTextureHeight),this.texture?.dispose(),this.texture=a.fbo?.detachColorTexture(),s.dispose(),a.dispose(),this._splatAtlasTextureHeight=r,this._updatePageAllocator(),!0}requestPage(){let t=this.pageAllocator.findFirstFreePage();return null===t&&this.grow()&&(t=this.pageAllocator.findFirstFreePage()),null!==t&&this.pageAllocator.allocate(t),t}freePage(t){this.pageAllocator.free(t)}update(t,e,r){this.ensureTextureAtlas(),this.texture.updateData(0,t,e,h,1,r)}_updatePageAllocator(){const t=o*this._splatAtlasTextureHeight/h;this.pageAllocator.pageCount!==t&&this.pageAllocator.resize(t)}clear(){this.texture&&(this._cache.put("splatTextureAtlas",this.texture),this.texture=null)}destroy(){this._cache.destroy(),this.texture?.dispose(),this.texture=null}}export{p as GaussianSplatTextureAtlas};
2
+ import{reallocGrowthFactor as t}from"../../../../core/arrayUtils.js";import{initialSplatAtlasTextureHeight as e,GaussianSplatAtlasPages as s,splatAtlasTextureWidth as r,elementsPerSplatPage as a}from"./GaussianSplatAtlasPages.js";import{PixelType as i,SizedPixelFormat as l}from"../../../webgl/enums.js";import{DisposableFramebufferObject as o}from"../../../webgl/FramebufferObject.js";import h from"../../../webgl/Texture.js";import{TextureDescriptor as u}from"../../../webgl/TextureDescriptor.js";class p{constructor(t,r,a){this._splatAtlasTextureHeight=e,this.texture=null,this._rctx=t,this._fboCache=a,this.pageAllocator=new s,this._cache=r.newCache("gaussian texture cache",t=>t.dispose())}ensureTextureAtlas(){if(this.texture?.hasWebGLTextureObject)return;this.texture=null;const t=this._cache.pop("splatTextureAtlas");if(t)return void(this.texture=t);const e=new u;e.height=this._splatAtlasTextureHeight,e.width=r,e.pixelFormat=36249,e.dataType=i.UNSIGNED_INT,e.internalFormat=l.RGBA32UI,e.samplingMode=9728,e.wrapMode=33071,e.isImmutable=!0,this.texture=new h(this._rctx,e),this._updatePageAllocator()}grow(){if(!this.texture)return this.ensureTextureAtlas(),!1;const e=Math.floor(this._splatAtlasTextureHeight*t);if(e*r>this._rctx.parameters.maxPreferredTexturePixels)return!1;const s=new o(this._rctx,this.texture),a=this._fboCache.acquire(r,e,"gaussian splat atlas resize",11);return this._rctx.blitFramebuffer(s,a.fbo,16384,9728,0,0,r,this._splatAtlasTextureHeight,0,0,r,this._splatAtlasTextureHeight),this.texture?.dispose(),this.texture=a.fbo?.detachColorTexture(),s.dispose(),a.dispose(),this._splatAtlasTextureHeight=e,this._updatePageAllocator(),!0}requestPage(){let t=this.pageAllocator.findFirstFreePage();return null===t&&this.grow()&&(t=this.pageAllocator.findFirstFreePage()),null!==t&&this.pageAllocator.allocate(t),t}freePage(t){this.pageAllocator.free(t)}update(t,e,s){this.ensureTextureAtlas(),this.texture.updateData(0,t,e,a,1,s)}_updatePageAllocator(){const t=r*this._splatAtlasTextureHeight/a;this.pageAllocator.pageCount!==t&&this.pageAllocator.resize(t)}clear(){this.texture&&(this._cache.put("splatTextureAtlas",this.texture),this.texture=null)}destroy(){this._cache.destroy(),this.texture?.dispose(),this.texture=null}}export{p as GaussianSplatTextureAtlas};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{estimateNumberArrayMemory as t}from"../../../../core/memoryEstimations.js";import{create as s}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{create as e}from"../../../../geometry/support/aaBoundingBox.js";import{splatPageSizeInU32 as i}from"./GaussianSplatAtlasPages.js";class o{constructor(o,r,n,a,h,b,u,c,d){this.handle=o,this.obb=r,this.gaussianAtlasIndices=n,this.pageIds=a,this.relativePositions=h,this.squaredScales=b,this.gaussianCount=u,this.maxScale=c,this.elevationRange=d,this.bvhIntersectionGeneration=0,this.lifecycleState=0,this.fadeDirection=0,this.opacityModifier=0,this.boundingBox=null,this.usedMemory=t(this.gaussianAtlasIndices,this.relativePositions,this.squaredScales)+this.pageIds.length*i*4;const l=s();r.getCenter(l),this._obbCenterX=l[0],this._obbCenterY=l[1],this._obbCenterZ=l[2];const f=r.radius??-1;this._obbRadius=f;const m=f<0?-1:f*f;this._obbRadiusSquared=m;const g=r.halfSize;this._obbShortestHalfsize=g?Math.min(g[0],g[1],g[2]):0;const _=e();r.toAaBoundingBox(_),this.boundingBox=_}boundingVolumeIntersectsRay(t,s){if(!this.obb)return!0;const{_obbCenterX:e,_obbCenterY:i,_obbCenterZ:o}=this,r=e-t[0],n=i-t[1],a=o-t[2],h=r*s[0]+n*s[1]+a*s[2],b=r*r+n*n+a*a-h*h;return(this._obbRadiusSquared<0||b<=this._obbRadiusSquared)&&this.obb.intersectRay(t,s)}boundingVolumeIntersectsSphere(t){const s=this._obbRadius;if(s<0)return!0;const e=t.center,i=t.radius,o=s+i,r=this._obbCenterX-e[0];if(r>o)return!1;const n=this._obbCenterY-e[1];if(n>o)return!1;const a=this._obbCenterZ-e[2];if(a>o)return!1;const h=r*r+n*n+a*a;if(h>o*o)return!1;if(h<=(this._obbShortestHalfsize+i)**2)return!0;return Math.sqrt(h)+s<=i||(this.obb?.intersectSphere(t)??!0)}}export{o as GaussianTile};
2
+ import{estimateNumberArrayMemory as t}from"../../../../core/memoryEstimations.js";import{create as s}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{create as e}from"../../../../geometry/support/aaBoundingBox.js";import{splatPageSizeInU32 as i}from"./GaussianSplatAtlasPages.js";class o{constructor(o,n,r,a,h,b,c,u,d,l){this.handle=o,this.obb=n,this.gaussianAtlasIndices=r,this.pageIds=a,this.relativePositions=h,this.packedRotations=b,this.packedScales=c,this.gaussianCount=u,this.maxScaleSquared=d,this.elevationRange=l,this.bvhIntersectionGeneration=0,this.lifecycleState=0,this.fadeDirection=0,this.opacityModifier=0,this.boundingBox=null,this.usedMemory=t(this.gaussianAtlasIndices,this.relativePositions,this.packedRotations,this.packedScales)+this.pageIds.length*i*4;const f=s();n.getCenter(f),this._obbCenterX=f[0],this._obbCenterY=f[1],this._obbCenterZ=f[2];const m=n.radius??-1;this._obbRadius=m;const g=m<0?-1:m*m;this._obbRadiusSquared=g;const p=n.halfSize;this._obbShortestHalfsize=p?Math.min(p[0],p[1],p[2]):0;const _=e();n.toAaBoundingBox(_),this.boundingBox=_}boundingVolumeIntersectsRay(t,s){if(!this.obb)return!0;const{_obbCenterX:e,_obbCenterY:i,_obbCenterZ:o}=this,n=e-t[0],r=i-t[1],a=o-t[2],h=n*s[0]+r*s[1]+a*s[2],b=n*n+r*r+a*a-h*h;return(this._obbRadiusSquared<0||b<=this._obbRadiusSquared)&&this.obb.intersectRay(t,s)}boundingVolumeIntersectsSphere(t){const s=this._obbRadius;if(s<0)return!0;const e=t.center,i=t.radius,o=s+i,n=this._obbCenterX-e[0];if(n>o)return!1;const r=this._obbCenterY-e[1];if(r>o)return!1;const a=this._obbCenterZ-e[2];if(a>o)return!1;const h=n*n+r*r+a*a;if(h>o*o)return!1;if(h<=(this._obbShortestHalfsize+i)**2)return!0;return Math.sqrt(h)+s<=i||(this.obb?.intersectSphere(t)??!0)}}export{o as GaussianTile};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{projectBuffer as e}from"../../../../geometry/projection/projectBuffer.js";import{newDoubleArray as t,doubleSubArray as n}from"../../../../geometry/support/DoubleArray.js";import{applyPerVertexElevationAlignment as s}from"../../layers/graphics/elevationAlignmentUtils.js";import{load as i,axisFromRings as o,ringsToOutlinedTessellationInfo as l,tessellateOrLoad as r}from"../../layers/graphics/tessellationUtils.js";import{drapedZ as u}from"../../terrain/OverlayRenderer.js";async function c(){return i()}class a{constructor(e,t,n,s){this.positions=e,this.polygonIndices=t,this.outline=n,this.projectionSuccess=s,this.count=e.length/3}get vertexCount(){return this.positions.length/3}get polygonIndexCount(){return this.polygonIndices.length}get outlineIndexCount(){const{outline:e}=this;if("tessellated-indices"!==e.output)return 0;let t=0;for(let n=0;n<e.outlineIndices.length;n++)t+=y(e.outlineIndices[n]);return t}get outlineSegmentCount(){const{outline:e}=this;if("tessellated-indices"!==e.output)return 0;let t=0;for(let n=0;n<e.outlineIndices.length;n++){const s=y(e.outlineIndices[n]);s>1&&(t+=s)}return t}}class p extends a{}class d extends a{}class f extends a{constructor(e,t,n,s,i,o){super(e,n,s,i),this.mapPositions=t,this.sampledElevation=o}}function g(e,t){const{projectIfNearlyVertical:n=!1,outlineOutput:s="none"}=t??{},i="tessellated-indices"===s,u=o(e.rings,!!e.hasZ,e.spatialReference),c=l(e.rings,{hasZ:!!e.hasZ,ccwRingsAsHoles:!0,spatialReference:e.spatialReference,axis:u}),{pending:a,result:p}=r(c,{projectionAxis:n?u:void 0,outlines:i?c.outlines:void 0});if(a||!p.succeeded)return null;let f={output:"none"};if("vertex-data"===s){const e=p.positions!==c.positions?c.positions:c.positions.slice();f={output:"vertex-data",outlines:m(c.outlines,e)}}else"tessellated-indices"===s&&(f=R(p));return new d(p.positions,p.indices,f,!0)}function h(t,n){const{drapedSpatialReference:s,projectIfNearlyVertical:i=!1,outlineOutput:c="none"}=n,a=o(t.rings,!1,t.spatialReference),d=l(t.rings,{hasZ:!1,ccwRingsAsHoles:!0,spatialReference:t.spatialReference,axis:a}),f="none"!==c,g=e(d.positions,t.spatialReference,0,d.positions,s,0),{pending:h,result:x}=r(d,{projectionAxis:i?a:void 0,outlines:f?d.outlines:void 0});if(h||!x.succeeded)return null;const{positions:v,indices:y}=x;for(let e=2;e<v.length;e+=3)v[e]=u;let j={output:"none"};if("vertex-data"===c){if(v!==d.positions)for(let t=2;t<d.positions.length;t+=3)d.positions[t]=u;const e=v!==d.positions?d.positions:d.positions.slice();j={output:"vertex-data",outlines:m(d.outlines,e)}}else"tessellated-indices"===c&&(j=R(x));return new p(v,y,j,g)}function x(e,n,i,u,c){const{projectIfNearlyVertical:a=!1,outlineOutput:p="none"}=c??{},d="none"!==p,g=!!e.hasZ&&"on-the-ground"!==u.mode,h=o(e.rings,g,e.spatialReference),x=l(e.rings,{hasZ:g,ccwRingsAsHoles:!0,spatialReference:e.spatialReference,axis:h}),{pending:m,result:y}=r(x,{projectionAxis:a?h:void 0,outlines:d?x.outlines:void 0});if(m||!y.succeeded)return null;const{positions:j,vertexCount:I}=y,w=t(j.length),A=s(j,e.spatialReference,0,w,0,j,0,I,n,i,u);let Z={output:"none"};"vertex-data"===p?Z={output:"vertex-data",outlines:v(y,w)}:"tessellated-indices"===p&&(Z=R(y));const C=null!=A;return new f(j,w,y.indices,Z,C,A)}function m(e,t,s=null){return e.filter(({count:e})=>e>1).map(({index:e,count:i})=>{const o=3*e,l=3*i;return null!=s?new I(e,i,n(t,o,l),n(s,o,l)):new j(e,i,n(t,o,l))})}function R(e){const{outlineIndexBuffer:t,outlineRingLengths:n}=e;if(null==t||null==n)return{output:"none"};const s=new Array(n.length);let i=0;for(let o=0;o<n.length;o++){const e=n[o],l=t.slice(i,i+e);s[o]=l,i+=e}return{output:"tessellated-indices",outlineIndices:s}}function v(e,s){const{outlineIndexBuffer:i,outlineRingLengths:o,positions:l}=e;if(null==i||null==o)return[];let r=0;for(let t=0;t<o.length;t++)r+=o[t]-1;const u=t(3*r),c=t(3*r),a=new Array;let p=0,d=0;for(let t=0;t<o.length;t++){const e=o[t],r=e-1;for(let t=0;t<r;t++){const e=3*i[p+t],n=3*(d+t);u[n]=l[e],u[n+1]=l[e+1],u[n+2]=l[e+2],c[n]=s[e],c[n+1]=s[e+1],c[n+2]=s[e+2]}a.push(new I(d,r,n(u,3*d,3*r),n(c,3*d,3*r))),p+=e,d+=r}return a}function y(e,t=0,n=e.length){return n>1&&e[t]===e[t+n-1]?n-1:n}class j{constructor(e,t,n){this.index=e,this.count=t,this.position=n}}class I extends j{constructor(e,t,n,s){super(e,t,n),this.mapPositions=s}}export{I as OutlineVertexData,j as OutlineVertexDataDraped,a as PolygonRenderInfoBase,p as PolygonRenderInfoDraped,f as PolygonRenderInfoElevationAligned,d as PolygonRenderInfoNotElevationAligned,c as load,h as polygonToRenderInfoDraped,x as polygonToRenderInfoElevationAligned,g as polygonToRenderInfoNotElevationAligned,R as splitOutlineIndexRings,v as tessellatedOutlineIndicesToVertexData};
2
+ import{projectBuffer as e}from"../../../../geometry/projection/projectBuffer.js";import{newDoubleArray as t,doubleSubArray as n}from"../../../../geometry/support/DoubleArray.js";import{applyPerVertexElevationAlignment as s}from"../../layers/graphics/elevationAlignmentUtils.js";import{axisFromRings as i,ringsToOutlinedTessellationInfo as o,tessellateOrLoad as l,load as r}from"../../layers/graphics/tessellationUtils.js";import{drapedZ as u}from"../../terrain/OverlayRenderer.js";async function c(){return r()}class a{constructor(e,t,n,s){this.positions=e,this.polygonIndices=t,this.outline=n,this.projectionSuccess=s,this.count=e.length/3}get vertexCount(){return this.positions.length/3}get polygonIndexCount(){return this.polygonIndices.length}get outlineIndexCount(){const{outline:e}=this;if("tessellated-indices"!==e.output)return 0;let t=0;for(let n=0;n<e.outlineIndices.length;n++)t+=y(e.outlineIndices[n]);return t}get outlineSegmentCount(){const{outline:e}=this;if("tessellated-indices"!==e.output)return 0;let t=0;for(let n=0;n<e.outlineIndices.length;n++){const s=y(e.outlineIndices[n]);s>1&&(t+=s)}return t}}class p extends a{}class d extends a{}class f extends a{constructor(e,t,n,s,i,o){super(e,n,s,i),this.mapPositions=t,this.sampledElevation=o}}function g(e,t){const{projectIfNearlyVertical:n=!1,outlineOutput:s="none"}=t??{},r="tessellated-indices"===s,u=i(e.rings,!!e.hasZ,e.spatialReference),c=o(e.rings,{hasZ:!!e.hasZ,ccwRingsAsHoles:!0,spatialReference:e.spatialReference,axis:u}),{pending:a,result:p}=l(c,{projectionAxis:n?u:void 0,outlines:r?c.outlines:void 0});if(a||!p.succeeded)return null;let f={output:"none"};if("vertex-data"===s){const e=p.positions!==c.positions?c.positions:c.positions.slice();f={output:"vertex-data",outlines:m(c.outlines,e)}}else"tessellated-indices"===s&&(f=R(p));return new d(p.positions,p.indices,f,!0)}function h(t,n){const{drapedSpatialReference:s,projectIfNearlyVertical:r=!1,outlineOutput:c="none"}=n,a=i(t.rings,!1,t.spatialReference),d=o(t.rings,{hasZ:!1,ccwRingsAsHoles:!0,spatialReference:t.spatialReference,axis:a}),f="none"!==c,g=e(d.positions,t.spatialReference,0,d.positions,s,0),{pending:h,result:x}=l(d,{projectionAxis:r?a:void 0,outlines:f?d.outlines:void 0});if(h||!x.succeeded)return null;const{positions:v,indices:y}=x;for(let e=2;e<v.length;e+=3)v[e]=u;let j={output:"none"};if("vertex-data"===c){if(v!==d.positions)for(let t=2;t<d.positions.length;t+=3)d.positions[t]=u;const e=v!==d.positions?d.positions:d.positions.slice();j={output:"vertex-data",outlines:m(d.outlines,e)}}else"tessellated-indices"===c&&(j=R(x));return new p(v,y,j,g)}function x(e,n,r,u,c){const{projectIfNearlyVertical:a=!1,outlineOutput:p="none"}=c??{},d="none"!==p,g=!!e.hasZ&&"on-the-ground"!==u.mode,h=i(e.rings,g,e.spatialReference),x=o(e.rings,{hasZ:g,ccwRingsAsHoles:!0,spatialReference:e.spatialReference,axis:h}),{pending:m,result:y}=l(x,{projectionAxis:a?h:void 0,outlines:d?x.outlines:void 0});if(m||!y.succeeded)return null;const{positions:j,vertexCount:I}=y,w=t(j.length),A=s(j,e.spatialReference,0,w,0,j,0,I,n,r,u);let Z={output:"none"};"vertex-data"===p?Z={output:"vertex-data",outlines:v(y,w)}:"tessellated-indices"===p&&(Z=R(y));const C=null!=A;return new f(j,w,y.indices,Z,C,A)}function m(e,t,s=null){return e.filter(({count:e})=>e>1).map(({index:e,count:i})=>{const o=3*e,l=3*i;return null!=s?new I(e,i,n(t,o,l),n(s,o,l)):new j(e,i,n(t,o,l))})}function R(e){const{outlineIndexBuffer:t,outlineRingLengths:n}=e;if(null==t||null==n)return{output:"none"};const s=new Array(n.length);let i=0;for(let o=0;o<n.length;o++){const e=n[o],l=t.slice(i,i+e);s[o]=l,i+=e}return{output:"tessellated-indices",outlineIndices:s}}function v(e,s){const{outlineIndexBuffer:i,outlineRingLengths:o,positions:l}=e;if(null==i||null==o)return[];let r=0;for(let t=0;t<o.length;t++)r+=o[t]-1;const u=t(3*r),c=t(3*r),a=new Array;let p=0,d=0;for(let t=0;t<o.length;t++){const e=o[t],r=e-1;for(let t=0;t<r;t++){const e=3*i[p+t],n=3*(d+t);u[n]=l[e],u[n+1]=l[e+1],u[n+2]=l[e+2],c[n]=s[e],c[n+1]=s[e+1],c[n+2]=s[e+2]}a.push(new I(d,r,n(u,3*d,3*r),n(c,3*d,3*r))),p+=e,d+=r}return a}function y(e,t=0,n=e.length){return n>1&&e[t]===e[t+n-1]?n-1:n}class j{constructor(e,t,n){this.index=e,this.count=t,this.position=n}}class I extends j{constructor(e,t,n,s){super(e,t,n),this.mapPositions=s}}export{I as OutlineVertexData,j as OutlineVertexDataDraped,a as PolygonRenderInfoBase,p as PolygonRenderInfoDraped,f as PolygonRenderInfoElevationAligned,d as PolygonRenderInfoNotElevationAligned,c as load,h as polygonToRenderInfoDraped,x as polygonToRenderInfoElevationAligned,g as polygonToRenderInfoNotElevationAligned,R as splitOutlineIndexRings,v as tessellatedOutlineIndicesToVertexData};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{SizedDepthStencilFormat as e}from"../../../webgl/enums.js";import{FramebufferObject as t}from"../../../webgl/FramebufferObject.js";import{RenderbufferDescriptor as r}from"../../../webgl/RenderbufferDescriptor.js";import{TextureDescriptor as s}from"../../../webgl/TextureDescriptor.js";class o{constructor(e){this._rctx=e,this._fbos=new Map}get(e){return this._getPool(e)}dispose(){this._fbos.forEach(e=>e.dispose()),this._fbos.clear()}_getPool(o){const i=this._fbos.get(o);if(i)return i;const f=new t(this._rctx,new s(o),new r(e.DEPTH24_STENCIL8,o));return this._fbos.set(o,f),f}}export{o as MultiSizeFramebuffer};
2
+ import{SizedDepthStencilFormat as e}from"../../../webgl/enums.js";import{DisposableFramebufferObject as t}from"../../../webgl/FramebufferObject.js";import{RenderbufferDescriptor as r}from"../../../webgl/RenderbufferDescriptor.js";import{TextureDescriptor as s}from"../../../webgl/TextureDescriptor.js";class o{constructor(e){this._rctx=e,this._fbos=new Map}get(e){return this._getPool(e)}dispose(){this._fbos.forEach(e=>e.dispose()),this._fbos.clear()}_getPool(o){const i=this._fbos.get(o);if(i)return i;const f=new t(this._rctx,new s(o),new r(e.DEPTH24_STENCIL8,o));return this._fbos.set(o,f),f}}export{o as MultiSizeFramebuffer};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{__decorate as t}from"tslib";import{someMap as e}from"../../../core/MapUtils.js";import{releaseMaybe as o}from"../../../core/maybe.js";import{subclass as h}from"../../../core/accessorSupport/decorators.js";import{RenderNodeOutput as s}from"../webgl.js";import{isManagedDepthTexture as r}from"./ManagedDepthTexture.js";import i from"./ManagedFBOResource.js";import{ColorAttachment0 as a,DepthStencilAttachment as c}from"../../webgl/enums.js";let l=class extends i{constructor(t,e,o,h,r,i){super(t,i),this.fbo=o,this.type=0,this._colors=new Map,this._name=s.COMPOSITE,this.acquireColor=null,this.acquireDepth=null,this._name=e,this.acquireColor=h,this.acquireDepth=r}dispose(){this.fbo?.dispose()}get usedMemory(){return this.fbo?.usedMemory||0}get name(){return this._name}setName(t){this._name=t}getTexture(t=a){return t===c?this.fbo?.depthStencilTexture:this.fbo?.getColorTexture(t)}get depthTexture(){return this.getTexture(c)}getAttachment(t=a){return t===c?this._depth:this._colors.get(t)}obtainAttachment(t){const e=this.getAttachment(t);return e?.retain(),this.detachColor(t),e}hasAttachment(t){return e(this._colors,e=>e.name===t)}attachDepth(t){return t?.retain(),this.detachDepth(),t&&this.fbo?.attachDepthStencil(t.attachment),this._depth=t,this}detachDepth(){this.fbo?.detachDepthStencilTexture(),this.fbo?.detachDepthStencilBuffer(),this._depth=o(this._depth)}obtainDepthTexture(){const t=this._depth;return r(t)?(this.fbo?.detachDepthStencilTexture(),this._depth=null,t):null}attachColor(t,e){return t.retain(),this.detachColor(e),this.fbo?.attachColorTexture(t.attachment,e),this._colors.set(e,t),this}detachColor(t){this.fbo?.detachColorTexture(t),this._colors.get(t)?.release(),this._colors.delete(t)}detachAllColors(){this._colors.forEach((t,e)=>this.detachColor(e))}detachAll(){this.detachAllColors(),this.detachDepth()}detachAllColorsBut0(){const t=new Map(this._colors);t.delete(a),this.fbo.detachColorTextures(...t.keys()),t.forEach((t,e)=>{this._colors.get(e)?.release(),this._colors.delete(e)})}detachAllButColor0(){this.detachAllColorsBut0(),this.detachDepth()}};l=t([h("esri.views.3d.webgl.ManagedFBO")],l);const n=l;export{n as default};
2
+ import{__decorate as t}from"tslib";import{someMap as e}from"../../../core/MapUtils.js";import{releaseMaybe as o}from"../../../core/maybe.js";import{subclass as s}from"../../../core/accessorSupport/decorators.js";import{RenderNodeOutput as r}from"../webgl.js";import{isManagedDepthTexture as h}from"./ManagedDepthTexture.js";import i from"./ManagedFBOResource.js";import{ColorAttachment0 as a,DepthStencilAttachment as c}from"../../webgl/enums.js";let l=class extends i{constructor(t,e,o,s,h,i){super(t,i),this.fbo=o,this.type=0,this._colors=new Map,this._name=r.COMPOSITE,this.acquireColor=null,this.acquireDepth=null,this._name=e,this.acquireColor=s,this.acquireDepth=h}dispose(){this.fbo?.dispose()}get usedMemory(){return this.fbo?.usedMemory||0}get name(){return this._name}setName(t){this._name=t}getTexture(t=a){return t===c?this.fbo?.depthStencilTexture:this.fbo?.getColorTexture(t)}get depthTexture(){return this.getTexture(c)}getAttachment(t=a){return t===c?this._depth:this._colors.get(t)}obtainAttachment(t){const e=this.getAttachment(t);return e?.retain(),this.detachColor(t),e}hasAttachment(t){return e(this._colors,e=>e.name===t)}attachDepth(t){return t?.retain(),this.detachDepth(),t&&this.fbo?.attachDepthStencil(t.attachment),this._depth=t,this}detachDepth(){this.fbo?.detachDepthStencilTexture(),this.fbo?.detachDepthStencilBuffer(),this._depth=o(this._depth)}obtainDepthTexture(){const t=this._depth;return h(t)?(this.fbo?.detachDepthStencilTexture(),this._depth=null,t):null}attachColor(t,e){return t.retain(),this.detachColor(e),this.fbo?.attachColorTexture(t.attachment,e),this._colors.set(e,t),this}detachColor(t){this.fbo?.detachColorTexture(t),this._colors.get(t)?.release(),this._colors.delete(t)}detachAllColors(){const t=Array.from(this._colors.keys());this._detachColors(t)}detachAll(){this.detachAllColors(),this.detachDepth()}detachAllColorsBut0(){const t=Array.from(this._colors.keys());t.shift(),this._detachColors(t)}_detachColors(t){this.fbo.detachColorTextures(...t),t.forEach(t=>{this._colors.get(t)?.release(),this._colors.delete(t)})}detachAllButColor0(){this.detachAllColorsBut0(),this.detachDepth()}};l=t([s("esri.views.3d.webgl.ManagedFBO")],l);const n=l;export{n as default};
@@ -107,7 +107,7 @@ export interface RenderNodeProperties extends Partial<Pick<RenderNode, "produces
107
107
  * used for advanced graphics effects. The following additional inputs are available:
108
108
  *
109
109
  * <span id="render-node-input-images"></span>
110
- * | <img src="https://developers.arcgis.com/javascript/latest/assets/references/core/views/3d/rendernodeCompositeColor.png" style="width:200px;"/> | <img src="https://developers.arcgis.com/javascript/latest/assets/references/core/views/3d/rendernodeCompositeColorDepth.png" style="width:200px;"/> | <img src="https://developers.arcgis.com/javascript/latest/assets/references/core/views/3d/rendernodeCompositeEmissive.png" style="width:200px;"/> | <img src="https://developers.arcgis.com/javascript/latest/assets/references/core/views/3d/rendernodeHighlight.png" style="width:200px;"/> | <img src="https://developers.arcgis.com/javascript/latest/assets/references/core/views/3d/rendernodeNormals.png" style="width:200px;"/> |
110
+ * | <img src="https://developers.arcgis.com/javascript/latest/assets/references/core/views/3d/rendernodeCompositeColor.avif" style="width:200px;"/> | <img src="https://developers.arcgis.com/javascript/latest/assets/references/core/views/3d/rendernodeCompositeColorDepth.avif" style="width:200px;"/> | <img src="https://developers.arcgis.com/javascript/latest/assets/references/core/views/3d/rendernodeCompositeEmissive.avif" style="width:200px;"/> | <img src="https://developers.arcgis.com/javascript/latest/assets/references/core/views/3d/rendernodeHighlight.avif" style="width:200px;"/> | <img src="https://developers.arcgis.com/javascript/latest/assets/references/core/views/3d/rendernodeNormals.avif" style="width:200px;"/> |
111
111
  * | ---------- | ---------- | ---------- | ---------- | ---------- |
112
112
  * | composite-color | composite-color depth attachment | composite-color emissive attachment | highlights | normals |
113
113
  *
@@ -142,7 +142,7 @@ export interface RenderNodeProperties extends Partial<Pick<RenderNode, "produces
142
142
  * drawn as a perfect sphere with a radius of 6378137, so the unit of the coordinate system should be considered
143
143
  * meters.
144
144
  *
145
- * ![rendernode-global-coordinate-system](https://developers.arcgis.com/javascript/latest/assets/references/core/views/3d/externalRenderers-global-coordinate-system.png)
145
+ * ![rendernode-global-coordinate-system](https://developers.arcgis.com/javascript/latest/assets/references/core/views/3d/externalRenderers-global-coordinate-system.avif)
146
146
  *
147
147
  * You can use [toRenderCoordinates()](https://developers.arcgis.com/javascript/latest/references/core/views/3d/webgl/#toRenderCoordinates) and [fromRenderCoordinates()](https://developers.arcgis.com/javascript/latest/references/core/views/3d/webgl/#fromRenderCoordinates) to transform to
148
148
  * and from the rendering coordinate system without having to worry about viewingMode and the exact coordinate system
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import"../../../../core/has.js";import e from"../../webgl/ManagedColorAttachment.js";import{ManagedDepthTexture as t}from"../../webgl/ManagedDepthTexture.js";import a from"../../webgl/ManagedFBO.js";import{isDepthFormat as r,formatString as c,DepthTextureFormats as h,ColorFormats as i}from"./FBOCacheFormats.js";import{FBOCacheUsage as s}from"./FBOCacheUsage.js";import{FBOPool as o}from"./FBOPool.js";import{DepthStencilAttachment as n,ColorAttachment0 as l}from"../../../webgl/enums.js";import{FramebufferObject as u}from"../../../webgl/FramebufferObject.js";import m from"../../../webgl/Texture.js";class d{constructor(e){this.rctx=e,this._interactive=!1,this._usage=new s,this._acquired=new Set,this._cache=new o(e.newCache,"FBOCache"),this._depthCache=new o(e.newCache,"DepthAttachmentCache"),this._colorCache=new o(e.newCache,"ColorAttachmentCache")}destroy(){this._cache.destroy(),this._depthCache.destroy(),this._colorCache.destroy()}clean(){this._cache.clean(),this._colorCache.clean(),this._depthCache.clean()}frameStart(){this._cache.frame(),this._colorCache.frame(),this._depthCache.frame(),this.debugCallback?.(),this._usage.clear()}frameEnd(){const{debugCallback:e}=this;e&&(this._usage.summarize(),this._acquired.forEach(t=>e(t.name,t.fbo)))}get usedMemory(){return Array.from(this._acquired.values()).reduce((e,t)=>e+t.usedMemory,this._cache.usedMemory+this._colorCache.usedMemory+this._depthCache.usedMemory)}set interactive(e){this._cache.interactive=this._colorCache.interactive=this._depthCache.interactive=e,this._interactive=e}get interactive(){return this._interactive}acquire(e,t,h,i=5){const s=p(i,e,t);let o=this._cache.pop(s);const{rctx:m}=this;if(o){o.retain(),o.setName(h);const e=o.getAttachment(n);e&&(e.name=C);const t=o.getAttachment(l);t&&(t.name=_(0)),m.unbindTexture(o.fbo.colorTexture)}else{const c=new u(m),d=(a,r,c)=>{r??=5;const h=this._acquireColor(r,e,t,c??_(a-l));return this.rctx.unbindTexture(h.attachment),o.attachColor(h,a),h.release(),o},p=a=>{a??=13;const r=this.acquireDepth(a,e,t,`${o.name} ${C}`);return o.attachDepth(r),r.release(),o},f=()=>{if(!o)return;this.debugCallback?.(o.name,o.fbo),this._acquired.delete(o);const e=r(i);e&&null!=o.getAttachment(n)||!e&&null!=o.getAttachment(l)?(e?(o.fbo?.invalidateAttachments([n]),o.detachAllColors()):(o.fbo?.invalidateAttachments([l]),o.detachAllButColor0()),this._trackRelease(o),this._cache.put(o)):o.dispose()};o=new a(s,h,c,d,p,f),r(i)?o.acquireDepth(i):o.acquireColor(l,i)}return this._trackAcquire(o,"f "+c(i),e,t),this._trackHandle(o)}acquireDepth(e,a,r,i){const s=p(e,a,r);let o=this._depthCache.pop(s);if(o)o.retain(),o.attachment.setShadowFiltering(!1);else{const c=new m(this.rctx,{...h[e],width:a,height:r});o=new t(s,c,()=>{this._trackRelease(o),this._depthCache.put(o)})}return o.name=i,this._trackAcquire(o,"d "+c(e),a,r),o}_acquireColor(t,a,r,h){const s=p(t,a,r);let o=this._colorCache.pop(s);if(o)o.retain();else{const c=new m(this.rctx,{...i[t],width:a,height:r,isImmutable:!0});o=new e(s,c,()=>{this._trackRelease(o),this._colorCache.put(o)})}return o.name=h,this._trackAcquire(o,"c "+c(t),a,r),o}_trackHandle(e){return this._acquired.add(e),e}_trackAcquire(e,t,a,r){this.debugCallback&&this._usage.add(e,t,a,r)}_trackRelease(e){this.debugCallback&&this._usage.remove(e)}get test(){return null}}function _(e=0){return`color${e}`}const C="depth";function p(e,t,a){return`${t}x${a}:${e}`}export{d as FBOCache};
2
+ import"../../../../core/has.js";import e from"../../webgl/ManagedColorAttachment.js";import{ManagedDepthTexture as t}from"../../webgl/ManagedDepthTexture.js";import a from"../../webgl/ManagedFBO.js";import{isDepthFormat as r,formatString as c,DepthTextureFormats as h,ColorFormats as i}from"./FBOCacheFormats.js";import{FBOCacheUsage as s}from"./FBOCacheUsage.js";import{FBOPool as o}from"./FBOPool.js";import{DepthStencilAttachment as n,ColorAttachment0 as l}from"../../../webgl/enums.js";import{DisposableFramebufferObject as u}from"../../../webgl/FramebufferObject.js";import m from"../../../webgl/Texture.js";class d{constructor(e){this.rctx=e,this._interactive=!1,this._usage=new s,this._acquired=new Set,this._cache=new o(e.newCache,"FBOCache"),this._depthCache=new o(e.newCache,"DepthAttachmentCache"),this._colorCache=new o(e.newCache,"ColorAttachmentCache")}destroy(){this._cache.destroy(),this._depthCache.destroy(),this._colorCache.destroy()}clean(){this._cache.clean(),this._colorCache.clean(),this._depthCache.clean()}frameStart(){this._cache.frame(),this._colorCache.frame(),this._depthCache.frame(),this.debugCallback?.(),this._usage.clear()}frameEnd(){const{debugCallback:e}=this;e&&(this._usage.summarize(),this._acquired.forEach(t=>e(t.name,t.fbo)))}get usedMemory(){return Array.from(this._acquired.values()).reduce((e,t)=>e+t.usedMemory,this._cache.usedMemory+this._colorCache.usedMemory+this._depthCache.usedMemory)}set interactive(e){this._cache.interactive=this._colorCache.interactive=this._depthCache.interactive=e,this._interactive=e}get interactive(){return this._interactive}acquire(e,t,h,i=5){const s=p(i,e,t);let o=this._cache.pop(s);const{rctx:m}=this;if(o){o.retain(),o.setName(h);const e=o.getAttachment(n);e&&(e.name=C);const t=o.getAttachment(l);t&&(t.name=_(0)),m.unbindTexture(o.fbo.colorTexture)}else{const c=new u(m),d=(a,r,c)=>{r??=5;const h=this._acquireColor(r,e,t,c??_(a-l));return this.rctx.unbindTexture(h.attachment),o.attachColor(h,a),h.release(),o},p=a=>{a??=13;const r=this.acquireDepth(a,e,t,`${o.name} ${C}`);return o.attachDepth(r),r.release(),o},f=()=>{if(!o)return;this.debugCallback?.(o.name,o.fbo),this._acquired.delete(o);const e=r(i);e&&null!=o.getAttachment(n)||!e&&null!=o.getAttachment(l)?(e?(o.fbo?.invalidateAttachments([n]),o.detachAllColors()):(o.fbo?.invalidateAttachments([l]),o.detachAllButColor0()),this._trackRelease(o),this._cache.put(o)):o.dispose()};o=new a(s,h,c,d,p,f),r(i)?o.acquireDepth(i):o.acquireColor(l,i)}return this._trackAcquire(o,"f "+c(i),e,t),this._trackHandle(o)}acquireDepth(e,a,r,i){const s=p(e,a,r);let o=this._depthCache.pop(s);if(o)o.retain(),o.attachment.setShadowFiltering(!1);else{const c=new m(this.rctx,{...h[e],width:a,height:r});o=new t(s,c,()=>{this._trackRelease(o),this._depthCache.put(o)})}return o.name=i,this._trackAcquire(o,"d "+c(e),a,r),o}_acquireColor(t,a,r,h){const s=p(t,a,r);let o=this._colorCache.pop(s);if(o)o.retain();else{const c=new m(this.rctx,{...i[t],width:a,height:r,isImmutable:!0});o=new e(s,c,()=>{this._trackRelease(o),this._colorCache.put(o)})}return o.name=h,this._trackAcquire(o,"c "+c(t),a,r),o}_trackHandle(e){return this._acquired.add(e),e}_trackAcquire(e,t,a,r){this.debugCallback&&this._usage.add(e,t,a,r)}_trackRelease(e){this.debugCallback&&this._usage.remove(e)}get test(){return null}}function _(e=0){return`color${e}`}const C="depth";function p(e,t,a){return`${t}x${a}:${e}`}export{d as FBOCache};
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
2
- import{__decorate as s}from"tslib";import{disposeMaybe as e}from"../../../../../core/maybe.js";import{someSet as t}from"../../../../../core/SetUtils.js";import{subclass as r}from"../../../../../core/accessorSupport/decorators.js";import{fromMat4 as a,transpose as i,invert as o}from"../../../../../core/libs/gl-matrix-2/math/mat3.js";import{create as h}from"../../../../../core/libs/gl-matrix-2/factories/mat3f64.js";import{set as n,copy as m}from"../../../../../core/libs/gl-matrix-2/math/vec3.js";import{create as c}from"../../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{MaterialPassParameters as d,ShadowMapPassParameters as u,HighlightPassParameters as p,ViewshedShadowMapPassParameters as l,AllRenderPasses as _}from"./AllRenderPasses.js";import{TwoVectorPosition as w}from"../util/TwoVectorPosition.js";import{SyncRenderPlugin as f}from"../../effects/RenderPlugin.js";import{DepthRange as P}from"../../lib/DepthRange.js";import{SizedPixelFormat as g,DataType as x}from"../../../../webgl/enums.js";import y from"../../../../webgl/Texture.js";import{TextureDescriptor as b}from"../../../../webgl/TextureDescriptor.js";let T=class extends f{constructor(){super(...arguments),this.produces=new Map([[2,s=>this._produces(s,2)],[4,s=>this._produces(s,4)],[0,s=>this._produces(s,0)],[7,s=>this._produces(s,7)],[10,s=>this._produces(s,10)]]),this._drawParametersArray=new Array,this._drawParametersSet=new Set,this._transformationTexture=null,this._materialPassParameters=new d,this._shadowPassParameters=new u,this._highlightPassParameters=new p,this._viewshedPassParameters=new l,this._systems=new Set}initializeRenderContext(s){this._context=s,this._passes=new _(s,this)}get rctx(){return this._context.renderContext.rctx}get bind(){return this._context.renderContext.bind}uninitializeRenderContext(){}dispose(){this._context=null,this._systems.clear(),this._transformationTexture=e(this._transformationTexture),this._passes?.opaque.destroy(),this._passes?.transparent.destroy(),this._passes?.integratedMesh.destroy(),this._passes?.transparentIntegratedMesh.destroy(),this._passes?.occludedGround.destroy(),this._passes?.shadowMap.destroy(),this._passes?.highlight.destroy(),this._passes?.highlightIntegratedMesh.destroy(),this._passes?.highlightShadowMap.destroy(),this._passes?.viewshedShadowMap.destroy(),this._passes?.defaultShadowMap.destroy(),this._passes=null}register(s){this._systems.add(s)}_produces(s,e){return!!this._invoke(s,e,s=>s.count>0)}prepareRender(s){const{_systems:t,_passes:r}=this;if(0!==t.size&&null!=r){this._drawParametersSet.clear(),this._drawParametersArray.length=0,this._transformationTexture=e(this._transformationTexture);for(const s of Object.values(r))s.prepareSubmit();t.forEach(e=>e.submit(r,s.bind)),this._updateTransformationTexture();for(const s of Object.values(r))s.finishSubmit();this._context.techniques.frameUpdate()}}acquireTechniques(s){if(0===this._systems.size)return null;const e=5===s.output||6===s.output||7===s.output?this._shadowPassParameters:8===s.output?this._viewshedPassParameters:10===s.output?this._highlightPassParameters:this._materialPassParameters,{bind:t}=s;return this._updateParameters(t.camera,e,t.slot),this._invoke(s.output,s.bind.slot,(e,t)=>(t.transformationTexture=this._transformationTexture,e.acquire(t,s.bind)))}render(s,e){this._invoke(s.output,s.bind.slot,(t,r)=>t.dispatch(r,s.bind,e))}_invoke(s,e,t){if(null==this._passes)return null;switch(e){case 2:switch(s){case 0:case 1:case 2:case 3:case 4:case 11:return t(this._passes.opaque,this._materialPassParameters);case 10:return t(this._passes.highlight,this._highlightPassParameters);case 5:return t(this._passes.shadowMap,this._shadowPassParameters);case 6:return t(this._passes.highlightShadowMap,this._shadowPassParameters);case 7:return t(this._passes.defaultShadowMap,this._shadowPassParameters);case 8:return t(this._passes.viewshedShadowMap,this._viewshedPassParameters)}break;case 4:switch(s){case 0:case 1:case 2:case 3:case 4:case 11:return t(this._passes.transparent,this._materialPassParameters)}break;case 0:switch(s){case 0:case 1:case 2:case 3:case 4:case 11:case 9:return t(this._passes.integratedMesh,this._materialPassParameters);case 10:return t(this._passes.highlightIntegratedMesh,this._highlightPassParameters)}break;case 7:switch(s){case 0:case 1:case 2:return t(this._passes.transparentIntegratedMesh,this._materialPassParameters)}break;case 10:switch(s){case 0:case 1:case 2:case 3:case 4:case 11:return t(this._passes.occludedGround,this._materialPassParameters)}}return null}requestRender(){this._context.requestRender()}queryDepthRange(s){const e=new P;return this._systems.forEach(t=>e.union(t.queryDepthRange(s))),e}get hasEmissions(){return t(this._systems,s=>0!==s.hasEmissions)?3:0}_updateParameters(s,e,t){const r=s.viewInverseTransposeMatrix,h=4===t,c=10===t;n(M,r[3],r[7],r[11]),S.set(M),m(e.transformWorldFromViewTH,S.high),m(e.transformWorldFromViewTL,S.low),m(e.slicePlaneLocalOrigin,M),a(e.transformViewFromCameraRelativeRS,s.viewMatrix),0===e.identifier&&(this._materialPassParameters.transparent=h,this._materialPassParameters.occludedGround=c,i(v,e.transformViewFromCameraRelativeRS),o(e.transformNormalViewFromGlobal,v))}hasHighlight(s){return t(this._systems,e=>e.hasHighlight(s))}registerDrawParameters(s){if(!this._drawParametersSet.has(s)){this._drawParametersSet.add(s);const e=this._drawParametersArray.length;this._drawParametersArray.push(s),s.setTransformationDrawId(e)}}_updateTransformationTexture(){const s=this._drawParametersArray.length;if(0===s)return;const e=5,t=3*e,r=2**Math.ceil(Math.log2(s)),a=new Float32Array(r*t);for(let i=0;i<s;i++){const s=this._drawParametersArray[i];s.setTransformationDrawId(i);const e=i*t;a.set(s.transformationFloats,e)}if(this._transformationTexture&&this._transformationTexture.descriptor.height>=s)this._transformationTexture.updateData(0,0,0,e,s,a);else{this._transformationTexture?.dispose();const s=new b(e,r);s.internalFormat=g.RGB32F,s.dataType=x.FLOAT,s.hasMipmap=!1,s.isImmutable=!0,s.pixelFormat=6407,s.samplingMode=9728,this._transformationTexture=new y(this.rctx,s,a)}}};T=s([r("esri.views.3d.webgl-engine.core.renderPasses.RenderPassManager")],T);const M=c(),v=h(),S=new w;export{T as RenderPassManager};
2
+ import{__decorate as s}from"tslib";import{disposeMaybe as e}from"../../../../../core/maybe.js";import{someSet as t}from"../../../../../core/SetUtils.js";import{subclass as r}from"../../../../../core/accessorSupport/decorators.js";import{fromMat4 as a,transpose as i,invert as o}from"../../../../../core/libs/gl-matrix-2/math/mat3.js";import{create as n}from"../../../../../core/libs/gl-matrix-2/factories/mat3f64.js";import{set as h,copy as m}from"../../../../../core/libs/gl-matrix-2/math/vec3.js";import{create as c}from"../../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{MaterialPassParameters as d,ShadowMapPassParameters as u,HighlightPassParameters as p,ViewshedShadowMapPassParameters as l,AllRenderPasses as _}from"./AllRenderPasses.js";import{TwoVectorPosition as w}from"../util/TwoVectorPosition.js";import{SyncRenderPlugin as f}from"../../effects/RenderPlugin.js";import{DepthRange as g}from"../../lib/DepthRange.js";import{SizedPixelFormat as P,DataType as x}from"../../../../webgl/enums.js";import y from"../../../../webgl/Texture.js";import{TextureDescriptor as b}from"../../../../webgl/TextureDescriptor.js";let T=class extends f{constructor(){super(...arguments),this.produces=new Map([[2,s=>this._produces(s,2)],[4,s=>this._produces(s,4)],[0,s=>this._produces(s,0)],[7,s=>this._produces(s,7)],[10,s=>this._produces(s,10)]]),this._drawParametersArray=new Array,this._drawParametersSet=new Set,this._transformationTexture=null,this._materialPassParameters=new d,this._shadowPassParameters=new u,this._highlightPassParameters=new p,this._viewshedPassParameters=new l,this._systems=new Set}initializeRenderContext(s){this._context=s,this._passes=new _(s,this)}get rctx(){return this._context.renderContext.rctx}get bind(){return this._context.renderContext.bind}uninitializeRenderContext(){}dispose(){this._context=null,this._systems.clear(),this._transformationTexture=e(this._transformationTexture),this._passes?.opaque.destroy(),this._passes?.transparent.destroy(),this._passes?.integratedMesh.destroy(),this._passes?.transparentIntegratedMesh.destroy(),this._passes?.occludedGround.destroy(),this._passes?.shadowMap.destroy(),this._passes?.highlight.destroy(),this._passes?.highlightIntegratedMesh.destroy(),this._passes?.highlightShadowMap.destroy(),this._passes?.viewshedShadowMap.destroy(),this._passes?.defaultShadowMap.destroy(),this._passes=null}register(s){this._systems.add(s)}_produces(s,e){return!!this._invoke(s,e,s=>s.count>0)}prepareRender(s){const{_systems:t,_passes:r}=this;if(0!==t.size&&null!=r){this._drawParametersSet.clear(),this._drawParametersArray.length=0,this._transformationTexture=e(this._transformationTexture);for(const s of Object.values(r))s.prepareSubmit();t.forEach(e=>e.submit(r,s.bind)),this._updateTransformationTexture();for(const s of Object.values(r))s.finishSubmit();this._context.techniques.frameUpdate()}}acquireTechniques(s){if(0===this._systems.size)return null;const{output:e,bind:t}=s;return this._invoke(e,t.slot,(e,r)=>(this._updateParameters(t.camera,r,t.slot),r.transformationTexture=this._transformationTexture,e.acquire(r,s.bind)))}render(s,e){this._invoke(s.output,s.bind.slot,(t,r)=>t.dispatch(r,s.bind,e))}_invoke(s,e,t){if(null==this._passes)return null;switch(e){case 2:switch(s){case 0:case 1:case 2:case 3:case 4:case 11:return t(this._passes.opaque,this._materialPassParameters);case 10:return t(this._passes.highlight,this._highlightPassParameters);case 5:return t(this._passes.shadowMap,this._shadowPassParameters);case 6:return t(this._passes.highlightShadowMap,this._shadowPassParameters);case 7:return t(this._passes.defaultShadowMap,this._shadowPassParameters);case 8:return t(this._passes.viewshedShadowMap,this._viewshedPassParameters)}break;case 4:switch(s){case 0:case 1:case 2:case 3:case 4:case 11:return t(this._passes.transparent,this._materialPassParameters)}break;case 0:switch(s){case 0:case 1:case 2:case 3:case 4:case 11:case 9:return t(this._passes.integratedMesh,this._materialPassParameters);case 10:return t(this._passes.highlightIntegratedMesh,this._highlightPassParameters)}break;case 7:switch(s){case 0:case 1:case 2:return t(this._passes.transparentIntegratedMesh,this._materialPassParameters)}break;case 10:switch(s){case 0:case 1:case 2:case 3:case 4:case 11:return t(this._passes.occludedGround,this._materialPassParameters)}}return null}requestRender(){this._context.requestRender()}queryDepthRange(s){const e=new g;return this._systems.forEach(t=>e.union(t.queryDepthRange(s))),e}get hasEmissions(){return t(this._systems,s=>0!==s.hasEmissions)?3:0}_updateParameters(s,e,t){const r=s.viewInverseTransposeMatrix,n=4===t,c=10===t;h(M,r[3],r[7],r[11]),S.set(M),m(e.transformWorldFromViewTH,S.high),m(e.transformWorldFromViewTL,S.low),m(e.slicePlaneLocalOrigin,M),a(e.transformViewFromCameraRelativeRS,s.viewMatrix),0===e.identifier&&(this._materialPassParameters.transparent=n,this._materialPassParameters.occludedGround=c,i(v,e.transformViewFromCameraRelativeRS),o(e.transformNormalViewFromGlobal,v))}hasHighlight(s){return t(this._systems,e=>e.hasHighlight(s))}registerDrawParameters(s){if(!this._drawParametersSet.has(s)){this._drawParametersSet.add(s);const e=this._drawParametersArray.length;this._drawParametersArray.push(s),s.setTransformationDrawId(e)}}_updateTransformationTexture(){const s=this._drawParametersArray.length;if(0===s)return;const e=5,t=3*e,r=2**Math.ceil(Math.log2(s)),a=new Float32Array(r*t);for(let i=0;i<s;i++){const s=this._drawParametersArray[i];s.setTransformationDrawId(i);const e=i*t;a.set(s.transformationFloats,e)}if(this._transformationTexture&&this._transformationTexture.descriptor.height>=s)this._transformationTexture.updateData(0,0,0,e,s,a);else{this._transformationTexture?.dispose();const s=new b(e,r);s.internalFormat=P.RGB32F,s.dataType=x.FLOAT,s.hasMipmap=!1,s.isImmutable=!0,s.pixelFormat=6407,s.samplingMode=9728,this._transformationTexture=new y(this.rctx,s,a)}}};T=s([r("esri.views.3d.webgl-engine.core.renderPasses.RenderPassManager")],T);const M=c(),v=n(),S=new w;export{T as RenderPassManager};