@arcgis/core 5.0.0-next.60 → 5.0.0-next.62

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 (662) hide show
  1. package/Graphic.d.ts +1 -1
  2. package/analysis/VolumeMeasurement/volumeMeasurementConfiguration.js +1 -1
  3. package/applications/Components/previewSymbol2D.d.ts +1 -1
  4. package/applications/Components/webStyleSymbolUtils.d.ts +1 -1
  5. package/assets/components/assets/combobox/t9n/messages.ar.json +1 -1
  6. package/assets/components/assets/combobox/t9n/messages.bg.json +1 -1
  7. package/assets/components/assets/combobox/t9n/messages.bs.json +1 -1
  8. package/assets/components/assets/combobox/t9n/messages.ca.json +1 -1
  9. package/assets/components/assets/combobox/t9n/messages.cs.json +1 -1
  10. package/assets/components/assets/combobox/t9n/messages.da.json +1 -1
  11. package/assets/components/assets/combobox/t9n/messages.de.json +1 -1
  12. package/assets/components/assets/combobox/t9n/messages.el.json +1 -1
  13. package/assets/components/assets/combobox/t9n/messages.en.json +1 -1
  14. package/assets/components/assets/combobox/t9n/messages.es.json +1 -1
  15. package/assets/components/assets/combobox/t9n/messages.et.json +1 -1
  16. package/assets/components/assets/combobox/t9n/messages.fi.json +1 -1
  17. package/assets/components/assets/combobox/t9n/messages.fr.json +1 -1
  18. package/assets/components/assets/combobox/t9n/messages.he.json +1 -1
  19. package/assets/components/assets/combobox/t9n/messages.hr.json +1 -1
  20. package/assets/components/assets/combobox/t9n/messages.hu.json +1 -1
  21. package/assets/components/assets/combobox/t9n/messages.id.json +1 -1
  22. package/assets/components/assets/combobox/t9n/messages.it.json +1 -1
  23. package/assets/components/assets/combobox/t9n/messages.ja.json +1 -1
  24. package/assets/components/assets/combobox/t9n/messages.json +1 -1
  25. package/assets/components/assets/combobox/t9n/messages.ko.json +1 -1
  26. package/assets/components/assets/combobox/t9n/messages.lt.json +1 -1
  27. package/assets/components/assets/combobox/t9n/messages.lv.json +1 -1
  28. package/assets/components/assets/combobox/t9n/messages.nl.json +1 -1
  29. package/assets/components/assets/combobox/t9n/messages.no.json +1 -1
  30. package/assets/components/assets/combobox/t9n/messages.pl.json +1 -1
  31. package/assets/components/assets/combobox/t9n/messages.pt-BR.json +1 -1
  32. package/assets/components/assets/combobox/t9n/messages.pt-PT.json +1 -1
  33. package/assets/components/assets/combobox/t9n/messages.ro.json +1 -1
  34. package/assets/components/assets/combobox/t9n/messages.ru.json +1 -1
  35. package/assets/components/assets/combobox/t9n/messages.sk.json +1 -1
  36. package/assets/components/assets/combobox/t9n/messages.sl.json +1 -1
  37. package/assets/components/assets/combobox/t9n/messages.sr.json +1 -1
  38. package/assets/components/assets/combobox/t9n/messages.sv.json +1 -1
  39. package/assets/components/assets/combobox/t9n/messages.th.json +1 -1
  40. package/assets/components/assets/combobox/t9n/messages.tr.json +1 -1
  41. package/assets/components/assets/combobox/t9n/messages.uk.json +1 -1
  42. package/assets/components/assets/combobox/t9n/messages.vi.json +1 -1
  43. package/assets/components/assets/combobox/t9n/messages.zh-CN.json +1 -1
  44. package/assets/components/assets/combobox/t9n/messages.zh-HK.json +1 -1
  45. package/assets/components/assets/combobox/t9n/messages.zh-TW.json +1 -1
  46. package/assets/components/assets/date-picker/nls/fr-CA.json +1 -0
  47. package/assets/components/assets/icon/arcgisLivingAtlas16.json +1 -0
  48. package/assets/components/assets/icon/arcgisLivingAtlas24.json +1 -0
  49. package/assets/components/assets/icon/arcgisLivingAtlas32.json +1 -0
  50. package/assets/components/assets/icon/arcgisSolutions16.json +1 -0
  51. package/assets/components/assets/icon/arcgisSolutions24.json +1 -0
  52. package/assets/components/assets/icon/arcgisSolutions32.json +1 -0
  53. package/assets/components/assets/icon/cameraSensorMap24.json +1 -1
  54. package/assets/components/assets/icon/contingentValuesRetire16.json +1 -0
  55. package/assets/components/assets/icon/contingentValuesRetire24.json +1 -0
  56. package/assets/components/assets/icon/contingentValuesRetire32.json +1 -0
  57. package/assets/components/assets/icon/domain16.json +1 -1
  58. package/assets/components/assets/icon/domain24.json +1 -1
  59. package/assets/components/assets/icon/domain32.json +1 -1
  60. package/assets/components/assets/icon/duplicateValues16.json +1 -0
  61. package/assets/components/assets/icon/duplicateValues24.json +1 -0
  62. package/assets/components/assets/icon/duplicateValues32.json +1 -0
  63. package/assets/components/assets/icon/envelope32F.json +1 -1
  64. package/assets/components/assets/icon/fieldGroups16.json +1 -0
  65. package/assets/components/assets/icon/fieldGroups24.json +1 -0
  66. package/assets/components/assets/icon/fieldGroups32.json +1 -0
  67. package/assets/components/assets/icon/groupContent16.json +1 -0
  68. package/assets/components/assets/icon/groupContent24.json +1 -0
  69. package/assets/components/assets/icon/groupContent32.json +1 -0
  70. package/assets/components/assets/icon/groupTemplate16.json +1 -0
  71. package/assets/components/assets/icon/groupTemplate24.json +1 -0
  72. package/assets/components/assets/icon/groupTemplate32.json +1 -0
  73. package/assets/components/assets/icon/integerSet16.json +1 -0
  74. package/assets/components/assets/icon/integerSet24.json +1 -0
  75. package/assets/components/assets/icon/integerSet32.json +1 -0
  76. package/assets/components/assets/icon/intersection16.json +1 -1
  77. package/assets/components/assets/icon/lineIntersection16.json +1 -1
  78. package/assets/components/assets/icon/linkChartCentrality16.json +1 -1
  79. package/assets/components/assets/icon/locationReferencingDataset16.json +1 -1
  80. package/assets/components/assets/icon/locationReferencingDataset24.json +1 -1
  81. package/assets/components/assets/icon/locationReferencingDataset32.json +1 -1
  82. package/assets/components/assets/icon/metadata16.json +1 -0
  83. package/assets/components/assets/icon/metadata24.json +1 -0
  84. package/assets/components/assets/icon/metadata32.json +1 -0
  85. package/assets/components/assets/icon/missionSystemMessage16.json +1 -0
  86. package/assets/components/assets/icon/missionSystemMessage24.json +1 -0
  87. package/assets/components/assets/icon/missionSystemMessage32.json +1 -0
  88. package/assets/components/assets/icon/newCompletePart16.json +1 -1
  89. package/assets/components/assets/icon/newCompletePart24.json +1 -1
  90. package/assets/components/assets/icon/newCompletePart32.json +1 -1
  91. package/assets/components/assets/icon/numberSet16.json +1 -0
  92. package/assets/components/assets/icon/numberSet24.json +1 -0
  93. package/assets/components/assets/icon/numberSet32.json +1 -0
  94. package/assets/components/assets/icon/openData16.json +1 -0
  95. package/assets/components/assets/icon/openData24.json +1 -0
  96. package/assets/components/assets/icon/openData32.json +1 -0
  97. package/assets/components/assets/icon/organizeTemplate16.json +1 -0
  98. package/assets/components/assets/icon/organizeTemplate24.json +1 -0
  99. package/assets/components/assets/icon/organizeTemplate32.json +1 -0
  100. package/assets/components/assets/icon/partneredCollaboration16.json +1 -0
  101. package/assets/components/assets/icon/partneredCollaboration24.json +1 -0
  102. package/assets/components/assets/icon/partneredCollaboration32.json +1 -0
  103. package/assets/components/assets/icon/personMagnifyingGlass16.json +1 -1
  104. package/assets/components/assets/icon/personMagnifyingGlass24.json +1 -1
  105. package/assets/components/assets/icon/pieChartSectionHashFilled16.json +1 -1
  106. package/assets/components/assets/icon/relativeDirectionArrows16.json +1 -0
  107. package/assets/components/assets/icon/relativeDirectionArrows24.json +1 -0
  108. package/assets/components/assets/icon/relativeDirectionArrows32.json +1 -0
  109. package/assets/components/assets/icon/signalHealth16.json +1 -0
  110. package/assets/components/assets/icon/signalHealth24.json +1 -0
  111. package/assets/components/assets/icon/signalHealth32.json +1 -0
  112. package/assets/components/assets/icon/sortAscendingView16.json +1 -0
  113. package/assets/components/assets/icon/sortAscendingView24.json +1 -0
  114. package/assets/components/assets/icon/sortAscendingView32.json +1 -0
  115. package/assets/components/assets/icon/sortDescendingView16.json +1 -0
  116. package/assets/components/assets/icon/sortDescendingView24.json +1 -0
  117. package/assets/components/assets/icon/sortDescendingView32.json +1 -0
  118. package/assets/components/assets/icon/starValues16.json +1 -0
  119. package/assets/components/assets/icon/starValues24.json +1 -0
  120. package/assets/components/assets/icon/starValues32.json +1 -0
  121. package/assets/components/assets/icon/updateTable16.json +1 -0
  122. package/assets/components/assets/icon/updateTable24.json +1 -0
  123. package/assets/components/assets/icon/updateTable32.json +1 -0
  124. package/assets/esri/core/workers/RemoteClient.js +1 -1
  125. package/assets/esri/core/workers/chunks/{94929cf2b9fc66a93882.js → 02cf735176f286a48dd2.js} +1 -1
  126. package/assets/esri/core/workers/chunks/{f3437ae6bba846b524d3.js → 095c1b88cdcb91ab837e.js} +1 -1
  127. package/assets/esri/core/workers/chunks/{b7f2fb6684cf684b0bce.js → 0dc3a04ce717b7ddd957.js} +1 -1
  128. package/assets/esri/core/workers/chunks/{297344c2c1119159d143.js → 10373885604655f673df.js} +1 -1
  129. package/assets/esri/core/workers/chunks/{8208c073e606973ea1ad.js → 12f700b932a241e59071.js} +1 -1
  130. package/assets/esri/core/workers/chunks/{1e8ceed33a3657ac02b3.js → 153ff2ceefccd946498b.js} +1 -1
  131. package/assets/esri/core/workers/chunks/{ca761dc5f45cafef313e.js → 17dea03fc4eb414f0022.js} +1 -1
  132. package/assets/esri/core/workers/chunks/1800994523d7cdfb73af.js +1 -0
  133. package/assets/esri/core/workers/chunks/{ec5f83aa752c39a96609.js → 19db60a3b4b09d445bd1.js} +1 -1
  134. package/assets/esri/core/workers/chunks/{7147fc7502b385b302b2.js → 23b623637126f8411a30.js} +1 -1
  135. package/assets/esri/core/workers/chunks/{a7aa87e2c4197ba595ef.js → 2abc205f81f26fc4852b.js} +2 -2
  136. package/assets/esri/core/workers/chunks/37002a46f03a9fc5f644.js +2 -0
  137. package/assets/esri/core/workers/chunks/{78fc9a55e620602db1ff.js.LICENSE.txt → 37002a46f03a9fc5f644.js.LICENSE.txt} +1 -1
  138. package/assets/esri/core/workers/chunks/{b4a59dd11d75df7bd510.js → 3cce8e894bf37c3e598e.js} +1 -1
  139. package/assets/esri/core/workers/chunks/{492d575894c7905bb70c.js → 3d49c6427120edc8eac9.js} +1 -1
  140. package/assets/esri/core/workers/chunks/{23a9dd9454d5249bbd59.js → 3da53c017f9c5d2d778a.js} +1 -1
  141. package/assets/esri/core/workers/chunks/43e2c1d72cd9c8beed2f.js +2 -0
  142. package/assets/esri/core/workers/chunks/{3266c3392c24ce6cdd83.js.LICENSE.txt → 43e2c1d72cd9c8beed2f.js.LICENSE.txt} +1 -1
  143. package/assets/esri/core/workers/chunks/{3d1a5a3467f3a6585b3e.js → 4f03d19a70dca6c507be.js} +1 -1
  144. package/assets/esri/core/workers/chunks/{24c35a46cf8ed11b774d.js → 5180b15f1a865756a02e.js} +1 -1
  145. package/assets/esri/core/workers/chunks/57302b92e9899cce4ba3.js +1 -0
  146. package/assets/esri/core/workers/chunks/5909a0e763fddc3542e7.js +2 -0
  147. package/assets/esri/core/workers/chunks/{6f3ffc04086bca30e55d.js.LICENSE.txt → 5909a0e763fddc3542e7.js.LICENSE.txt} +2 -2
  148. package/assets/esri/core/workers/chunks/{d9736c783513e9c9b22f.js → 5a2933ae19345b7d5aa7.js} +1 -1
  149. package/assets/esri/core/workers/chunks/{5d31fbabaa875f8627c0.js → 631a11a2b2001c708527.js} +1 -1
  150. package/assets/esri/core/workers/chunks/{fa95c9248fbfab338f2e.js → 63b8cd7d5cafbaeed894.js} +1 -1
  151. package/assets/esri/core/workers/chunks/6b4a24248182245167ca.js +1 -0
  152. package/assets/esri/core/workers/chunks/6be530ab81291745485b.js +2 -0
  153. package/assets/esri/core/workers/chunks/{70e2804d3710c6af468e.js.LICENSE.txt → 6be530ab81291745485b.js.LICENSE.txt} +1 -1
  154. package/assets/esri/core/workers/chunks/{ef9a23d41acb5ad36426.js → 6cb44cd319cb6c2539c8.js} +1 -1
  155. package/assets/esri/core/workers/chunks/73c416ae0ec5a1815591.js +2 -0
  156. package/assets/esri/core/workers/chunks/{be631029691d9a320cb5.js.LICENSE.txt → 73c416ae0ec5a1815591.js.LICENSE.txt} +1 -7
  157. package/assets/esri/core/workers/chunks/{352c674730c7b7258ae3.js → 76086517591d0eb35156.js} +1 -1
  158. package/assets/esri/core/workers/chunks/{436f206898306df019ac.js → 7c47fefbf4c93b63200f.js} +1 -1
  159. package/assets/esri/core/workers/chunks/7e8573749a02e1f54fb1.js +1 -0
  160. package/assets/esri/core/workers/chunks/{9ff8ee6ed6b98c03ae7e.js → 9ccabf8142fb5de4d3e2.js} +2 -2
  161. package/assets/esri/core/workers/chunks/{9ff8ee6ed6b98c03ae7e.js.LICENSE.txt → 9ccabf8142fb5de4d3e2.js.LICENSE.txt} +1 -1
  162. package/assets/esri/core/workers/chunks/ab71865b94022e78035c.js +1 -0
  163. package/assets/esri/core/workers/chunks/{424daef7b5dec1b99aba.js → af3e93a4ac3ff2addc90.js} +1 -1
  164. package/assets/esri/core/workers/chunks/{bf82bb1cdd8b31e7f2aa.js → bb08359610a41e304b55.js} +1 -1
  165. package/assets/esri/core/workers/chunks/{495b11fdecc3ba90d454.js → bfc063d4431bfa162160.js} +1 -1
  166. package/assets/esri/core/workers/chunks/c2aeecd27e004c6cd7e1.js +2 -0
  167. package/assets/esri/core/workers/chunks/c2aeecd27e004c6cd7e1.js.LICENSE.txt +9 -0
  168. package/assets/esri/core/workers/chunks/{60362c5651ef41fa7e5f.js → c2bab829d6f6e05bbd81.js} +1 -1
  169. package/assets/esri/core/workers/chunks/{fa0bbf0d7eadb924c473.js → cc50f96321a7c12f300b.js} +1 -1
  170. package/assets/esri/core/workers/chunks/{62752cd6821959cf6751.js → cfbe9993263fa6f69363.js} +1 -1
  171. package/assets/esri/core/workers/chunks/cfe1506a443fc84a0b91.js +1 -0
  172. package/assets/esri/core/workers/chunks/d13b2ce8a89938b0472b.js +1 -0
  173. package/assets/esri/core/workers/chunks/da99fd0d3106dd357743.js +1 -0
  174. package/assets/esri/core/workers/chunks/{2d8dca9a4a58469ddd05.js → e705d041f6c1632bfbcc.js} +1 -1
  175. package/assets/esri/core/workers/chunks/{0483a2cfdb8c7158e73a.js → e85da52d9cc7d9396872.js} +1 -1
  176. package/assets/esri/core/workers/chunks/e95821a199e10b389e29.js +2 -0
  177. package/assets/esri/core/workers/chunks/{69278d08a7d64917f826.js.LICENSE.txt → e95821a199e10b389e29.js.LICENSE.txt} +1 -1
  178. package/assets/esri/core/workers/chunks/f25bebd2b6eb0d0f6626.js +2 -0
  179. package/assets/esri/core/workers/chunks/{d9251c3c85c3ddd242c8.js.LICENSE.txt → f25bebd2b6eb0d0f6626.js.LICENSE.txt} +1 -1
  180. package/assets/esri/core/workers/chunks/f32d4813b450a3eb4262.js +1 -0
  181. package/assets/esri/core/workers/chunks/{1ced78750c61600b2d4e.js → f351007cdcd0938d3b6c.js} +1 -1
  182. package/assets/esri/core/workers/chunks/{4b088260252787734c00.js → f5f584d325f8f2ea825f.js} +1 -1
  183. package/assets/esri/core/workers/chunks/{3405a23973f9e701a4d6.js → f7d93aae350796b88562.js} +1 -1
  184. package/assets/esri/core/workers/chunks/f9bddbf5dbc91897cb04.js +1 -0
  185. package/assets/esri/libs/parquet/pkg/bundle_bg.wasm +0 -0
  186. package/assets/esri/themes/base/_core.scss +1 -1
  187. package/assets/esri/themes/base/widgets/_BuildingPhasePicker.scss +1 -3
  188. package/assets/esri/themes/base/widgets/_FeatureTable.scss +4 -4
  189. package/assets/esri/themes/base/widgets/_Grid.scss +6 -5
  190. package/assets/esri/themes/base/widgets/_Sketch.scss +0 -3
  191. package/assets/esri/themes/base/widgets/_Tooltip.scss +6 -6
  192. package/assets/esri/themes/dark/main.css +1 -1
  193. package/assets/esri/themes/light/main.css +1 -1
  194. package/assets/esri/themes/light/view.css +1 -1
  195. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_ar.json +1 -1
  196. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_bg.json +1 -1
  197. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_bs.json +1 -1
  198. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_ca.json +1 -1
  199. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_cs.json +1 -1
  200. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_da.json +1 -1
  201. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_de.json +1 -1
  202. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_el.json +1 -1
  203. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_es.json +1 -1
  204. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_et.json +1 -1
  205. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_fi.json +1 -1
  206. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_fr.json +1 -1
  207. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_he.json +1 -1
  208. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_hr.json +1 -1
  209. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_hu.json +1 -1
  210. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_id.json +1 -1
  211. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_it.json +1 -1
  212. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_ja.json +1 -1
  213. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_ko.json +1 -1
  214. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_lt.json +1 -1
  215. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_lv.json +1 -1
  216. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_nl.json +1 -1
  217. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_no.json +1 -1
  218. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_pl.json +1 -1
  219. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_pt-BR.json +1 -1
  220. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_pt-PT.json +1 -1
  221. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_ro.json +1 -1
  222. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_ru.json +1 -1
  223. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_sk.json +1 -1
  224. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_sl.json +1 -1
  225. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_sr.json +1 -1
  226. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_sv.json +1 -1
  227. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_th.json +1 -1
  228. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_tr.json +1 -1
  229. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_uk.json +1 -1
  230. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_vi.json +1 -1
  231. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_zh-CN.json +1 -1
  232. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_zh-HK.json +1 -1
  233. package/assets/esri/widgets/UtilityNetworkValidateTopology/t9n/UtilityNetworkValidateTopology_zh-TW.json +1 -1
  234. package/chunks/CutFillDepth.glsl.js +13 -10
  235. package/chunks/CutFillReduction.glsl.js +14 -8
  236. package/chunks/GaussianSplat.glsl.js +1 -1
  237. package/chunks/Laserlines.glsl.js +2 -2
  238. package/chunks/boundedPlane.js +1 -1
  239. package/chunks/cameraUtilsSpherical.js +1 -1
  240. package/chunks/vec32.js +1 -1
  241. package/config.js +1 -1
  242. package/core/Loadable.d.ts +8 -2
  243. package/core/libs/gl-matrix-2/math/vec3.js +1 -1
  244. package/core/reactiveUtils.d.ts +1 -1
  245. package/effects/FocusAreas.d.ts +1 -1
  246. package/form/FormTemplate.d.ts +2 -2
  247. package/form/elements/AttachmentElement.d.ts +2 -2
  248. package/form/elements/GroupElement.d.ts +2 -2
  249. package/form/elements/inputs/attachments/AttachmentInput.d.ts +9 -2
  250. package/form/elements/inputs/attachments/AudioInput.d.ts +10 -1
  251. package/form/elements/inputs/attachments/DocumentInput.d.ts +9 -1
  252. package/form/elements/inputs/attachments/ImageInput.d.ts +10 -1
  253. package/form/elements/inputs/attachments/Input.d.ts +19 -1
  254. package/form/elements/inputs/attachments/SignatureInput.d.ts +5 -0
  255. package/form/elements/inputs/attachments/VideoInput.d.ts +10 -1
  256. package/form/elements/inputs/attachments/types.d.ts +15 -0
  257. package/form/elements.d.ts +0 -9
  258. package/form/types.d.ts +17 -0
  259. package/geometry/support/lineSegment.js +1 -1
  260. package/geometry/support/meshUtils/merge.js +1 -1
  261. package/geometry/support/sphere.js +1 -1
  262. package/interfaces.d.ts +74 -212
  263. package/intl/substitute.d.ts +1 -1
  264. package/intl.d.ts +5 -5
  265. package/kernel.js +1 -1
  266. package/layers/VoxelWasmPerSceneView.js +1 -1
  267. package/layers/catalog/CatalogFootprintLayer.d.ts +1 -1
  268. package/layers/knowledgeGraph/layerUtils.js +1 -1
  269. package/layers/ogc/types.d.ts +1 -1
  270. package/layers/orientedImagery/transformations/worldToImage.js +1 -1
  271. package/layers/support/FieldsIndex.d.ts +2 -1
  272. package/layers/support/RouteStopSymbols.d.ts +1 -1
  273. package/layers/support/RouteSymbols.d.ts +1 -1
  274. package/layers/support/tiles3DUtils.js +1 -1
  275. package/layers/voxel/VoxelVolume.js +1 -1
  276. package/networks/UtilityNetwork.js +1 -1
  277. package/networks/support/Circuit.d.ts +2 -2
  278. package/networks/support/CircuitLocation.d.ts +3 -3
  279. package/networks/support/CircuitLocation.js +1 -1
  280. package/networks/support/CircuitPathConnectivityElement.js +1 -1
  281. package/networks/support/CircuitSection.d.ts +2 -2
  282. package/networks/support/jsonTypes.d.ts +2 -2
  283. package/networks/support/networkFieldUtils.js +1 -1
  284. package/package.json +3 -3
  285. package/portal/PortalUser.d.ts +2 -2
  286. package/renderers/ClassBreaksRenderer.d.ts +2 -2
  287. package/renderers/SimpleRenderer.d.ts +1 -1
  288. package/renderers/UniqueValueRenderer.d.ts +1 -1
  289. package/renderers/support/ClassBreakInfo.d.ts +1 -1
  290. package/renderers/support/RendererLegendOptions.d.ts +2 -1
  291. package/renderers/support/UniqueValueClass.d.ts +1 -1
  292. package/renderers/support/UniqueValueInfo.d.ts +1 -1
  293. package/renderers/types.d.ts +1 -1
  294. package/rest/networks/circuits/alterCircuit.js +1 -1
  295. package/rest/networks/circuits/createCircuit.js +1 -1
  296. package/rest/networks/circuits/deleteCircuits.js +1 -1
  297. package/rest/networks/circuits/exportCircuits.js +1 -1
  298. package/rest/networks/circuits/queryCircuits.js +1 -1
  299. package/rest/networks/circuits/support/QueryCircuitsParameters.js +1 -1
  300. package/rest/networks/circuits/verifyCircuits.js +1 -1
  301. package/rest/networks/support/Association.js +1 -1
  302. package/rest/networks/support/TelecomNetworkElement.d.ts +6 -5
  303. package/rest/networks/support/TelecomNetworkElement.js +1 -1
  304. package/rest/networks/support/TraceLocation.d.ts +10 -8
  305. package/rest/networks/support/TraceLocation.js +1 -1
  306. package/rest/networks/support/TraceResult.js +1 -1
  307. package/rest/networks/unitIdentifiers/insertGap.js +1 -1
  308. package/rest/networks/unitIdentifiers/queryUnitIdentifiers.js +1 -1
  309. package/rest/networks/unitIdentifiers/reset.js +1 -1
  310. package/rest/networks/unitIdentifiers/resize.js +1 -1
  311. package/rest/networks/unitIdentifiers/support/UnitQueryResult.js +1 -1
  312. package/rest/places.d.ts +0 -4
  313. package/rest/support/AttributeBinsQuery.d.ts +1 -14
  314. package/rest/symbolService.d.ts +2 -2
  315. package/smartMapping/raster/renderers/vectorField.d.ts +0 -1
  316. package/smartMapping/renderers/opacity.d.ts +1 -1
  317. package/smartMapping/renderers/support/spikeUtils.d.ts +2 -2
  318. package/smartMapping/renderers/type.d.ts +1 -1
  319. package/smartMapping/renderers/univariateColorSize.d.ts +4 -4
  320. package/smartMapping/statistics/types.d.ts +2 -2
  321. package/support/actions/actionUtils.js +1 -1
  322. package/support/revision.js +1 -1
  323. package/symbols/CIMSymbol.d.ts +29 -29
  324. package/symbols/Font.d.ts +1 -1
  325. package/symbols/IconSymbol3DLayer.d.ts +3 -4
  326. package/symbols/ObjectSymbol3DLayer.d.ts +3 -4
  327. package/symbols/Symbol.d.ts +2 -5
  328. package/symbols/Symbol3DLayer.d.ts +2 -3
  329. package/symbols/TextSymbol.d.ts +3 -3
  330. package/symbols/TextSymbol3DLayer.d.ts +3 -3
  331. package/symbols/WaterSymbol3DLayer.d.ts +4 -7
  332. package/symbols/WebStyleSymbol.d.ts +5 -5
  333. package/symbols/cim/cimAnalyzer.js +1 -1
  334. package/symbols/cim/defaultCIMValues.js +1 -1
  335. package/symbols/cim/{CIMTypes.d.ts → types.d.ts} +216 -167
  336. package/symbols/cim/types.js +5 -0
  337. package/symbols/support/IconSymbol3DLayerResource.d.ts +2 -3
  338. package/symbols/support/ObjectSymbol3DLayerResource.d.ts +2 -3
  339. package/symbols/support/Symbol3DFillMaterial.d.ts +2 -2
  340. package/symbols/support/cimConversionUtils.d.ts +1 -1
  341. package/symbols/support/cimSymbolUtils.d.ts +4 -4
  342. package/symbols/support/jsonUtils.d.ts +1 -1
  343. package/symbols/support/symbolUtils.d.ts +66 -4
  344. package/symbols/support/types.d.ts +3 -62
  345. package/symbols/types.d.ts +113 -1
  346. package/unionTypes.d.ts +61 -14
  347. package/views/2d/engine/flow/dataUtils.js +1 -1
  348. package/views/2d/engine/flow/utils.js +1 -1
  349. package/views/2d/engine/vectorTiles/shaders/sources/shaderRepository.js +1 -1
  350. package/views/2d/engine/webgl/shaderGraph/techniques/fill/GradientFillMeshWriter.js +1 -1
  351. package/views/2d/engine/webgl/shaderGraph/techniques/fill/GradientSizeHelper.js +1 -1
  352. package/views/2d/engine/webgl/shaderGraph/techniques/line/GradientStrokeMeshWriter.js +1 -1
  353. package/views/2d/engine/webgl/shaders/sources/shaderRepository.js +1 -1
  354. package/views/2d/interactive/SegmentLabels2D.js +1 -1
  355. package/views/2d/layers/BaseLayerViewGL2D.d.ts +6 -6
  356. package/views/2d/layers/RouteLayerView2D.js +1 -1
  357. package/views/2d/layers/support/RouteLayerInteraction.js +1 -1
  358. package/views/2d/layers/support/RouteLayerInteractiveOptions.js +5 -0
  359. package/views/2d/layers/support/RouteLayerWaypointVisualization.js +1 -1
  360. package/views/3d/analysis/AreaMeasurement/support/AreaMeasurementVisualization.js +1 -1
  361. package/views/3d/analysis/AreaMeasurement/support/MeasurementData.js +1 -1
  362. package/views/3d/analysis/Dimension/lengthDimensionConstraintUtils.js +1 -1
  363. package/views/3d/analysis/Dimension/lengthDimensionUtils.js +1 -1
  364. package/views/3d/analysis/LineOfSight/LineOfSightController.js +1 -1
  365. package/views/3d/analysis/LineOfSight/LineOfSightIntersectionResult.js +1 -1
  366. package/views/3d/analysis/Slice/sliceToolUtils.js +1 -1
  367. package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillComputation.js +1 -1
  368. package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillController.js +1 -1
  369. package/views/3d/analysis/VolumeMeasurement/VolumeMeasurementCutFillVisualization.js +1 -1
  370. package/views/3d/analysis/VolumeMeasurementAnalysisView3D.js +1 -1
  371. package/views/3d/animation/pointToPoint/Camera.js +1 -1
  372. package/views/3d/camera/constraintUtils/distance.js +1 -1
  373. package/views/3d/camera/constraintUtils/tilt.js +1 -1
  374. package/views/3d/environment/ChapmanApproximation.glsl.js +1 -1
  375. package/views/3d/environment/CloudsParameters.js +1 -1
  376. package/views/3d/environment/EnvironmentManager.js +1 -1
  377. package/views/3d/environment/MarsAtmosphere.js +1 -1
  378. package/views/3d/interactive/SegmentLabels3D.js +1 -1
  379. package/views/3d/interactive/editingTools/manipulations/MoveZManipulation.js +1 -1
  380. package/views/3d/interactive/editingTools/media/MediaElementManipulator3D.js +1 -1
  381. package/views/3d/interactive/editingTools/reshape/edgeOffsetUtils.js +1 -1
  382. package/views/3d/interactive/visualElements/LabelVisualElement.js +1 -1
  383. package/views/3d/interactive/visualElements/RightAngleQuadVisualElement.js +1 -1
  384. package/views/3d/layers/FlowSubView3D.js +1 -1
  385. package/views/3d/layers/GaussianSplatLayerView3D.js +1 -1
  386. package/views/3d/layers/IntegratedMesh3DTilesLayerView3D.js +1 -1
  387. package/views/3d/layers/graphics/Graphics3DObjectSymbolLayer.js +1 -1
  388. package/views/3d/layers/graphics/objectResourceUtils.js +1 -1
  389. package/views/3d/layers/i3s/I3SViewportQueries.js +1 -1
  390. package/views/3d/layers/i3s/PointCloudRenderer.js +1 -1
  391. package/views/3d/layers/support/FeatureTileMeasurements3D.js +1 -1
  392. package/views/3d/layers/support/FeatureTileVisibility3D.js +1 -1
  393. package/views/3d/state/Frustum.js +1 -1
  394. package/views/3d/state/controllers/FovController.js +1 -1
  395. package/views/3d/state/controllers/GamepadKeyboardController.js +1 -1
  396. package/views/3d/state/controllers/momentum/ZoomPlanarMomentumController.js +1 -1
  397. package/views/3d/support/FrustumExtentIntersection.js +1 -1
  398. package/views/3d/support/cameraUtils.js +1 -1
  399. package/views/3d/support/engineContent/line.js +1 -1
  400. package/views/3d/support/flow/FlowWorker.js +1 -1
  401. package/views/3d/support/flow/StreamlineResources3D.js +1 -1
  402. package/views/3d/support/flow/constants.js +1 -1
  403. package/views/3d/support/flow/geometryUtils.js +1 -1
  404. package/views/3d/support/gaussianSplatting/GaussianSplatDataStore.js +1 -1
  405. package/views/3d/support/gaussianSplatting/GaussianSplatTextureAtlas.js +1 -1
  406. package/views/3d/support/intersectionUtils.js +1 -1
  407. package/views/3d/support/orientedBoundingBox.js +1 -1
  408. package/views/3d/support/pointsOfInterest/CameraOnSurface.js +1 -1
  409. package/views/3d/support/pointsOfInterest/CenterOnSurface.js +1 -1
  410. package/views/3d/support/pointsOfInterest/Focus.js +1 -1
  411. package/views/3d/support/viewpointUtils.js +1 -1
  412. package/views/3d/terrain/OverlayManager.js +1 -1
  413. package/views/3d/terrain/OverlayRenderer.js +1 -1
  414. package/views/3d/terrain/PatchRenderData.js +1 -1
  415. package/views/3d/terrain/SphericalPatch.js +1 -1
  416. package/views/3d/terrain/Tile.js +1 -1
  417. package/views/3d/webgl/RenderCamera.js +1 -1
  418. package/views/3d/webgl-engine/core/FBOCache.js +1 -1
  419. package/views/3d/webgl-engine/core/FBOCacheFormats.js +1 -1
  420. package/views/3d/webgl-engine/effects/focusArea/FocusAreaMaskNode.js +1 -1
  421. package/views/3d/webgl-engine/effects/geometry/RenderOccludedRenderNode.js +1 -1
  422. package/views/3d/webgl-engine/lib/CutFillDepth.js +1 -1
  423. package/views/3d/webgl-engine/lib/GPUPointOcclusionQuery.js +1 -1
  424. package/views/3d/webgl-engine/lib/GaussianSplatRenderNode.js +1 -1
  425. package/views/3d/webgl-engine/lib/MainFramebuffer.js +1 -1
  426. package/views/3d/webgl-engine/lib/Object3D.js +1 -1
  427. package/views/3d/webgl-engine/lib/Renderer.js +1 -1
  428. package/views/3d/webgl-engine/lib/ShadowAccumulator.js +1 -1
  429. package/views/3d/webgl-engine/lib/ShadowMap.js +1 -1
  430. package/views/3d/webgl-engine/lib/Viewshed.js +1 -1
  431. package/views/3d/webgl-engine/lib/ViewshedShadowMap.js +1 -1
  432. package/views/3d/webgl-engine/lib/edgeRendering/edgePreprocessing.js +1 -1
  433. package/views/3d/webgl-engine/lib/geometryDataUtils.js +1 -1
  434. package/views/3d/webgl-engine/lib/triangleIntersectionUtils.js +1 -1
  435. package/views/3d/webgl-engine/materials/HUDMaterial.js +1 -1
  436. package/views/3d/webgl-engine/materials/LineMarkerMaterial.js +1 -1
  437. package/views/3d/webgl-engine/materials/MeasurementArrowMaterial.js +1 -1
  438. package/views/3d/webgl-engine/materials/NativeLineMaterial.js +1 -1
  439. package/views/3d/webgl-engine/materials/RibbonLineMaterial.js +1 -1
  440. package/views/3d/webgl-engine/shaders/AnimatedLine.glsl.js +13 -12
  441. package/views/3d/webgl-engine/shaders/CutFillDepthTechniqueConfiguration.js +5 -0
  442. package/views/3d/webgl-engine/shaders/CutFillReductionTechniqueConfiguration.js +5 -0
  443. package/views/3d/webgl-engine/shaders/RibbonLineTechniqueConfiguration.js +1 -1
  444. package/views/3d/webgl-engine/shaders/SphereDepthInterpolate.glsl.js +1 -1
  445. package/views/interactive/GraphicManipulator.js +1 -1
  446. package/views/interactive/coordinateHelper.js +1 -1
  447. package/views/interactive/editGeometry/operations/OffsetEdgeVertex.js +1 -1
  448. package/views/interactive/sketch/constraints.js +1 -1
  449. package/views/interactive/snapping/featureSources/sceneLayerSource/SceneLayerSnappingSourceWorker.js +1 -1
  450. package/views/interactive/snapping/featureSources/sceneLayerSource/sceneLayerSnappingUtils.js +1 -1
  451. package/views/interactive/snapping/hints/LineSnappingHint.js +1 -1
  452. package/views/interactive/tooltip/tooltipCommonUtils.js +1 -1
  453. package/views/navigation/PanSphericalMomentumEstimator.js +1 -1
  454. package/views/support/Scheduler.js +1 -1
  455. package/views/support/euclideanAreaMeasurementUtils.js +1 -1
  456. package/views/support/euclideanLengthMeasurementUtils.js +1 -1
  457. package/views/support/geometry3dUtils.js +1 -1
  458. package/webdoc/widgets/FloorFilter.js +1 -1
  459. package/widgets/BasemapLayerList.js +1 -1
  460. package/widgets/BatchAttributeForm.js +1 -1
  461. package/widgets/Bookmarks.js +1 -1
  462. package/widgets/BuildingExplorer/BuildingLevelPicker/BuildingLevelPicker.js +1 -1
  463. package/widgets/BuildingExplorer/BuildingPhasePicker/BuildingPhasePicker.js +1 -1
  464. package/widgets/CatalogLayerList.js +1 -1
  465. package/widgets/Directions/DirectionsViewModel.js +1 -1
  466. package/widgets/Directions.js +1 -1
  467. package/widgets/Editor/components/FeatureList.js +1 -1
  468. package/widgets/Editor/components/PendingFeatureList.js +1 -1
  469. package/widgets/Editor/components/UpdateFeaturePanelContent.js +1 -1
  470. package/widgets/ElevationProfile/components/LegendItem.js +1 -1
  471. package/widgets/ElevationProfile/components/SettingsButton.js +1 -1
  472. package/widgets/ElevationProfile.js +1 -1
  473. package/widgets/Expand/ExpandViewModel.d.ts +1 -0
  474. package/widgets/Expand/ExpandViewModel.js +1 -1
  475. package/widgets/Expand.js +1 -1
  476. package/widgets/FeatureForm/FeatureFormUtilityNetworkAssociations/UtilityNetworkAssociationItemList.js +1 -1
  477. package/widgets/FeatureForm.js +1 -1
  478. package/widgets/FeatureTable/Grid/Column.js +1 -1
  479. package/widgets/FeatureTable/RelationshipColumn.js +1 -1
  480. package/widgets/FeatureTable.js +1 -1
  481. package/widgets/Features/FeaturesDrillIn.js +1 -1
  482. package/widgets/Features.js +1 -1
  483. package/widgets/FloorFilter/FloorFilterViewModel.js +1 -1
  484. package/widgets/LayerList/LayerListItem.js +1 -1
  485. package/widgets/LayerList.js +1 -1
  486. package/widgets/Legend/LegendViewModel.js +1 -1
  487. package/widgets/Print.js +1 -1
  488. package/widgets/Search/SearchSource.d.ts +1 -1
  489. package/widgets/Sketch/support/ResponsiveToolbar/OverflowGroup.js +1 -1
  490. package/widgets/Sketch/support/ResponsiveToolbar/SplitButton.js +1 -1
  491. package/widgets/Sketch/support/ResponsiveToolbar/responsiveToolbarUtils.js +1 -1
  492. package/widgets/Sketch/types.d.ts +1 -1
  493. package/widgets/Sketch.js +1 -1
  494. package/widgets/Slice.js +1 -1
  495. package/widgets/TableList/types.d.ts +2 -3
  496. package/widgets/TableList.d.ts +1 -1
  497. package/widgets/TableList.js +1 -1
  498. package/widgets/TimeZoneLabel.js +1 -1
  499. package/widgets/UtilityNetworkAssociations.js +1 -1
  500. package/widgets/UtilityNetworkTrace/UtilityNetworkTraceFeature.js +1 -1
  501. package/widgets/UtilityNetworkTrace/UtilityNetworkTraceFeaturesDrillIn.js +1 -1
  502. package/widgets/UtilityNetworkTrace.js +1 -1
  503. package/widgets/UtilityNetworkValidateTopology.js +1 -1
  504. package/widgets/ValuePicker/ValuePickerCombobox.js +1 -1
  505. package/widgets/support/GeolocationPositioning.js +1 -1
  506. package/widgets/support/SelectionList.js +1 -1
  507. package/widgets/support/iconUtils.js +1 -1
  508. package/widgets/types.d.ts +2 -2
  509. package/assets/components/assets/modal/t9n/messages.ar.json +0 -1
  510. package/assets/components/assets/modal/t9n/messages.bg.json +0 -1
  511. package/assets/components/assets/modal/t9n/messages.bs.json +0 -1
  512. package/assets/components/assets/modal/t9n/messages.ca.json +0 -1
  513. package/assets/components/assets/modal/t9n/messages.cs.json +0 -1
  514. package/assets/components/assets/modal/t9n/messages.da.json +0 -1
  515. package/assets/components/assets/modal/t9n/messages.de.json +0 -1
  516. package/assets/components/assets/modal/t9n/messages.el.json +0 -1
  517. package/assets/components/assets/modal/t9n/messages.en.json +0 -1
  518. package/assets/components/assets/modal/t9n/messages.es.json +0 -1
  519. package/assets/components/assets/modal/t9n/messages.et.json +0 -1
  520. package/assets/components/assets/modal/t9n/messages.fi.json +0 -1
  521. package/assets/components/assets/modal/t9n/messages.fr.json +0 -1
  522. package/assets/components/assets/modal/t9n/messages.he.json +0 -1
  523. package/assets/components/assets/modal/t9n/messages.hr.json +0 -1
  524. package/assets/components/assets/modal/t9n/messages.hu.json +0 -1
  525. package/assets/components/assets/modal/t9n/messages.id.json +0 -1
  526. package/assets/components/assets/modal/t9n/messages.it.json +0 -1
  527. package/assets/components/assets/modal/t9n/messages.ja.json +0 -1
  528. package/assets/components/assets/modal/t9n/messages.json +0 -1
  529. package/assets/components/assets/modal/t9n/messages.ko.json +0 -1
  530. package/assets/components/assets/modal/t9n/messages.lt.json +0 -1
  531. package/assets/components/assets/modal/t9n/messages.lv.json +0 -1
  532. package/assets/components/assets/modal/t9n/messages.nl.json +0 -1
  533. package/assets/components/assets/modal/t9n/messages.no.json +0 -1
  534. package/assets/components/assets/modal/t9n/messages.pl.json +0 -1
  535. package/assets/components/assets/modal/t9n/messages.pt-BR.json +0 -1
  536. package/assets/components/assets/modal/t9n/messages.pt-PT.json +0 -1
  537. package/assets/components/assets/modal/t9n/messages.ro.json +0 -1
  538. package/assets/components/assets/modal/t9n/messages.ru.json +0 -1
  539. package/assets/components/assets/modal/t9n/messages.sk.json +0 -1
  540. package/assets/components/assets/modal/t9n/messages.sl.json +0 -1
  541. package/assets/components/assets/modal/t9n/messages.sr.json +0 -1
  542. package/assets/components/assets/modal/t9n/messages.sv.json +0 -1
  543. package/assets/components/assets/modal/t9n/messages.th.json +0 -1
  544. package/assets/components/assets/modal/t9n/messages.tr.json +0 -1
  545. package/assets/components/assets/modal/t9n/messages.uk.json +0 -1
  546. package/assets/components/assets/modal/t9n/messages.vi.json +0 -1
  547. package/assets/components/assets/modal/t9n/messages.zh-CN.json +0 -1
  548. package/assets/components/assets/modal/t9n/messages.zh-HK.json +0 -1
  549. package/assets/components/assets/modal/t9n/messages.zh-TW.json +0 -1
  550. package/assets/components/assets/tip/t9n/messages.ar.json +0 -1
  551. package/assets/components/assets/tip/t9n/messages.bg.json +0 -1
  552. package/assets/components/assets/tip/t9n/messages.bs.json +0 -1
  553. package/assets/components/assets/tip/t9n/messages.ca.json +0 -1
  554. package/assets/components/assets/tip/t9n/messages.cs.json +0 -1
  555. package/assets/components/assets/tip/t9n/messages.da.json +0 -1
  556. package/assets/components/assets/tip/t9n/messages.de.json +0 -1
  557. package/assets/components/assets/tip/t9n/messages.el.json +0 -1
  558. package/assets/components/assets/tip/t9n/messages.en.json +0 -1
  559. package/assets/components/assets/tip/t9n/messages.es.json +0 -1
  560. package/assets/components/assets/tip/t9n/messages.et.json +0 -1
  561. package/assets/components/assets/tip/t9n/messages.fi.json +0 -1
  562. package/assets/components/assets/tip/t9n/messages.fr.json +0 -1
  563. package/assets/components/assets/tip/t9n/messages.he.json +0 -1
  564. package/assets/components/assets/tip/t9n/messages.hr.json +0 -1
  565. package/assets/components/assets/tip/t9n/messages.hu.json +0 -1
  566. package/assets/components/assets/tip/t9n/messages.id.json +0 -1
  567. package/assets/components/assets/tip/t9n/messages.it.json +0 -1
  568. package/assets/components/assets/tip/t9n/messages.ja.json +0 -1
  569. package/assets/components/assets/tip/t9n/messages.json +0 -1
  570. package/assets/components/assets/tip/t9n/messages.ko.json +0 -1
  571. package/assets/components/assets/tip/t9n/messages.lt.json +0 -1
  572. package/assets/components/assets/tip/t9n/messages.lv.json +0 -1
  573. package/assets/components/assets/tip/t9n/messages.nl.json +0 -1
  574. package/assets/components/assets/tip/t9n/messages.no.json +0 -1
  575. package/assets/components/assets/tip/t9n/messages.pl.json +0 -1
  576. package/assets/components/assets/tip/t9n/messages.pt-BR.json +0 -1
  577. package/assets/components/assets/tip/t9n/messages.pt-PT.json +0 -1
  578. package/assets/components/assets/tip/t9n/messages.ro.json +0 -1
  579. package/assets/components/assets/tip/t9n/messages.ru.json +0 -1
  580. package/assets/components/assets/tip/t9n/messages.sk.json +0 -1
  581. package/assets/components/assets/tip/t9n/messages.sl.json +0 -1
  582. package/assets/components/assets/tip/t9n/messages.sr.json +0 -1
  583. package/assets/components/assets/tip/t9n/messages.sv.json +0 -1
  584. package/assets/components/assets/tip/t9n/messages.th.json +0 -1
  585. package/assets/components/assets/tip/t9n/messages.tr.json +0 -1
  586. package/assets/components/assets/tip/t9n/messages.uk.json +0 -1
  587. package/assets/components/assets/tip/t9n/messages.vi.json +0 -1
  588. package/assets/components/assets/tip/t9n/messages.zh-CN.json +0 -1
  589. package/assets/components/assets/tip/t9n/messages.zh-HK.json +0 -1
  590. package/assets/components/assets/tip/t9n/messages.zh-TW.json +0 -1
  591. package/assets/components/assets/tip-manager/t9n/messages.ar.json +0 -1
  592. package/assets/components/assets/tip-manager/t9n/messages.bg.json +0 -1
  593. package/assets/components/assets/tip-manager/t9n/messages.bs.json +0 -1
  594. package/assets/components/assets/tip-manager/t9n/messages.ca.json +0 -1
  595. package/assets/components/assets/tip-manager/t9n/messages.cs.json +0 -1
  596. package/assets/components/assets/tip-manager/t9n/messages.da.json +0 -1
  597. package/assets/components/assets/tip-manager/t9n/messages.de.json +0 -1
  598. package/assets/components/assets/tip-manager/t9n/messages.el.json +0 -1
  599. package/assets/components/assets/tip-manager/t9n/messages.en.json +0 -1
  600. package/assets/components/assets/tip-manager/t9n/messages.es.json +0 -1
  601. package/assets/components/assets/tip-manager/t9n/messages.et.json +0 -1
  602. package/assets/components/assets/tip-manager/t9n/messages.fi.json +0 -1
  603. package/assets/components/assets/tip-manager/t9n/messages.fr.json +0 -1
  604. package/assets/components/assets/tip-manager/t9n/messages.he.json +0 -1
  605. package/assets/components/assets/tip-manager/t9n/messages.hr.json +0 -1
  606. package/assets/components/assets/tip-manager/t9n/messages.hu.json +0 -1
  607. package/assets/components/assets/tip-manager/t9n/messages.id.json +0 -1
  608. package/assets/components/assets/tip-manager/t9n/messages.it.json +0 -1
  609. package/assets/components/assets/tip-manager/t9n/messages.ja.json +0 -1
  610. package/assets/components/assets/tip-manager/t9n/messages.json +0 -1
  611. package/assets/components/assets/tip-manager/t9n/messages.ko.json +0 -1
  612. package/assets/components/assets/tip-manager/t9n/messages.lt.json +0 -1
  613. package/assets/components/assets/tip-manager/t9n/messages.lv.json +0 -1
  614. package/assets/components/assets/tip-manager/t9n/messages.nl.json +0 -1
  615. package/assets/components/assets/tip-manager/t9n/messages.no.json +0 -1
  616. package/assets/components/assets/tip-manager/t9n/messages.pl.json +0 -1
  617. package/assets/components/assets/tip-manager/t9n/messages.pt-BR.json +0 -1
  618. package/assets/components/assets/tip-manager/t9n/messages.pt-PT.json +0 -1
  619. package/assets/components/assets/tip-manager/t9n/messages.ro.json +0 -1
  620. package/assets/components/assets/tip-manager/t9n/messages.ru.json +0 -1
  621. package/assets/components/assets/tip-manager/t9n/messages.sk.json +0 -1
  622. package/assets/components/assets/tip-manager/t9n/messages.sl.json +0 -1
  623. package/assets/components/assets/tip-manager/t9n/messages.sr.json +0 -1
  624. package/assets/components/assets/tip-manager/t9n/messages.sv.json +0 -1
  625. package/assets/components/assets/tip-manager/t9n/messages.th.json +0 -1
  626. package/assets/components/assets/tip-manager/t9n/messages.tr.json +0 -1
  627. package/assets/components/assets/tip-manager/t9n/messages.uk.json +0 -1
  628. package/assets/components/assets/tip-manager/t9n/messages.vi.json +0 -1
  629. package/assets/components/assets/tip-manager/t9n/messages.zh-CN.json +0 -1
  630. package/assets/components/assets/tip-manager/t9n/messages.zh-HK.json +0 -1
  631. package/assets/components/assets/tip-manager/t9n/messages.zh-TW.json +0 -1
  632. package/assets/esri/core/workers/chunks/1e17ad6cdffa5016a3db.js +0 -1
  633. package/assets/esri/core/workers/chunks/211837df0edada4414c5.js +0 -1
  634. package/assets/esri/core/workers/chunks/21ebd234cf32ae52b3ea.js +0 -1
  635. package/assets/esri/core/workers/chunks/262c5794650853457acc.js +0 -1
  636. package/assets/esri/core/workers/chunks/3266c3392c24ce6cdd83.js +0 -2
  637. package/assets/esri/core/workers/chunks/509065a27bd07bd32475.js +0 -1
  638. package/assets/esri/core/workers/chunks/69278d08a7d64917f826.js +0 -2
  639. package/assets/esri/core/workers/chunks/6f3ffc04086bca30e55d.js +0 -2
  640. package/assets/esri/core/workers/chunks/70e2804d3710c6af468e.js +0 -2
  641. package/assets/esri/core/workers/chunks/78fc9a55e620602db1ff.js +0 -2
  642. package/assets/esri/core/workers/chunks/a67c3958d76d10c04fa6.js +0 -2
  643. package/assets/esri/core/workers/chunks/a67c3958d76d10c04fa6.js.LICENSE.txt +0 -3
  644. package/assets/esri/core/workers/chunks/a94dd0f5839b6e2bb2d2.js +0 -1
  645. package/assets/esri/core/workers/chunks/b7bcff9a64f41a0a0b6a.js +0 -1
  646. package/assets/esri/core/workers/chunks/be631029691d9a320cb5.js +0 -2
  647. package/assets/esri/core/workers/chunks/c7802c144959d60e774a.js +0 -1
  648. package/assets/esri/core/workers/chunks/d9251c3c85c3ddd242c8.js +0 -2
  649. package/assets/esri/core/workers/chunks/edd3cf415955309b4ca4.js +0 -1
  650. package/assets/esri/core/workers/chunks/fbd577f56529063ce491.js +0 -1
  651. package/form/elements/inputs/attachments/support/inputs.d.ts +0 -10
  652. package/form/support/formUtils.d.ts +0 -4
  653. package/symbols/cim/enums.d.ts +0 -50
  654. package/symbols/cim/enums.js +0 -5
  655. package/symbols/support/OccludedVisibility.d.ts +0 -2
  656. package/symbols/support/materialUtils.d.ts +0 -2
  657. package/symbols/support/textUtils.d.ts +0 -10
  658. package/symbols/support/typeUtils.d.ts +0 -86
  659. package/symbols/support/webStyleAcceptedFormats.d.ts +0 -2
  660. package/symbols.d.ts +0 -439
  661. package/symbols.js +0 -5
  662. /package/effects/{FocusAreaStyle.d.ts → types.d.ts} +0 -0
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{n as t,d as r,h as n,H as e,a as s,g as o,c as i,f as u,i as c,j as f,u as a}from"../../../../chunks/vec32.js";import{create as h,fromValues as l,freeze as m}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getReferenceEllipsoid as d}from"../../../../geometry/ellipsoidUtils.js";import{getSphericalPCPF as p}from"../../../../geometry/spatialReferenceEllipsoidUtils.js";import{projectBuffer as _}from"../../../../geometry/projection/projectBuffer.js";import{projectVec3Array as g}from"../../../../geometry/projection/projectVec3Array.js";import{fromValues as b,signedDistance as S}from"../../../../geometry/support/plane.js";import{Frustum as M}from"../../state/Frustum.js";class F{constructor(t,r){this._renderCoordsHelper=t,this.opaqueGround=r,this._cache=new Map,this._cameraForward=h(),this._cameraEye=h(),this._cameraFovY=55*Math.PI/180,this._frustumBoundingSphereCenter=h(),this._frustumBoundingSphereRadius=0,this._frustum=new M(t),this._renderSR=t.spatialReference;const n=p(this._renderSR);this._renderSREllipsoidRadius=d(n).radius}setup(n){this._aboveGround=n.aboveGround,this._frustum.update(n),t(this._cameraForward,n.viewForward),r(this._cameraEye,n.eye),this._cameraFovY=n.fovY,this._updateFrustumBoundingSphere()}done(){this._cache.clear()}compute(t){if(this._cache.has(t.id))return this._cache.get(t.id);const r=this._isVisibleInFrustum(t);return this._cache.set(t.id,r),r}_isVisibleInFrustum(t){return 2===this._renderCoordsHelper.viewingMode?this._isTileVisibleInFrustumLocal(t):this._isTileVisibleInFrustumGlobal(t)}_updateFrustumBoundingSphere(){const t=this._frustum.boundingSphere;r(this._frustumBoundingSphereCenter,t.center),this._frustumBoundingSphereRadius=t.radius+Bt}_isTileVisibleInFrustumLocal(t){const r=t.spatialReference,u=t.extent,c=this._renderSR;if(!u)return!0;if(C[0]=u[0],C[1]=u[1],C[2]=0,C[3]=u[2],C[4]=u[3],C[5]=0,!_(C,r,0,C,c,0))return!1;n(E[0],C[0],C[1],0),n(E[1],C[3],C[1],0),n(E[2],C[3],C[4],0),n(E[3],C[0],C[4],0),n(k,.5*(C[0]+C[3]),.5*(C[1]+C[4]),.5*(C[2]+C[5]));const f=St,a=.5*e(E[0],E[2]),h=this._frustum,l=this._frustumBoundingSphereRadius,m=this._frustumBoundingSphereCenter,d=W;s(d,m,k);const p=o(f,d),g=A;i(g,k,f,p);if(e(g,m)>a+l)return!1;const b=this._cameraForward,S=o(b,St),M=this._cameraFovY,F=this._cameraEye;if(Math.abs(S)<Math.abs(Math.cos(.5*M))){let t=!0;const r=n(Mt,b[0],b[1],0),e=o(F,r);for(let n=0;n<4;++n){const s=E[n];if(o(s,r)-e>0){t=!1;break}}if(t)return!1}{const t=E[0],r=E[2];if(t[0]<=F[0]&&F[0]<=r[0]&&t[1]<=F[1]&&F[1]<=r[1])return!0}const R=x,v=this.opaqueGround&&this._aboveGround,j=this.opaqueGround&&!this._aboveGround,G=Math.min(j?pt:1/0,p+l),B=Math.max(v?-pt:-1/0,p-l);for(let n=0;n<4;++n)i(R[n],E[n],f,G),i(R[n+4],E[n],f,B);if(y(h.planes,R,8))return!1;if(q(h.planes,R,8))return!0;for(let n=0;n<4;++n){const t=R[n],r=R[n+4];if(Ft(h.planes,t,r))return!0;const e=R[(n+1)%4];if(Ft(h.planes,t,e))return!0;const s=R[4+(n+1)%4];if(Ft(h.planes,r,s))return!0}if(jt[0][3]=+E[0][0],jt[1][3]=-E[2][0],jt[2][3]=+E[0][1],jt[3][3]=-E[2][1],jt[4][3]=+B,jt[5][3]=-G,q(jt,h.points))return!0;if(q(jt,h.points))return!0;for(let n=0;n<4;++n){const t=F,r=h.points[n+4];if(Rt(jt,t,r))return!0;const e=h.points[4+(n+1)%4];if(Rt(jt,r,e))return!0}return!1}_isTileVisibleInFrustumGlobal(r){if(r.level<w)return!0;const l=r.spatialReference,m=r.extent;if(!m||!l)return!0;const d=this.opaqueGround&&this._aboveGround,p=this.opaqueGround&&!this._aboveGround,_=E,b=.5*(m[0]+m[2]);if(n(_[0],m[0],m[1],0),n(_[1],m[2],m[1],0),n(_[2],m[2],m[3],0),n(_[3],m[0],m[3],0),n(_[4],b,m[1],0),n(_[5],b,m[3],0),!g(_,l,0,_,this._renderSR,0,6))return!1;const M=_[0][2]>0,F=_[3][2]<0,G=M||F,B=this._renderSREllipsoidRadius;if(G){const t=T;R(t,Gt,_[0]);const r=Y;if(R(r,Gt,_[1]),M){const n=P,e=_[4],s=H;R(s,e,Gt),R(n,s,e);const o=_[0];u(o,t,n),j(o,B);const i=_[1];u(i,r,n),j(i,B)}else if(F){const n=P,e=_[5],s=H;R(s,e,Gt),R(n,e,s);const o=_[3];u(o,n,t),j(o,B);const i=_[2];u(i,n,r),j(i,B)}}const q=k,I=s(N,_[3],_[0]);t(I,I);const x=c(O,_[0],_[3]);f(x,x,.5);const C=-o(x,I),A=c(Q,_[0],_[1]);f(A,A,.5);const W=c(X,_[2],_[3]);f(W,W,.5);const et=s(Z,W,A);t(et,et);const ht=-(C+o(I,A))/o(I,et);i(q,A,et,ht),j(q,B);const lt=this._frustumBoundingSphereRadius,mt=this._frustumBoundingSphereCenter,St=this._frustum,Mt=St.planes,Ft=L;t(Ft,q);const Rt=o(_[0],Ft)/a(_[0]),vt=St.origin,jt=St.points;let Bt=!1;if(d){{Bt=!0;const r=t(_t,vt);for(let n=0;n<4;++n){const e=jt[4+n],i=s(h(),e,vt);t(i,i);const c=u(h(),r,i);t(c,c);const f=u(h(),i,c);t(f,f);if(o(vt,f)>B){Bt=!1;break}}}if(Bt){if(o(vt,Ft)<B*Rt-pt)return!1}const r=t(_t,St.origin);if(o(r,Ft)<0)return!1;{const r=t(gt,St.direction);if(o(r,Ft)>bt)return!1}}const yt=Math.sqrt(1-Rt*Rt);if(yt>.9)return!0;let qt=!1;const wt=o(Ft,mt),It=a(mt);if(It<=lt&&!Mt.some(t=>S(t,z)>0)){if(!d)return!0;qt=!0}const Vt=wt/It;if(!qt&&wt<=0){if(-wt>lt)return!1}const xt=lt/It;if(Math.sqrt(1-Vt*Vt)*Math.sqrt(1-xt*xt)-xt*Vt>yt)return!1;if(!Bt){if(_.some(t=>St.intersectsPoint(t)))return!0;if(St.intersectsPoint(q))return!0}const Ct=D;s(Ct,mt,z);const Et=o(Ct,Ft),kt=U;f(kt,Ft,Et);const Pt=e(kt,mt),Tt=l.isWGS84,Yt=r.lij,Ht=Tt&&Yt[2]===2**Yt[0]-1,Lt=Tt&&0===Yt[2],Ut=Lt?ct:Ht?it:st,At=Lt?ft:Ht?ut:ot;if(!qt){const t=_,r=at,n=$,e=tt,s=z;for(const o of Ut){const i=t[o];if(v(n,t[(o+1)%4],i),v(e,s,i),R(r,e,n),V(r,jt,1))return!1}}let Wt=null;if(!d&&Et<1.01*lt){const t=2.5*lt;if(Pt>Rt*t+lt)return!1;const r=K,e=t/Rt;for(let n=0;n<4;++n)f(r[n],_[n],e/B);n(r[4],0,0,0),Wt=r}else{const t=(p?B+pt:Et+lt)/Rt,r=d?B-pt:(Et-lt)/Rt,n=J;for(let e=0;e<4;++e){const s=_[e];f(n[e],s,r/B),f(n[e+4],s,t/B)}Wt=n}if(y(Mt,Wt,Wt.length))return!1;const zt=St.lines,Dt=rt,Jt=nt;for(const n of zt){t(Jt,n.direction);for(const r of At){const n=Wt[r];if(t(Dt,n),dt(Jt,Dt,Wt,jt))return!1;const e=(r+1)%4;if(d){const r=Wt[e];if(s(Dt,r,n),t(Dt,Dt),dt(Jt,Dt,Wt,jt))return!1}if(p){const n=Wt[4+r],o=Wt[4+e];if(s(Dt,o,n),t(Dt,Dt),dt(Jt,Dt,Wt,jt))return!1}}}return!0}}function R(r,n,e){return u(r,n,e),t(r,r),r}function v(r,n,e){return s(r,n,e),t(r,r),r}function j(t,r){return f(t,t,r/a(t)),t}const G=[0,1,2,3,5];function B(t,r,n){for(let e=0;e<n;++e)if(S(t,r[e])<=0)return!1;return!0}function y(t,r,n){for(const e of G)if(B(t[e],r,n))return!0;return!1}function q(t,r,n=r.length){for(let e=0;e<n;++e){const n=r[e];let s=!0;for(const r of t){if(S(r,n)>0){s=!1;break}}if(s)return!0}return!1}const w=2,I=4;function V(t,r,n){for(const e of r)if(o(e,t)<n)return!1;return!0}const x=[h(),h(),h(),h(),h(),h(),h(),h()],C=[0,0,0,0,0,0],E=[h(),h(),h(),h(),h(),h()],k=h(),P=h(),T=h(),Y=h(),H=h(),L=h(),U=h(),A=h(),W=h(),z=m(0,0,0),D=h(),J=[h(),h(),h(),h(),h(),h(),h(),h()],K=[h(),h(),h(),h(),h()],N=h(),O=h(),Q=h(),X=h(),Z=h(),$=h(),tt=h(),rt=h(),nt=h(),et=h(),st=[0,1,2,3],ot=[0,1,2,3],it=[0,1,3],ut=[0,1,3],ct=[1,2,3],ft=[1,2,3],at=h();function ht(t,r,n){let e=1/0,s=-1/0;for(const i of n){const t=o(r,i);e=Math.min(e,t),s=Math.max(s,t)}t[0]=e,t[1]=s}function lt(t,r,n,e){let s=1/0,i=-1/0;for(const u of e){const e=o(n,u);if(s=Math.min(s,e),i=Math.max(i,e),s<=r&&i>=t)return!1}return!0}const mt=[0,0];function dt(t,r,n,e){const s=n.length,o=e.length;if(0===s||0===o)return!0;const i=et;R(i,t,r);const u=o<s,c=u?n:e,f=mt;return ht(f,i,u?e:n),lt(f[0],f[1],i,c)}const pt=430,_t=h(),gt=h(),bt=Math.cos(.25*Math.PI),St=l(0,0,1),Mt=h();function Ft(t,r,n){const e={t0:0,t1:1};for(const s of G){if(!vt(t[s],r,n,e))return!1}return e.t0<e.t1}function Rt(t,r,n){const e={t0:0,t1:1};for(const s of t){if(!vt(s,r,n,e))return!1}return e.t0<e.t1}function vt(t,r,n,e){let{t0:s,t1:o}=e;const i=S(t,r),u=S(t,n);if(i>=0&&u>=0)return!1;if(i<0&&u>=0){const t=-i/(u-i);if(t<s)return!1;t<o&&(o=t)}else if(i>=0&&u<0){const t=i/(i-u);if(t>o)return!1;t>s&&(s=t)}return e.t0=s,e.t1=o,!0}const jt=[b(-1,0,0,1),b(1,0,0,-1),b(0,-1,0,1),b(0,1,0,-1),b(0,0,-1,1),b(0,0,1,-1)],Gt=m(0,0,1),Bt=1;export{F as FeatureTileVisibility3D,q as isAnyVertexInPolyhedron,y as isConvexHullOutsideOfFrustum,I as maxLODLevelDelta,w as minTileLOD};
5
+ import{n as t,d as r,h as n,F as e,a as s,g as o,c as i,f as u,i as c,j as f,u as a}from"../../../../chunks/vec32.js";import{create as h,fromValues as l,freeze as m}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getReferenceEllipsoid as d}from"../../../../geometry/ellipsoidUtils.js";import{getSphericalPCPF as p}from"../../../../geometry/spatialReferenceEllipsoidUtils.js";import{projectBuffer as _}from"../../../../geometry/projection/projectBuffer.js";import{projectVec3Array as g}from"../../../../geometry/projection/projectVec3Array.js";import{fromValues as b,signedDistance as S}from"../../../../geometry/support/plane.js";import{Frustum as F}from"../../state/Frustum.js";class M{constructor(t,r){this._renderCoordsHelper=t,this.opaqueGround=r,this._cache=new Map,this._cameraForward=h(),this._cameraEye=h(),this._cameraFovY=55*Math.PI/180,this._frustumBoundingSphereCenter=h(),this._frustumBoundingSphereRadius=0,this._frustum=new F(t),this._renderSR=t.spatialReference;const n=p(this._renderSR);this._renderSREllipsoidRadius=d(n).radius}setup(n){this._aboveGround=n.aboveGround,this._frustum.update(n),t(this._cameraForward,n.viewForward),r(this._cameraEye,n.eye),this._cameraFovY=n.fovY,this._updateFrustumBoundingSphere()}done(){this._cache.clear()}compute(t){if(this._cache.has(t.id))return this._cache.get(t.id);const r=this._isVisibleInFrustum(t);return this._cache.set(t.id,r),r}_isVisibleInFrustum(t){return 2===this._renderCoordsHelper.viewingMode?this._isTileVisibleInFrustumLocal(t):this._isTileVisibleInFrustumGlobal(t)}_updateFrustumBoundingSphere(){const t=this._frustum.boundingSphere;r(this._frustumBoundingSphereCenter,t.center),this._frustumBoundingSphereRadius=t.radius+Bt}_isTileVisibleInFrustumLocal(t){const r=t.spatialReference,u=t.extent,c=this._renderSR;if(!u)return!0;if(C[0]=u[0],C[1]=u[1],C[2]=0,C[3]=u[2],C[4]=u[3],C[5]=0,!_(C,r,0,C,c,0))return!1;n(E[0],C[0],C[1],0),n(E[1],C[3],C[1],0),n(E[2],C[3],C[4],0),n(E[3],C[0],C[4],0),n(k,.5*(C[0]+C[3]),.5*(C[1]+C[4]),.5*(C[2]+C[5]));const f=St,a=.5*e(E[0],E[2]),h=this._frustum,l=this._frustumBoundingSphereRadius,m=this._frustumBoundingSphereCenter,d=W;s(d,m,k);const p=o(f,d),g=A;i(g,k,f,p);if(e(g,m)>a+l)return!1;const b=this._cameraForward,S=o(b,St),F=this._cameraFovY,M=this._cameraEye;if(Math.abs(S)<Math.abs(Math.cos(.5*F))){let t=!0;const r=n(Ft,b[0],b[1],0),e=o(M,r);for(let n=0;n<4;++n){const s=E[n];if(o(s,r)-e>0){t=!1;break}}if(t)return!1}{const t=E[0],r=E[2];if(t[0]<=M[0]&&M[0]<=r[0]&&t[1]<=M[1]&&M[1]<=r[1])return!0}const R=x,v=this.opaqueGround&&this._aboveGround,j=this.opaqueGround&&!this._aboveGround,G=Math.min(j?pt:1/0,p+l),B=Math.max(v?-pt:-1/0,p-l);for(let n=0;n<4;++n)i(R[n],E[n],f,G),i(R[n+4],E[n],f,B);if(y(h.planes,R,8))return!1;if(q(h.planes,R,8))return!0;for(let n=0;n<4;++n){const t=R[n],r=R[n+4];if(Mt(h.planes,t,r))return!0;const e=R[(n+1)%4];if(Mt(h.planes,t,e))return!0;const s=R[4+(n+1)%4];if(Mt(h.planes,r,s))return!0}if(jt[0][3]=+E[0][0],jt[1][3]=-E[2][0],jt[2][3]=+E[0][1],jt[3][3]=-E[2][1],jt[4][3]=+B,jt[5][3]=-G,q(jt,h.points))return!0;if(q(jt,h.points))return!0;for(let n=0;n<4;++n){const t=M,r=h.points[n+4];if(Rt(jt,t,r))return!0;const e=h.points[4+(n+1)%4];if(Rt(jt,r,e))return!0}return!1}_isTileVisibleInFrustumGlobal(r){if(r.level<w)return!0;const l=r.spatialReference,m=r.extent;if(!m||!l)return!0;const d=this.opaqueGround&&this._aboveGround,p=this.opaqueGround&&!this._aboveGround,_=E,b=.5*(m[0]+m[2]);if(n(_[0],m[0],m[1],0),n(_[1],m[2],m[1],0),n(_[2],m[2],m[3],0),n(_[3],m[0],m[3],0),n(_[4],b,m[1],0),n(_[5],b,m[3],0),!g(_,l,0,_,this._renderSR,0,6))return!1;const F=_[0][2]>0,M=_[3][2]<0,G=F||M,B=this._renderSREllipsoidRadius;if(G){const t=T;R(t,Gt,_[0]);const r=Y;if(R(r,Gt,_[1]),F){const n=P,e=_[4],s=H;R(s,e,Gt),R(n,s,e);const o=_[0];u(o,t,n),j(o,B);const i=_[1];u(i,r,n),j(i,B)}else if(M){const n=P,e=_[5],s=H;R(s,e,Gt),R(n,e,s);const o=_[3];u(o,n,t),j(o,B);const i=_[2];u(i,n,r),j(i,B)}}const q=k,I=s(N,_[3],_[0]);t(I,I);const x=c(O,_[0],_[3]);f(x,x,.5);const C=-o(x,I),A=c(Q,_[0],_[1]);f(A,A,.5);const W=c(X,_[2],_[3]);f(W,W,.5);const et=s(Z,W,A);t(et,et);const ht=-(C+o(I,A))/o(I,et);i(q,A,et,ht),j(q,B);const lt=this._frustumBoundingSphereRadius,mt=this._frustumBoundingSphereCenter,St=this._frustum,Ft=St.planes,Mt=L;t(Mt,q);const Rt=o(_[0],Mt)/a(_[0]),vt=St.origin,jt=St.points;let Bt=!1;if(d){{Bt=!0;const r=t(_t,vt);for(let n=0;n<4;++n){const e=jt[4+n],i=s(h(),e,vt);t(i,i);const c=u(h(),r,i);t(c,c);const f=u(h(),i,c);t(f,f);if(o(vt,f)>B){Bt=!1;break}}}if(Bt){if(o(vt,Mt)<B*Rt-pt)return!1}const r=t(_t,St.origin);if(o(r,Mt)<0)return!1;{const r=t(gt,St.direction);if(o(r,Mt)>bt)return!1}}const yt=Math.sqrt(1-Rt*Rt);if(yt>.9)return!0;let qt=!1;const wt=o(Mt,mt),It=a(mt);if(It<=lt&&!Ft.some(t=>S(t,z)>0)){if(!d)return!0;qt=!0}const Vt=wt/It;if(!qt&&wt<=0){if(-wt>lt)return!1}const xt=lt/It;if(Math.sqrt(1-Vt*Vt)*Math.sqrt(1-xt*xt)-xt*Vt>yt)return!1;if(!Bt){if(_.some(t=>St.intersectsPoint(t)))return!0;if(St.intersectsPoint(q))return!0}const Ct=D;s(Ct,mt,z);const Et=o(Ct,Mt),kt=U;f(kt,Mt,Et);const Pt=e(kt,mt),Tt=l.isWGS84,Yt=r.lij,Ht=Tt&&Yt[2]===2**Yt[0]-1,Lt=Tt&&0===Yt[2],Ut=Lt?ct:Ht?it:st,At=Lt?ft:Ht?ut:ot;if(!qt){const t=_,r=at,n=$,e=tt,s=z;for(const o of Ut){const i=t[o];if(v(n,t[(o+1)%4],i),v(e,s,i),R(r,e,n),V(r,jt,1))return!1}}let Wt=null;if(!d&&Et<1.01*lt){const t=2.5*lt;if(Pt>Rt*t+lt)return!1;const r=K,e=t/Rt;for(let n=0;n<4;++n)f(r[n],_[n],e/B);n(r[4],0,0,0),Wt=r}else{const t=(p?B+pt:Et+lt)/Rt,r=d?B-pt:(Et-lt)/Rt,n=J;for(let e=0;e<4;++e){const s=_[e];f(n[e],s,r/B),f(n[e+4],s,t/B)}Wt=n}if(y(Ft,Wt,Wt.length))return!1;const zt=St.lines,Dt=rt,Jt=nt;for(const n of zt){t(Jt,n.direction);for(const r of At){const n=Wt[r];if(t(Dt,n),dt(Jt,Dt,Wt,jt))return!1;const e=(r+1)%4;if(d){const r=Wt[e];if(s(Dt,r,n),t(Dt,Dt),dt(Jt,Dt,Wt,jt))return!1}if(p){const n=Wt[4+r],o=Wt[4+e];if(s(Dt,o,n),t(Dt,Dt),dt(Jt,Dt,Wt,jt))return!1}}}return!0}}function R(r,n,e){return u(r,n,e),t(r,r),r}function v(r,n,e){return s(r,n,e),t(r,r),r}function j(t,r){return f(t,t,r/a(t)),t}const G=[0,1,2,3,5];function B(t,r,n){for(let e=0;e<n;++e)if(S(t,r[e])<=0)return!1;return!0}function y(t,r,n){for(const e of G)if(B(t[e],r,n))return!0;return!1}function q(t,r,n=r.length){for(let e=0;e<n;++e){const n=r[e];let s=!0;for(const r of t){if(S(r,n)>0){s=!1;break}}if(s)return!0}return!1}const w=2,I=4;function V(t,r,n){for(const e of r)if(o(e,t)<n)return!1;return!0}const x=[h(),h(),h(),h(),h(),h(),h(),h()],C=[0,0,0,0,0,0],E=[h(),h(),h(),h(),h(),h()],k=h(),P=h(),T=h(),Y=h(),H=h(),L=h(),U=h(),A=h(),W=h(),z=m(0,0,0),D=h(),J=[h(),h(),h(),h(),h(),h(),h(),h()],K=[h(),h(),h(),h(),h()],N=h(),O=h(),Q=h(),X=h(),Z=h(),$=h(),tt=h(),rt=h(),nt=h(),et=h(),st=[0,1,2,3],ot=[0,1,2,3],it=[0,1,3],ut=[0,1,3],ct=[1,2,3],ft=[1,2,3],at=h();function ht(t,r,n){let e=1/0,s=-1/0;for(const i of n){const t=o(r,i);e=Math.min(e,t),s=Math.max(s,t)}t[0]=e,t[1]=s}function lt(t,r,n,e){let s=1/0,i=-1/0;for(const u of e){const e=o(n,u);if(s=Math.min(s,e),i=Math.max(i,e),s<=r&&i>=t)return!1}return!0}const mt=[0,0];function dt(t,r,n,e){const s=n.length,o=e.length;if(0===s||0===o)return!0;const i=et;R(i,t,r);const u=o<s,c=u?n:e,f=mt;return ht(f,i,u?e:n),lt(f[0],f[1],i,c)}const pt=430,_t=h(),gt=h(),bt=Math.cos(.25*Math.PI),St=l(0,0,1),Ft=h();function Mt(t,r,n){const e={t0:0,t1:1};for(const s of G){if(!vt(t[s],r,n,e))return!1}return e.t0<e.t1}function Rt(t,r,n){const e={t0:0,t1:1};for(const s of t){if(!vt(s,r,n,e))return!1}return e.t0<e.t1}function vt(t,r,n,e){let{t0:s,t1:o}=e;const i=S(t,r),u=S(t,n);if(i>=0&&u>=0)return!1;if(i<0&&u>=0){const t=-i/(u-i);if(t<s)return!1;t<o&&(o=t)}else if(i>=0&&u<0){const t=i/(i-u);if(t>o)return!1;t>s&&(s=t)}return e.t0=s,e.t1=o,!0}const jt=[b(-1,0,0,1),b(1,0,0,-1),b(0,-1,0,1),b(0,1,0,-1),b(0,0,-1,1),b(0,0,1,-1)],Gt=m(0,0,1),Bt=1;export{M as FeatureTileVisibility3D,q as isAnyVertexInPolyhedron,y as isConvexHullOutsideOfFrustum,I as maxLODLevelDelta,w as minTileLOD};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{d as t,n as i,a as e,g as s,c as r,E as n}from"../../../chunks/vec32.js";import{create as o}from"../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{create as h,createPoints as u,fromMatrix as p,computePlanes as d,intersectsSphere as a,intersectsRay as c,intersectsLineSegment as g,intersectsPoint as _,planePointIndices as l}from"../../../geometry/support/frustum.js";import{Sphere as m}from"../../../geometry/support/sphere.js";class f{get planes(){return this.frustum}get points(){return this._points}get mutablePoints(){return this._points}get direction(){return this._direction}get origin(){return this._origin}get boundingSphere(){return this._boundingSphereDirty&&this._updateBoundingSphere(),this._boundingSphere}constructor(t){this.renderCoordsHelper=t,this.frustum=h(),this._points=u(),this.lines=new Array(12),this._origin=o(),this._direction=o(),this._boundingSphere=new m,this._altitude=null,this._boundingSphereDirty=!0;for(let i=0;i<12;i++)this.lines[i]={origin:null,direction:o(),endpoint:null}}update(i){p(i.viewMatrix,i.projectionMatrix,this.frustum,this._points),t(this._origin,i.eye),t(this._direction,i.viewForward),this._altitude=this.renderCoordsHelper.getAltitude(this._origin),this._updateLines(),this._boundingSphereDirty=!0}updatePoints(i){for(let e=0;e<this._points.length;e++)t(this._points[e],i[e]);d(this.frustum,this._points),this._updateLines()}get altitude(){return this._altitude}intersectsSphere(t){return a(this.frustum,t)}intersectsRay(t){return c(this.frustum,t)}intersectsLineSegment(t,i){return g(this.frustum,t,i)}intersectsPoint(t){return _(this.frustum,t)}_updateLines(){const t=this._points;for(let i=0;i<4;i++){const e=i+4;S(this.lines[i],t[i],t[e]),S(this.lines[i+4],t[i],3===i?t[0]:t[i+1]),S(this.lines[i+8],t[e],3===i?t[4]:t[e+1])}}_updateBoundingSphere(){const{origin:t}=this,n=y;i(n,this.direction);const o=b;e(o,this.points[4],t);const h=.5*s(o,o)/s(n,o),u=this._boundingSphere,p=r(j,t,n,h);u.center=p,u.radius=h}static{this.planePointIndices=l}static{this.nearFarLineIndices=[[0,4],[1,5],[2,6],[3,7]]}}function S(t,i,e){t.origin=i,t.endpoint=e,n(t.direction,i,e)}const b=o(),y=o(),j=o();export{f as Frustum};
5
+ import{d as t,n as i,a as e,g as s,c as r,C as n}from"../../../chunks/vec32.js";import{create as o}from"../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{create as h,createPoints as u,fromMatrix as p,computePlanes as d,intersectsSphere as a,intersectsRay as c,intersectsLineSegment as g,intersectsPoint as _,planePointIndices as l}from"../../../geometry/support/frustum.js";import{Sphere as m}from"../../../geometry/support/sphere.js";class f{get planes(){return this.frustum}get points(){return this._points}get mutablePoints(){return this._points}get direction(){return this._direction}get origin(){return this._origin}get boundingSphere(){return this._boundingSphereDirty&&this._updateBoundingSphere(),this._boundingSphere}constructor(t){this.renderCoordsHelper=t,this.frustum=h(),this._points=u(),this.lines=new Array(12),this._origin=o(),this._direction=o(),this._boundingSphere=new m,this._altitude=null,this._boundingSphereDirty=!0;for(let i=0;i<12;i++)this.lines[i]={origin:null,direction:o(),endpoint:null}}update(i){p(i.viewMatrix,i.projectionMatrix,this.frustum,this._points),t(this._origin,i.eye),t(this._direction,i.viewForward),this._altitude=this.renderCoordsHelper.getAltitude(this._origin),this._updateLines(),this._boundingSphereDirty=!0}updatePoints(i){for(let e=0;e<this._points.length;e++)t(this._points[e],i[e]);d(this.frustum,this._points),this._updateLines()}get altitude(){return this._altitude}intersectsSphere(t){return a(this.frustum,t)}intersectsRay(t){return c(this.frustum,t)}intersectsLineSegment(t,i){return g(this.frustum,t,i)}intersectsPoint(t){return _(this.frustum,t)}_updateLines(){const t=this._points;for(let i=0;i<4;i++){const e=i+4;S(this.lines[i],t[i],t[e]),S(this.lines[i+4],t[i],3===i?t[0]:t[i+1]),S(this.lines[i+8],t[e],3===i?t[4]:t[e+1])}}_updateBoundingSphere(){const{origin:t}=this,n=y;i(n,this.direction);const o=b;e(o,this.points[4],t);const h=.5*s(o,o)/s(n,o),u=this._boundingSphere,p=r(j,t,n,h);u.center=p,u.radius=h}static{this.planePointIndices=l}static{this.nearFarLineIndices=[[0,4],[1,5],[2,6],[3,7]]}}function S(t,i,e){t.origin=i,t.endpoint=e,n(t.direction,i,e)}const b=o(),y=o(),j=o();export{f as Frustum};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as t}from"tslib";import i from"../../../../Camera.js";import{deg2rad as e,rad2deg as r,clamp as s}from"../../../../core/mathUtils.js";import{destroyMaybe as o}from"../../../../core/maybe.js";import{property as a,subclass as n}from"../../../../core/accessorSupport/decorators.js";import{i as h,j as l,d as m,D as v}from"../../../../chunks/vec32.js";import{create as c}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{pixelDistanceToInteractionFactor as _,applyAll as u}from"../../camera/constraintUtils.js";import{ConstraintOptions as p}from"../../camera/constraintUtils/ConstraintOptions.js";import{InteractiveController as d}from"./InteractiveController.js";import{pivotSearchAreaSize as f}from"../utils/navigationUtils.js";import w from"../../../ui/Component.js";import{FovOverlay as y}from"../../../../widgets/FovOverlay.js";let g=class extends d{constructor(t){super(t),this.onStop=null,this._timeOutId=void 0,this._onReset=()=>{this._startSize=this._lastDrag=null,this._setFov(S),this.updateTimeout()},this._center=c(),this._viewForward=c(),this._constraints=new p(15,1)}begin(t){j(t)?this._showOverlay().fov=t.fov:(this._lastDrag=t[1],this._startSize=null,this._ensureStartSize(this.view.state.camera))}updateTimeout(){clearTimeout(this._timeOutId),this._timeOutId=setTimeout(this.onStop,1500)}update(t){if(null==this._lastDrag)return this._lastDrag=t[1],this._startSize=null,void this._ensureStartSize(this.view.state.camera);const i=-(this._lastDrag-t[1])/2;this._lastDrag=t[1],this.step(i)}step(t){if(!this.running)return void(this._startSize=this._lastDrag=null);const i=this.view.state,o=this.currentCamera.copyFrom(i.camera),a=r(o.fov)+t,n=e(s(a,C,F));n!==o.fov?this._setFov(n):this._showOverlay().fov=o.fov}finish(){this.running&&(this._startSize=this._lastDrag=null,this.finishController())}destroy(){this.hideOverlay()}onControllerEnd(t){super.onControllerEnd(t),this._startSize=this._lastDrag=null,this.hideOverlay()}_showOverlay(){return this._overlay||(this._overlay=new w({id:"esri.FovOverlay",node:new y({onReset:this._onReset})}),this.view.ui.add(this._overlay)),this._overlay.widget}hideOverlay(){this._overlay&&(this.view.ui.remove(this._overlay),this._overlay=o(this._overlay))}_setFov(t){const i=this.view.state,e=this.currentCamera.copyFrom(i.camera),r=this._ensureStartSize(e)/Math.tan(t/2),s=h(O,this._center,l(O,this._viewForward,-r));e.eye=s,e.fov=t,this._constraints.interactionStartCamera=i.camera,this._constraints.interactionFactor=_(this.currentCamera.height-i.camera.height),u(this.view,this.currentCamera,this._constraints),this.begin(e),this.commitCamera()}_ensureStartSize(t){if(null==this._startSize){m(this._viewForward,t.viewForward);const i=this.view.stage.renderView.getMinimalDepthForArea(null,t.fullWidth/t.pixelRatio*.5,t.fullHeight/t.pixelRatio*.5,t,f),e=v(t.eye,this.view.pointsOfInterest.centerOnContent.renderLocation),r=i??e;h(this._center,t.eye,l(O,this._viewForward,r)),this._startSize=r*Math.tan(t.fov/2)}return this._startSize}};t([a()],g.prototype,"onStop",void 0),g=t([n("esri.views.3d.state.controllers.FovController")],g);const S=e((new i).fov),C=10,F=150,O=c();function j(t){return!Array.isArray(t)}export{g as FovController};
5
+ import{__decorate as t}from"tslib";import i from"../../../../Camera.js";import{deg2rad as e,rad2deg as r,clamp as s}from"../../../../core/mathUtils.js";import{destroyMaybe as o}from"../../../../core/maybe.js";import{property as a,subclass as n}from"../../../../core/accessorSupport/decorators.js";import{i as h,j as l,d as m,B as v}from"../../../../chunks/vec32.js";import{create as c}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{pixelDistanceToInteractionFactor as _,applyAll as u}from"../../camera/constraintUtils.js";import{ConstraintOptions as p}from"../../camera/constraintUtils/ConstraintOptions.js";import{InteractiveController as d}from"./InteractiveController.js";import{pivotSearchAreaSize as f}from"../utils/navigationUtils.js";import w from"../../../ui/Component.js";import{FovOverlay as y}from"../../../../widgets/FovOverlay.js";let g=class extends d{constructor(t){super(t),this.onStop=null,this._timeOutId=void 0,this._onReset=()=>{this._startSize=this._lastDrag=null,this._setFov(S),this.updateTimeout()},this._center=c(),this._viewForward=c(),this._constraints=new p(15,1)}begin(t){j(t)?this._showOverlay().fov=t.fov:(this._lastDrag=t[1],this._startSize=null,this._ensureStartSize(this.view.state.camera))}updateTimeout(){clearTimeout(this._timeOutId),this._timeOutId=setTimeout(this.onStop,1500)}update(t){if(null==this._lastDrag)return this._lastDrag=t[1],this._startSize=null,void this._ensureStartSize(this.view.state.camera);const i=-(this._lastDrag-t[1])/2;this._lastDrag=t[1],this.step(i)}step(t){if(!this.running)return void(this._startSize=this._lastDrag=null);const i=this.view.state,o=this.currentCamera.copyFrom(i.camera),a=r(o.fov)+t,n=e(s(a,C,F));n!==o.fov?this._setFov(n):this._showOverlay().fov=o.fov}finish(){this.running&&(this._startSize=this._lastDrag=null,this.finishController())}destroy(){this.hideOverlay()}onControllerEnd(t){super.onControllerEnd(t),this._startSize=this._lastDrag=null,this.hideOverlay()}_showOverlay(){return this._overlay||(this._overlay=new w({id:"esri.FovOverlay",node:new y({onReset:this._onReset})}),this.view.ui.add(this._overlay)),this._overlay.widget}hideOverlay(){this._overlay&&(this.view.ui.remove(this._overlay),this._overlay=o(this._overlay))}_setFov(t){const i=this.view.state,e=this.currentCamera.copyFrom(i.camera),r=this._ensureStartSize(e)/Math.tan(t/2),s=h(O,this._center,l(O,this._viewForward,-r));e.eye=s,e.fov=t,this._constraints.interactionStartCamera=i.camera,this._constraints.interactionFactor=_(this.currentCamera.height-i.camera.height),u(this.view,this.currentCamera,this._constraints),this.begin(e),this.commitCamera()}_ensureStartSize(t){if(null==this._startSize){m(this._viewForward,t.viewForward);const i=this.view.stage.renderView.getMinimalDepthForArea(null,t.fullWidth/t.pixelRatio*.5,t.fullHeight/t.pixelRatio*.5,t,f),e=v(t.eye,this.view.pointsOfInterest.centerOnContent.renderLocation),r=i??e;h(this._center,t.eye,l(O,this._viewForward,r)),this._startSize=r*Math.tan(t.fov/2)}return this._startSize}};t([a()],g.prototype,"onStop",void 0),g=t([n("esri.views.3d.state.controllers.FovController")],g);const S=e((new i).fov),C=10,F=150,O=c();function j(t){return!Array.isArray(t)}export{g as FovController};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as t}from"tslib";import{neverReached as e}from"../../../../core/compilerUtils.js";import{clamp as i,acosClamped as a,deg2rad as r}from"../../../../core/mathUtils.js";import{property as o,subclass as n}from"../../../../core/accessorSupport/decorators.js";import{translate as s,rotate as c,identity as l}from"../../../../core/libs/gl-matrix-2/math/mat4.js";import{create as m}from"../../../../core/libs/gl-matrix-2/factories/mat4f64.js";import{e as h,p,i as d,j as u,d as f,q as _,b as v,h as g,n as C,f as y,D as w,E as b,g as S}from"../../../../chunks/vec32.js";import{create as O}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getReferenceEllipsoid as x}from"../../../../geometry/ellipsoidUtils.js";import{wrap as M}from"../../../../geometry/support/ray.js";import{Sphere as j}from"../../../../geometry/support/sphere.js";import{angle as z}from"../../../../geometry/support/vector.js";import{sv3d as T}from"../../../../geometry/support/vectorStacks.js";import{applyAll as A}from"../../camera/constraintUtils.js";import{ConstraintOptions as D}from"../../camera/constraintUtils/ConstraintOptions.js";import{TiltRange as R}from"../Constraints.js";import{InteractiveController as E}from"./InteractiveController.js";import{panMotionToRotationMatrix as H,onSurfaceTiltToEyeTiltGlobal as U,offSurfaceTiltToEyeTiltGlobal as k}from"../utils/navigationUtils.js";import{viewAngle as F}from"../utils/viewUtils.js";import{headingTiltToDirectionUp as G}from"../../support/cameraUtils.js";import{createDirectionUp as P}from"../../support/cameraUtilsInternal.js";import B from"../../webgl/RenderCamera.js";import{extractTransformation as I,isZeroTransformation as V,extractTransformationKeyboard as q}from"../../../navigation/gamepadAndKeyboardUtils.js";let L=class extends E{constructor(t){super(t),this._filteredSurfaceElevation=0,this._transformation={translation:[0,0,0],heading:0,tilt:0,zoom:0},this._keysButtonState=[0,0,0,0,0,0,0,0,0,0,0,0],this._tmpCamera=new B,this._headingStart=0,this._constraintOptions=new D(15,0,0,new B,null,1)}handleEventGamepad(t){const e=I(t,this.view.navigation.gamepad,this._transformation);("end"===t.action||V(e))&&this.finishController()}activateDirection(t){this._keysButtonState[t]=1,q(this._keysButtonState,this._transformation)}directionActive(t){return 1===this._keysButtonState[t]}countActiveDirections(){return this._keysButtonState.reduce((t,e)=>e>0?t+1:t,0)}deactivateDirection(t){this._keysButtonState[t]=0;const e=q(this._keysButtonState,this._transformation);V(e)&&this.finishController()}onControllerStart(t){this._filteredSurfaceElevation=this.view.pointsOfInterest.cameraOnSurface.location.z,this._headingStart=this.view.camera.heading,super.onControllerStart(t)}_updateFilteredSurfaceElevation(t){const e=this.view.pointsOfInterest.cameraOnSurface.location.z,i=1;this._filteredSurfaceElevation+=i*(e-this._filteredSurfaceElevation)*t}stepController(t,e){this._updateStartHeading(),this._updateFilteredSurfaceElevation(t),this.currentCamera.copyViewFrom(e),this._updateCameraCenter(),this._constraintOptions.interactionStartCamera?.copyFrom(this.currentCamera),this._calculateControlTransformation(t,this.currentCamera,Y),this._applyDisabledMovementTypes(Y),this._applyPan(Y.pan),this._applyRotate(Y.rotate),this._applyZoom(Y.zoom),this._applyAscend(Y.ascend),this._constraintOptions.interactionType=0,this._constraintOptions.selection=8,A(this.view,this.currentCamera,this._constraintOptions),super.stepController(t,e)}_updateStartHeading(){0!==this._transformation.heading&&(this._headingStart=this.view.camera.heading)}_applyRotate(t){if(!t.enabled)return;const e=this.currentCamera;h($,e.center,e.eye),p($,$,t.matrix),e.center=d($,$,e.eye),e.up=p($,e.up,t.matrix),this._constraintOptions.interactionType=3,this._constraintOptions.selection=7,A(this.view,e,this._constraintOptions)}_applyPan(t,e=this.currentCamera){if(!t.enabled)return;e.eye=p($,e.eye,t.matrix),e.center=p($,e.center,t.matrix);this.view.state.isGlobal&&(e.up=p($,e.up,t.matrix)),this._constraintOptions.interactionType=4,this._constraintOptions.selection=15,A(this.view,e,this._constraintOptions)}_applyZoom(t){if(!t)return;const e=this.currentCamera.viewForward;this.currentCamera.eye=d($,this.currentCamera.eye,u(T.get(),e,t)),f(tt,e),_(tt,tt),this._constraintOptions.interactionDirection=tt,this._constraintOptions.interactionType=1,this._constraintOptions.selection=7,A(this.view,this.currentCamera,this._constraintOptions),this._constraintOptions.interactionDirection=null}_applyAscend(t){if(!t)return;const e=this.view.renderCoordsHelper.worldUpAtPosition(this.currentCamera.eye,T.get());this._constraintOptions.interactionDirection=f(tt,e);if(this.view.state.isGlobal){const e=v(this.currentCamera.eye),i=(e+t)/e;this.currentCamera.eye=u($,this.currentCamera.eye,i),this.currentCamera.center=u($,this.currentCamera.center,i)}else{const i=u(T.get(),e,t);this.currentCamera.eye=d($,this.currentCamera.eye,i),this.currentCamera.center=d($,this.currentCamera.center,i)}this._updateCameraCenter(),this._constraintOptions.interactionType=5,this._constraintOptions.selection=8,A(this.view,this.currentCamera,this._constraintOptions)&&this._updateCameraCenter(),this._constraintOptions.selection=7,A(this.view,this.currentCamera,this._constraintOptions),this._constraintOptions.interactionDirection=null}_calculateControlTransformation(t,e,i){at(i);const a=this._computeVelocities(t);this.view.state.isLocal?this._calculateControlTransformationLocal(a,e,i):this._calculateControlTransformationGlobal(a,e,i)}_updateCameraCenter(){const t=this.view.pointsOfInterest.centerOnSurfaceFrequent.estimatedSurfaceAltitude,e=this.view.renderCoordsHelper,i=this.currentCamera.ray;this.currentCamera.center=e.intersectManifoldClosestSilhouette(i,t,$)}_calculateControlTransformationLocal(t,a,r){const{viewRight:o,viewForward:n}=a,l=this._transformation,m=this.view.navigation.gamepad,h=g(T.get(),n[0],n[1],0);C(h,h);const p=l.translation[0]*t.pan;if(0!==p){const t=u(T.get(),o,p);s(r.pan.matrix,r.pan.matrix,t),r.pan.enabled=!0}switch(m.mode){case"pan":{const e=-l.translation[1]*t.pan;if(0!==e){const t=u(T.get(),h,e);s(r.pan.matrix,r.pan.matrix,t),r.pan.enabled=!0}r.zoom=l.zoom*t.zoom;break}case"zoom":r.zoom=(-l.translation[1]+l.zoom)*t.zoom;break;default:e(m.mode)}const d=l.translation[2]*t.ascend;r.ascend=d;const f=-l.heading*t.rotate;0!==f&&(c(r.rotate.matrix,r.rotate.matrix,f,this.view.renderCoordsHelper.worldUpAtPosition(a.eye,T.get())),r.rotate.enabled=!0);const _=l.tilt*t.rotate,v=F(this.view.renderCoordsHelper,a.center,a.eye),y=i(v+_,R.min,R.max)-v;y&&(c(r.rotate.matrix,r.rotate.matrix,y,o),r.rotate.enabled=!0)}_calculateControlTransformationGlobal(t,e,i){const{eye:a,viewRight:r}=e,o=this._transformation,n=this.view.navigation.gamepad,s=y(T.get(),r,a);C(s,s),_(s,s),H(this.startCamera,e,o,t,this.view.camera.heading,this._headingStart,this.view.camera.tilt,i,n),this._tmpCamera.copyFrom(this.currentCamera),this._applyPan(Y.pan,this._tmpCamera);const l=this.view.pointsOfInterest.centerOnSurfaceFrequent.estimatedSurfaceAltitude,m=o.translation[2]*t.ascend;i.ascend=m;const h=-o.heading*t.rotate;0!==h&&(c(i.rotate.matrix,i.rotate.matrix,h,this._tmpCamera.eye),i.rotate.enabled=!0);const p=o.tilt*t.rotate,d=this._clampTiltDeltaGlobalToValidRange(p,e.ray,l);0!==d&&(c(i.rotate.matrix,i.rotate.matrix,d,this._tmpCamera.viewRight),i.rotate.enabled=!0),i.zoom+=o.zoom*t.zoom}_clampTiltDeltaGlobalToValidRange(t,e,a){const r=x(this.view.spatialReference),o=U(R.min,e.origin,a,r);let n=0,s=0;const c=T.get();if(this.view.renderCoordsHelper.intersectManifold(e,a,c)){const t=F(this.view.renderCoordsHelper,c,e.origin);n=U(t,e.origin,a,r),s=U(R.max,e.origin,a,r)}else{it.radius=a+r.radius,it.closestPointOnSilhouette(e,c);const t=Math.PI+z(e.direction,c);n=k(t,e.origin,a,r),s=k(R.max,e.origin,a,r)}return i(n+t,o,s)-n}_getPointAbsoluteSurfaceElevation(t,e,i){const{renderCoordsHelper:a}=this.view,r=a.getAltitude(t),o=e+Math.abs(r-e);return a.setAltitude(i,o,t),o}_clampedDistanceToSurface(t,e){const{renderCoordsHelper:i}=this.view,{camera:a}=this.view.state,{direction:r}=G(this.view,e,0,Z,et),o=i.intersectManifoldClosestSilhouette(M(e,r),t,T.get()),n=w(e,o),s=i.intersectManifoldClosestSilhouette(M(e,b(T.get(),e,a.center)),t,T.get()),c=w(e,s);return Math.min(n,c)}_computeHeadingRotateRadius(t){const{renderCoordsHelper:e,state:i}=this.view,{camera:r,isGlobal:o}=i,n=e.intersectManifoldClosestSilhouette(r.ray,this._filteredSurfaceElevation,T.get());if(o){const e=h(T.get(),t,n),i=v(e);u(e,e,1/i);const r=C(T.get(),t),o=a(S(r,e));return i*Math.sin(Math.min(X,o))}{const i=f(T.get(),t);return e.setAltitude(i,this._filteredSurfaceElevation),w(n,i)}}_minimumAscendVelocity(){return this.view.state.constraints.collision.enabled?0:N}_computeVelocities(t){const e=this._filteredSurfaceElevation,a=e+x(this.view.spatialReference).radius,{camera:r,isGlobal:o}=this.view.state,n=T.get(),s=this._getPointAbsoluteSurfaceElevation(r.eye,e,n),c=this._clampedDistanceToSurface(e,n),l=r.width/2,m=J*r.width,h=J*r.width,p=c*Math.tan(.5*r.fovX)/l,d=p/a,u=p/this._computeHeadingRotateRadius(n),f=s-e;return{pan:(o?d:p)*m*t,ascend:Math.max(this._minimumAscendVelocity()*t,2**(m*t/l)*f-f),zoom:2**(m*t/l)*c-c,rotate:i(u*h,Q,W)*t}}_applyDisabledMovementTypes(t){null==this.disableMovements||void 0!==this.disableMovements.mode&&this.view.state.viewingMode!==this.disableMovements.mode||(t.zoom=this.disableMovements.zoom?0:t.zoom,t.ascend=this.disableMovements.ascend?0:t.ascend,t.pan.enabled=!this.disableMovements.pan,this.disableMovements.pan&&l(t.pan.matrix),t.rotate.enabled=!this.disableMovements.rotate,this.disableMovements.rotate&&l(t.rotate.matrix))}static activatesFor(t,e){const i=I(e,t.navigation.gamepad,K);return!("end"===e.action||V(i))}};t([o({constructOnly:!0})],L.prototype,"gamepadDevice",void 0),t([o({constructOnly:!0})],L.prototype,"disableMovements",void 0),L=t([n("esri.views.3d.state.controllers.GamepadKeyboardController")],L);const K={translation:[0,0,0],heading:0,tilt:0,zoom:0},Z=80,X=r(Z),J=.75,N=5,Q=r(30),W=r(80),Y={zoom:0,ascend:0,pan:{enabled:!1,matrix:m()},rotate:{enabled:!1,matrix:m()}},$=O(),tt=O(),et=P(),it=new j;function at(t){t.zoom=0,t.ascend=0,t.pan.enabled=!1,l(t.pan.matrix),t.rotate.enabled=!1,l(t.rotate.matrix)}export{L as GamepadKeyboardController};
5
+ import{__decorate as t}from"tslib";import{neverReached as e}from"../../../../core/compilerUtils.js";import{clamp as i,acosClamped as a,deg2rad as r}from"../../../../core/mathUtils.js";import{property as o,subclass as n}from"../../../../core/accessorSupport/decorators.js";import{translate as s,rotate as c,identity as l}from"../../../../core/libs/gl-matrix-2/math/mat4.js";import{create as m}from"../../../../core/libs/gl-matrix-2/factories/mat4f64.js";import{e as h,p,i as d,j as u,d as f,q as _,b as v,h as C,n as g,f as y,B as w,C as b,g as S}from"../../../../chunks/vec32.js";import{create as O}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getReferenceEllipsoid as x}from"../../../../geometry/ellipsoidUtils.js";import{wrap as M}from"../../../../geometry/support/ray.js";import{Sphere as j}from"../../../../geometry/support/sphere.js";import{angle as z}from"../../../../geometry/support/vector.js";import{sv3d as T}from"../../../../geometry/support/vectorStacks.js";import{applyAll as A}from"../../camera/constraintUtils.js";import{ConstraintOptions as D}from"../../camera/constraintUtils/ConstraintOptions.js";import{TiltRange as R}from"../Constraints.js";import{InteractiveController as H}from"./InteractiveController.js";import{panMotionToRotationMatrix as E,onSurfaceTiltToEyeTiltGlobal as U,offSurfaceTiltToEyeTiltGlobal as k}from"../utils/navigationUtils.js";import{viewAngle as F}from"../utils/viewUtils.js";import{headingTiltToDirectionUp as G}from"../../support/cameraUtils.js";import{createDirectionUp as P}from"../../support/cameraUtilsInternal.js";import B from"../../webgl/RenderCamera.js";import{extractTransformation as I,isZeroTransformation as V,extractTransformationKeyboard as q}from"../../../navigation/gamepadAndKeyboardUtils.js";let L=class extends H{constructor(t){super(t),this._filteredSurfaceElevation=0,this._transformation={translation:[0,0,0],heading:0,tilt:0,zoom:0},this._keysButtonState=[0,0,0,0,0,0,0,0,0,0,0,0],this._tmpCamera=new B,this._headingStart=0,this._constraintOptions=new D(15,0,0,new B,null,1)}handleEventGamepad(t){const e=I(t,this.view.navigation.gamepad,this._transformation);("end"===t.action||V(e))&&this.finishController()}activateDirection(t){this._keysButtonState[t]=1,q(this._keysButtonState,this._transformation)}directionActive(t){return 1===this._keysButtonState[t]}countActiveDirections(){return this._keysButtonState.reduce((t,e)=>e>0?t+1:t,0)}deactivateDirection(t){this._keysButtonState[t]=0;const e=q(this._keysButtonState,this._transformation);V(e)&&this.finishController()}onControllerStart(t){this._filteredSurfaceElevation=this.view.pointsOfInterest.cameraOnSurface.location.z,this._headingStart=this.view.camera.heading,super.onControllerStart(t)}_updateFilteredSurfaceElevation(t){const e=this.view.pointsOfInterest.cameraOnSurface.location.z,i=1;this._filteredSurfaceElevation+=i*(e-this._filteredSurfaceElevation)*t}stepController(t,e){this._updateStartHeading(),this._updateFilteredSurfaceElevation(t),this.currentCamera.copyViewFrom(e),this._updateCameraCenter(),this._constraintOptions.interactionStartCamera?.copyFrom(this.currentCamera),this._calculateControlTransformation(t,this.currentCamera,Y),this._applyDisabledMovementTypes(Y),this._applyPan(Y.pan),this._applyRotate(Y.rotate),this._applyZoom(Y.zoom),this._applyAscend(Y.ascend),this._constraintOptions.interactionType=0,this._constraintOptions.selection=8,A(this.view,this.currentCamera,this._constraintOptions),super.stepController(t,e)}_updateStartHeading(){0!==this._transformation.heading&&(this._headingStart=this.view.camera.heading)}_applyRotate(t){if(!t.enabled)return;const e=this.currentCamera;h($,e.center,e.eye),p($,$,t.matrix),e.center=d($,$,e.eye),e.up=p($,e.up,t.matrix),this._constraintOptions.interactionType=3,this._constraintOptions.selection=7,A(this.view,e,this._constraintOptions)}_applyPan(t,e=this.currentCamera){if(!t.enabled)return;e.eye=p($,e.eye,t.matrix),e.center=p($,e.center,t.matrix);this.view.state.isGlobal&&(e.up=p($,e.up,t.matrix)),this._constraintOptions.interactionType=4,this._constraintOptions.selection=15,A(this.view,e,this._constraintOptions)}_applyZoom(t){if(!t)return;const e=this.currentCamera.viewForward;this.currentCamera.eye=d($,this.currentCamera.eye,u(T.get(),e,t)),f(tt,e),_(tt,tt),this._constraintOptions.interactionDirection=tt,this._constraintOptions.interactionType=1,this._constraintOptions.selection=7,A(this.view,this.currentCamera,this._constraintOptions),this._constraintOptions.interactionDirection=null}_applyAscend(t){if(!t)return;const e=this.view.renderCoordsHelper.worldUpAtPosition(this.currentCamera.eye,T.get());this._constraintOptions.interactionDirection=f(tt,e);if(this.view.state.isGlobal){const e=v(this.currentCamera.eye),i=(e+t)/e;this.currentCamera.eye=u($,this.currentCamera.eye,i),this.currentCamera.center=u($,this.currentCamera.center,i)}else{const i=u(T.get(),e,t);this.currentCamera.eye=d($,this.currentCamera.eye,i),this.currentCamera.center=d($,this.currentCamera.center,i)}this._updateCameraCenter(),this._constraintOptions.interactionType=5,this._constraintOptions.selection=8,A(this.view,this.currentCamera,this._constraintOptions)&&this._updateCameraCenter(),this._constraintOptions.selection=7,A(this.view,this.currentCamera,this._constraintOptions),this._constraintOptions.interactionDirection=null}_calculateControlTransformation(t,e,i){at(i);const a=this._computeVelocities(t);this.view.state.isLocal?this._calculateControlTransformationLocal(a,e,i):this._calculateControlTransformationGlobal(a,e,i)}_updateCameraCenter(){const t=this.view.pointsOfInterest.centerOnSurfaceFrequent.estimatedSurfaceAltitude,e=this.view.renderCoordsHelper,i=this.currentCamera.ray;this.currentCamera.center=e.intersectManifoldClosestSilhouette(i,t,$)}_calculateControlTransformationLocal(t,a,r){const{viewRight:o,viewForward:n}=a,l=this._transformation,m=this.view.navigation.gamepad,h=C(T.get(),n[0],n[1],0);g(h,h);const p=l.translation[0]*t.pan;if(0!==p){const t=u(T.get(),o,p);s(r.pan.matrix,r.pan.matrix,t),r.pan.enabled=!0}switch(m.mode){case"pan":{const e=-l.translation[1]*t.pan;if(0!==e){const t=u(T.get(),h,e);s(r.pan.matrix,r.pan.matrix,t),r.pan.enabled=!0}r.zoom=l.zoom*t.zoom;break}case"zoom":r.zoom=(-l.translation[1]+l.zoom)*t.zoom;break;default:e(m.mode)}const d=l.translation[2]*t.ascend;r.ascend=d;const f=-l.heading*t.rotate;0!==f&&(c(r.rotate.matrix,r.rotate.matrix,f,this.view.renderCoordsHelper.worldUpAtPosition(a.eye,T.get())),r.rotate.enabled=!0);const _=l.tilt*t.rotate,v=F(this.view.renderCoordsHelper,a.center,a.eye),y=i(v+_,R.min,R.max)-v;y&&(c(r.rotate.matrix,r.rotate.matrix,y,o),r.rotate.enabled=!0)}_calculateControlTransformationGlobal(t,e,i){const{eye:a,viewRight:r}=e,o=this._transformation,n=this.view.navigation.gamepad,s=y(T.get(),r,a);g(s,s),_(s,s),E(this.startCamera,e,o,t,this.view.camera.heading,this._headingStart,this.view.camera.tilt,i,n),this._tmpCamera.copyFrom(this.currentCamera),this._applyPan(Y.pan,this._tmpCamera);const l=this.view.pointsOfInterest.centerOnSurfaceFrequent.estimatedSurfaceAltitude,m=o.translation[2]*t.ascend;i.ascend=m;const h=-o.heading*t.rotate;0!==h&&(c(i.rotate.matrix,i.rotate.matrix,h,this._tmpCamera.eye),i.rotate.enabled=!0);const p=o.tilt*t.rotate,d=this._clampTiltDeltaGlobalToValidRange(p,e.ray,l);0!==d&&(c(i.rotate.matrix,i.rotate.matrix,d,this._tmpCamera.viewRight),i.rotate.enabled=!0),i.zoom+=o.zoom*t.zoom}_clampTiltDeltaGlobalToValidRange(t,e,a){const r=x(this.view.spatialReference),o=U(R.min,e.origin,a,r);let n=0,s=0;const c=T.get();if(this.view.renderCoordsHelper.intersectManifold(e,a,c)){const t=F(this.view.renderCoordsHelper,c,e.origin);n=U(t,e.origin,a,r),s=U(R.max,e.origin,a,r)}else{it.radius=a+r.radius,it.closestPointOnSilhouette(e,c);const t=Math.PI+z(e.direction,c);n=k(t,e.origin,a,r),s=k(R.max,e.origin,a,r)}return i(n+t,o,s)-n}_getPointAbsoluteSurfaceElevation(t,e,i){const{renderCoordsHelper:a}=this.view,r=a.getAltitude(t),o=e+Math.abs(r-e);return a.setAltitude(i,o,t),o}_clampedDistanceToSurface(t,e){const{renderCoordsHelper:i}=this.view,{camera:a}=this.view.state,{direction:r}=G(this.view,e,0,Z,et),o=i.intersectManifoldClosestSilhouette(M(e,r),t,T.get()),n=w(e,o),s=i.intersectManifoldClosestSilhouette(M(e,b(T.get(),e,a.center)),t,T.get()),c=w(e,s);return Math.min(n,c)}_computeHeadingRotateRadius(t){const{renderCoordsHelper:e,state:i}=this.view,{camera:r,isGlobal:o}=i,n=e.intersectManifoldClosestSilhouette(r.ray,this._filteredSurfaceElevation,T.get());if(o){const e=h(T.get(),t,n),i=v(e);u(e,e,1/i);const r=g(T.get(),t),o=a(S(r,e));return i*Math.sin(Math.min(X,o))}{const i=f(T.get(),t);return e.setAltitude(i,this._filteredSurfaceElevation),w(n,i)}}_minimumAscendVelocity(){return this.view.state.constraints.collision.enabled?0:N}_computeVelocities(t){const e=this._filteredSurfaceElevation,a=e+x(this.view.spatialReference).radius,{camera:r,isGlobal:o}=this.view.state,n=T.get(),s=this._getPointAbsoluteSurfaceElevation(r.eye,e,n),c=this._clampedDistanceToSurface(e,n),l=r.width/2,m=J*r.width,h=J*r.width,p=c*Math.tan(.5*r.fovX)/l,d=p/a,u=p/this._computeHeadingRotateRadius(n),f=s-e;return{pan:(o?d:p)*m*t,ascend:Math.max(this._minimumAscendVelocity()*t,2**(m*t/l)*f-f),zoom:2**(m*t/l)*c-c,rotate:i(u*h,Q,W)*t}}_applyDisabledMovementTypes(t){null==this.disableMovements||void 0!==this.disableMovements.mode&&this.view.state.viewingMode!==this.disableMovements.mode||(t.zoom=this.disableMovements.zoom?0:t.zoom,t.ascend=this.disableMovements.ascend?0:t.ascend,t.pan.enabled=!this.disableMovements.pan,this.disableMovements.pan&&l(t.pan.matrix),t.rotate.enabled=!this.disableMovements.rotate,this.disableMovements.rotate&&l(t.rotate.matrix))}static activatesFor(t,e){const i=I(e,t.navigation.gamepad,K);return!("end"===e.action||V(i))}};t([o({constructOnly:!0})],L.prototype,"gamepadDevice",void 0),t([o({constructOnly:!0})],L.prototype,"disableMovements",void 0),L=t([n("esri.views.3d.state.controllers.GamepadKeyboardController")],L);const K={translation:[0,0,0],heading:0,tilt:0,zoom:0},Z=80,X=r(Z),J=.75,N=5,Q=r(30),W=r(80),Y={zoom:0,ascend:0,pan:{enabled:!1,matrix:m()},rotate:{enabled:!1,matrix:m()}},$=O(),tt=O(),et=P(),it=new j;function at(t){t.zoom=0,t.ascend=0,t.pan.enabled=!1,l(t.pan.matrix),t.rotate.enabled=!1,l(t.rotate.matrix)}export{L as GamepadKeyboardController};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as t}from"tslib";import{property as o,subclass as e}from"../../../../../core/accessorSupport/decorators.js";import{d as r,E as s}from"../../../../../chunks/vec32.js";import{create as i,clone as n}from"../../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{MomentumController as m}from"./MomentumController.js";import{applyZoomToPoint as c}from"../../utils/navigationUtils.js";let a=class extends m{constructor(t){super(t),this.interactionType=1,this.constraintOptions.interactionDirection=i()}momentumStep(t,o){const{interactionDirection:e}=this.constraintOptions;if(!e)return;r(e,o.eye);const i=this.momentum.valueDelta(0,t);c(o,this.zoomCenter,i,this.view.state.constraints.minimumPoiDistance),s(e,o.eye,e)}set zoomCenter(t){this._set("zoomCenter",n(t))}};t([o({constructOnly:!0})],a.prototype,"momentum",void 0),t([o({constructOnly:!0})],a.prototype,"zoomCenter",null),a=t([e("esri.views.3d.state.controllers.momentum.ZoomPlanarMomentumController")],a);export{a as ZoomPlanarMomentumController};
5
+ import{__decorate as t}from"tslib";import{property as o,subclass as e}from"../../../../../core/accessorSupport/decorators.js";import{d as r,C as s}from"../../../../../chunks/vec32.js";import{create as i,clone as n}from"../../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{MomentumController as m}from"./MomentumController.js";import{applyZoomToPoint as c}from"../../utils/navigationUtils.js";let a=class extends m{constructor(t){super(t),this.interactionType=1,this.constraintOptions.interactionDirection=i()}momentumStep(t,o){const{interactionDirection:e}=this.constraintOptions;if(!e)return;r(e,o.eye);const i=this.momentum.valueDelta(0,t);c(o,this.zoomCenter,i,this.view.state.constraints.minimumPoiDistance),s(e,o.eye,e)}set zoomCenter(t){this._set("zoomCenter",n(t))}};t([o({constructOnly:!0})],a.prototype,"momentum",void 0),t([o({constructOnly:!0})],a.prototype,"zoomCenter",null),a=t([e("esri.views.3d.state.controllers.momentum.ZoomPlanarMomentumController")],a);export{a as ZoomPlanarMomentumController};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{neverReached as t}from"../../../core/compilerUtils.js";import{lerp as e}from"../../../core/mathUtils.js";import{invert as i}from"../../../core/libs/gl-matrix-2/math/mat4.js";import{create as r}from"../../../core/libs/gl-matrix-2/factories/mat4f64.js";import{i as n,j as o,E as s,p as a,h as c,g as l}from"../../../chunks/vec32.js";import{create as p}from"../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getReferenceEllipsoid as h}from"../../../geometry/ellipsoidUtils.js";import{computeTranslationToOriginAndRotation as d}from"../../../geometry/projection/computeTranslationToOriginAndRotation.js";import{projectBoundingRect as _}from"../../../geometry/projection/projectBoundingRect.js";import{projectVectorToVector as m}from"../../../geometry/projection/projectVectorToVector.js";import{empty as g,create as x,expandWithVec3 as f}from"../../../geometry/support/aaBoundingBox.js";import{center as u,create as y}from"../../../geometry/support/aaBoundingRect.js";import{fromPoints as j,create as R}from"../../../geometry/support/lineSegment.js";import{create as b,fromVectorsAndPoint as S,copy as B,negate as C,signedDistance as H}from"../../../geometry/support/plane.js";import{wrap as w}from"../../../geometry/support/ray.js";import{frustumLineSegment as M}from"./intersectionUtils.js";const A=.5*Math.PI,E=A/Math.PI*180;class G{constructor(t){this._extent=new Array(4),this._planes=new Array(6),this._maxSpan=0,this._center={origin:p(),direction:p()},this._renderCoordsHelper=t.renderCoordsHelper;for(let e=0;e<4;e++)this._extent[e]={origin:p(),direction:p(),cap:{next:null,direction:p()}},this._planes[e]=b();this._planes[4]=b(),this._planes[5]=b(),this._planesWithoutFar=this._planes.slice(0,5)}update(t,e,i,r=!0){const a=this._extent;this._toRenderBoundingExtent(t,e,i),n(this._center.origin,a[0].origin,a[2].origin),o(this._center.origin,this._center.origin,.5),this._renderCoordsHelper.worldUpAtPosition(this._center.origin,this._center.direction),r||o(this._center.direction,this._center.direction,-1);for(let n=0;n<4;n++){const t=a[n];this._renderCoordsHelper.worldUpAtPosition(t.origin,t.direction);const e=a[3===n?0:n+1];t.cap.next=e.origin,s(t.cap.direction,t.origin,e.origin),S(t.direction,t.cap.direction,t.origin,this._planes[n]),r||o(t.direction,t.direction,-1)}S(a[0].cap.direction,a[1].cap.direction,a[0].origin,this._planes[4]),r?C(this._planes[4],this._planes[5]):(B(this._planes[5],this._planes[4]),C(this._planes[4],this._planes[4])),this._maxSpan=Math.max(Math.abs(t[0]-t[2]),Math.abs(t[1]-t[3])),this._maxSpanSpatialReference=e,this._minGlobalAltitude=.9*h(this._maxSpanSpatialReference).radius}isVisibleInFrustum(t,e,i=!1){if(null==t)return!1;if(1===this._renderCoordsHelper.viewingMode){const i=this._maxSpanSpatialReference.isGeographic?E:A*e;if(this._maxSpan>i)return!0;if(null!=t.altitude&&t.altitude>=this._minGlobalAltitude)return this._isVisibleInFrustumGlobal(t)}if(0===this._maxSpan){const e=this._extent[0];return!(i||!t.intersectsRay(w(e.origin,e.direction)))}for(let n=0;n<this._extent.length;n++){const e=this._extent[n];if(!i&&t.intersectsRay(w(e.origin,e.direction)))return!0;if(t.intersectsLineSegment(j(e.origin,e.cap.next,k),e.cap.direction))return!0}const r=i?this._planes:this._planesWithoutFar;for(let n=0;n<t.lines.length;n++){const e=t.lines[n];if(M(r,e.origin,e.endpoint,e.direction))return!0}return!1}_toRenderBoundingExtentGlobal(t,r,n){const o=5;u(t,v),v[2]=n,d(r,v,F,this._renderCoordsHelper.spatialReference),i(I,F),g(V);for(const{x0:i,x1:s,y0:c,y1:l}of U)for(let p=0;p<o;p++){const h=p/(o-1);v[0]=e(t[i],t[s],h),v[1]=e(t[c],t[l],h),v[2]=n,m(v,r,v,this._renderCoordsHelper.spatialReference),a(v,v,I),f(V,v)}c(this._extent[0].origin,V[0],V[1],V[2]),c(this._extent[1].origin,V[3],V[1],V[2]),c(this._extent[2].origin,V[3],V[4],V[2]),c(this._extent[3].origin,V[0],V[4],V[2]);for(let e=0;e<4;++e)a(this._extent[e].origin,this._extent[e].origin,F)}_toRenderBoundingExtentLocal(t,e,i){_(t,e,P,this._renderCoordsHelper.spatialReference),c(this._extent[0].origin,P[0],P[1],i),c(this._extent[1].origin,P[2],P[1],i),c(this._extent[2].origin,P[2],P[3],i),c(this._extent[3].origin,P[0],P[3],i)}_toRenderBoundingExtent(e,i,r){switch(this._renderCoordsHelper.viewingMode){case 1:this._toRenderBoundingExtentGlobal(e,i,r);break;case 2:this._toRenderBoundingExtentLocal(e,i,r);break;default:t(this._renderCoordsHelper.viewingMode)}}_isVisibleInFrustumGlobal(t){if(H(t.planes[4],this._center.origin)<0&&l(this._center.direction,t.direction)<0)return!0;for(let e=0;e<4;e++){const i=this._extent[e];if(H(t.planes[4],i.origin)<0&&l(i.direction,t.direction)<0)return!0}return!1}}const U=[{x0:0,y0:1,x1:2,y1:1},{x0:0,y0:3,x1:2,y1:3},{x0:0,y0:1,x1:0,y1:3},{x0:2,y0:1,x1:2,y1:3}],v=p(),F=r(),I=r(),V=x(),P=y(),k=R();export{G as FrustumExtentIntersection};
5
+ import{neverReached as t}from"../../../core/compilerUtils.js";import{lerp as e}from"../../../core/mathUtils.js";import{invert as i}from"../../../core/libs/gl-matrix-2/math/mat4.js";import{create as r}from"../../../core/libs/gl-matrix-2/factories/mat4f64.js";import{i as n,j as o,C as s,p as a,h as c,g as l}from"../../../chunks/vec32.js";import{create as p}from"../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getReferenceEllipsoid as h}from"../../../geometry/ellipsoidUtils.js";import{computeTranslationToOriginAndRotation as d}from"../../../geometry/projection/computeTranslationToOriginAndRotation.js";import{projectBoundingRect as _}from"../../../geometry/projection/projectBoundingRect.js";import{projectVectorToVector as m}from"../../../geometry/projection/projectVectorToVector.js";import{empty as g,create as x,expandWithVec3 as f}from"../../../geometry/support/aaBoundingBox.js";import{center as u,create as y}from"../../../geometry/support/aaBoundingRect.js";import{fromPoints as j,create as R}from"../../../geometry/support/lineSegment.js";import{create as b,fromVectorsAndPoint as S,copy as C,negate as B,signedDistance as H}from"../../../geometry/support/plane.js";import{wrap as w}from"../../../geometry/support/ray.js";import{frustumLineSegment as M}from"./intersectionUtils.js";const A=.5*Math.PI,G=A/Math.PI*180;class E{constructor(t){this._extent=new Array(4),this._planes=new Array(6),this._maxSpan=0,this._center={origin:p(),direction:p()},this._renderCoordsHelper=t.renderCoordsHelper;for(let e=0;e<4;e++)this._extent[e]={origin:p(),direction:p(),cap:{next:null,direction:p()}},this._planes[e]=b();this._planes[4]=b(),this._planes[5]=b(),this._planesWithoutFar=this._planes.slice(0,5)}update(t,e,i,r=!0){const a=this._extent;this._toRenderBoundingExtent(t,e,i),n(this._center.origin,a[0].origin,a[2].origin),o(this._center.origin,this._center.origin,.5),this._renderCoordsHelper.worldUpAtPosition(this._center.origin,this._center.direction),r||o(this._center.direction,this._center.direction,-1);for(let n=0;n<4;n++){const t=a[n];this._renderCoordsHelper.worldUpAtPosition(t.origin,t.direction);const e=a[3===n?0:n+1];t.cap.next=e.origin,s(t.cap.direction,t.origin,e.origin),S(t.direction,t.cap.direction,t.origin,this._planes[n]),r||o(t.direction,t.direction,-1)}S(a[0].cap.direction,a[1].cap.direction,a[0].origin,this._planes[4]),r?B(this._planes[4],this._planes[5]):(C(this._planes[5],this._planes[4]),B(this._planes[4],this._planes[4])),this._maxSpan=Math.max(Math.abs(t[0]-t[2]),Math.abs(t[1]-t[3])),this._maxSpanSpatialReference=e,this._minGlobalAltitude=.9*h(this._maxSpanSpatialReference).radius}isVisibleInFrustum(t,e,i=!1){if(null==t)return!1;if(1===this._renderCoordsHelper.viewingMode){const i=this._maxSpanSpatialReference.isGeographic?G:A*e;if(this._maxSpan>i)return!0;if(null!=t.altitude&&t.altitude>=this._minGlobalAltitude)return this._isVisibleInFrustumGlobal(t)}if(0===this._maxSpan){const e=this._extent[0];return!(i||!t.intersectsRay(w(e.origin,e.direction)))}for(let n=0;n<this._extent.length;n++){const e=this._extent[n];if(!i&&t.intersectsRay(w(e.origin,e.direction)))return!0;if(t.intersectsLineSegment(j(e.origin,e.cap.next,k),e.cap.direction))return!0}const r=i?this._planes:this._planesWithoutFar;for(let n=0;n<t.lines.length;n++){const e=t.lines[n];if(M(r,e.origin,e.endpoint,e.direction))return!0}return!1}_toRenderBoundingExtentGlobal(t,r,n){const o=5;u(t,v),v[2]=n,d(r,v,F,this._renderCoordsHelper.spatialReference),i(I,F),g(V);for(const{x0:i,x1:s,y0:c,y1:l}of U)for(let p=0;p<o;p++){const h=p/(o-1);v[0]=e(t[i],t[s],h),v[1]=e(t[c],t[l],h),v[2]=n,m(v,r,v,this._renderCoordsHelper.spatialReference),a(v,v,I),f(V,v)}c(this._extent[0].origin,V[0],V[1],V[2]),c(this._extent[1].origin,V[3],V[1],V[2]),c(this._extent[2].origin,V[3],V[4],V[2]),c(this._extent[3].origin,V[0],V[4],V[2]);for(let e=0;e<4;++e)a(this._extent[e].origin,this._extent[e].origin,F)}_toRenderBoundingExtentLocal(t,e,i){_(t,e,P,this._renderCoordsHelper.spatialReference),c(this._extent[0].origin,P[0],P[1],i),c(this._extent[1].origin,P[2],P[1],i),c(this._extent[2].origin,P[2],P[3],i),c(this._extent[3].origin,P[0],P[3],i)}_toRenderBoundingExtent(e,i,r){switch(this._renderCoordsHelper.viewingMode){case 1:this._toRenderBoundingExtentGlobal(e,i,r);break;case 2:this._toRenderBoundingExtentLocal(e,i,r);break;default:t(this._renderCoordsHelper.viewingMode)}}_isVisibleInFrustumGlobal(t){if(H(t.planes[4],this._center.origin)<0&&l(this._center.direction,t.direction)<0)return!0;for(let e=0;e<4;e++){const i=this._extent[e];if(H(t.planes[4],i.origin)<0&&l(i.direction,t.direction)<0)return!0}return!1}}const U=[{x0:0,y0:1,x1:2,y1:1},{x0:0,y0:3,x1:2,y1:3},{x0:0,y0:1,x1:0,y1:3},{x0:2,y0:1,x1:2,y1:3}],v=p(),F=r(),I=r(),V=x(),P=y(),k=R();export{E as FrustumExtentIntersection};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import e from"../../../Camera.js";import t from"../../../core/Logger.js";import{deg2rad as n,rad2deg as r,asinClamped as i}from"../../../core/mathUtils.js";import{throwIfAborted as a}from"../../../core/promiseUtils.js";import{d as o,D as c,H as s,b as l}from"../../../chunks/vec32.js";import{create as u,clone as f}from"../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getReferenceEllipsoid as m}from"../../../geometry/ellipsoidUtils.js";import p from"../../../geometry/Point.js";import{projectAsync as d,project as h}from"../../../geometry/projectionUtils.js";import g from"../../../geometry/SpatialReference.js";import{projectPointToVectorAsync as y,projectPointToVector as v}from"../../../geometry/projection/projectPointToVector.js";import{projectVectorToPointAsync as R,projectVectorToPoint as w}from"../../../geometry/projection/projectVectorToPoint.js";import{gcsCyclical as x,webMercatorCyclical as M}from"../../../geometry/support/normalizeUtils.js";import{toRenderCamera as j}from"../webgl.js";import{getGreatCircleSpanAt as T}from"./earthUtils.js";import{getElevationAtPoint as z}from"./ElevationProvider.js";import{viewModeDependentUtil as S,directionToHeadingTilt as C}from"./viewingModeUtils.js";import{isSpatialReferenceSupported as b}from"../../support/spatialReferenceSupport.js";const P=()=>t.getLogger("esri.views.3d.support.cameraUtils"),A=96*39.37,L=1,U=8,H=5,q=1,I=u();function E(e){return e.spatialReference??g.WGS84}function F(e,t,n,r,i){return S(e).headingTiltToDirectionUp(t,n,r,i)}function G(e,t){const{camera:n}=e.state,{unitInMeters:r}=e.renderCoordsHelper;t/=r;return n.width/2/n.pixelRatio/(A/t)/Math.tan(n.fovX/2)}function D(e,t){const{camera:n}=e.state,{unitInMeters:r}=e.renderCoordsHelper,i=t*Math.tan(n.fovX/2),a=n.width/2/n.pixelRatio;return A/(a/i)*r}function O(e,t,n,r){const i=r.levelAtScale(t),a=k(C(e,n.eye,n.viewForward,n.up).tilt),o=Math.max(i-a,0);return r.scaleAtLevel(o)}function X(e,t,n){const r=n.levelAtScale(e),i=k(t);return n.scaleAtLevel(r+i)}function k(e){return 2*((e>90?180-e:e)/90)**2}function V(e,t,n=0){const r=e.basemapTerrain?.tilingScheme;if(!r)return 0;const i=m(e.spatialReference).radius,a=2===e.state.viewingMode?t.eye[2]:l(t.eye)-i;return O(e,D(e,Math.abs(a-n)),t,r)}function W(e,t,n=0){const r=j(e,t);return r?V(e,r,n):0}const Y=1,N=100;function Z(e,t,a,o){if(0===t)return 0;const s=e.state.contentCamera,u=c(s.eye,a),f=e.basemapTerrain?.tilingScheme;if(!f)return P().error("#scaleToTargetDistance()","Cannot compute distance from scale without a tiling scheme"),u;let p=u;const d=C(e,s.eye,s.viewForward,s.up),h=d.tilt>90;if(e.state.isLocal){const r=(G(e,X(t,d.tilt,f))-Math.abs(s.eye[2]-o[2]))/Math.cos(n(d.tilt));return p=h?p-r:p+r,p}let g=1/0,y=0,v=te(e,d.heading,d.tilt,a,u,1);if(!v)return p;const R=l(o);for(;g>Y&&y<N;){const o=l(v.eye),u=h?180-v.tilt:v.tilt,w=n(u),x=Math.sin(w)*o,M=Math.cos(w)*o,j=G(e,X(t,v.tilt,f)),T=h?R-j:R+j,z=i(x/T),S=Math.cos(z)*T-M,C=c(v.eye,a);p=h?C-S:C+S,v=te(e,d.heading,d.tilt,a,p,1);const b=Me(e,v,r(s.fov));if(!v||!b)return p;const P=W(e,b,R-m(e.spatialReference).radius);g=Math.abs(t-P),++y}return p}async function B(e,t,n,r,i,a){return K(e,t,G(e,n),r,i,a)}function J(e,t,n,r,i,a){return Me(e,te(e,r.heading,r.tilt,t,n,i),r.fov,a)}async function K(e,t,n,r,i,o){const c=await ne(e,r.heading,r.tilt,t,n,i,o);return a(o),je(e,c,r.fov,o)}function Q(e,t){return!!(e.basemapTerrain&&e.renderCoordsHelper.fromRenderCoords(t,I,e.spatialReference)&&e.elevationProvider&&(z(e.elevationProvider,I)??0)>I[2]-q)}async function $(e,t,n){if(Q(e,t))return!0;const{elevationProvider:r,spatialReference:i,renderCoordsHelper:o}=e;if(null==r||!o.fromRenderCoords(t,I,i))return!1;const[c,s,l]=I,u=await r.queryElevation(c,s,l,i,"ground",n)??0;return a(n),u>l-q}async function _(e,t,n){const r=u();if(null==t)return o(r,e.state.camera.center);if(t instanceof p){const{renderSpatialReference:i,basemapTerrain:o,elevationProvider:c}=e,s=t.spatialReference;if(await y(t,r,i,{signal:n}),a(n),null==t.z&&null!=o&&null!=c){const i=await c.queryElevation(t.x,t.y,t.z??0,s,"ground",n);a(n),null!=i&&e.renderCoordsHelper.setAltitude(r,i)}return r}return o(r,t)}function ee(e,t){const n=u();if(null==t)return o(n,e.state.camera.center);if(t instanceof p){if(!v(t,n,e.renderSpatialReference))return null;const{basemapTerrain:r,elevationProvider:i}=e;if(null==t.z&&null!=r&&null!=i){const r=z(i,t);null!=r&&e.renderCoordsHelper.setAltitude(n,r)}return n}return o(n,t)}function te(e,t,n,r,i,a){return re(e,t,n,r instanceof p?r:null,ee(e,r),i,a)}async function ne(e,t,n,r,i,o,c){const s=r instanceof p?r:null,l=await _(e,r,c);return a(c),ie(e,t,n,s,l,i,o,c)}function re(e,t,n,r,i,a,o){if(null==i)return null;if(!r&&(r=new p({spatialReference:E(e)}),!w(i,e.renderSpatialReference,r)))return null;const c=ae(e,t,n,i,a,o);if(oe(e,n,o)&&Q(e,c.eye)){const{tilt:o,mode:c}=ce(e,n,i,a);return re(e,t,o,r,i,a,c)}return se(c,i)}async function ie(e,t,n,r,i,o,c,s){r||(r=new p({spatialReference:E(e)}),await R(i,e.renderSpatialReference,r,{signal:s})||(r=null)),a(s);const l=ae(e,t,n,i,o,c);if(oe(e,n,c)&&await $(e,l.eye,s)){a(s);const{tilt:c,mode:l}=ce(e,n,i,o);return ie(e,t,c,r,i,o,l,s)}return se(l,i)}function ae(e,t,n,r,i,a){const o=ge(e,t,n,r,i=Math.max(i,e.state.constraints.minimumPoiDistance),a);return(0,S(e).eyeForCenterWithHeadingTilt)(r,i,o.heading,o.tilt)}function oe(e,t,n){const r=e.map.ground.navigationConstraint;return 1===n&&e.state.isGlobal&&t>0&&(null==r||"stay-above"===r.type)}function ce(e,t,n,r){const i=we(e,n,r,Re(e,r,t,n));return{tilt:i,mode:t-i<1?0:1}}function se(e,t){return{...e,center:f(t)}}function le(e,t){const{state:n,spatialReference:r}=e,i=t.spatialReference;return n.isGlobal&&b(i,1)||n.isLocal&&r.equals(i)}function ue(e,t){let n,r,i;if(e.state.isGlobal){const e=new p(t.xmin,t.ymin,t.spatialReference),a=new p(t.xmax,t.ymax,t.spatialReference),o=t.spatialReference.isGeographic?x:M;n=new p({x:o.center(e.x,a.x),y:(a.y+e.y)/2,z:null!=t.zmax&&null!=t.zmin?(t.zmax+t.zmin)/2:void 0,spatialReference:t.spatialReference});const c=m(t.spatialReference),s=T(n,e,a);r=s.lon,i=s.lat,o.diff(e.x,a.x)>o.range/2&&(r+=c.halfCircumference),r=Math.min(r,c.halfCircumference),i=Math.min(i,c.halfCircumference)}else{const a=e.renderSpatialReference??t.spatialReference;a.equals(t.spatialReference)||(t=h(t,a)),r=t.xmax-t.xmin,i=t.ymax-t.ymin;const o=null!=t.zmax&&null!=t.zmin?(t.zmax+t.zmin)/2:void 0;n=new p({x:t.xmin+.5*r,y:t.ymin+.5*i,z:o,spatialReference:a})}const a=null!=t.zmax&&null!=t.zmin?t.zmax-t.zmin:0,o=e.state.camera,c=1/Math.tan(o.fovX/2),s=1/Math.tan(o.fovY/2),l=1/Math.tan(o.fov/2);return{center:n,distance:Math.max(.5*r*c,.5*i*s,.5*a*l)/L}}async function fe(e,t,n,r,i,o){const c=le(e,t)?t:await d(t,e.spatialReference,{signal:o});a(o);const{center:s,distance:l}=ue(e,c),u=await ne(e,n,r,s,l,i,o);return a(o),je(e,u,e.camera.fov,o)}function me(e,t,n,r,i,a){let o;try{o=le(e,t)?t:h(t,e.spatialReference)}catch(u){return null}const{center:c,distance:s}=ue(e,o),l=te(e,n,r,c,s,i);return null==l?null:Me(e,l,e.camera.fov,a)}function pe(e,t,n){const r=e.renderSpatialReference,i=new p({spatialReference:E(e)});if(!w(n,r,i))return null;const a=Math.tan(t.fovX/2),o=Math.tan(t.fovY/2),c=s(t.eye,n),l=2*c*a*L,u=2*c*o*L;return S(e).toExtent(e,i,l,u)}function de(e,t){return S(e).toArea(e,t)}function he(e,t,n){const r=e.pointsOfInterest.centerOnSurfaceFrequent.distance;if(Math.log(n/r)/Math.LN2>U)return!0;const i=t,a=e.pointsOfInterest.centerOnSurfaceFrequent.renderLocation;return c(i,a)/(Math.tan(.5*e.state.camera.fov)*r)>H}function ge(e,t,n,r,i,a){let o=0;return 1===a&&he(e,r,i)?(t=0,o=ve(e,i,n,r)):o=xe(e,r,i,n),o=e.state.constraints.clampTilt(i,o),{heading:t,tilt:n=we(e,r,i,o)}}const ye=.7;function ve(e,t,n,r){const i=xe(e,r,t,n);if(!e.state.constraints.tilt)return i;const a=e.state.constraints.tilt(t);a.max=Math.min(a.max,.5*Math.PI);const o=a.min*(1-ye)+a.max*ye;return Math.min(i,o)}function Re(e,t,n,r){let i=xe(e,r,t,n);if(!e.state.constraints.tilt)return i;const a=e.state.constraints.tilt(t);return i=Math.min(i,.5*Math.PI),a.min*(1-ye)+i*ye}function we(e,t,n,r){return S(e).lookAtTiltToEyeTilt(r,t,n)}function xe(e,t,n,r){return S(e).eyeTiltToLookAtTilt(r,t,n)}function Me(t,n,r,i){if(null==n)return null;const a=t.renderSpatialReference,o=new p({spatialReference:E(t)});return w(n.eye,a,o)?(i??=new e,i.position=o,i.heading=n.heading,i.tilt=n.tilt,i.fov=r,i):null}async function je(t,n,r,i){const o=t.renderSpatialReference,c=new p({spatialReference:E(t)});return await R(n.eye,o,c,{signal:i}),a(i),new e(c,n.heading,n.tilt,r)}function Te(e,t){const n=e.basemapTerrain?.tilingScheme;if(n)return n.levelAtScale(t);P().error("#scaleToZoom()","Cannot compute zoom from scale without a tiling scheme")}function ze(e,t){const n=e.basemapTerrain?.tilingScheme;if(n)return n.scaleAtLevel(t);P().error("#zoomToScale()","Cannot compute scale from zoom without a tiling scheme")}export{O as applyTiltAdjustToScale,D as distanceToScale,K as fromCenterDistanceAsync,J as fromCenterDistanceSync,B as fromCenterScale,fe as fromExtentAsync,me as fromExtentSync,ne as getObserverForPointAtDistanceAsync,te as getObserverForPointAtDistanceSync,E as getViewSR,F as headingTiltToDirectionUp,X as removeTiltAdjustFromScale,Y as scaleErrorThreshold,G as scaleToDistance,Te as scaleToZoom,de as toArea,pe as toExtent,Z as viewScaleToCameraDistance,ze as zoomToScale};
5
+ import e from"../../../Camera.js";import t from"../../../core/Logger.js";import{deg2rad as n,rad2deg as r,asinClamped as i}from"../../../core/mathUtils.js";import{throwIfAborted as a}from"../../../core/promiseUtils.js";import{d as o,B as c,F as s,b as l}from"../../../chunks/vec32.js";import{create as u,clone as f}from"../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getReferenceEllipsoid as m}from"../../../geometry/ellipsoidUtils.js";import p from"../../../geometry/Point.js";import{projectAsync as d,project as h}from"../../../geometry/projectionUtils.js";import g from"../../../geometry/SpatialReference.js";import{projectPointToVectorAsync as y,projectPointToVector as v}from"../../../geometry/projection/projectPointToVector.js";import{projectVectorToPointAsync as R,projectVectorToPoint as w}from"../../../geometry/projection/projectVectorToPoint.js";import{gcsCyclical as x,webMercatorCyclical as M}from"../../../geometry/support/normalizeUtils.js";import{toRenderCamera as j}from"../webgl.js";import{getGreatCircleSpanAt as T}from"./earthUtils.js";import{getElevationAtPoint as z}from"./ElevationProvider.js";import{viewModeDependentUtil as S,directionToHeadingTilt as C}from"./viewingModeUtils.js";import{isSpatialReferenceSupported as b}from"../../support/spatialReferenceSupport.js";const P=()=>t.getLogger("esri.views.3d.support.cameraUtils"),A=96*39.37,L=1,U=8,H=5,q=1,F=u();function I(e){return e.spatialReference??g.WGS84}function E(e,t,n,r,i){return S(e).headingTiltToDirectionUp(t,n,r,i)}function G(e,t){const{camera:n}=e.state,{unitInMeters:r}=e.renderCoordsHelper;t/=r;return n.width/2/n.pixelRatio/(A/t)/Math.tan(n.fovX/2)}function O(e,t){const{camera:n}=e.state,{unitInMeters:r}=e.renderCoordsHelper,i=t*Math.tan(n.fovX/2),a=n.width/2/n.pixelRatio;return A/(a/i)*r}function X(e,t,n,r){const i=r.levelAtScale(t),a=D(C(e,n.eye,n.viewForward,n.up).tilt),o=Math.max(i-a,0);return r.scaleAtLevel(o)}function k(e,t,n){const r=n.levelAtScale(e),i=D(t);return n.scaleAtLevel(r+i)}function D(e){return 2*((e>90?180-e:e)/90)**2}function V(e,t,n=0){const r=e.basemapTerrain?.tilingScheme;if(!r)return 0;const i=m(e.spatialReference).radius,a=2===e.state.viewingMode?t.eye[2]:l(t.eye)-i;return X(e,O(e,Math.abs(a-n)),t,r)}function W(e,t,n=0){const r=j(e,t);return r?V(e,r,n):0}const Y=1,B=100;function N(e,t,a,o){if(0===t)return 0;const s=e.state.contentCamera,u=c(s.eye,a),f=e.basemapTerrain?.tilingScheme;if(!f)return P().error("#scaleToTargetDistance()","Cannot compute distance from scale without a tiling scheme"),u;let p=u;const d=C(e,s.eye,s.viewForward,s.up),h=d.tilt>90;if(e.state.isLocal){const r=(G(e,k(t,d.tilt,f))-Math.abs(s.eye[2]-o[2]))/Math.cos(n(d.tilt));return p=h?p-r:p+r,p}let g=1/0,y=0,v=te(e,d.heading,d.tilt,a,u,1);if(!v)return p;const R=l(o);for(;g>Y&&y<B;){const o=l(v.eye),u=h?180-v.tilt:v.tilt,w=n(u),x=Math.sin(w)*o,M=Math.cos(w)*o,j=G(e,k(t,v.tilt,f)),T=h?R-j:R+j,z=i(x/T),S=Math.cos(z)*T-M,C=c(v.eye,a);p=h?C-S:C+S,v=te(e,d.heading,d.tilt,a,p,1);const b=Me(e,v,r(s.fov));if(!v||!b)return p;const P=W(e,b,R-m(e.spatialReference).radius);g=Math.abs(t-P),++y}return p}async function Z(e,t,n,r,i,a){return K(e,t,G(e,n),r,i,a)}function J(e,t,n,r,i,a){return Me(e,te(e,r.heading,r.tilt,t,n,i),r.fov,a)}async function K(e,t,n,r,i,o){const c=await ne(e,r.heading,r.tilt,t,n,i,o);return a(o),je(e,c,r.fov,o)}function Q(e,t){return!!(e.basemapTerrain&&e.renderCoordsHelper.fromRenderCoords(t,F,e.spatialReference)&&e.elevationProvider&&(z(e.elevationProvider,F)??0)>F[2]-q)}async function $(e,t,n){if(Q(e,t))return!0;const{elevationProvider:r,spatialReference:i,renderCoordsHelper:o}=e;if(null==r||!o.fromRenderCoords(t,F,i))return!1;const[c,s,l]=F,u=await r.queryElevation(c,s,l,i,"ground",n)??0;return a(n),u>l-q}async function _(e,t,n){const r=u();if(null==t)return o(r,e.state.camera.center);if(t instanceof p){const{renderSpatialReference:i,basemapTerrain:o,elevationProvider:c}=e,s=t.spatialReference;if(await y(t,r,i,{signal:n}),a(n),null==t.z&&null!=o&&null!=c){const i=await c.queryElevation(t.x,t.y,t.z??0,s,"ground",n);a(n),null!=i&&e.renderCoordsHelper.setAltitude(r,i)}return r}return o(r,t)}function ee(e,t){const n=u();if(null==t)return o(n,e.state.camera.center);if(t instanceof p){if(!v(t,n,e.renderSpatialReference))return null;const{basemapTerrain:r,elevationProvider:i}=e;if(null==t.z&&null!=r&&null!=i){const r=z(i,t);null!=r&&e.renderCoordsHelper.setAltitude(n,r)}return n}return o(n,t)}function te(e,t,n,r,i,a){return re(e,t,n,r instanceof p?r:null,ee(e,r),i,a)}async function ne(e,t,n,r,i,o,c){const s=r instanceof p?r:null,l=await _(e,r,c);return a(c),ie(e,t,n,s,l,i,o,c)}function re(e,t,n,r,i,a,o){if(null==i)return null;if(!r&&(r=new p({spatialReference:I(e)}),!w(i,e.renderSpatialReference,r)))return null;const c=ae(e,t,n,i,a,o);if(oe(e,n,o)&&Q(e,c.eye)){const{tilt:o,mode:c}=ce(e,n,i,a);return re(e,t,o,r,i,a,c)}return se(c,i)}async function ie(e,t,n,r,i,o,c,s){r||(r=new p({spatialReference:I(e)}),await R(i,e.renderSpatialReference,r,{signal:s})||(r=null)),a(s);const l=ae(e,t,n,i,o,c);if(oe(e,n,c)&&await $(e,l.eye,s)){a(s);const{tilt:c,mode:l}=ce(e,n,i,o);return ie(e,t,c,r,i,o,l,s)}return se(l,i)}function ae(e,t,n,r,i,a){const o=ge(e,t,n,r,i=Math.max(i,e.state.constraints.minimumPoiDistance),a);return(0,S(e).eyeForCenterWithHeadingTilt)(r,i,o.heading,o.tilt)}function oe(e,t,n){const r=e.map.ground.navigationConstraint;return 1===n&&e.state.isGlobal&&t>0&&(null==r||"stay-above"===r.type)}function ce(e,t,n,r){const i=we(e,n,r,Re(e,r,t,n));return{tilt:i,mode:t-i<1?0:1}}function se(e,t){return{...e,center:f(t)}}function le(e,t){const{state:n,spatialReference:r}=e,i=t.spatialReference;return n.isGlobal&&b(i,1)||n.isLocal&&r.equals(i)}function ue(e,t){let n,r,i;if(e.state.isGlobal){const e=new p(t.xmin,t.ymin,t.spatialReference),a=new p(t.xmax,t.ymax,t.spatialReference),o=t.spatialReference.isGeographic?x:M;n=new p({x:o.center(e.x,a.x),y:(a.y+e.y)/2,z:null!=t.zmax&&null!=t.zmin?(t.zmax+t.zmin)/2:void 0,spatialReference:t.spatialReference});const c=m(t.spatialReference),s=T(n,e,a);r=s.lon,i=s.lat,o.diff(e.x,a.x)>o.range/2&&(r+=c.halfCircumference),r=Math.min(r,c.halfCircumference),i=Math.min(i,c.halfCircumference)}else{const a=e.renderSpatialReference??t.spatialReference;a.equals(t.spatialReference)||(t=h(t,a)),r=t.xmax-t.xmin,i=t.ymax-t.ymin;const o=null!=t.zmax&&null!=t.zmin?(t.zmax+t.zmin)/2:void 0;n=new p({x:t.xmin+.5*r,y:t.ymin+.5*i,z:o,spatialReference:a})}const a=null!=t.zmax&&null!=t.zmin?t.zmax-t.zmin:0,o=e.state.camera,c=1/Math.tan(o.fovX/2),s=1/Math.tan(o.fovY/2),l=1/Math.tan(o.fov/2);return{center:n,distance:Math.max(.5*r*c,.5*i*s,.5*a*l)/L}}async function fe(e,t,n,r,i,o){const c=le(e,t)?t:await d(t,e.spatialReference,{signal:o});a(o);const{center:s,distance:l}=ue(e,c),u=await ne(e,n,r,s,l,i,o);return a(o),je(e,u,e.camera.fov,o)}function me(e,t,n,r,i,a){let o;try{o=le(e,t)?t:h(t,e.spatialReference)}catch(u){return null}const{center:c,distance:s}=ue(e,o),l=te(e,n,r,c,s,i);return null==l?null:Me(e,l,e.camera.fov,a)}function pe(e,t,n){const r=e.renderSpatialReference,i=new p({spatialReference:I(e)});if(!w(n,r,i))return null;const a=Math.tan(t.fovX/2),o=Math.tan(t.fovY/2),c=s(t.eye,n),l=2*c*a*L,u=2*c*o*L;return S(e).toExtent(e,i,l,u)}function de(e,t){return S(e).toArea(e,t)}function he(e,t,n){const r=e.pointsOfInterest.centerOnSurfaceFrequent.distance;if(Math.log(n/r)/Math.LN2>U)return!0;const i=t,a=e.pointsOfInterest.centerOnSurfaceFrequent.renderLocation;return c(i,a)/(Math.tan(.5*e.state.camera.fov)*r)>H}function ge(e,t,n,r,i,a){let o=0;return 1===a&&he(e,r,i)?(t=0,o=ve(e,i,n,r)):o=xe(e,r,i,n),o=e.state.constraints.clampTilt(i,o),{heading:t,tilt:n=we(e,r,i,o)}}const ye=.7;function ve(e,t,n,r){const i=xe(e,r,t,n);if(!e.state.constraints.tilt)return i;const a=e.state.constraints.tilt(t);a.max=Math.min(a.max,.5*Math.PI);const o=a.min*(1-ye)+a.max*ye;return Math.min(i,o)}function Re(e,t,n,r){let i=xe(e,r,t,n);if(!e.state.constraints.tilt)return i;const a=e.state.constraints.tilt(t);return i=Math.min(i,.5*Math.PI),a.min*(1-ye)+i*ye}function we(e,t,n,r){return S(e).lookAtTiltToEyeTilt(r,t,n)}function xe(e,t,n,r){return S(e).eyeTiltToLookAtTilt(r,t,n)}function Me(t,n,r,i){if(null==n)return null;const a=t.renderSpatialReference,o=new p({spatialReference:I(t)});return w(n.eye,a,o)?(i??=new e,i.position=o,i.heading=n.heading,i.tilt=n.tilt,i.fov=r,i):null}async function je(t,n,r,i){const o=t.renderSpatialReference,c=new p({spatialReference:I(t)});return await R(n.eye,o,c,{signal:i}),a(i),new e(c,n.heading,n.tilt,r)}function Te(e,t){const n=e.basemapTerrain?.tilingScheme;if(n)return n.levelAtScale(t);P().error("#scaleToZoom()","Cannot compute zoom from scale without a tiling scheme")}function ze(e,t){const n=e.basemapTerrain?.tilingScheme;if(n)return n.scaleAtLevel(t);P().error("#zoomToScale()","Cannot compute scale from zoom without a tiling scheme")}export{X as applyTiltAdjustToScale,O as distanceToScale,K as fromCenterDistanceAsync,J as fromCenterDistanceSync,Z as fromCenterScale,fe as fromExtentAsync,me as fromExtentSync,ne as getObserverForPointAtDistanceAsync,te as getObserverForPointAtDistanceSync,I as getViewSR,E as headingTiltToDirectionUp,k as removeTiltAdjustFromScale,Y as scaleErrorThreshold,G as scaleToDistance,Te as scaleToZoom,de as toArea,pe as toExtent,N as viewScaleToCameraDistance,ze as zoomToScale};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{set as t,dist as e}from"../../../../core/libs/gl-matrix-2/math/vec2.js";import{create as r}from"../../../../core/libs/gl-matrix-2/factories/vec2f64.js";import{ONES as o}from"../../../../core/libs/gl-matrix-2/factories/vec4f64.js";import{getReferenceEllipsoid as n}from"../../../../geometry/ellipsoidUtils.js";import{lonLatToWebMercatorComparable as i}from"../../../../geometry/projection/projectors.js";import{newDoubleArray as a}from"../../../../geometry/support/DoubleArray.js";import{newFloatArray as u}from"../../../../geometry/support/FloatArray.js";import{newHalfFloatArray as s}from"../../../../geometry/support/HalfFloatArray.js";import{getZeroIndexArray as l}from"../../../../geometry/support/Indices.js";import{Attribute as c}from"../../webgl-engine/lib/Attribute.js";import{Geometry as p}from"../../webgl-engine/lib/Geometry.js";function f(t,e,r=null){const o=[],n=e.mapPositions,i=m(e,o),a=i.data,u=i.indices.length,s=l(u);return h(e,o,s),y(e,o,s),g(e,o,s),b(e,o,i.indices,s),w(e,o,i.indices,s),D(e,o),F(e,o,i.indices,s),d(e,o,a),new p(t,o,n,2,r)}function m(t,e){const{attributeData:{position:r},removeDuplicateStartEnd:o}=t,n=j(r)&&o,i=r.length/3-(n?1:0),a=new Array(2*(i-1)),u=n?r.slice(0,-3):r;let s=0;for(let c=0;c<i-1;c++)a[s++]=c,a[s++]=c+1;const l=new c(u,a,3,n);return e.push(["position",l]),l}function h(t,e,r){if(null!=t.attributeData.colorFeature)return;const n=t.attributeData.color;e.push(["color",new c(n??o,r,4)])}function g(t,e,r){t.attributeData.normal&&e.push(["normal",new c(t.attributeData.normal,r,3)])}function b(t,e,r,o){const n=t.attributeData.colorFeature;null!=n&&("number"==typeof n?e.push(["colorFeatureAttribute",new c([n],o,1,!0)]):e.push(["colorFeatureAttribute",new c(n,r,1,!0)]))}function y(t,e,r){null==t.attributeData.sizeFeature&&e.push(["size",new c([t.attributeData.size??1],r,1,!0)])}function w(t,e,r,o){const n=t.attributeData.sizeFeature;null!=n&&("number"==typeof n?e.push(["sizeFeatureAttribute",new c([n],o,1,!0)]):e.push(["sizeFeatureAttribute",new c(n,r,1,!0)]))}function D(t,e){const{attributeData:{position:r,timeStamps:o}}=t;if(!o)return;const n=r.length/3,i=new Array(2*(n-1));let a=0;for(let u=0;u<n-1;u++)i[a++]=u,i[a++]=u+1;e.push(["timeStamps",new c(o,i,z,!0)])}function F(t,e,r,o){const n=t.attributeData.opacityFeature;null!=n&&("number"==typeof n?e.push(["opacityFeatureAttribute",new c([n],o,1,!0)]):e.push(["opacityFeatureAttribute",new c(n,r,1,!0)]))}function d(r,o,s){if(null==r.overlayInfo||1!==r.overlayInfo.renderCoordsHelper.viewingMode||!r.overlayInfo.spatialReference.isGeographic)return;const l=a(s.length),p=n(r.overlayInfo.spatialReference);for(let t=0;t<l.length;t+=3)i(s,t,l,t,p);const f=s.length/3,m=u(f+1);let h=A,g=v,b=0,y=0;t(h,l[y++],l[y++]),y++,m[0]=0;for(let n=1;n<f+1;++n)n===f&&(y=0),t(g,l[y++],l[y++]),y++,b+=e(h,g),m[n]=b,[h,g]=[g,h];o.push(["distanceToStart",new c(m,o[0][1].indices,1,!0)])}function j(t){const e=t.length;return t[0]===t[e-3]&&t[1]===t[e-2]&&t[2]===t[e-1]}const A=r(),v=r(),z=4;function S(t,e,r,o,n){if(null==t||0===t.length)return[];const i=[];return t.forEach((t,u)=>{const s=t.length,l=a(3*s);t.forEach((t,e)=>{l[3*e]=t[0],l[3*e+1]=t[1],l[3*e+2]=t[2]});const c={attributeData:{position:l,normal:e,colorFeature:r?.[u],opacityFeature:o?.[u],sizeFeature:n?.[u]},removeDuplicateStartEnd:!1};i.push(c)}),i}function E(t,e,r,o,n,i){if(null==t||0===t.length)return[];const a=S(t,e,o,n,i);return t.forEach((t,e)=>{const o=r?.[e],n=null!=o?x(o.timeStamps,o.streamlineType):void 0;a[e].attributeData.timeStamps=n}),a}function I(t,e=0,r=.01){const o=s(t.length);o[0]=0;for(let i=1;i<t.length;i++){const e=t[i-1],r=t[i],n=Math.sqrt((r[0]-e[0])**2+(r[1]-e[1])**2+(r[2]-e[2])**2);o[i]=o[i-1]+n}const n=o.map(t=>t*r);if(0!==e&&e<n.length){const t=n[e];for(let e=0;e<n.length;e++)n[e]-=t}return n}function x(t,e){const r=s(t.length*z),o=t[0],n=t[t.length-1];for(let i=0;i<t.length;i++)r[i*z]=t[i],r[i*z+1]=o,r[i*z+2]=n,r[i*z+3]=e+.5;return r}export{E as animatedLineStripsToParameters,f as createGeometry,I as getLinearTimeStamps,S as lineStripsToParameters,z as numTimeStampValuesPerVertex,x as timeStampsToAttribute};
5
+ import{set as t,dist as e}from"../../../../core/libs/gl-matrix-2/math/vec2.js";import{create as r}from"../../../../core/libs/gl-matrix-2/factories/vec2f64.js";import{ONES as o}from"../../../../core/libs/gl-matrix-2/factories/vec4f64.js";import{getReferenceEllipsoid as n}from"../../../../geometry/ellipsoidUtils.js";import{lonLatToWebMercatorComparable as i}from"../../../../geometry/projection/projectors.js";import{newDoubleArray as a}from"../../../../geometry/support/DoubleArray.js";import{newFloatArray as u}from"../../../../geometry/support/FloatArray.js";import{newHalfFloatArray as s}from"../../../../geometry/support/HalfFloatArray.js";import{getZeroIndexArray as l}from"../../../../geometry/support/Indices.js";import{Attribute as c}from"../../webgl-engine/lib/Attribute.js";import{Geometry as p}from"../../webgl-engine/lib/Geometry.js";function f(t,e,r=null){const o=[],n=e.mapPositions,i=m(e,o),a=i.data,u=i.indices.length,s=l(u);return h(e,o,s),y(e,o,s),g(e,o,s),b(e,o,i.indices,s),w(e,o,i.indices,s),D(e,o),F(e,o,i.indices,s),d(e,o,a),new p(t,o,n,2,r)}function m(t,e){const{attributeData:{position:r},removeDuplicateStartEnd:o}=t,n=j(r)&&o,i=r.length/3-(n?1:0),a=new Array(2*(i-1)),u=n?r.slice(0,-3):r;let s=0;for(let c=0;c<i-1;c++)a[s++]=c,a[s++]=c+1;const l=new c(u,a,3,n);return e.push(["position",l]),l}function h(t,e,r){if(null!=t.attributeData.colorFeature)return;const n=t.attributeData.color;e.push(["color",new c(n??o,r,4)])}function g(t,e,r){t.attributeData.normal&&e.push(["normal",new c(t.attributeData.normal,r,3)])}function b(t,e,r,o){const n=t.attributeData.colorFeature;null!=n&&("number"==typeof n?e.push(["colorFeatureAttribute",new c([n],o,1,!0)]):e.push(["colorFeatureAttribute",new c(n,r,1,!0)]))}function y(t,e,r){null==t.attributeData.sizeFeature&&e.push(["size",new c([t.attributeData.size??1],r,1,!0)])}function w(t,e,r,o){const n=t.attributeData.sizeFeature;null!=n&&("number"==typeof n?e.push(["sizeFeatureAttribute",new c([n],o,1,!0)]):e.push(["sizeFeatureAttribute",new c(n,r,1,!0)]))}function D(t,e){const{attributeData:{position:r,timeStamps:o}}=t;if(!o)return;const n=r.length/3,i=new Array(2*(n-1));let a=0;for(let u=0;u<n-1;u++)i[a++]=u,i[a++]=u+1;e.push(["timeStamps",new c(o,i,z,!0)])}function F(t,e,r,o){const n=t.attributeData.opacityFeature;null!=n&&("number"==typeof n?e.push(["opacityFeatureAttribute",new c([n],o,1,!0)]):e.push(["opacityFeatureAttribute",new c(n,r,1,!0)]))}function d(r,o,s){if(null==r.overlayInfo||1!==r.overlayInfo.renderCoordsHelper.viewingMode||!r.overlayInfo.spatialReference.isGeographic)return;const l=a(s.length),p=n(r.overlayInfo.spatialReference);for(let t=0;t<l.length;t+=3)i(s,t,l,t,p);const f=s.length/3,m=u(f+1);let h=A,g=v,b=0,y=0;t(h,l[y++],l[y++]),y++,m[0]=0;for(let n=1;n<f+1;++n)n===f&&(y=0),t(g,l[y++],l[y++]),y++,b+=e(h,g),m[n]=b,[h,g]=[g,h];o.push(["distanceToStart",new c(m,o[0][1].indices,1,!0)])}function j(t){const e=t.length;return t[0]===t[e-3]&&t[1]===t[e-2]&&t[2]===t[e-1]}const A=r(),v=r(),z=4;function S(t,e,r,o,n){if(null==t||0===t.length)return[];const i=[];return t.forEach((t,u)=>{const s=t.length,l=a(3*s);t.forEach((t,e)=>{l[3*e]=t[0],l[3*e+1]=t[1],l[3*e+2]=t[2]});const c={attributeData:{position:l,normal:e,colorFeature:r?.[u],opacityFeature:o?.[u],sizeFeature:n?.[u]},removeDuplicateStartEnd:!1};i.push(c)}),i}function E(t,e,r,o,n,i){if(null==t||0===t.length)return[];const a=S(t,e,o,n,i);return t.forEach((t,e)=>{const o=r?.[e],n=null!=o?x(o.timeStamps,o.stage):void 0;a[e].attributeData.timeStamps=n}),a}function I(t,e=0,r=.01){const o=s(t.length);o[0]=0;for(let i=1;i<t.length;i++){const e=t[i-1],r=t[i],n=Math.sqrt((r[0]-e[0])**2+(r[1]-e[1])**2+(r[2]-e[2])**2);o[i]=o[i-1]+n}const n=o.map(t=>t*r);if(0!==e&&e<n.length){const t=n[e];for(let e=0;e<n.length;e++)n[e]-=t}return n}function x(t,e){const r=s(t.length*z),o=t[0],n=t[t.length-1];for(let i=0;i<t.length;i++)r[i*z]=t[i],r[i*z+1]=o,r[i*z+2]=n,r[i*z+3]=e+.5;return r}export{E as animatedLineStripsToParameters,f as createGeometry,I as getLinearTimeStamps,S as lineStripsToParameters,z as numTimeStampValuesPerVertex,x as timeStampsToAttribute};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as t}from"tslib";import{subclass as e}from"../../../../core/accessorSupport/decorators.js";import{createFlowFieldFromData as s,traceFlowPaths as a}from"../../../2d/engine/flow/dataUtils.js";import{createFlowFieldFromDataTiled as i,valuesPerFlowVertex as r}from"./loadUtils.js";let o=class{constructor(){this._tileData=new Map}async generateStreamlines(t){const{flowData:e,flowExtentInfo:a,needsMagnitude:i,simulationSettings:r,startPositions:o}=t,n=l(s(r,e),r,a.modelSize,i,o);return{result:{streamlines:n},transferList:n?.map(t=>t.vertices.buffer)}}async generateTiledStreamlines(t){const{flowDataTiles:e,flowExtentInfo:s,needsMagnitude:a,reset:r,simulationSettings:o,startPositions:n}=t;this._updateTileData(e,r);const f=l(i(o,this._tileData,s),o,s.modelSize,a,n);return{result:{streamlines:f},transferList:f?.map(t=>t.vertices.buffer)??[]}}_updateTileData(t,e){if(e)for(const s of this._tileData.keys())t.has(s)||this._tileData.delete(s);t.forEach((t,e)=>{"delete"===t.type?this._tileData.delete(e):"on-worker"!==t.type&&"invalid"!==t.type&&this._tileData.set(e,t.data)})}};o=t([e("esri.views.3d.support.flow.FlowWorker")],o);const n=o;function l(t,e,s,i,o){if(null==t)return;const n=a(e,t,s[0],s[1],{positions:o}),l=[],f=r(i);for(const{vertices:a,stage:r}of n){const t=new Float32Array(a.length*f);for(let e=0;e<a.length;e++)t[e*f]=a[e].x,t[e*f+1]=a[e].y,t[e*f+2]=a[e].t,i&&(t[e*f+3]=a[e].speed);l.push({vertices:t,stage:r,hasMagnitude:i})}return l}export{n as default};
5
+ import{__decorate as t}from"tslib";import{subclass as e}from"../../../../core/accessorSupport/decorators.js";import{createFlowFieldFromData as s,traceFlowPaths as a}from"../../../2d/engine/flow/dataUtils.js";import{createFlowFieldFromDataTiled as i,valuesPerFlowVertex as r}from"./loadUtils.js";let o=class{constructor(){this._tileData=new Map}async generateStreamlines(t){const{flowData:e,flowExtentInfo:a,needsMagnitude:i,simulationSettings:r,startPositions:o}=t,n=l(s(r,e),r,a.modelSize,i,o);return{result:{streamlines:n},transferList:n?.map(t=>t.vertices.buffer)}}async generateTiledStreamlines(t){const{flowDataTiles:e,flowExtentInfo:s,needsMagnitude:a,reset:r,simulationSettings:o,startPositions:n}=t;this._updateTileData(e,r);const f=l(i(o,this._tileData,s),o,s.modelSize,a,n);return{result:{streamlines:f},transferList:f?.map(t=>t.vertices.buffer)??[]}}_updateTileData(t,e){if(e)for(const s of this._tileData.keys())t.has(s)||this._tileData.delete(s);t.forEach((t,e)=>{"delete"===t.type?this._tileData.delete(e):"on-worker"!==t.type&&"invalid"!==t.type&&this._tileData.set(e,t.data)})}};o=t([e("esri.views.3d.support.flow.FlowWorker")],o);const n=o;function l(t,e,s,i,o){if(null==t)return;const n=a(e,t,s[0],s[1],{positions:o}),l=[],f=r(i);for(const{vertices:a,stage:r}of n){const t=new Float32Array(a.length*f);for(let e=0;e<a.length;e++)t[e*f]=a[e].x,t[e*f+1]=a[e].y,t[e*f+2]=a[e].time,i&&(t[e*f+3]=a[e].speed);l.push({vertices:t,stage:r,hasMagnitude:i})}return l}export{n as default};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import"../../../../core/has.js";import{estimateNestedObjectMemory as e}from"../../../../core/memoryEstimations.js";import{Seconds as t}from"../../../../core/time.js";import{FlowQuery3D as s}from"./FlowQuery3D.js";class i{constructor(e,t,s,i,r){this._query=e,this.streamlines=t,this._material=s,this.geometries=i,this._bytesPerFeature=r,this._startTime=0,this._endTime=1/0,this.usedMemory=null,this.startTime=this._query.time,this.computeMemory()}computeMemory(){const t=e(this.streamlines),s=e(this.geometries.map(e=>e.attributes)),i=this.streamlines.length*this._bytesPerFeature;this.usedMemory=t+s+i}get startTime(){return this._startTime}set startTime(e){this._query.time!==e&&(this._query=new s(this._query.extent,this._query.timeExtent,this._query.size,this._query.pixelRatio,t(e))),this._startTime=e,this.setMaterialParameters({startTime:e})}get endTime(){return this._endTime}set endTime(e){this._endTime=e,this.setMaterialParameters({endTime:e})}get query(){return this._query}hasFadedOut(e){return this.endTime+this._material.parameters.fadeOutTime<e}setMaterialParameters(e){this._material.setParameters(e)}get test(){return null}}export{i as StreamlineResources3D};
5
+ import"../../../../core/has.js";import{estimateNestedObjectMemory as e}from"../../../../core/memoryEstimations.js";import{Seconds as t}from"../../../../core/time.js";import{fadeOutTime as s}from"./constants.js";import{FlowQuery3D as r}from"./FlowQuery3D.js";class i{constructor(e,s,r,i,m){this._query=e,this.streamlines=s,this._material=r,this.geometries=i,this._bytesPerFeature=m,this._endTime=t(1/0),this.usedMemory=null,this.computeMemory()}computeMemory(){const t=e(this.streamlines),s=e(this.geometries.map(e=>e.attributes)),r=this.streamlines.length*this._bytesPerFeature;this.usedMemory=t+s+r}get startTime(){return this._query.time}set startTime(e){this._query.time!==e&&(this._query=new r(this._query.extent,this._query.timeExtent,this._query.size,this._query.pixelRatio,t(e))),this.setMaterialParameters({startTime:e})}get endTime(){return this._endTime}set endTime(e){this._endTime!==e&&(this._endTime=e,this.setMaterialParameters({endTime:e}))}get query(){return this._query}hasFadedOut(e){return this.endTime+s<e}setMaterialParameters(e){this._material.setParameters(e)}get test(){return null}}export{i as StreamlineResources3D};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- const e=.1,o=1,t=1,c=1e3,n=!1,p=3,r=1,s=27e6,x=501,a=256,b=!0,d=3,f=2,g=2;export{e as averageLoadingTimeSmoothingFactor,r as defaultTransitionDuration,f as densityFactor,t as fadeInTime,o as fadeOutTime,g as loadAllTilesDensityFactor,a as minimumTracingResolution,s as scaleThresholdForLoadingAllTiles,n as seamlessTransitionEnabled,x as streamlinGeometryBatchSize,d as tileFilterDistance,b as tileFilteringByDistanceEnabled,c as tilesWaitingTime,p as transitionDurationFactor};
5
+ import{Seconds as e}from"../../../../core/time.js";const o=.1,r=e(1),t=e(1),m=1e3,c=!1,i=3,p=1,s=27e6,f=501,j=256,n=!0,x=3,a=2,b=2;export{o as averageLoadingTimeSmoothingFactor,p as defaultTransitionDuration,a as densityFactor,t as fadeInTime,r as fadeOutTime,b as loadAllTilesDensityFactor,j as minimumTracingResolution,s as scaleThresholdForLoadingAllTiles,c as seamlessTransitionEnabled,f as streamlinGeometryBatchSize,x as tileFilterDistance,n as tileFilteringByDistanceEnabled,m as tilesWaitingTime,i as transitionDurationFactor};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{fromValues as t}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{newFloatArray as o}from"../../../../geometry/support/FloatArray.js";import{newHalfFloatArray as e}from"../../../../geometry/support/HalfFloatArray.js";import{zValueInAbsoluteHeightMode as r}from"../../../../support/elevationInfoUtils.js";import{convertVisualVariables as i,ConvertOptions as s}from"../../layers/support/FastSymbolUpdates.js";import{animatedLineStripsToParameters as n,createGeometry as a}from"../engineContent/line.js";import{valuesPerFlowVertex as l}from"./loadUtils.js";import{drapedZ as p}from"../../terrain/OverlayRenderer.js";function c(t,r,{vertices:i,stage:s,hasMagnitude:c},m,u,d){const{spatialReference:v}=r.extent,h=[],y=l(c),g=r.flowExtentInfo.modelSize[0];let S=0;for(let o=0;o<i.length;o+=y){if(d&&o>0){const t=i[o]-i[o-y];t>g/2?S-=g:-t>g/2&&(S+=g)}const[e,s]=r.modelToMapSpace(i[o]+S,i[o+1],!1),n=d?[e,s,p]:f(e,s,v,t,m);h.push(n)}const j=Math.floor(i.length/y),V=e(j);for(let o=0;o<j;o++)V[o]=i[o*y+2];const{hasVVColor:b,hasVVOpacity:z,hasVVSize:C}=u.parameters;let w,x,R;if(c&&(b||z||C)){const t=o(j);for(let o=0;o<j;o++)t[o]=i[o*y+3];b&&(w=[t]),z&&(x=[t]),C&&(R=[t])}const U=n([h],void 0,[{timeStamps:V,streamlineType:s}],w,x,R);return a(u,U[0])}function m(t,o,e){if(null==t)return{};let r=null;if(t.visualVariables){const o=[],e=t.visualVariables,n=new s({supports:{size:!0,color:!0,rotation:!1,opacity:!0}});r=i(e,n,o)}const n=r?.color?[1,1,1,1]:t.color.toUnitRGBA();n[3]*=o;return{color:n,width:t.trailWidth,cap:0,animationSpeed:t.flowSpeed,trailLength:t.trailLength,animation:3,emissiveStrength:e,vvColor:r?.color,vvOpacity:r?.opacity,vvSize:r?.size}}function f(o,e,i,s,n){const{absoluteZ:a}=r(o,e,0,i,s,n),l=t(o,e,a);return s.renderCoordsHelper.toRenderCoords(l,i,l),l}export{c as createStreamlineGeometry,m as materialParametersFromRenderer};
5
+ import{fromValues as t}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{newFloatArray as o}from"../../../../geometry/support/FloatArray.js";import{newHalfFloatArray as e}from"../../../../geometry/support/HalfFloatArray.js";import{zValueInAbsoluteHeightMode as r}from"../../../../support/elevationInfoUtils.js";import{convertVisualVariables as i,ConvertOptions as s}from"../../layers/support/FastSymbolUpdates.js";import{animatedLineStripsToParameters as n,createGeometry as a}from"../engineContent/line.js";import{valuesPerFlowVertex as l}from"./loadUtils.js";import{drapedZ as p}from"../../terrain/OverlayRenderer.js";function c(t,r,{vertices:i,stage:s,hasMagnitude:c},m,u,d){const{spatialReference:v}=r.extent,h=[],g=l(c),y=r.flowExtentInfo.modelSize[0];let S=0;for(let o=0;o<i.length;o+=g){if(d&&o>0){const t=i[o]-i[o-g];t>y/2?S-=y:-t>y/2&&(S+=y)}const[e,s]=r.modelToMapSpace(i[o]+S,i[o+1],!1),n=d?[e,s,p]:f(e,s,v,t,m);h.push(n)}const j=Math.floor(i.length/g),V=e(j);for(let o=0;o<j;o++)V[o]=i[o*g+2];const{hasVVColor:b,hasVVOpacity:z,hasVVSize:C}=u.parameters;let w,x,R;if(c&&(b||z||C)){const t=o(j);for(let o=0;o<j;o++)t[o]=i[o*g+3];b&&(w=[t]),z&&(x=[t]),C&&(R=[t])}const U=n([h],void 0,[{timeStamps:V,stage:s}],w,x,R);return a(u,U[0])}function m(t,o,e){if(null==t)return{};let r=null;if(t.visualVariables){const o=[],e=t.visualVariables,n=new s({supports:{size:!0,color:!0,rotation:!1,opacity:!0}});r=i(e,n,o)}const n=r?.color?[1,1,1,1]:t.color.toUnitRGBA();n[3]*=o;return{color:n,width:t.trailWidth,cap:0,animationSpeed:t.flowSpeed,trailLength:t.trailLength,animation:3,emissiveStrength:e,vvColor:r?.color,vvOpacity:r?.opacity,vvSize:r?.size}}function f(o,e,i,s,n){const{absoluteZ:a}=r(o,e,0,i,s,n),l=t(o,e,a);return s.renderCoordsHelper.toRenderCoords(l,i,l),l}export{c as createStreamlineGeometry,m as materialParametersFromRenderer};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{reallocGrowthFactor as e}from"../../../../core/arrayUtils.js";import"../../../../core/has.js";import{signal as r}from"../../../../core/signal.js";import{intersectsSphere as s}from"../../../../geometry/support/frustum.js";import{Sphere as t}from"../../../../geometry/support/sphere.js";import{makeScheduleFunction as i}from"../../layers/support/makeScheduleFunction.js";import{GaussianSplatSortWorkerHandle as n}from"../GaussianSplatWorkerHandle.js";import{GaussianSplatFadeTexture as a}from"./GaussianSplatFadeTexture.js";import{GaussianSplatOrderTexture as o}from"./GaussianSplatOrderTexture.js";import{GaussianSplatTextureAtlas as u}from"./GaussianSplatTextureAtlas.js";class h{constructor(e){this._updating=r(!1),this.visibleGaussians=0,this._visibleGaussianTiles=new Array,this._workerHandle=null,this._isSorting=!1,this._pendingSortTask=!1,this._bufferCapacity=0,this._minimumBoundingSphere=new t,this._renderer=e,this._orderTexture=new o(this._renderer.renderingContext),this._fadingTexture=new a(this._renderer.renderingContext),this._textureAtlas=new u(this._renderer.renderingContext,this._renderer.view.resourceController.memoryController,this._renderer.fboCache);const{resourceController:s}=this._renderer.view;this._workerHandle=new n(i(s))}get textureAtlas(){return this._textureAtlas}get orderTexture(){return this._orderTexture}get fadingTexture(){return this._fadingTexture}get visibleGaussianTiles(){return this._visibleGaussianTiles}updateGaussianVisibility(e){this._visibleGaussianTiles=e,this.requestSort()}isUpdating(){return this._updating.value}destroy(){this._pendingSortTask=!1,this._workerHandle?.destroyWorkerAndSelf(),this._textureAtlas.destroy(),this._orderTexture.destroy(),this._fadingTexture.destroy()}requestSort(){this._updating.value=!0,this._isSorting?this._pendingSortTask=!0:(this._isSorting=!0,this._pendingSortTask=!1,this._sortOnWorker().then(()=>this._handleSortComplete()).catch(()=>this._handleSortComplete()))}_handleSortComplete(){this._isSorting=!1,this._pendingSortTask?this.requestSort():this._updating.value=!1}_clearBuffersAndTextures(){this._bufferCapacity=0,this._orderTexture.clear(),this._textureAtlas.clear()}_ensureBufferCapacity(r){if(this._bufferCapacity<r){const s=Math.ceil(r*e);this._atlasIndicesBuffer=new Uint32Array(s),this._sortedAtlasIndicesBuffer=new Uint32Array(s),this._distancesBuffer=new Float64Array(s),this._sortOrderBuffer=new Uint32Array(s),this._bufferCapacity=s}}async _sortOnWorker(){if(0===this._visibleGaussianTiles.length)return this.visibleGaussians=0,this._clearBuffersAndTextures(),void this._renderer.requestRender(1);let e=this._visibleGaussianTiles.reduce((e,r)=>e+r.gaussianAtlasIndices.length,0);this._ensureBufferCapacity(e),this._textureAtlas.ensureTextureAtlas();const r=this._renderer.camera.frustum,t=this._renderer.camera.eye,i=t[0],n=t[1],a=t[2];let o=0;if(this._visibleGaussianTiles.forEach(t=>{const u=t.gaussianAtlasIndices,h=t.positions;if(this._minimumBoundingSphere.center=t.obb.center,this._minimumBoundingSphere.radius=t.obb.radius+t.maxScale,s(r,this._minimumBoundingSphere))for(let e=0;e<u.length;e++){this._atlasIndicesBuffer[o]=u[e];const r=3*e,s=h[r]-i,t=h[r+1]-n,d=h[r+2]-a;this._distancesBuffer[o]=s*s+t*t+d*d,this._sortOrderBuffer[o]=o,o++}else e-=u.length}),0===e)return this.visibleGaussians=0,this._clearBuffersAndTextures(),void this._renderer.requestRender(1);const u={distances:this._distancesBuffer,sortOrderIndices:this._sortOrderBuffer,numGaussians:e,preciseSort:!1};await(this._workerHandle?.sort(u).then(r=>{this._distancesBuffer=r.distances,this._sortOrderBuffer=r.sortedOrderIndices;const s=this._sortedAtlasIndicesBuffer.subarray(0,e);for(let i=0;i<e;i++)s[i]=this._atlasIndicesBuffer[r.sortedOrderIndices[i]];this._orderTexture.setData(s,e);const t=this._renderer.view.qualitySettings.gaussianSplat.maxAllowedVisibleGaussians;this.visibleGaussians=Math.min(e,t),this._renderer.requestRender(1)}))}}export{h as GaussianSplatDataStore};
5
+ import{reallocGrowthFactor as e}from"../../../../core/arrayUtils.js";import{signal as r}from"../../../../core/signal.js";import{n as t}from"../../../../chunks/vec32.js";import{create as s}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{intersectsSphere as i}from"../../../../geometry/support/frustum.js";import{Sphere as n}from"../../../../geometry/support/sphere.js";import{makeScheduleFunction as a}from"../../layers/support/makeScheduleFunction.js";import{GaussianSplatSortWorkerHandle as o}from"../GaussianSplatWorkerHandle.js";import{GaussianSplatFadeTexture as u}from"./GaussianSplatFadeTexture.js";import{GaussianSplatOrderTexture as h}from"./GaussianSplatOrderTexture.js";import{GaussianSplatTextureAtlas as d}from"./GaussianSplatTextureAtlas.js";class l{constructor(e){this._updating=r(!1),this._useDeterministicSort=!1,this.visibleGaussians=0,this._visibleGaussianTiles=new Array,this._workerHandle=null,this._isSorting=!1,this._pendingSortTask=!1,this._bufferCapacity=0,this._minimumBoundingSphere=new n,this._cameraDirectionNormalized=s(),this._renderer=e,this._orderTexture=new h(this._renderer.renderingContext),this._fadingTexture=new u(this._renderer.renderingContext),this._textureAtlas=new d(this._renderer.renderingContext,this._renderer.view.resourceController.memoryController,this._renderer.fboCache);const{resourceController:t}=this._renderer.view;this._workerHandle=new o(a(t))}get textureAtlas(){return this._textureAtlas}get orderTexture(){return this._orderTexture}get fadingTexture(){return this._fadingTexture}get visibleGaussianTiles(){return this._visibleGaussianTiles}updateGaussianVisibility(e){this._visibleGaussianTiles=e,this.requestSort()}isUpdating(){return this._updating.value}destroy(){this._pendingSortTask=!1,this._workerHandle?.destroyWorkerAndSelf(),this._textureAtlas.destroy(),this._orderTexture.destroy(),this._fadingTexture.destroy()}requestSort(){this._updating.value=!0,this._isSorting?this._pendingSortTask=!0:(this._isSorting=!0,this._pendingSortTask=!1,this._sortOnWorker().then(()=>this._handleSortComplete()).catch(()=>this._handleSortComplete()))}_handleSortComplete(){this._isSorting=!1,this._pendingSortTask?this.requestSort():this._updating.value=!1}_clearBuffersAndTextures(){this._bufferCapacity=0,this._orderTexture.clear(),this._textureAtlas.clear()}_ensureBufferCapacity(r){if(this._bufferCapacity<r){const t=Math.ceil(r*e);this._atlasIndicesBuffer=new Uint32Array(t),this._sortedAtlasIndicesBuffer=new Uint32Array(t),this._distancesBuffer=new Float64Array(t),this._sortOrderBuffer=new Uint32Array(t),this._bufferCapacity=t}}async _sortOnWorker(){if(0===this._visibleGaussianTiles.length)return this.visibleGaussians=0,this._clearBuffersAndTextures(),void this._renderer.requestRender(1);this._useDeterministicSort&&this._visibleGaussianTiles.sort((e,r)=>e.obb.centerX-r.obb.centerX||e.obb.centerY-r.obb.centerY||e.obb.centerZ-r.obb.centerZ);let e=this._visibleGaussianTiles.reduce((e,r)=>e+r.gaussianAtlasIndices.length,0);this._ensureBufferCapacity(e),this._textureAtlas.ensureTextureAtlas();const{frustum:r}=this._renderer.camera;t(this._cameraDirectionNormalized,this._renderer.camera.ray.direction);const s=this._cameraDirectionNormalized[0],n=this._cameraDirectionNormalized[1],a=this._cameraDirectionNormalized[2];let o=0;if(this._visibleGaussianTiles.forEach(t=>{const{gaussianAtlasIndices:u,positions:h}=t;if(this._minimumBoundingSphere.center=t.obb.center,this._minimumBoundingSphere.radius=t.obb.radius+t.maxScale,i(r,this._minimumBoundingSphere))for(let e=0;e<u.length;e++){this._atlasIndicesBuffer[o]=u[e];const r=3*e,t=h[r],i=h[r+1],d=h[r+2];this._distancesBuffer[o]=t*s+i*n+d*a,this._sortOrderBuffer[o]=o,o++}else e-=u.length}),0===e)return this.visibleGaussians=0,this._clearBuffersAndTextures(),void this._renderer.requestRender(1);const u={distances:this._distancesBuffer,sortOrderIndices:this._sortOrderBuffer,numGaussians:e,preciseSort:this._useDeterministicSort};await(this._workerHandle?.sort(u).then(r=>{this._distancesBuffer=r.distances,this._sortOrderBuffer=r.sortedOrderIndices;const t=this._sortedAtlasIndicesBuffer.subarray(0,e);for(let i=0;i<e;i++)t[i]=this._atlasIndicesBuffer[r.sortedOrderIndices[i]];this._orderTexture.setData(t,e);const s=this._renderer.view.qualitySettings.gaussianSplat.maxAllowedVisibleGaussians;this.visibleGaussians=Math.min(e,s),this._renderer.requestRender(1)}))}set useDeterministicSort(e){this._useDeterministicSort=e}}export{l as GaussianSplatDataStore};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{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{Texture as 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 o,splatAtlasTextureWidth as l,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 o,this._cache=e.newCache("gaussian texture cache",t=>t.dispose())}ensureTextureAtlas(){if(this.texture)return;const t=this._cache.pop("splatTextureAtlas");if(t)return void(this.texture=t);const e=new u;e.height=this._splatAtlasTextureHeight,e.width=l,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*l>this._rctx.parameters.maxPreferredTexturePixels)return!1;const s=new e(this._rctx,this.texture),a=this._fboCache.acquire(l,r,"gaussian splat atlas resize",11);return this._rctx.blitFramebuffer(s,a.fbo,16384,9728,0,0,l,this._splatAtlasTextureHeight,0,0,l,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=l*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()}}export{p as GaussianSplatTextureAtlas};
5
+ 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{Texture as 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 o,splatAtlasTextureWidth as l,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 o,this._cache=e.newCache("gaussian texture cache",t=>t.dispose())}ensureTextureAtlas(){if(this.texture)return;const t=this._cache.pop("splatTextureAtlas");if(t)return void(this.texture=t);const e=new u;e.height=this._splatAtlasTextureHeight,e.width=l,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*l>this._rctx.parameters.maxPreferredTexturePixels)return!1;const s=new e(this._rctx,this.texture),a=this._fboCache.acquire(l,r,"gaussian splat atlas resize",12);return this._rctx.blitFramebuffer(s,a.fbo,16384,9728,0,0,l,this._splatAtlasTextureHeight,0,0,l,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=l*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()}}export{p as GaussianSplatTextureAtlas};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{create as r}from"../../../core/libs/gl-matrix-2/factories/vec2f64.js";import{D as n,d as t,e as i,j as e,g as c,i as o,n as u}from"../../../chunks/vec32.js";import{create as f}from"../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getNormal as l,signedDistance as s}from"../../../geometry/support/plane.js";function p(r,n,t){return r[0]*n[0]+r[1]*n[1]+r[2]*n[2]+r[3]<t}function a(r,n,t){const i=n[0],e=n[1],c=n[2];return!(r[0][0]*i+r[0][1]*e+r[0][2]*c+r[0][3]>t)&&(!(r[1][0]*i+r[1][1]*e+r[1][2]*c+r[1][3]>t)&&(!(r[2][0]*i+r[2][1]*e+r[2][2]*c+r[2][3]>t)&&(!(r[3][0]*i+r[3][1]*e+r[3][2]*c+r[3][3]>t)&&(!(r[4][0]*i+r[4][1]*e+r[4][2]*c+r[4][3]>t)&&!(r[5][0]*i+r[5][1]*e+r[5][2]*c+r[5][3]>t)))))}function m(r,n,t,i){return h(r,n,null,v(i,n,t,!1))}function d(r,n){for(let t=0;t<6;t++){if(s(r[t],n)>0)return!1}return!0}function g(r,n,t,i){return h(r,n,t,v(i,n,t,!0))}function j(r,n,t,u){const f=c(t,i(r,u,n));return o(r,n,e(r,t,f))}const b={dir:f(),len:0,clip:r()};function v(r,c,o,f){const l=b;return r?(o&&f&&(l.len=n(c,o)),t(l.dir,r)):f?(l.len=n(c,o),i(l.dir,o,c),e(l.dir,l.dir,1/l.len)):(i(l.dir,o,c),u(l.dir,l.dir)),l}function x(r,n,t){const i=c(l(r),t.dir),e=-s(r,n);if(e<0&&i>=0)return!1;if(i>-1e-6&&i<1e-6)return e>0;if((e<0||i<0)&&!(e<0&&i<0))return!0;const o=e/i;return i>0?o<t.clip[1]&&(t.clip[1]=o):o>t.clip[0]&&(t.clip[0]=o),t.clip[0]<=t.clip[1]}function h(r,n,t,i){i.clip[0]=0,i.clip[1]=t?i.len:Number.MAX_VALUE;for(let e=0;e<r.length;e++)if(!x(r[e],n,i))return!1;return!0}export{j as closestPointOnRay,g as frustumLineSegment,d as frustumPoint,m as frustumRay,a as frustumSphere,p as planeSphere};
5
+ import{create as r}from"../../../core/libs/gl-matrix-2/factories/vec2f64.js";import{B as n,d as t,e as i,j as e,g as c,i as o,n as u}from"../../../chunks/vec32.js";import{create as f}from"../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getNormal as l,signedDistance as s}from"../../../geometry/support/plane.js";function p(r,n,t){return r[0]*n[0]+r[1]*n[1]+r[2]*n[2]+r[3]<t}function a(r,n,t){const i=n[0],e=n[1],c=n[2];return!(r[0][0]*i+r[0][1]*e+r[0][2]*c+r[0][3]>t)&&(!(r[1][0]*i+r[1][1]*e+r[1][2]*c+r[1][3]>t)&&(!(r[2][0]*i+r[2][1]*e+r[2][2]*c+r[2][3]>t)&&(!(r[3][0]*i+r[3][1]*e+r[3][2]*c+r[3][3]>t)&&(!(r[4][0]*i+r[4][1]*e+r[4][2]*c+r[4][3]>t)&&!(r[5][0]*i+r[5][1]*e+r[5][2]*c+r[5][3]>t)))))}function m(r,n,t,i){return h(r,n,null,v(i,n,t,!1))}function d(r,n){for(let t=0;t<6;t++){if(s(r[t],n)>0)return!1}return!0}function g(r,n,t,i){return h(r,n,t,v(i,n,t,!0))}function j(r,n,t,u){const f=c(t,i(r,u,n));return o(r,n,e(r,t,f))}const b={dir:f(),len:0,clip:r()};function v(r,c,o,f){const l=b;return r?(o&&f&&(l.len=n(c,o)),t(l.dir,r)):f?(l.len=n(c,o),i(l.dir,o,c),e(l.dir,l.dir,1/l.len)):(i(l.dir,o,c),u(l.dir,l.dir)),l}function x(r,n,t){const i=c(l(r),t.dir),e=-s(r,n);if(e<0&&i>=0)return!1;if(i>-1e-6&&i<1e-6)return e>0;if((e<0||i<0)&&!(e<0&&i<0))return!0;const o=e/i;return i>0?o<t.clip[1]&&(t.clip[1]=o):o>t.clip[0]&&(t.clip[0]=o),t.clip[0]<=t.clip[1]}function h(r,n,t,i){i.clip[0]=0,i.clip[1]=t?i.len:Number.MAX_VALUE;for(let e=0;e<r.length;e++)if(!x(r[e],n,i))return!1;return!0}export{j as closestPointOnRay,g as frustumLineSegment,d as frustumPoint,m as frustumRay,a as frustumSphere,p as planeSphere};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{fromQuat as t,scale as e}from"../../../core/libs/gl-matrix-2/math/mat3.js";import{create as a}from"../../../core/libs/gl-matrix-2/factories/mat3f64.js";import{create as s}from"../../../core/libs/gl-matrix-2/factories/mat4f64.js";import{set as r,conjugate as i,multiply as n}from"../../../core/libs/gl-matrix-2/math/quat.js";import{IDENTITY as o,create as h}from"../../../core/libs/gl-matrix-2/factories/quatf64.js";import{h as c,r as d,g as f,f as u,u as l,j as m,v as _,w as g,x as p,t as M,i as b,a as j,y as S,z,b as x,c as y,A as C,B as A}from"../../../chunks/vec32.js";import{ZEROS as q,freeze as P,create as Q,UNIT_Z as v}from"../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{t as R}from"../../../chunks/vec42.js";import{create as w}from"../../../core/libs/gl-matrix-2/factories/vec4f64.js";import{getReferenceEllipsoid as D}from"../../../geometry/ellipsoidUtils.js";import{getSphericalPCPF as H}from"../../../geometry/spatialReferenceEllipsoidUtils.js";import{computeTranslationToOriginAndRotation as k}from"../../../geometry/projection/computeTranslationToOriginAndRotation.js";import{projectBuffer as F}from"../../../geometry/projection/projectBuffer.js";import{getProjector as B}from"../../../geometry/projection/projectors.js";import{getNormal as W}from"../../../geometry/support/plane.js";import{isPlateCarree as U}from"../../../geometry/support/spatialReferenceUtils.js";import{sv3d as Z,sq4d as G}from"../../../geometry/support/vectorStacks.js";import{computeOBB as I}from"./dito.js";import{Vertices as O}from"../webgl-engine/lib/Attribute.js";class T{constructor(t=q,e=bt,a=o){this._data=[t[0],t[1],t[2],e[0],e[1],e[2],a[0],a[1],a[2],a[3]]}clone(){return T.fromData(this._data)}invalidate(){this._data[3]=-1}get isValid(){return this._data[3]>=0}static fromData(t){const e=new T;return e._copyFromData(t),e}static fromJSON(t){return new T(t.center,t.halfSize,t.quaternion)}copy(t){this._copyFromData(t.data)}_copyFromData(t){for(let e=0;e<10;++e)this._data[e]=t[e]}get center(){return c(Z.get(),this._data[0],this._data[1],this._data[2])}get centerX(){return this._data[0]}get centerY(){return this._data[1]}get centerZ(){return this._data[2]}getCenter(t){return t[0]=this._data[0],t[1]=this._data[1],t[2]=this._data[2],t}set center(t){this._data[0]=t[0],this._data[1]=t[1],this._data[2]=t[2]}setCenter(t,e,a){this._data[0]=t,this._data[1]=e,this._data[2]=a}get halfSize(){return c(Z.get(),this._data[3],this._data[4],this._data[5])}get halfSizeX(){return this._data[3]}get halfSizeY(){return this._data[4]}get halfSizeZ(){return this._data[5]}getHalfSize(t){return t[0]=this._data[3],t[1]=this._data[4],t[2]=this._data[5],t}set halfSize(t){this._data[3]=t[0],this._data[4]=t[1],this._data[5]=t[2]}get quaternion(){return r(G.get(),this._data[6],this._data[7],this._data[8],this._data[9])}getQuaternion(t){return t[0]=this._data[6],t[1]=this._data[7],t[2]=this._data[8],t[3]=this._data[9],t}set quaternion(t){this._data[6]=t[0],this._data[7]=t[1],this._data[8]=t[2],this._data[9]=t[3]}get data(){return this._data}getCorners(t){const e=this._data,a=r(X,e[6],e[7],e[8],e[9]);for(let s=0;s<8;++s){const r=t[s];r[0]=(1&s?-1:1)*e[3],r[1]=(2&s?-1:1)*e[4],r[2]=(4&s?-1:1)*e[5],d(r,r,a),r[0]+=e[0],r[1]+=e[1],r[2]+=e[2]}return t}getAxes(t){const e=this._data,a=r(X,e[6],e[7],e[8],e[9]);return d(t[0],[1,0,0],a),d(t[1],[0,1,0],a),d(t[2],[0,0,1],a),t}intersectsFrustum(t){const e=this.center,a=t.planes;for(const d of a){const t=W(d),a=this.projectedRadius(t);if(f(t,e)+d[3]-a>0)return!1}const s=this.getAxes(_t),r=t.points,i=this.halfSize;for(let d=0;d<3;++d){const t=s[d],a=-f(t,e),n=i[d];let o=!0,h=!0;for(const e of r){const s=f(e,t)+a;o&&=s>n,h&&=s<-n}if(o||h)return!1}if(this.getCorners(mt).some(e=>t.intersectsPoint(e)))return!0;const n=zt;for(let d=0;d<3;++d){const t=s[d];n[d]=f(t,e)}const o=t=>{for(let e=0;e<3;++e){const a=s[e],r=i[e],o=f(a,t)-n[e];if(o>r||o<-r)return!1}return!0};if(t.points.some(t=>o(t)))return!0;const h=t.lines,c=St;for(let d=0;d<8;++d){const t=h[d].direction;for(const a of s){u(c,t,a);const s=l(c);if(!(s>0))continue;m(c,c,1/s);const i=this.projectedRadius(c),n=f(e,c),o=n-i,h=n+i;let d=!1,_=!1,g=!0;for(const t of r){const e=f(c,t);if(e>h){if(_){g=!1;break}d=!0}else{if(!(e<o)){g=!1;break}if(d){g=!1;break}_=!0}}if(g)return!1}}return!0}doesIntersectFrustumConservativeApproximation(t){return this.intersectPlane(t[0])<=0&&this.intersectPlane(t[1])<=0&&this.intersectPlane(t[2])<=0&&this.intersectPlane(t[3])<=0&&this.intersectPlane(t[4])<=0&&this.intersectPlane(t[5])<=0}get radius(){const t=this._data[3],e=this._data[4],a=this._data[5];return Math.sqrt(t*t+e*e+a*a)}intersectsPoint(t){const e=this.getAxes(_t),a=this.halfSize,{center:s}=this;for(let r=0;r<3;++r){const i=e[r],n=a[r],o=f(i,t)-f(i,s);if(o>n||o<-n)return!1}return!0}intersectSphere(t){const{center:e}=t,a=this._data;J[0]=a[0]-e[0],J[1]=a[1]-e[1],J[2]=a[2]-e[2];const s=this.getQuaternion(Y);return i(X,s),d(J,J,X),_(J,J),N[0]=Math.min(J[0],a[3]),N[1]=Math.min(J[1],a[4]),N[2]=Math.min(J[2],a[5]),g(N,J)<t.radius*t.radius}intersectSphereWithMBS(t,e=this.radius){const a=this._data,{center:s}=t;J[0]=a[0]-s[0],J[1]=a[1]-s[1],J[2]=a[2]-s[2];const r=t.radius,i=r+e;return!(p(J)>i*i)&&(X[0]=-a[6],X[1]=-a[7],X[2]=-a[8],X[3]=a[9],d(J,J,X),_(J,J),N[0]=Math.min(J[0],a[3]),N[1]=Math.min(J[1],a[4]),N[2]=Math.min(J[2],a[5]),g(N,J)<r*r)}intersectPlane(t){const e=t[0]*this._data[0]+t[1]*this._data[1]+t[2]*this._data[2]+t[3],a=this.projectedRadius(W(t));return e>a?1:e<-a?-1:0}intersectRay(t,e,a=0){const s=this._data,r=X;r[0]=-s[6],r[1]=-s[7],r[2]=-s[8],r[3]=s[9],J[0]=t[0]-s[0],J[1]=t[1]-s[1],J[2]=t[2]-s[2];const i=d(J,J,X),n=d(N,e,X);let o=-1/0,h=1/0;const c=this.getHalfSize(ft);for(let d=0;d<3;d++){const t=i[d],e=n[d],s=c[d]+a;if(Math.abs(e)>1e-6){const a=(s-t)/e,r=(-s-t)/e;o=Math.max(o,Math.min(a,r)),h=Math.min(h,Math.max(a,r))}else if(t>s||t<-s)return!1}return o<=h}projectedArea(a,s,r,n){const o=this.getQuaternion(Y);i(X,o),J[0]=a[0]-this._data[0],J[1]=a[1]-this._data[1],J[2]=a[2]-this._data[2],d(J,J,X);const h=this.getHalfSize(ft),f=J[0]<-h[0]?-1:J[0]>h[0]?1:0,u=J[1]<-h[1]?-1:J[1]>h[1]?1:0,l=J[2]<-h[2]?-1:J[2]>h[2]?1:0,m=Math.abs(f)+Math.abs(u)+Math.abs(l);if(0===m)return 1/0;const _=1===m?4:6,g=6*(f+3*u+9*l+13);t(ut,o),e(ut,ut,h);const p=this.getCenter(ct);for(let t=0;t<_;t++){const e=$[g+t];c(J,((1&e)<<1)-1,(2&e)-1,((4&e)>>1)-1),M(J,J,ut),b(V,p,J),V[3]=1,R(V,V,s);const a=1/Math.max(1e-6,V[3]);L[2*t]=V[0]*a,L[2*t+1]=V[1]*a}const j=2*_-2;let S=L[0]*(L[3]-L[j+1])+L[j]*(L[1]-L[j-1]);for(let t=2;t<j;t+=2)S+=L[t]*(L[t+3]-L[t-1]);return Math.abs(S)*r*n*.125}projectedRadius(t){const e=this.getQuaternion(Y);return i(X,e),d(J,t,X),Math.abs(J[0]*this._data[3])+Math.abs(J[1]*this._data[4])+Math.abs(J[2]*this._data[5])}minimumDistancePlane(t){return t[0]*this._data[0]+t[1]*this._data[1]+t[2]*this._data[2]+t[3]-this.projectedRadius(W(t))}maximumDistancePlane(t){return t[0]*this._data[0]+t[1]*this._data[1]+t[2]*this._data[2]+t[3]+this.projectedRadius(W(t))}toAaBoundingBox(e){const a=this.getQuaternion(Y),s=t(ut,a),r=this._data[3]*Math.abs(s[0])+this._data[4]*Math.abs(s[3])+this._data[5]*Math.abs(s[6]),i=this._data[3]*Math.abs(s[1])+this._data[4]*Math.abs(s[4])+this._data[5]*Math.abs(s[7]),n=this._data[3]*Math.abs(s[2])+this._data[4]*Math.abs(s[5])+this._data[5]*Math.abs(s[8]);e[0]=this._data[0]-r,e[1]=this._data[1]-i,e[2]=this._data[2]-n,e[3]=this._data[0]+r,e[4]=this._data[1]+i,e[5]=this._data[2]+n}transform(t,e,a,s=0,r=H(a),i=H(e),n=B(e,i)){if(a===r)e.isGeographic?it(this,t,e,s,i):rt(this,t,e,s,i,n);else if(e.isWGS84&&(a.isWebMercator||U(a)))et(e,this,a,t,s);else if(e.isWebMercator&&U(a))at(e,this,a,t,s);else{const r=this.getCenter(ct);r[2]+=s,F(r,e,0,r,a,0),t.center=r,this!==t&&(t.quaternion=this.getQuaternion(Y),t.halfSize=this.getHalfSize(ft))}}}const X=h(),Y=h(),E=h(),J=Q(),N=Q(),V=w();function K(t,e=new T){return I(t,e),e}const L=[.1,.2,.3,.4,.5,.6,.7,.8,.9,1,1.1,1.2],$=(()=>{const t=new Int8Array(162);let e=0;const a=a=>{for(let s=0;s<a.length;s++)t[e+s]=a[s];e+=6};return a([6,2,3,1,5,4]),a([0,2,3,1,5,4]),a([0,2,3,7,5,4]),a([0,1,3,2,6,4]),a([0,1,3,2,0,0]),a([0,1,5,7,3,2]),a([0,1,3,7,6,4]),a([0,1,3,7,6,2]),a([0,1,5,7,6,2]),a([0,1,5,4,6,2]),a([0,1,5,4,0,0]),a([0,1,3,7,5,4]),a([0,2,6,4,0,0]),a([0,0,0,0,0,0]),a([1,3,7,5,0,0]),a([2,3,7,6,4,0]),a([2,3,7,6,0,0]),a([2,3,1,5,7,6]),a([0,1,5,7,6,2]),a([0,1,5,7,6,4]),a([0,1,3,7,6,4]),a([4,5,7,6,2,0]),a([4,5,7,6,0,0]),a([4,5,1,3,7,6]),a([0,2,3,7,5,4]),a([6,2,3,7,5,4]),a([6,2,3,1,5,4]),t})();function tt(t,e,a,s,r){const n=t.getQuaternion(Y);r.quaternion=n,i(X,n);const o=t.getCenter(ct),h=t.getHalfSize(ft);if(1===s){d(gt,o,X),_(pt,gt),z(Mt,pt,h),j(Mt,pt,Mt);const s=x(Mt);b(Mt,pt,h);const i=x(Mt);if(s<a)r.center=o,c(gt,a,a,a),r.halfSize=b(gt,h,gt);else{const n=i>0?1+e/i:1,o=s>0?1+a/s:1,c=(o+n)/2,f=(o-n)/2;m(Mt,pt,f),r.halfSize=y(Mt,Mt,h,c),m(Mt,pt,c),y(Mt,Mt,h,f),C(gt,gt),A(gt,Mt,gt);const u=t.getQuaternion(E);r.center=d(gt,gt,u)}}else{r.center=y(gt,o,v,(a+e)/2);const t=d(gt,v,X);_(t,t),r.halfSize=y(pt,h,t,(a-e)/2)}return r}function et(t,e,a,s,r){e.getCenter(ct),ct[2]+=r;const i=H(a);F(ct,t,0,ct,i,0),st(i,e,ct,a,s)}function at(t,e,a,s,r){e.getCenter(ct),ct[2]+=r,st(t,e,ct,a,s)}function st(e,a,s,r,i){const n=a.getQuaternion(Y),o=t(ut,n),h=a.getHalfSize(ft);for(let t=0;t<8;++t){for(let e=0;e<3;++e)ht[e]=h[e]*(t&1<<e?-1:1);for(let e=0;e<3;++e){let a=s[e];for(let t=0;t<3;++t)a+=ht[t]*o[3*t+e];nt[3*t+e]=a}}F(nt,e,0,nt,r,0,8),K(ot,i)}function rt(t,e,a,s,r=H(a),o=B(a,r)){t.getCorners(mt),t.getCenter(ht),ht[2]+=s,k(a,ht,lt,r),e.setCenter(lt[12],lt[13],lt[14]);const h=2*Math.sqrt(1+lt[0]+lt[5]+lt[10]);X[0]=(lt[6]-lt[9])/h,X[1]=(lt[8]-lt[2])/h,X[2]=(lt[1]-lt[4])/h,X[3]=.25*h;const f=t.getQuaternion(Y);e.quaternion=n(X,X,f),i(X,X),c(pt,0,0,0);const u=e.getCenter(dt);for(const i of mt)i[2]+=s,o(i,0,i,0),j(gt,i,u),d(gt,gt,X),_(gt,gt),S(pt,pt,gt);e.halfSize=pt}function it(t,e,a,s,r=H(a)){const n=D(a),o=1+Math.max(0,s)/(n.radius+t.centerZ);t.getCenter(ht),ht[2]+=s,F(ht,a,0,ht,r,0),e.center=ht;const h=t.getQuaternion(Y);e.quaternion=h,i(X,h),c(gt,0,0,1),d(gt,gt,X);const f=t.getHalfSize(ft);c(gt,f[0]*Math.abs(gt[0]),f[1]*Math.abs(gt[1]),f[2]*Math.abs(gt[2])),m(gt,gt,n.inverseFlattening),b(gt,f,gt),e.halfSize=m(gt,gt,o)}const nt=new Array(24),ot=new O(nt,3),ht=Q(),ct=Q(),dt=Q(),ft=Q(),ut=a(),lt=s(),mt=[[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0]],_t=[Q(),Q(),Q()],gt=Q(),pt=Q(),Mt=Q(),bt=P(-1,-1,-1);function jt(t){return Array.from(t)}const St=Q(),zt=[0,0,0];export{T as Obb,K as compute,tt as computeOffsetObb,jt as ensurePackedObbData};
5
+ import{fromQuat as t,scale as a}from"../../../core/libs/gl-matrix-2/math/mat3.js";import{create as e}from"../../../core/libs/gl-matrix-2/factories/mat3f64.js";import{create as s}from"../../../core/libs/gl-matrix-2/factories/mat4f64.js";import{set as r,conjugate as i,multiply as n}from"../../../core/libs/gl-matrix-2/math/quat.js";import{IDENTITY as o,create as h}from"../../../core/libs/gl-matrix-2/factories/quatf64.js";import{h as c,r as f,g as d,f as u,u as l,j as m,t as _,i as g,a as p,v as M,w as b,x as j,b as S,c as z,y as x,z as y}from"../../../chunks/vec32.js";import{ZEROS as C,freeze as q,create as A,UNIT_Z as P}from"../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{t as v}from"../../../chunks/vec42.js";import{create as Q}from"../../../core/libs/gl-matrix-2/factories/vec4f64.js";import{getReferenceEllipsoid as R}from"../../../geometry/ellipsoidUtils.js";import{getSphericalPCPF as w}from"../../../geometry/spatialReferenceEllipsoidUtils.js";import{computeTranslationToOriginAndRotation as D}from"../../../geometry/projection/computeTranslationToOriginAndRotation.js";import{projectBuffer as H}from"../../../geometry/projection/projectBuffer.js";import{getProjector as k}from"../../../geometry/projection/projectors.js";import{getNormal as F}from"../../../geometry/support/plane.js";import{isPlateCarree as B}from"../../../geometry/support/spatialReferenceUtils.js";import{sv3d as W,sq4d as U}from"../../../geometry/support/vectorStacks.js";import{computeOBB as Z}from"./dito.js";import{Vertices as G}from"../webgl-engine/lib/Attribute.js";class O{constructor(t=C,a=pt,e=o){this._data=[t[0],t[1],t[2],a[0],a[1],a[2],e[0],e[1],e[2],e[3]]}clone(){return O.fromData(this._data)}invalidate(){this._data[3]=-1}get isValid(){return this._data[3]>=0}static fromData(t){const a=new O;return a._copyFromData(t),a}static fromJSON(t){return new O(t.center,t.halfSize,t.quaternion)}copy(t){this._copyFromData(t.data)}_copyFromData(t){for(let a=0;a<10;++a)this._data[a]=t[a]}get center(){return c(W.get(),this._data[0],this._data[1],this._data[2])}get centerX(){return this._data[0]}get centerY(){return this._data[1]}get centerZ(){return this._data[2]}getCenter(t){return t[0]=this._data[0],t[1]=this._data[1],t[2]=this._data[2],t}set center(t){this._data[0]=t[0],this._data[1]=t[1],this._data[2]=t[2]}setCenter(t,a,e){this._data[0]=t,this._data[1]=a,this._data[2]=e}get halfSize(){return c(W.get(),this._data[3],this._data[4],this._data[5])}get halfSizeX(){return this._data[3]}get halfSizeY(){return this._data[4]}get halfSizeZ(){return this._data[5]}getHalfSize(t){return t[0]=this._data[3],t[1]=this._data[4],t[2]=this._data[5],t}set halfSize(t){this._data[3]=t[0],this._data[4]=t[1],this._data[5]=t[2]}get quaternion(){return r(U.get(),this._data[6],this._data[7],this._data[8],this._data[9])}getQuaternion(t){return t[0]=this._data[6],t[1]=this._data[7],t[2]=this._data[8],t[3]=this._data[9],t}set quaternion(t){this._data[6]=t[0],this._data[7]=t[1],this._data[8]=t[2],this._data[9]=t[3]}get data(){return this._data}getCorners(t){const a=this._data,e=r(T,a[6],a[7],a[8],a[9]);for(let s=0;s<8;++s){const r=t[s];r[0]=(1&s?-1:1)*a[3],r[1]=(2&s?-1:1)*a[4],r[2]=(4&s?-1:1)*a[5],f(r,r,e),r[0]+=a[0],r[1]+=a[1],r[2]+=a[2]}return t}getAxes(t){const a=this._data,e=r(T,a[6],a[7],a[8],a[9]);return f(t[0],[1,0,0],e),f(t[1],[0,1,0],e),f(t[2],[0,0,1],e),t}intersectsFrustum(t){const a=this.center,e=t.planes;for(const f of e){const t=F(f),e=this.projectedRadius(t);if(d(t,a)+f[3]-e>0)return!1}const s=this.getAxes(lt),r=t.points,i=this.halfSize;for(let f=0;f<3;++f){const t=s[f],e=-d(t,a),n=i[f];let o=!0,h=!0;for(const a of r){const s=d(a,t)+e;o&&=s>n,h&&=s<-n}if(o||h)return!1}if(this.getCorners(ut).some(a=>t.intersectsPoint(a)))return!0;const n=jt;for(let f=0;f<3;++f){const t=s[f];n[f]=d(t,a)}const o=t=>{for(let a=0;a<3;++a){const e=s[a],r=i[a],o=d(e,t)-n[a];if(o>r||o<-r)return!1}return!0};if(t.points.some(t=>o(t)))return!0;const h=t.lines,c=bt;for(let f=0;f<8;++f){const t=h[f].direction;for(const e of s){u(c,t,e);const s=l(c);if(!(s>0))continue;m(c,c,1/s);const i=this.projectedRadius(c),n=d(a,c),o=n-i,h=n+i;let f=!1,_=!1,g=!0;for(const t of r){const a=d(c,t);if(a>h){if(_){g=!1;break}f=!0}else{if(!(a<o)){g=!1;break}if(f){g=!1;break}_=!0}}if(g)return!1}}return!0}intersectsFrustumConservativeApproximation(t){return this.intersectPlane(t[0])<=0&&this.intersectPlane(t[1])<=0&&this.intersectPlane(t[2])<=0&&this.intersectPlane(t[3])<=0&&this.intersectPlane(t[4])<=0&&this.intersectPlane(t[5])<=0}get radius(){const t=this._data[3],a=this._data[4],e=this._data[5];return Math.sqrt(t*t+a*a+e*e)}intersectsPoint(t){const a=this.getAxes(lt),e=this.halfSize,{center:s}=this;for(let r=0;r<3;++r){const i=a[r],n=e[r],o=d(i,t)-d(i,s);if(o>n||o<-n)return!1}return!0}intersectSphere(t){const{center:a,radius:e}=t,s=this._data,r=s[3],i=s[4],n=s[5],o=Math.max(r,i,n)+e,h=s[0]-a[0];if(h>o)return!1;const c=s[1]-a[1];if(c>o)return!1;const f=s[2]-a[2];if(f>o)return!1;const d=-s[6],u=-s[7],l=-s[8],m=u*f-l*c,_=l*h-d*f,g=d*c-u*h,p=u*g-l*_,M=l*m-d*g,b=d*_-u*m,j=2*s[9],S=Math.abs(h+m*j+2*p),z=Math.abs(c+_*j+2*M),x=Math.abs(f+g*j+2*b),y=S-Math.min(S,r),C=z-Math.min(z,i),q=x-Math.min(x,n);return y*y+C*C+q*q<e*e}intersectSphereWithMBS(t,a=this.radius){const e=this._data,{center:s,radius:r}=t,i=a+r,n=e[0]-s[0];if(n>i)return!1;const o=e[1]-s[1];if(o>i)return!1;const h=e[2]-s[2];if(h>i)return!1;if(n*n+o*o+h*h>i*i)return!1;const c=-e[6],f=-e[7],d=-e[8],u=f*h-d*o,l=d*n-c*h,m=c*o-f*n,_=f*m-d*l,g=d*u-c*m,p=c*l-f*u,M=2*e[9],b=Math.abs(n+u*M+2*_),j=Math.abs(o+l*M+2*g),S=Math.abs(h+m*M+2*p),z=b-Math.min(b,e[3]),x=j-Math.min(j,e[4]),y=S-Math.min(S,e[5]);return z*z+x*x+y*y<r*r}intersectPlane(t){const a=t[0]*this._data[0]+t[1]*this._data[1]+t[2]*this._data[2]+t[3],e=this.projectedRadius(F(t));return a>e?1:a<-e?-1:0}intersectRay(t,a,e=0){const s=this._data,r=T;r[0]=-s[6],r[1]=-s[7],r[2]=-s[8],r[3]=s[9],E[0]=t[0]-s[0],E[1]=t[1]-s[1],E[2]=t[2]-s[2];const i=f(E,E,T),n=f(I,a,T);let o=-1/0,h=1/0;const c=this.getHalfSize(ct);for(let f=0;f<3;f++){const t=i[f],a=n[f],s=c[f]+e;if(Math.abs(a)>1e-6){const e=(s-t)/a,r=(-s-t)/a;o=Math.max(o,Math.min(e,r)),h=Math.min(h,Math.max(e,r))}else if(t>s||t<-s)return!1}return o<=h}projectedArea(e,s,r,n){const o=this.getQuaternion(X);i(T,o),E[0]=e[0]-this._data[0],E[1]=e[1]-this._data[1],E[2]=e[2]-this._data[2],f(E,E,T);const h=this.getHalfSize(ct),d=E[0]<-h[0]?-1:E[0]>h[0]?1:0,u=E[1]<-h[1]?-1:E[1]>h[1]?1:0,l=E[2]<-h[2]?-1:E[2]>h[2]?1:0,m=Math.abs(d)+Math.abs(u)+Math.abs(l);if(0===m)return 1/0;const p=1===m?4:6,M=6*(d+3*u+9*l+13);t(ft,o),a(ft,ft,h);const b=this.getCenter(ot);for(let t=0;t<p;t++){const a=K[M+t];c(E,((1&a)<<1)-1,(2&a)-1,((4&a)>>1)-1),_(E,E,ft),g(J,b,E),J[3]=1,v(J,J,s);const e=1/Math.max(1e-6,J[3]);V[2*t]=J[0]*e,V[2*t+1]=J[1]*e}const j=2*p-2;let S=V[0]*(V[3]-V[j+1])+V[j]*(V[1]-V[j-1]);for(let t=2;t<j;t+=2)S+=V[t]*(V[t+3]-V[t-1]);return Math.abs(S)*r*n*.125}projectedRadius(t){const a=this.getQuaternion(X);return i(T,a),f(E,t,T),Math.abs(E[0]*this._data[3])+Math.abs(E[1]*this._data[4])+Math.abs(E[2]*this._data[5])}minimumDistancePlane(t){return t[0]*this._data[0]+t[1]*this._data[1]+t[2]*this._data[2]+t[3]-this.projectedRadius(F(t))}maximumDistancePlane(t){return t[0]*this._data[0]+t[1]*this._data[1]+t[2]*this._data[2]+t[3]+this.projectedRadius(F(t))}toAaBoundingBox(a){const e=this.getQuaternion(X),s=t(ft,e),r=this._data[3]*Math.abs(s[0])+this._data[4]*Math.abs(s[3])+this._data[5]*Math.abs(s[6]),i=this._data[3]*Math.abs(s[1])+this._data[4]*Math.abs(s[4])+this._data[5]*Math.abs(s[7]),n=this._data[3]*Math.abs(s[2])+this._data[4]*Math.abs(s[5])+this._data[5]*Math.abs(s[8]);a[0]=this._data[0]-r,a[1]=this._data[1]-i,a[2]=this._data[2]-n,a[3]=this._data[0]+r,a[4]=this._data[1]+i,a[5]=this._data[2]+n}transform(t,a,e,s=0,r=w(e),i=w(a),n=k(a,i)){if(e===r)a.isGeographic?st(this,t,a,s,i):et(this,t,a,s,i,n);else if(a.isWGS84&&(e.isWebMercator||B(e)))$(a,this,e,t,s);else if(a.isWebMercator&&B(e))tt(a,this,e,t,s);else{const r=this.getCenter(ot);r[2]+=s,H(r,a,0,r,e,0),t.center=r,this!==t&&(t.quaternion=this.getQuaternion(X),t.halfSize=this.getHalfSize(ct))}}}const T=h(),X=h(),Y=h(),E=A(),I=A(),J=Q();function N(t,a=new O){return Z(t,a),a}const V=[.1,.2,.3,.4,.5,.6,.7,.8,.9,1,1.1,1.2],K=(()=>{const t=new Int8Array(162);let a=0;const e=e=>{for(let s=0;s<e.length;s++)t[a+s]=e[s];a+=6};return e([6,2,3,1,5,4]),e([0,2,3,1,5,4]),e([0,2,3,7,5,4]),e([0,1,3,2,6,4]),e([0,1,3,2,0,0]),e([0,1,5,7,3,2]),e([0,1,3,7,6,4]),e([0,1,3,7,6,2]),e([0,1,5,7,6,2]),e([0,1,5,4,6,2]),e([0,1,5,4,0,0]),e([0,1,3,7,5,4]),e([0,2,6,4,0,0]),e([0,0,0,0,0,0]),e([1,3,7,5,0,0]),e([2,3,7,6,4,0]),e([2,3,7,6,0,0]),e([2,3,1,5,7,6]),e([0,1,5,7,6,2]),e([0,1,5,7,6,4]),e([0,1,3,7,6,4]),e([4,5,7,6,2,0]),e([4,5,7,6,0,0]),e([4,5,1,3,7,6]),e([0,2,3,7,5,4]),e([6,2,3,7,5,4]),e([6,2,3,1,5,4]),t})();function L(t,a,e,s,r){const n=t.getQuaternion(X);r.quaternion=n,i(T,n);const o=t.getCenter(ot),h=t.getHalfSize(ct);if(1===s){f(mt,o,T),M(_t,mt),j(gt,_t,h),p(gt,_t,gt);const s=S(gt);g(gt,_t,h);const i=S(gt);if(s<e)r.center=o,c(mt,e,e,e),r.halfSize=g(mt,h,mt);else{const n=i>0?1+a/i:1,o=s>0?1+e/s:1,c=(o+n)/2,d=(o-n)/2;m(gt,_t,d),r.halfSize=z(gt,gt,h,c),m(gt,_t,c),z(gt,gt,h,d),x(mt,mt),y(mt,gt,mt);const u=t.getQuaternion(Y);r.center=f(mt,mt,u)}}else{r.center=z(mt,o,P,(e+a)/2);const t=f(mt,P,T);M(t,t),r.halfSize=z(_t,h,t,(e-a)/2)}return r}function $(t,a,e,s,r){a.getCenter(ot),ot[2]+=r;const i=w(e);H(ot,t,0,ot,i,0),at(i,a,ot,e,s)}function tt(t,a,e,s,r){a.getCenter(ot),ot[2]+=r,at(t,a,ot,e,s)}function at(a,e,s,r,i){const n=e.getQuaternion(X),o=t(ft,n),h=e.getHalfSize(ct);for(let t=0;t<8;++t){for(let a=0;a<3;++a)nt[a]=h[a]*(t&1<<a?-1:1);for(let a=0;a<3;++a){let e=s[a];for(let t=0;t<3;++t)e+=nt[t]*o[3*t+a];rt[3*t+a]=e}}H(rt,a,0,rt,r,0,8),N(it,i)}function et(t,a,e,s,r=w(e),o=k(e,r)){t.getCorners(ut),t.getCenter(nt),nt[2]+=s,D(e,nt,dt,r),a.setCenter(dt[12],dt[13],dt[14]);const h=2*Math.sqrt(1+dt[0]+dt[5]+dt[10]);T[0]=(dt[6]-dt[9])/h,T[1]=(dt[8]-dt[2])/h,T[2]=(dt[1]-dt[4])/h,T[3]=.25*h;const d=t.getQuaternion(X);a.quaternion=n(T,T,d),i(T,T),c(_t,0,0,0);const u=a.getCenter(ht);for(const i of ut)i[2]+=s,o(i,0,i,0),p(mt,i,u),f(mt,mt,T),M(mt,mt),b(_t,_t,mt);a.halfSize=_t}function st(t,a,e,s,r=w(e)){const n=R(e),o=1+Math.max(0,s)/(n.radius+t.centerZ);t.getCenter(nt),nt[2]+=s,H(nt,e,0,nt,r,0),a.center=nt;const h=t.getQuaternion(X);a.quaternion=h,i(T,h),c(mt,0,0,1),f(mt,mt,T);const d=t.getHalfSize(ct);c(mt,d[0]*Math.abs(mt[0]),d[1]*Math.abs(mt[1]),d[2]*Math.abs(mt[2])),m(mt,mt,n.inverseFlattening),g(mt,d,mt),a.halfSize=m(mt,mt,o)}const rt=new Array(24),it=new G(rt,3),nt=A(),ot=A(),ht=A(),ct=A(),ft=e(),dt=s(),ut=[[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0],[0,0,0]],lt=[A(),A(),A()],mt=A(),_t=A(),gt=A(),pt=q(-1,-1,-1);function Mt(t){return Array.from(t)}const bt=A(),jt=[0,0,0];export{O as Obb,N as compute,L as computeOffsetObb,Mt as ensurePackedObbData};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as t}from"tslib";import{destroyMaybe as e}from"../../../../core/maybe.js";import{on as r}from"../../../../core/reactiveUtils.js";import{property as i,subclass as o}from"../../../../core/accessorSupport/decorators.js";import{D as s,m as n,d as a}from"../../../../chunks/vec32.js";import{create as l}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import d from"../../../../geometry/Point.js";import{InvalidLayerError as h}from"../../../../layers/support/ElevationQuery.js";import{distanceToScale as p}from"../cameraUtils.js";import{PointOfInterest as c}from"./PointOfInterest.js";import{PropertiesPool as u}from"../../../support/PropertiesPool.js";import{Yield as m}from"../../../support/Yield.js";let _=class extends c{constructor(t){super(t),this._dirty=!1,this._propertiesPool=new u({location:()=>new d,renderLocation:()=>l()},this),this._estimatedSurfaceAltitude=0,this._elevationQueryController=null,this.renderLocation=l(),this._tmpPoint=new d}initialize(){if(this.scheduler&&this.addHandles(this.scheduler.registerTask(this.task,this)),this.runTask(),this.map){const t=()=>this._setDirty();this.addHandles(r(()=>this.map?.ground?.layers,"change",t,{onListenerAdd:t,onListenerRemove:t}))}this._updateRenderLocation()}destroy(){this._cancelPendingRequest(),this._propertiesPool=e(this._propertiesPool)}get _camera(){return this.state.contentCamera}get location(){const t=this._propertiesPool.get("location");return t.spatialReference=this.state.spatialReference,this.renderCoordsHelper.fromRenderCoords(this.renderLocation,t),t}get scale(){const t=this._camera,e=s(t.eye,this.renderLocation),r={renderCoordsHelper:this.renderCoordsHelper,state:{camera:t}};return p(r,e)}get updating(){return this._dirty||null!=this._elevationQueryController}updateRenderLocation(){this._setDirty(),this._updateRenderLocation()}_setDirty(){this._dirty||(this._dirty=!0,this.notifyChange("updating"))}_cancelPendingRequest(){const t=this._elevationQueryController;t&&(this._elevationQueryController=null,t.abort(),this.notifyChange("updating"))}get readyToRun(){return!this._elevationQueryController&&this._dirty}runTask(){if(this._cancelPendingRequest(),this._dirty=!1,this.notifyChange("updating"),!this.map?.ground)return this._updateSurfaceAltitude(0),m;const t=this.state.spatialReference;this._tmpPoint.spatialReference=t,this.renderCoordsHelper.fromRenderCoords(this._camera.eye,this._tmpPoint);const e=(this._tmpPoint.z??0)>f&&1===this.renderCoordsHelper.viewingMode&&(t.isWGS84||t.isWebMercator);let r=new AbortController;return this.map.ground.queryElevation(this._tmpPoint,{signal:r.signal,cache:this.cache,minDemResolution:e?g:0}).then(t=>this._updateSurfaceAltitude(t.geometry.z??0)).catch(t=>{if(t.name===h)if(this.integratedMeshElevationSampler){this._tmpPoint.spatialReference=this.integratedMeshElevationSampler.spatialReference,this.renderCoordsHelper.fromRenderCoords(this._camera.eye,this._tmpPoint);const t=this.integratedMeshElevationSampler.elevationAt(this._tmpPoint.x,this._tmpPoint.y)??0;this._updateSurfaceAltitude(t===this.integratedMeshElevationSampler.noDataValue?0:t)}else this._updateSurfaceAltitude(0)}).catch(()=>{}).then(()=>{this._elevationQueryController===r&&(this._elevationQueryController=null,this.notifyChange("updating")),r=null}),this._elevationQueryController=r,m}_updateSurfaceAltitude(t){this._estimatedSurfaceAltitude!==t&&(this._estimatedSurfaceAltitude=t,this._updateRenderLocation())}_updateRenderLocation(){this.renderCoordsHelper.setAltitude(y,this._estimatedSurfaceAltitude,this._camera.eye),n(this._get("renderLocation"),y)||(this._set("renderLocation",a(this._propertiesPool.get("renderLocation"),y)),this.notifyChange("renderLocation"))}};t([i({constructOnly:!0})],_.prototype,"scheduler",void 0),t([i({constructOnly:!0})],_.prototype,"cache",void 0),t([i({constructOnly:!0})],_.prototype,"map",void 0),t([i({constructOnly:!0})],_.prototype,"task",void 0),t([i({constructOnly:!0})],_.prototype,"integratedMeshElevationSampler",void 0),t([i()],_.prototype,"location",null),t([i()],_.prototype,"renderLocation",void 0),t([i()],_.prototype,"scale",null),t([i()],_.prototype,"updating",null),_=t([o("esri.views.3d.support.pointsOfInterest.CameraOnSurface")],_);const y=l(),f=1e5,g=1e6;export{_ as CameraOnSurface};
5
+ import{__decorate as t}from"tslib";import{destroyMaybe as e}from"../../../../core/maybe.js";import{on as r}from"../../../../core/reactiveUtils.js";import{property as i,subclass as o}from"../../../../core/accessorSupport/decorators.js";import{B as s,m as n,d as a}from"../../../../chunks/vec32.js";import{create as l}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import d from"../../../../geometry/Point.js";import{InvalidLayerError as h}from"../../../../layers/support/ElevationQuery.js";import{distanceToScale as p}from"../cameraUtils.js";import{PointOfInterest as c}from"./PointOfInterest.js";import{PropertiesPool as u}from"../../../support/PropertiesPool.js";import{Yield as m}from"../../../support/Yield.js";let _=class extends c{constructor(t){super(t),this._dirty=!1,this._propertiesPool=new u({location:()=>new d,renderLocation:()=>l()},this),this._estimatedSurfaceAltitude=0,this._elevationQueryController=null,this.renderLocation=l(),this._tmpPoint=new d}initialize(){if(this.scheduler&&this.addHandles(this.scheduler.registerTask(this.task,this)),this.runTask(),this.map){const t=()=>this._setDirty();this.addHandles(r(()=>this.map?.ground?.layers,"change",t,{onListenerAdd:t,onListenerRemove:t}))}this._updateRenderLocation()}destroy(){this._cancelPendingRequest(),this._propertiesPool=e(this._propertiesPool)}get _camera(){return this.state.contentCamera}get location(){const t=this._propertiesPool.get("location");return t.spatialReference=this.state.spatialReference,this.renderCoordsHelper.fromRenderCoords(this.renderLocation,t),t}get scale(){const t=this._camera,e=s(t.eye,this.renderLocation),r={renderCoordsHelper:this.renderCoordsHelper,state:{camera:t}};return p(r,e)}get updating(){return this._dirty||null!=this._elevationQueryController}updateRenderLocation(){this._setDirty(),this._updateRenderLocation()}_setDirty(){this._dirty||(this._dirty=!0,this.notifyChange("updating"))}_cancelPendingRequest(){const t=this._elevationQueryController;t&&(this._elevationQueryController=null,t.abort(),this.notifyChange("updating"))}get readyToRun(){return!this._elevationQueryController&&this._dirty}runTask(){if(this._cancelPendingRequest(),this._dirty=!1,this.notifyChange("updating"),!this.map?.ground)return this._updateSurfaceAltitude(0),m;const t=this.state.spatialReference;this._tmpPoint.spatialReference=t,this.renderCoordsHelper.fromRenderCoords(this._camera.eye,this._tmpPoint);const e=(this._tmpPoint.z??0)>f&&1===this.renderCoordsHelper.viewingMode&&(t.isWGS84||t.isWebMercator);let r=new AbortController;return this.map.ground.queryElevation(this._tmpPoint,{signal:r.signal,cache:this.cache,minDemResolution:e?g:0}).then(t=>this._updateSurfaceAltitude(t.geometry.z??0)).catch(t=>{if(t.name===h)if(this.integratedMeshElevationSampler){this._tmpPoint.spatialReference=this.integratedMeshElevationSampler.spatialReference,this.renderCoordsHelper.fromRenderCoords(this._camera.eye,this._tmpPoint);const t=this.integratedMeshElevationSampler.elevationAt(this._tmpPoint.x,this._tmpPoint.y)??0;this._updateSurfaceAltitude(t===this.integratedMeshElevationSampler.noDataValue?0:t)}else this._updateSurfaceAltitude(0)}).catch(()=>{}).then(()=>{this._elevationQueryController===r&&(this._elevationQueryController=null,this.notifyChange("updating")),r=null}),this._elevationQueryController=r,m}_updateSurfaceAltitude(t){this._estimatedSurfaceAltitude!==t&&(this._estimatedSurfaceAltitude=t,this._updateRenderLocation())}_updateRenderLocation(){this.renderCoordsHelper.setAltitude(y,this._estimatedSurfaceAltitude,this._camera.eye),n(this._get("renderLocation"),y)||(this._set("renderLocation",a(this._propertiesPool.get("renderLocation"),y)),this.notifyChange("renderLocation"))}};t([i({constructOnly:!0})],_.prototype,"scheduler",void 0),t([i({constructOnly:!0})],_.prototype,"cache",void 0),t([i({constructOnly:!0})],_.prototype,"map",void 0),t([i({constructOnly:!0})],_.prototype,"task",void 0),t([i({constructOnly:!0})],_.prototype,"integratedMeshElevationSampler",void 0),t([i()],_.prototype,"location",null),t([i()],_.prototype,"renderLocation",void 0),t([i()],_.prototype,"scale",null),t([i()],_.prototype,"updating",null),_=t([o("esri.views.3d.support.pointsOfInterest.CameraOnSurface")],_);const y=l(),f=1e5,g=1e6;export{_ as CameraOnSurface};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as t}from"tslib";import{clamp as e}from"../../../../core/mathUtils.js";import{removeMaybe as r,destroyMaybe as i}from"../../../../core/maybe.js";import{property as s,subclass as o}from"../../../../core/accessorSupport/decorators.js";import{d as a,D as n,j as c,i as u,m as l,F as d}from"../../../../chunks/vec32.js";import{create as p}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getReferenceEllipsoid as h}from"../../../../geometry/ellipsoidUtils.js";import f from"../../../../geometry/Point.js";import{projectBoundingRect as m}from"../../../../geometry/projection/projectBoundingRect.js";import{create as _}from"../../../../geometry/support/aaBoundingRect.js";import{debugFlags as S}from"../debugFlags.js";import{PointOfInterest as y}from"./PointOfInterest.js";import{PropertiesPool as g}from"../../../support/PropertiesPool.js";import{Yield as A}from"../../../support/Yield.js";let j=class extends y{constructor(t){super(t),this._propertiesPool=new g({location:()=>new f,renderLocation:()=>p()},this),this._currentSurfaceAltitude=0,this._latestSurfaceAltitude=0,this.distance=0,this.renderLocation=p(),this.updating=!1}initialize(){this._frameWorker=this.scheduler.registerTask(this.task,this),this.runTask()}destroy(){this._frameWorker=r(this._frameWorker),this._propertiesPool=i(this._propertiesPool)}get _camera(){return this.state.contentCamera}get location(){const t=this._propertiesPool?.get("location");return t?(t.spatialReference=this.state.spatialReference,this.renderCoordsHelper.fromRenderCoords(this.renderLocation,t),t):new f}updateRenderLocation(){this.updating=!0,this._updateRenderLocation()}get estimatedSurfaceAltitude(){return this._latestSurfaceAltitude}get readyToRun(){return this.updating}runTask(){return this._latestSurfaceAltitude=this.estimateSurfaceAltitudeAtCenter(),this._updateRenderLocation(),this.updating=!1,A}_updateRenderLocation(){const t=L;let e=this._calculateSurfaceIntersection(this._currentSurfaceAltitude,t);const r=this._currentSurfaceAltitude!==this._latestSurfaceAltitude;!e&&r&&(e=this._calculateSurfaceIntersection(this._latestSurfaceAltitude,t),e&&(this._currentSurfaceAltitude=this._latestSurfaceAltitude));const i=v;e&&this._latestSurfaceAltitudeChangesDistanceSignificantly(t,i)&&(a(t,i),this._currentSurfaceAltitude=this._latestSurfaceAltitude),e?this.distance=n(this._camera.eye,t):(c(t,this._camera.viewForward,this._get("distance")),u(t,t,this._camera.eye)),l(this._get("renderLocation"),t)||this._set("renderLocation",a(this._propertiesPool.get("renderLocation"),t))}_calculateSurfaceIntersection(t,r){const i=this._camera;if(!this.renderCoordsHelper.intersectInfiniteManifold(i.ray,t,r))return!1;if(this.state.isGlobal){const e=h(this.renderCoordsHelper.spatialReference).radius,s=e+t,o=d(i.eye),a=o<s*s,l=n(i.eye,r);if(a&&l>e/4){const t=s-Math.sqrt(o);return c(r,i.viewForward,t),u(r,r,i.eye),!0}}else{const t=this.surface?.ready?this.surface.groundExtent:null;null!=t&&m(t,this.surface?.spatialReference,C,this.renderCoordsHelper.spatialReference)&&(r[0]=e(r[0],C[0],C[2]),r[1]=e(r[1],C[1],C[3]))}return!0}_latestSurfaceAltitudeChangesDistanceSignificantly(t,e){if(this._latestSurfaceAltitude===this._currentSurfaceAltitude||null==t)return!1;if(this._calculateSurfaceIntersection(this._latestSurfaceAltitude,e)){if(S.TESTS_DISABLE_OPTIMIZATIONS)return!0;const r=this._camera.eye,i=n(r,t),s=n(r,e);if(Math.abs(s-i)/i>R)return!0}return!1}};t([s({constructOnly:!0})],j.prototype,"scheduler",void 0),t([s({constructOnly:!0})],j.prototype,"task",void 0),t([s()],j.prototype,"distance",void 0),t([s({constructOnly:!0})],j.prototype,"estimateSurfaceAltitudeAtCenter",void 0),t([s({readOnly:!0})],j.prototype,"location",null),t([s({readOnly:!0})],j.prototype,"renderLocation",void 0),t([s()],j.prototype,"updating",void 0),j=t([o("esri.views.3d.support.pointsOfInterest.CenterOnSurface")],j);const R=.05,L=p(),v=p(),C=_();export{j as CenterOnSurface};
5
+ import{__decorate as t}from"tslib";import{clamp as e}from"../../../../core/mathUtils.js";import{removeMaybe as r,destroyMaybe as i}from"../../../../core/maybe.js";import{property as s,subclass as o}from"../../../../core/accessorSupport/decorators.js";import{d as a,B as n,j as c,i as u,m as l,D as d}from"../../../../chunks/vec32.js";import{create as p}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import{getReferenceEllipsoid as h}from"../../../../geometry/ellipsoidUtils.js";import f from"../../../../geometry/Point.js";import{projectBoundingRect as m}from"../../../../geometry/projection/projectBoundingRect.js";import{create as _}from"../../../../geometry/support/aaBoundingRect.js";import{debugFlags as S}from"../debugFlags.js";import{PointOfInterest as y}from"./PointOfInterest.js";import{PropertiesPool as g}from"../../../support/PropertiesPool.js";import{Yield as A}from"../../../support/Yield.js";let j=class extends y{constructor(t){super(t),this._propertiesPool=new g({location:()=>new f,renderLocation:()=>p()},this),this._currentSurfaceAltitude=0,this._latestSurfaceAltitude=0,this.distance=0,this.renderLocation=p(),this.updating=!1}initialize(){this._frameWorker=this.scheduler.registerTask(this.task,this),this.runTask()}destroy(){this._frameWorker=r(this._frameWorker),this._propertiesPool=i(this._propertiesPool)}get _camera(){return this.state.contentCamera}get location(){const t=this._propertiesPool?.get("location");return t?(t.spatialReference=this.state.spatialReference,this.renderCoordsHelper.fromRenderCoords(this.renderLocation,t),t):new f}updateRenderLocation(){this.updating=!0,this._updateRenderLocation()}get estimatedSurfaceAltitude(){return this._latestSurfaceAltitude}get readyToRun(){return this.updating}runTask(){return this._latestSurfaceAltitude=this.estimateSurfaceAltitudeAtCenter(),this._updateRenderLocation(),this.updating=!1,A}_updateRenderLocation(){const t=L;let e=this._calculateSurfaceIntersection(this._currentSurfaceAltitude,t);const r=this._currentSurfaceAltitude!==this._latestSurfaceAltitude;!e&&r&&(e=this._calculateSurfaceIntersection(this._latestSurfaceAltitude,t),e&&(this._currentSurfaceAltitude=this._latestSurfaceAltitude));const i=v;e&&this._latestSurfaceAltitudeChangesDistanceSignificantly(t,i)&&(a(t,i),this._currentSurfaceAltitude=this._latestSurfaceAltitude),e?this.distance=n(this._camera.eye,t):(c(t,this._camera.viewForward,this._get("distance")),u(t,t,this._camera.eye)),l(this._get("renderLocation"),t)||this._set("renderLocation",a(this._propertiesPool.get("renderLocation"),t))}_calculateSurfaceIntersection(t,r){const i=this._camera;if(!this.renderCoordsHelper.intersectInfiniteManifold(i.ray,t,r))return!1;if(this.state.isGlobal){const e=h(this.renderCoordsHelper.spatialReference).radius,s=e+t,o=d(i.eye),a=o<s*s,l=n(i.eye,r);if(a&&l>e/4){const t=s-Math.sqrt(o);return c(r,i.viewForward,t),u(r,r,i.eye),!0}}else{const t=this.surface?.ready?this.surface.groundExtent:null;null!=t&&m(t,this.surface?.spatialReference,C,this.renderCoordsHelper.spatialReference)&&(r[0]=e(r[0],C[0],C[2]),r[1]=e(r[1],C[1],C[3]))}return!0}_latestSurfaceAltitudeChangesDistanceSignificantly(t,e){if(this._latestSurfaceAltitude===this._currentSurfaceAltitude||null==t)return!1;if(this._calculateSurfaceIntersection(this._latestSurfaceAltitude,e)){if(S.TESTS_DISABLE_OPTIMIZATIONS)return!0;const r=this._camera.eye,i=n(r,t),s=n(r,e);if(Math.abs(s-i)/i>R)return!0}return!1}};t([s({constructOnly:!0})],j.prototype,"scheduler",void 0),t([s({constructOnly:!0})],j.prototype,"task",void 0),t([s()],j.prototype,"distance",void 0),t([s({constructOnly:!0})],j.prototype,"estimateSurfaceAltitudeAtCenter",void 0),t([s({readOnly:!0})],j.prototype,"location",null),t([s({readOnly:!0})],j.prototype,"renderLocation",void 0),t([s()],j.prototype,"updating",void 0),j=t([o("esri.views.3d.support.pointsOfInterest.CenterOnSurface")],j);const R=.05,L=p(),v=p(),C=_();export{j as CenterOnSurface};
@@ -2,4 +2,4 @@
2
2
  All material copyright Esri, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/5.0/esri/copyright.txt for details.
