@itwin/core-geometry 5.2.0-dev.29 → 5.2.0-dev.30

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 (737) hide show
  1. package/lib/cjs/Constant.js.map +1 -1
  2. package/lib/cjs/Geometry.d.ts +30 -10
  3. package/lib/cjs/Geometry.d.ts.map +1 -1
  4. package/lib/cjs/Geometry.js +74 -10
  5. package/lib/cjs/Geometry.js.map +1 -1
  6. package/lib/cjs/bspline/AkimaCurve3d.d.ts +19 -6
  7. package/lib/cjs/bspline/AkimaCurve3d.d.ts.map +1 -1
  8. package/lib/cjs/bspline/AkimaCurve3d.js +21 -5
  9. package/lib/cjs/bspline/AkimaCurve3d.js.map +1 -1
  10. package/lib/cjs/bspline/BSpline1dNd.js.map +1 -1
  11. package/lib/cjs/bspline/BSplineCurve.d.ts +3 -3
  12. package/lib/cjs/bspline/BSplineCurve.d.ts.map +1 -1
  13. package/lib/cjs/bspline/BSplineCurve.js +6 -6
  14. package/lib/cjs/bspline/BSplineCurve.js.map +1 -1
  15. package/lib/cjs/bspline/BSplineCurve3dH.js.map +1 -1
  16. package/lib/cjs/bspline/BSplineCurveOps.d.ts.map +1 -1
  17. package/lib/cjs/bspline/BSplineCurveOps.js +1 -1
  18. package/lib/cjs/bspline/BSplineCurveOps.js.map +1 -1
  19. package/lib/cjs/bspline/BSplineSurface.js.map +1 -1
  20. package/lib/cjs/bspline/Bezier1dNd.js.map +1 -1
  21. package/lib/cjs/bspline/BezierCurve3d.js.map +1 -1
  22. package/lib/cjs/bspline/BezierCurve3dH.js.map +1 -1
  23. package/lib/cjs/bspline/BezierCurveBase.d.ts +2 -2
  24. package/lib/cjs/bspline/BezierCurveBase.d.ts.map +1 -1
  25. package/lib/cjs/bspline/BezierCurveBase.js +4 -6
  26. package/lib/cjs/bspline/BezierCurveBase.js.map +1 -1
  27. package/lib/cjs/bspline/InterpolationCurve3d.d.ts +27 -17
  28. package/lib/cjs/bspline/InterpolationCurve3d.d.ts.map +1 -1
  29. package/lib/cjs/bspline/InterpolationCurve3d.js +17 -7
  30. package/lib/cjs/bspline/InterpolationCurve3d.js.map +1 -1
  31. package/lib/cjs/bspline/KnotVector.js.map +1 -1
  32. package/lib/cjs/bspline/SurfaceLocationDetail.js.map +1 -1
  33. package/lib/cjs/clipping/AlternatingConvexClipTree.js.map +1 -1
  34. package/lib/cjs/clipping/BooleanClipFactory.js.map +1 -1
  35. package/lib/cjs/clipping/BooleanClipNode.js.map +1 -1
  36. package/lib/cjs/clipping/ClipPlane.d.ts +9 -3
  37. package/lib/cjs/clipping/ClipPlane.d.ts.map +1 -1
  38. package/lib/cjs/clipping/ClipPlane.js +8 -0
  39. package/lib/cjs/clipping/ClipPlane.js.map +1 -1
  40. package/lib/cjs/clipping/ClipPrimitive.js.map +1 -1
  41. package/lib/cjs/clipping/ClipUtils.d.ts +14 -1
  42. package/lib/cjs/clipping/ClipUtils.d.ts.map +1 -1
  43. package/lib/cjs/clipping/ClipUtils.js +21 -3
  44. package/lib/cjs/clipping/ClipUtils.js.map +1 -1
  45. package/lib/cjs/clipping/ClipVector.js.map +1 -1
  46. package/lib/cjs/clipping/ConvexClipPlaneSet.d.ts +2 -2
  47. package/lib/cjs/clipping/ConvexClipPlaneSet.d.ts.map +1 -1
  48. package/lib/cjs/clipping/ConvexClipPlaneSet.js +6 -4
  49. package/lib/cjs/clipping/ConvexClipPlaneSet.js.map +1 -1
  50. package/lib/cjs/clipping/UnionOfConvexClipPlaneSets.js.map +1 -1
  51. package/lib/cjs/clipping/internalContexts/LineStringOffsetClipperContext.js.map +1 -1
  52. package/lib/cjs/core-geometry.js.map +1 -1
  53. package/lib/cjs/curve/Arc3d.d.ts +27 -17
  54. package/lib/cjs/curve/Arc3d.d.ts.map +1 -1
  55. package/lib/cjs/curve/Arc3d.js +61 -35
  56. package/lib/cjs/curve/Arc3d.js.map +1 -1
  57. package/lib/cjs/curve/ConstructCurveBetweenCurves.js.map +1 -1
  58. package/lib/cjs/curve/CoordinateXYZ.js.map +1 -1
  59. package/lib/cjs/curve/CurveChainWithDistanceIndex.js.map +1 -1
  60. package/lib/cjs/curve/CurveCollection.d.ts +1 -0
  61. package/lib/cjs/curve/CurveCollection.d.ts.map +1 -1
  62. package/lib/cjs/curve/CurveCollection.js +1 -0
  63. package/lib/cjs/curve/CurveCollection.js.map +1 -1
  64. package/lib/cjs/curve/CurveCurve.js.map +1 -1
  65. package/lib/cjs/curve/CurveExtendMode.js.map +1 -1
  66. package/lib/cjs/curve/CurveFactory.js.map +1 -1
  67. package/lib/cjs/curve/CurveLocationDetail.d.ts +8 -7
  68. package/lib/cjs/curve/CurveLocationDetail.d.ts.map +1 -1
  69. package/lib/cjs/curve/CurveLocationDetail.js.map +1 -1
  70. package/lib/cjs/curve/CurveOps.d.ts +51 -1
  71. package/lib/cjs/curve/CurveOps.d.ts.map +1 -1
  72. package/lib/cjs/curve/CurveOps.js +97 -3
  73. package/lib/cjs/curve/CurveOps.js.map +1 -1
  74. package/lib/cjs/curve/CurvePrimitive.js.map +1 -1
  75. package/lib/cjs/curve/CurveProcessor.js.map +1 -1
  76. package/lib/cjs/curve/CurveTypes.js.map +1 -1
  77. package/lib/cjs/curve/CurveWireMomentsXYZ.js.map +1 -1
  78. package/lib/cjs/curve/GeometryQuery.js.map +1 -1
  79. package/lib/cjs/curve/LineSegment3d.js.map +1 -1
  80. package/lib/cjs/curve/LineString3d.d.ts +4 -4
  81. package/lib/cjs/curve/LineString3d.d.ts.map +1 -1
  82. package/lib/cjs/curve/LineString3d.js +8 -8
  83. package/lib/cjs/curve/LineString3d.js.map +1 -1
  84. package/lib/cjs/curve/Loop.js.map +1 -1
  85. package/lib/cjs/curve/OffsetOptions.js.map +1 -1
  86. package/lib/cjs/curve/ParityRegion.js.map +1 -1
  87. package/lib/cjs/curve/Path.js.map +1 -1
  88. package/lib/cjs/curve/PointString3d.js.map +1 -1
  89. package/lib/cjs/curve/ProxyCurve.js.map +1 -1
  90. package/lib/cjs/curve/Query/ConsolidateAdjacentPrimitivesContext.js +3 -3
  91. package/lib/cjs/curve/Query/ConsolidateAdjacentPrimitivesContext.js.map +1 -1
  92. package/lib/cjs/curve/Query/CurveSplitContext.js.map +1 -1
  93. package/lib/cjs/curve/Query/CylindricalRange.js.map +1 -1
  94. package/lib/cjs/curve/Query/InOutTests.js.map +1 -1
  95. package/lib/cjs/curve/Query/PlanarSubdivision.d.ts +6 -2
  96. package/lib/cjs/curve/Query/PlanarSubdivision.d.ts.map +1 -1
  97. package/lib/cjs/curve/Query/PlanarSubdivision.js +12 -7
  98. package/lib/cjs/curve/Query/PlanarSubdivision.js.map +1 -1
  99. package/lib/cjs/curve/Query/StrokeCountChain.js.map +1 -1
  100. package/lib/cjs/curve/Query/StrokeCountMap.js.map +1 -1
  101. package/lib/cjs/curve/RegionMomentsXY.js.map +1 -1
  102. package/lib/cjs/curve/RegionOps.d.ts +9 -4
  103. package/lib/cjs/curve/RegionOps.d.ts.map +1 -1
  104. package/lib/cjs/curve/RegionOps.js +10 -5
  105. package/lib/cjs/curve/RegionOps.js.map +1 -1
  106. package/lib/cjs/curve/RegionOpsClassificationSweeps.js.map +1 -1
  107. package/lib/cjs/curve/StrokeOptions.js.map +1 -1
  108. package/lib/cjs/curve/UnionRegion.js.map +1 -1
  109. package/lib/cjs/curve/internalContexts/AnnounceTangentStrokeHandler.js.map +1 -1
  110. package/lib/cjs/curve/internalContexts/AppendPlaneIntersectionStrokeHandler.js.map +1 -1
  111. package/lib/cjs/curve/internalContexts/ChainCollectorContext.js.map +1 -1
  112. package/lib/cjs/curve/internalContexts/CloneCurvesContext.js.map +1 -1
  113. package/lib/cjs/curve/internalContexts/CloneWithExpandedLineStrings.js.map +1 -1
  114. package/lib/cjs/curve/internalContexts/ClosestPointStrokeHandler.js.map +1 -1
  115. package/lib/cjs/curve/internalContexts/CountLinearPartsSearchContext.js.map +1 -1
  116. package/lib/cjs/curve/internalContexts/CurveCurveCloseApproachXY.js.map +1 -1
  117. package/lib/cjs/curve/internalContexts/CurveCurveIntersectXY.d.ts.map +1 -1
  118. package/lib/cjs/curve/internalContexts/CurveCurveIntersectXY.js +2 -1
  119. package/lib/cjs/curve/internalContexts/CurveCurveIntersectXY.js.map +1 -1
  120. package/lib/cjs/curve/internalContexts/CurveCurveIntersectXYZ.js.map +1 -1
  121. package/lib/cjs/curve/internalContexts/CurveLengthContext.js.map +1 -1
  122. package/lib/cjs/curve/internalContexts/CurveOffsetXYHandler.js.map +1 -1
  123. package/lib/cjs/curve/internalContexts/EllipticalArcApproximationContext.js.map +1 -1
  124. package/lib/cjs/curve/internalContexts/GapSearchContext.js.map +1 -1
  125. package/lib/cjs/curve/internalContexts/MultiChainCollector.d.ts +4 -4
  126. package/lib/cjs/curve/internalContexts/MultiChainCollector.d.ts.map +1 -1
  127. package/lib/cjs/curve/internalContexts/MultiChainCollector.js +21 -18
  128. package/lib/cjs/curve/internalContexts/MultiChainCollector.js.map +1 -1
  129. package/lib/cjs/curve/internalContexts/NewtonRtoRStrokeHandler.js.map +1 -1
  130. package/lib/cjs/curve/internalContexts/PlaneAltitudeRangeContext.js.map +1 -1
  131. package/lib/cjs/curve/internalContexts/PolygonOffsetContext.js.map +1 -1
  132. package/lib/cjs/curve/internalContexts/SumLengthsContext.js.map +1 -1
  133. package/lib/cjs/curve/internalContexts/TransferWithSplitArcs.js.map +1 -1
  134. package/lib/cjs/curve/internalContexts/TransformInPlaceContext.js.map +1 -1
  135. package/lib/cjs/curve/spiral/AustralianRailCorpXYEvaluator.js.map +1 -1
  136. package/lib/cjs/curve/spiral/ClothoidSeries.js.map +1 -1
  137. package/lib/cjs/curve/spiral/CubicEvaluator.js.map +1 -1
  138. package/lib/cjs/curve/spiral/CzechSpiralEvaluator.js.map +1 -1
  139. package/lib/cjs/curve/spiral/DirectHalfCosineSpiralEvaluator.js.map +1 -1
  140. package/lib/cjs/curve/spiral/DirectSpiral3d.d.ts +2 -2
  141. package/lib/cjs/curve/spiral/DirectSpiral3d.d.ts.map +1 -1
  142. package/lib/cjs/curve/spiral/DirectSpiral3d.js +6 -2
  143. package/lib/cjs/curve/spiral/DirectSpiral3d.js.map +1 -1
  144. package/lib/cjs/curve/spiral/IntegratedSpiral3d.d.ts +2 -2
  145. package/lib/cjs/curve/spiral/IntegratedSpiral3d.d.ts.map +1 -1
  146. package/lib/cjs/curve/spiral/IntegratedSpiral3d.js +6 -2
  147. package/lib/cjs/curve/spiral/IntegratedSpiral3d.js.map +1 -1
  148. package/lib/cjs/curve/spiral/MXCubicAlongArcSpiralEvaluator.js.map +1 -1
  149. package/lib/cjs/curve/spiral/NormalizedTransition.js.map +1 -1
  150. package/lib/cjs/curve/spiral/PolishCubicSpiralEvaluator.js.map +1 -1
  151. package/lib/cjs/curve/spiral/TransitionConditionalProperties.js.map +1 -1
  152. package/lib/cjs/curve/spiral/TransitionSpiral3d.d.ts +5 -1
  153. package/lib/cjs/curve/spiral/TransitionSpiral3d.d.ts.map +1 -1
  154. package/lib/cjs/curve/spiral/TransitionSpiral3d.js +0 -3
  155. package/lib/cjs/curve/spiral/TransitionSpiral3d.js.map +1 -1
  156. package/lib/cjs/curve/spiral/XYCurveEvaluator.js.map +1 -1
  157. package/lib/cjs/geometry3d/Angle.js.map +1 -1
  158. package/lib/cjs/geometry3d/AngleSweep.d.ts +6 -2
  159. package/lib/cjs/geometry3d/AngleSweep.d.ts.map +1 -1
  160. package/lib/cjs/geometry3d/AngleSweep.js +12 -3
  161. package/lib/cjs/geometry3d/AngleSweep.js.map +1 -1
  162. package/lib/cjs/geometry3d/BarycentricTriangle.js.map +1 -1
  163. package/lib/cjs/geometry3d/BilinearPatch.js.map +1 -1
  164. package/lib/cjs/geometry3d/CoincidentGeometryOps.js.map +1 -1
  165. package/lib/cjs/geometry3d/Ellipsoid.js.map +1 -1
  166. package/lib/cjs/geometry3d/FrameBuilder.d.ts +2 -1
  167. package/lib/cjs/geometry3d/FrameBuilder.d.ts.map +1 -1
  168. package/lib/cjs/geometry3d/FrameBuilder.js +14 -18
  169. package/lib/cjs/geometry3d/FrameBuilder.js.map +1 -1
  170. package/lib/cjs/geometry3d/FrustumAnimation.js.map +1 -1
  171. package/lib/cjs/geometry3d/GeometryHandler.js.map +1 -1
  172. package/lib/cjs/geometry3d/GrowableBlockedArray.js.map +1 -1
  173. package/lib/cjs/geometry3d/GrowableFloat64Array.js.map +1 -1
  174. package/lib/cjs/geometry3d/GrowableXYArray.js.map +1 -1
  175. package/lib/cjs/geometry3d/GrowableXYZArray.js.map +1 -1
  176. package/lib/cjs/geometry3d/IndexedCollectionInterval.js.map +1 -1
  177. package/lib/cjs/geometry3d/IndexedXYCollection.js.map +1 -1
  178. package/lib/cjs/geometry3d/IndexedXYZCollection.js.map +1 -1
  179. package/lib/cjs/geometry3d/LongitudeLatitudeAltitude.js.map +1 -1
  180. package/lib/cjs/geometry3d/Matrix3d.d.ts +1 -1
  181. package/lib/cjs/geometry3d/Matrix3d.js +1 -1
  182. package/lib/cjs/geometry3d/Matrix3d.js.map +1 -1
  183. package/lib/cjs/geometry3d/OrderedRotationAngles.js.map +1 -1
  184. package/lib/cjs/geometry3d/Plane3d.js.map +1 -1
  185. package/lib/cjs/geometry3d/Plane3dByOriginAndUnitNormal.js.map +1 -1
  186. package/lib/cjs/geometry3d/Plane3dByOriginAndVectors.js.map +1 -1
  187. package/lib/cjs/geometry3d/Point2dArrayCarrier.js.map +1 -1
  188. package/lib/cjs/geometry3d/Point2dVector2d.d.ts +18 -2
  189. package/lib/cjs/geometry3d/Point2dVector2d.d.ts.map +1 -1
  190. package/lib/cjs/geometry3d/Point2dVector2d.js +37 -4
  191. package/lib/cjs/geometry3d/Point2dVector2d.js.map +1 -1
  192. package/lib/cjs/geometry3d/Point3dArrayCarrier.js.map +1 -1
  193. package/lib/cjs/geometry3d/Point3dVector3d.d.ts +1 -1
  194. package/lib/cjs/geometry3d/Point3dVector3d.d.ts.map +1 -1
  195. package/lib/cjs/geometry3d/Point3dVector3d.js +1 -0
  196. package/lib/cjs/geometry3d/Point3dVector3d.js.map +1 -1
  197. package/lib/cjs/geometry3d/PointHelpers.js.map +1 -1
  198. package/lib/cjs/geometry3d/PointStreaming.d.ts +8 -0
  199. package/lib/cjs/geometry3d/PointStreaming.d.ts.map +1 -1
  200. package/lib/cjs/geometry3d/PointStreaming.js +18 -2
  201. package/lib/cjs/geometry3d/PointStreaming.js.map +1 -1
  202. package/lib/cjs/geometry3d/PolygonOps.js.map +1 -1
  203. package/lib/cjs/geometry3d/PolylineCompressionByEdgeOffset.d.ts +8 -2
  204. package/lib/cjs/geometry3d/PolylineCompressionByEdgeOffset.d.ts.map +1 -1
  205. package/lib/cjs/geometry3d/PolylineCompressionByEdgeOffset.js +10 -4
  206. package/lib/cjs/geometry3d/PolylineCompressionByEdgeOffset.js.map +1 -1
  207. package/lib/cjs/geometry3d/PolylineOps.d.ts +14 -3
  208. package/lib/cjs/geometry3d/PolylineOps.d.ts.map +1 -1
  209. package/lib/cjs/geometry3d/PolylineOps.js +20 -4
  210. package/lib/cjs/geometry3d/PolylineOps.js.map +1 -1
  211. package/lib/cjs/geometry3d/Range.d.ts +34 -32
  212. package/lib/cjs/geometry3d/Range.d.ts.map +1 -1
  213. package/lib/cjs/geometry3d/Range.js +28 -21
  214. package/lib/cjs/geometry3d/Range.js.map +1 -1
  215. package/lib/cjs/geometry3d/Ray2d.d.ts +16 -6
  216. package/lib/cjs/geometry3d/Ray2d.d.ts.map +1 -1
  217. package/lib/cjs/geometry3d/Ray2d.js +28 -4
  218. package/lib/cjs/geometry3d/Ray2d.js.map +1 -1
  219. package/lib/cjs/geometry3d/Ray3d.d.ts.map +1 -1
  220. package/lib/cjs/geometry3d/Ray3d.js +3 -4
  221. package/lib/cjs/geometry3d/Ray3d.js.map +1 -1
  222. package/lib/cjs/geometry3d/ReusableObjectCache.js.map +1 -1
  223. package/lib/cjs/geometry3d/Segment1d.js.map +1 -1
  224. package/lib/cjs/geometry3d/SortablePolygon.js.map +1 -1
  225. package/lib/cjs/geometry3d/Transform.d.ts +1 -1
  226. package/lib/cjs/geometry3d/Transform.js +1 -1
  227. package/lib/cjs/geometry3d/Transform.js.map +1 -1
  228. package/lib/cjs/geometry3d/UVSurfaceOps.js.map +1 -1
  229. package/lib/cjs/geometry3d/XYZProps.d.ts +12 -1
  230. package/lib/cjs/geometry3d/XYZProps.d.ts.map +1 -1
  231. package/lib/cjs/geometry3d/XYZProps.js +17 -2
  232. package/lib/cjs/geometry3d/XYZProps.js.map +1 -1
  233. package/lib/cjs/geometry3d/YawPitchRollAngles.js.map +1 -1
  234. package/lib/cjs/geometry4d/Map4d.js.map +1 -1
  235. package/lib/cjs/geometry4d/Matrix4d.js.map +1 -1
  236. package/lib/cjs/geometry4d/MomentData.js.map +1 -1
  237. package/lib/cjs/geometry4d/PlaneByOriginAndVectors4d.js.map +1 -1
  238. package/lib/cjs/geometry4d/Point4d.js.map +1 -1
  239. package/lib/cjs/numerics/BandedSystem.js.map +1 -1
  240. package/lib/cjs/numerics/BezierPolynomials.d.ts.map +1 -1
  241. package/lib/cjs/numerics/BezierPolynomials.js +5 -9
  242. package/lib/cjs/numerics/BezierPolynomials.js.map +1 -1
  243. package/lib/cjs/numerics/ClusterableArray.js.map +1 -1
  244. package/lib/cjs/numerics/Complex.js.map +1 -1
  245. package/lib/cjs/numerics/ConvexPolygon2d.js.map +1 -1
  246. package/lib/cjs/numerics/Newton.js.map +1 -1
  247. package/lib/cjs/numerics/PascalCoefficients.js.map +1 -1
  248. package/lib/cjs/numerics/PolarData.js.map +1 -1
  249. package/lib/cjs/numerics/Polynomials.js.map +1 -1
  250. package/lib/cjs/numerics/Quadrature.js.map +1 -1
  251. package/lib/cjs/numerics/Range1dArray.js.map +1 -1
  252. package/lib/cjs/numerics/SmallSystem.d.ts +13 -7
  253. package/lib/cjs/numerics/SmallSystem.d.ts.map +1 -1
  254. package/lib/cjs/numerics/SmallSystem.js +13 -7
  255. package/lib/cjs/numerics/SmallSystem.js.map +1 -1
  256. package/lib/cjs/numerics/TriDiagonalSystem.js.map +1 -1
  257. package/lib/cjs/numerics/UnionFind.js.map +1 -1
  258. package/lib/cjs/numerics/UsageSums.js.map +1 -1
  259. package/lib/cjs/polyface/AuxData.js.map +1 -1
  260. package/lib/cjs/polyface/BoxTopology.js.map +1 -1
  261. package/lib/cjs/polyface/FacetFaceData.js.map +1 -1
  262. package/lib/cjs/polyface/FacetLocationDetail.js.map +1 -1
  263. package/lib/cjs/polyface/FacetOrientation.js.map +1 -1
  264. package/lib/cjs/polyface/GreedyTriangulationBetweenLineStrings.js.map +1 -1
  265. package/lib/cjs/polyface/IndexedEdgeMatcher.js.map +1 -1
  266. package/lib/cjs/polyface/IndexedPolyfaceVisitor.js.map +1 -1
  267. package/lib/cjs/polyface/IndexedPolyfaceWalker.js.map +1 -1
  268. package/lib/cjs/polyface/Polyface.js.map +1 -1
  269. package/lib/cjs/polyface/PolyfaceBuilder.d.ts +25 -6
  270. package/lib/cjs/polyface/PolyfaceBuilder.d.ts.map +1 -1
  271. package/lib/cjs/polyface/PolyfaceBuilder.js +59 -8
  272. package/lib/cjs/polyface/PolyfaceBuilder.js.map +1 -1
  273. package/lib/cjs/polyface/PolyfaceClip.js.map +1 -1
  274. package/lib/cjs/polyface/PolyfaceData.js.map +1 -1
  275. package/lib/cjs/polyface/PolyfaceQuery.d.ts.map +1 -1
  276. package/lib/cjs/polyface/PolyfaceQuery.js +8 -10
  277. package/lib/cjs/polyface/PolyfaceQuery.js.map +1 -1
  278. package/lib/cjs/polyface/RangeLengthData.js.map +1 -1
  279. package/lib/cjs/polyface/RangeTree/LineString3dRangeTreeContext.js.map +1 -1
  280. package/lib/cjs/polyface/RangeTree/MinimumValueTester.js.map +1 -1
  281. package/lib/cjs/polyface/RangeTree/Point3dArrayRangeTreeContext.d.ts +8 -5
  282. package/lib/cjs/polyface/RangeTree/Point3dArrayRangeTreeContext.d.ts.map +1 -1
  283. package/lib/cjs/polyface/RangeTree/Point3dArrayRangeTreeContext.js +8 -4
  284. package/lib/cjs/polyface/RangeTree/Point3dArrayRangeTreeContext.js.map +1 -1
  285. package/lib/cjs/polyface/RangeTree/PolyfaceRangeTreeContext.d.ts +3 -3
  286. package/lib/cjs/polyface/RangeTree/PolyfaceRangeTreeContext.d.ts.map +1 -1
  287. package/lib/cjs/polyface/RangeTree/PolyfaceRangeTreeContext.js +1 -1
  288. package/lib/cjs/polyface/RangeTree/PolyfaceRangeTreeContext.js.map +1 -1
  289. package/lib/cjs/polyface/RangeTree/RangeTreeNode.d.ts +4 -2
  290. package/lib/cjs/polyface/RangeTree/RangeTreeNode.d.ts.map +1 -1
  291. package/lib/cjs/polyface/RangeTree/RangeTreeNode.js +9 -12
  292. package/lib/cjs/polyface/RangeTree/RangeTreeNode.js.map +1 -1
  293. package/lib/cjs/polyface/RangeTree/RangeTreeSearchHandlers.d.ts +8 -3
  294. package/lib/cjs/polyface/RangeTree/RangeTreeSearchHandlers.d.ts.map +1 -1
  295. package/lib/cjs/polyface/RangeTree/RangeTreeSearchHandlers.js +13 -6
  296. package/lib/cjs/polyface/RangeTree/RangeTreeSearchHandlers.js.map +1 -1
  297. package/lib/cjs/polyface/TaggedNumericData.js.map +1 -1
  298. package/lib/cjs/polyface/TriangleCandidate.js.map +1 -1
  299. package/lib/cjs/polyface/multiclip/BuildAverageNormalsContext.js.map +1 -1
  300. package/lib/cjs/polyface/multiclip/GriddedRaggedRange2dSet.js.map +1 -1
  301. package/lib/cjs/polyface/multiclip/GriddedRaggedRange2dSetWithOverflow.js.map +1 -1
  302. package/lib/cjs/polyface/multiclip/LinearSearchRange2dArray.js.map +1 -1
  303. package/lib/cjs/polyface/multiclip/OffsetMeshContext.js.map +1 -1
  304. package/lib/cjs/polyface/multiclip/Range2dSearchInterface.js.map +1 -1
  305. package/lib/cjs/polyface/multiclip/RangeSearch.js.map +1 -1
  306. package/lib/cjs/polyface/multiclip/SweepLineStringToFacetContext.js.map +1 -1
  307. package/lib/cjs/polyface/multiclip/XYPointBuckets.js.map +1 -1
  308. package/lib/cjs/serialization/BGFBAccessors.js.map +1 -1
  309. package/lib/cjs/serialization/BGFBReader.js.map +1 -1
  310. package/lib/cjs/serialization/BGFBWriter.js.map +1 -1
  311. package/lib/cjs/serialization/BentleyGeometryFlatBuffer.js.map +1 -1
  312. package/lib/cjs/serialization/DeepCompare.js +1 -1
  313. package/lib/cjs/serialization/DeepCompare.js.map +1 -1
  314. package/lib/cjs/serialization/GeometrySamples.d.ts +2 -1
  315. package/lib/cjs/serialization/GeometrySamples.d.ts.map +1 -1
  316. package/lib/cjs/serialization/GeometrySamples.js +2 -1
  317. package/lib/cjs/serialization/GeometrySamples.js.map +1 -1
  318. package/lib/cjs/serialization/IModelJsonSchema.js.map +1 -1
  319. package/lib/cjs/serialization/SerializationHelpers.js.map +1 -1
  320. package/lib/cjs/solid/Box.js.map +1 -1
  321. package/lib/cjs/solid/Cone.js.map +1 -1
  322. package/lib/cjs/solid/LinearSweep.js.map +1 -1
  323. package/lib/cjs/solid/RotationalSweep.js.map +1 -1
  324. package/lib/cjs/solid/RuledSweep.js.map +1 -1
  325. package/lib/cjs/solid/SolidPrimitive.js.map +1 -1
  326. package/lib/cjs/solid/Sphere.js.map +1 -1
  327. package/lib/cjs/solid/SweepContour.js.map +1 -1
  328. package/lib/cjs/solid/TorusPipe.js.map +1 -1
  329. package/lib/cjs/topology/ChainMerge.js.map +1 -1
  330. package/lib/cjs/topology/Graph.d.ts +38 -12
  331. package/lib/cjs/topology/Graph.d.ts.map +1 -1
  332. package/lib/cjs/topology/Graph.js +91 -23
  333. package/lib/cjs/topology/Graph.js.map +1 -1
  334. package/lib/cjs/topology/HalfEdgeGraphFromIndexedLoopsContext.d.ts +5 -4
  335. package/lib/cjs/topology/HalfEdgeGraphFromIndexedLoopsContext.d.ts.map +1 -1
  336. package/lib/cjs/topology/HalfEdgeGraphFromIndexedLoopsContext.js +6 -5
  337. package/lib/cjs/topology/HalfEdgeGraphFromIndexedLoopsContext.js.map +1 -1
  338. package/lib/cjs/topology/HalfEdgeGraphSearch.d.ts +20 -11
  339. package/lib/cjs/topology/HalfEdgeGraphSearch.d.ts.map +1 -1
  340. package/lib/cjs/topology/HalfEdgeGraphSearch.js +43 -39
  341. package/lib/cjs/topology/HalfEdgeGraphSearch.js.map +1 -1
  342. package/lib/cjs/topology/HalfEdgeGraphSpineContext.js.map +1 -1
  343. package/lib/cjs/topology/HalfEdgeGraphValidation.js.map +1 -1
  344. package/lib/cjs/topology/HalfEdgeMarkSet.js.map +1 -1
  345. package/lib/cjs/topology/HalfEdgeNodeXYZUV.js.map +1 -1
  346. package/lib/cjs/topology/HalfEdgePointInGraphSearch.js.map +1 -1
  347. package/lib/cjs/topology/HalfEdgePositionDetail.js.map +1 -1
  348. package/lib/cjs/topology/HalfEdgePriorityQueue.js.map +1 -1
  349. package/lib/cjs/topology/InsertAndRetriangulateContext.js.map +1 -1
  350. package/lib/cjs/topology/MaskManager.js.map +1 -1
  351. package/lib/cjs/topology/Merging.d.ts +7 -4
  352. package/lib/cjs/topology/Merging.d.ts.map +1 -1
  353. package/lib/cjs/topology/Merging.js +16 -11
  354. package/lib/cjs/topology/Merging.js.map +1 -1
  355. package/lib/cjs/topology/RegularizeFace.js.map +1 -1
  356. package/lib/cjs/topology/SignedDataSummary.js.map +1 -1
  357. package/lib/cjs/topology/SpaceTriangulation.js.map +1 -1
  358. package/lib/cjs/topology/Triangulation.d.ts +13 -11
  359. package/lib/cjs/topology/Triangulation.d.ts.map +1 -1
  360. package/lib/cjs/topology/Triangulation.js +40 -36
  361. package/lib/cjs/topology/Triangulation.js.map +1 -1
  362. package/lib/cjs/topology/Voronoi.d.ts +195 -0
  363. package/lib/cjs/topology/Voronoi.d.ts.map +1 -0
  364. package/lib/cjs/topology/Voronoi.js +700 -0
  365. package/lib/cjs/topology/Voronoi.js.map +1 -0
  366. package/lib/cjs/topology/XYParitySearchContext.d.ts +1 -1
  367. package/lib/cjs/topology/XYParitySearchContext.d.ts.map +1 -1
  368. package/lib/cjs/topology/XYParitySearchContext.js.map +1 -1
  369. package/lib/esm/Constant.js.map +1 -1
  370. package/lib/esm/Geometry.d.ts +30 -10
  371. package/lib/esm/Geometry.d.ts.map +1 -1
  372. package/lib/esm/Geometry.js +74 -10
  373. package/lib/esm/Geometry.js.map +1 -1
  374. package/lib/esm/bspline/AkimaCurve3d.d.ts +19 -6
  375. package/lib/esm/bspline/AkimaCurve3d.d.ts.map +1 -1
  376. package/lib/esm/bspline/AkimaCurve3d.js +21 -5
  377. package/lib/esm/bspline/AkimaCurve3d.js.map +1 -1
  378. package/lib/esm/bspline/BSpline1dNd.js.map +1 -1
  379. package/lib/esm/bspline/BSplineCurve.d.ts +3 -3
  380. package/lib/esm/bspline/BSplineCurve.d.ts.map +1 -1
  381. package/lib/esm/bspline/BSplineCurve.js +6 -6
  382. package/lib/esm/bspline/BSplineCurve.js.map +1 -1
  383. package/lib/esm/bspline/BSplineCurve3dH.js.map +1 -1
  384. package/lib/esm/bspline/BSplineCurveOps.d.ts.map +1 -1
  385. package/lib/esm/bspline/BSplineCurveOps.js +1 -1
  386. package/lib/esm/bspline/BSplineCurveOps.js.map +1 -1
  387. package/lib/esm/bspline/BSplineSurface.js.map +1 -1
  388. package/lib/esm/bspline/Bezier1dNd.js.map +1 -1
  389. package/lib/esm/bspline/BezierCurve3d.js.map +1 -1
  390. package/lib/esm/bspline/BezierCurve3dH.js.map +1 -1
  391. package/lib/esm/bspline/BezierCurveBase.d.ts +2 -2
  392. package/lib/esm/bspline/BezierCurveBase.d.ts.map +1 -1
  393. package/lib/esm/bspline/BezierCurveBase.js +4 -6
  394. package/lib/esm/bspline/BezierCurveBase.js.map +1 -1
  395. package/lib/esm/bspline/InterpolationCurve3d.d.ts +27 -17
  396. package/lib/esm/bspline/InterpolationCurve3d.d.ts.map +1 -1
  397. package/lib/esm/bspline/InterpolationCurve3d.js +17 -7
  398. package/lib/esm/bspline/InterpolationCurve3d.js.map +1 -1
  399. package/lib/esm/bspline/KnotVector.js.map +1 -1
  400. package/lib/esm/bspline/SurfaceLocationDetail.js.map +1 -1
  401. package/lib/esm/clipping/AlternatingConvexClipTree.js.map +1 -1
  402. package/lib/esm/clipping/BooleanClipFactory.js.map +1 -1
  403. package/lib/esm/clipping/BooleanClipNode.js.map +1 -1
  404. package/lib/esm/clipping/ClipPlane.d.ts +9 -3
  405. package/lib/esm/clipping/ClipPlane.d.ts.map +1 -1
  406. package/lib/esm/clipping/ClipPlane.js +8 -0
  407. package/lib/esm/clipping/ClipPlane.js.map +1 -1
  408. package/lib/esm/clipping/ClipPrimitive.js.map +1 -1
  409. package/lib/esm/clipping/ClipUtils.d.ts +14 -1
  410. package/lib/esm/clipping/ClipUtils.d.ts.map +1 -1
  411. package/lib/esm/clipping/ClipUtils.js +21 -3
  412. package/lib/esm/clipping/ClipUtils.js.map +1 -1
  413. package/lib/esm/clipping/ClipVector.js.map +1 -1
  414. package/lib/esm/clipping/ConvexClipPlaneSet.d.ts +2 -2
  415. package/lib/esm/clipping/ConvexClipPlaneSet.d.ts.map +1 -1
  416. package/lib/esm/clipping/ConvexClipPlaneSet.js +6 -4
  417. package/lib/esm/clipping/ConvexClipPlaneSet.js.map +1 -1
  418. package/lib/esm/clipping/UnionOfConvexClipPlaneSets.js.map +1 -1
  419. package/lib/esm/clipping/internalContexts/LineStringOffsetClipperContext.js.map +1 -1
  420. package/lib/esm/core-geometry.js.map +1 -1
  421. package/lib/esm/curve/Arc3d.d.ts +27 -17
  422. package/lib/esm/curve/Arc3d.d.ts.map +1 -1
  423. package/lib/esm/curve/Arc3d.js +61 -35
  424. package/lib/esm/curve/Arc3d.js.map +1 -1
  425. package/lib/esm/curve/ConstructCurveBetweenCurves.js.map +1 -1
  426. package/lib/esm/curve/CoordinateXYZ.js.map +1 -1
  427. package/lib/esm/curve/CurveChainWithDistanceIndex.js.map +1 -1
  428. package/lib/esm/curve/CurveCollection.d.ts +1 -0
  429. package/lib/esm/curve/CurveCollection.d.ts.map +1 -1
  430. package/lib/esm/curve/CurveCollection.js +1 -0
  431. package/lib/esm/curve/CurveCollection.js.map +1 -1
  432. package/lib/esm/curve/CurveCurve.js.map +1 -1
  433. package/lib/esm/curve/CurveExtendMode.js.map +1 -1
  434. package/lib/esm/curve/CurveFactory.js.map +1 -1
  435. package/lib/esm/curve/CurveLocationDetail.d.ts +8 -7
  436. package/lib/esm/curve/CurveLocationDetail.d.ts.map +1 -1
  437. package/lib/esm/curve/CurveLocationDetail.js.map +1 -1
  438. package/lib/esm/curve/CurveOps.d.ts +51 -1
  439. package/lib/esm/curve/CurveOps.d.ts.map +1 -1
  440. package/lib/esm/curve/CurveOps.js +98 -4
  441. package/lib/esm/curve/CurveOps.js.map +1 -1
  442. package/lib/esm/curve/CurvePrimitive.js.map +1 -1
  443. package/lib/esm/curve/CurveProcessor.js.map +1 -1
  444. package/lib/esm/curve/CurveTypes.js.map +1 -1
  445. package/lib/esm/curve/CurveWireMomentsXYZ.js.map +1 -1
  446. package/lib/esm/curve/GeometryQuery.js.map +1 -1
  447. package/lib/esm/curve/LineSegment3d.js.map +1 -1
  448. package/lib/esm/curve/LineString3d.d.ts +4 -4
  449. package/lib/esm/curve/LineString3d.d.ts.map +1 -1
  450. package/lib/esm/curve/LineString3d.js +8 -8
  451. package/lib/esm/curve/LineString3d.js.map +1 -1
  452. package/lib/esm/curve/Loop.js.map +1 -1
  453. package/lib/esm/curve/OffsetOptions.js.map +1 -1
  454. package/lib/esm/curve/ParityRegion.js.map +1 -1
  455. package/lib/esm/curve/Path.js.map +1 -1
  456. package/lib/esm/curve/PointString3d.js.map +1 -1
  457. package/lib/esm/curve/ProxyCurve.js.map +1 -1
  458. package/lib/esm/curve/Query/ConsolidateAdjacentPrimitivesContext.js +3 -3
  459. package/lib/esm/curve/Query/ConsolidateAdjacentPrimitivesContext.js.map +1 -1
  460. package/lib/esm/curve/Query/CurveSplitContext.js.map +1 -1
  461. package/lib/esm/curve/Query/CylindricalRange.js.map +1 -1
  462. package/lib/esm/curve/Query/InOutTests.js.map +1 -1
  463. package/lib/esm/curve/Query/PlanarSubdivision.d.ts +6 -2
  464. package/lib/esm/curve/Query/PlanarSubdivision.d.ts.map +1 -1
  465. package/lib/esm/curve/Query/PlanarSubdivision.js +12 -7
  466. package/lib/esm/curve/Query/PlanarSubdivision.js.map +1 -1
  467. package/lib/esm/curve/Query/StrokeCountChain.js.map +1 -1
  468. package/lib/esm/curve/Query/StrokeCountMap.js.map +1 -1
  469. package/lib/esm/curve/RegionMomentsXY.js.map +1 -1
  470. package/lib/esm/curve/RegionOps.d.ts +9 -4
  471. package/lib/esm/curve/RegionOps.d.ts.map +1 -1
  472. package/lib/esm/curve/RegionOps.js +10 -5
  473. package/lib/esm/curve/RegionOps.js.map +1 -1
  474. package/lib/esm/curve/RegionOpsClassificationSweeps.js.map +1 -1
  475. package/lib/esm/curve/StrokeOptions.js.map +1 -1
  476. package/lib/esm/curve/UnionRegion.js.map +1 -1
  477. package/lib/esm/curve/internalContexts/AnnounceTangentStrokeHandler.js.map +1 -1
  478. package/lib/esm/curve/internalContexts/AppendPlaneIntersectionStrokeHandler.js.map +1 -1
  479. package/lib/esm/curve/internalContexts/ChainCollectorContext.js.map +1 -1
  480. package/lib/esm/curve/internalContexts/CloneCurvesContext.js.map +1 -1
  481. package/lib/esm/curve/internalContexts/CloneWithExpandedLineStrings.js.map +1 -1
  482. package/lib/esm/curve/internalContexts/ClosestPointStrokeHandler.js.map +1 -1
  483. package/lib/esm/curve/internalContexts/CountLinearPartsSearchContext.js.map +1 -1
  484. package/lib/esm/curve/internalContexts/CurveCurveCloseApproachXY.js.map +1 -1
  485. package/lib/esm/curve/internalContexts/CurveCurveIntersectXY.d.ts.map +1 -1
  486. package/lib/esm/curve/internalContexts/CurveCurveIntersectXY.js +2 -1
  487. package/lib/esm/curve/internalContexts/CurveCurveIntersectXY.js.map +1 -1
  488. package/lib/esm/curve/internalContexts/CurveCurveIntersectXYZ.js.map +1 -1
  489. package/lib/esm/curve/internalContexts/CurveLengthContext.js.map +1 -1
  490. package/lib/esm/curve/internalContexts/CurveOffsetXYHandler.js.map +1 -1
  491. package/lib/esm/curve/internalContexts/EllipticalArcApproximationContext.js.map +1 -1
  492. package/lib/esm/curve/internalContexts/GapSearchContext.js.map +1 -1
  493. package/lib/esm/curve/internalContexts/MultiChainCollector.d.ts +4 -4
  494. package/lib/esm/curve/internalContexts/MultiChainCollector.d.ts.map +1 -1
  495. package/lib/esm/curve/internalContexts/MultiChainCollector.js +21 -18
  496. package/lib/esm/curve/internalContexts/MultiChainCollector.js.map +1 -1
  497. package/lib/esm/curve/internalContexts/NewtonRtoRStrokeHandler.js.map +1 -1
  498. package/lib/esm/curve/internalContexts/PlaneAltitudeRangeContext.js.map +1 -1
  499. package/lib/esm/curve/internalContexts/PolygonOffsetContext.js.map +1 -1
  500. package/lib/esm/curve/internalContexts/SumLengthsContext.js.map +1 -1
  501. package/lib/esm/curve/internalContexts/TransferWithSplitArcs.js.map +1 -1
  502. package/lib/esm/curve/internalContexts/TransformInPlaceContext.js.map +1 -1
  503. package/lib/esm/curve/spiral/AustralianRailCorpXYEvaluator.js.map +1 -1
  504. package/lib/esm/curve/spiral/ClothoidSeries.js.map +1 -1
  505. package/lib/esm/curve/spiral/CubicEvaluator.js.map +1 -1
  506. package/lib/esm/curve/spiral/CzechSpiralEvaluator.js.map +1 -1
  507. package/lib/esm/curve/spiral/DirectHalfCosineSpiralEvaluator.js.map +1 -1
  508. package/lib/esm/curve/spiral/DirectSpiral3d.d.ts +2 -2
  509. package/lib/esm/curve/spiral/DirectSpiral3d.d.ts.map +1 -1
  510. package/lib/esm/curve/spiral/DirectSpiral3d.js +6 -2
  511. package/lib/esm/curve/spiral/DirectSpiral3d.js.map +1 -1
  512. package/lib/esm/curve/spiral/IntegratedSpiral3d.d.ts +2 -2
  513. package/lib/esm/curve/spiral/IntegratedSpiral3d.d.ts.map +1 -1
  514. package/lib/esm/curve/spiral/IntegratedSpiral3d.js +6 -2
  515. package/lib/esm/curve/spiral/IntegratedSpiral3d.js.map +1 -1
  516. package/lib/esm/curve/spiral/MXCubicAlongArcSpiralEvaluator.js.map +1 -1
  517. package/lib/esm/curve/spiral/NormalizedTransition.js.map +1 -1
  518. package/lib/esm/curve/spiral/PolishCubicSpiralEvaluator.js.map +1 -1
  519. package/lib/esm/curve/spiral/TransitionConditionalProperties.js.map +1 -1
  520. package/lib/esm/curve/spiral/TransitionSpiral3d.d.ts +5 -1
  521. package/lib/esm/curve/spiral/TransitionSpiral3d.d.ts.map +1 -1
  522. package/lib/esm/curve/spiral/TransitionSpiral3d.js +0 -3
  523. package/lib/esm/curve/spiral/TransitionSpiral3d.js.map +1 -1
  524. package/lib/esm/curve/spiral/XYCurveEvaluator.js.map +1 -1
  525. package/lib/esm/geometry3d/Angle.js.map +1 -1
  526. package/lib/esm/geometry3d/AngleSweep.d.ts +6 -2
  527. package/lib/esm/geometry3d/AngleSweep.d.ts.map +1 -1
  528. package/lib/esm/geometry3d/AngleSweep.js +12 -3
  529. package/lib/esm/geometry3d/AngleSweep.js.map +1 -1
  530. package/lib/esm/geometry3d/BarycentricTriangle.js.map +1 -1
  531. package/lib/esm/geometry3d/BilinearPatch.js.map +1 -1
  532. package/lib/esm/geometry3d/CoincidentGeometryOps.js.map +1 -1
  533. package/lib/esm/geometry3d/Ellipsoid.js.map +1 -1
  534. package/lib/esm/geometry3d/FrameBuilder.d.ts +2 -1
  535. package/lib/esm/geometry3d/FrameBuilder.d.ts.map +1 -1
  536. package/lib/esm/geometry3d/FrameBuilder.js +14 -18
  537. package/lib/esm/geometry3d/FrameBuilder.js.map +1 -1
  538. package/lib/esm/geometry3d/FrustumAnimation.js.map +1 -1
  539. package/lib/esm/geometry3d/GeometryHandler.js.map +1 -1
  540. package/lib/esm/geometry3d/GrowableBlockedArray.js.map +1 -1
  541. package/lib/esm/geometry3d/GrowableFloat64Array.js.map +1 -1
  542. package/lib/esm/geometry3d/GrowableXYArray.js.map +1 -1
  543. package/lib/esm/geometry3d/GrowableXYZArray.js.map +1 -1
  544. package/lib/esm/geometry3d/IndexedCollectionInterval.js.map +1 -1
  545. package/lib/esm/geometry3d/IndexedXYCollection.js.map +1 -1
  546. package/lib/esm/geometry3d/IndexedXYZCollection.js.map +1 -1
  547. package/lib/esm/geometry3d/LongitudeLatitudeAltitude.js.map +1 -1
  548. package/lib/esm/geometry3d/Matrix3d.d.ts +1 -1
  549. package/lib/esm/geometry3d/Matrix3d.js +1 -1
  550. package/lib/esm/geometry3d/Matrix3d.js.map +1 -1
  551. package/lib/esm/geometry3d/OrderedRotationAngles.js.map +1 -1
  552. package/lib/esm/geometry3d/Plane3d.js.map +1 -1
  553. package/lib/esm/geometry3d/Plane3dByOriginAndUnitNormal.js.map +1 -1
  554. package/lib/esm/geometry3d/Plane3dByOriginAndVectors.js.map +1 -1
  555. package/lib/esm/geometry3d/Point2dArrayCarrier.js.map +1 -1
  556. package/lib/esm/geometry3d/Point2dVector2d.d.ts +18 -2
  557. package/lib/esm/geometry3d/Point2dVector2d.d.ts.map +1 -1
  558. package/lib/esm/geometry3d/Point2dVector2d.js +37 -4
  559. package/lib/esm/geometry3d/Point2dVector2d.js.map +1 -1
  560. package/lib/esm/geometry3d/Point3dArrayCarrier.js.map +1 -1
  561. package/lib/esm/geometry3d/Point3dVector3d.d.ts +1 -1
  562. package/lib/esm/geometry3d/Point3dVector3d.d.ts.map +1 -1
  563. package/lib/esm/geometry3d/Point3dVector3d.js +1 -0
  564. package/lib/esm/geometry3d/Point3dVector3d.js.map +1 -1
  565. package/lib/esm/geometry3d/PointHelpers.js.map +1 -1
  566. package/lib/esm/geometry3d/PointStreaming.d.ts +8 -0
  567. package/lib/esm/geometry3d/PointStreaming.d.ts.map +1 -1
  568. package/lib/esm/geometry3d/PointStreaming.js +18 -2
  569. package/lib/esm/geometry3d/PointStreaming.js.map +1 -1
  570. package/lib/esm/geometry3d/PolygonOps.js.map +1 -1
  571. package/lib/esm/geometry3d/PolylineCompressionByEdgeOffset.d.ts +8 -2
  572. package/lib/esm/geometry3d/PolylineCompressionByEdgeOffset.d.ts.map +1 -1
  573. package/lib/esm/geometry3d/PolylineCompressionByEdgeOffset.js +10 -4
  574. package/lib/esm/geometry3d/PolylineCompressionByEdgeOffset.js.map +1 -1
  575. package/lib/esm/geometry3d/PolylineOps.d.ts +14 -3
  576. package/lib/esm/geometry3d/PolylineOps.d.ts.map +1 -1
  577. package/lib/esm/geometry3d/PolylineOps.js +20 -4
  578. package/lib/esm/geometry3d/PolylineOps.js.map +1 -1
  579. package/lib/esm/geometry3d/Range.d.ts +34 -32
  580. package/lib/esm/geometry3d/Range.d.ts.map +1 -1
  581. package/lib/esm/geometry3d/Range.js +28 -21
  582. package/lib/esm/geometry3d/Range.js.map +1 -1
  583. package/lib/esm/geometry3d/Ray2d.d.ts +16 -6
  584. package/lib/esm/geometry3d/Ray2d.d.ts.map +1 -1
  585. package/lib/esm/geometry3d/Ray2d.js +28 -4
  586. package/lib/esm/geometry3d/Ray2d.js.map +1 -1
  587. package/lib/esm/geometry3d/Ray3d.d.ts.map +1 -1
  588. package/lib/esm/geometry3d/Ray3d.js +3 -4
  589. package/lib/esm/geometry3d/Ray3d.js.map +1 -1
  590. package/lib/esm/geometry3d/ReusableObjectCache.js.map +1 -1
  591. package/lib/esm/geometry3d/Segment1d.js.map +1 -1
  592. package/lib/esm/geometry3d/SortablePolygon.js.map +1 -1
  593. package/lib/esm/geometry3d/Transform.d.ts +1 -1
  594. package/lib/esm/geometry3d/Transform.js +1 -1
  595. package/lib/esm/geometry3d/Transform.js.map +1 -1
  596. package/lib/esm/geometry3d/UVSurfaceOps.js.map +1 -1
  597. package/lib/esm/geometry3d/XYZProps.d.ts +12 -1
  598. package/lib/esm/geometry3d/XYZProps.d.ts.map +1 -1
  599. package/lib/esm/geometry3d/XYZProps.js +16 -1
  600. package/lib/esm/geometry3d/XYZProps.js.map +1 -1
  601. package/lib/esm/geometry3d/YawPitchRollAngles.js.map +1 -1
  602. package/lib/esm/geometry4d/Map4d.js.map +1 -1
  603. package/lib/esm/geometry4d/Matrix4d.js.map +1 -1
  604. package/lib/esm/geometry4d/MomentData.js.map +1 -1
  605. package/lib/esm/geometry4d/PlaneByOriginAndVectors4d.js.map +1 -1
  606. package/lib/esm/geometry4d/Point4d.js.map +1 -1
  607. package/lib/esm/numerics/BandedSystem.js.map +1 -1
  608. package/lib/esm/numerics/BezierPolynomials.d.ts.map +1 -1
  609. package/lib/esm/numerics/BezierPolynomials.js +5 -9
  610. package/lib/esm/numerics/BezierPolynomials.js.map +1 -1
  611. package/lib/esm/numerics/ClusterableArray.js.map +1 -1
  612. package/lib/esm/numerics/Complex.js.map +1 -1
  613. package/lib/esm/numerics/ConvexPolygon2d.js.map +1 -1
  614. package/lib/esm/numerics/Newton.js.map +1 -1
  615. package/lib/esm/numerics/PascalCoefficients.js.map +1 -1
  616. package/lib/esm/numerics/PolarData.js.map +1 -1
  617. package/lib/esm/numerics/Polynomials.js.map +1 -1
  618. package/lib/esm/numerics/Quadrature.js.map +1 -1
  619. package/lib/esm/numerics/Range1dArray.js.map +1 -1
  620. package/lib/esm/numerics/SmallSystem.d.ts +13 -7
  621. package/lib/esm/numerics/SmallSystem.d.ts.map +1 -1
  622. package/lib/esm/numerics/SmallSystem.js +13 -7
  623. package/lib/esm/numerics/SmallSystem.js.map +1 -1
  624. package/lib/esm/numerics/TriDiagonalSystem.js.map +1 -1
  625. package/lib/esm/numerics/UnionFind.js.map +1 -1
  626. package/lib/esm/numerics/UsageSums.js.map +1 -1
  627. package/lib/esm/polyface/AuxData.js.map +1 -1
  628. package/lib/esm/polyface/BoxTopology.js.map +1 -1
  629. package/lib/esm/polyface/FacetFaceData.js.map +1 -1
  630. package/lib/esm/polyface/FacetLocationDetail.js.map +1 -1
  631. package/lib/esm/polyface/FacetOrientation.js.map +1 -1
  632. package/lib/esm/polyface/GreedyTriangulationBetweenLineStrings.js.map +1 -1
  633. package/lib/esm/polyface/IndexedEdgeMatcher.js.map +1 -1
  634. package/lib/esm/polyface/IndexedPolyfaceVisitor.js.map +1 -1
  635. package/lib/esm/polyface/IndexedPolyfaceWalker.js.map +1 -1
  636. package/lib/esm/polyface/Polyface.js.map +1 -1
  637. package/lib/esm/polyface/PolyfaceBuilder.d.ts +25 -6
  638. package/lib/esm/polyface/PolyfaceBuilder.d.ts.map +1 -1
  639. package/lib/esm/polyface/PolyfaceBuilder.js +59 -8
  640. package/lib/esm/polyface/PolyfaceBuilder.js.map +1 -1
  641. package/lib/esm/polyface/PolyfaceClip.js.map +1 -1
  642. package/lib/esm/polyface/PolyfaceData.js.map +1 -1
  643. package/lib/esm/polyface/PolyfaceQuery.d.ts.map +1 -1
  644. package/lib/esm/polyface/PolyfaceQuery.js +8 -10
  645. package/lib/esm/polyface/PolyfaceQuery.js.map +1 -1
  646. package/lib/esm/polyface/RangeLengthData.js.map +1 -1
  647. package/lib/esm/polyface/RangeTree/LineString3dRangeTreeContext.js.map +1 -1
  648. package/lib/esm/polyface/RangeTree/MinimumValueTester.js.map +1 -1
  649. package/lib/esm/polyface/RangeTree/Point3dArrayRangeTreeContext.d.ts +8 -5
  650. package/lib/esm/polyface/RangeTree/Point3dArrayRangeTreeContext.d.ts.map +1 -1
  651. package/lib/esm/polyface/RangeTree/Point3dArrayRangeTreeContext.js +8 -4
  652. package/lib/esm/polyface/RangeTree/Point3dArrayRangeTreeContext.js.map +1 -1
  653. package/lib/esm/polyface/RangeTree/PolyfaceRangeTreeContext.d.ts +3 -3
  654. package/lib/esm/polyface/RangeTree/PolyfaceRangeTreeContext.d.ts.map +1 -1
  655. package/lib/esm/polyface/RangeTree/PolyfaceRangeTreeContext.js +1 -1
  656. package/lib/esm/polyface/RangeTree/PolyfaceRangeTreeContext.js.map +1 -1
  657. package/lib/esm/polyface/RangeTree/RangeTreeNode.d.ts +4 -2
  658. package/lib/esm/polyface/RangeTree/RangeTreeNode.d.ts.map +1 -1
  659. package/lib/esm/polyface/RangeTree/RangeTreeNode.js +9 -12
  660. package/lib/esm/polyface/RangeTree/RangeTreeNode.js.map +1 -1
  661. package/lib/esm/polyface/RangeTree/RangeTreeSearchHandlers.d.ts +8 -3
  662. package/lib/esm/polyface/RangeTree/RangeTreeSearchHandlers.d.ts.map +1 -1
  663. package/lib/esm/polyface/RangeTree/RangeTreeSearchHandlers.js +13 -6
  664. package/lib/esm/polyface/RangeTree/RangeTreeSearchHandlers.js.map +1 -1
  665. package/lib/esm/polyface/TaggedNumericData.js.map +1 -1
  666. package/lib/esm/polyface/TriangleCandidate.js.map +1 -1
  667. package/lib/esm/polyface/multiclip/BuildAverageNormalsContext.js.map +1 -1
  668. package/lib/esm/polyface/multiclip/GriddedRaggedRange2dSet.js.map +1 -1
  669. package/lib/esm/polyface/multiclip/GriddedRaggedRange2dSetWithOverflow.js.map +1 -1
  670. package/lib/esm/polyface/multiclip/LinearSearchRange2dArray.js.map +1 -1
  671. package/lib/esm/polyface/multiclip/OffsetMeshContext.js.map +1 -1
  672. package/lib/esm/polyface/multiclip/Range2dSearchInterface.js.map +1 -1
  673. package/lib/esm/polyface/multiclip/RangeSearch.js.map +1 -1
  674. package/lib/esm/polyface/multiclip/SweepLineStringToFacetContext.js.map +1 -1
  675. package/lib/esm/polyface/multiclip/XYPointBuckets.js.map +1 -1
  676. package/lib/esm/serialization/BGFBAccessors.js.map +1 -1
  677. package/lib/esm/serialization/BGFBReader.js.map +1 -1
  678. package/lib/esm/serialization/BGFBWriter.js.map +1 -1
  679. package/lib/esm/serialization/BentleyGeometryFlatBuffer.js.map +1 -1
  680. package/lib/esm/serialization/DeepCompare.js +1 -1
  681. package/lib/esm/serialization/DeepCompare.js.map +1 -1
  682. package/lib/esm/serialization/GeometrySamples.d.ts +2 -1
  683. package/lib/esm/serialization/GeometrySamples.d.ts.map +1 -1
  684. package/lib/esm/serialization/GeometrySamples.js +2 -1
  685. package/lib/esm/serialization/GeometrySamples.js.map +1 -1
  686. package/lib/esm/serialization/IModelJsonSchema.js.map +1 -1
  687. package/lib/esm/serialization/SerializationHelpers.js.map +1 -1
  688. package/lib/esm/solid/Box.js.map +1 -1
  689. package/lib/esm/solid/Cone.js.map +1 -1
  690. package/lib/esm/solid/LinearSweep.js.map +1 -1
  691. package/lib/esm/solid/RotationalSweep.js.map +1 -1
  692. package/lib/esm/solid/RuledSweep.js.map +1 -1
  693. package/lib/esm/solid/SolidPrimitive.js.map +1 -1
  694. package/lib/esm/solid/Sphere.js.map +1 -1
  695. package/lib/esm/solid/SweepContour.js.map +1 -1
  696. package/lib/esm/solid/TorusPipe.js.map +1 -1
  697. package/lib/esm/topology/ChainMerge.js.map +1 -1
  698. package/lib/esm/topology/Graph.d.ts +38 -12
  699. package/lib/esm/topology/Graph.d.ts.map +1 -1
  700. package/lib/esm/topology/Graph.js +92 -24
  701. package/lib/esm/topology/Graph.js.map +1 -1
  702. package/lib/esm/topology/HalfEdgeGraphFromIndexedLoopsContext.d.ts +5 -4
  703. package/lib/esm/topology/HalfEdgeGraphFromIndexedLoopsContext.d.ts.map +1 -1
  704. package/lib/esm/topology/HalfEdgeGraphFromIndexedLoopsContext.js +6 -5
  705. package/lib/esm/topology/HalfEdgeGraphFromIndexedLoopsContext.js.map +1 -1
  706. package/lib/esm/topology/HalfEdgeGraphSearch.d.ts +20 -11
  707. package/lib/esm/topology/HalfEdgeGraphSearch.d.ts.map +1 -1
  708. package/lib/esm/topology/HalfEdgeGraphSearch.js +43 -39
  709. package/lib/esm/topology/HalfEdgeGraphSearch.js.map +1 -1
  710. package/lib/esm/topology/HalfEdgeGraphSpineContext.js.map +1 -1
  711. package/lib/esm/topology/HalfEdgeGraphValidation.js.map +1 -1
  712. package/lib/esm/topology/HalfEdgeMarkSet.js.map +1 -1
  713. package/lib/esm/topology/HalfEdgeNodeXYZUV.js.map +1 -1
  714. package/lib/esm/topology/HalfEdgePointInGraphSearch.js.map +1 -1
  715. package/lib/esm/topology/HalfEdgePositionDetail.js.map +1 -1
  716. package/lib/esm/topology/HalfEdgePriorityQueue.js.map +1 -1
  717. package/lib/esm/topology/InsertAndRetriangulateContext.js.map +1 -1
  718. package/lib/esm/topology/MaskManager.js.map +1 -1
  719. package/lib/esm/topology/Merging.d.ts +7 -4
  720. package/lib/esm/topology/Merging.d.ts.map +1 -1
  721. package/lib/esm/topology/Merging.js +17 -12
  722. package/lib/esm/topology/Merging.js.map +1 -1
  723. package/lib/esm/topology/RegularizeFace.js.map +1 -1
  724. package/lib/esm/topology/SignedDataSummary.js.map +1 -1
  725. package/lib/esm/topology/SpaceTriangulation.js.map +1 -1
  726. package/lib/esm/topology/Triangulation.d.ts +13 -11
  727. package/lib/esm/topology/Triangulation.d.ts.map +1 -1
  728. package/lib/esm/topology/Triangulation.js +40 -36
  729. package/lib/esm/topology/Triangulation.js.map +1 -1
  730. package/lib/esm/topology/Voronoi.d.ts +195 -0
  731. package/lib/esm/topology/Voronoi.d.ts.map +1 -0
  732. package/lib/esm/topology/Voronoi.js +696 -0
  733. package/lib/esm/topology/Voronoi.js.map +1 -0
  734. package/lib/esm/topology/XYParitySearchContext.d.ts +1 -1
  735. package/lib/esm/topology/XYParitySearchContext.d.ts.map +1 -1
  736. package/lib/esm/topology/XYParitySearchContext.js.map +1 -1
  737. package/package.json +3 -3
