@arcgis/core 4.32.0-next.20241021 → 4.32.0-next.20241023

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 (257) hide show
  1. package/applications/MapViewer/templateUtils.d.ts +4 -0
  2. package/applications/MapViewer/templateUtils.js +5 -0
  3. package/assets/esri/core/workers/RemoteClient.js +1 -1
  4. package/assets/esri/core/workers/chunks/0b7ee57bec7ffac312f2.js +1 -0
  5. package/assets/esri/core/workers/chunks/{1ba1d9c867ec6a492af9.js → 0f3912bca9fe25eea75c.js} +1 -1
  6. package/assets/esri/core/workers/chunks/{842ebde78db9bfcaf07b.js → 1678d1d0ecb9b2af69a8.js} +1 -1
  7. package/assets/esri/core/workers/chunks/1d16ca7791f64dd7c7fb.js +1 -0
  8. package/assets/esri/core/workers/chunks/1d4be734ff961e313257.js +1 -0
  9. package/assets/esri/core/workers/chunks/{b292758308dfac4ba8ee.js → 2d8aa31dc96bbd014036.js} +1 -1
  10. package/assets/esri/core/workers/chunks/{53f648321c5fde26bfe4.js → 319e06888467f9f460ab.js} +1 -1
  11. package/assets/esri/core/workers/chunks/33cae7ece52a77394b05.js +1 -0
  12. package/assets/esri/core/workers/chunks/{210a954f5299fe105e0b.js → 539060ffb7f230fb1bd0.js} +1 -1
  13. package/assets/esri/core/workers/chunks/545441dcc8e915e63ff1.js +1 -0
  14. package/assets/esri/core/workers/chunks/{303f39b9b7bd33109df8.js → 587df97288a83721d251.js} +1 -1
  15. package/assets/esri/core/workers/chunks/5caa02a7a85d05e253b4.js +1 -0
  16. package/assets/esri/core/workers/chunks/5cfecb320e1dcd258b2e.js +1 -0
  17. package/assets/esri/core/workers/chunks/67018ef25736f0722f6e.js +1 -0
  18. package/assets/esri/core/workers/chunks/89f74819ac1b5884c149.js +1 -0
  19. package/assets/esri/core/workers/chunks/92b2d81ef16877341f97.js +1 -0
  20. package/assets/esri/core/workers/chunks/{e6e77cbdeb99d90caad1.js → 97f62fad6d416a666319.js} +1 -1
  21. package/assets/esri/core/workers/chunks/98c1956b2e27058c8a51.js +1 -0
  22. package/assets/esri/core/workers/chunks/9c8a910b6261a4d5da77.js +1 -0
  23. package/assets/esri/core/workers/chunks/ab6eaa3ae2e233f91a5e.js +1 -0
  24. package/assets/esri/core/workers/chunks/{63719f892a7d1025c7d3.js → b42c1ab7579a3c464f72.js} +1 -1
  25. package/assets/esri/core/workers/chunks/{03eba36affe6ed1f5a11.js → bc4ef18d0a02354186e3.js} +7 -7
  26. package/assets/esri/core/workers/chunks/{c71304c88fce556340ef.js → c859f73b57a764e99b02.js} +1 -1
  27. package/assets/esri/core/workers/chunks/cb3038ec3ef0d86bf2a0.js +1 -0
  28. package/assets/esri/core/workers/chunks/{ae20ca2008a2ea6a46b2.js → d8f4bd2b4366388f8a28.js} +1 -1
  29. package/assets/esri/core/workers/chunks/e71fa25ed45bae5a1adb.js +320 -0
  30. package/assets/esri/core/workers/chunks/{9c9a8a529494c6d1dfa3.js → ec9d5af8887854e821c8.js} +1 -1
  31. package/assets/esri/libs/parquet/pkg/arcgis_parquet_bg.wasm +0 -0
  32. package/assets/esri/themes/base/widgets/_BatchAttributeForm.scss +14 -0
  33. package/assets/esri/themes/base/widgets/_OrientedImageryViewer.scss +1 -1
  34. package/assets/esri/themes/dark/main.css +1 -1
  35. package/assets/esri/themes/light/main.css +1 -1
  36. package/assets/esri/themes/light/view.css +1 -1
  37. package/chunks/Bufferer-BhkgvSV4.js +5 -0
  38. package/chunks/{Distance2DCalculator-DM4OojiI.js → Distance2DCalculator-BX0Ep7eP.js} +1 -1
  39. package/chunks/{GeodeticDistanceCalculator-DzvUOSaR.js → GeodeticDistanceCalculator-B5uO-Y_z.js} +1 -1
  40. package/chunks/OperatorCrosses.js +5 -0
  41. package/chunks/OperatorCut.js +1 -1
  42. package/chunks/OperatorGeodesicBuffer.js +1 -1
  43. package/chunks/OperatorGeodeticArea.js +1 -1
  44. package/chunks/OperatorGeodeticDensifyByLength.js +1 -1
  45. package/chunks/OperatorGeodeticDistance.js +1 -1
  46. package/chunks/OperatorGeodeticLength.js +1 -1
  47. package/chunks/OperatorIntersects.js +5 -0
  48. package/chunks/OperatorMultiPartToSinglePart.js +1 -1
  49. package/chunks/OperatorOverlaps.js +5 -0
  50. package/chunks/OperatorProximity.js +1 -1
  51. package/chunks/OperatorProximityGeodesic.js +1 -1
  52. package/chunks/OperatorShapePreservingLength.js +1 -1
  53. package/chunks/OperatorTouches.js +5 -0
  54. package/chunks/OperatorWithin.js +5 -0
  55. package/chunks/QuadraticBezier.js +1 -1
  56. package/chunks/SSAOBlur.glsl.js +5 -5
  57. package/chunks/SideCalculator2D-CoWc8Oe3.js +1 -1
  58. package/chunks/Transformation2D.js +1 -1
  59. package/core/MemCache.js +1 -1
  60. package/core/MemCachePool.js +1 -1
  61. package/core/unitUtils.js +1 -1
  62. package/geometry/Mesh.js +1 -1
  63. package/geometry/operators/affineTransformOperator.js +1 -1
  64. package/geometry/operators/alphaShapeOperator.js +1 -1
  65. package/geometry/operators/areaOperator.js +1 -1
  66. package/geometry/operators/autoCompleteOperator.js +1 -1
  67. package/geometry/operators/boundaryOperator.js +1 -1
  68. package/geometry/operators/bufferOperator.js +1 -1
  69. package/geometry/operators/centroidOperator.js +1 -1
  70. package/geometry/operators/clipOperator.js +1 -1
  71. package/geometry/operators/containsOperator.js +1 -1
  72. package/geometry/operators/convexHullOperator.js +1 -1
  73. package/geometry/operators/crossesOperator.js +1 -1
  74. package/geometry/operators/cutOperator.js +1 -1
  75. package/geometry/operators/densifyOperator.js +1 -1
  76. package/geometry/operators/differenceOperator.js +1 -1
  77. package/geometry/operators/disjointOperator.js +1 -1
  78. package/geometry/operators/distanceOperator.js +1 -1
  79. package/geometry/operators/equalsOperator.js +1 -1
  80. package/geometry/operators/extendOperator.js +1 -1
  81. package/geometry/operators/generalizeOperator.js +1 -1
  82. package/geometry/operators/geodesicBufferOperator.js +1 -1
  83. package/geometry/operators/geodesicProximityOperator.js +1 -1
  84. package/geometry/operators/geodeticAreaOperator.js +1 -1
  85. package/geometry/operators/geodeticDensifyOperator.js +1 -1
  86. package/geometry/operators/geodeticDistanceOperator.js +1 -1
  87. package/geometry/operators/geodeticLengthOperator.js +1 -1
  88. package/geometry/operators/graphicBufferOperator.js +1 -1
  89. package/geometry/operators/gx/operatorAlphaShape.js +1 -1
  90. package/geometry/operators/gx/operatorAutoComplete.js +1 -1
  91. package/geometry/operators/gx/operatorBoundary.js +1 -1
  92. package/geometry/operators/gx/operatorBuffer.js +1 -1
  93. package/geometry/operators/gx/operatorConvexHull.js +1 -1
  94. package/geometry/operators/gx/operatorDifference.js +1 -1
  95. package/geometry/operators/gx/operatorGeodesicBuffer.js +1 -1
  96. package/geometry/operators/gx/operatorGeodeticArea.js +1 -1
  97. package/geometry/operators/gx/operatorGeodeticDensify.js +1 -1
  98. package/geometry/operators/gx/operatorGeodeticDistance.js +1 -1
  99. package/geometry/operators/gx/operatorGeodeticLength.js +1 -1
  100. package/geometry/operators/gx/operatorGraphicBuffer.js +1 -1
  101. package/geometry/operators/gx/operatorIntegrate.js +1 -1
  102. package/geometry/operators/gx/operatorIntersection.js +1 -1
  103. package/geometry/operators/gx/operatorLabelPoint.js +1 -1
  104. package/geometry/operators/gx/operatorLinesToPolygons.js +1 -1
  105. package/geometry/operators/gx/operatorLocateBetween.js +1 -1
  106. package/geometry/operators/gx/operatorOffset.js +1 -1
  107. package/geometry/operators/gx/operatorPolygonOverlay.js +1 -1
  108. package/geometry/operators/gx/operatorPolygonSlicer.js +1 -1
  109. package/geometry/operators/gx/operatorProject.js +1 -1
  110. package/geometry/operators/gx/operatorProximityGeodesic.js +1 -1
  111. package/geometry/operators/gx/operatorSimplify.js +1 -1
  112. package/geometry/operators/gx/operatorSymmetricDifference.js +1 -1
  113. package/geometry/operators/gx/operatorUnion.js +1 -1
  114. package/geometry/operators/integrateOperator.js +1 -1
  115. package/geometry/operators/intersectionOperator.js +1 -1
  116. package/geometry/operators/intersectsOperator.js +1 -1
  117. package/geometry/operators/isNearOperator.js +1 -1
  118. package/geometry/operators/json/containsOperator.js +5 -0
  119. package/geometry/operators/json/crossesOperator.js +5 -0
  120. package/geometry/operators/json/disjointOperator.js +5 -0
  121. package/geometry/operators/json/intersectsOperator.js +5 -0
  122. package/geometry/operators/json/offsetOperator.js +5 -0
  123. package/geometry/operators/json/overlapsOperator.js +5 -0
  124. package/geometry/operators/json/touchesOperator.js +5 -0
  125. package/geometry/operators/json/withinOperator.js +5 -0
  126. package/geometry/operators/labelPointOperator.js +1 -1
  127. package/geometry/operators/lengthOperator.js +1 -1
  128. package/geometry/operators/linesToPolygonsOperator.js +1 -1
  129. package/geometry/operators/locateBetweenOperator.js +1 -1
  130. package/geometry/operators/minimumBoundingCircleOperator.js +1 -1
  131. package/geometry/operators/multiPartToSinglePartOperator.js +1 -1
  132. package/geometry/operators/offsetOperator.js +1 -1
  133. package/geometry/operators/overlapsOperator.js +1 -1
  134. package/geometry/operators/polygonOverlayOperator.js +1 -1
  135. package/geometry/operators/polygonSlicerOperator.js +1 -1
  136. package/geometry/operators/projectOperator.js +1 -1
  137. package/geometry/operators/proximityOperator.js +1 -1
  138. package/geometry/operators/relateOperator.js +1 -1
  139. package/geometry/operators/reshapeOperator.js +1 -1
  140. package/geometry/operators/simplifyOperator.js +1 -1
  141. package/geometry/operators/singlePartToMultiPartOperator.js +1 -1
  142. package/geometry/operators/support/apiConverter.js +5 -0
  143. package/geometry/operators/support/initNoPeFactory.js +5 -0
  144. package/geometry/operators/support/jsonConverter.js +5 -0
  145. package/geometry/operators/support/proximityResult.js +1 -1
  146. package/geometry/operators/symmetricDifferenceOperator.js +1 -1
  147. package/geometry/operators/touchesOperator.js +1 -1
  148. package/geometry/operators/unionOperator.js +1 -1
  149. package/geometry/operators/withinOperator.js +1 -1
  150. package/geometry/support/MeshVertexAttributes.js +1 -1
  151. package/interfaces.d.ts +134 -0
  152. package/layers/LinkChartLayer.js +1 -1
  153. package/layers/SceneLayer.js +1 -1
  154. package/layers/graphics/OptimizedGeometry.js +1 -1
  155. package/layers/graphics/sources/ParquetSource.js +1 -1
  156. package/layers/knowledgeGraph/supportUtils.js +1 -1
  157. package/layers/support/ElevationQueryTileCache.js +1 -1
  158. package/layers/support/ElevationTileData.js +1 -1
  159. package/layers/support/mediaUtils.js +1 -1
  160. package/layers/support/parquetLayerUtils.js +1 -1
  161. package/layers/support/rasterFunctions/ClipFunction.js +1 -1
  162. package/layers/support/rasterFunctions/clipUtils.js +1 -1
  163. package/layers/support/rasterFunctions/localUtils.js +1 -1
  164. package/libs/parquet/parquet.js +1 -1
  165. package/linkChart/LinkChartProperties.js +1 -1
  166. package/package.json +1 -1
  167. package/smartMapping/raster/renderers/classBreaks.js +1 -1
  168. package/smartMapping/raster/renderers/rgb.js +1 -1
  169. package/smartMapping/raster/renderers/stretch.js +1 -1
  170. package/smartMapping/raster/support/adapters/ImageryTileLayerAdapter.js +1 -1
  171. package/smartMapping/raster/support/adapters/RasterLayerAdapter.js +1 -1
  172. package/smartMapping/renderers/support/rendererUtils.d.ts +4 -0
  173. package/support/revision.js +1 -1
  174. package/symbols/cim/effects/EffectControlMeasureLine.js +1 -1
  175. package/views/2d/engine/vectorTiles/RenderBucket.js +1 -1
  176. package/views/2d/engine/vectorTiles/TileHandler3D.js +1 -1
  177. package/views/2d/engine/vectorTiles/VectorTile.js +1 -1
  178. package/views/2d/engine/webgl/shaderGraph/techniques/animated/AnimatedMarkerMeshWriter.js +1 -1
  179. package/views/2d/engine/webgl/shaderGraph/techniques/animated/AnimatedMarkerShader.js +1 -1
  180. package/views/2d/grid/GridView2D.js +1 -1
  181. package/views/2d/layers/FeatureLayerView2D.js +1 -1
  182. package/views/2d/layers/MediaLayerView2D.js +1 -1
  183. package/views/2d/layers/TileLayerView2D.js +1 -1
  184. package/views/2d/layers/features/layerAdapters/ParquetLayerAdapter.js +1 -1
  185. package/views/2d/layers/features/schema/processor/symbols/ComplexSymbolSchema.js +1 -1
  186. package/views/2d/layers/features/support/FeatureSetReaderParquet.js +1 -1
  187. package/views/3d/analysis/Viewshed/ViewshedSubTool.js +1 -1
  188. package/views/3d/camera/constraintUtils/tilt.js +1 -1
  189. package/views/3d/glTF/loader.js +1 -1
  190. package/views/3d/layers/I3SMeshView3D.js +1 -1
  191. package/views/3d/layers/IntegratedMesh3DTilesLayerView3D.js +1 -1
  192. package/views/3d/layers/PointCloudLayerView3D.js +1 -1
  193. package/views/3d/layers/SceneLayerGraphicsView3D.js +1 -1
  194. package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
  195. package/views/3d/layers/graphics/Graphics3DSymbol.js +1 -1
  196. package/views/3d/layers/graphics/Graphics3DWebStyleSymbol.js +1 -1
  197. package/views/3d/layers/graphics/ObjectResourceCache.js +1 -1
  198. package/views/3d/layers/graphics/wosrLoader.js +1 -1
  199. package/views/3d/layers/i3s/CachedMeshData.js +5 -0
  200. package/views/3d/layers/i3s/I3SClientNodeLoader.js +1 -1
  201. package/views/3d/layers/i3s/I3SOverrides.js +1 -1
  202. package/views/3d/layers/i3s/PointRenderer.js +1 -1
  203. package/views/3d/layers/support/FeatureTile.js +1 -1
  204. package/views/3d/layers/support/FeatureTileFetcher3D.js +1 -1
  205. package/views/3d/state/ViewStateManager.js +1 -1
  206. package/views/3d/state/controllers/FovController.js +1 -1
  207. package/views/3d/support/buffer/InterleavedLayout.js +1 -1
  208. package/views/3d/terrain/Tile.js +1 -1
  209. package/views/3d/terrain/TileTexture.js +1 -1
  210. package/views/3d/webgl/ManagedFBO.js +1 -1
  211. package/views/3d/webgl/ManagedFBOAttachment.js +1 -1
  212. package/views/3d/webgl-engine/core/FBOCache.js +1 -1
  213. package/views/3d/webgl-engine/core/FBOPool.js +1 -1
  214. package/views/3d/webgl-engine/core/shaderLibrary/output/OutputHighlight.glsl.js +1 -1
  215. package/views/3d/webgl-engine/lib/edgeRendering/EdgeView.js +1 -1
  216. package/views/3d/webgl-engine/materials/ProceduralTextureRepository.js +1 -1
  217. package/views/3d/webgl-engine/materials/renderers/MergedRenderer.js +1 -1
  218. package/views/3d/webgl-engine/shaders/SSAOBlur.glsl.js +1 -1
  219. package/views/input/BrowserEventSource.js +1 -1
  220. package/views/webgl/Texture.js +1 -1
  221. package/views/webgl/VertexArrayObject.js +1 -1
  222. package/webdoc/support/webdocSaveUtils.js +1 -1
  223. package/widgets/Attribution/AttributionViewModel.js +1 -1
  224. package/widgets/BatchAttributeForm/BatchAttributeFormViewModel.js +1 -1
  225. package/widgets/BatchAttributeForm/css.js +1 -1
  226. package/widgets/BatchAttributeForm/templates/support/createBatchFormTemplate.js +1 -1
  227. package/widgets/BatchAttributeForm.js +1 -1
  228. package/widgets/ElevationProfile/support/ElevationProfileView2D.js +1 -1
  229. package/widgets/ElevationProfile/support/ProfileLine2D.js +5 -0
  230. package/widgets/ElevationProfile/support/ProfileLines3D.js +1 -1
  231. package/widgets/ElevationProfile/support/constants.js +1 -1
  232. package/widgets/ElevationProfile/support/visualizationUtils.js +5 -0
  233. package/widgets/FeatureTable/FeatureTableViewModel.js +1 -1
  234. package/widgets/FeatureTable/Grid/GridViewModel.js +1 -1
  235. package/widgets/FeatureTable/support/columnUtils.js +1 -1
  236. package/widgets/FeatureTable/support/tableUtils.js +1 -1
  237. package/widgets/FeatureTable/support/templateUtils.js +5 -0
  238. package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
  239. package/widgets/support/GridControls/GridControlsViewModel.js +1 -1
  240. package/widgets/support/GridControls.js +1 -1
  241. package/assets/esri/core/workers/chunks/03d0394fff1463c224f9.js +0 -1
  242. package/assets/esri/core/workers/chunks/0c40cac18711f79f0a7d.js +0 -1
  243. package/assets/esri/core/workers/chunks/1a97f98facfc62a9fc69.js +0 -1
  244. package/assets/esri/core/workers/chunks/1e3ed3ee48c2977cff6f.js +0 -1
  245. package/assets/esri/core/workers/chunks/1fc064e37d030e449d5e.js +0 -1
  246. package/assets/esri/core/workers/chunks/4daab36de5efa03a8cbb.js +0 -1
  247. package/assets/esri/core/workers/chunks/77d129134c2a66cd86d8.js +0 -1
  248. package/assets/esri/core/workers/chunks/88bd9e023764da377aa7.js +0 -1
  249. package/assets/esri/core/workers/chunks/92ce57cb12d9a7a3699e.js +0 -1
  250. package/assets/esri/core/workers/chunks/a5675c989d00b7400f98.js +0 -1
  251. package/assets/esri/core/workers/chunks/c06c5c815b5e37717fa1.js +0 -1
  252. package/assets/esri/core/workers/chunks/ca1385e165aae8a32ca2.js +0 -1
  253. package/assets/esri/core/workers/chunks/ce8c1208916f54af7e68.js +0 -320
  254. package/assets/esri/core/workers/chunks/df51c93b2dbcc89efc23.js +0 -1
  255. package/assets/esri/core/workers/chunks/efa3c919261672871f2f.js +0 -1
  256. package/chunks/Bufferer-fr1_Nc47.js +0 -5
  257. package/geometry/operators/support/converterAPI.js +0 -5
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{c as e}from"../../chunks/Centroid-DZi-eb9F.js";import{fromGeometry as r,toPoint as t,getSpatialReference as n}from"./support/converterAPI.js";class u{getOperatorType(){return 10205}accelerateGeometry(e,r,t){return!1}canAccelerateGeometry(e){return!1}supportsCurves(){return!0}execute(r,t){return e(r)}}const o=new u;function c(e){const u=o.execute(r(e),null);return t(u,n(e))}function s(){return o.supportsCurves()}export{c as execute,s as supportsCurves};
5
+ import{c as e}from"../../chunks/Centroid-DZi-eb9F.js";import{fromGeometry as r,toPoint as t,getSpatialReference as n}from"./support/apiConverter.js";class u{getOperatorType(){return 10205}accelerateGeometry(e,r,t){return!1}canAccelerateGeometry(e){return!1}supportsCurves(){return!0}execute(r,t){return e(r)}}const o=new u;function s(e){const u=o.execute(r(e),null);return t(u,n(e))}function c(){return o.supportsCurves()}export{s as execute,c as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{execute as e,executeMany as r,supportsCurves as o}from"./gx/operatorClip.js";import{getSpatialReference as t,fromExtent as n,toGeometry as p,fromSpatialReference as s,fromGeometry as u}from"./support/converterAPI.js";function a(r,o){const a=t(r),c=n(o).asEnvelope2D();return p(e(u(r),c,s(a)),a)}function c(e,o){const a=e.map(u),c=t(e),i=n(o).asEnvelope2D();return r(a,i,s(c)).map((e=>p(e,c)))}function i(){return o()}export{a as execute,c as executeMany,i as supportsCurves};
5
+ import{execute as e,executeMany as r,supportsCurves as o}from"./gx/operatorClip.js";import{getSpatialReference as t,fromExtent as n,toGeometry as p,fromSpatialReference as s,fromGeometry as u}from"./support/apiConverter.js";function a(r,o){const a=t(r),c=n(o).asEnvelope2D();return p(e(u(r),c,s(a)),a)}function c(e,o){const a=e.map(u),c=t(e),i=n(o).asEnvelope2D();return r(a,i,s(c)).map((e=>p(e,c)))}function i(){return o()}export{a as execute,c as executeMany,i as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{f as e}from"../../chunks/QuadraticBezier.js";import{getSpatialReference as r,fromGeometry as t,fromSpatialReference as n}from"./support/converterAPI.js";const o=new e;function u(e){const u=r(e);return o.accelerateGeometry(t(e),n(u),0)}function c(e,r){return o.execute(t(e),t(r),n(e.spatialReference),null)}function s(){return o.supportsCurves()}export{u as accelerateGeometry,c as execute,s as supportsCurves};
5
+ import{f as e}from"../../chunks/QuadraticBezier.js";import{getSpatialReference as r,fromGeometry as t,fromSpatialReference as n}from"./support/apiConverter.js";const o=new e;function u(e){const u=r(e);return o.accelerateGeometry(t(e),n(u),0)}function c(e,r){return o.execute(t(e),t(r),n(e.spatialReference),null)}function s(){return o.supportsCurves()}export{u as accelerateGeometry,c as execute,s as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{execute as r,executeMany as e,isConvex as t,supportsCurves as n}from"./gx/operatorConvexHull.js";import{getSpatialReference as o,toGeometry as u,fromGeometry as s}from"./support/converterAPI.js";function p(e){const t=o(e);return u(r(s(e)),t)}function c(r,t={}){const{merge:n=!1}=t,p=r.map(s),c=o(r);return e(p,n).map((r=>u(r,c)))}function a(r){return t(s(r))}function i(){return n()}export{p as execute,c as executeMany,a as isConvex,i as supportsCurves};
5
+ import{execute as r,executeMany as e,isConvex as t,supportsCurves as n}from"./gx/operatorConvexHull.js";import{getSpatialReference as o,toGeometry as u,fromGeometry as s}from"./support/apiConverter.js";function p(e){const t=o(e);return u(r(s(e)),t)}function a(r,t={}){const{merge:n=!1}=t,p=r.map(s),a=o(r);return e(p,n).map((r=>u(r,a)))}function c(r){return t(s(r))}function i(){return n()}export{p as execute,a as executeMany,c as isConvex,i as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{aK as e,aL as r}from"../../chunks/QuadraticBezier.js";import{getSpatialReference as t,fromGeometry as n,fromSpatialReference as u}from"./support/converterAPI.js";class o extends e{getOperatorType(){return 6}execute(e,t,n,u){return r(e,t,n,16,u)}}const s=new o;function c(e){const r=t(e);return s.accelerateGeometry(n(e),u(r),0)}function a(e,r){return s.execute(n(e),n(r),u(e.spatialReference),null)}function p(){return s.supportsCurves()}export{c as accelerateGeometry,a as execute,p as supportsCurves};
5
+ import{O as e}from"../../chunks/OperatorCrosses.js";import{getSpatialReference as r,fromGeometry as t,fromSpatialReference as n}from"./support/apiConverter.js";const o=new e;function s(e){const s=r(e);return o.accelerateGeometry(t(e),n(s),0)}function u(e,r){return o.execute(t(e),t(r),n(e.spatialReference),null)}function c(){return o.supportsCurves()}export{s as accelerateGeometry,u as execute,c as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{isSome as r}from"../../core/arrayUtils.js";import{execute as t,supportsCurves as o}from"./gx/operatorCut.js";import{getSpatialReference as e,fromSpatialReference as s,fromPolyline as p,fromGeometry as u,toGeometry as n}from"./support/converterAPI.js";function i(o,i){const m=e(o);return t(u(o),p(i),s(m)).map((r=>n(r,m))).filter(r)}function m(){return o()}export{i as execute,m as supportsCurves};
5
+ import{isSome as r}from"../../core/arrayUtils.js";import{execute as t,supportsCurves as o}from"./gx/operatorCut.js";import{getSpatialReference as e,fromSpatialReference as p,fromPolyline as s,fromGeometry as u,toGeometry as i}from"./support/apiConverter.js";function n(o,n){const a=e(o);return t(u(o),s(n),p(a)).map((r=>i(r,a))).filter(r)}function a(){return o()}export{n as execute,a as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{isSome as r}from"../../core/arrayUtils.js";import{deg2rad as t}from"../../core/mathUtils.js";import{convertToSpatialReferenceUnit as e}from"../../core/unitUtils.js";import{execute as o,executeMany as n,supportsCurves as i}from"./gx/operatorDensify.js";import{getSpatialReference as s,toGeometry as m,fromGeometry as a}from"./support/converterAPI.js";function u(r,n,i={}){let{maxAngleInDegrees:u=0,maxDeviation:p=0,unit:c}=i;const f=s(r);return c&&(n=e(n,c,f),p&&(p=e(p,c,f))),m(o(a(r),n,p,t(u)),f)}function p(o,i,u={}){let{maxAngleInDegrees:p=0,maxDeviation:c=0,unit:f}=u;const l=o.map(a),x=s(o);return f&&(i=e(i,f,x),c&&(c=e(c,f,x))),n(l,i,c,t(p)).map((r=>m(r,x))).filter(r)}function c(){return i()}export{u as execute,p as executeMany,c as supportsCurves};
5
+ import{isSome as r}from"../../core/arrayUtils.js";import{deg2rad as t}from"../../core/mathUtils.js";import{convertToSpatialReferenceUnit as e}from"../../core/unitUtils.js";import{execute as o,executeMany as n,supportsCurves as i}from"./gx/operatorDensify.js";import{getSpatialReference as s,toGeometry as a,fromGeometry as m}from"./support/apiConverter.js";function p(r,n,i={}){let{maxAngleInDegrees:p=0,maxDeviation:u=0,unit:c}=i;const f=s(r);return c&&(n=e(n,c,f),u&&(u=e(u,c,f))),a(o(m(r),n,u,t(p)),f)}function u(o,i,p={}){let{maxAngleInDegrees:u=0,maxDeviation:c=0,unit:f}=p;const l=o.map(m),x=s(o);return f&&(i=e(i,f,x),c&&(c=e(c,f,x))),n(l,i,c,t(u)).map((r=>a(r,x))).filter(r)}function c(){return i()}export{p as execute,u as executeMany,c as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{execute as r,executeMany as e,supportsCurves as t}from"./gx/operatorDifference.js";import{getSpatialReference as o,toGeometry as n,fromSpatialReference as s,fromGeometry as u}from"./support/converterAPI.js";function p(e,t){const p=o(e);return n(r(u(e),u(t),s(p)),p)}function c(r,t){const p=r.map(u),c=o(r);return e(p,u(t),s(c)).map((r=>n(r,c)))}function a(){return t()}export{p as execute,c as executeMany,a as supportsCurves};
5
+ import{execute as r,executeMany as e,supportsCurves as t}from"./gx/operatorDifference.js";import{getSpatialReference as o,toGeometry as n,fromSpatialReference as p,fromGeometry as s}from"./support/apiConverter.js";function u(e,t){const u=o(e);return n(r(s(e),s(t),p(u)),u)}function a(r,t){const u=r.map(s),a=o(r);return e(u,s(t),p(a)).map((r=>n(r,a)))}function c(){return t()}export{u as execute,a as executeMany,c as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{p as e}from"../../chunks/QuadraticBezier.js";import{getSpatialReference as r,fromGeometry as t,fromSpatialReference as n}from"./support/converterAPI.js";const o=new e;function c(e){const c=r(e);return o.accelerateGeometry(t(e),n(c),0)}function u(e,r){return o.execute(t(e),t(r),n(e.spatialReference))}function s(){return o.supportsCurves()}export{c as accelerateGeometry,u as execute,s as supportsCurves};
5
+ import{q as e}from"../../chunks/QuadraticBezier.js";import{getSpatialReference as r,fromGeometry as t,fromSpatialReference as n}from"./support/apiConverter.js";const o=new e;function u(e){const u=r(e);return o.accelerateGeometry(t(e),n(u),0)}function c(e,r){return o.execute(t(e),t(r),n(e.spatialReference))}function s(){return o.supportsCurves()}export{u as accelerateGeometry,c as execute,s as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{a as e}from"../../chunks/Geometry.js";import{D as r}from"../../chunks/Distance2DCalculator-DM4OojiI.js";import{convertFromSpatialReferenceUnit as t}from"../../core/unitUtils.js";import{fromGeometry as u,getSpatialReference as n}from"./support/converterAPI.js";class s{getOperatorType(){return 10100}supportsCurves(){return!0}accelerateGeometry(e,r,t){return!1}canAccelerateGeometry(e){return!1}execute(e,r,t){return this.executeEx(e,r,t,null,null,Number.NaN)}executeEx(t,u,n,s,o,c){if(t.isEmpty()||u.isEmpty())return Number.NaN;e(t),e(u);const i=t,m=u;Number.isNaN(c)&&(c=Number.POSITIVE_INFINITY);const a=new r(c,n).calculate(i,m,s,o);return Number.isFinite(a)?a:Number.NaN}}const o=new s;function c(e,r,s={}){const{unit:c}=s;let i=o.execute(u(e),u(r),null);if(i&&c){const r=n(e);i=t(i,r,c)}return i}function i(){return o.supportsCurves()}export{c as execute,i as supportsCurves};
5
+ import{a as e}from"../../chunks/Geometry.js";import{D as r}from"../../chunks/Distance2DCalculator-BX0Ep7eP.js";import{convertFromSpatialReferenceUnit as t}from"../../core/unitUtils.js";import{fromGeometry as u,getSpatialReference as n}from"./support/apiConverter.js";class s{getOperatorType(){return 10100}supportsCurves(){return!0}accelerateGeometry(e,r,t){return!1}canAccelerateGeometry(e){return!1}execute(e,r,t){return this.executeEx(e,r,t,null,null,Number.NaN)}executeEx(t,u,n,s,o,c){if(t.isEmpty()||u.isEmpty())return Number.NaN;e(t),e(u);const i=t,a=u;Number.isNaN(c)&&(c=Number.POSITIVE_INFINITY);const m=new r(c,n).calculate(i,a,s,o);return Number.isFinite(m)?m:Number.NaN}}const o=new s;function c(e,r,s={}){const{unit:c}=s;let i=o.execute(u(e),u(r),null);if(i&&c){const r=n(e);i=t(i,r,c)}return i}function i(){return o.supportsCurves()}export{c as execute,i as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{aK as e,aL as r}from"../../chunks/QuadraticBezier.js";import{getSpatialReference as t,fromGeometry as n,fromSpatialReference as u}from"./support/converterAPI.js";class o extends e{getOperatorType(){return 2}execute(e,t,n,u){return r(e,t,n,3,u)}}const s=new o;function c(e){const r=t(e);return s.accelerateGeometry(n(e),u(r),0)}function a(e,r){return s.execute(n(e),n(r),u(e.spatialReference),null)}function p(){return s.supportsCurves()}export{c as accelerateGeometry,a as execute,p as supportsCurves};
5
+ import{g as e,r}from"../../chunks/QuadraticBezier.js";import{getSpatialReference as t,fromGeometry as n,fromSpatialReference as u}from"./support/apiConverter.js";class o extends e{getOperatorType(){return 2}execute(e,t,n,u){return r(e,t,n,3,u)}}const s=new o;function c(e){const r=t(e);return s.accelerateGeometry(n(e),u(r),0)}function a(e,r){return s.execute(n(e),n(r),u(e.spatialReference),null)}function p(){return s.supportsCurves()}export{c as accelerateGeometry,a as execute,p as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{t as e,k as t,G as n,d as r}from"../../chunks/Geometry.js";import{t as o,h as s,S as a,P as i,aM as g,aN as u,aO as m}from"../../chunks/QuadraticBezier.js";import{getSpatialReference as c,fromPolyline as l,fromSpatialReference as d,toPolyline as p}from"./support/converterAPI.js";function h(t,n,r,a,i){if(t.isEmpty()||n.isEmpty())return null;if(8&a&&16&a)return null;2&a&&4&a&&e("");const g=new o,u=new o;t.queryEnvelope(g),n.queryEnvelope(u),g.mergeEnvelope2D(u);return f(t,n,s(r,g,!0).total(),a)}function f(e,o,s,u){t(e),t(o);let m,c=!1;const l=e.querySegmentIterator(),d=o.querySegmentIterator();let p=0;const h=new a,f=new i({vd:e.getDescription()}),P=new i({vd:e.getDescription()}),S=[],x=[];for(y(e,S,x);l.nextPath();){let t=!0,o=0;for(;2!==o;){if(0===o){l.nextSegment().getGeometryType()!==n.enumLine&&r(""),o++}else{l.resetToLastSegment();if(l.previousSegment().getGeometryType()!==n.enumLine&&r(""),c&&t){const n=l.getPathIndex();m.addSegmentsFromPath(e,n,0,e.getSegmentCountPath(n),!0),t=!1}o++}let a=!1;if(p<x.length){const e=x[S[p]],t=l.getPathIndex();if(e.m_path===t){const t=1===o?l.getStartPointIndex():l.getEndPointIndex();e.m_pointIndex===t&&(a=!0,p++)}}if(1===o){if(8&u)continue}else if(16&u)continue;if(!a){1===o?l.previousSegment():l.nextSegment();const a=1===o?l.nextSegment():l.previousSegment(),i=a,p=i.calculateLength2D();d.resetToFirstPath();let y=!1,S=Number.NaN;for(;d.nextPath();){for(;d.hasNextSegment();){const e=d.nextSegment();e.getGeometryType()!==n.enumLine&&r("");const t=e,{bIntersect:a,t1:u,t2:m}=g(i,t);if(a){const e=t.calculateLength2D();if(m*e>=-s&&(1-m)*e>=-s)if(1===o){if(u*p<=-s)(Number.isNaN(S)||u>S)&&(S=u);else if(u*p<=s){S=Number.NaN,y=!0;break}}else if((1-u)*p<=-s)(Number.isNaN(S)||u<S)&&(S=u);else if((1-u)*p<=s){S=Number.NaN,y=!0;break}}}if(y)break}if(!Number.isNaN(S)){if(!c){m=e.createInstance();for(let t=0;t<l.getPathIndex();t++)m.addPath(e,t,!0)}if(1===o){a.queryCoord(S,f);const n=l.getPathIndex();if(2&u?e.getPointByVal(e.getPathStart(n),P):4&u&&P.setEmpty(),1&u||(h.create(a.getGeometryType()),a.copyTo(h.get()),h.get().setEnd(f),h.get().reverse(),m.addSegment(h.get(),!0),t=!1),m.addSegmentsFromPath(e,n,0,e.getSegmentCountPath(n),t),1&u){const e=m.getPathStart(n);m.setPointByVal(e,f)}if(2&u||4&u){const e=m.getPathStart(n),t=f.getXY();P.setXY(t),m.setPointByVal(e,P)}c=!0,t=!1}else{const n=l.getPathIndex();if(t&&(m.addSegmentsFromPath(e,n,0,e.getSegmentCountPath(n),!0),t=!1),2&u?e.getPointByVal(e.getPathEnd(n)-1,P):4&u&&P.setEmpty(),a.queryCoord(S,f),1&u){const e=m.getPathEnd(n);m.setPointByVal(e-1,f)}else h.create(a.getGeometryType()),a.copyTo(h.get()),h.get().setEnd(f),m.addSegment(h.get(),!1);if(2&u||4&u){const e=m.getPathEnd(n),t=f.getXY();P.setXY(t),m.setPointByVal(e-1,P)}c=!0}}}}}return c?m:null}function P(e,t){return{m_path:e,m_pointIndex:t}}function y(e,t,n){const r=[],o=[],s=e.querySegmentIterator();for(;s.nextPath();){s.resetToFirstSegment();const e=s.nextSegment().getStartXY(),t=s.getPathIndex(),n=s.getStartPointIndex();r.push(e),o.push(P(t,n)),s.resetToLastSegment();const a=s.previousSegment().getEndXY(),i=s.getPathIndex(),g=s.getEndPointIndex();r.push(a),o.push(P(i,g))}const a=new u(0);for(let g=0;g<r.length;g++)a.add(g);const i={userSort(e,t,n){n.sort(e,t,((e,t)=>r[e].compare(r[t])))},getValue:e=>r[e].y};(new m).sort(a,0,a.size(),i);for(let g=0;g<a.size()-1;g++){const e=r[a.read(g)];if(e.equals(r[a.read(g+1)])){do{const e=o[a.read(g)];n.push(e),g++}while(g<a.size()&&e.equals(r[a.read(g)]));g--}}t.length=n.length;for(let g=0;g<n.length;g++)t[g]=g;t.sort(((e,t)=>{const r=n[e],o=n[t];return r.m_path<o.m_path?-1:r.m_path>o.m_path?1:r.m_pointIndex<o.m_pointIndex?-1:1}))}class S{getOperatorType(){return 10007}supportsCurves(){return!1}accelerateGeometry(e,t,n){return!1}canAccelerateGeometry(e){return!1}execute(e,t,n,r,o){return h(e,t,n,r)}}const x=new S;function I(e,t,n){let r=0;n&&(n.relocateEnds&&(r|=1),n.keepEndAttributes&&(r|=2),n.noEndAttributes&&(r|=4),n.noExtendAtFrom&&(r|=8),n.noExtendAtTo&&(r|=16));const o=c(e),s=x.execute(l(e),l(t),d(o),r,null);return s?p(s,o):null}function E(){return x.supportsCurves()}export{I as execute,E as supportsCurves};
5
+ import{t as e,k as t,G as n,d as r}from"../../chunks/Geometry.js";import{v as o,j as s,S as a,P as i,aM as g,aN as u,aO as m}from"../../chunks/QuadraticBezier.js";import{getSpatialReference as c,fromPolyline as l,fromSpatialReference as d,toPolyline as p}from"./support/apiConverter.js";function h(t,n,r,a,i){if(t.isEmpty()||n.isEmpty())return null;if(8&a&&16&a)return null;2&a&&4&a&&e("");const g=new o,u=new o;t.queryEnvelope(g),n.queryEnvelope(u),g.mergeEnvelope2D(u);return f(t,n,s(r,g,!0).total(),a)}function f(e,o,s,u){t(e),t(o);let m,c=!1;const l=e.querySegmentIterator(),d=o.querySegmentIterator();let p=0;const h=new a,f=new i({vd:e.getDescription()}),P=new i({vd:e.getDescription()}),S=[],x=[];for(y(e,S,x);l.nextPath();){let t=!0,o=0;for(;2!==o;){if(0===o){l.nextSegment().getGeometryType()!==n.enumLine&&r(""),o++}else{l.resetToLastSegment();if(l.previousSegment().getGeometryType()!==n.enumLine&&r(""),c&&t){const n=l.getPathIndex();m.addSegmentsFromPath(e,n,0,e.getSegmentCountPath(n),!0),t=!1}o++}let a=!1;if(p<x.length){const e=x[S[p]],t=l.getPathIndex();if(e.m_path===t){const t=1===o?l.getStartPointIndex():l.getEndPointIndex();e.m_pointIndex===t&&(a=!0,p++)}}if(1===o){if(8&u)continue}else if(16&u)continue;if(!a){1===o?l.previousSegment():l.nextSegment();const a=1===o?l.nextSegment():l.previousSegment(),i=a,p=i.calculateLength2D();d.resetToFirstPath();let y=!1,S=Number.NaN;for(;d.nextPath();){for(;d.hasNextSegment();){const e=d.nextSegment();e.getGeometryType()!==n.enumLine&&r("");const t=e,{bIntersect:a,t1:u,t2:m}=g(i,t);if(a){const e=t.calculateLength2D();if(m*e>=-s&&(1-m)*e>=-s)if(1===o){if(u*p<=-s)(Number.isNaN(S)||u>S)&&(S=u);else if(u*p<=s){S=Number.NaN,y=!0;break}}else if((1-u)*p<=-s)(Number.isNaN(S)||u<S)&&(S=u);else if((1-u)*p<=s){S=Number.NaN,y=!0;break}}}if(y)break}if(!Number.isNaN(S)){if(!c){m=e.createInstance();for(let t=0;t<l.getPathIndex();t++)m.addPath(e,t,!0)}if(1===o){a.queryCoord(S,f);const n=l.getPathIndex();if(2&u?e.getPointByVal(e.getPathStart(n),P):4&u&&P.setEmpty(),1&u||(h.create(a.getGeometryType()),a.copyTo(h.get()),h.get().setEnd(f),h.get().reverse(),m.addSegment(h.get(),!0),t=!1),m.addSegmentsFromPath(e,n,0,e.getSegmentCountPath(n),t),1&u){const e=m.getPathStart(n);m.setPointByVal(e,f)}if(2&u||4&u){const e=m.getPathStart(n),t=f.getXY();P.setXY(t),m.setPointByVal(e,P)}c=!0,t=!1}else{const n=l.getPathIndex();if(t&&(m.addSegmentsFromPath(e,n,0,e.getSegmentCountPath(n),!0),t=!1),2&u?e.getPointByVal(e.getPathEnd(n)-1,P):4&u&&P.setEmpty(),a.queryCoord(S,f),1&u){const e=m.getPathEnd(n);m.setPointByVal(e-1,f)}else h.create(a.getGeometryType()),a.copyTo(h.get()),h.get().setEnd(f),m.addSegment(h.get(),!1);if(2&u||4&u){const e=m.getPathEnd(n),t=f.getXY();P.setXY(t),m.setPointByVal(e-1,P)}c=!0}}}}}return c?m:null}function P(e,t){return{m_path:e,m_pointIndex:t}}function y(e,t,n){const r=[],o=[],s=e.querySegmentIterator();for(;s.nextPath();){s.resetToFirstSegment();const e=s.nextSegment().getStartXY(),t=s.getPathIndex(),n=s.getStartPointIndex();r.push(e),o.push(P(t,n)),s.resetToLastSegment();const a=s.previousSegment().getEndXY(),i=s.getPathIndex(),g=s.getEndPointIndex();r.push(a),o.push(P(i,g))}const a=new u(0);for(let g=0;g<r.length;g++)a.add(g);const i={userSort(e,t,n){n.sort(e,t,((e,t)=>r[e].compare(r[t])))},getValue:e=>r[e].y};(new m).sort(a,0,a.size(),i);for(let g=0;g<a.size()-1;g++){const e=r[a.read(g)];if(e.equals(r[a.read(g+1)])){do{const e=o[a.read(g)];n.push(e),g++}while(g<a.size()&&e.equals(r[a.read(g)]));g--}}t.length=n.length;for(let g=0;g<n.length;g++)t[g]=g;t.sort(((e,t)=>{const r=n[e],o=n[t];return r.m_path<o.m_path?-1:r.m_path>o.m_path?1:r.m_pointIndex<o.m_pointIndex?-1:1}))}class S{getOperatorType(){return 10007}supportsCurves(){return!1}accelerateGeometry(e,t,n){return!1}canAccelerateGeometry(e){return!1}execute(e,t,n,r,o){return h(e,t,n,r)}}const x=new S;function E(e,t,n){let r=0;n&&(n.relocateEnds&&(r|=1),n.keepEndAttributes&&(r|=2),n.noEndAttributes&&(r|=4),n.noExtendAtFrom&&(r|=8),n.noExtendAtTo&&(r|=16));const o=c(e),s=x.execute(l(e),l(t),d(o),r,null);return s?p(s,o):null}function I(){return x.supportsCurves()}export{E as execute,I as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{isSome as r}from"../../core/arrayUtils.js";import{convertToSpatialReferenceUnit as e}from"../../core/unitUtils.js";import{execute as t,executeMany as o,supportsCurves as n}from"./gx/operatorGeneralize.js";import{getSpatialReference as s,toGeometry as a,fromGeometry as i}from"./support/converterAPI.js";function u(r,o,n={}){const{removeDegenerateParts:u=!1,unit:m}=n,p=s(r);return m&&(o=e(o,m,p)),a(t(i(r),o,u),p)}function m(t,n,u={}){const{removeDegenerateParts:m=!1,unit:p}=u,c=t.map(i),f=s(t);return p&&(n=e(n,p,f)),o(c,n,m).map((r=>a(r,f))).filter(r)}function p(){return n()}export{u as execute,m as executeMany,p as supportsCurves};
5
+ import{isSome as r}from"../../core/arrayUtils.js";import{convertToSpatialReferenceUnit as e}from"../../core/unitUtils.js";import{execute as t,executeMany as o,supportsCurves as n}from"./gx/operatorGeneralize.js";import{getSpatialReference as s,toGeometry as a,fromGeometry as i}from"./support/apiConverter.js";function u(r,o,n={}){const{removeDegenerateParts:u=!1,unit:p}=n,m=s(r);return p&&(o=e(o,p,m)),a(t(i(r),o,u),m)}function p(t,n,u={}){const{removeDegenerateParts:p=!1,unit:m}=u,c=t.map(i),f=s(t);return m&&(n=e(n,m,f)),o(c,n,p).map((r=>a(r,f))).filter(r)}function m(){return n()}export{u as execute,p as executeMany,m as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{isSome as e}from"../../core/arrayUtils.js";import{convertUnit as r}from"../../core/unitUtils.js";import{isLoaded as t,load as o,execute as s,executeMany as i,supportsCurves as n}from"./gx/operatorGeodesicBuffer.js";import{getSpatialReference as u,toGeometry as a,fromSpatialReference as m,fromGeometry as p}from"./support/converterAPI.js";import{geodeticCurveType as c}from"./support/geodeticCurveType.js";function f(){return t()}function d(){return o()}function v(e,t,o={}){let{curveType:i="geodesic",maxDeviation:n=NaN,unit:f}=o;f&&(t=r(t,f,"meters"),n&&(n=r(n,f,"meters")));const d=u(e);return a(s(p(e),m(d),c[i],t,n),d)}function l(t,o,s={}){let{curveType:n="geodesic",maxDeviation:f=NaN,union:d=!1,unit:v}=s;v&&(o=o.map((e=>r(e,v,"meters"))),f&&(f=r(f,v,"meters")));const l=t.map(p),x=u(t);return i(l,m(x),c[n],o,f,d).map((e=>a(e,x))).filter(e)}function x(){return n()}export{v as execute,l as executeMany,f as isLoaded,d as load,x as supportsCurves};
5
+ import{isSome as e}from"../../core/arrayUtils.js";import{convertUnit as r}from"../../core/unitUtils.js";import{isLoaded as t,load as o,execute as i,executeMany as s,supportsCurves as n}from"./gx/operatorGeodesicBuffer.js";import{getSpatialReference as u,toGeometry as a,fromSpatialReference as p,fromGeometry as m}from"./support/apiConverter.js";import{geodeticCurveType as c}from"./support/geodeticCurveType.js";function f(){return t()}function d(){return o()}function v(e,t,o={}){let{curveType:s="geodesic",maxDeviation:n=NaN,unit:f}=o;f&&(t=r(t,f,"meters"),n&&(n=r(n,f,"meters")));const d=u(e);return a(i(m(e),p(d),c[s],t,n),d)}function l(t,o,i={}){let{curveType:n="geodesic",maxDeviation:f=NaN,union:d=!1,unit:v}=i;v&&(o=o.map((e=>r(e,v,"meters"))),f&&(f=r(f,v,"meters")));const l=t.map(m),x=u(t);return s(l,p(x),c[n],o,f,d).map((e=>a(e,x))).filter(e)}function x(){return n()}export{v as execute,l as executeMany,f as isLoaded,d as load,x as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{convertUnit as t}from"../../core/unitUtils.js";import{isLoaded as e,load as r,getNearestCoordinate as s,getNearestVertex as n,getNearestVertices as i,supportsCurves as o}from"./gx/operatorProximityGeodesic.js";import{getSpatialReference as a,fromSpatialReference as m,fromPoint as c,fromGeometry as u}from"./support/converterAPI.js";import{toProximityResult as d}from"./support/proximityResult.js";function p(){return e()}function f(){return r()}function g(e,r,n={}){let{calculateLeftRightSide:i=!1,maxDeviation:o=NaN,testPolygonInterior:p=!0,unit:f}=n;f&&o&&(o=t(o,f,"meters"));const g=a(e),_=s(u(e),c(r).getXY(),m(g),o,p,i);return f&&_.m_distance&&(_.m_distance=t(_.m_distance,"meters",f)),d(_,e,i)}function _(e,r,s={}){const{unit:i}=s,o=a(e),p=n(u(e),c(r).getXY(),m(o));return i&&p.m_distance&&(p.m_distance=t(p.m_distance,"meters",i)),d(p,e)}function l(e,r,s,n,o={}){const{unit:p}=o;p&&s&&(s=t(s,p,"meters"));const f=a(e);return i(u(e),c(r).getXY(),m(f),s,n).map((r=>(p&&r.m_distance&&(r.m_distance=t(r.m_distance,"meters",p)),d(r,e))))}function x(){return o()}export{g as getNearestCoordinate,_ as getNearestVertex,l as getNearestVertices,p as isLoaded,f as load,x as supportsCurves};
5
+ import{convertUnit as t}from"../../core/unitUtils.js";import{isLoaded as e,load as r,getNearestCoordinate as s,getNearestVertex as n,getNearestVertices as i,supportsCurves as o}from"./gx/operatorProximityGeodesic.js";import{getSpatialReference as a,fromSpatialReference as m,fromPoint as c,fromGeometry as u}from"./support/apiConverter.js";import{toProximityResult as d}from"./support/proximityResult.js";function p(){return e()}function f(){return r()}function g(e,r,n={}){let{calculateLeftRightSide:i=!1,maxDeviation:o=NaN,testPolygonInterior:p=!0,unit:f}=n;f&&o&&(o=t(o,f,"meters"));const g=a(e),_=s(u(e),c(r).getXY(),m(g),o,p,i);return f&&_.m_distance&&(_.m_distance=t(_.m_distance,"meters",f)),d(_,e,i)}function _(e,r,s={}){const{unit:i}=s,o=a(e),p=n(u(e),c(r).getXY(),m(o));return i&&p.m_distance&&(p.m_distance=t(p.m_distance,"meters",i)),d(p,e)}function l(e,r,s,n,o={}){const{unit:p}=o;p&&s&&(s=t(s,p,"meters"));const f=a(e);return i(u(e),c(r).getXY(),m(f),s,n).map((r=>(p&&r.m_distance&&(r.m_distance=t(r.m_distance,"meters",p)),d(r,e))))}function x(){return o()}export{g as getNearestCoordinate,_ as getNearestVertex,l as getNearestVertices,p as isLoaded,f as load,x as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{convertUnit as r}from"../../core/unitUtils.js";import{isLoaded as e,load as t,execute as o,supportsCurves as s}from"./gx/operatorGeodeticArea.js";import{getSpatialReference as u,fromSpatialReference as n,fromGeometry as i}from"./support/converterAPI.js";import{geodeticCurveType as p}from"./support/geodeticCurveType.js";function c(){return e()}function a(){return t()}function m(e,t={}){const{curveType:s="geodesic",unit:c}=t,a=u(e);let m=o(i(e),n(a),p[s]);return m&&c&&(m=r(m,"square-meters",c)),m}function f(){return s()}export{m as execute,c as isLoaded,a as load,f as supportsCurves};
5
+ import{convertUnit as r}from"../../core/unitUtils.js";import{isLoaded as e,load as t,execute as o,supportsCurves as s}from"./gx/operatorGeodeticArea.js";import{getSpatialReference as u,fromSpatialReference as i,fromGeometry as n}from"./support/apiConverter.js";import{geodeticCurveType as p}from"./support/geodeticCurveType.js";function c(){return e()}function a(){return t()}function m(e,t={}){const{curveType:s="geodesic",unit:c}=t,a=u(e);let m=o(n(e),i(a),p[s]);return m&&c&&(m=r(m,"square-meters",c)),m}function f(){return s()}export{m as execute,c as isLoaded,a as load,f as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{convertUnit as e}from"../../core/unitUtils.js";import{isLoaded as t,load as r,execute as o,executeMany as n,supportsCurves as s}from"./gx/operatorGeodeticDensify.js";import{getSpatialReference as u,toGeometry as c,fromSpatialReference as i,fromGeometry as p}from"./support/converterAPI.js";import{geodeticCurveType as m}from"./support/geodeticCurveType.js";function a(){return t()}function f(){return r()}function d(t,r,n={}){const{curveType:s="geodesic",unit:a}=n;a&&(r=e(r,a,"meters"));const f=u(t);return c(o(p(t),r,i(f),m[s]),f)}function v(t,r,o={}){const{curveType:s="geodesic",unit:a}=o;a&&(r=e(r,a,"meters"));const f=t.map(p),d=u(t);return n(f,r,i(d),m[s]).map((e=>c(e,d)))}function y(){return s()}export{d as execute,v as executeMany,a as isLoaded,f as load,y as supportsCurves};
5
+ import{convertUnit as e}from"../../core/unitUtils.js";import{isLoaded as t,load as r,execute as o,executeMany as n,supportsCurves as s}from"./gx/operatorGeodeticDensify.js";import{getSpatialReference as u,toGeometry as i,fromSpatialReference as c,fromGeometry as p}from"./support/apiConverter.js";import{geodeticCurveType as a}from"./support/geodeticCurveType.js";function m(){return t()}function f(){return r()}function d(t,r,n={}){const{curveType:s="geodesic",unit:m}=n;m&&(r=e(r,m,"meters"));const f=u(t);return i(o(p(t),r,c(f),a[s]),f)}function v(t,r,o={}){const{curveType:s="geodesic",unit:m}=o;m&&(r=e(r,m,"meters"));const f=t.map(p),d=u(t);return n(f,r,c(d),a[s]).map((e=>i(e,d)))}function y(){return s()}export{d as execute,v as executeMany,m as isLoaded,f as load,y as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{convertUnit as r}from"../../core/unitUtils.js";import{isLoaded as e,load as t,execute as o,supportsCurves as s}from"./gx/operatorGeodeticDistance.js";import{getSpatialReference as n,fromSpatialReference as u,fromGeometry as i}from"./support/converterAPI.js";import{geodeticCurveType as p}from"./support/geodeticCurveType.js";function c(){return e()}function m(){return t()}function a(e,t,s={}){const{curveType:c="geodesic",unit:m}=s,a=n(e);let f=o(i(e),i(t),u(a),p[c]);return f&&m&&(f=r(f,"meters",m)),f}function f(){return s()}export{a as execute,c as isLoaded,m as load,f as supportsCurves};
5
+ import{convertUnit as r}from"../../core/unitUtils.js";import{isLoaded as e,load as t,execute as o,supportsCurves as s}from"./gx/operatorGeodeticDistance.js";import{getSpatialReference as i,fromSpatialReference as n,fromGeometry as u}from"./support/apiConverter.js";import{geodeticCurveType as p}from"./support/geodeticCurveType.js";function c(){return e()}function a(){return t()}function m(e,t,s={}){const{curveType:c="geodesic",unit:a}=s,m=i(e);let f=o(u(e),u(t),n(m),p[c]);return f&&a&&(f=r(f,"meters",a)),f}function f(){return s()}export{m as execute,c as isLoaded,a as load,f as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{convertUnit as r}from"../../core/unitUtils.js";import{isLoaded as e,load as t,execute as o,supportsCurves as s}from"./gx/operatorGeodeticLength.js";import{getSpatialReference as n,fromSpatialReference as u,fromGeometry as i}from"./support/converterAPI.js";import{geodeticCurveType as p}from"./support/geodeticCurveType.js";function c(){return e()}function m(){return t()}function f(e,t={}){const{curveType:s="geodesic",unit:c}=t,m=n(e);let f=o(i(e),u(m),p[s]);return f&&c&&(f=r(f,"meters",c)),f}function a(){return s()}export{f as execute,c as isLoaded,m as load,a as supportsCurves};
5
+ import{convertUnit as r}from"../../core/unitUtils.js";import{isLoaded as e,load as t,execute as o,supportsCurves as s}from"./gx/operatorGeodeticLength.js";import{getSpatialReference as n,fromSpatialReference as u,fromGeometry as i}from"./support/apiConverter.js";import{geodeticCurveType as p}from"./support/geodeticCurveType.js";function c(){return e()}function m(){return t()}function a(e,t={}){const{curveType:s="geodesic",unit:c}=t,m=n(e);let a=o(i(e),u(m),p[s]);return a&&c&&(a=r(a,"meters",c)),a}function f(){return s()}export{a as execute,c as isLoaded,m as load,f as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{isSome as r}from"../../core/arrayUtils.js";import{convertToSpatialReferenceUnit as t}from"../../core/unitUtils.js";import{executeMany as e,supportsCurves as o}from"./gx/operatorGraphicBuffer.js";import{fromGeometry as i,getSpatialReference as n,fromSpatialReference as u,toGeometry as m}from"./support/converterAPI.js";const s={round:0,miter:1,bevel:2},a={round:0,butt:1,square:2};function p(o,p,c,f,l={}){let{maxDeviation:x=NaN,maxVerticesInFullCircle:j=96,miterLimit:v=10,union:b=!1,unit:d}=l;const y=o.map(i),C=n(o);return d&&(p=p.map((r=>t(r,d,C))),x&&(x=t(x,d,C))),e(y,u(C),p,s[c],a[f],v,x,j,b).map((r=>m(r,C))).filter(r)}function c(){return o()}export{p as executeMany,c as supportsCurves};
5
+ import{isSome as r}from"../../core/arrayUtils.js";import{convertToSpatialReferenceUnit as t}from"../../core/unitUtils.js";import{executeMany as e,supportsCurves as o}from"./gx/operatorGraphicBuffer.js";import{fromGeometry as i,getSpatialReference as n,fromSpatialReference as u,toGeometry as a}from"./support/apiConverter.js";const m={round:0,miter:1,bevel:2},s={round:0,butt:1,square:2};function p(o,p,c,f,l={}){let{maxDeviation:x=NaN,maxVerticesInFullCircle:j=96,miterLimit:v=10,union:C=!1,unit:b}=l;const d=o.map(i),y=n(o);return b&&(p=p.map((r=>t(r,b,y))),x&&(x=t(x,b,y))),e(d,u(y),p,m[c],s[f],v,x,j,C).map((r=>a(r,y))).filter(r)}function c(){return o()}export{p as executeMany,c as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{G as t,S as e}from"../../../chunks/SimpleGeometryCursor.js";import{k as i,a as n,f as s,G as o,t as r,g as h}from"../../../chunks/Geometry.js";import{d,P as g,i as a,u as c,f as l,s as u,c as f,n as m}from"../../../chunks/Transformation2D.js";import{a as p,M as E,ay as x,az as P}from"../../../chunks/QuadraticBezier.js";function _(t,e,i,n,s,o){const r=n-e;if(r<=o)return P(t,e,i,n,s),i;const h=w(t,e,n,s,Math.min(Math.max(r>>1,3),100)),d=t[h];t[e]=u(t[h],t[h]=t[e]);let g=e+1,a=!1;for(let c=e+1;c!==n;++c)s(t[c],d)&&(t[g]=u(t[c],t[c]=t[g]),++g,a=!0);if(!a)for(let c=e+1;c<i;++c)s(d,t[c])||(c!==g&&(t[g]=u(t[c],t[c]=t[g])),++g);return--g,t[g]=u(t[e],t[e]=t[g]),g}function F(t,e,i){const n=Math.trunc(e/2);let s=BigInt(n);const o=BigInt(e);for(let h=0;h<i;++h)t.push(Number(s%o)),s=6364136223846793005n*s+1442695040888963407n&0x7fffffffffffffffn,s=BigInt.asUintN(64,s);m(t);const r=c(t,((t,e)=>t===e));t.length=r}function w(t,e,i,n,s){const o=[];F(o,i-e,s);const r=[];for(let d=0,g=o.length;d<g;d++){const i=o[d];r.push(l(t[e+i],i))}const h=Math.trunc(r.length/2);return r.sort(((t,e)=>n(t.first,e.first)?-1:1)),e+r[h].second}function k(){return{p:new g,userData:Number.NaN,edge:null}}class T{constructor(){this.info=0,this.mask=!1,this.p=null,this.a=[null,null],this.twin=null}nextFreeEdge(){return this.twin}setIndex(t){this.info=t,this.mask=!1}getIndex(){return this.info}setMask(){this.mask=!0}getMask(){return this.mask}}function y(t,e){return{first:t,second:e}}function C(t,e){t.first=e.first,t.second=e.second}function b(){return this.i1-this.i0}function D(){return{i0:Number.NaN,i1:Number.NaN,nextFreeEdgeIndex:[-1],box:[y(null,null),y(null,null)],size:b}}function I(){return{k:0,pTask:null,pTask0:null,pTask1:null}}function X(){return{p:[new g,new g],points:[null,null]}}function Y(){return{p:[null,null,null]}}class N{constructor(){this.m_nextFreePairEdge=y(null,null),this.m_points=[],this.m_pointZero=null,this.m_edges=[],this.m_voronoiToEdge=[],this.m_nextFreeEdge=0}clear(){this.m_nextFreePairEdge=y(null,null),this.m_points.length=0,this.m_pointZero=null,this.m_edges.length=0,this.m_voronoiToEdge.length=0,this.m_nextFreeEdge=0}reservePoints(t){h(t>1)}prepare(t){{const e=k();e.p.x=Number.POSITIVE_INFINITY,e.p.y=Number.POSITIVE_INFINITY,e.userData=t,this.m_points.push(e)}}addVertex(t,e){const i=k();i.p.assign(t),i.userData=e,i.edge=null,this.m_points.push(i)}removeDuplicates(){const t=this.m_points.shift();this.m_points.sort(((t,e)=>t.p.compareX(e.p)));const e=c(this.m_points,((t,e)=>t.p.equals(e.p))),i=e!==this.m_points.length;return this.m_points.length=e,this.m_points.unshift(t),i}removeDuplicatesEx(t){return h(0),!1}boundVoronoiCells(t,e){const i=this.m_points.length;if(i<2)return!1;const n=[this.m_points[1].p.clone(),this.m_points[1].p.clone()];for(let d=2;d<i;d++){const t=this.m_points[d].p;t.x<n[0].x&&(n[0].x=t.x),n[1].x<t.x&&(n[1].x=t.x),t.y<n[0].y&&(n[0].y=t.y),n[1].y<t.y&&(n[1].y=t.y)}const s=new g;s.x=.5*(n[0].x+n[1].x),s.y=.5*(n[0].y+n[1].y);let o=0;for(let d=1;d<i;d++){const t=this.m_points[d].p,e=g.sqrDistanceCoords(t.x,t.y,s.x,s.y);o<e&&(o=e)}const r=Math.sqrt(o),h=Math.max(r+2*t,1.5*r);{const t=.8660254037844386,i=.5;let n=1,o=0;for(let r=0;r<12;r++){const r=new g;r.x=s.x+h*n,r.y=s.y+h*o,this.addVertex(r,e);const d=n*i+o*t;n=n*t-o*i,o=d}}return!0}construct(){const t=D();return!!this.constructTask(t)&&(this.solveTask(t),!0)}constructTask(t){if(this.m_pointZero=this.createZeroHandle(),h(void 0!==this.m_pointZero),this.m_points.length<3)return!1;const e=6*(this.m_points.length-2);this.m_edges=d(T,e);for(let i=0;i<e;i++)this.m_edges[i].setIndex(i);return t.i0=1,t.i1=this.m_points.length,t.nextFreeEdgeIndex[0]=0,!0}splitTask(t,e,i,n){const s=t,o=e,r=i,h=n;s.k=this.findMaxSide(h.i0,h.i1);let d=h.i0+h.i1>>1;const g=1250;if(0===s.k){d=_(this.m_points,h.i0,d,h.i1,((t,e)=>t.p[0]!==e.p[0]?t.p[0]<e.p[0]:t.p[1]<e.p[1]),g)}else{d=_(this.m_points,h.i0,d,h.i1,((t,e)=>t.p[1]!==e.p[1]?t.p[1]<e.p[1]:t.p[0]<e.p[0]),g)}o.i0=h.i0,o.i1=d,o.nextFreeEdgeIndex[0]=h.nextFreeEdgeIndex[0],h.nextFreeEdgeIndex[0]+=6*(o.i1-o.i0-1)+2,r.i0=d,r.i1=h.i1,r.nextFreeEdgeIndex[0]=h.nextFreeEdgeIndex[0],h.nextFreeEdgeIndex[0]+=6*(r.i1-r.i0-1)+2,s.pTask=h,s.pTask0=o,s.pTask1=r}solveMergeTask(t){const e=this.newPairEdgeEx(t.pTask.nextFreeEdgeIndex,!1);if(t.pTask.box[t.k]=y(t.pTask0.box[t.k].first,t.pTask1.box[t.k].second),t.pTask.box[1-t.k]=y(j(this.getPointXYFromEdge(t.pTask0.box[1-t.k].first),this.getPointXYFromEdge(t.pTask1.box[1-t.k].first),1-t.k)?t.pTask0.box[1-t.k].first:t.pTask1.box[1-t.k].first,j(this.getPointXYFromEdge(t.pTask0.box[1-t.k].second),this.getPointXYFromEdge(t.pTask1.box[1-t.k].second),1-t.k)?t.pTask1.box[1-t.k].second:t.pTask0.box[1-t.k].second),t.pTask.i0+2===t.pTask.i1){const i=t.pTask0.box[t.k].second,n=i.twin,s=t.pTask1.box[t.k].first,o=s.twin;return this.joinEdges2(n,o),this.joinEdges2(o,n),void this.join(i,s,0,1,e)}const i=[new Array(2),new Array(2)];i[0][0]=i[1][0]=y(t.pTask0.box[t.k].second,t.pTask0.box[t.k].second.twin),i[0][1]=i[1][1]=y(t.pTask1.box[t.k].first,t.pTask1.box[t.k].first.twin);const n=[!1,!1];if(t.pTask0.i0+1===t.pTask0.i1?(this.findEdgeSide(i[0],n,1,0),this.findEdgeSide(i[1],n,1,1)):(this.findEdge(i[0],n,0),this.findEdge(i[1],n,1)),n[0]||n[1]){if(n[0]){const e=this.newPairEdgeEx(t.pTask0.nextFreeEdgeIndex,!1);this.insertEdge(i[0][0].first,e.first,0),this.insertEdge(i[0][0].second,e.second,1)}if(n[1]){const e=this.newPairEdgeEx(t.pTask1.nextFreeEdgeIndex,!1);this.insertEdge(i[0][1].first,e.first,1),this.insertEdge(i[0][1].second,e.second,0)}}else this.getNextDEdge(i[0][0].first,0)!==i[0][0].first&&(i[1][0]=this.newPairEdgeEx(t.pTask0.nextFreeEdgeIndex,!1),this.insertEdge(i[0][0].first,i[1][0].first,0),this.insertEdge(i[0][0].second,i[1][0].second,1)),this.getNextDEdge(i[0][1].first,0)!==i[0][1].first&&(i[1][1]=this.newPairEdgeEx(t.pTask1.nextFreeEdgeIndex,!1),this.insertEdge(i[0][1].first,i[1][1].first,1),this.insertEdge(i[0][1].second,i[1][1].second,0));this.merge(i[1][0],i[0][0],i[0][1],i[1][1],e)}solveTask(t){const e=t;switch(e.i1-e.i0){case 1:{this.insertPoint(e.i0,e.nextFreeEdgeIndex);const t=this.m_points[e.i0].edge;e.box[0]=e.box[1]=l(t,t)}break;case 2:{const t=e.i0,i=t+1;this.insertPoint(t,e.nextFreeEdgeIndex),this.insertPoint(i,e.nextFreeEdgeIndex);const n=this.m_points[t],s=this.m_points[i],o=n.edge,r=s.edge,h=o.twin,d=r.twin;this.joinEdges2(h,d),this.joinEdges2(d,h);const g=this.newPairEdgeEx(e.nextFreeEdgeIndex,!1);this.join(o,r,0,1,g);for(let a=0;a<2;a++)e.box[a]=j(this.getPointXY(n),this.getPointXY(s),a)?y(o,r):y(r,o)}break;case 3:{const t=[e.i0,e.i0+1,e.i0+2];this.insertPoint(t[0],e.nextFreeEdgeIndex),this.insertPoint(t[1],e.nextFreeEdgeIndex),this.insertPoint(t[2],e.nextFreeEdgeIndex);const i=[this.m_points[t[0]],this.m_points[t[1]],this.m_points[t[2]]],n=this.caseFromCompare(i[0].p,i[1].p,i[2].p),s=[i[0].edge,i[1].edge,i[2].edge],o=N.c_aTableDelaunayTriangulationSolution[n],r=A(19*A(1+(7&o))),h=A(19*A(1+(o>>5)));let d=A(o<<3)>>6;const g=3&r,a=r>>6,c=3&h,l=h>>6;e.box[0]=y(s[g],s[a]),e.box[1]=y(s[c],s[l]);const f=[s[0].twin,s[1].twin,s[2].twin],m=[this.newPairEdgeEx(e.nextFreeEdgeIndex,!1),this.newPairEdgeEx(e.nextFreeEdgeIndex,!1),this.newPairEdgeEx(e.nextFreeEdgeIndex,!1)];switch(3===d&&(d=this.orientation(i[0].p,i[1].p,i[2].p)+1),d){case 0:this.joinEdges2(f[0],f[2]),this.joinEdges2(f[2],f[1]),this.joinEdges2(f[1],f[0]),this.join(s[0],s[2],0,1,m[0]),this.join(s[2],s[1],0,1,m[1]),this.join(s[1],s[0],0,1,m[2]);break;case 1:{const t=[0,1,2];t[3-(g+a)]=u(t[1],t[1]=t[3-(g+a)]),this.joinEdges2(f[t[0]],f[t[1]]),this.joinEdges2(f[t[1]],f[t[2]]),this.joinEdges2(f[t[2]],f[t[0]]),this.join(s[t[0]],s[t[1]],0,1,m[0]),this.join(s[t[1]],s[t[2]],0,1,m[1]),this.join(m[1].first,f[t[2]],0,1,m[2])}break;case 2:this.joinEdges2(f[0],f[1]),this.joinEdges2(f[1],f[2]),this.joinEdges2(f[2],f[0]),this.join(s[0],s[1],0,1,m[0]),this.join(s[1],s[2],0,1,m[1]),this.join(s[2],s[0],0,1,m[2])}}break;default:{const e=I(),i=D(),n=D();this.splitTask(e,i,n,t),this.solveTask(i),this.solveTask(n),this.solveMergeTask(e)}}}constructForConvexHull(){return h(0),!1}getOutsideHull(){const t=[],e=this.m_points[0].edge;let i=e;do{t.push(this.getPointFromEdge(this.getTwinEdge(i))),i=this.getNextDEdge(i,0)}while(i!==e);return t}getConvexHull(){const t=[],e=this.m_points[0].edge;let i=e;do{const e=this.getPointFromEdge(this.getTwinEdge(i));t.length<2||!this.insideLine(this.getPointXY(t.at(-2)),this.getPointXY(t.at(-1)),this.getPointXY(e))?t.push(e):t[t.length-1]=e,i=this.getNextDEdge(i,0)}while(i!==e);return 2<t.length&&this.insideLine(this.getPointXY(t[0]),this.getPointXY(t.at(-1)),this.getPointXY(t.at(-2)))&&t.pop(),2<t.length&&this.insideLine(this.getPointXY(t[1]),this.getPointXY(t[0]),this.getPointXY(t.at(-1)))&&(t[0]=t.at(-1),t.pop()),t}getVoronoiPolygon(t,e){t.length=0;const i=this.getEdgeFromPoint(e);let n=i;for(;;){const e=this.calculateCircleCenter(n);t.push(e);const s=this.getNextDEdge(n,1);if(s===i)break;n=s}}getNearestPoint(t){this.isInfinitePointFromPoint(t)&&r("Not supported for the infinite point");const e=this.getPointXY(t);let i=this.m_pointZero,n=Number.MAX_VALUE;const s=this.getEdgeFromPoint(t);let o=s;do{const t=this.getPointFromEdge(this.getTwinEdge(o));if(!this.isInfinitePointFromPoint(t)){const s=g.sqrDistance(e,this.getPointXY(t));s<n&&(i=t,n=s)}o=this.getCounterClockwiseEdge(o)}while(o!==s);return i}addConstraint(t,e){const i=[null],n=[null];if(!this.constraintFindFirstEdge(i,n,t,e))return y(n[0],i[0]);i[0]=this.getTwinEdge(i[0]);const s=this.getPointXY(t),o=this.getPointXY(e),h=[new Array(0),new Array(0)],d=i[0];for(;;){const t=this.getClockwiseEdge(n[0]);t.getMask()&&r("add_constraint");const d=y(t,this.getTwinEdge(t));this.deleteTwinEdges(d,!0);const g=this.getCounterClockwiseEdge(this.getTwinEdge(i[0])),a=this.getTwinEdge(this.getClockwiseEdge(n[0])),c=this.getPointFromEdge(a);if(c===e){h[0].push(i[0]),i[0]=g,h[1].push(n[0]),n[0]=a;break}const l=this.orientation(s,o,this.getPointXY(c));0===l&&r("add_constraint - point on constraint"),0<l?(h[0].push(i[0]),i[0]=g):(h[1].push(n[0]),n[0]=a)}h[0].push(i[0]),h[1].push(n[0]);const g=this.newPairEdge();g.first.setMask(),g.second.setMask(),this.join(n[0],d,1,1,g),this.triangulateConstraint(h[0],1,h[0].length-1,g),h[1].reverse();const a=y(g.second,g.first);return this.triangulateConstraint(h[1],1,h[1].length-1,a),a}verify(){for(let t=0,e=this.m_edges.length;t<e;t++){const e=this.m_edges[t];if(!e.getMask()&&!this.testEdge(e))return!1}return!0}getDelaunayTriangleCount(){return this.m_points.length-2<<1}getSmallestEnclosingCircle(){return h(0),{}}getVoronoiSegments(t=Number.MAX_VALUE){const e=[];for(let i=0,n=this.m_edges.length;i<n;i+=2){const n=y(null,null);if(n.first=this.m_edges[i],n.second=n.first.twin,this.isInfinitePointFromEdge(n.first)&&(n.second=u(n.first,n.first=n.second)),this.isInfinitePointFromEdge(n.second)){const i=d(g,3);i[0]=this.calculateCircleCenter(this.getNextDEdge(n.first,0).twin,1),i[2]=this.calculateCircleCenter(this.getNextDEdge(n.first,1),1);const s=d(g,2);s[0].assign(i[0]),s[1].assign(i[2]),s[0].rightPerpendicularThis(),s[1].leftPerpendicularThis(),i[1]=i[0].add(s[0]).add(i[2].add(s[1])),i[1].normalize();for(const e of i)e.mulThis(t);const o=X();o.points[0]=n.first.p,o.points[1]=n.second.p;for(let t=0;t<i.length-1;t++){for(let e=0;e<2;e++)o.p[e]=i[t+e];o.p[0].equals(o.p[1])||e.push(o)}}else if(this.isInfinitePointFromEdge(this.getNextDEdge(n.first,0).twin)&&this.isInfinitePointFromEdge(this.getNextDEdge(n.first,1).twin)){const t=d(g,3);t[0]=this.calculateCircleCenter(n.first),t[1]=this.getPointXY(this.getPointFromEdge(n.first)).add(this.getPointXY(this.getPointFromEdge(n.second))).mul(.5),t[2]=this.calculateCircleCenter(n.second);const i=X();i.points[0]=n.first.p,i.points[1]=n.second.p;for(let n=0;n<t.length-1;n++){for(let e=0;e<2;e++)i.p[e]=t[n+e];i.p[0].equals(i.p[1])||e.push(i)}}else{const t=X();t.p[0]=this.calculateCircleCenter(n.first),t.p[1]=this.calculateCircleCenter(n.second),t.points[0]=n.first.p,t.points[1]=n.second.p,t.p[0].equals(t.p[1])||e.push(t)}}return e}startDelaunayTriangles(){return-1}nextDelaunayTriangle(t,e){for(;;){if(++e[0],e[0]===this.m_edges.length)return!1;const i=this.m_edges[e[0]];if(t.p[0]=this.getPointFromEdge(i),this.isInfinitePointFromPoint(t.p[0]))continue;const n=this.getTwinEdge(i);if(t.p[1]=this.getPointFromEdge(n),this.isInfinitePointFromPoint(t.p[1]))continue;if(this.getPointXY(t.p[1]).lt(this.getPointXY(t.p[0])))continue;const s=this.getTwinEdge(this.getNextDEdge(i,1));if(t.p[2]=this.getPointFromEdge(s),!this.isInfinitePointFromPoint(t.p[2])&&!this.getPointXY(t.p[2]).lt(this.getPointXY(t.p[0])))return!0}}getPointCount(){return this.m_points.length-1}getPoint(t){return this.m_points[t+1]}getInfinitePoint(){return this.m_pointZero}isInfinitePointFromPoint(t){return t===this.m_pointZero}getPointXY(t){return t.p}getPointIndex(t){return t.userData}setPointIndex(t,e){t.userData=e}getEdgeFromPoint(t){return t.edge}isInfinitePointFromEdge(t){return t.p===this.m_pointZero}getEdgeCount(){return this.m_edges.length}getEdge(t){return this.m_edges[t]}getEdgeIndex(t){return t.getIndex()}getPointFromEdge(t){return t.p}getPointXYFromEdge(t){return t.p.p}getCounterClockwiseEdge(t){return t.a[0]}getClockwiseEdge(t){return t.a[1]}getTwinEdge(t){return t.twin}getPreviousEdge(t){return this.getTwinEdge(this.getCounterClockwiseEdge(t))}getNextEdge(t){return this.getClockwiseEdge(this.getTwinEdge(t))}getPairEdgeFromPoint(t){return h(0),{}}getNextDEdge(t,e=1){return t.a[e]}newPairEdge(){const t=y(this.m_nextFreePairEdge.first,this.m_nextFreePairEdge.second);return this.m_nextFreePairEdge.first=this.m_nextFreePairEdge.first.nextFreeEdge(),this.m_nextFreePairEdge.second=this.m_nextFreePairEdge.second.nextFreeEdge(),t.first.twin=t.second,t.second.twin=t.first,t}newPairEdgeEx(t,e){let i;if(e&&null!==this.m_nextFreePairEdge.first)i=y(this.m_nextFreePairEdge.first,this.m_nextFreePairEdge.second),this.m_nextFreePairEdge.first=this.m_nextFreePairEdge.first.nextFreeEdge(),this.m_nextFreePairEdge.second=this.m_nextFreePairEdge.second.nextFreeEdge();else{const e=t[0]++,n=t[0]++;i=y(this.m_edges[e],this.m_edges[n])}return i.first.twin=i.second,i.second.twin=i.first,i}insertEdge(t,e,i){e.p=t.p;const n=t.a[i],s=e.a;s[i]=n,s[1-i]=t,t.a[i]=e,n.a[1-i]=e}insertPoint(t,e){const i=this.m_points[t],n=this.newPairEdgeEx(e,!1),s=n.first,o=n.second;i.edge=n.first,s.p=this.m_points[t],s.a[0]=n.first,s.a[1]=n.first,o.p=this.m_pointZero,o.a[0]=n.second,o.a[1]=n.second,null===this.m_points[0].edge&&(this.m_points[0].edge=n.second)}deleteTwinEdges(t,e){this.deleteEdge(t.first),this.deleteEdge(t.second),e&&(t.first.twin=this.m_nextFreePairEdge.first,t.second.twin=this.m_nextFreePairEdge.second,this.m_nextFreePairEdge=t)}join(t,e,i,n,s){this.insertEdge(t,s.first,i),this.insertEdge(e,s.second,n)}joinEdges2(t,e){t.a[1]=e,e.a[0]=t}joinEdges4(t,e,i,n){h(0)}checkEdge(t,e,i,n,s){for(;;){const o=y(null,null);if(o.first=this.getNextDEdge(t.first,n),o.second=o.first.twin,this.isInfinitePointFromEdge(o.second))return t;const r=this.getPointXYFromEdge(t.second),h=this.getPointXYFromEdge(o.second);if(this.inCircle(e,i,r,h)<=0)return t;if(this.deleteTwinEdges(t,s),!s){const e=this.getNextDEdge(t.second,n).twin;this.join(o.second,e,n,n,t)}t=o}}calculateCircleCenter(t,e=Number.MAX_VALUE){const i=this.getPointXYFromEdge(t),n=this.getPointXYFromEdge(t.twin),s=this.getNextDEdge(t,0);if(this.isInfinitePointFromEdge(s.twin)){const t=new g;if(Number.isNaN(e))t.setNAN();else{const s=n.sub(i);s.leftPerpendicularThis(),t.assign(s),t.divThis(Math.max(Math.abs(t.x),Math.abs(t.y))),t.normalize(),t.mulThis(e)}return t}const o=this.getPointXYFromEdge(s.twin);return this.calculateCircleCenterFromThreePoints(i,n,o)}createZeroHandle(){return this.m_points[0]}deleteEdge(t){const e=t,i=e.p;i.edge===t&&(i.edge=e.a[0]),e.a[0].a[1]=e.a[1],e.a[1].a[0]=e.a[0]}testEdge(t){if(this.isInfinitePointFromEdge(t))return!0;const e=t.twin;if(this.isInfinitePointFromEdge(e))return!0;const i=this.getNextDEdge(t,0).twin,n=this.getNextDEdge(e,0).twin;if(this.isInfinitePointFromEdge(i)||this.isInfinitePointFromEdge(n))return!0;const s=this.getPointXYFromEdge(t),o=this.getPointXYFromEdge(e),r=this.getPointXYFromEdge(i),h=this.getPointXYFromEdge(n);return!(this.orientation(s,o,r)<=0)&&(!(0<=this.orientation(s,o,h))&&this.inCircle(s,o,r,h)<=0)}findMaxSide(t,e){const i=[this.m_points[t].p.clone(),this.m_points[t].p.clone()];for(t++;t!==e;t++){const e=this.m_points[t].p;e.x<i[0].x&&(i[0].x=e.x),i[1].x<e.x&&(i[1].x=e.x),e.y<i[0].y&&(i[0].y=e.y),i[1].y<e.y&&(i[1].y=e.y)}return i[1].x-i[0].x<i[1].y-i[0].y?1:0}findEdge(t,e,i){let n=!1,s=0;for(;;){const o=y(null,null);if(o.second=this.getNextDEdge(t[s].second,i^s),o.first=o.second.twin,0===i&&this.orientation(this.getPointXYFromEdge(t[0].first),this.getPointXYFromEdge(t[1].first),this.getPointXYFromEdge(o.first))<0||1===i&&0<this.orientation(this.getPointXYFromEdge(t[0].first),this.getPointXYFromEdge(t[1].first),this.getPointXYFromEdge(o.first)))t[s]=o,e[s]=!0,n=!1;else{if(n)return;s^=1,n=!0}}}findEdgeSide(t,e,i,n){for(;;){const s=y(null,null);if(s.second=this.getNextDEdge(t[i].second,n^i),s.first=s.second.twin,!(0===n&&this.orientation(this.getPointXYFromEdge(t[0].first),this.getPointXYFromEdge(t[1].first),this.getPointXYFromEdge(s.first))<0||1===n&&0<this.orientation(this.getPointXYFromEdge(t[0].first),this.getPointXYFromEdge(t[1].first),this.getPointXYFromEdge(s.first))))return;t[i]=s,e[i]=!0}}merge(t,e,i,n,s){const o={...t},r={...n},h={...s};let d={...e},g={...i};const a=d.second,c=g.second;for(;;){if(this.join(d.first,g.first,0,1,h),d.first=this.getNextDEdge(h.first,0),g.first=this.getNextDEdge(h.second,1),d.first===o.first&&g.first===r.first){this.joinEdges2(a,c),this.joinEdges2(r.second,o.second);break}d.second=d.first.twin,g.second=g.first.twin;const t=this.getPointXYFromEdge(h.first),e=this.getPointXYFromEdge(h.second);if(d.first===o.first){let i=y(null,null);i.first=this.getNextDEdge(g.first,1),i.second=i.first.twin,i=this.checkEdge(i,t,e,1,!1),C(d,h),C(h,g),g=y(i.second,i.first)}else if(g.first===r.first){let i=y(null,null);i.first=this.getNextDEdge(d.first,0),i.second=i.first.twin,i=this.checkEdge(i,t,e,0,!1),g=y(h.second,h.first),C(h,d),d=y(i.second,i.first)}else{let i=y(null,null);i.first=this.getNextDEdge(d.first,0),i.second=i.first.twin,i=this.checkEdge(i,t,e,0,!1);let n=y(null,null);n.first=this.getNextDEdge(g.first,1),n.second=n.first.twin,n=this.checkEdge(n,t,e,1,!1);const s=this.getPointXYFromEdge(i.second),o=this.getPointXYFromEdge(n.second);let r=this.inCircle(t,e,s,o);0===r&&(r=this.orientation(t,e,o)),0<r?(C(d,h),C(h,g),g=y(n.second,n.first)):(g=y(h.second,h.first),C(h,d),d=y(i.second,i.first))}this.deleteTwinEdges(h,!1)}}mergeForConvexHull(t,e,i,n){h(0)}constructForConvexHullRecursive(t,e){h(0)}findEdgeClockwise(t,e,i,n,s,o){for(t[0]=n;;){e[0]=t[0],++e[0]===i.length&&(e[0]=0);const n=this.orientation(s,o,this.getPointXYFromEdge(i[e[0]]));if(n<=0)return n<0;t[0]=e[0]}}findEdgeCounterClockwise(t,e,i,n,s,o){for(e[0]=n;;){t[0]=0!==e[0]?e[0]:i.length,t[0]--;const n=this.orientation(s,o,this.getPointXYFromEdge(i[t[0]]));if(0<=n)return 0<n;e[0]=t[0]}}constraintFindFirstEdge(t,e,i,n){const s=[];{const o=this.getEdgeFromPoint(i);let r=o;do{const i=this.getTwinEdge(r);if(this.getPointFromEdge(i)===n)return t[0]=i,e[0]=r,t[0].setMask(),e[0].setMask(),!1;s.push(i),r=this.getClockwiseEdge(r)}while(r!==o)}s.length<3&&r("add_constraint");let o=-1;for(let c=0,l=s.length;c<l;c++)this.isInfinitePointFromEdge(s[c])&&(-1!==o&&r("add_constraint"),o=c);const h=this.getPointXY(i),d=this.getPointXY(n);let g,a;if(-1!==o){x(s,0,o+1,s.length),s.pop();0===this.orientation(h,d,this.getPointXYFromEdge(s[0]))&&r("add_constraint - point on constraint");for(0===this.orientation(h,d,this.getPointXYFromEdge(s.at(-1)))&&r("add_constraint - point on constraint"),g=0,a=s.length-1;g+1!==a;){const t=g+a>>1,e=this.orientation(h,d,this.getPointXYFromEdge(s[t]));0===e&&r("add_constraint - point on constraint"),0<e?g=t:a=t}}else{let t=0,e=this.orientation(h,d,this.getPointXYFromEdge(s[t]));if(0!==e)if(0<e){const e=[0],i=[0];this.findEdgeClockwise(e,i,s,t,h,d)||r("add_constraint"),g=e[0],a=i[0]}else{const e=[0],i=[0];this.findEdgeCounterClockwise(e,i,s,t,h,d)||r("add_constraint"),g=e[0],a=i[0]}else{t++,e=this.orientation(h,d,this.getPointXYFromEdge(s[t])),e<=0&&r("add_constraint");const i=[0],n=[0];this.findEdgeClockwise(i,n,s,t,h,d)||r("add_constraint"),g=i[0],a=n[0]}}return t[0]=s[g],e[0]=s[a],!0}triangulateConstraint(t,e,i,n){if(e===i)return;let s=i;for(let o=e;o!==i;++o)this.inCircle(this.getPointXYFromEdge(n.first),this.getPointXYFromEdge(n.second),this.getPointXYFromEdge(t[s]),this.getPointXYFromEdge(t[o]))<0&&(s=o);if(s!==i){const e=this.newPairEdge();this.join(n.first,t[s],1,1,e),t[s]=e.second,this.triangulateConstraint(t,s+1,i,e)}if(s!==e){const i=this.newPairEdge();this.join(t[s],n.second,1,0,i),this.triangulateConstraint(t,e,s-1,i)}}insideLine(t,e,i){return 0===this.orientation(t,e,i)&&(e.x<t.x!=e.x<i.x||e.y<t.y!=e.y<i.y)}orientation(t,e,i){return g.orientationRobust(t,e,i)}inCircle(t,e,i,n){return g.inCircleRobust(t,e,i,n)}calculateCircleCenterFromThreePoints(t,e,i){return e.lt(t)&&(e=u(t,t=e)),i.lt(e)&&(i=u(e,e=i)),e.lt(t)&&(e=u(t,t=e)),g.calculateCircleCenterFromThreePoints(t,e,i)}compare(t,e){return 3*((v(t[0]<e[0])<<1)+v(t[0]>e[0]))+(v(t[1]<e[1])<<1)+v(t[1]>e[1])-1}caseFromCompare(t,e,i){return(this.compare(t,e)<<6)+(this.compare(t,i)<<3)+this.compare(e,i)}}function v(t){return t?1:0}function j(t,e,i){return t[i]!==e[i]?t[i]<e[i]:t[1-i]<e[1-i]}function A(t){return 255&t}N.c_aTableDelaunayTriangulationSolution=Uint8Array.from([41,74,0,0,0,0,0,0,0,206,0,0,0,0,0,0,0,0,0,0,65,0,0,0,0,0,33,33,65,0,0,0,0,0,0,0,193,0,0,0,0,0,0,0,0,0,0,214,0,0,0,0,0,86,54,86,0,0,0,0,0,0,0,214,173,0,0,0,0,0,0,0,107,239,0,0,0,0,0,0,0,0,0,181,0,0,0,0,0,0,0,181,0,0,0,0,0,0,117,117,245,0,0,0,0,0,0,0,0,0,103,0,0,0,0,0,0,0,167,0,0,0,0,0,0,231,103,231,0,0,0,0,0,0,50,0,0,0,0,0,0,0,0,198,0,0,41,0,0,74,0,0,49,0,0,49,0,0,50,0,0,194,0,0,193,0,0,194,0,0,0,0,0,206,0,0,0,0,0,0,0,0,54,0,0,0,0,0,0,0,0,198,0,0,0,0,0,82,50,82,0,0,0,0,0,0,0,198,0,66,0,0,65,0,0,66,49,66,33,57,65,82,50,90,0,194,0,0,193,0,0,194,0,0,0,0,0,0,0,214,0,0,0,0,0,86,54,86,0,0,0,0,0,0,0,222,0,0,0,0,0,0,178,0,0,0,0,0,0,230,102,230,177,0,0,177,0,0,178,0,177,0,0,177,0,0,178,0,113,226,113,113,249,226,122,226,0,0,0,0,0,0,102,0,0,0,0,0,0,0,190,0,0,0,0,0,0,230,102,230,0,0,0,165,0,0,0,0,0,0,0,0,243,0,0,0,0,0,173,0,0,0,0,0,0,0,0,165,0,0,0,0,0,0,0,0,245,0,0,0,0,0,107,0,0,239,0,0,163,0,0,163,0,0,167,0,0,247,0,0,243,0,0,247,0,0,37,37,69,0,0,0,0,0,0,0,211,0,0,0,0,0,0,0,69,0,0,0,0,0,37,37,69,0,0,0,0,0,0,0,221,0,0,0,0,215,0,0,211,0,0,215,35,87,35,35,91,87,63,87,0,215,0,0,211,0,0,215,0,0,0,165,0,0,0,0,0,0,115,115,243,0,0,0,0,0,0,181,0,0,0,0,0,0,0,189,0,0,0,0,0,0,117,117,245,0,0,0,99,0,0,99,0,0,103,0,163,0,0,163,0,0,167,0,99,247,115,123,243,231,103,255]);class S{constructor(t){this.m_numberOfSets=t,this.m_elements=Array.from({length:t},((t,e)=>e)),this.m_sizes=f(t,1)}getNumberOfSets(){return this.m_numberOfSets}connected(t,e){return this.findRoot(t)===this.findRoot(e)}connect(t,e){const i=this.findRoot(t),n=this.findRoot(e);return i!==n&&(this.m_sizes[i]<this.m_sizes[n]?(this.m_sizes[n]+=this.m_sizes[i],this.m_elements[i]=n):(this.m_sizes[i]+=this.m_sizes[n],this.m_elements[n]=i),--this.m_numberOfSets,!0)}connectRange(t,e,i){if(e!==i)for(let n=e;n<i;++n)this.connect(t[e],t[n])}size(){return this.m_elements.length}size1(t){return h(0),0}findRoot(t){let e=t;if(this.m_elements[e]!==e)do{this.m_elements[e]=this.m_elements[this.m_elements[e]],e=this.m_elements[e]}while(this.m_elements[e]!==e);return e}}function M(){return l(Number.NaN,l([0,0,0],[0,0,0]))}function G(t,e){if(t.first!==e.first)return t.first-e.first;let i=t.second.first,n=e.second.first;for(let s=0;s<3;++s)if(i[s]!==n[s])return i[s]-n[s];i=t.second.second,n=e.second.second;for(let s=0;s<3;++s)if(i[s]!==n[s])return i[s]-n[s];return 0}class q{getOperatorType(){return 10112}accelerateGeometry(t,e,i){return!1}canAccelerateGeometry(t){return!1}supportsCurves(){return!1}executeMany(t,e,i,n){return new z(t,e,i,n)}execute(t,e,i,n=null){const s=new z(null,e,!1,i);s.addGeometry(t);return s.buildAlphaShape(n)}}class z extends t{alphaShapeConstruct(t,e){const i=t.getEdgeCount(),n=new p({vd:this.m_vertexDescription});if(!n)throw new Error("alphaShapeConstruct");for(let s=0;s<i;++s){if(2!==e[s])continue;const i=y(null,null);i.first=t.getEdge(s),i.second=t.getTwinEdge(i.first);if(1!==e[t.getEdgeIndex(i.second)])continue;t.getPointXYFromEdge(i.first),n.startPath(t.getPointXYFromEdge(i.first));let o=s,r=i.second;for(;;){for(e[o]=3,r=t.getCounterClockwiseEdge(r);1===e[t.getEdgeIndex(r)];)r=t.getCounterClockwiseEdge(r);if(r===i.first)break;n.lineTo(t.getPointXYFromEdge(r)),o=t.getEdgeIndex(r),r=t.getTwinEdge(r)}}return n}alphaShape(t,e){const i=t.getEdgeCount(),n=new Uint8Array(i);for(let s=0;s<i;++s){if(0!==n[s])continue;const i=Y(),o=t.getEdge(s);i.p[0]=t.getPointFromEdge(o);const r=t.getClockwiseEdge(t.getTwinEdge(o));i.p[1]=t.getPointFromEdge(r);const h=t.getEdgeIndex(r),a=t.getClockwiseEdge(t.getTwinEdge(r));i.p[2]=t.getPointFromEdge(a);const c=t.getEdgeIndex(a);let l=1;for(let e=0;e<3;++e)if(t.isInfinitePointFromPoint(i.p[e])){l=2;break}if(1===l){const n=d(g,3);for(let e=0;e<3;++e)n[e]=t.getPointXY(i.p[e]);const s=g.sqrDistance(n[0],n[1]),o=g.sqrDistance(n[1],n[2]),r=g.sqrDistance(n[2],n[0]),h=2*n[1].sub(n[0]).crossProduct(n[2].sub(n[0]));e<s*o*r/(h*h)&&(l=2)}n[s]=n[h]=n[c]=l}return this.alphaShapeConstruct(t,n)}alphaShapeAlphaOut(t,e){const i=t.getEdgeCount(),n=new Uint8Array(i),s=[],o=new S(t.getPointCount());for(let h=0;h<i;++h){if(0!==n[h])continue;const e=Y(),i=t.getEdge(h);e.p[0]=t.getPointFromEdge(i);const o=t.getClockwiseEdge(t.getTwinEdge(i));e.p[1]=t.getPointFromEdge(o);const r=t.getEdgeIndex(o),d=t.getClockwiseEdge(t.getTwinEdge(o));e.p[2]=t.getPointFromEdge(d);const a=t.getEdgeIndex(d);let c=1;for(let n=0;n<3;++n)if(t.isInfinitePointFromPoint(e.p[n])){c=2;break}if(1===c){const i=new Array(3);for(let s=0;s<3;++s)i[s]=t.getPointXY(e.p[s]);const n=g.sqrDistance(i[0],i[1]),o=g.sqrDistance(i[1],i[2]),d=g.sqrDistance(i[2],i[0]),l=i[1].sub(i[0]).crossProduct(i[2].sub(i[0])),u=M();u.first=n*o*d/(l*l),u.second.first[0]=h,u.second.first[1]=r,u.second.first[2]=a,u.second.second[0]=t.getPointIndex(e.p[0]),u.second.second[1]=t.getPointIndex(e.p[1]),u.second.second[2]=t.getPointIndex(e.p[2]),s.push(u),c=2}n[h]=n[r]=n[a]=c}s.sort(((t,e)=>G(t,e)));let r=0;for(const h of s){if(1===o.getNumberOfSets()&&h.first!==r)break;n[h.second.first[0]]=n[h.second.first[1]]=n[h.second.first[2]]=1;const t=[h.second.second[0],h.second.second[1],h.second.second[2]];o.connectRange(t,0,3),r=h.first}return e&&(e[0]=.25*r),this.alphaShapeConstruct(t,n)}constructor(t,e,i,n){super(),this.m_multiPointForAttributes=null,this.m_inputGeometryCursor=null,this.m_index=-1,this.m_nDelaunayPoints=0,this.m_cDelaunay=new N,this.m_vertexDescription=null,this.m_progressTracker=n,this.m_alpha=Number.isNaN(e)||!Number.isFinite(e)||e<0?-1:e<Number.MIN_VALUE?0:e,this.m_bMerge=i,this.m_bDone=!1,this.m_inputGeometryCursor=t,this.prepareDelaunay()}prepareDelaunay(){this.m_nDelaunayPoints=0,this.m_cDelaunay.clear(),0!==this.m_alpha&&this.m_cDelaunay.prepare(a())}next(){if(this.m_bMerge){if(!this.m_bDone){const t=this.calculateAlphaShapeMerging(this.m_inputGeometryCursor,this.m_progressTracker);return this.m_bDone=!0,t}return null}if(!this.m_bDone){const t=this.m_inputGeometryCursor.next();if(null!==t)return i(t),n(t),this.m_index=this.m_inputGeometryCursor.getGeometryID(),this.calculateAlphaShape(t,this.m_progressTracker);this.m_bDone=!0}return null}tock(){return!0}getRank(){return 1}getGeometryID(){return this.m_index}calculateAlphaShapeMerging(t,e){let s;for(;s=t.next();)i(s),n(s),this.addGeometry(s);return this.buildAlphaShape()}calculateAlphaShape(t,e){return t.isEmpty()?new p({vd:t.getDescription()}):(this.prepareDelaunay(),this.addGeometry(t),this.buildAlphaShape())}buildAlphaShape(t=null){if(t&&(t[0]=this.m_alpha),0===this.m_alpha)return this.m_vertexDescription?new p({vd:this.m_vertexDescription}):new p;if(this.m_cDelaunay.removeDuplicates())for(let e=0,i=this.m_cDelaunay.getPointCount();e<i;++e)this.m_cDelaunay.setPointIndex(this.m_cDelaunay.getPoint(e),e);if(!this.m_cDelaunay.construct())return this.m_vertexDescription?new p({vd:this.m_vertexDescription}):new p;return this.m_alpha<0?this.alphaShapeAlphaOut(this.m_cDelaunay,t):this.alphaShape(this.m_cDelaunay,this.m_alpha)}addGeometry(t){if(i(t),n(t),0===this.m_alpha)return;if(this.m_vertexDescription&&this.m_bMerge||(this.m_vertexDescription=t.getDescription(),this.m_vertexDescription.getAttributeCount()>1?this.m_multiPointForAttributes=new E({vd:this.m_vertexDescription}):this.m_multiPointForAttributes=null),t.isEmpty())return;const e=t.getGeometryType();if(s(e)){const e=t,i=new g;for(let t=0,n=e.getPointCount();t<n;t++)e.queryXY(t,i),this.m_cDelaunay.addVertex(i,this.m_nDelaunayPoints++);this.m_multiPointForAttributes&&this.m_multiPointForAttributes.addPoints(e,0,-1)}else if(e===o.enumPoint){const e=t,i=e.getXY();this.m_cDelaunay.addVertex(i,this.m_nDelaunayPoints++),this.m_multiPointForAttributes&&this.m_multiPointForAttributes.add(e)}else r("bad geometry type")}}const V=new q;function O(t,e,i){return V.execute(t,e,null,i)}function R(t,i,n){const s=V.executeMany(new e(t),i,n,null);return Array.from(s)}function Z(){return V.supportsCurves()}export{O as execute,R as executeMany,Z as supportsCurves};
5
+ import{G as t,S as e}from"../../../chunks/SimpleGeometryCursor.js";import{k as i,a as n,f as s,G as o,t as r,g as h}from"../../../chunks/Geometry.js";import{d,P as g,i as a,u as c,f as l,s as u,c as f,n as m}from"../../../chunks/Transformation2D.js";import{a as p,M as E,aA as x,aB as P}from"../../../chunks/QuadraticBezier.js";function _(t,e,i,n,s,o){const r=n-e;if(r<=o)return P(t,e,i,n,s),i;const h=w(t,e,n,s,Math.min(Math.max(r>>1,3),100)),d=t[h];t[e]=u(t[h],t[h]=t[e]);let g=e+1,a=!1;for(let c=e+1;c!==n;++c)s(t[c],d)&&(t[g]=u(t[c],t[c]=t[g]),++g,a=!0);if(!a)for(let c=e+1;c<i;++c)s(d,t[c])||(c!==g&&(t[g]=u(t[c],t[c]=t[g])),++g);return--g,t[g]=u(t[e],t[e]=t[g]),g}function F(t,e,i){const n=Math.trunc(e/2);let s=BigInt(n);const o=BigInt(e);for(let h=0;h<i;++h)t.push(Number(s%o)),s=6364136223846793005n*s+1442695040888963407n&0x7fffffffffffffffn,s=BigInt.asUintN(64,s);m(t);const r=c(t,((t,e)=>t===e));t.length=r}function w(t,e,i,n,s){const o=[];F(o,i-e,s);const r=[];for(let d=0,g=o.length;d<g;d++){const i=o[d];r.push(l(t[e+i],i))}const h=Math.trunc(r.length/2);return r.sort(((t,e)=>n(t.first,e.first)?-1:1)),e+r[h].second}function k(){return{p:new g,userData:Number.NaN,edge:null}}class T{constructor(){this.info=0,this.mask=!1,this.p=null,this.a=[null,null],this.twin=null}nextFreeEdge(){return this.twin}setIndex(t){this.info=t,this.mask=!1}getIndex(){return this.info}setMask(){this.mask=!0}getMask(){return this.mask}}function C(t,e){return{first:t,second:e}}function y(t,e){t.first=e.first,t.second=e.second}function b(){return this.i1-this.i0}function D(){return{i0:Number.NaN,i1:Number.NaN,nextFreeEdgeIndex:[-1],box:[C(null,null),C(null,null)],size:b}}function I(){return{k:0,pTask:null,pTask0:null,pTask1:null}}function X(){return{p:[new g,new g],points:[null,null]}}function Y(){return{p:[null,null,null]}}class N{constructor(){this.m_nextFreePairEdge=C(null,null),this.m_points=[],this.m_pointZero=null,this.m_edges=[],this.m_voronoiToEdge=[],this.m_nextFreeEdge=0}clear(){this.m_nextFreePairEdge=C(null,null),this.m_points.length=0,this.m_pointZero=null,this.m_edges.length=0,this.m_voronoiToEdge.length=0,this.m_nextFreeEdge=0}reservePoints(t){h(t>1)}prepare(t){{const e=k();e.p.x=Number.POSITIVE_INFINITY,e.p.y=Number.POSITIVE_INFINITY,e.userData=t,this.m_points.push(e)}}addVertex(t,e){const i=k();i.p.assign(t),i.userData=e,i.edge=null,this.m_points.push(i)}removeDuplicates(){const t=this.m_points.shift();this.m_points.sort(((t,e)=>t.p.compareX(e.p)));const e=c(this.m_points,((t,e)=>t.p.equals(e.p))),i=e!==this.m_points.length;return this.m_points.length=e,this.m_points.unshift(t),i}removeDuplicatesEx(t){return h(0),!1}boundVoronoiCells(t,e){const i=this.m_points.length;if(i<2)return!1;const n=[this.m_points[1].p.clone(),this.m_points[1].p.clone()];for(let d=2;d<i;d++){const t=this.m_points[d].p;t.x<n[0].x&&(n[0].x=t.x),n[1].x<t.x&&(n[1].x=t.x),t.y<n[0].y&&(n[0].y=t.y),n[1].y<t.y&&(n[1].y=t.y)}const s=new g;s.x=.5*(n[0].x+n[1].x),s.y=.5*(n[0].y+n[1].y);let o=0;for(let d=1;d<i;d++){const t=this.m_points[d].p,e=g.sqrDistanceCoords(t.x,t.y,s.x,s.y);o<e&&(o=e)}const r=Math.sqrt(o),h=Math.max(r+2*t,1.5*r);{const t=.8660254037844386,i=.5;let n=1,o=0;for(let r=0;r<12;r++){const r=new g;r.x=s.x+h*n,r.y=s.y+h*o,this.addVertex(r,e);const d=n*i+o*t;n=n*t-o*i,o=d}}return!0}construct(){const t=D();return!!this.constructTask(t)&&(this.solveTask(t),!0)}constructTask(t){if(this.m_pointZero=this.createZeroHandle(),h(void 0!==this.m_pointZero),this.m_points.length<3)return!1;const e=6*(this.m_points.length-2);this.m_edges=d(T,e);for(let i=0;i<e;i++)this.m_edges[i].setIndex(i);return t.i0=1,t.i1=this.m_points.length,t.nextFreeEdgeIndex[0]=0,!0}splitTask(t,e,i,n){const s=t,o=e,r=i,h=n;s.k=this.findMaxSide(h.i0,h.i1);let d=h.i0+h.i1>>1;const g=1250;if(0===s.k){d=_(this.m_points,h.i0,d,h.i1,((t,e)=>t.p[0]!==e.p[0]?t.p[0]<e.p[0]:t.p[1]<e.p[1]),g)}else{d=_(this.m_points,h.i0,d,h.i1,((t,e)=>t.p[1]!==e.p[1]?t.p[1]<e.p[1]:t.p[0]<e.p[0]),g)}o.i0=h.i0,o.i1=d,o.nextFreeEdgeIndex[0]=h.nextFreeEdgeIndex[0],h.nextFreeEdgeIndex[0]+=6*(o.i1-o.i0-1)+2,r.i0=d,r.i1=h.i1,r.nextFreeEdgeIndex[0]=h.nextFreeEdgeIndex[0],h.nextFreeEdgeIndex[0]+=6*(r.i1-r.i0-1)+2,s.pTask=h,s.pTask0=o,s.pTask1=r}solveMergeTask(t){const e=this.newPairEdgeEx(t.pTask.nextFreeEdgeIndex,!1);if(t.pTask.box[t.k]=C(t.pTask0.box[t.k].first,t.pTask1.box[t.k].second),t.pTask.box[1-t.k]=C(j(this.getPointXYFromEdge(t.pTask0.box[1-t.k].first),this.getPointXYFromEdge(t.pTask1.box[1-t.k].first),1-t.k)?t.pTask0.box[1-t.k].first:t.pTask1.box[1-t.k].first,j(this.getPointXYFromEdge(t.pTask0.box[1-t.k].second),this.getPointXYFromEdge(t.pTask1.box[1-t.k].second),1-t.k)?t.pTask1.box[1-t.k].second:t.pTask0.box[1-t.k].second),t.pTask.i0+2===t.pTask.i1){const i=t.pTask0.box[t.k].second,n=i.twin,s=t.pTask1.box[t.k].first,o=s.twin;return this.joinEdges2(n,o),this.joinEdges2(o,n),void this.join(i,s,0,1,e)}const i=[new Array(2),new Array(2)];i[0][0]=i[1][0]=C(t.pTask0.box[t.k].second,t.pTask0.box[t.k].second.twin),i[0][1]=i[1][1]=C(t.pTask1.box[t.k].first,t.pTask1.box[t.k].first.twin);const n=[!1,!1];if(t.pTask0.i0+1===t.pTask0.i1?(this.findEdgeSide(i[0],n,1,0),this.findEdgeSide(i[1],n,1,1)):(this.findEdge(i[0],n,0),this.findEdge(i[1],n,1)),n[0]||n[1]){if(n[0]){const e=this.newPairEdgeEx(t.pTask0.nextFreeEdgeIndex,!1);this.insertEdge(i[0][0].first,e.first,0),this.insertEdge(i[0][0].second,e.second,1)}if(n[1]){const e=this.newPairEdgeEx(t.pTask1.nextFreeEdgeIndex,!1);this.insertEdge(i[0][1].first,e.first,1),this.insertEdge(i[0][1].second,e.second,0)}}else this.getNextDEdge(i[0][0].first,0)!==i[0][0].first&&(i[1][0]=this.newPairEdgeEx(t.pTask0.nextFreeEdgeIndex,!1),this.insertEdge(i[0][0].first,i[1][0].first,0),this.insertEdge(i[0][0].second,i[1][0].second,1)),this.getNextDEdge(i[0][1].first,0)!==i[0][1].first&&(i[1][1]=this.newPairEdgeEx(t.pTask1.nextFreeEdgeIndex,!1),this.insertEdge(i[0][1].first,i[1][1].first,1),this.insertEdge(i[0][1].second,i[1][1].second,0));this.merge(i[1][0],i[0][0],i[0][1],i[1][1],e)}solveTask(t){const e=t;switch(e.i1-e.i0){case 1:{this.insertPoint(e.i0,e.nextFreeEdgeIndex);const t=this.m_points[e.i0].edge;e.box[0]=e.box[1]=l(t,t)}break;case 2:{const t=e.i0,i=t+1;this.insertPoint(t,e.nextFreeEdgeIndex),this.insertPoint(i,e.nextFreeEdgeIndex);const n=this.m_points[t],s=this.m_points[i],o=n.edge,r=s.edge,h=o.twin,d=r.twin;this.joinEdges2(h,d),this.joinEdges2(d,h);const g=this.newPairEdgeEx(e.nextFreeEdgeIndex,!1);this.join(o,r,0,1,g);for(let a=0;a<2;a++)e.box[a]=j(this.getPointXY(n),this.getPointXY(s),a)?C(o,r):C(r,o)}break;case 3:{const t=[e.i0,e.i0+1,e.i0+2];this.insertPoint(t[0],e.nextFreeEdgeIndex),this.insertPoint(t[1],e.nextFreeEdgeIndex),this.insertPoint(t[2],e.nextFreeEdgeIndex);const i=[this.m_points[t[0]],this.m_points[t[1]],this.m_points[t[2]]],n=this.caseFromCompare(i[0].p,i[1].p,i[2].p),s=[i[0].edge,i[1].edge,i[2].edge],o=N.c_aTableDelaunayTriangulationSolution[n],r=A(19*A(1+(7&o))),h=A(19*A(1+(o>>5)));let d=A(o<<3)>>6;const g=3&r,a=r>>6,c=3&h,l=h>>6;e.box[0]=C(s[g],s[a]),e.box[1]=C(s[c],s[l]);const f=[s[0].twin,s[1].twin,s[2].twin],m=[this.newPairEdgeEx(e.nextFreeEdgeIndex,!1),this.newPairEdgeEx(e.nextFreeEdgeIndex,!1),this.newPairEdgeEx(e.nextFreeEdgeIndex,!1)];switch(3===d&&(d=this.orientation(i[0].p,i[1].p,i[2].p)+1),d){case 0:this.joinEdges2(f[0],f[2]),this.joinEdges2(f[2],f[1]),this.joinEdges2(f[1],f[0]),this.join(s[0],s[2],0,1,m[0]),this.join(s[2],s[1],0,1,m[1]),this.join(s[1],s[0],0,1,m[2]);break;case 1:{const t=[0,1,2];t[3-(g+a)]=u(t[1],t[1]=t[3-(g+a)]),this.joinEdges2(f[t[0]],f[t[1]]),this.joinEdges2(f[t[1]],f[t[2]]),this.joinEdges2(f[t[2]],f[t[0]]),this.join(s[t[0]],s[t[1]],0,1,m[0]),this.join(s[t[1]],s[t[2]],0,1,m[1]),this.join(m[1].first,f[t[2]],0,1,m[2])}break;case 2:this.joinEdges2(f[0],f[1]),this.joinEdges2(f[1],f[2]),this.joinEdges2(f[2],f[0]),this.join(s[0],s[1],0,1,m[0]),this.join(s[1],s[2],0,1,m[1]),this.join(s[2],s[0],0,1,m[2])}}break;default:{const e=I(),i=D(),n=D();this.splitTask(e,i,n,t),this.solveTask(i),this.solveTask(n),this.solveMergeTask(e)}}}constructForConvexHull(){return h(0),!1}getOutsideHull(){const t=[],e=this.m_points[0].edge;let i=e;do{t.push(this.getPointFromEdge(this.getTwinEdge(i))),i=this.getNextDEdge(i,0)}while(i!==e);return t}getConvexHull(){const t=[],e=this.m_points[0].edge;let i=e;do{const e=this.getPointFromEdge(this.getTwinEdge(i));t.length<2||!this.insideLine(this.getPointXY(t.at(-2)),this.getPointXY(t.at(-1)),this.getPointXY(e))?t.push(e):t[t.length-1]=e,i=this.getNextDEdge(i,0)}while(i!==e);return 2<t.length&&this.insideLine(this.getPointXY(t[0]),this.getPointXY(t.at(-1)),this.getPointXY(t.at(-2)))&&t.pop(),2<t.length&&this.insideLine(this.getPointXY(t[1]),this.getPointXY(t[0]),this.getPointXY(t.at(-1)))&&(t[0]=t.at(-1),t.pop()),t}getVoronoiPolygon(t,e){t.length=0;const i=this.getEdgeFromPoint(e);let n=i;for(;;){const e=this.calculateCircleCenter(n);t.push(e);const s=this.getNextDEdge(n,1);if(s===i)break;n=s}}getNearestPoint(t){this.isInfinitePointFromPoint(t)&&r("Not supported for the infinite point");const e=this.getPointXY(t);let i=this.m_pointZero,n=Number.MAX_VALUE;const s=this.getEdgeFromPoint(t);let o=s;do{const t=this.getPointFromEdge(this.getTwinEdge(o));if(!this.isInfinitePointFromPoint(t)){const s=g.sqrDistance(e,this.getPointXY(t));s<n&&(i=t,n=s)}o=this.getCounterClockwiseEdge(o)}while(o!==s);return i}addConstraint(t,e){const i=[null],n=[null];if(!this.constraintFindFirstEdge(i,n,t,e))return C(n[0],i[0]);i[0]=this.getTwinEdge(i[0]);const s=this.getPointXY(t),o=this.getPointXY(e),h=[new Array(0),new Array(0)],d=i[0];for(;;){const t=this.getClockwiseEdge(n[0]);t.getMask()&&r("add_constraint");const d=C(t,this.getTwinEdge(t));this.deleteTwinEdges(d,!0);const g=this.getCounterClockwiseEdge(this.getTwinEdge(i[0])),a=this.getTwinEdge(this.getClockwiseEdge(n[0])),c=this.getPointFromEdge(a);if(c===e){h[0].push(i[0]),i[0]=g,h[1].push(n[0]),n[0]=a;break}const l=this.orientation(s,o,this.getPointXY(c));0===l&&r("add_constraint - point on constraint"),0<l?(h[0].push(i[0]),i[0]=g):(h[1].push(n[0]),n[0]=a)}h[0].push(i[0]),h[1].push(n[0]);const g=this.newPairEdge();g.first.setMask(),g.second.setMask(),this.join(n[0],d,1,1,g),this.triangulateConstraint(h[0],1,h[0].length-1,g),h[1].reverse();const a=C(g.second,g.first);return this.triangulateConstraint(h[1],1,h[1].length-1,a),a}verify(){for(let t=0,e=this.m_edges.length;t<e;t++){const e=this.m_edges[t];if(!e.getMask()&&!this.testEdge(e))return!1}return!0}getDelaunayTriangleCount(){return this.m_points.length-2<<1}getSmallestEnclosingCircle(){return h(0),{}}getVoronoiSegments(t=Number.MAX_VALUE){const e=[];for(let i=0,n=this.m_edges.length;i<n;i+=2){const n=C(null,null);if(n.first=this.m_edges[i],n.second=n.first.twin,this.isInfinitePointFromEdge(n.first)&&(n.second=u(n.first,n.first=n.second)),this.isInfinitePointFromEdge(n.second)){const i=d(g,3);i[0]=this.calculateCircleCenter(this.getNextDEdge(n.first,0).twin,1),i[2]=this.calculateCircleCenter(this.getNextDEdge(n.first,1),1);const s=d(g,2);s[0].assign(i[0]),s[1].assign(i[2]),s[0].rightPerpendicularThis(),s[1].leftPerpendicularThis(),i[1]=i[0].add(s[0]).add(i[2].add(s[1])),i[1].normalize();for(const e of i)e.mulThis(t);const o=X();o.points[0]=n.first.p,o.points[1]=n.second.p;for(let t=0;t<i.length-1;t++){for(let e=0;e<2;e++)o.p[e]=i[t+e];o.p[0].equals(o.p[1])||e.push(o)}}else if(this.isInfinitePointFromEdge(this.getNextDEdge(n.first,0).twin)&&this.isInfinitePointFromEdge(this.getNextDEdge(n.first,1).twin)){const t=d(g,3);t[0]=this.calculateCircleCenter(n.first),t[1]=this.getPointXY(this.getPointFromEdge(n.first)).add(this.getPointXY(this.getPointFromEdge(n.second))).mul(.5),t[2]=this.calculateCircleCenter(n.second);const i=X();i.points[0]=n.first.p,i.points[1]=n.second.p;for(let n=0;n<t.length-1;n++){for(let e=0;e<2;e++)i.p[e]=t[n+e];i.p[0].equals(i.p[1])||e.push(i)}}else{const t=X();t.p[0]=this.calculateCircleCenter(n.first),t.p[1]=this.calculateCircleCenter(n.second),t.points[0]=n.first.p,t.points[1]=n.second.p,t.p[0].equals(t.p[1])||e.push(t)}}return e}startDelaunayTriangles(){return-1}nextDelaunayTriangle(t,e){for(;;){if(++e[0],e[0]===this.m_edges.length)return!1;const i=this.m_edges[e[0]];if(t.p[0]=this.getPointFromEdge(i),this.isInfinitePointFromPoint(t.p[0]))continue;const n=this.getTwinEdge(i);if(t.p[1]=this.getPointFromEdge(n),this.isInfinitePointFromPoint(t.p[1]))continue;if(this.getPointXY(t.p[1]).lt(this.getPointXY(t.p[0])))continue;const s=this.getTwinEdge(this.getNextDEdge(i,1));if(t.p[2]=this.getPointFromEdge(s),!this.isInfinitePointFromPoint(t.p[2])&&!this.getPointXY(t.p[2]).lt(this.getPointXY(t.p[0])))return!0}}getPointCount(){return this.m_points.length-1}getPoint(t){return this.m_points[t+1]}getInfinitePoint(){return this.m_pointZero}isInfinitePointFromPoint(t){return t===this.m_pointZero}getPointXY(t){return t.p}getPointIndex(t){return t.userData}setPointIndex(t,e){t.userData=e}getEdgeFromPoint(t){return t.edge}isInfinitePointFromEdge(t){return t.p===this.m_pointZero}getEdgeCount(){return this.m_edges.length}getEdge(t){return this.m_edges[t]}getEdgeIndex(t){return t.getIndex()}getPointFromEdge(t){return t.p}getPointXYFromEdge(t){return t.p.p}getCounterClockwiseEdge(t){return t.a[0]}getClockwiseEdge(t){return t.a[1]}getTwinEdge(t){return t.twin}getPreviousEdge(t){return this.getTwinEdge(this.getCounterClockwiseEdge(t))}getNextEdge(t){return this.getClockwiseEdge(this.getTwinEdge(t))}getPairEdgeFromPoint(t){return h(0),{}}getNextDEdge(t,e=1){return t.a[e]}newPairEdge(){const t=C(this.m_nextFreePairEdge.first,this.m_nextFreePairEdge.second);return this.m_nextFreePairEdge.first=this.m_nextFreePairEdge.first.nextFreeEdge(),this.m_nextFreePairEdge.second=this.m_nextFreePairEdge.second.nextFreeEdge(),t.first.twin=t.second,t.second.twin=t.first,t}newPairEdgeEx(t,e){let i;if(e&&null!==this.m_nextFreePairEdge.first)i=C(this.m_nextFreePairEdge.first,this.m_nextFreePairEdge.second),this.m_nextFreePairEdge.first=this.m_nextFreePairEdge.first.nextFreeEdge(),this.m_nextFreePairEdge.second=this.m_nextFreePairEdge.second.nextFreeEdge();else{const e=t[0]++,n=t[0]++;i=C(this.m_edges[e],this.m_edges[n])}return i.first.twin=i.second,i.second.twin=i.first,i}insertEdge(t,e,i){e.p=t.p;const n=t.a[i],s=e.a;s[i]=n,s[1-i]=t,t.a[i]=e,n.a[1-i]=e}insertPoint(t,e){const i=this.m_points[t],n=this.newPairEdgeEx(e,!1),s=n.first,o=n.second;i.edge=n.first,s.p=this.m_points[t],s.a[0]=n.first,s.a[1]=n.first,o.p=this.m_pointZero,o.a[0]=n.second,o.a[1]=n.second,null===this.m_points[0].edge&&(this.m_points[0].edge=n.second)}deleteTwinEdges(t,e){this.deleteEdge(t.first),this.deleteEdge(t.second),e&&(t.first.twin=this.m_nextFreePairEdge.first,t.second.twin=this.m_nextFreePairEdge.second,this.m_nextFreePairEdge=t)}join(t,e,i,n,s){this.insertEdge(t,s.first,i),this.insertEdge(e,s.second,n)}joinEdges2(t,e){t.a[1]=e,e.a[0]=t}joinEdges4(t,e,i,n){h(0)}checkEdge(t,e,i,n,s){for(;;){const o=C(null,null);if(o.first=this.getNextDEdge(t.first,n),o.second=o.first.twin,this.isInfinitePointFromEdge(o.second))return t;const r=this.getPointXYFromEdge(t.second),h=this.getPointXYFromEdge(o.second);if(this.inCircle(e,i,r,h)<=0)return t;if(this.deleteTwinEdges(t,s),!s){const e=this.getNextDEdge(t.second,n).twin;this.join(o.second,e,n,n,t)}t=o}}calculateCircleCenter(t,e=Number.MAX_VALUE){const i=this.getPointXYFromEdge(t),n=this.getPointXYFromEdge(t.twin),s=this.getNextDEdge(t,0);if(this.isInfinitePointFromEdge(s.twin)){const t=new g;if(Number.isNaN(e))t.setNAN();else{const s=n.sub(i);s.leftPerpendicularThis(),t.assign(s),t.divThis(Math.max(Math.abs(t.x),Math.abs(t.y))),t.normalize(),t.mulThis(e)}return t}const o=this.getPointXYFromEdge(s.twin);return this.calculateCircleCenterFromThreePoints(i,n,o)}createZeroHandle(){return this.m_points[0]}deleteEdge(t){const e=t,i=e.p;i.edge===t&&(i.edge=e.a[0]),e.a[0].a[1]=e.a[1],e.a[1].a[0]=e.a[0]}testEdge(t){if(this.isInfinitePointFromEdge(t))return!0;const e=t.twin;if(this.isInfinitePointFromEdge(e))return!0;const i=this.getNextDEdge(t,0).twin,n=this.getNextDEdge(e,0).twin;if(this.isInfinitePointFromEdge(i)||this.isInfinitePointFromEdge(n))return!0;const s=this.getPointXYFromEdge(t),o=this.getPointXYFromEdge(e),r=this.getPointXYFromEdge(i),h=this.getPointXYFromEdge(n);return!(this.orientation(s,o,r)<=0)&&(!(0<=this.orientation(s,o,h))&&this.inCircle(s,o,r,h)<=0)}findMaxSide(t,e){const i=[this.m_points[t].p.clone(),this.m_points[t].p.clone()];for(t++;t!==e;t++){const e=this.m_points[t].p;e.x<i[0].x&&(i[0].x=e.x),i[1].x<e.x&&(i[1].x=e.x),e.y<i[0].y&&(i[0].y=e.y),i[1].y<e.y&&(i[1].y=e.y)}return i[1].x-i[0].x<i[1].y-i[0].y?1:0}findEdge(t,e,i){let n=!1,s=0;for(;;){const o=C(null,null);if(o.second=this.getNextDEdge(t[s].second,i^s),o.first=o.second.twin,0===i&&this.orientation(this.getPointXYFromEdge(t[0].first),this.getPointXYFromEdge(t[1].first),this.getPointXYFromEdge(o.first))<0||1===i&&0<this.orientation(this.getPointXYFromEdge(t[0].first),this.getPointXYFromEdge(t[1].first),this.getPointXYFromEdge(o.first)))t[s]=o,e[s]=!0,n=!1;else{if(n)return;s^=1,n=!0}}}findEdgeSide(t,e,i,n){for(;;){const s=C(null,null);if(s.second=this.getNextDEdge(t[i].second,n^i),s.first=s.second.twin,!(0===n&&this.orientation(this.getPointXYFromEdge(t[0].first),this.getPointXYFromEdge(t[1].first),this.getPointXYFromEdge(s.first))<0||1===n&&0<this.orientation(this.getPointXYFromEdge(t[0].first),this.getPointXYFromEdge(t[1].first),this.getPointXYFromEdge(s.first))))return;t[i]=s,e[i]=!0}}merge(t,e,i,n,s){const o={...t},r={...n},h={...s};let d={...e},g={...i};const a=d.second,c=g.second;for(;;){if(this.join(d.first,g.first,0,1,h),d.first=this.getNextDEdge(h.first,0),g.first=this.getNextDEdge(h.second,1),d.first===o.first&&g.first===r.first){this.joinEdges2(a,c),this.joinEdges2(r.second,o.second);break}d.second=d.first.twin,g.second=g.first.twin;const t=this.getPointXYFromEdge(h.first),e=this.getPointXYFromEdge(h.second);if(d.first===o.first){let i=C(null,null);i.first=this.getNextDEdge(g.first,1),i.second=i.first.twin,i=this.checkEdge(i,t,e,1,!1),y(d,h),y(h,g),g=C(i.second,i.first)}else if(g.first===r.first){let i=C(null,null);i.first=this.getNextDEdge(d.first,0),i.second=i.first.twin,i=this.checkEdge(i,t,e,0,!1),g=C(h.second,h.first),y(h,d),d=C(i.second,i.first)}else{let i=C(null,null);i.first=this.getNextDEdge(d.first,0),i.second=i.first.twin,i=this.checkEdge(i,t,e,0,!1);let n=C(null,null);n.first=this.getNextDEdge(g.first,1),n.second=n.first.twin,n=this.checkEdge(n,t,e,1,!1);const s=this.getPointXYFromEdge(i.second),o=this.getPointXYFromEdge(n.second);let r=this.inCircle(t,e,s,o);0===r&&(r=this.orientation(t,e,o)),0<r?(y(d,h),y(h,g),g=C(n.second,n.first)):(g=C(h.second,h.first),y(h,d),d=C(i.second,i.first))}this.deleteTwinEdges(h,!1)}}mergeForConvexHull(t,e,i,n){h(0)}constructForConvexHullRecursive(t,e){h(0)}findEdgeClockwise(t,e,i,n,s,o){for(t[0]=n;;){e[0]=t[0],++e[0]===i.length&&(e[0]=0);const n=this.orientation(s,o,this.getPointXYFromEdge(i[e[0]]));if(n<=0)return n<0;t[0]=e[0]}}findEdgeCounterClockwise(t,e,i,n,s,o){for(e[0]=n;;){t[0]=0!==e[0]?e[0]:i.length,t[0]--;const n=this.orientation(s,o,this.getPointXYFromEdge(i[t[0]]));if(0<=n)return 0<n;e[0]=t[0]}}constraintFindFirstEdge(t,e,i,n){const s=[];{const o=this.getEdgeFromPoint(i);let r=o;do{const i=this.getTwinEdge(r);if(this.getPointFromEdge(i)===n)return t[0]=i,e[0]=r,t[0].setMask(),e[0].setMask(),!1;s.push(i),r=this.getClockwiseEdge(r)}while(r!==o)}s.length<3&&r("add_constraint");let o=-1;for(let c=0,l=s.length;c<l;c++)this.isInfinitePointFromEdge(s[c])&&(-1!==o&&r("add_constraint"),o=c);const h=this.getPointXY(i),d=this.getPointXY(n);let g,a;if(-1!==o){x(s,0,o+1,s.length),s.pop();0===this.orientation(h,d,this.getPointXYFromEdge(s[0]))&&r("add_constraint - point on constraint");for(0===this.orientation(h,d,this.getPointXYFromEdge(s.at(-1)))&&r("add_constraint - point on constraint"),g=0,a=s.length-1;g+1!==a;){const t=g+a>>1,e=this.orientation(h,d,this.getPointXYFromEdge(s[t]));0===e&&r("add_constraint - point on constraint"),0<e?g=t:a=t}}else{let t=0,e=this.orientation(h,d,this.getPointXYFromEdge(s[t]));if(0!==e)if(0<e){const e=[0],i=[0];this.findEdgeClockwise(e,i,s,t,h,d)||r("add_constraint"),g=e[0],a=i[0]}else{const e=[0],i=[0];this.findEdgeCounterClockwise(e,i,s,t,h,d)||r("add_constraint"),g=e[0],a=i[0]}else{t++,e=this.orientation(h,d,this.getPointXYFromEdge(s[t])),e<=0&&r("add_constraint");const i=[0],n=[0];this.findEdgeClockwise(i,n,s,t,h,d)||r("add_constraint"),g=i[0],a=n[0]}}return t[0]=s[g],e[0]=s[a],!0}triangulateConstraint(t,e,i,n){if(e===i)return;let s=i;for(let o=e;o!==i;++o)this.inCircle(this.getPointXYFromEdge(n.first),this.getPointXYFromEdge(n.second),this.getPointXYFromEdge(t[s]),this.getPointXYFromEdge(t[o]))<0&&(s=o);if(s!==i){const e=this.newPairEdge();this.join(n.first,t[s],1,1,e),t[s]=e.second,this.triangulateConstraint(t,s+1,i,e)}if(s!==e){const i=this.newPairEdge();this.join(t[s],n.second,1,0,i),this.triangulateConstraint(t,e,s-1,i)}}insideLine(t,e,i){return 0===this.orientation(t,e,i)&&(e.x<t.x!=e.x<i.x||e.y<t.y!=e.y<i.y)}orientation(t,e,i){return g.orientationRobust(t,e,i)}inCircle(t,e,i,n){return g.inCircleRobust(t,e,i,n)}calculateCircleCenterFromThreePoints(t,e,i){return e.lt(t)&&(e=u(t,t=e)),i.lt(e)&&(i=u(e,e=i)),e.lt(t)&&(e=u(t,t=e)),g.calculateCircleCenterFromThreePoints(t,e,i)}compare(t,e){return 3*((v(t[0]<e[0])<<1)+v(t[0]>e[0]))+(v(t[1]<e[1])<<1)+v(t[1]>e[1])-1}caseFromCompare(t,e,i){return(this.compare(t,e)<<6)+(this.compare(t,i)<<3)+this.compare(e,i)}}function v(t){return t?1:0}function j(t,e,i){return t[i]!==e[i]?t[i]<e[i]:t[1-i]<e[1-i]}function A(t){return 255&t}N.c_aTableDelaunayTriangulationSolution=Uint8Array.from([41,74,0,0,0,0,0,0,0,206,0,0,0,0,0,0,0,0,0,0,65,0,0,0,0,0,33,33,65,0,0,0,0,0,0,0,193,0,0,0,0,0,0,0,0,0,0,214,0,0,0,0,0,86,54,86,0,0,0,0,0,0,0,214,173,0,0,0,0,0,0,0,107,239,0,0,0,0,0,0,0,0,0,181,0,0,0,0,0,0,0,181,0,0,0,0,0,0,117,117,245,0,0,0,0,0,0,0,0,0,103,0,0,0,0,0,0,0,167,0,0,0,0,0,0,231,103,231,0,0,0,0,0,0,50,0,0,0,0,0,0,0,0,198,0,0,41,0,0,74,0,0,49,0,0,49,0,0,50,0,0,194,0,0,193,0,0,194,0,0,0,0,0,206,0,0,0,0,0,0,0,0,54,0,0,0,0,0,0,0,0,198,0,0,0,0,0,82,50,82,0,0,0,0,0,0,0,198,0,66,0,0,65,0,0,66,49,66,33,57,65,82,50,90,0,194,0,0,193,0,0,194,0,0,0,0,0,0,0,214,0,0,0,0,0,86,54,86,0,0,0,0,0,0,0,222,0,0,0,0,0,0,178,0,0,0,0,0,0,230,102,230,177,0,0,177,0,0,178,0,177,0,0,177,0,0,178,0,113,226,113,113,249,226,122,226,0,0,0,0,0,0,102,0,0,0,0,0,0,0,190,0,0,0,0,0,0,230,102,230,0,0,0,165,0,0,0,0,0,0,0,0,243,0,0,0,0,0,173,0,0,0,0,0,0,0,0,165,0,0,0,0,0,0,0,0,245,0,0,0,0,0,107,0,0,239,0,0,163,0,0,163,0,0,167,0,0,247,0,0,243,0,0,247,0,0,37,37,69,0,0,0,0,0,0,0,211,0,0,0,0,0,0,0,69,0,0,0,0,0,37,37,69,0,0,0,0,0,0,0,221,0,0,0,0,215,0,0,211,0,0,215,35,87,35,35,91,87,63,87,0,215,0,0,211,0,0,215,0,0,0,165,0,0,0,0,0,0,115,115,243,0,0,0,0,0,0,181,0,0,0,0,0,0,0,189,0,0,0,0,0,0,117,117,245,0,0,0,99,0,0,99,0,0,103,0,163,0,0,163,0,0,167,0,99,247,115,123,243,231,103,255]);class S{constructor(t){this.m_numberOfSets=t,this.m_elements=Array.from({length:t},((t,e)=>e)),this.m_sizes=f(t,1)}getNumberOfSets(){return this.m_numberOfSets}connected(t,e){return this.findRoot(t)===this.findRoot(e)}connect(t,e){const i=this.findRoot(t),n=this.findRoot(e);return i!==n&&(this.m_sizes[i]<this.m_sizes[n]?(this.m_sizes[n]+=this.m_sizes[i],this.m_elements[i]=n):(this.m_sizes[i]+=this.m_sizes[n],this.m_elements[n]=i),--this.m_numberOfSets,!0)}connectRange(t,e,i){if(e!==i)for(let n=e;n<i;++n)this.connect(t[e],t[n])}size(){return this.m_elements.length}size1(t){return h(0),0}findRoot(t){let e=t;if(this.m_elements[e]!==e)do{this.m_elements[e]=this.m_elements[this.m_elements[e]],e=this.m_elements[e]}while(this.m_elements[e]!==e);return e}}function M(){return l(Number.NaN,l([0,0,0],[0,0,0]))}function G(t,e){if(t.first!==e.first)return t.first-e.first;let i=t.second.first,n=e.second.first;for(let s=0;s<3;++s)if(i[s]!==n[s])return i[s]-n[s];i=t.second.second,n=e.second.second;for(let s=0;s<3;++s)if(i[s]!==n[s])return i[s]-n[s];return 0}class q{getOperatorType(){return 10112}accelerateGeometry(t,e,i){return!1}canAccelerateGeometry(t){return!1}supportsCurves(){return!1}executeMany(t,e,i,n){return new z(t,e,i,n)}execute(t,e,i,n=null){const s=new z(null,e,!1,i);s.addGeometry(t);return s.buildAlphaShape(n)}}class z extends t{alphaShapeConstruct(t,e){const i=t.getEdgeCount(),n=new p({vd:this.m_vertexDescription});if(!n)throw new Error("alphaShapeConstruct");for(let s=0;s<i;++s){if(2!==e[s])continue;const i=C(null,null);i.first=t.getEdge(s),i.second=t.getTwinEdge(i.first);if(1!==e[t.getEdgeIndex(i.second)])continue;t.getPointXYFromEdge(i.first),n.startPath(t.getPointXYFromEdge(i.first));let o=s,r=i.second;for(;;){for(e[o]=3,r=t.getCounterClockwiseEdge(r);1===e[t.getEdgeIndex(r)];)r=t.getCounterClockwiseEdge(r);if(r===i.first)break;n.lineTo(t.getPointXYFromEdge(r)),o=t.getEdgeIndex(r),r=t.getTwinEdge(r)}}return n}alphaShape(t,e){const i=t.getEdgeCount(),n=new Uint8Array(i);for(let s=0;s<i;++s){if(0!==n[s])continue;const i=Y(),o=t.getEdge(s);i.p[0]=t.getPointFromEdge(o);const r=t.getClockwiseEdge(t.getTwinEdge(o));i.p[1]=t.getPointFromEdge(r);const h=t.getEdgeIndex(r),a=t.getClockwiseEdge(t.getTwinEdge(r));i.p[2]=t.getPointFromEdge(a);const c=t.getEdgeIndex(a);let l=1;for(let e=0;e<3;++e)if(t.isInfinitePointFromPoint(i.p[e])){l=2;break}if(1===l){const n=d(g,3);for(let e=0;e<3;++e)n[e]=t.getPointXY(i.p[e]);const s=g.sqrDistance(n[0],n[1]),o=g.sqrDistance(n[1],n[2]),r=g.sqrDistance(n[2],n[0]),h=2*n[1].sub(n[0]).crossProduct(n[2].sub(n[0]));e<s*o*r/(h*h)&&(l=2)}n[s]=n[h]=n[c]=l}return this.alphaShapeConstruct(t,n)}alphaShapeAlphaOut(t,e){const i=t.getEdgeCount(),n=new Uint8Array(i),s=[],o=new S(t.getPointCount());for(let h=0;h<i;++h){if(0!==n[h])continue;const e=Y(),i=t.getEdge(h);e.p[0]=t.getPointFromEdge(i);const o=t.getClockwiseEdge(t.getTwinEdge(i));e.p[1]=t.getPointFromEdge(o);const r=t.getEdgeIndex(o),d=t.getClockwiseEdge(t.getTwinEdge(o));e.p[2]=t.getPointFromEdge(d);const a=t.getEdgeIndex(d);let c=1;for(let n=0;n<3;++n)if(t.isInfinitePointFromPoint(e.p[n])){c=2;break}if(1===c){const i=new Array(3);for(let s=0;s<3;++s)i[s]=t.getPointXY(e.p[s]);const n=g.sqrDistance(i[0],i[1]),o=g.sqrDistance(i[1],i[2]),d=g.sqrDistance(i[2],i[0]),l=i[1].sub(i[0]).crossProduct(i[2].sub(i[0])),u=M();u.first=n*o*d/(l*l),u.second.first[0]=h,u.second.first[1]=r,u.second.first[2]=a,u.second.second[0]=t.getPointIndex(e.p[0]),u.second.second[1]=t.getPointIndex(e.p[1]),u.second.second[2]=t.getPointIndex(e.p[2]),s.push(u),c=2}n[h]=n[r]=n[a]=c}s.sort(((t,e)=>G(t,e)));let r=0;for(const h of s){if(1===o.getNumberOfSets()&&h.first!==r)break;n[h.second.first[0]]=n[h.second.first[1]]=n[h.second.first[2]]=1;const t=[h.second.second[0],h.second.second[1],h.second.second[2]];o.connectRange(t,0,3),r=h.first}return e&&(e[0]=.25*r),this.alphaShapeConstruct(t,n)}constructor(t,e,i,n){super(),this.m_multiPointForAttributes=null,this.m_inputGeometryCursor=null,this.m_index=-1,this.m_nDelaunayPoints=0,this.m_cDelaunay=new N,this.m_vertexDescription=null,this.m_progressTracker=n,this.m_alpha=Number.isNaN(e)||!Number.isFinite(e)||e<0?-1:e<Number.MIN_VALUE?0:e,this.m_bMerge=i,this.m_bDone=!1,this.m_inputGeometryCursor=t,this.prepareDelaunay()}prepareDelaunay(){this.m_nDelaunayPoints=0,this.m_cDelaunay.clear(),0!==this.m_alpha&&this.m_cDelaunay.prepare(a())}next(){if(this.m_bMerge){if(!this.m_bDone){const t=this.calculateAlphaShapeMerging(this.m_inputGeometryCursor,this.m_progressTracker);return this.m_bDone=!0,t}return null}if(!this.m_bDone){const t=this.m_inputGeometryCursor.next();if(null!==t)return i(t),n(t),this.m_index=this.m_inputGeometryCursor.getGeometryID(),this.calculateAlphaShape(t,this.m_progressTracker);this.m_bDone=!0}return null}tock(){return!0}getRank(){return 1}getGeometryID(){return this.m_index}calculateAlphaShapeMerging(t,e){let s;for(;s=t.next();)i(s),n(s),this.addGeometry(s);return this.buildAlphaShape()}calculateAlphaShape(t,e){return t.isEmpty()?new p({vd:t.getDescription()}):(this.prepareDelaunay(),this.addGeometry(t),this.buildAlphaShape())}buildAlphaShape(t=null){if(t&&(t[0]=this.m_alpha),0===this.m_alpha)return this.m_vertexDescription?new p({vd:this.m_vertexDescription}):new p;if(this.m_cDelaunay.removeDuplicates())for(let e=0,i=this.m_cDelaunay.getPointCount();e<i;++e)this.m_cDelaunay.setPointIndex(this.m_cDelaunay.getPoint(e),e);if(!this.m_cDelaunay.construct())return this.m_vertexDescription?new p({vd:this.m_vertexDescription}):new p;return this.m_alpha<0?this.alphaShapeAlphaOut(this.m_cDelaunay,t):this.alphaShape(this.m_cDelaunay,this.m_alpha)}addGeometry(t){if(i(t),n(t),0===this.m_alpha)return;if(this.m_vertexDescription&&this.m_bMerge||(this.m_vertexDescription=t.getDescription(),this.m_vertexDescription.getAttributeCount()>1?this.m_multiPointForAttributes=new E({vd:this.m_vertexDescription}):this.m_multiPointForAttributes=null),t.isEmpty())return;const e=t.getGeometryType();if(s(e)){const e=t,i=new g;for(let t=0,n=e.getPointCount();t<n;t++)e.queryXY(t,i),this.m_cDelaunay.addVertex(i,this.m_nDelaunayPoints++);this.m_multiPointForAttributes&&this.m_multiPointForAttributes.addPoints(e,0,-1)}else if(e===o.enumPoint){const e=t,i=e.getXY();this.m_cDelaunay.addVertex(i,this.m_nDelaunayPoints++),this.m_multiPointForAttributes&&this.m_multiPointForAttributes.add(e)}else r("bad geometry type")}}const V=new q;function O(t,e,i){return V.execute(t,e,null,i)}function R(t,i,n){const s=V.executeMany(new e(t),i,n,null);return Array.from(s)}function Z(){return V.supportsCurves()}export{O as execute,R as executeMany,Z as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{G as e,S as t}from"../../../chunks/SimpleGeometryCursor.js";import{F as r,t as s,j as n,n as o,h as u,aA as m}from"../../../chunks/QuadraticBezier.js";import{G as i,l}from"../../../chunks/Geometry.js";class p{getOperatorType(){return 10008}accelerateGeometry(e,t,r){return!1}canAccelerateGeometry(e){return!1}supportsCurves(){return!0}execute(e,t,s,n){const o=(new r).executeMany(e,s,n);return new a(o,t,s,n)}}class a extends e{constructor(e,t,r,s){super(),this.m_resultPolygons=null,this.m_polygons=e,this.m_polylines=t,this.m_sr=r,this.m_progressTracker=s,this.m_bFirst=!0}tock(){return!0}getRank(){return 1}next(){return this.m_bFirst&&(this.performOperation(),this.m_bFirst=!1),this.m_resultPolygons?this.m_resultPolygons.next():null}getGeometryID(){return null!=this.m_resultPolygons?this.m_resultPolygons.getGeometryID():-1}performOperation(){const e=new s,t=new n;let r,p=o;for(;r=this.m_polylines.next();){if(r.getGeometryType()!==i.enumPolyline||r.isEmpty())continue;p===o?p=t.addGeometry(r):t.appendGeometry(p,r);const n=new s;r.queryEnvelope(n),e.mergeEnvelope2D(n)}if(0===t.getTotalPointCount())return;for(;r=this.m_polygons.next();){if(!l(r.getGeometryType())||r.isEmpty())continue;const n=new s;r.queryEnvelope(n),e.mergeEnvelope2D(n),t.addGeometry(r)}const a=u(this.m_sr,e,!0);this.m_resultPolygons=m(t,p,a,this.m_progressTracker)}}const y=new p;function c(e,r,s){const n=y.execute(new t(e),new t(r),s,null);return Array.from(n)}function h(){return y.supportsCurves()}export{c as execute,h as supportsCurves};
5
+ import{G as e,S as t}from"../../../chunks/SimpleGeometryCursor.js";import{H as r,v as s,k as n,o,j as u,aC as m}from"../../../chunks/QuadraticBezier.js";import{G as i,l}from"../../../chunks/Geometry.js";class p{getOperatorType(){return 10008}accelerateGeometry(e,t,r){return!1}canAccelerateGeometry(e){return!1}supportsCurves(){return!0}execute(e,t,s,n){const o=(new r).executeMany(e,s,n);return new a(o,t,s,n)}}class a extends e{constructor(e,t,r,s){super(),this.m_resultPolygons=null,this.m_polygons=e,this.m_polylines=t,this.m_sr=r,this.m_progressTracker=s,this.m_bFirst=!0}tock(){return!0}getRank(){return 1}next(){return this.m_bFirst&&(this.performOperation(),this.m_bFirst=!1),this.m_resultPolygons?this.m_resultPolygons.next():null}getGeometryID(){return null!=this.m_resultPolygons?this.m_resultPolygons.getGeometryID():-1}performOperation(){const e=new s,t=new n;let r,p=o;for(;r=this.m_polylines.next();){if(r.getGeometryType()!==i.enumPolyline||r.isEmpty())continue;p===o?p=t.addGeometry(r):t.appendGeometry(p,r);const n=new s;r.queryEnvelope(n),e.mergeEnvelope2D(n)}if(0===t.getTotalPointCount())return;for(;r=this.m_polygons.next();){if(!l(r.getGeometryType())||r.isEmpty())continue;const n=new s;r.queryEnvelope(n),e.mergeEnvelope2D(n),t.addGeometry(r)}const a=u(this.m_sr,e,!0);this.m_resultPolygons=m(t,p,a,this.m_progressTracker)}}const y=new p;function c(e,r,s){const n=y.execute(new t(e),new t(r),s,null);return Array.from(n)}function h(){return y.supportsCurves()}export{c as execute,h as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{G as e,S as r}from"../../../chunks/SimpleGeometryCursor.js";import{av as t,P as n}from"../../../chunks/QuadraticBezier.js";import{a as s}from"../../../chunks/Geometry.js";class u{getOperatorType(){return 10109}supportsCurves(){return!0}accelerateGeometry(e,r,t){return!1}canAccelerateGeometry(e){return!1}executeMany(e,r){return new i(e,r)}execute(e,r){return o(e)}}function o(e,r){const s=t(e);return null===s?new n({vd:e.getDescription()}):s}class i extends e{constructor(e,r){super(),this.m_progressTracker=r,this.m_index=-1,this.m_bDone=!1,this.m_inputGeometryCursor=e}next(){if(!this.m_bDone){const e=this.m_inputGeometryCursor.next();if(null!==e)return s(e),this.m_index=this.m_inputGeometryCursor.getGeometryID(),o(e);this.m_bDone=!0}return null}getGeometryID(){return this.m_index}tock(){return!0}getRank(){return 1}}const c=new u;function m(e){return c.execute(e,null)}function a(e){const t=c.executeMany(new r(e),null);return Array.from(t)}function p(){return c.supportsCurves()}export{m as execute,a as executeMany,p as supportsCurves};
5
+ import{G as e,S as r}from"../../../chunks/SimpleGeometryCursor.js";import{ax as t,P as n}from"../../../chunks/QuadraticBezier.js";import{a as s}from"../../../chunks/Geometry.js";class u{getOperatorType(){return 10109}supportsCurves(){return!0}accelerateGeometry(e,r,t){return!1}canAccelerateGeometry(e){return!1}executeMany(e,r){return new i(e,r)}execute(e,r){return o(e)}}function o(e,r){const s=t(e);return null===s?new n({vd:e.getDescription()}):s}class i extends e{constructor(e,r){super(),this.m_progressTracker=r,this.m_index=-1,this.m_bDone=!1,this.m_inputGeometryCursor=e}next(){if(!this.m_bDone){const e=this.m_inputGeometryCursor.next();if(null!==e)return s(e),this.m_index=this.m_inputGeometryCursor.getGeometryID(),o(e);this.m_bDone=!0}return null}getGeometryID(){return this.m_index}tock(){return!0}getRank(){return 1}}const c=new u;function m(e){return c.execute(e,null)}function a(e){const t=c.executeMany(new r(e),null);return Array.from(t)}function p(){return c.supportsCurves()}export{m as execute,a as executeMany,p as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{S as e,G as t}from"../../../chunks/SimpleGeometryCursor.js";import{t as r,a as n}from"../../../chunks/Geometry.js";import{F as s,t as i}from"../../../chunks/QuadraticBezier.js";import{B as u}from"../../../chunks/Bufferer-fr1_Nc47.js";class m{getOperatorType(){return 10004}supportsCurves(){return!0}accelerateGeometry(e,t,r){return!1}canAccelerateGeometry(e){return!1}executeMany(e,t,r,n,s){return this.executeManyEx(e,t,r,Number.NaN,96,n,s)}execute(t,n,s,i){Number.isFinite(s)||r("Invalid distance for buffer operation");const u=new e([t]),m=[s];return this.executeMany(u,n,m,!1,i).next()}executeManyEx(e,t,n,i,u,m,a){if(void 0!==n.find((e=>!Number.isFinite(e)))&&r("Invalid distance for buffer operation"),m){const r=new o(e,t,n,i,u,!1,a);return(new s).executeMany(r,t,a,2)}return new o(e,t,n,i,u,!1,a)}}class o extends t{constructor(e,t,r,n,s,m,o){super(),this.m_currentUnionEnvelope2D=new i,this.m_index=-1,this.m_dindex=-1,this.m_progressTracker=o,this.m_bufferer=new u(o),this.m_inputGeoms=e,this.m_spatialReference=t,this.m_distances=r,this.m_maxDeviation=n,this.m_maxVerticesInFullCircle=s}tock(){return!0}getRank(){return 1}next(){{let e;for(;e=this.m_inputGeoms.next();)return n(e),this.m_index=this.m_inputGeoms.getGeometryID(),this.m_dindex+1<this.m_distances.length&&this.m_dindex++,this.buffer(e,this.m_distances[this.m_dindex]);return null}}getGeometryID(){return this.m_index}buffer(e,t){return this.m_bufferer.buffer(e,t,this.m_spatialReference,0,0,4,this.m_maxDeviation,this.m_maxVerticesInFullCircle)}}const a=new m;function c(e,t,r){return a.execute(e,t,r,null)}function f(t,r,n,s){const i=a.executeMany(new e(t),r,n,s,null);return Array.from(i)}function h(t,r,n,s,i,u){const m=a.executeManyEx(new e(t),r,n,s,i,u,null);return Array.from(m)}function x(){return a.supportsCurves()}export{c as execute,f as executeMany,h as executeManyEx,x as supportsCurves};
5
+ import{S as e,G as t}from"../../../chunks/SimpleGeometryCursor.js";import{t as r,a as n}from"../../../chunks/Geometry.js";import{H as s,v as i}from"../../../chunks/QuadraticBezier.js";import{B as u}from"../../../chunks/Bufferer-BhkgvSV4.js";class m{getOperatorType(){return 10004}supportsCurves(){return!0}accelerateGeometry(e,t,r){return!1}canAccelerateGeometry(e){return!1}executeMany(e,t,r,n,s){return this.executeManyEx(e,t,r,Number.NaN,96,n,s)}execute(t,n,s,i){Number.isFinite(s)||r("Invalid distance for buffer operation");const u=new e([t]),m=[s];return this.executeMany(u,n,m,!1,i).next()}executeManyEx(e,t,n,i,u,m,a){if(void 0!==n.find((e=>!Number.isFinite(e)))&&r("Invalid distance for buffer operation"),m){const r=new o(e,t,n,i,u,!1,a);return(new s).executeMany(r,t,a,2)}return new o(e,t,n,i,u,!1,a)}}class o extends t{constructor(e,t,r,n,s,m,o){super(),this.m_currentUnionEnvelope2D=new i,this.m_index=-1,this.m_dindex=-1,this.m_progressTracker=o,this.m_bufferer=new u(o),this.m_inputGeoms=e,this.m_spatialReference=t,this.m_distances=r,this.m_maxDeviation=n,this.m_maxVerticesInFullCircle=s}tock(){return!0}getRank(){return 1}next(){{let e;for(;e=this.m_inputGeoms.next();)return n(e),this.m_index=this.m_inputGeoms.getGeometryID(),this.m_dindex+1<this.m_distances.length&&this.m_dindex++,this.buffer(e,this.m_distances[this.m_dindex]);return null}}getGeometryID(){return this.m_index}buffer(e,t){return this.m_bufferer.buffer(e,t,this.m_spatialReference,0,0,4,this.m_maxDeviation,this.m_maxVerticesInFullCircle)}}const a=new m;function c(e,t,r){return a.execute(e,t,r,null)}function f(t,r,n,s){const i=a.executeMany(new e(t),r,n,s,null);return Array.from(i)}function h(t,r,n,s,i,u){const m=a.executeManyEx(new e(t),r,n,s,i,u,null);return Array.from(m)}function x(){return a.supportsCurves()}export{c as execute,f as executeMany,h as executeManyEx,x as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{G as t,S as e}from"../../../chunks/SimpleGeometryCursor.js";import{k as n,a as r,G as o,c as u,t as i}from"../../../chunks/Geometry.js";import{aF as s,aG as m,aH as a,P as c,b as g,t as y,a as l,aI as f,aJ as p}from"../../../chunks/QuadraticBezier.js";class x{getOperatorType(){return 10102}supportsCurves(){return!1}accelerateGeometry(t,e,n){return!1}canAccelerateGeometry(t){return!1}executeMany(t,e,n){return new C(e,t,n)}execute(t,e){return G(t)}isConvex(t,e){if(n(t),r(t),t.isEmpty())return!0;const i=t.getGeometryType();if(i===o.enumPoint)return!0;if(i===o.enumEnvelope){const e=t;return e.getXMin()!==e.getXMax()&&e.getYMin()!==e.getYMax()}if(u(i)){const e=t;return!e.getStartXY().equals(e.getEndXY())}if(i===o.enumMultiPoint){return 1===t.getPointCount()}if(i===o.enumPolyline){const e=t;return 1===e.getPathCount()&&2===e.getPointCount()&&!e.getXY(0).equals(e.getXY(1))}if(i===o.enumGeometryCollection){const n=t;return 1===n.getGeometryCount()&&this.isConvex(n.getGeometry(0),e)}const m=t;return!(1!==m.getPathCount()||m.getPointCount()<3)&&s(m,0)}constructOrientedMinimumBoundingBox(t,e,n,r,o){m(t,e,n,r,o)}}class C extends t{constructor(t,e,n){super(),e||i(""),this.m_progressTracker=n,this.m_index=-1,this.m_bMerge=t,this.m_bDone=!1,this.m_inputGeometryCursor=e}getGeometryID(){return this.m_index}tock(){return!0}getRank(){return 1}next(){if(this.m_bMerge){if(!this.m_bDone){const t=h(this.m_inputGeometryCursor);return this.m_bDone=!0,t}return null}if(!this.m_bDone){const t=this.m_inputGeometryCursor.next();if(null!==t)return n(t),r(t),this.m_index=this.m_inputGeometryCursor.getGeometryID(),G(t);this.m_bDone=!0}return null}}function h(t,e){const o=new a;let u;for(;u=t.next();)n(u),r(u),o.addGeometry(u);return o.getBoundingGeometry()}function G(t,e){if(t||i(""),n(t),r(t),t.isEmpty())return t.createInstance();const s=t.getGeometryType();if(u(s)){const e=t;if(e.getStartXY().equals(e.getEndXY())){const t=new c;return e.queryStart(t),t}{const n=new c,r=new g({vd:t.getDescription()});return e.queryStart(n),r.startPathPoint(n),e.queryEnd(n),r.lineToPoint(n),r}}if(s===o.enumEnvelope){const e=t,n=new y;if(e.queryEnvelope(n),n.xmin===n.xmax&&n.ymin===n.ymax){const t=new c;return e.queryCornerByVal(0,t),t}if(n.xmin===n.xmax||n.ymin===n.ymax){const n=new c,r=new g({vd:t.getDescription()});return e.queryCornerByVal(0,n),r.startPathPoint(n),e.queryCornerByVal(1,n),r.lineToPoint(n),r}{const n=new l({vd:t.getDescription()});return n.addEnvelope(e,!1),n}}if(s===o.enumGeometryCollection)return h(f(t,-1));if(P(t)){if(s===o.enumMultiPoint){const e=t,n=new c;return e.getPointByVal(0,n),n}return t}return p(t)}function P(t,e){if(n(t),r(t),t.isEmpty())return!0;const i=t.getGeometryType();if(i===o.enumPoint)return!0;if(i===o.enumEnvelope){const e=t;return e.getXMin()!==e.getXMax()&&e.getYMin()!==e.getYMax()}if(u(i)){const e=t;return!e.getStartXY().equals(e.getEndXY())}if(i===o.enumMultiPoint){return 1===t.getPointCount()}if(i===o.enumPolyline){const e=t;return 1===e.getPathCount()&&2===e.getPointCount()&&!e.getXY(0).equals(e.getXY(1))}if(i===o.enumGeometryCollection){const e=t;return 1===e.getGeometryCount()&&P(e.getGeometry(0))}const m=t;return!(1!==m.getPathCount()||m.getPointCount()<3)&&s(m,0)}const d=new x;function M(t){return d.execute(t,null)}function _(t,n){const r=d.executeMany(new e(t),n,null);return Array.from(r)}function X(t){return d.isConvex(t,null)}function Y(t,e,n,r,o){return d.constructOrientedMinimumBoundingBox(t,e,n,r,o)}function v(){return d.supportsCurves()}export{Y as constructOrientedMinimumBoundingBox,M as execute,_ as executeMany,X as isConvex,v as supportsCurves};
5
+ import{G as t,S as e}from"../../../chunks/SimpleGeometryCursor.js";import{k as n,a as r,G as o,c as u,t as i}from"../../../chunks/Geometry.js";import{aH as s,aI as m,aJ as a,P as c,b as g,v as y,a as l,aK as f,aL as p}from"../../../chunks/QuadraticBezier.js";class x{getOperatorType(){return 10102}supportsCurves(){return!1}accelerateGeometry(t,e,n){return!1}canAccelerateGeometry(t){return!1}executeMany(t,e,n){return new C(e,t,n)}execute(t,e){return P(t)}isConvex(t,e){if(n(t),r(t),t.isEmpty())return!0;const i=t.getGeometryType();if(i===o.enumPoint)return!0;if(i===o.enumEnvelope){const e=t;return e.getXMin()!==e.getXMax()&&e.getYMin()!==e.getYMax()}if(u(i)){const e=t;return!e.getStartXY().equals(e.getEndXY())}if(i===o.enumMultiPoint){return 1===t.getPointCount()}if(i===o.enumPolyline){const e=t;return 1===e.getPathCount()&&2===e.getPointCount()&&!e.getXY(0).equals(e.getXY(1))}if(i===o.enumGeometryCollection){const n=t;return 1===n.getGeometryCount()&&this.isConvex(n.getGeometry(0),e)}const m=t;return!(1!==m.getPathCount()||m.getPointCount()<3)&&s(m,0)}constructOrientedMinimumBoundingBox(t,e,n,r,o){m(t,e,n,r,o)}}class C extends t{constructor(t,e,n){super(),e||i(""),this.m_progressTracker=n,this.m_index=-1,this.m_bMerge=t,this.m_bDone=!1,this.m_inputGeometryCursor=e}getGeometryID(){return this.m_index}tock(){return!0}getRank(){return 1}next(){if(this.m_bMerge){if(!this.m_bDone){const t=h(this.m_inputGeometryCursor);return this.m_bDone=!0,t}return null}if(!this.m_bDone){const t=this.m_inputGeometryCursor.next();if(null!==t)return n(t),r(t),this.m_index=this.m_inputGeometryCursor.getGeometryID(),P(t);this.m_bDone=!0}return null}}function h(t,e){const o=new a;let u;for(;u=t.next();)n(u),r(u),o.addGeometry(u);return o.getBoundingGeometry()}function P(t,e){if(t||i(""),n(t),r(t),t.isEmpty())return t.createInstance();const s=t.getGeometryType();if(u(s)){const e=t;if(e.getStartXY().equals(e.getEndXY())){const t=new c;return e.queryStart(t),t}{const n=new c,r=new g({vd:t.getDescription()});return e.queryStart(n),r.startPathPoint(n),e.queryEnd(n),r.lineToPoint(n),r}}if(s===o.enumEnvelope){const e=t,n=new y;if(e.queryEnvelope(n),n.xmin===n.xmax&&n.ymin===n.ymax){const t=new c;return e.queryCornerByVal(0,t),t}if(n.xmin===n.xmax||n.ymin===n.ymax){const n=new c,r=new g({vd:t.getDescription()});return e.queryCornerByVal(0,n),r.startPathPoint(n),e.queryCornerByVal(1,n),r.lineToPoint(n),r}{const n=new l({vd:t.getDescription()});return n.addEnvelope(e,!1),n}}if(s===o.enumGeometryCollection)return h(f(t,-1));if(G(t)){if(s===o.enumMultiPoint){const e=t,n=new c;return e.getPointByVal(0,n),n}return t}return p(t)}function G(t,e){if(n(t),r(t),t.isEmpty())return!0;const i=t.getGeometryType();if(i===o.enumPoint)return!0;if(i===o.enumEnvelope){const e=t;return e.getXMin()!==e.getXMax()&&e.getYMin()!==e.getYMax()}if(u(i)){const e=t;return!e.getStartXY().equals(e.getEndXY())}if(i===o.enumMultiPoint){return 1===t.getPointCount()}if(i===o.enumPolyline){const e=t;return 1===e.getPathCount()&&2===e.getPointCount()&&!e.getXY(0).equals(e.getXY(1))}if(i===o.enumGeometryCollection){const e=t;return 1===e.getGeometryCount()&&G(e.getGeometry(0))}const m=t;return!(1!==m.getPathCount()||m.getPointCount()<3)&&s(m,0)}const d=new x;function M(t){return d.execute(t,null)}function _(t,n){const r=d.executeMany(new e(t),n,null);return Array.from(r)}function v(t){return d.isConvex(t,null)}function X(t,e,n,r,o){return d.constructOrientedMinimumBoundingBox(t,e,n,r,o)}function Y(){return d.supportsCurves()}export{X as constructOrientedMinimumBoundingBox,M as execute,_ as executeMany,v as isConvex,Y as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{S as r}from"../../../chunks/SimpleGeometryCursor.js";import"../../../chunks/Geometry.js";import{o as n}from"../../../chunks/QuadraticBezier.js";import"../../../chunks/Transformation2D.js";const e=new n;function o(r,n,o){return e.execute(r,n,o,null)}function t(n,o,t){const u=e.executeMany(new r(n),new r([o]),t,null);return Array.from(u)}function u(){return e.supportsCurves()}export{o as execute,t as executeMany,u as supportsCurves};
5
+ import{S as r}from"../../../chunks/SimpleGeometryCursor.js";import"../../../chunks/Geometry.js";import{p as n}from"../../../chunks/QuadraticBezier.js";import"../../../chunks/Transformation2D.js";const e=new n;function t(r,n,t){return e.execute(r,n,t,null)}function o(n,t,o){const u=e.executeMany(new r(n),new r([t]),o,null);return Array.from(u)}function u(){return e.supportsCurves()}export{t as execute,o as executeMany,u as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{S as r}from"../../../chunks/SimpleGeometryCursor.js";import{u as e}from"../../../chunks/QuadraticBezier.js";import"../../../chunks/Geometry.js";import"../../../chunks/Transformation2D.js";import{l as n,i as o,p as t}from"../../../chunks/pe.js";let s;function u(){return!!s&&o()}async function i(){if(!u()){const[r]=await Promise.all([import("../../../chunks/OperatorGeodesicBuffer.js"),n()]);s=new r.OperatorGeodesicBuffer,e(t)}}function c(r,e,n,o,t){return s.execute(r,e,n,o,t,!1,null)}function a(e,n,o,t,u,i){const c=s.executeMany(new r(e),n,o,t,u,!1,i,null);return Array.from(c)}function f(){return s.supportsCurves()}export{c as execute,a as executeMany,u as isLoaded,i as load,f as supportsCurves};
5
+ import{S as r}from"../../../chunks/SimpleGeometryCursor.js";import{w as e}from"../../../chunks/QuadraticBezier.js";import"../../../chunks/Geometry.js";import"../../../chunks/Transformation2D.js";import{l as n,i as o,p as t}from"../../../chunks/pe.js";let s;function u(){return!!s&&o()}async function i(){if(!u()){const[r]=await Promise.all([import("../../../chunks/OperatorGeodesicBuffer.js"),n()]);s=new r.OperatorGeodesicBuffer,e(t)}}function c(r,e,n,o,t){return s.execute(r,e,n,o,t,!1,null)}function a(e,n,o,t,u,i){const c=s.executeMany(new r(e),n,o,t,u,!1,i,null);return Array.from(c)}function f(){return s.supportsCurves()}export{c as execute,a as executeMany,u as isLoaded,i as load,f as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{u as r}from"../../../chunks/QuadraticBezier.js";import"../../../chunks/Geometry.js";import"../../../chunks/Transformation2D.js";import{l as t,i as e,p as n}from"../../../chunks/pe.js";let o;function s(){return!!o&&e()}async function i(){if(!s()){const[e]=await Promise.all([import("../../../chunks/OperatorGeodeticArea.js"),t()]);o=new e.OperatorGeodeticArea,r(n)}}function u(r,t,e){return o.execute(r,t,e,null)}function a(){return o.supportsCurves()}export{u as execute,s as isLoaded,i as load,a as supportsCurves};
5
+ import{w as r}from"../../../chunks/QuadraticBezier.js";import"../../../chunks/Geometry.js";import"../../../chunks/Transformation2D.js";import{l as t,i as e,p as n}from"../../../chunks/pe.js";let o;function s(){return!!o&&e()}async function i(){if(!s()){const[e]=await Promise.all([import("../../../chunks/OperatorGeodeticArea.js"),t()]);o=new e.OperatorGeodeticArea,r(n)}}function u(r,t,e){return o.execute(r,t,e,null)}function a(){return o.supportsCurves()}export{u as execute,s as isLoaded,i as load,a as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{S as r}from"../../../chunks/SimpleGeometryCursor.js";import{u as e}from"../../../chunks/QuadraticBezier.js";import"../../../chunks/Geometry.js";import"../../../chunks/Transformation2D.js";import{l as n,i as t,p as o}from"../../../chunks/pe.js";let s;function u(){return!!s&&t()}async function i(){if(!u()){const[r]=await Promise.all([import("../../../chunks/OperatorGeodeticDensifyByLength.js"),n()]);s=new r.OperatorGeodeticDensifyByLength,e(o)}}function c(r,e,n,t){return s.execute(r,e,n,t,null)}function a(e,n,t,o){const u=s.executeMany(new r(e),n,t,o,null);return Array.from(u)}function m(){return s.supportsCurves()}export{c as execute,a as executeMany,u as isLoaded,i as load,m as supportsCurves};
5
+ import{S as r}from"../../../chunks/SimpleGeometryCursor.js";import{w as e}from"../../../chunks/QuadraticBezier.js";import"../../../chunks/Geometry.js";import"../../../chunks/Transformation2D.js";import{l as n,i as t,p as o}from"../../../chunks/pe.js";let s;function i(){return!!s&&t()}async function u(){if(!i()){const[r]=await Promise.all([import("../../../chunks/OperatorGeodeticDensifyByLength.js"),n()]);s=new r.OperatorGeodeticDensifyByLength,e(o)}}function c(r,e,n,t){return s.execute(r,e,n,t,null)}function a(e,n,t,o){const i=s.executeMany(new r(e),n,t,o,null);return Array.from(i)}function m(){return s.supportsCurves()}export{c as execute,a as executeMany,i as isLoaded,u as load,m as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{u as t}from"../../../chunks/QuadraticBezier.js";import"../../../chunks/Geometry.js";import"../../../chunks/Transformation2D.js";import{l as r,i as e,p as n}from"../../../chunks/pe.js";let s;function o(){return!!s&&e()}async function i(){if(!o()){const[e]=await Promise.all([import("../../../chunks/OperatorGeodeticDistance.js"),r()]);s=new e.OperatorGeodeticDistance,t(n)}}function u(t,r,e,n){return s.execute(t,r,e,n,null)}function c(){return s.supportsCurves()}export{u as execute,o as isLoaded,i as load,c as supportsCurves};
5
+ import{w as t}from"../../../chunks/QuadraticBezier.js";import"../../../chunks/Geometry.js";import"../../../chunks/Transformation2D.js";import{l as r,i as e,p as n}from"../../../chunks/pe.js";let s;function o(){return!!s&&e()}async function i(){if(!o()){const[e]=await Promise.all([import("../../../chunks/OperatorGeodeticDistance.js"),r()]);s=new e.OperatorGeodeticDistance,t(n)}}function c(t,r,e,n){return s.execute(t,r,e,n,null)}function u(){return s.supportsCurves()}export{c as execute,o as isLoaded,i as load,u as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{u as t}from"../../../chunks/QuadraticBezier.js";import"../../../chunks/Geometry.js";import"../../../chunks/Transformation2D.js";import{l as r,i as e,p as n}from"../../../chunks/pe.js";let o;function s(){return!!o&&e()}async function i(){if(!s()){const[e]=await Promise.all([import("../../../chunks/OperatorGeodeticLength.js"),r()]);o=new e.OperatorGeodeticLength,t(n)}}function u(t,r,e){return o.execute(t,r,e,null)}function c(){return o.supportsCurves()}export{u as execute,s as isLoaded,i as load,c as supportsCurves};
5
+ import{w as t}from"../../../chunks/QuadraticBezier.js";import"../../../chunks/Geometry.js";import"../../../chunks/Transformation2D.js";import{l as r,i as e,p as n}from"../../../chunks/pe.js";let o;function s(){return!!o&&e()}async function i(){if(!s()){const[e]=await Promise.all([import("../../../chunks/OperatorGeodeticLength.js"),r()]);o=new e.OperatorGeodeticLength,t(n)}}function u(t,r,e){return o.execute(t,r,e,null)}function c(){return o.supportsCurves()}export{u as execute,s as isLoaded,i as load,c as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{G as e,S as t}from"../../../chunks/SimpleGeometryCursor.js";import{a as r}from"../../../chunks/Geometry.js";import{F as s,t as i}from"../../../chunks/QuadraticBezier.js";import{B as n}from"../../../chunks/Bufferer-fr1_Nc47.js";class m{getOperatorType(){return 10111}supportsCurves(){return!0}accelerateGeometry(e,t,r){return!1}canAccelerateGeometry(e){return!1}executeMany(e,t,r,i,n,m,o,a,c,h,_){if(c){const c=new u(e,t,r,i,n,m,o,a,_);return(new s).executeMany(c,t,_,2)}return new u(e,t,r,i,n,m,o,a,_)}}class u extends e{constructor(e,t,r,s,m,u,o,a,c){super(),this.m_currentUnionEnvelope2D=new i,this.m_index=-1,this.m_dindex=-1,this.m_progressTracker=c,this.m_bufferer=new n(c),this.m_inputGeoms=e,this.m_spatialReference=t,this.m_distances=r,this.m_maxDeviation=o,this.m_maxVerticesInFullCircle=a,this.m_joins=s,this.m_caps=m,this.m_miterLimit=u}tock(){return!0}getRank(){return 1}next(){{let e;for(;e=this.m_inputGeoms.next();)return r(e),this.m_index=this.m_inputGeoms.getGeometryID(),this.m_dindex+1<this.m_distances.length&&this.m_dindex++,this.buffer(e,this.m_distances[this.m_dindex]);return null}}getGeometryID(){return this.m_index}buffer(e,t){return this.m_bufferer.buffer(e,t,this.m_spatialReference,this.m_joins,this.m_caps,this.m_miterLimit,this.m_maxDeviation,this.m_maxVerticesInFullCircle)}}const o=new m;function a(e,r,s,i,n,m,u,a,c){const h=o.executeMany(new t(e),r,s,i,n,m,u,a,c,0,null);return Array.from(h)}function c(){return o.supportsCurves()}export{a as executeMany,c as supportsCurves};
5
+ import{G as e,S as t}from"../../../chunks/SimpleGeometryCursor.js";import{a as r}from"../../../chunks/Geometry.js";import{H as s,v as i}from"../../../chunks/QuadraticBezier.js";import{B as n}from"../../../chunks/Bufferer-BhkgvSV4.js";class m{getOperatorType(){return 10111}supportsCurves(){return!0}accelerateGeometry(e,t,r){return!1}canAccelerateGeometry(e){return!1}executeMany(e,t,r,i,n,m,o,a,c,h,_){if(c){const c=new u(e,t,r,i,n,m,o,a,_);return(new s).executeMany(c,t,_,2)}return new u(e,t,r,i,n,m,o,a,_)}}class u extends e{constructor(e,t,r,s,m,u,o,a,c){super(),this.m_currentUnionEnvelope2D=new i,this.m_index=-1,this.m_dindex=-1,this.m_progressTracker=c,this.m_bufferer=new n(c),this.m_inputGeoms=e,this.m_spatialReference=t,this.m_distances=r,this.m_maxDeviation=o,this.m_maxVerticesInFullCircle=a,this.m_joins=s,this.m_caps=m,this.m_miterLimit=u}tock(){return!0}getRank(){return 1}next(){{let e;for(;e=this.m_inputGeoms.next();)return r(e),this.m_index=this.m_inputGeoms.getGeometryID(),this.m_dindex+1<this.m_distances.length&&this.m_dindex++,this.buffer(e,this.m_distances[this.m_dindex]);return null}}getGeometryID(){return this.m_index}buffer(e,t){return this.m_bufferer.buffer(e,t,this.m_spatialReference,this.m_joins,this.m_caps,this.m_miterLimit,this.m_maxDeviation,this.m_maxVerticesInFullCircle)}}const o=new m;function a(e,r,s,i,n,m,u,a,c){const h=o.executeMany(new t(e),r,s,i,n,m,u,a,c,0,null);return Array.from(h)}function c(){return o.supportsCurves()}export{a as executeMany,c as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{G as e,S as t}from"../../../chunks/SimpleGeometryCursor.js";import{o as s,G as i,a as r}from"../../../chunks/Geometry.js";import{j as m,n as o,aP as h,aQ as n,t as a,aR as _,h as p,k as u,s as l,l as y,aS as c,aT as G,P as g,C as d,aU as f}from"../../../chunks/QuadraticBezier.js";class x{getOperatorType(){return 10009}supportsCurves(){return!0}accelerateGeometry(e,t,s){return!1}canAccelerateGeometry(e){return!1}executeMany(e,t,s,i=0){return new T(e,t,s,i)}}class T extends e{constructor(e,t,i,r){super(),this.m_shape=new m,this.m_currentGeom=o,this.m_progressCounter=0,this.m_geomIndex=-1,this.m_geomTypeIndex=-1,this.m_index=-1,this.m_bBuilt=!1,this.m_bOutputOnlyModified=!1,this.m_bSimplifyPolygons=!1,this.m_bSnapToSr=!1,this.m_progressTracker=i,this.m_inputGeometries=e,this.m_sr=t,this.m_options=r,1===r||2===r?(this.m_bOutputOnlyModified=!0,this.m_options=0,this.m_bSimplifyPolygons=!0,this.m_bSnapToSr=null!=t&&2===r,this.m_bSnapToSr&&!h()&&s("PE is required for snapping to spatial reference operation")):0===r&&(this.m_bSimplifyPolygons=!0)}progress_(e=!1){}tock(){return!0}getRank(){return 1}moveToNextGeom(){for(;;){if(this.m_bBuilt?this.m_currentGeom=this.m_shape.getNextGeometry(this.m_currentGeom):(this.m_currentGeom=this.m_shape.getFirstGeometry(),this.m_bBuilt=!0),this.m_currentGeom!==o){let e=!1;if(this.m_bSimplifyPolygons&&this.m_shape.getGeometryType(this.m_currentGeom)===i.enumPolygon&&(e=n(this.m_shape,this.m_currentGeom,-1,!1,o,this.m_progressTracker)),this.m_bOutputOnlyModified&&!e&&!this.m_shape.getGeometryModified(this.m_currentGeom))continue}break}}next(){if(this.m_bBuilt)this.moveToNextGeom();else{this.m_geomIndex=this.m_shape.createGeometryUserIndex();const e=new a;for(let o=this.m_inputGeometries.next();null!=o;o=this.m_inputGeometries.next()){this.progress_(),r(o);let t=!1;this.m_bSnapToSr&&(o=o.clone(),t=_(this.m_sr,o));const s=this.m_shape.addGeometry(o);this.m_shape.setGeometryUserIndex(s,this.m_geomIndex,this.m_inputGeometries.getGeometryID());const m=o.getGeometryType();m===i.enumPoint&&(-1===this.m_geomTypeIndex&&(this.m_geomTypeIndex=this.m_shape.createGeometryUserIndex()),this.m_shape.setGeometryUserIndex(s,this.m_geomTypeIndex,m));const h=new a;o.queryLooseEnvelope(h),e.mergeEnvelope2D(h),t&&this.m_shape.setGeometryModified(s,!0)}const t=p(this.m_sr,e,!0),s=p(this.m_sr,e,!1);e.inflate(10*t.total()),this.m_shape.forceSetEnvelope2D(e);let m=null,h=0,g=0;if(this.m_shape.hasCurves()){m=new d;const s=u(t.total(),e);h=l(t.total()),g=f(s,h),y(this.m_shape,s,t.total(),12e3,m,null,this.m_progressTracker)}if(c(this.m_shape,s,this.m_progressTracker)){if(G(this.m_shape,t.add(g),this.m_progressTracker,0===this.m_options,this.m_bOutputOnlyModified),null!==m){if(this.m_bSimplifyPolygons){for(let e=this.m_shape.getFirstGeometry();e!==o;e=this.m_shape.getNextGeometry(e))if(this.m_shape.getGeometryType(e)===i.enumPolygon){n(this.m_shape,e,-1,!1,o,this.m_progressTracker)&&this.m_shape.setGeometryModified(e,!0)}this.m_bSimplifyPolygons=!1}m.stitchCurves(this.m_shape,o,h,!0),m.clearStitcher(this.m_shape)}}else this.m_bSimplifyPolygons=!1,null!==m&&(m.stitchCurves(this.m_shape,o,h,!0),m.clearStitcher(this.m_shape));this.moveToNextGeom()}if(this.m_currentGeom!==o){if(this.m_index=this.m_shape.getGeometryUserIndex(this.m_currentGeom,this.m_geomIndex),-1!==this.m_geomTypeIndex&&this.m_shape.getGeometryUserIndex(this.m_currentGeom,this.m_geomTypeIndex)===i.enumPoint){const e=new g({vd:this.m_shape.getVertexDescription()});return this.m_shape.queryPointGeometryOnly(this.m_currentGeom,e),this.m_bSnapToSr&&_(this.m_sr,e),e}{const e=this.m_shape.getGeometry(this.m_currentGeom);return this.m_bSnapToSr&&_(this.m_sr,e),e}}return null}getGeometryID(){return this.m_index}}const S=new x;function b(e,s,i){const r=S.executeMany(new t(e),s,null,i);return Array.from(r)}function I(){return S.supportsCurves()}export{b as executeMany,I as supportsCurves};
5
+ import{G as e,S as t}from"../../../chunks/SimpleGeometryCursor.js";import{o as s,G as i,a as r}from"../../../chunks/Geometry.js";import{k as m,o,aP as h,aQ as n,v as a,aR as _,j as p,l as u,s as l,m as y,aS as c,aT as G,P as g,C as d,aU as f}from"../../../chunks/QuadraticBezier.js";class x{getOperatorType(){return 10009}supportsCurves(){return!0}accelerateGeometry(e,t,s){return!1}canAccelerateGeometry(e){return!1}executeMany(e,t,s,i=0){return new T(e,t,s,i)}}class T extends e{constructor(e,t,i,r){super(),this.m_shape=new m,this.m_currentGeom=o,this.m_progressCounter=0,this.m_geomIndex=-1,this.m_geomTypeIndex=-1,this.m_index=-1,this.m_bBuilt=!1,this.m_bOutputOnlyModified=!1,this.m_bSimplifyPolygons=!1,this.m_bSnapToSr=!1,this.m_progressTracker=i,this.m_inputGeometries=e,this.m_sr=t,this.m_options=r,1===r||2===r?(this.m_bOutputOnlyModified=!0,this.m_options=0,this.m_bSimplifyPolygons=!0,this.m_bSnapToSr=null!=t&&2===r,this.m_bSnapToSr&&!h()&&s("PE is required for snapping to spatial reference operation")):0===r&&(this.m_bSimplifyPolygons=!0)}progress_(e=!1){}tock(){return!0}getRank(){return 1}moveToNextGeom(){for(;;){if(this.m_bBuilt?this.m_currentGeom=this.m_shape.getNextGeometry(this.m_currentGeom):(this.m_currentGeom=this.m_shape.getFirstGeometry(),this.m_bBuilt=!0),this.m_currentGeom!==o){let e=!1;if(this.m_bSimplifyPolygons&&this.m_shape.getGeometryType(this.m_currentGeom)===i.enumPolygon&&(e=n(this.m_shape,this.m_currentGeom,-1,!1,o,this.m_progressTracker)),this.m_bOutputOnlyModified&&!e&&!this.m_shape.getGeometryModified(this.m_currentGeom))continue}break}}next(){if(this.m_bBuilt)this.moveToNextGeom();else{this.m_geomIndex=this.m_shape.createGeometryUserIndex();const e=new a;for(let o=this.m_inputGeometries.next();null!=o;o=this.m_inputGeometries.next()){this.progress_(),r(o);let t=!1;this.m_bSnapToSr&&(o=o.clone(),t=_(this.m_sr,o));const s=this.m_shape.addGeometry(o);this.m_shape.setGeometryUserIndex(s,this.m_geomIndex,this.m_inputGeometries.getGeometryID());const m=o.getGeometryType();m===i.enumPoint&&(-1===this.m_geomTypeIndex&&(this.m_geomTypeIndex=this.m_shape.createGeometryUserIndex()),this.m_shape.setGeometryUserIndex(s,this.m_geomTypeIndex,m));const h=new a;o.queryLooseEnvelope(h),e.mergeEnvelope2D(h),t&&this.m_shape.setGeometryModified(s,!0)}const t=p(this.m_sr,e,!0),s=p(this.m_sr,e,!1);e.inflate(10*t.total()),this.m_shape.forceSetEnvelope2D(e);let m=null,h=0,g=0;if(this.m_shape.hasCurves()){m=new d;const s=u(t.total(),e);h=l(t.total()),g=f(s,h),y(this.m_shape,s,t.total(),12e3,m,null,this.m_progressTracker)}if(c(this.m_shape,s,this.m_progressTracker)){if(G(this.m_shape,t.add(g),this.m_progressTracker,0===this.m_options,this.m_bOutputOnlyModified),null!==m){if(this.m_bSimplifyPolygons){for(let e=this.m_shape.getFirstGeometry();e!==o;e=this.m_shape.getNextGeometry(e))if(this.m_shape.getGeometryType(e)===i.enumPolygon){n(this.m_shape,e,-1,!1,o,this.m_progressTracker)&&this.m_shape.setGeometryModified(e,!0)}this.m_bSimplifyPolygons=!1}m.stitchCurves(this.m_shape,o,h,!0),m.clearStitcher(this.m_shape)}}else this.m_bSimplifyPolygons=!1,null!==m&&(m.stitchCurves(this.m_shape,o,h,!0),m.clearStitcher(this.m_shape));this.moveToNextGeom()}if(this.m_currentGeom!==o){if(this.m_index=this.m_shape.getGeometryUserIndex(this.m_currentGeom,this.m_geomIndex),-1!==this.m_geomTypeIndex&&this.m_shape.getGeometryUserIndex(this.m_currentGeom,this.m_geomTypeIndex)===i.enumPoint){const e=new g({vd:this.m_shape.getVertexDescription()});return this.m_shape.queryPointGeometryOnly(this.m_currentGeom,e),this.m_bSnapToSr&&_(this.m_sr,e),e}{const e=this.m_shape.getGeometry(this.m_currentGeom);return this.m_bSnapToSr&&_(this.m_sr,e),e}}return null}getGeometryID(){return this.m_index}}const S=new x;function b(e,s,i){const r=S.executeMany(new t(e),s,null,i);return Array.from(r)}function I(){return S.supportsCurves()}export{b as executeMany,I as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{S as e}from"../../../chunks/SimpleGeometryCursor.js";import"../../../chunks/Geometry.js";import{v as r}from"../../../chunks/QuadraticBezier.js";const n=new r;function t(e,r){return n.accelerateGeometry(e,r,0)}function u(e,r,t){return n.execute(e,r,t,null)}function o(r,t,u,o){const c=n.executeMany(new e(r),new e([t]),u,null,o);return Array.from(c)}function c(){return n.supportsCurves()}export{t as accelerateGeometry,u as execute,o as executeMany,c as supportsCurves};
5
+ import{S as e}from"../../../chunks/SimpleGeometryCursor.js";import"../../../chunks/Geometry.js";import{x as r}from"../../../chunks/QuadraticBezier.js";const n=new r;function t(e,r){return n.accelerateGeometry(e,r,0)}function u(e,r,t){return n.execute(e,r,t,null)}function o(r,t,u,o){const c=n.executeMany(new e(r),new e([t]),u,null,o);return Array.from(c)}function c(){return n.supportsCurves()}export{t as accelerateGeometry,u as execute,o as executeMany,c as supportsCurves};
@@ -2,4 +2,4 @@
2
2
  All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  See https://js.arcgis.com/4.32/esri/copyright.txt for details.
4
4
  */
5
- import{G as e,S as t}from"../../../chunks/SimpleGeometryCursor.js";import{g as n,a as r,t as o,G as s}from"../../../chunks/Geometry.js";import{P as a,t as i,h as l,a as u,aV as c,q as m,L as N}from"../../../chunks/QuadraticBezier.js";import{P as g,l as y,o as h,d as P}from"../../../chunks/Transformation2D.js";import{a as d}from"../../../chunks/Centroid-DZi-eb9F.js";import{O as x}from"../../../chunks/OperatorProximity.js";class f{getOperatorType(){return 10203}accelerateGeometry(e,t,n){return!1}canAccelerateGeometry(e){return!1}supportsCurves(){return!0}executeMany(e,t){return new p(e,t)}execute(e,t){return new p(null,t).labelPoint(e)}}class p extends e{progress_(){}tock(){return n(0),!1}getRank(){return n(0),0}constructor(e,t){super(),this.m_index=-1,this.m_progressCounter=0,this.m_progressTracker=t,this.m_inputGeoms=e}next(){const e=this.m_inputGeoms.next();return e?(r(e),this.m_index=this.m_inputGeoms.getGeometryID(),this.labelPoint(e)):null}getGeometryID(){return this.m_index}labelPoint(e){if(null===e&&o("null pointer is not allowed"),e.getGeometryType()===s.enumPoint)return e;if(e.isEmpty())return new a({vd:e.getDescription()});switch(e.getGeometryType()){case s.enumPolygon:return this.labelPointPolygon(e);case s.enumPolyline:return this.labelPointPolyline(e);case s.enumMultiPoint:return this.labelPointMultiPoint(e);case s.enumEnvelope:return this.labelPointEnvelope(e);default:o("geometry is not supported")}}labelPointPolygon(e){const t=new i;e.queryEnvelope(t);const r=l(null,t,!0).total();let o=null,s=e;if(e.hasNonLinearSegments()){const t=new u({copy:e}),a=c(t,.25*r,r);n(a!==e),o=a,s=o}let N=0,P=0;for(let n=0,a=s.getPathCount();n<a;++n){const e=Math.abs(s.calculateRingArea2D(n));e>P&&(P=e,N=n)}const f=new g;if(Math.abs(P)<=2*r*r?f.setNAN():f.assign(d(s,N)),Number.isNaN(f.x)){const e=new i;return s.queryPathEnvelope(N,e),new a({pt:e.getCenter()})}if(s.getPointCount()<4)return new a({x:f.x,y:f.y});const p=g.getNAN(),w=[p.clone(),p.clone(),p.clone(),p.clone()],b=[Number.NaN,Number.NaN,Number.NaN,Number.NaN],C=[Number.NaN,Number.NaN,Number.NaN,Number.NaN];let _=!1,D=(new x).getNearestCoordinate(s,f,!0,!1);if(0===D.m_distance&&(_=!0,w[0]=f,D=(new x).getNearestCoordinate(s,f,!1,!1),D.m_distance>.25*t.minDimension()*1.66666666))return new a({x:f.x,y:f.y});b[0]=D.m_distance,C[0]=0;const A=new g;let E=!1,k=.25,q=-1;const G=new i;s.queryPathEnvelope(N,G);do{let e=Number.NaN;if(w[1]=this.calculateParacentroid_(s,y(G.xmin,G.xmax,k),r),w[1].isNAN()||(D=(new x).getNearestCoordinate(s,w[1],!1,!1),e=D.m_distance),e>r&&1===m(s,w[1],r))E=!0,b[1]=e,C[1]=g.sqrDistance(w[1],f);else if(e>q&&(q=e,A.setCoordsPoint2D(w[1])),k-=.01,k<.1){if(!(q>=0))break;E=!0,b[1]=q,w[1]=A,C[1]=g.sqrDistance(w[1],f)}}while(!E);E=!1,k=.5,q=-1;let M=.01,S=1;do{let e=Number.NaN;if(w[2]=this.calculateParacentroid_(s,y(G.xmin,G.xmax,k),r),w[2].isNAN()||(D=(new x).getNearestCoordinate(s,w[2],!1,!1),e=D.m_distance),e>r&&1===m(s,w[2],r))E=!0,b[2]=e,C[2]=g.sqrDistance(w[2],f);else if(e>q&&(q=e,A.setCoordsPoint2D(w[2])),k=.5+M*S,M+=.01,S*=-1,k<.3||k>.7){if(!(q>=0))break;E=!0,b[2]=q,w[2]=A,C[2]=g.sqrDistance(w[2],f)}}while(!E);E=!1,k=.75,q=-1;do{let e=Number.NaN;if(w[3]=this.calculateParacentroid_(s,y(G.xmin,G.xmax,k),r),w[3].isNAN()||(D=(new x).getNearestCoordinate(s,w[3],!1,!1),e=D.m_distance),e>r&&1===m(s,w[3],r))E=!0,b[3]=e,C[3]=g.sqrDistance(w[3],f);else if(e>q&&(q=e,A.setCoordsPoint2D(w[3])),k+=.01,k>.9){if(!(q>=0))break;E=!0,b[3]=q,w[3]=A,C[3]=g.sqrDistance(w[3],f)}}while(!E);const v=[0,1,2,3],X=_?0:1;for(let n=X;n<4;n++)for(let e=X;e<3;e++){const t=C[e],n=C[e+1];if(h(t,n)>0){const r=v[e];v[e]=v[e+1],v[e+1]=r,C[e]=n,C[e+1]=t}}let L=X,T=0,j=0;for(let n=X;n<4;n++){switch(n){case 0:j=2*b[v[n]];break;case 1:j=1.66666666*b[v[n]];break;case 2:j=1.33333333*b[v[n]];break;case 3:j=b[v[n]]}j>T&&(T=j,L=v[n])}return n(!w[L].isNAN()),new a({x:w[L].x,y:w[L].y})}labelPointPolyline(e){const t=new g;if(e.getPointCount()>2*e.getPathCount()){let n=-1,r=-Number.MAX_VALUE;for(let t=0,i=e.getPathCount();t<i;t++)if(e.getPathSize(t)>2){const o=e.calculatePathLength2D(t);o>r&&(r=o,n=t)}const o=e.getPathStart(n),s=e.getPathEnd(n),a=Math.trunc((o+s)/2);t.assign(e.getXY(a))}else{let n=-Number.MAX_VALUE;const r=e.querySegmentIterator();for(;r.nextPath();)if(r.hasNextSegment()){const e=r.nextSegment(),o=e.calculateLength2D();o>n&&(n=o,t.assign(e.getCoord2D(e.lengthToT(.5*o))))}}return new a({x:t.x,y:t.y})}labelPointMultiPoint(e){const t=new i;e.queryEnvelope(t);const n=t.getCenter(),r=(new x).getNearestCoordinate(e,n,!1,!1).m_coordinate;return new a({x:r.x,y:r.y})}labelPointEnvelope(e){const t=e.getCenterXY();return new a({x:t.x,y:t.y})}calculateParacentroid_(e,t,r){const o=new i;e.queryEnvelope(o);const s=new g(t,0);let a=Number.MAX_VALUE,l=Number.MAX_VALUE,u=!1,c=!1;const m=new N;m.setStartXYCoords(s.x,o.ymin-1),m.setEndXYCoords(s.x,o.ymax+1);const y=new i,h=new g,d=new g,x=P(g,2),f=e.querySegmentIterator();for(;f.nextPath();)for(;f.hasNextSegment();){const e=f.nextSegment();if(e.queryEnvelope(y),n(e.isMonotoneQuickAndDirty()),h.setCoordsPoint2D(m.getStartXY()),d.setCoordsPoint2D(m.getEndXY()),0===y.clipLine(h,d))continue;if(1!==m.intersect(e,x,null,null,r))continue;const t=x[0].y;a>l?t<a&&(a=t,u=!0):t<l&&(l=t,c=!0)}return u&&c?s.y=(a+l)/2:s.setNAN(),s}}const w=new f;function b(e){return w.execute(e,null)}function C(e){const n=w.executeMany(new t(e),null);return Array.from(n)}function _(){return w.supportsCurves()}export{b as execute,C as executeMany,_ as supportsCurves};
5
+ import{G as e,S as t}from"../../../chunks/SimpleGeometryCursor.js";import{g as n,a as r,t as o,G as s}from"../../../chunks/Geometry.js";import{P as a,v as i,j as l,a as u,aV as c,t as m,L as N}from"../../../chunks/QuadraticBezier.js";import{P as g,l as y,o as h,d as P}from"../../../chunks/Transformation2D.js";import{a as d}from"../../../chunks/Centroid-DZi-eb9F.js";import{O as x}from"../../../chunks/OperatorProximity.js";class f{getOperatorType(){return 10203}accelerateGeometry(e,t,n){return!1}canAccelerateGeometry(e){return!1}supportsCurves(){return!0}executeMany(e,t){return new p(e,t)}execute(e,t){return new p(null,t).labelPoint(e)}}class p extends e{progress_(){}tock(){return n(0),!1}getRank(){return n(0),0}constructor(e,t){super(),this.m_index=-1,this.m_progressCounter=0,this.m_progressTracker=t,this.m_inputGeoms=e}next(){const e=this.m_inputGeoms.next();return e?(r(e),this.m_index=this.m_inputGeoms.getGeometryID(),this.labelPoint(e)):null}getGeometryID(){return this.m_index}labelPoint(e){if(null===e&&o("null pointer is not allowed"),e.getGeometryType()===s.enumPoint)return e;if(e.isEmpty())return new a({vd:e.getDescription()});switch(e.getGeometryType()){case s.enumPolygon:return this.labelPointPolygon(e);case s.enumPolyline:return this.labelPointPolyline(e);case s.enumMultiPoint:return this.labelPointMultiPoint(e);case s.enumEnvelope:return this.labelPointEnvelope(e);default:o("geometry is not supported")}}labelPointPolygon(e){const t=new i;e.queryEnvelope(t);const r=l(null,t,!0).total();let o=null,s=e;if(e.hasNonLinearSegments()){const t=new u({copy:e}),a=c(t,.25*r,r);n(a!==e),o=a,s=o}let N=0,P=0;for(let n=0,a=s.getPathCount();n<a;++n){const e=Math.abs(s.calculateRingArea2D(n));e>P&&(P=e,N=n)}const f=new g;if(Math.abs(P)<=2*r*r?f.setNAN():f.assign(d(s,N)),Number.isNaN(f.x)){const e=new i;return s.queryPathEnvelope(N,e),new a({pt:e.getCenter()})}if(s.getPointCount()<4)return new a({x:f.x,y:f.y});const p=g.getNAN(),w=[p.clone(),p.clone(),p.clone(),p.clone()],b=[Number.NaN,Number.NaN,Number.NaN,Number.NaN],C=[Number.NaN,Number.NaN,Number.NaN,Number.NaN];let _=!1,D=(new x).getNearestCoordinate(s,f,!0,!1);if(0===D.m_distance&&(_=!0,w[0]=f,D=(new x).getNearestCoordinate(s,f,!1,!1),D.m_distance>.25*t.minDimension()*1.66666666))return new a({x:f.x,y:f.y});b[0]=D.m_distance,C[0]=0;const A=new g;let E=!1,k=.25,q=-1;const v=new i;s.queryPathEnvelope(N,v);do{let e=Number.NaN;if(w[1]=this.calculateParacentroid_(s,y(v.xmin,v.xmax,k),r),w[1].isNAN()||(D=(new x).getNearestCoordinate(s,w[1],!1,!1),e=D.m_distance),e>r&&1===m(s,w[1],r))E=!0,b[1]=e,C[1]=g.sqrDistance(w[1],f);else if(e>q&&(q=e,A.setCoordsPoint2D(w[1])),k-=.01,k<.1){if(!(q>=0))break;E=!0,b[1]=q,w[1]=A,C[1]=g.sqrDistance(w[1],f)}}while(!E);E=!1,k=.5,q=-1;let G=.01,M=1;do{let e=Number.NaN;if(w[2]=this.calculateParacentroid_(s,y(v.xmin,v.xmax,k),r),w[2].isNAN()||(D=(new x).getNearestCoordinate(s,w[2],!1,!1),e=D.m_distance),e>r&&1===m(s,w[2],r))E=!0,b[2]=e,C[2]=g.sqrDistance(w[2],f);else if(e>q&&(q=e,A.setCoordsPoint2D(w[2])),k=.5+G*M,G+=.01,M*=-1,k<.3||k>.7){if(!(q>=0))break;E=!0,b[2]=q,w[2]=A,C[2]=g.sqrDistance(w[2],f)}}while(!E);E=!1,k=.75,q=-1;do{let e=Number.NaN;if(w[3]=this.calculateParacentroid_(s,y(v.xmin,v.xmax,k),r),w[3].isNAN()||(D=(new x).getNearestCoordinate(s,w[3],!1,!1),e=D.m_distance),e>r&&1===m(s,w[3],r))E=!0,b[3]=e,C[3]=g.sqrDistance(w[3],f);else if(e>q&&(q=e,A.setCoordsPoint2D(w[3])),k+=.01,k>.9){if(!(q>=0))break;E=!0,b[3]=q,w[3]=A,C[3]=g.sqrDistance(w[3],f)}}while(!E);const S=[0,1,2,3],X=_?0:1;for(let n=X;n<4;n++)for(let e=X;e<3;e++){const t=C[e],n=C[e+1];if(h(t,n)>0){const r=S[e];S[e]=S[e+1],S[e+1]=r,C[e]=n,C[e+1]=t}}let L=X,j=0,T=0;for(let n=X;n<4;n++){switch(n){case 0:T=2*b[S[n]];break;case 1:T=1.66666666*b[S[n]];break;case 2:T=1.33333333*b[S[n]];break;case 3:T=b[S[n]]}T>j&&(j=T,L=S[n])}return n(!w[L].isNAN()),new a({x:w[L].x,y:w[L].y})}labelPointPolyline(e){const t=new g;if(e.getPointCount()>2*e.getPathCount()){let n=-1,r=-Number.MAX_VALUE;for(let t=0,i=e.getPathCount();t<i;t++)if(e.getPathSize(t)>2){const o=e.calculatePathLength2D(t);o>r&&(r=o,n=t)}const o=e.getPathStart(n),s=e.getPathEnd(n),a=Math.trunc((o+s)/2);t.assign(e.getXY(a))}else{let n=-Number.MAX_VALUE;const r=e.querySegmentIterator();for(;r.nextPath();)if(r.hasNextSegment()){const e=r.nextSegment(),o=e.calculateLength2D();o>n&&(n=o,t.assign(e.getCoord2D(e.lengthToT(.5*o))))}}return new a({x:t.x,y:t.y})}labelPointMultiPoint(e){const t=new i;e.queryEnvelope(t);const n=t.getCenter(),r=(new x).getNearestCoordinate(e,n,!1,!1).m_coordinate;return new a({x:r.x,y:r.y})}labelPointEnvelope(e){const t=e.getCenterXY();return new a({x:t.x,y:t.y})}calculateParacentroid_(e,t,r){const o=new i;e.queryEnvelope(o);const s=new g(t,0);let a=Number.MAX_VALUE,l=Number.MAX_VALUE,u=!1,c=!1;const m=new N;m.setStartXYCoords(s.x,o.ymin-1),m.setEndXYCoords(s.x,o.ymax+1);const y=new i,h=new g,d=new g,x=P(g,2),f=e.querySegmentIterator();for(;f.nextPath();)for(;f.hasNextSegment();){const e=f.nextSegment();if(e.queryEnvelope(y),n(e.isMonotoneQuickAndDirty()),h.setCoordsPoint2D(m.getStartXY()),d.setCoordsPoint2D(m.getEndXY()),0===y.clipLine(h,d))continue;if(1!==m.intersect(e,x,null,null,r))continue;const t=x[0].y;a>l?t<a&&(a=t,u=!0):t<l&&(l=t,c=!0)}return u&&c?s.y=(a+l)/2:s.setNAN(),s}}const w=new f;function b(e){return w.execute(e,null)}function C(e){const n=w.executeMany(new t(e),null);return Array.from(n)}function _(){return w.supportsCurves()}export{b as execute,C as executeMany,_ as supportsCurves};