4
4
  */
5
- import{__decorate as e}from"tslib";import{clamp as t}from"../../../../core/mathUtils.js";import{destroyMaybe as r}from"../../../../core/maybe.js";import{watch as o}from"../../../../core/reactiveUtils.js";import{createRenderScreenPointArray3 as i}from"../../../../core/screenUtils.js";import{property as n,subclass as s}from"../../../../core/accessorSupport/decorators.js";import{m as a,g as c,G as d,d as p,l,e as u,n as h}from"../../../../chunks/vec32.js";import{create as m}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import f from"../../../../geometry/Point.js";import{wrap as y}from"../../../../geometry/support/ray.js";import{PointOfInterest as g}from"./PointOfInterest.js";import{PropertiesPool as P}from"../../../support/PropertiesPool.js";import{TaskPriority as _}from"../../../support/Scheduler.js";import{Yield as L}from"../../../support/Yield.js";let R=class extends g{constructor(e){super(e),this._propertiesPool=new P({location:()=>new f,renderLocation:()=>m()},this),this._dirty=!0,this.renderLocation=this._propertiesPool.get("renderLocation")}initialize(){this.addHandles([o(()=>this.centerOnSurface.renderLocation,()=>this.updateRenderLocation(),{equals:a}),o(()=>this.state.contentCamera,()=>this.updateRenderLocation())]),this.scheduler&&this.addHandles(this.scheduler.registerTask(_.POINT_OF_INTEREST_FREQUENT,this))}destroy(){this._propertiesPool=r(this._propertiesPool)}get updating(){return this._dirty||this.centerOnSurface.updating}get location(){const e=this._propertiesPool.get("location");return e.spatialReference=this.state.spatialReference,this.renderCoordsHelper.fromRenderCoords(this.renderLocation,e),e}get worldUnitsPerContentPixel(){const{camera:e,contentPixelRatio:t}=this.state;return e.computeRenderPixelSizeAt(this.renderLocation)*(e.pixelRatio/t)}get readyToRun(){return this._dirty}runTask(){const e=this._get("renderLocation"),r=this.centerOnSurface.renderLocation,o=this.renderCoordsHelper,i=this.state.contentCamera;this._dirty=!1,o.worldUpAtPosition(r,S);const n=Math.max(0,(Math.acos(c(S,i.viewForward))-.5*Math.PI)*(i.aboveGround?1:-1));if(Number.isNaN(n)){if(!e||!d(e,r)){const e=this._propertiesPool.get("renderLocation");p(e,r),this._set("renderLocation",e)}return L}const s=1-t(n/(.5*Math.PI),0,1),a=s*s*s;this._calculateScreenHorizontalEdgeOnSurface(O);const u=this._propertiesPool.get("renderLocation");return l(u,r,O,a),e&&d(e,u)||this._set("renderLocation",u),L}_calculateScreenHorizontalEdgeOnSurface(e){const t=this.state.contentCamera,r=t.getRenderCenter(i());if(r[1]=t.aboveGround?t.padding[2]:t.fullHeight-t.padding[0],this.estimateSurfaceIntersectionAtRenderPoint(r,e))return e;const o=this.renderCoordsHelper.getAltitude(this.centerOnSurface.renderLocation);if(t.unprojectFromRenderScreen(r,j)){u(j,j,t.eye);const r=h(j,j);if(this.renderCoordsHelper.intersectInfiniteManifold(y(t.eye,r),o,e))return e}return this.renderCoordsHelper.setAltitude(e,o,t.eye)}updateRenderLocation(){this._dirty=!0}};e([n()],R.prototype,"_dirty",void 0),e([n({constructOnly:!0})],R.prototype,"scheduler",void 0),e([n({constructOnly:!0})],R.prototype,"centerOnSurface",void 0),e([n({constructOnly:!0})],R.prototype,"estimateSurfaceIntersectionAtRenderPoint",void 0),e([n()],R.prototype,"updating",null),e([n()],R.prototype,"location",null),e([n()],R.prototype,"renderLocation",void 0),e([n()],R.prototype,"worldUnitsPerContentPixel",null),R=e([s("esri.views.3d.support.pointsOfInterest.Focus")],R);const S=m(),j=m(),O=m();export{R as Focus};
5
+ import{__decorate as e}from"tslib";import{clamp as t}from"../../../../core/mathUtils.js";import{destroyMaybe as r}from"../../../../core/maybe.js";import{watch as o}from"../../../../core/reactiveUtils.js";import{createRenderScreenPointArray3 as i}from"../../../../core/screenUtils.js";import{property as n,subclass as s}from"../../../../core/accessorSupport/decorators.js";import{m as a,g as c,E as d,d as p,l,e as u,n as h}from"../../../../chunks/vec32.js";import{create as m}from"../../../../core/libs/gl-matrix-2/factories/vec3f64.js";import f from"../../../../geometry/Point.js";import{wrap as y}from"../../../../geometry/support/ray.js";import{PointOfInterest as g}from"./PointOfInterest.js";import{PropertiesPool as P}from"../../../support/PropertiesPool.js";import{TaskPriority as _}from"../../../support/Scheduler.js";import{Yield as L}from"../../../support/Yield.js";let R=class extends g{constructor(e){super(e),this._propertiesPool=new P({location:()=>new f,renderLocation:()=>m()},this),this._dirty=!0,this.renderLocation=this._propertiesPool.get("renderLocation")}initialize(){this.addHandles([o(()=>this.centerOnSurface.renderLocation,()=>this.updateRenderLocation(),{equals:a}),o(()=>this.state.contentCamera,()=>this.updateRenderLocation())]),this.scheduler&&this.addHandles(this.scheduler.registerTask(_.POINT_OF_INTEREST_FREQUENT,this))}destroy(){this._propertiesPool=r(this._propertiesPool)}get updating(){return this._dirty||this.centerOnSurface.updating}get location(){const e=this._propertiesPool.get("location");return e.spatialReference=this.state.spatialReference,this.renderCoordsHelper.fromRenderCoords(this.renderLocation,e),e}get worldUnitsPerContentPixel(){const{camera:e,contentPixelRatio:t}=this.state;return e.computeRenderPixelSizeAt(this.renderLocation)*(e.pixelRatio/t)}get readyToRun(){return this._dirty}runTask(){const e=this._get("renderLocation"),r=this.centerOnSurface.renderLocation,o=this.renderCoordsHelper,i=this.state.contentCamera;this._dirty=!1,o.worldUpAtPosition(r,S);const n=Math.max(0,(Math.acos(c(S,i.viewForward))-.5*Math.PI)*(i.aboveGround?1:-1));if(Number.isNaN(n)){if(!e||!d(e,r)){const e=this._propertiesPool.get("renderLocation");p(e,r),this._set("renderLocation",e)}return L}const s=1-t(n/(.5*Math.PI),0,1),a=s*s*s;this._calculateScreenHorizontalEdgeOnSurface(O);const u=this._propertiesPool.get("renderLocation");return l(u,r,O,a),e&&d(e,u)||this._set("renderLocation",u),L}_calculateScreenHorizontalEdgeOnSurface(e){const t=this.state.contentCamera,r=t.getRenderCenter(i());if(r[1]=t.aboveGround?t.padding[2]:t.fullHeight-t.padding[0],this.estimateSurfaceIntersectionAtRenderPoint(r,e))return e;const o=this.renderCoordsHelper.getAltitude(this.centerOnSurface.renderLocation);if(t.unprojectFromRenderScreen(r,j)){u(j,j,t.eye);const r=h(j,j);if(this.renderCoordsHelper.intersectInfiniteManifold(y(t.eye,r),o,e))return e}return this.renderCoordsHelper.setAltitude(e,o,t.eye)}updateRenderLocation(){this._dirty=!0}};e([n()],R.prototype,"_dirty",void 0),e([n({constructOnly:!0})],R.prototype,"scheduler",void 0),e([n({constructOnly:!0})],R.prototype,"centerOnSurface",void 0),e([n({constructOnly:!0})],R.prototype,"estimateSurfaceIntersectionAtRenderPoint",void 0),e([n()],R.prototype,"updating",null),e([n()],R.prototype,"location",null),e([n()],R.prototype,"renderLocation",void 0),e([n()],R.prototype,"worldUnitsPerContentPixel",null),R=e([s("esri.views.3d.support.pointsOfInterest.Focus")],R);const S=m(),j=m(),O=m();export{R as Focus};