@@ -1 +1 @@
1
- {"version":3,"file":"RangeLengthData.js","sourceRoot":"","sources":["../../../src/polyface/RangeLengthData.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAGH,+CAA8C;AAC9C,qDAAkD;AAElD;;;;;;;;;;;GAWG;AACH,MAAa,eAAe;IAC1B,kEAAkE;IAC3D,KAAK,CAAU;IACtB,MAAM;IACC,KAAK,CAAY;IACjB,KAAK,CAAY;IACjB,KAAK,CAAY;IACxB;QACE,IAAI,CAAC,KAAK,GAAG,eAAO,CAAC,UAAU,EAAE,CAAC;QAClC,IAAI,CAAC,KAAK,GAAG,IAAI,qBAAS,EAAE,CAAC;QAC7B,IAAI,CAAC,KAAK,GAAG,IAAI,qBAAS,EAAE,CAAC;QAC7B,IAAI,CAAC,KAAK,GAAG,IAAI,qBAAS,EAAE,CAAC;QAC7B,IAAI,CAAC,UAAU,GAAG,eAAO,CAAC,UAAU,EAAE,CAAC;IACzC,CAAC;IACO,UAAU,CAAU;IAC5B,2EAA2E;IACpE,+BAA+B,CAAC,MAAwB;QAC7D,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;QACjC,IAAI,CAAC,KAAK,CAAC,WAAW,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;QACxC,IAAI,CAAC,KAAK,CAAC,UAAU,CAAC,IAAI,CAAC,UAAU,CAAC,OAAO,EAAE,CAAC,CAAC;QACjD,IAAI,CAAC,KAAK,CAAC,UAAU,CAAC,IAAI,CAAC,UAAU,CAAC,OAAO,EAAE,CAAC,CAAC;QACjD,IAAI,CAAC,KAAK,CAAC,UAAU,CAAC,IAAI,CAAC,UAAU,CAAC,OAAO,EAAE,CAAC,CAAC;IACnD,CAAC;CACF;AAvBD,0CAuBC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module RangeSearch\n */\n\nimport { GrowableXYZArray } from \"../geometry3d/GrowableXYZArray\";\nimport { Range3d } from \"../geometry3d/Range\";\nimport { UsageSums } from \"../numerics/UsageSums\";\n\n/**\n * Accumulated data for x,y,z length statistics in ranges.\n * * Usage pattern:\n * * create a enw RangeLengthData:\n * * `myData = new RangeLengthData ();`\n * * announce ranges to be accumulated:\n * * (many times) `myData.accumulateRowableXYZArrayRange (points);\n * * access data in public members:\n * * `myData.range` -- the composite range.\n * * `myData.xLength`, `myData.yLength`, `myData.zLength` -- mean, minMax, count, and standardDeviation of range lengths in x,y,z directions.\n * @public\n */\nexport class RangeLengthData {\n /** Overall range of all data observed by `accumulate` methods. */\n public range: Range3d;\n /** */\n public xSums: UsageSums;\n public ySums: UsageSums;\n public zSums: UsageSums;\n public constructor() {\n this.range = Range3d.createNull();\n this.xSums = new UsageSums();\n this.ySums = new UsageSums();\n this.zSums = new UsageSums();\n this._workRange = Range3d.createNull();\n }\n private _workRange: Range3d;\n /** Extend the range and length sums by the range of points in an array. */\n public accumulateGrowableXYZArrayRange(points: GrowableXYZArray) {\n points.setRange(this._workRange);\n this.range.extendRange(this._workRange);\n this.xSums.accumulate(this._workRange.xLength());\n this.ySums.accumulate(this._workRange.yLength());\n this.zSums.accumulate(this._workRange.zLength());\n }\n}\n"]}
1
+ {"version":3,"file":"RangeLengthData.js","sourceRoot":"","sources":["../../../src/polyface/RangeLengthData.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAGH,+CAA8C;AAC9C,qDAAkD;AAElD;;;;;;;;;;;GAWG;AACH,MAAa,eAAe;IAC1B,kEAAkE;IAC3D,KAAK,CAAU;IACtB,MAAM;IACC,KAAK,CAAY;IACjB,KAAK,CAAY;IACjB,KAAK,CAAY;IACxB;QACE,IAAI,CAAC,KAAK,GAAG,eAAO,CAAC,UAAU,EAAE,CAAC;QAClC,IAAI,CAAC,KAAK,GAAG,IAAI,qBAAS,EAAE,CAAC;QAC7B,IAAI,CAAC,KAAK,GAAG,IAAI,qBAAS,EAAE,CAAC;QAC7B,IAAI,CAAC,KAAK,GAAG,IAAI,qBAAS,EAAE,CAAC;QAC7B,IAAI,CAAC,UAAU,GAAG,eAAO,CAAC,UAAU,EAAE,CAAC;IACzC,CAAC;IACO,UAAU,CAAU;IAC5B,2EAA2E;IACpE,+BAA+B,CAAC,MAAwB;QAC7D,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;QACjC,IAAI,CAAC,KAAK,CAAC,WAAW,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;QACxC,IAAI,CAAC,KAAK,CAAC,UAAU,CAAC,IAAI,CAAC,UAAU,CAAC,OAAO,EAAE,CAAC,CAAC;QACjD,IAAI,CAAC,KAAK,CAAC,UAAU,CAAC,IAAI,CAAC,UAAU,CAAC,OAAO,EAAE,CAAC,CAAC;QACjD,IAAI,CAAC,KAAK,CAAC,UAAU,CAAC,IAAI,CAAC,UAAU,CAAC,OAAO,EAAE,CAAC,CAAC;IACnD,CAAC;CACF;AAvBD,0CAuBC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module RangeSearch\r\n */\r\n\r\nimport { GrowableXYZArray } from \"../geometry3d/GrowableXYZArray\";\r\nimport { Range3d } from \"../geometry3d/Range\";\r\nimport { UsageSums } from \"../numerics/UsageSums\";\r\n\r\n/**\r\n * Accumulated data for x,y,z length statistics in ranges.\r\n * * Usage pattern:\r\n * * create a enw RangeLengthData:\r\n * * `myData = new RangeLengthData ();`\r\n * * announce ranges to be accumulated:\r\n * * (many times) `myData.accumulateRowableXYZArrayRange (points);\r\n * * access data in public members:\r\n * * `myData.range` -- the composite range.\r\n * * `myData.xLength`, `myData.yLength`, `myData.zLength` -- mean, minMax, count, and standardDeviation of range lengths in x,y,z directions.\r\n * @public\r\n */\r\nexport class RangeLengthData {\r\n /** Overall range of all data observed by `accumulate` methods. */\r\n public range: Range3d;\r\n /** */\r\n public xSums: UsageSums;\r\n public ySums: UsageSums;\r\n public zSums: UsageSums;\r\n public constructor() {\r\n this.range = Range3d.createNull();\r\n this.xSums = new UsageSums();\r\n this.ySums = new UsageSums();\r\n this.zSums = new UsageSums();\r\n this._workRange = Range3d.createNull();\r\n }\r\n private _workRange: Range3d;\r\n /** Extend the range and length sums by the range of points in an array. */\r\n public accumulateGrowableXYZArrayRange(points: GrowableXYZArray) {\r\n points.setRange(this._workRange);\r\n this.range.extendRange(this._workRange);\r\n this.xSums.accumulate(this._workRange.xLength());\r\n this.ySums.accumulate(this._workRange.yLength());\r\n this.zSums.accumulate(this._workRange.zLength());\r\n }\r\n}\r\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"LineString3dRangeTreeContext.js","sourceRoot":"","sources":["../../../../src/polyface/RangeTree/LineString3dRangeTreeContext.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAGH,2DAAwD;AACxD,6CAA0C;AAE1C,kDAAiD;AACjD,mDAA8D;AAC9D,uEAEmC;AAEnC;;;;GAIG;AACH,MAAa,4BAA4B;IACvC,gEAAgE;IACzD,UAAU,CAAe;IAEhC,gEAAgE;IACzD,gBAAgB,CAAS;IAChC,iEAAiE;IAC1D,iBAAiB,CAAS;IACjC,0CAA0C;IACnC,YAAY,CAAS;IAC5B,sCAAsC;IAC/B,SAAS,CAAS;IAEzB,6EAA6E;IACrE,cAAc,CAAwB;IAE9C,6DAA6D;IAC7D,YAAoB,aAAoC,EAAE,MAAoB;QAC5E,IAAI,CAAC,UAAU,GAAG,MAAM,CAAC;QACzB,IAAI,CAAC,cAAc,GAAG,aAAa,CAAC;QACpC,IAAI,CAAC,gBAAgB,GAAG,CAAC,CAAC;QAC1B,IAAI,CAAC,iBAAiB,GAAG,CAAC,CAAC;QAC3B,IAAI,CAAC,YAAY,GAAG,CAAC,CAAC;QACtB,IAAI,CAAC,SAAS,GAAG,CAAC,CAAC;IACrB,CAAC;IACD;;;;;;;OAOG;IACI,MAAM,CAAC,aAAa,CAAC,MAAgC,EAAE,kBAA0B,CAAC,EAAE,oBAA4B,CAAC;QACtH,MAAM,UAAU,GAAG,MAAM,YAAY,2BAAY,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,2BAAY,CAAC,YAAY,CAAC,MAAM,CAAC,CAAC;QAC/F,MAAM,aAAa,GAAG,4BAAY,CAAC,mBAAmB,CACpD,CAAC,CAAC,KAAa,EAAW,EAAE,GAAG,OAAO,eAAO,CAAC,MAAM,CAAC,UAAU,CAAC,OAAO,CAAC,KAAK,CAAE,EAAE,UAAU,CAAC,OAAO,CAAC,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AAU,CAAC,MAAM,IAAI,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,aAAa,EAAE,CAAC;IACpG,CAAC;IACD;;;;;;MAME;IACK,MAAM,CAAC,wBAAwB,CAAC,QAAsC,EAAE,QAAsC,EAAE,OAAgB;QACrI,MAAM,OAAO,GAAG,IAAI,sFAA4D,CAAC,QAAQ,EAAE,QAAQ,EAAE,OAAO,CAAC,CAAC;QAC9G,6BAAa,CAAC,qBAAqB,CAAC,QAAQ,CAAC,cAAc,EAAE,QAAQ,CAAC,cAAc,EAAE,OAAO,CAAC,CAAC;QAC/F,OAAO,OAAO,CAAC,WAAW,CAAC,UAAU,CAAC,MAAM,IAAI,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,aAAa,EAAE,CAAC;IACpG,CAAC;CACF;AA3ED,oEA2EC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module RangeSearch\n */\n\nimport { CurveLocationDetail, CurveLocationDetailPair } from \"../../curve/CurveLocationDetail\";\nimport { LineString3d } from \"../../curve/LineString3d\";\nimport { Geometry } from \"../../Geometry\";\nimport { Point3d } from \"../../geometry3d/Point3dVector3d\";\nimport { Range3d } from \"../../geometry3d/Range\";\nimport { RangeTreeNode, RangeTreeOps } from \"./RangeTreeNode\";\nimport {\n SingleTreeSearchHandlerForClosestPointOnLineString3d, TwoTreeSearchHandlerForLineString3dLineString3dCloseApproach,\n} from \"./RangeTreeSearchHandlers\";\n\n/**\n * Handler class for searching a range tree containing the segments of a linestring.\n * * Facilitates multiple searches for closest point and close approach calculations.\n * @public\n */\nexport class LineString3dRangeTreeContext {\n /** Polyline points being searched, indexed by the range tree */\n public lineString: LineString3d;\n\n /** Diagnostic: number of range tests that have returned true */\n public numRangeTestTrue: number;\n /** Diagnostic: number of range tests that have returned false */\n public numRangeTestFalse: number;\n /** Diagnostic: number of points tested */\n public numPointTest: number;\n /** Diagnostic: number of searches. */\n public numSearch: number;\n\n /** Range tree, whose appData are indices into the linestring points array */\n private _rangeTreeRoot: RangeTreeNode<number>;\n\n /** Constructor: capture inputs, initialize debug counters */\n private constructor(rangeTreeRoot: RangeTreeNode<number>, points: LineString3d) {\n this.lineString = points;\n this._rangeTreeRoot = rangeTreeRoot;\n this.numRangeTestTrue = 0;\n this.numRangeTestFalse = 0;\n this.numPointTest = 0;\n this.numSearch = 0;\n }\n /**\n * Create a range tree context for the polyline points:\n * * initialize with segment ranges\n * * appData are segment indices\n * @param linestring captured if LineString3d, otherwise copied\n * @param maxChildPerNode maximum children per range tree node (default 4)\n * @param maxAppDataPerLeaf maximum segment indices per leaf node (default 4)\n */\n public static createCapture(points: Point3d[] | LineString3d, maxChildPerNode: number = 4, maxAppDataPerLeaf: number = 4): LineString3dRangeTreeContext | undefined {\n const linestring = points instanceof LineString3d ? points : LineString3d.createPoints(points);\n const rangeTreeRoot = RangeTreeOps.createByIndexSplits<number>(\n ((index: number): Range3d => { return Range3d.create(linestring.pointAt(index)!, linestring.pointAt(index + 1)!); }),\n ((index: number): number => { return index; }),\n linestring.numPoints() - 1, // number of segments\n maxChildPerNode,\n maxAppDataPerLeaf,\n );\n return rangeTreeRoot ? new LineString3dRangeTreeContext(rangeTreeRoot, linestring) : undefined;\n }\n /**\n * Search the range tree for closest point(s) to spacePoint.\n * @param spacePoint point to test\n * @param maxDist collect points at no more than this distance from spacePoint. If undefined, return only the closest point.\n * @return closest point detail(s) with detail.a set to the distance from spacePoint to detail.point\n */\n public searchForClosestPoint(spacePoint: Point3d, maxDist?: number): CurveLocationDetail | CurveLocationDetail[] | undefined {\n const handler = new SingleTreeSearchHandlerForClosestPointOnLineString3d(spacePoint, this, maxDist);\n this.numSearch++;\n // seed the search with a few segments -- this reduces early trips deep into ranges that are far from spacePoint.\n const numTest = Geometry.clamp(Math.floor(this.lineString.numPoints() / 20), 2, 7);\n const testStep = Math.floor(this.lineString.numPoints() / numTest);\n handler.processAppData(0);\n handler.processAppData(this.lineString.numPoints() - 2);\n for (let i = testStep; i + 1 < this.lineString.numPoints(); i += testStep)\n handler.processAppData(i);\n this._rangeTreeRoot.searchTopDown(handler);\n return handler.searchState.savedItems.length <= 1 ? handler.getResult() : handler.getSavedItems();\n }\n /**\n * Search the range trees for closest approach(es) between the polylines.\n * @param contextA first polyline context\n * @param contextB second polyline context\n * @param maxDist collect close approaches separated by no more than this distance. If undefined, return only the closest approach.\n * @return closest approach detail pair(s), one per context, with detail.a set to the approach distance\n */\n public static searchForClosestApproach(contextA: LineString3dRangeTreeContext, contextB: LineString3dRangeTreeContext, maxDist?: number): CurveLocationDetailPair | CurveLocationDetailPair[] | undefined {\n const handler = new TwoTreeSearchHandlerForLineString3dLineString3dCloseApproach(contextA, contextB, maxDist);\n RangeTreeNode.searchTwoTreesTopDown(contextA._rangeTreeRoot, contextB._rangeTreeRoot, handler);\n return handler.searchState.savedItems.length <= 1 ? handler.getResult() : handler.getSavedItems();\n }\n}\n"]}
1
+ {"version":3,"file":"LineString3dRangeTreeContext.js","sourceRoot":"","sources":["../../../../src/polyface/RangeTree/LineString3dRangeTreeContext.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAGH,2DAAwD;AACxD,6CAA0C;AAE1C,kDAAiD;AACjD,mDAA8D;AAC9D,uEAEmC;AAEnC;;;;GAIG;AACH,MAAa,4BAA4B;IACvC,gEAAgE;IACzD,UAAU,CAAe;IAEhC,gEAAgE;IACzD,gBAAgB,CAAS;IAChC,iEAAiE;IAC1D,iBAAiB,CAAS;IACjC,0CAA0C;IACnC,YAAY,CAAS;IAC5B,sCAAsC;IAC/B,SAAS,CAAS;IAEzB,6EAA6E;IACrE,cAAc,CAAwB;IAE9C,6DAA6D;IAC7D,YAAoB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AC,OAAO,CAAC,aAAa,EAAE,CAAC;IACpG,CAAC;CACF;AA3ED,oEA2EC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module RangeSearch\r\n */\r\n\r\nimport { CurveLocationDetail, CurveLocationDetailPair } from \"../../curve/CurveLocationDetail\";\r\nimport { LineString3d } from \"../../curve/LineString3d\";\r\nimport { Geometry } from \"../../Geometry\";\r\nimport { Point3d } from \"../../geometry3d/Point3dVector3d\";\r\nimport { Range3d } from \"../../geometry3d/Range\";\r\nimport { RangeTreeNode, RangeTreeOps } from \"./RangeTreeNode\";\r\nimport {\r\n SingleTreeSearchHandlerForClosestPointOnLineString3d, TwoTreeSearchHandlerForLineString3dLineString3dCloseApproach,\r\n} from \"./RangeTreeSearchHandlers\";\r\n\r\n/**\r\n * Handler class for searching a range tree containing the segments of a linestring.\r\n * * Facilitates multiple searches for closest point and close approach calculations.\r\n * @public\r\n */\r\nexport class LineString3dRangeTreeContext {\r\n /** Polyline points being searched, indexed by the range tree */\r\n public lineString: LineString3d;\r\n\r\n /** Diagnostic: number of range tests that have returned true */\r\n public numRangeTestTrue: number;\r\n /** Diagnostic: number of range tests that have returned false */\r\n public numRangeTestFalse: number;\r\n /** Diagnostic: number of points tested */\r\n public numPointTest: number;\r\n /** Diagnostic: number of searches. */\r\n public numSearch: number;\r\n\r\n /** Range tree, whose appData are indices into the linestring points array */\r\n private _rangeTreeRoot: RangeTreeNode<number>;\r\n\r\n /** Constructor: capture inputs, initialize debug counters */\r\n private constructor(rangeTreeRoot: RangeTreeNode<number>, points: LineString3d) {\r\n this.lineString = points;\r\n this._rangeTreeRoot = rangeTreeRoot;\r\n this.numRangeTestTrue = 0;\r\n this.numRangeTestFalse = 0;\r\n this.numPointTest = 0;\r\n this.numSearch = 0;\r\n }\r\n /**\r\n * Create a range tree context for the polyline points:\r\n * * initialize with segment ranges\r\n * * appData are segment indices\r\n * @param linestring captured if LineString3d, otherwise copied\r\n * @param maxChildPerNode maximum children per range tree node (default 4)\r\n * @param maxAppDataPerLeaf maximum segment indices per leaf node (default 4)\r\n */\r\n public static createCapture(points: Point3d[] | LineString3d, maxChildPerNode: number = 4, maxAppDataPerLeaf: number = 4): LineString3dRangeTreeContext | undefined {\r\n const linestring = points instanceof LineString3d ? points : LineString3d.createPoints(points);\r\n const rangeTreeRoot = RangeTreeOps.createByIndexSplits<number>(\r\n ((index: number): Range3d => { return Range3d.create(linestring.pointAt(index)!, linestring.pointAt(index + 1)!); }),\r\n ((index: number): number => { return index; }),\r\n linestring.numPoints() - 1, // number of segments\r\n maxChildPerNode,\r\n maxAppDataPerLeaf,\r\n );\r\n return rangeTreeRoot ? new LineString3dRangeTreeContext(rangeTreeRoot, linestring) : undefined;\r\n }\r\n /**\r\n * Search the range tree for closest point(s) to spacePoint.\r\n * @param spacePoint point to test\r\n * @param maxDist collect points at no more than this distance from spacePoint. If undefined, return only the closest point.\r\n * @return closest point detail(s) with detail.a set to the distance from spacePoint to detail.point\r\n */\r\n public searchForClosestPoint(spacePoint: Point3d, maxDist?: number): CurveLocationDetail | CurveLocationDetail[] | undefined {\r\n const handler = new SingleTreeSearchHandlerForClosestPointOnLineString3d(spacePoint, this, maxDist);\r\n this.numSearch++;\r\n // seed the search with a few segments -- this reduces early trips deep into ranges that are far from spacePoint.\r\n const numTest = Geometry.clamp(Math.floor(this.lineString.numPoints() / 20), 2, 7);\r\n const testStep = Math.floor(this.lineString.numPoints() / numTest);\r\n handler.processAppData(0);\r\n handler.processAppData(this.lineString.numPoints() - 2);\r\n for (let i = testStep; i + 1 < this.lineString.numPoints(); i += testStep)\r\n handler.processAppData(i);\r\n this._rangeTreeRoot.searchTopDown(handler);\r\n return handler.searchState.savedItems.length <= 1 ? handler.getResult() : handler.getSavedItems();\r\n }\r\n /**\r\n * Search the range trees for closest approach(es) between the polylines.\r\n * @param contextA first polyline context\r\n * @param contextB second polyline context\r\n * @param maxDist collect close approaches separated by no more than this distance. If undefined, return only the closest approach.\r\n * @return closest approach detail pair(s), one per context, with detail.a set to the approach distance\r\n */\r\n public static searchForClosestApproach(contextA: LineString3dRangeTreeContext, contextB: LineString3dRangeTreeContext, maxDist?: number): CurveLocationDetailPair | CurveLocationDetailPair[] | undefined {\r\n const handler = new TwoTreeSearchHandlerForLineString3dLineString3dCloseApproach(contextA, contextB, maxDist);\r\n RangeTreeNode.searchTwoTreesTopDown(contextA._rangeTreeRoot, contextB._rangeTreeRoot, handler);\r\n return handler.searchState.savedItems.length <= 1 ? handler.getResult() : handler.getSavedItems();\r\n }\r\n}\r\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"MinimumValueTester.js","sourceRoot":"","sources":["../../../../src/polyface/RangeTree/MinimumValueTester.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH;;;;;;GAMG;AACH,MAAa,kBAAkB;IACtB,cAAc,CAAgB;IAC9B,QAAQ,CAAqB;IAC7B,uBAAuB,CAAqB;IAC5C,UAAU,GAAQ,EAAE,CAAC;IACrB,WAAW,GAAa,EAAE,CAAC;IAClC;;OAEG;IACH,YAAoB,wBAAiC;QACnD,IAAI,CAAC,oBAAoB,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC;QAChD,IAAI,CAAC,iCAAiC,CAAC,wBAAwB,EAAE,KAAK,CAAC,CAAC;IAC1E,CAAC;IACD;;;;OAIG;IACI,MAAM,CAAC,MAAM,CAAI,wBAAiC;QACvD,OAAO,IAAI,kBAAkB,CAAI,wBAAwB,CAAC,CAAC;IAC7D,CAAC;IACD;;;;;OAKG;IACI,oBAAoB,CAAC,OAAsB,SAAS,EAAE,QAA4B,SAAS;QAChG,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC;QAC3B,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC;IACxB,CAAC;IACD;;;;OAIG;IACI,iCAAiC,CAAC,KAAyB,EAAE,qBAA8B,KAAK;QACrG,IAAI,CAAC,uBAAuB,GAAG,KAAK,CAAC;QACrC,IAAI,kBAAkB,EAAE,CAAC;YACvB,IAAI,CAAC,UAAU,GAAG,EAAE,CAAC;YACrB,IAAI,CAAC,WAAW,GAAG,EAAE,CAAC;QACxB,CAAC;IACH,CAAC;IACD;;;;;;;;;;;OAWG;IACI,WAAW,CAAC,IAAO,EAAE,KAAa;QACvC,IAAI,IAAI,CAAC,gBAAgB,CAAC,KAAK,CAAC,EAAE,CAAC;YACjC,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;YAC7B,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAC7B,CAAC;QACD,IAAI,IAAI,CAAC,aAAa,CAAC,KAAK,CAAC,EAAE,CAAC;YAC9B,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC;YACtB,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC;YAC3B,OAAO,IAAI,CAAC;QACd,CAAC;QACD,OAAO,KAAK,CAAC;IACf,CAAC;IACD,4EAA4E;IACrE,gBAAgB,CAAC,KAAa;QACnC,OAAO,IAAI,CAAC,uBAAuB,KAAK,SAAS,IAAI,KAAK,IAAI,IAAI,CAAC,uBAAuB,CAAC;IAC7F,CAAC;IACD,+EAA+E;IACxE,aAAa,CAAC,KAAa;QAChC,OAAO,IAAI,CAAC,QAAQ,KAAK,SAAS,IAAI,KAAK,GAAG,IAAI,CAAC,QAAQ,CAAC;IAC9D,CAAC;IACD,qGAAqG;IAC9F,iBAAiB,CAAC,KAAa;QACpC,OAAO,IAAI,CAAC,aAAa,CAAC,KAAK,CAAC,IAAI,IAAI,CAAC,gBAAgB,CAAC,KAAK,CAAC,CAAC;IACnE,CAAC;CACF;AA/ED,gDA+EC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module CartesianGeometry\n */\n\n/**\n * Data carrier for use when repeatedly testing items (of parameterized type T) to determine the one with a minimum associated value.\n * * Optionally pushes to arrays of items and values when the value does not exceed a given trigger.\n * * * The item at minimum value is still recorded, even if the minimum value exceeds the trigger value.\n * * When comparing a potential minimum value to an undefined value, the number is always accepted as the new minimum.\n * @internal\n */\nexport class MinimumValueTester<T>{\n public itemAtMinValue: T | undefined;\n public minValue: number | undefined;\n public triggerForSavingToArray: number | undefined;\n public savedItems: T[] = [];\n public savedValues: number[] = [];\n /**\n * Capture the given item with undefined item and value, and optional maxValueForSavingToArray.\n */\n private constructor(maxValueForSavingToArray?: number) {\n this.resetMinValueAndItem(undefined, undefined);\n this.resetTriggerValueForSavingToArray(maxValueForSavingToArray, false);\n }\n /**\n * Static method to create a tester.\n * @param maxValueForSavingToArray optional numeric value limiting items to save to the optional array.\n * @returns new tester.\n */\n public static create<T>(maxValueForSavingToArray?: number): MinimumValueTester<T> {\n return new MinimumValueTester<T>(maxValueForSavingToArray);\n }\n /**\n * Install new minimum value and associated item, both possibly undefined.\n * * The existing arrays of saved items and values, and the trigger value, are unaffected.\n * @param item object to associate with the new minimum value\n * @param value new minimum value\n */\n public resetMinValueAndItem(item: T | undefined = undefined, value: number | undefined = undefined) {\n this.itemAtMinValue = item;\n this.minValue = value;\n }\n /**\n * Set the trigger value.\n * @param value new trigger value\n * @param reinitializeArrays whether to clear the arrays of saved items and values\n */\n public resetTriggerValueForSavingToArray(value: number | undefined, reinitializeArrays: boolean = false) {\n this.triggerForSavingToArray = value;\n if (reinitializeArrays) {\n this.savedItems = [];\n this.savedValues = [];\n }\n }\n /**\n * Test a new item with value.\n * * Push the new item and value to the saved arrays if both:\n * * `this.triggerForSavingToArray` is defined\n * * the new value is less than or equal to `this.triggerForSavingToArray`.\n * * Save the new item and value if either:\n * * `this.minValue` is undefined\n * * new value is less than `this.minValue`.\n * @param item item to be saved (captured!) if value conditions are met\n * @param value numeric value being minimized.\n * @returns true if and only if the input value is the new minimum value.\n */\n public testAndSave(item: T, value: number): boolean {\n if (this.doesValueTrigger(value)) {\n this.savedValues.push(value);\n this.savedItems.push(item);\n }\n if (this.isNewMinValue(value)) {\n this.minValue = value;\n this.itemAtMinValue = item;\n return true;\n }\n return false;\n }\n /** Whether the input value is small enough to be saved to this instance. */\n public doesValueTrigger(value: number): boolean {\n return this.triggerForSavingToArray !== undefined && value <= this.triggerForSavingToArray;\n }\n /** Whether the input value is smaller than the last recorded minimum value. */\n public isNewMinValue(value: number): boolean {\n return this.minValue === undefined || value < this.minValue;\n }\n /** Whether the input value is small enough to be the new minimum or to be saved to this instance. */\n public isNewMinOrTrigger(value: number): boolean {\n return this.isNewMinValue(value) || this.doesValueTrigger(value);\n }\n}\n"]}
1
+ {"version":3,"file":"MinimumValueTester.js","sourceRoot":"","sources":["../../../../src/polyface/RangeTree/MinimumValueTester.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH;;;;;;GAMG;AACH,MAAa,kBAAkB;IACtB,cAAc,CAAgB;IAC9B,QAAQ,CAAqB;IAC7B,uBAAuB,CAAqB;IAC5C,UAAU,GAAQ,EAAE,CAAC;IACrB,WAAW,GAAa,EAAE,CAAC;IAClC;;OAEG;IACH,YAAoB,wBAAiC;QACnD,IAAI,CAAC,oBAAoB,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC;QAChD,IAAI,CAAC,iCAAiC,CAAC,wBAAwB,EAAE,KAAK,CAAC,CAAC;IAC1E,CAAC;IACD;;;;OAIG;IACI,MAAM,CAAC,MAAM,CAAI,wBAAiC;QACvD,OAAO,IAAI,kBAAkB,CAAI,wBAAwB,CAAC,CAAC;IAC7D,CAAC;IACD;;;;;OAKG;IACI,oBAAoB,CAAC,OAAsB,SAAS,EAAE,QAA4B,SAAS;QAChG,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC;QAC3B,IAA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------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module CartesianGeometry\r\n */\r\n\r\n/**\r\n * Data carrier for use when repeatedly testing items (of parameterized type T) to determine the one with a minimum associated value.\r\n * * Optionally pushes to arrays of items and values when the value does not exceed a given trigger.\r\n * * * The item at minimum value is still recorded, even if the minimum value exceeds the trigger value.\r\n * * When comparing a potential minimum value to an undefined value, the number is always accepted as the new minimum.\r\n * @internal\r\n */\r\nexport class MinimumValueTester<T>{\r\n public itemAtMinValue: T | undefined;\r\n public minValue: number | undefined;\r\n public triggerForSavingToArray: number | undefined;\r\n public savedItems: T[] = [];\r\n public savedValues: number[] = [];\r\n /**\r\n * Capture the given item with undefined item and value, and optional maxValueForSavingToArray.\r\n */\r\n private constructor(maxValueForSavingToArray?: number) {\r\n this.resetMinValueAndItem(undefined, undefined);\r\n this.resetTriggerValueForSavingToArray(maxValueForSavingToArray, false);\r\n }\r\n /**\r\n * Static method to create a tester.\r\n * @param maxValueForSavingToArray optional numeric value limiting items to save to the optional array.\r\n * @returns new tester.\r\n */\r\n public static create<T>(maxValueForSavingToArray?: number): MinimumValueTester<T> {\r\n return new MinimumValueTester<T>(maxValueForSavingToArray);\r\n }\r\n /**\r\n * Install new minimum value and associated item, both possibly undefined.\r\n * * The existing arrays of saved items and values, and the trigger value, are unaffected.\r\n * @param item object to associate with the new minimum value\r\n * @param value new minimum value\r\n */\r\n public resetMinValueAndItem(item: T | undefined = undefined, value: number | undefined = undefined) {\r\n this.itemAtMinValue = item;\r\n this.minValue = value;\r\n }\r\n /**\r\n * Set the trigger value.\r\n * @param value new trigger value\r\n * @param reinitializeArrays whether to clear the arrays of saved items and values\r\n */\r\n public resetTriggerValueForSavingToArray(value: number | undefined, reinitializeArrays: boolean = false) {\r\n this.triggerForSavingToArray = value;\r\n if (reinitializeArrays) {\r\n this.savedItems = [];\r\n this.savedValues = [];\r\n }\r\n }\r\n /**\r\n * Test a new item with value.\r\n * * Push the new item and value to the saved arrays if both:\r\n * * `this.triggerForSavingToArray` is defined\r\n * * the new value is less than or equal to `this.triggerForSavingToArray`.\r\n * * Save the new item and value if either:\r\n * * `this.minValue` is undefined\r\n * * new value is less than `this.minValue`.\r\n * @param item item to be saved (captured!) if value conditions are met\r\n * @param value numeric value being minimized.\r\n * @returns true if and only if the input value is the new minimum value.\r\n */\r\n public testAndSave(item: T, value: number): boolean {\r\n if (this.doesValueTrigger(value)) {\r\n this.savedValues.push(value);\r\n this.savedItems.push(item);\r\n }\r\n if (this.isNewMinValue(value)) {\r\n this.minValue = value;\r\n this.itemAtMinValue = item;\r\n return true;\r\n }\r\n return false;\r\n }\r\n /** Whether the input value is small enough to be saved to this instance. */\r\n public doesValueTrigger(value: number): boolean {\r\n return this.triggerForSavingToArray !== undefined && value <= this.triggerForSavingToArray;\r\n }\r\n /** Whether the input value is smaller than the last recorded minimum value. */\r\n public isNewMinValue(value: number): boolean {\r\n return this.minValue === undefined || value < this.minValue;\r\n }\r\n /** Whether the input value is small enough to be the new minimum or to be saved to this instance. */\r\n public isNewMinOrTrigger(value: number): boolean {\r\n return this.isNewMinValue(value) || this.doesValueTrigger(value);\r\n }\r\n}\r\n"]}
@@ -2,7 +2,7 @@
2
2
  * @module RangeSearch
3
3
  */
4
4
  import { CurveLocationDetail, CurveLocationDetailPair } from "../../curve/CurveLocationDetail";
5
- import { Point3d } from "../../geometry3d/Point3dVector3d";
5
+ import { XAndY, XYAndZ } from "../../geometry3d/XYZProps";
6
6
  /**
7
7
  * Handler class for searching a range tree containing unordered Point3d data.
8
8
  * * Facilitates multiple searches for closest point and close approach calculations.
@@ -10,7 +10,7 @@ import { Point3d } from "../../geometry3d/Point3dVector3d";
10
10
  */
11
11
  export declare class Point3dArrayRangeTreeContext {
12
12
  /** Array of points being searched, indexed by the range tree */
13
- points: Point3d[];
13
+ points: XYAndZ[];
14
14
  /** Diagnostic: number of range tests returned true */
15
15
  numRangeTestTrue: number;
16
16
  /** Diagnostic: number of range tests returned false */
@@ -19,6 +19,8 @@ export declare class Point3dArrayRangeTreeContext {
19
19
  numPointTest: number;
20
20
  /** Diagnostic: number of searches */
21
21
  numSearch: number;
22
+ /** Whether to compute xy-distances, ignoring z-coordinates of points. */
23
+ xyOnly?: boolean;
22
24
  /** range tree, whose appData are indices into the points array */
23
25
  private _rangeTreeRoot;
24
26
  /** Constructor: capture inputs, initialize debug counters */
@@ -27,11 +29,12 @@ export declare class Point3dArrayRangeTreeContext {
27
29
  * Create a range tree context with given points:
28
30
  * * initialize with single-point ranges
29
31
  * * appData are point indices
30
- * @param points captured
32
+ * @param points reference captured
31
33
  * @param maxChildPerNode maximum children per range tree node (default 4)
32
34
  * @param maxAppDataPerLeaf maximum point indices per leaf node (default 4)
35
+ * @param xyOnly whether to compute xy-distances, ignoring z-coordinates of points
33
36
  */
34
- static createCapture(points: Point3d[], maxChildPerNode?: number, maxAppDataPerLeaf?: number): Point3dArrayRangeTreeContext | undefined;
37
+ static createCapture(points: XYAndZ[], maxChildPerNode?: number, maxAppDataPerLeaf?: number, xyOnly?: boolean): Point3dArrayRangeTreeContext | undefined;
35
38
  /**
36
39
  * Search the range tree for closest point(s) to spacePoint.
37
40
  * @param spacePoint point to test
@@ -41,7 +44,7 @@ export declare class Point3dArrayRangeTreeContext {
41
44
  * * detail.fraction = the index of the closest point in the points array
42
45
  * * detail.a = distance from spacePoint to closest point
43
46
  */
44
- searchForClosestPoint(spacePoint: Point3d, maxDist?: number): CurveLocationDetail | CurveLocationDetail[] | undefined;
47
+ searchForClosestPoint(spacePoint: XAndY | XYAndZ, maxDist?: number): CurveLocationDetail | CurveLocationDetail[] | undefined;
45
48
  /**
46
49
  * Search the range trees for closest approach(es) between the point arrays.
47
50
  * @param contextA first point array context
@@ -1 +1 @@
1
- {"version":3,"file":"Point3dArrayRangeTreeContext.d.ts","sourceRoot":"","sources":["../../../../src/polyface/RangeTree/Point3dArrayRangeTreeContext.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,mBAAmB,EAAE,uBAAuB,EAAE,MAAM,iCAAiC,CAAC;AAC/F,OAAO,EAAE,OAAO,EAAE,MAAM,kCAAkC,CAAC;AAO3D;;;;GAIG;AACH,qBAAa,4BAA4B;IACvC,gEAAgE;IACzD,MAAM,EAAE,OAAO,EAAE,CAAC;IAEzB,sDAAsD;IAC/C,gBAAgB,EAAE,MAAM,CAAC;IAChC,uDAAuD;IAChD,iBAAiB,EAAE,MAAM,CAAC;IACjC,iDAAiD;IAC1C,YAAY,EAAE,MAAM,CAAC;IAC5B,qCAAqC;IAC9B,SAAS,EAAE,MAAM,CAAC;IAEzB,kEAAkE;IAClE,OAAO,CAAC,cAAc,CAAwB;IAE9C,6DAA6D;IAC7D,OAAO;IAQP;;;;;;;OAOG;WACW,aAAa,CAAC,MAAM,EAAE,OAAO,EAAE,EAAE,eAAe,GAAE,MAAU,EAAE,iBAAiB,GAAE,MAAU,GAAG,4BAA4B,GAAG,SAAS;IAUpJ;;;;;;;;OAQG;IACI,qBAAqB,CAAC,UAAU,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,MAAM,GAAG,mBAAmB,GAAG,mBAAmB,EAAE,GAAG,SAAS;IAM5H;;;;;;;;;MASE;WACY,wBAAwB,CAAC,QAAQ,EAAE,4BAA4B,EAAE,QAAQ,EAAE,4BAA4B,EAAE,OAAO,CAAC,EAAE,MAAM,GAAG,uBAAuB,GAAG,uBAAuB,EAAE,GAAG,SAAS;CAK1M"}
1
+ {"version":3,"file":"Point3dArrayRangeTreeContext.d.ts","sourceRoot":"","sources":["../../../../src/polyface/RangeTree/Point3dArrayRangeTreeContext.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,mBAAmB,EAAE,uBAAuB,EAAE,MAAM,iCAAiC,CAAC;AAE/F,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,2BAA2B,CAAC;AAM1D;;;;GAIG;AACH,qBAAa,4BAA4B;IACvC,gEAAgE;IACzD,MAAM,EAAE,MAAM,EAAE,CAAC;IAExB,sDAAsD;IAC/C,gBAAgB,EAAE,MAAM,CAAC;IAChC,uDAAuD;IAChD,iBAAiB,EAAE,MAAM,CAAC;IACjC,iDAAiD;IAC1C,YAAY,EAAE,MAAM,CAAC;IAC5B,qCAAqC;IAC9B,SAAS,EAAE,MAAM,CAAC;IACzB,yEAAyE;IAClE,MAAM,CAAC,EAAE,OAAO,CAAC;IAExB,kEAAkE;IAClE,OAAO,CAAC,cAAc,CAAwB;IAE9C,6DAA6D;IAC7D,OAAO;IASP;;;;;;;;OAQG;WACW,aAAa,CAAC,MAAM,EAAE,MAAM,EAAE,EAAE,eAAe,GAAE,MAAU,EAAE,iBAAiB,GAAE,MAAU,EAAE,MAAM,GAAE,OAAe,GAAG,4BAA4B,GAAG,SAAS;IAU5K;;;;;;;;OAQG;IACI,qBAAqB,CAAC,UAAU,EAAE,KAAK,GAAG,MAAM,EAAE,OAAO,CAAC,EAAE,MAAM,GAAG,mBAAmB,GAAG,mBAAmB,EAAE,GAAG,SAAS;IAMnI;;;;;;;;;MASE;WACY,wBAAwB,CAAC,QAAQ,EAAE,4BAA4B,EAAE,QAAQ,EAAE,4BAA4B,EAAE,OAAO,CAAC,EAAE,MAAM,GAAG,uBAAuB,GAAG,uBAAuB,EAAE,GAAG,SAAS;CAK1M"}
@@ -27,28 +27,32 @@ class Point3dArrayRangeTreeContext {
27
27
  numPointTest;
28
28
  /** Diagnostic: number of searches */
29
29
  numSearch;
30
+ /** Whether to compute xy-distances, ignoring z-coordinates of points. */
31
+ xyOnly;
30
32
  /** range tree, whose appData are indices into the points array */
31
33
  _rangeTreeRoot;
32
34
  /** Constructor: capture inputs, initialize debug counters */
33
- constructor(rangeTreeRoot, points) {
35
+ constructor(rangeTreeRoot, points, xyOnly) {
34
36
  this.points = points;
35
37
  this._rangeTreeRoot = rangeTreeRoot;
36
38
  this.numRangeTestTrue = 0;
37
39
  this.numRangeTestFalse = 0;
38
40
  this.numPointTest = 0;
39
41
  this.numSearch = 0;
42
+ this.xyOnly = xyOnly;
40
43
  }
41
44
  /**
42
45
  * Create a range tree context with given points:
43
46
  * * initialize with single-point ranges
44
47
  * * appData are point indices
45
- * @param points captured
48
+ * @param points reference captured
46
49
  * @param maxChildPerNode maximum children per range tree node (default 4)
47
50
  * @param maxAppDataPerLeaf maximum point indices per leaf node (default 4)
51
+ * @param xyOnly whether to compute xy-distances, ignoring z-coordinates of points
48
52
  */
49
- static createCapture(points, maxChildPerNode = 4, maxAppDataPerLeaf = 4) {
53
+ static createCapture(points, maxChildPerNode = 4, maxAppDataPerLeaf = 4, xyOnly = false) {
50
54
  const rangeTreeRoot = RangeTreeNode_1.RangeTreeOps.createByIndexSplits(((index) => { return Range_1.Range3d.create(points[index]); }), ((index) => { return index; }), points.length, maxChildPerNode, maxAppDataPerLeaf);
51
- return rangeTreeRoot ? new Point3dArrayRangeTreeContext(rangeTreeRoot, points) : undefined;
55
+ return rangeTreeRoot ? new Point3dArrayRangeTreeContext(rangeTreeRoot, points, xyOnly) : undefined;
52
56
  }
53
57
  /**
54
58
  * Search the range tree for closest point(s) to spacePoint.
@@ -1 +1 @@
1
- {"version":3,"file":"Point3dArrayRangeTreeContext.js","sourceRoot":"","sources":["../../../../src/polyface/RangeTree/Point3dArrayRangeTreeContext.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAIH,kDAAiD;AACjD,mDAA8D;AAC9D,uEAEmC;AAEnC;;;;GAIG;AACH,MAAa,4BAA4B;IACvC,gEAAgE;IACzD,MAAM,CAAY;IAEzB,sDAAsD;IAC/C,gBAAgB,CAAS;IAChC,uDAAuD;IAChD,iBAAiB,CAAS;IACjC,iDAAiD;IAC1C,YAAY,CAAS;IAC5B,qCAAqC;IAC9B,SAAS,CAAS;IAEzB,kEAAkE;IAC1D,cAAc,CAAwB;IAE9C,6DAA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E,CAAC;IACpG,CAAC;IACD;;;;;;;;;MASE;IACK,MAAM,CAAC,wBAAwB,CAAC,QAAsC,EAAE,QAAsC,EAAE,OAAgB;QACrI,MAAM,OAAO,GAAG,IAAI,sFAA4D,CAAC,QAAQ,EAAE,QAAQ,EAAE,OAAO,CAAC,CAAC;QAC9G,6BAAa,CAAC,qBAAqB,CAAC,QAAQ,CAAC,cAAc,EAAE,QAAQ,CAAC,cAAc,EAAE,OAAO,CAAC,CAAC;QAC/F,OAAO,OAAO,CAAC,WAAW,CAAC,UAAU,CAAC,MAAM,IAAI,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,aAAa,EAAE,CAAC;IACpG,CAAC;CACF;AAzED,oEAyEC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module RangeSearch\n */\n\nimport { CurveLocationDetail, CurveLocationDetailPair } from \"../../curve/CurveLocationDetail\";\nimport { Point3d } from \"../../geometry3d/Point3dVector3d\";\nimport { Range3d } from \"../../geometry3d/Range\";\nimport { RangeTreeNode, RangeTreeOps } from \"./RangeTreeNode\";\nimport {\n SingleTreeSearchHandlerForClosestPointInArray, TwoTreeSearchHandlerForPoint3dArrayPoint3dArrayCloseApproach,\n} from \"./RangeTreeSearchHandlers\";\n\n/**\n * Handler class for searching a range tree containing unordered Point3d data.\n * * Facilitates multiple searches for closest point and close approach calculations.\n * @public\n */\nexport class Point3dArrayRangeTreeContext {\n /** Array of points being searched, indexed by the range tree */\n public points: Point3d[];\n\n /** Diagnostic: number of range tests returned true */\n public numRangeTestTrue: number;\n /** Diagnostic: number of range tests returned false */\n public numRangeTestFalse: number;\n /** Diagnostic: number of point distance tests */\n public numPointTest: number;\n /** Diagnostic: number of searches */\n public numSearch: number;\n\n /** range tree, whose appData are indices into the points array */\n private _rangeTreeRoot: RangeTreeNode<number>;\n\n /** Constructor: capture inputs, initialize debug counters */\n private constructor(rangeTreeRoot: RangeTreeNode<number>, points: Point3d[]) {\n this.points = points;\n this._rangeTreeRoot = rangeTreeRoot;\n this.numRangeTestTrue = 0;\n this.numRangeTestFalse = 0;\n this.numPointTest = 0;\n this.numSearch = 0;\n }\n /**\n * Create a range tree context with given points:\n * * initialize with single-point ranges\n * * appData are point indices\n * @param points captured\n * @param maxChildPerNode maximum children per range tree node (default 4)\n * @param maxAppDataPerLeaf maximum point indices per leaf node (default 4)\n */\n public static createCapture(points: Point3d[], maxChildPerNode: number = 4, maxAppDataPerLeaf: number = 4): Point3dArrayRangeTreeContext | undefined {\n const rangeTreeRoot = RangeTreeOps.createByIndexSplits<number>(\n ((index: number): Range3d => { return Range3d.create(points[index]); }),\n ((index: number): number => { return index; }),\n points.length,\n maxChildPerNode,\n maxAppDataPerLeaf,\n );\n return rangeTreeRoot ? new Point3dArrayRangeTreeContext(rangeTreeRoot, points) : undefined;\n }\n /**\n * Search the range tree for closest point(s) to spacePoint.\n * @param spacePoint point to test\n * @param maxDist collect points at no more than this distance from spacePoint. If undefined, return only the closest point.\n * @return closest point detail(s) with following fields set:\n * * detail.point = the closest point\n * * detail.fraction = the index of the closest point in the points array\n * * detail.a = distance from spacePoint to closest point\n */\n public searchForClosestPoint(spacePoint: Point3d, maxDist?: number): CurveLocationDetail | CurveLocationDetail[] | undefined {\n const handler = new SingleTreeSearchHandlerForClosestPointInArray(spacePoint, this, maxDist);\n this.numSearch++;\n this._rangeTreeRoot.searchTopDown(handler);\n return handler.searchState.savedItems.length <= 1 ? handler.getResult() : handler.getSavedItems();\n }\n /**\n * Search the range trees for closest approach(es) between the point arrays.\n * @param contextA first point array context\n * @param contextB second point array context\n * @param maxDist collect close approaches separated by no more than this distance. If undefined, return only the closest approach.\n * @return closest approach detail pair(s), one per context, each with the following fields set:\n * * detail.point = the point at closest approach\n * * detail.fraction = the index of detail.point in the points array\n * * detail.a = the closest approach distance\n */\n public static searchForClosestApproach(contextA: Point3dArrayRangeTreeContext, contextB: Point3dArrayRangeTreeContext, maxDist?: number): CurveLocationDetailPair | CurveLocationDetailPair[] | undefined {\n const handler = new TwoTreeSearchHandlerForPoint3dArrayPoint3dArrayCloseApproach(contextA, contextB, maxDist);\n RangeTreeNode.searchTwoTreesTopDown(contextA._rangeTreeRoot, contextB._rangeTreeRoot, handler);\n return handler.searchState.savedItems.length <= 1 ? handler.getResult() : handler.getSavedItems();\n }\n}\n\n"]}
1
+ {"version":3,"file":"Point3dArrayRangeTreeContext.js","sourceRoot":"","sources":["../../../../src/polyface/RangeTree/Point3dArrayRangeTreeContext.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAGH,kDAAiD;AAEjD,mDAA8D;AAC9D,uEAEmC;AAEnC;;;;GAIG;AACH,MAAa,4BAA4B;IACvC,gEAAgE;IACzD,MAAM,CAAW;IAExB,sDAAsD;IAC/C,gBAAgB,CAAS;IAChC,uDAAuD;IAChD,iBAAiB,CAAS;IACjC,iDAAiD;IAC1C,YAAY,CAAS;IAC5B,qCAAqC;IAC9B,SAAS,CAAS;IACzB,yEAAyE;IAClE,MAAM,CAAW;IAExB,kEAAkE;IAC1D,cAAc,CAAwB;IAE9C,6DAA6D;IAC7D,YAAoB,aAAoC,EAAE,MAAgB,EAAE,MAAe;QACzF,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,cAAc,GAAG,aAAa,CAAC;QACpC,IAAI,CAAC,gBAAgB,GAAG,CAAC,CAAC;QAC1B,IAAI,CAAC,iBAAiB,GAAG,CAAC,CAAC;QAC3B,IAAI,CAAC,YAAY,GAAG,CAAC,CAAC;QACtB,IAAI,CAAC,SAAS,GAAG,CAAC,CAAC;QACnB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IACD;;;;;;;;OAQG;IACI,MAAM,CAAC,aAAa,CAAC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AW,CAAC,UAAU,CAAC,MAAM,IAAI,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,aAAa,EAAE,CAAC;IACpG,CAAC;CACF;AA7ED,oEA6EC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module RangeSearch\r\n */\r\n\r\nimport { CurveLocationDetail, CurveLocationDetailPair } from \"../../curve/CurveLocationDetail\";\r\nimport { Range3d } from \"../../geometry3d/Range\";\r\nimport { XAndY, XYAndZ } from \"../../geometry3d/XYZProps\";\r\nimport { RangeTreeNode, RangeTreeOps } from \"./RangeTreeNode\";\r\nimport {\r\n SingleTreeSearchHandlerForClosestPointInArray, TwoTreeSearchHandlerForPoint3dArrayPoint3dArrayCloseApproach,\r\n} from \"./RangeTreeSearchHandlers\";\r\n\r\n/**\r\n * Handler class for searching a range tree containing unordered Point3d data.\r\n * * Facilitates multiple searches for closest point and close approach calculations.\r\n * @public\r\n */\r\nexport class Point3dArrayRangeTreeContext {\r\n /** Array of points being searched, indexed by the range tree */\r\n public points: XYAndZ[];\r\n\r\n /** Diagnostic: number of range tests returned true */\r\n public numRangeTestTrue: number;\r\n /** Diagnostic: number of range tests returned false */\r\n public numRangeTestFalse: number;\r\n /** Diagnostic: number of point distance tests */\r\n public numPointTest: number;\r\n /** Diagnostic: number of searches */\r\n public numSearch: number;\r\n /** Whether to compute xy-distances, ignoring z-coordinates of points. */\r\n public xyOnly?: boolean;\r\n\r\n /** range tree, whose appData are indices into the points array */\r\n private _rangeTreeRoot: RangeTreeNode<number>;\r\n\r\n /** Constructor: capture inputs, initialize debug counters */\r\n private constructor(rangeTreeRoot: RangeTreeNode<number>, points: XYAndZ[], xyOnly: boolean) {\r\n this.points = points;\r\n this._rangeTreeRoot = rangeTreeRoot;\r\n this.numRangeTestTrue = 0;\r\n this.numRangeTestFalse = 0;\r\n this.numPointTest = 0;\r\n this.numSearch = 0;\r\n this.xyOnly = xyOnly;\r\n }\r\n /**\r\n * Create a range tree context with given points:\r\n * * initialize with single-point ranges\r\n * * appData are point indices\r\n * @param points reference captured\r\n * @param maxChildPerNode maximum children per range tree node (default 4)\r\n * @param maxAppDataPerLeaf maximum point indices per leaf node (default 4)\r\n * @param xyOnly whether to compute xy-distances, ignoring z-coordinates of points\r\n */\r\n public static createCapture(points: XYAndZ[], maxChildPerNode: number = 4, maxAppDataPerLeaf: number = 4, xyOnly: boolean = false): Point3dArrayRangeTreeContext | undefined {\r\n const rangeTreeRoot = RangeTreeOps.createByIndexSplits<number>(\r\n ((index: number): Range3d => { return Range3d.create(points[index]); }),\r\n ((index: number): number => { return index; }),\r\n points.length,\r\n maxChildPerNode,\r\n maxAppDataPerLeaf,\r\n );\r\n return rangeTreeRoot ? new Point3dArrayRangeTreeContext(rangeTreeRoot, points, xyOnly) : undefined;\r\n }\r\n /**\r\n * Search the range tree for closest point(s) to spacePoint.\r\n * @param spacePoint point to test\r\n * @param maxDist collect points at no more than this distance from spacePoint. If undefined, return only the closest point.\r\n * @return closest point detail(s) with following fields set:\r\n * * detail.point = the closest point\r\n * * detail.fraction = the index of the closest point in the points array\r\n * * detail.a = distance from spacePoint to closest point\r\n */\r\n public searchForClosestPoint(spacePoint: XAndY | XYAndZ, maxDist?: number): CurveLocationDetail | CurveLocationDetail[] | undefined {\r\n const handler = new SingleTreeSearchHandlerForClosestPointInArray(spacePoint, this, maxDist);\r\n this.numSearch++;\r\n this._rangeTreeRoot.searchTopDown(handler);\r\n return handler.searchState.savedItems.length <= 1 ? handler.getResult() : handler.getSavedItems();\r\n }\r\n /**\r\n * Search the range trees for closest approach(es) between the point arrays.\r\n * @param contextA first point array context\r\n * @param contextB second point array context\r\n * @param maxDist collect close approaches separated by no more than this distance. If undefined, return only the closest approach.\r\n * @return closest approach detail pair(s), one per context, each with the following fields set:\r\n * * detail.point = the point at closest approach\r\n * * detail.fraction = the index of detail.point in the points array\r\n * * detail.a = the closest approach distance\r\n */\r\n public static searchForClosestApproach(contextA: Point3dArrayRangeTreeContext, contextB: Point3dArrayRangeTreeContext, maxDist?: number): CurveLocationDetailPair | CurveLocationDetailPair[] | undefined {\r\n const handler = new TwoTreeSearchHandlerForPoint3dArrayPoint3dArrayCloseApproach(contextA, contextB, maxDist);\r\n RangeTreeNode.searchTwoTreesTopDown(contextA._rangeTreeRoot, contextB._rangeTreeRoot, handler);\r\n return handler.searchState.savedItems.length <= 1 ? handler.getResult() : handler.getSavedItems();\r\n }\r\n}\r\n\r\n"]}
@@ -1,7 +1,7 @@
1
1
  /** @packageDocumentation
2
2
  * @module RangeSearch
3
3
  */
4
- import { Point3d } from "../../geometry3d/Point3dVector3d";
4
+ import { XAndY, XYAndZ } from "../../geometry3d/XYZProps";
5
5
  import { FacetLocationDetail, FacetLocationDetailPair } from "../FacetLocationDetail";
6
6
  import { Polyface, PolyfaceVisitor } from "../Polyface";
7
7
  /**
@@ -39,11 +39,11 @@ export declare class PolyfaceRangeTreeContext {
39
39
  /**
40
40
  * Search the range tree for closest facet(s) to spacePoint.
41
41
  * @param spacePoint point to test
42
- * @param maxDist collect points at no more than this distance from spacePoint. If undefined, return only the closest point.
42
+ * @param maxDist collect facet locations at no more than this distance from spacePoint. If undefined, return only the closest facet location.
43
43
  * @param searchFacetInterior whether to include facet interiors in search. Default is false: just consider facet boundaries.
44
44
  * @return closest point detail(s) with detail.a set to the distance from spacePoint to detail.point
45
45
  */
46
- searchForClosestPoint(spacePoint: Point3d, maxDist?: number, searchFacetInterior?: boolean): FacetLocationDetail | FacetLocationDetail[] | undefined;
46
+ searchForClosestPoint(spacePoint: XYAndZ | XAndY, maxDist?: number, searchFacetInterior?: boolean): FacetLocationDetail | FacetLocationDetail[] | undefined;
47
47
  /**
48
48
  * Search the range trees for closest approach(es) between the polyfaces.
49
49
  * @param contextA first polyface context
@@ -1 +1 @@
1
- {"version":3,"file":"PolyfaceRangeTreeContext.d.ts","sourceRoot":"","sources":["../../../../src/polyface/RangeTree/PolyfaceRangeTreeContext.ts"],"names":[],"mappings":"AAIA;;GAEG;AAGH,OAAO,EAAE,OAAO,EAAE,MAAM,kCAAkC,CAAC;AAE3D,OAAO,EAAE,mBAAmB,EAAE,uBAAuB,EAAE,MAAM,wBAAwB,CAAC;AACtF,OAAO,EAAE,QAAQ,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAKxD;;;;GAIG;AACH,qBAAa,wBAAwB;IACnC,8CAA8C;IACvC,OAAO,EAAE,eAAe,CAAC;IAChC,0DAA0D;IACnD,YAAY,EAAE,OAAO,CAAC;IAE7B,iEAAiE;IAC1D,gBAAgB,EAAE,MAAM,CAAC;IAChC,sEAAsE;IAC/D,iBAAiB,EAAE,MAAM,CAAC;IACjC,yCAAyC;IAClC,YAAY,EAAE,MAAM,CAAC;IAC5B,gDAAgD;IACzC,SAAS,EAAE,MAAM,CAAC;IAEzB,yDAAyD;IACzD,OAAO,CAAC,cAAc,CAAwB;IAE9C,6DAA6D;IAC7D,OAAO;IASP;;;;;;;;OAQG;WACW,aAAa,CAAC,OAAO,EAAE,QAAQ,GAAG,eAAe,EAAE,eAAe,GAAE,MAAU,EAAE,iBAAiB,GAAE,MAAU,EAAE,YAAY,GAAE,OAAe,GAAG,wBAAwB,GAAG,SAAS;IAajM;;;;;;OAMG;IACI,qBAAqB,CAAC,UAAU,EAAE,OAAO,EAAE,OAAO,CAAC,EAAE,MAAM,EAAE,mBAAmB,GAAE,OAAe,GAAG,mBAAmB,GAAG,mBAAmB,EAAE,GAAG,SAAS;IAclK;;;;;;;MAOE;WACY,wBAAwB,CAAC,QAAQ,EAAE,wBAAwB,EAAE,QAAQ,EAAE,wBAAwB,EAAE,OAAO,CAAC,EAAE,MAAM,EAAE,mBAAmB,GAAE,OAAe,GAAG,uBAAuB,GAAG,uBAAuB,EAAE,GAAG,SAAS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AAE,GAAG,SAAS;CAKxO"}
@@ -62,7 +62,7 @@ class PolyfaceRangeTreeContext {
62
62
  /**
63
63
  * Search the range tree for closest facet(s) to spacePoint.
64
64
  * @param spacePoint point to test
65
- * @param maxDist collect points at no more than this distance from spacePoint. If undefined, return only the closest point.
65
+ * @param maxDist collect facet locations at no more than this distance from spacePoint. If undefined, return only the closest facet location.
66
66
  * @param searchFacetInterior whether to include facet interiors in search. Default is false: just consider facet boundaries.
67
67
  * @return closest point detail(s) with detail.a set to the distance from spacePoint to detail.point
68
68
  */
@@ -1 +1 @@
1
- {"version":3,"file":"PolyfaceRangeTreeContext.js","sourceRoot":"","sources":["../../../../src/polyface/RangeTree/PolyfaceRangeTreeContext.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,6CAA0C;AAI1C,0CAAwD;AACxD,oDAAiD;AACjD,mDAA8D;AAC9D,uEAA6I;AAE7I;;;;GAIG;AACH,MAAa,wBAAwB;IACnC,8CAA8C;IACvC,OAAO,CAAkB;IAChC,0DAA0D;IACnD,YAAY,CAAU;IAE7B,iEAAiE;IAC1D,gBAAgB,CAAS;IAChC,sEAAsE;IAC/D,iBAAiB,CAAS;IACjC,yCAAyC;IAClC,YAAY,CAAS;IAC5B,gDAAgD;IACzC,SAAS,CAAS;IAEzB,yDAAyD;IACjD,cAAc,CAAwB;IAE9C,6DAA6D;IAC7D,YAAoB,aAAoC,EAAE,OAAwB,EAAE,eAAwB,KAAK;QAC/G,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,YAAY,GAAG,YAAY,CAAC;QACjC,IAAI,CAAC,cAAc,GAAG,aAAa,CAAC;QACpC,IAAI,CAAC,gBAAgB,GAAG,CAAC,CAAC;QAC1B,IAAI,CAAC,iBAAiB,GAAG,CAAC,CAAC;QAC3B,IAAI,CAAC,YAAY,GAAG,CAAC,CAAC;QACtB,IAAI,CAAC,SAAS,GAAG,CAAC,CAAC;IACrB,CAAC;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QAAQ,GAAG,IAAI,CAAC,KAAK,CAAC,QAAQ,GAAG,OAAO,CAAC,CAAC;QAChD,OAAO,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC;QAC1B,OAAO,CAAC,cAAc,CAAC,QAAQ,GAAG,CAAC,CAAC,CAAC;QACrC,KAAK,IAAI,CAAC,GAAG,QAAQ,EAAE,CAAC,GAAG,CAAC,GAAG,QAAQ,EAAE,CAAC,IAAI,QAAQ;YACpD,OAAO,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC;QAC5B,IAAI,CAAC,cAAc,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;QAC3C,OAAO,OAAO,CAAC,WAAW,CAAC,UAAU,CAAC,MAAM,IAAI,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,aAAa,EAAE,CAAC;IACpG,CAAC;IACD;;;;;;;MAOE;IACK,MAAM,CAAC,wBAAwB,CAAC,QAAkC,EAAE,QAAkC,EAAE,OAAgB,EAAE,sBAA+B,KAAK;QACnK,MAAM,OAAO,GAAG,IAAI,wEAA8C,CAAC,QAAQ,EAAE,QAAQ,EAAE,OAAO,EAAE,mBAAmB,CAAC,CAAC;QACrH,6BAAa,CAAC,qBAAqB,CAAC,QAAQ,CAAC,cAAc,EAAE,QAAQ,CAAC,cAAc,EAAE,OAAO,CAAC,CAAC;QAC/F,OAAO,OAAO,CAAC,WAAW,CAAC,UAAU,CAAC,MAAM,IAAI,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,aAAa,EAAE,CAAC;IACpG,CAAC;CACF;AApFD,4DAoFC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module RangeSearch\n */\n\nimport { Geometry } from \"../../Geometry\";\nimport { Point3d } from \"../../geometry3d/Point3dVector3d\";\nimport { Range3d } from \"../../geometry3d/Range\";\nimport { FacetLocationDetail, FacetLocationDetailPair } from \"../FacetLocationDetail\";\nimport { Polyface, PolyfaceVisitor } from \"../Polyface\";\nimport { PolyfaceQuery } from \"../PolyfaceQuery\";\nimport { RangeTreeNode, RangeTreeOps } from \"./RangeTreeNode\";\nimport { SingleTreeSearchHandlerForClosestPointOnPolyface, TwoTreeSearchHandlerForFacetFacetCloseApproach } from \"./RangeTreeSearchHandlers\";\n\n/**\n * Handler class for searching a range tree containing the facets of a polyface.\n * * Facilitates multiple searches for closest point and close approach calculations.\n * @public\n */\nexport class PolyfaceRangeTreeContext {\n /** Visitor for the polyface being searched */\n public visitor: PolyfaceVisitor;\n /** Whether all facets to visit are known to be convex. */\n public convexFacets: boolean;\n\n /** Diagnostic: number of range tests that have returned true. */\n public numRangeTestTrue: number;\n /** Diagnostic: number of range tests that have been returned false */\n public numRangeTestFalse: number;\n /** Diagnostic: number of facet tests. */\n public numFacetTest: number;\n /** Diagnostic: number of searches performed. */\n public numSearch: number;\n\n /** Range tree, whose appData are facet (read) indices */\n private _rangeTreeRoot: RangeTreeNode<number>;\n\n /** Constructor: capture inputs, initialize debug counters */\n private constructor(rangeTreeRoot: RangeTreeNode<number>, visitor: PolyfaceVisitor, convexFacets: boolean = false) {\n this.visitor = visitor;\n this.convexFacets = convexFacets;\n this._rangeTreeRoot = rangeTreeRoot;\n this.numRangeTestTrue = 0;\n this.numRangeTestFalse = 0;\n this.numFacetTest = 0;\n this.numSearch = 0;\n }\n /**\n * Create a range tree context for the Polyface facets.\n * * This is a very simple construction that splits \"right and left parts\" of the facet sequence.\n * * Facets with any recognizable \"left to right\" or \"top to bottom\" sequencing will have very effective search structures.\n * @param visitor access to facets, captured if PolyfaceVisitor\n * @param maxChildPerNode maximum children per range tree node (default 4)\n * @param maxAppDataPerLeaf maximum facet indices per leaf node (default 4)\n * @param convexFacets whether all facets are known to be convex (cf. [[PolyfaceQuery.areFacetsConvex]]) (default false)\n */\n public static createCapture(visitor: Polyface | PolyfaceVisitor, maxChildPerNode: number = 4, maxAppDataPerLeaf: number = 4, convexFacets: boolean = false): PolyfaceRangeTreeContext | undefined {\n if (visitor instanceof Polyface)\n return this.createCapture(visitor.createVisitor(0), maxChildPerNode, maxAppDataPerLeaf, convexFacets);\n const numFacet = PolyfaceQuery.visitorClientFacetCount(visitor);\n const rangeTreeRoot = RangeTreeOps.createByIndexSplits<number>(\n (index: number): Range3d => { visitor.moveToReadIndex(index); return visitor.range(); },\n (index: number): number => { return index; },\n numFacet,\n maxChildPerNode,\n maxAppDataPerLeaf,\n );\n return rangeTreeRoot ? new PolyfaceRangeTreeContext(rangeTreeRoot, visitor, convexFacets) : undefined;\n }\n /**\n * Search the range tree for closest facet(s) to spacePoint.\n * @param spacePoint point to test\n * @param maxDist collect points at no more than this distance from spacePoint. If undefined, return only the closest point.\n * @param searchFacetInterior whether to include facet interiors in search. Default is false: just consider facet boundaries.\n * @return closest point detail(s) with detail.a set to the distance from spacePoint to detail.point\n */\n public searchForClosestPoint(spacePoint: Point3d, maxDist?: number, searchFacetInterior: boolean = false): FacetLocationDetail | FacetLocationDetail[] | undefined {\n const handler = new SingleTreeSearchHandlerForClosestPointOnPolyface(spacePoint, this, maxDist, searchFacetInterior);\n this.numSearch++;\n const numFacet = PolyfaceQuery.visitorClientFacetCount(this.visitor);\n // seed the search with a few points -- this reduces early trips deep into early ranges that are far from spacePoint.\n const numTest = Geometry.clamp(Math.floor(numFacet / 20), 2, 7);\n const testStep = Math.floor(numFacet / numTest);\n handler.processAppData(0);\n handler.processAppData(numFacet - 1);\n for (let i = testStep; i + 1 < numFacet; i += testStep)\n handler.processAppData(i);\n this._rangeTreeRoot.searchTopDown(handler);\n return handler.searchState.savedItems.length <= 1 ? handler.getResult() : handler.getSavedItems();\n }\n /**\n * Search the range trees for closest approach(es) between the polyfaces.\n * @param contextA first polyface context\n * @param contextB second polyface context\n * @param maxDist collect close approaches separated by no more than this distance. If undefined, return only the closest approach.\n * @param searchFacetInterior whether to include facet interiors in search (`context.convexFacets` must be true for both contexts). Default is false: just consider facet boundaries.\n * @return closest approach detail pair(s), one per context, with detail.a set to the approach distance\n */\n public static searchForClosestApproach(contextA: PolyfaceRangeTreeContext, contextB: PolyfaceRangeTreeContext, maxDist?: number, searchFacetInterior: boolean = false): FacetLocationDetailPair | FacetLocationDetailPair[] | undefined {\n const handler = new TwoTreeSearchHandlerForFacetFacetCloseApproach(contextA, contextB, maxDist, searchFacetInterior);\n RangeTreeNode.searchTwoTreesTopDown(contextA._rangeTreeRoot, contextB._rangeTreeRoot, handler);\n return handler.searchState.savedItems.length <= 1 ? handler.getResult() : handler.getSavedItems();\n }\n}\n"]}
1
+ {"version":3,"file":"PolyfaceRangeTreeContext.js","sourceRoot":"","sources":["../../../../src/polyface/RangeTree/PolyfaceRangeTreeContext.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,6CAA0C;AAI1C,0CAAwD;AACxD,oDAAiD;AACjD,mDAA8D;AAC9D,uEAA6I;AAE7I;;;;GAIG;AACH,MAAa,wBAAwB;IACnC,8CAA8C;IACvC,OAAO,CAAkB;IAChC,0DAA0D;IACnD,YAAY,CAAU;IAE7B,iEAAiE;IAC1D,gBAAgB,CAAS;IAChC,sEAAsE;IAC/D,iBAAiB,CAAS;IACjC,yCAAyC;IAClC,YAAY,CAAS;IAC5B,gDAAgD;IACzC,SAAS,CAAS;IAEzB,yDAAyD;IACjD,cAAc,CAAwB;IAE9C,6DAA6D;IAC7D,YAAoB,aAAoC,EAAE,OAAwB,EAAE,eAAwB,KAAK;QAC/G,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,YAAY,GAAG,YAAY,CAAC;QACjC,IAAI,CAAC,cAAc,GAAG,aAAa,CAAC;QACpC,IAAI,CAAC,gBAAgB,GAAG,CAAC,CAAC;QAC1B,IAAI,CAA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entley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module RangeSearch\r\n */\r\n\r\nimport { Geometry } from \"../../Geometry\";\r\nimport { Range3d } from \"../../geometry3d/Range\";\r\nimport { XAndY, XYAndZ } from \"../../geometry3d/XYZProps\";\r\nimport { FacetLocationDetail, FacetLocationDetailPair } from \"../FacetLocationDetail\";\r\nimport { Polyface, PolyfaceVisitor } from \"../Polyface\";\r\nimport { PolyfaceQuery } from \"../PolyfaceQuery\";\r\nimport { RangeTreeNode, RangeTreeOps } from \"./RangeTreeNode\";\r\nimport { SingleTreeSearchHandlerForClosestPointOnPolyface, TwoTreeSearchHandlerForFacetFacetCloseApproach } from \"./RangeTreeSearchHandlers\";\r\n\r\n/**\r\n * Handler class for searching a range tree containing the facets of a polyface.\r\n * * Facilitates multiple searches for closest point and close approach calculations.\r\n * @public\r\n */\r\nexport class PolyfaceRangeTreeContext {\r\n /** Visitor for the polyface being searched */\r\n public visitor: PolyfaceVisitor;\r\n /** Whether all facets to visit are known to be convex. */\r\n public convexFacets: boolean;\r\n\r\n /** Diagnostic: number of range tests that have returned true. */\r\n public numRangeTestTrue: number;\r\n /** Diagnostic: number of range tests that have been returned false */\r\n public numRangeTestFalse: number;\r\n /** Diagnostic: number of facet tests. */\r\n public numFacetTest: number;\r\n /** Diagnostic: number of searches performed. */\r\n public numSearch: number;\r\n\r\n /** Range tree, whose appData are facet (read) indices */\r\n private _rangeTreeRoot: RangeTreeNode<number>;\r\n\r\n /** Constructor: capture inputs, initialize debug counters */\r\n private constructor(rangeTreeRoot: RangeTreeNode<number>, visitor: PolyfaceVisitor, convexFacets: boolean = false) {\r\n this.visitor = visitor;\r\n this.convexFacets = convexFacets;\r\n this._rangeTreeRoot = rangeTreeRoot;\r\n this.numRangeTestTrue = 0;\r\n this.numRangeTestFalse = 0;\r\n this.numFacetTest = 0;\r\n this.numSearch = 0;\r\n }\r\n /**\r\n * Create a range tree context for the Polyface facets.\r\n * * This is a very simple construction that splits \"right and left parts\" of the facet sequence.\r\n * * Facets with any recognizable \"left to right\" or \"top to bottom\" sequencing will have very effective search structures.\r\n * @param visitor access to facets, captured if PolyfaceVisitor\r\n * @param maxChildPerNode maximum children per range tree node (default 4)\r\n * @param maxAppDataPerLeaf maximum facet indices per leaf node (default 4)\r\n * @param convexFacets whether all facets are known to be convex (cf. [[PolyfaceQuery.areFacetsConvex]]) (default false)\r\n */\r\n public static createCapture(visitor: Polyface | PolyfaceVisitor, maxChildPerNode: number = 4, maxAppDataPerLeaf: number = 4, convexFacets: boolean = false): PolyfaceRangeTreeContext | undefined {\r\n if (visitor instanceof Polyface)\r\n return this.createCapture(visitor.createVisitor(0), maxChildPerNode, maxAppDataPerLeaf, convexFacets);\r\n const numFacet = PolyfaceQuery.visitorClientFacetCount(visitor);\r\n const rangeTreeRoot = RangeTreeOps.createByIndexSplits<number>(\r\n (index: number): Range3d => { visitor.moveToReadIndex(index); return visitor.range(); },\r\n (index: number): number => { return index; },\r\n numFacet,\r\n maxChildPerNode,\r\n maxAppDataPerLeaf,\r\n );\r\n return rangeTreeRoot ? new PolyfaceRangeTreeContext(rangeTreeRoot, visitor, convexFacets) : undefined;\r\n }\r\n /**\r\n * Search the range tree for closest facet(s) to spacePoint.\r\n * @param spacePoint point to test\r\n * @param maxDist collect facet locations at no more than this distance from spacePoint. If undefined, return only the closest facet location.\r\n * @param searchFacetInterior whether to include facet interiors in search. Default is false: just consider facet boundaries.\r\n * @return closest point detail(s) with detail.a set to the distance from spacePoint to detail.point\r\n */\r\n public searchForClosestPoint(spacePoint: XYAndZ | XAndY, maxDist?: number, searchFacetInterior: boolean = false): FacetLocationDetail | FacetLocationDetail[] | undefined {\r\n const handler = new SingleTreeSearchHandlerForClosestPointOnPolyface(spacePoint, this, maxDist, searchFacetInterior);\r\n this.numSearch++;\r\n const numFacet = PolyfaceQuery.visitorClientFacetCount(this.visitor);\r\n // seed the search with a few points -- this reduces early trips deep into early ranges that are far from spacePoint.\r\n const numTest = Geometry.clamp(Math.floor(numFacet / 20), 2, 7);\r\n const testStep = Math.floor(numFacet / numTest);\r\n handler.processAppData(0);\r\n handler.processAppData(numFacet - 1);\r\n for (let i = testStep; i + 1 < numFacet; i += testStep)\r\n handler.processAppData(i);\r\n this._rangeTreeRoot.searchTopDown(handler);\r\n return handler.searchState.savedItems.length <= 1 ? handler.getResult() : handler.getSavedItems();\r\n }\r\n /**\r\n * Search the range trees for closest approach(es) between the polyfaces.\r\n * @param contextA first polyface context\r\n * @param contextB second polyface context\r\n * @param maxDist collect close approaches separated by no more than this distance. If undefined, return only the closest approach.\r\n * @param searchFacetInterior whether to include facet interiors in search (`context.convexFacets` must be true for both contexts). Default is false: just consider facet boundaries.\r\n * @return closest approach detail pair(s), one per context, with detail.a set to the approach distance\r\n */\r\n public static searchForClosestApproach(contextA: PolyfaceRangeTreeContext, contextB: PolyfaceRangeTreeContext, maxDist?: number, searchFacetInterior: boolean = false): FacetLocationDetailPair | FacetLocationDetailPair[] | undefined {\r\n const handler = new TwoTreeSearchHandlerForFacetFacetCloseApproach(contextA, contextB, maxDist, searchFacetInterior);\r\n RangeTreeNode.searchTwoTreesTopDown(contextA._rangeTreeRoot, contextB._rangeTreeRoot, handler);\r\n return handler.searchState.savedItems.length <= 1 ? handler.getResult() : handler.getSavedItems();\r\n }\r\n}\r\n"]}
@@ -32,7 +32,7 @@ export declare abstract class SingleTreeSearchHandler<AppDataType> {
32
32
  * * Default implementation returns false so query runs to completion.
33
33
  * * Search processes check this after range tests and child processing.
34
34
  */
35
- isAborted(): boolean;
35
+ getIsAborted(): boolean;
36
36
  }
37
37
  /**
38
38
  * Abstract class for handler objects called during traversal of two range trees.
@@ -53,7 +53,9 @@ export declare abstract class TwoTreeSearchHandler<AppDataType> {
53
53
  * * Default implementation returns false so query runs to completion.
54
54
  * * Search processes check this after range tests and child processing.
55
55
  */
56
- isAborted(): boolean;
56
+ getIsAborted(): boolean;
57
+ /** Whether to ignore z-coordinates in distance computations. */
58
+ getXYOnly(): boolean;
57
59
  }
58
60
  /**
59
61
  * This class refines the TwoTreeSearchHandler with an implementation of `isRangePairActive` appropriate for computing the minimum distance between trees.
@@ -1 +1 @@
1
- {"version":3,"file":"RangeTreeNode.d.ts","sourceRoot":"","sources":["../../../../src/polyface/RangeTree/RangeTreeNode.ts"],"names":[],"mappings":"AAIA;;GAEG;AAGH,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AAEjD;;;;GAIG;AACH,KAAK,QAAQ,CAAC,CAAC,IAAI,SAAS,GAAG,CAAC,EAAE,GAAG,CAAC,CAAC;AACvC;;;;GAIG;AACH,KAAK,WAAW,CAAC,CAAC,IAAI,CAAC,EAAE,GAAG,CAAC,CAAC,KAAK,EAAE,MAAM,KAAK,CAAC,CAAC,CAAC;AA0CnD;;;GAGG;AACH,8BAAsB,uBAAuB,CAAC,WAAW;IACvD,qFAAqF;aACrE,aAAa,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO;IACtD;;;;OAIG;aACa,cAAc,CAAC,IAAI,EAAE,WAAW,GAAG,IAAI;IACvD;;;;OAIG;IAEI,SAAS,IAAI,OAAO;CAC5B;AACD;;;GAGG;AACH,8BAAsB,oBAAoB,CAAC,WAAW;IACpD,0FAA0F;aAC1E,iBAAiB,CAAC,SAAS,EAAE,OAAO,EAAE,UAAU,EAAE,OAAO,GAAG,OAAO;IACnF;;;;;OAKG;aACa,kBAAkB,CAAC,QAAQ,EAAE,WAAW,EAAE,SAAS,EAAE,WAAW,GAAG,IAAI;IACvF;;;;OAIG;IAEI,SAAS,IAAI,OAAO;CAC5B;AACD;;;;;GAKG;AACH,8BAAsB,wCAAwC,CAAC,WAAW,CAAE,SAAQ,oBAAoB,CAAC,WAAW,CAAC;IACnH;;;;OAIG;aACa,kBAAkB,IAAI,MAAM;IAC5C;;;;;OAKG;IACa,iBAAiB,CAAC,SAAS,EAAE,OAAO,EAA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AAC,mBAAmB;IA8ClC;;;;;;;OAOG;IACH,OAAO,CAAC,MAAM,CAAC,uBAAuB;IAmBtC;;;;;OAKG;WACW,qBAAqB,CAAC,WAAW,EAC7C,QAAQ,EAAE,aAAa,CAAC,WAAW,CAAC,EACpC,SAAS,EAAE,aAAa,CAAC,WAAW,CAAC,EACrC,OAAO,EAAE,oBAAoB,CAAC,WAAW,CAAC;CAI7C;AACD;;;GAGG;AACH,qBAAa,YAAY;IACvB,gCAAgC;WAClB,qBAAqB,CAAC,WAAW,EAAE,IAAI,EAAE,aAAa,CAAC,WAAW,CAAC,GAAG,MAAM;IAK1F,kCAAkC;WACpB,wBAAwB,CAAC,WAAW,EAAE,IAAI,EAAE,aAAa,CAAC,WAAW,CAAC,GAAG,MAAM;IAM7F;;;;;;;;OAQG;IACH,OAAO,CAAC,MAAM,CAAC,sBAAsB;IAgBrC;;;;;;;;;;OAUG;IACH,OAAO,CAAC,MAAM,CAAC,4BAA4B;IAuC3C;;;;;;;;;;OAUG;WACW,mBAAmB,CAAC,WAAW,EAC3C,MAAM,EAAE,WAAW,CAAC,OAAO,CAAC,EAC5B,OAAO,EAAE,WAAW,CAAC,WAAW,CAAC,EACjC,WAAW,EAAE,MAAM,EACnB,kBAAkB,GAAE,MAAU,EAC9B,iBAAiB,GAAE,MAAU,GAC5B,aAAa,CAAC,WAAW,CAAC,GAAG,SAAS;CAY1C"}
@@ -62,8 +62,7 @@ class SingleTreeSearchHandler {
62
62
  * * Default implementation returns false so query runs to completion.
63
63
  * * Search processes check this after range tests and child processing.
64
64
  */
65
- // eslint-disable-next-line @itwin/prefer-get
66
- isAborted() { return false; }
65
+ getIsAborted() { return false; }
67
66
  }
68
67
  exports.SingleTreeSearchHandler = SingleTreeSearchHandler;
69
68
  /**
@@ -76,8 +75,9 @@ class TwoTreeSearchHandler {
76
75
  * * Default implementation returns false so query runs to completion.
77
76
  * * Search processes check this after range tests and child processing.
78
77
  */
79
- // eslint-disable-next-line @itwin/prefer-get
80
- isAborted() { return false; }
78
+ getIsAborted() { return false; }
79
+ /** Whether to ignore z-coordinates in distance computations. */
80
+ getXYOnly() { return false; }
81
81
  }
82
82
  exports.TwoTreeSearchHandler = TwoTreeSearchHandler;
83
83
  /**
@@ -95,11 +95,8 @@ class TwoTreeDistanceMinimizationSearchHandler extends TwoTreeSearchHandler {
95
95
  */
96
96
  isRangePairActive(leftRange, rightRange) {
97
97
  const currentDistance = this.getCurrentDistance();
98
- const distanceBetweenRanges = leftRange.distanceToRange(rightRange);
99
- if (distanceBetweenRanges <= currentDistance) {
100
- return true;
101
- }
102
- return false;
98
+ const distanceBetweenRanges = this.getXYOnly() ? leftRange.distanceToRangeXY(rightRange) : leftRange.distanceToRange(rightRange);
99
+ return distanceBetweenRanges <= currentDistance;
103
100
  }
104
101
  }
105
102
  exports.TwoTreeDistanceMinimizationSearchHandler = TwoTreeDistanceMinimizationSearchHandler;
@@ -242,7 +239,7 @@ class RangeTreeNode {
242
239
  for (let i = 0; undefined !== (itemToProcess = this.getAppDataByIndex(i)); i++) {
243
240
  // console.log(itemToProcess);
244
241
  handler.processAppData(itemToProcess);
245
- if (handler.isAborted())
242
+ if (handler.getIsAborted())
246
243
  return;
247
244
  }
248
245
  let child;
@@ -271,7 +268,7 @@ class RangeTreeNode {
271
268
  handler.processAppDataPair(leftItem, rightItem);
272
269
  else
273
270
  handler.processAppDataPair(rightItem, leftItem);
274
- if (handler.isAborted())
271
+ if (handler.getIsAborted())
275
272
  return;
276
273
  }
277
274
  }
@@ -295,7 +292,7 @@ class RangeTreeNode {
295
292
  handler.processAppDataPair(leftItem, rightItem);
296
293
  else
297
294
  handler.processAppDataPair(rightItem, leftItem);
298
- if (handler.isAborted())
295
+ if (handler.getIsAborted())
299
296
  return;
300
297
  }
301
298
  }