@itwin/core-geometry 5.5.0-dev.4 → 5.5.0-dev.6

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 (611) hide show
  1. package/lib/cjs/Geometry.d.ts +7 -0
  2. package/lib/cjs/Geometry.d.ts.map +1 -1
  3. package/lib/cjs/Geometry.js +9 -0
  4. package/lib/cjs/Geometry.js.map +1 -1
  5. package/lib/cjs/bspline/BSplineCurve.d.ts.map +1 -1
  6. package/lib/cjs/bspline/BSplineCurve.js +2 -1
  7. package/lib/cjs/bspline/BSplineCurve.js.map +1 -1
  8. package/lib/cjs/bspline/BSplineCurveOps.d.ts.map +1 -1
  9. package/lib/cjs/bspline/BSplineCurveOps.js +4 -1
  10. package/lib/cjs/bspline/BSplineCurveOps.js.map +1 -1
  11. package/lib/cjs/bspline/BezierCurve3d.d.ts.map +1 -1
  12. package/lib/cjs/bspline/BezierCurve3d.js +14 -4
  13. package/lib/cjs/bspline/BezierCurve3d.js.map +1 -1
  14. package/lib/cjs/bspline/BezierCurve3dH.d.ts +2 -0
  15. package/lib/cjs/bspline/BezierCurve3dH.d.ts.map +1 -1
  16. package/lib/cjs/bspline/BezierCurve3dH.js +19 -3
  17. package/lib/cjs/bspline/BezierCurve3dH.js.map +1 -1
  18. package/lib/cjs/bspline/BezierCurveBase.d.ts +8 -2
  19. package/lib/cjs/bspline/BezierCurveBase.d.ts.map +1 -1
  20. package/lib/cjs/bspline/BezierCurveBase.js +10 -4
  21. package/lib/cjs/bspline/BezierCurveBase.js.map +1 -1
  22. package/lib/cjs/clipping/AlternatingConvexClipTree.js +4 -4
  23. package/lib/cjs/clipping/AlternatingConvexClipTree.js.map +1 -1
  24. package/lib/cjs/clipping/ClipPlane.d.ts +0 -3
  25. package/lib/cjs/clipping/ClipPlane.d.ts.map +1 -1
  26. package/lib/cjs/clipping/ClipPlane.js +9 -2
  27. package/lib/cjs/clipping/ClipPlane.js.map +1 -1
  28. package/lib/cjs/clipping/ClipPrimitive.d.ts +59 -9
  29. package/lib/cjs/clipping/ClipPrimitive.d.ts.map +1 -1
  30. package/lib/cjs/clipping/ClipPrimitive.js +124 -55
  31. package/lib/cjs/clipping/ClipPrimitive.js.map +1 -1
  32. package/lib/cjs/clipping/ClipUtils.js +1 -1
  33. package/lib/cjs/clipping/ClipUtils.js.map +1 -1
  34. package/lib/cjs/clipping/ClipVector.d.ts.map +1 -1
  35. package/lib/cjs/clipping/ClipVector.js +12 -8
  36. package/lib/cjs/clipping/ClipVector.js.map +1 -1
  37. package/lib/cjs/clipping/ConvexClipPlaneSet.d.ts +0 -2
  38. package/lib/cjs/clipping/ConvexClipPlaneSet.d.ts.map +1 -1
  39. package/lib/cjs/clipping/ConvexClipPlaneSet.js +19 -18
  40. package/lib/cjs/clipping/ConvexClipPlaneSet.js.map +1 -1
  41. package/lib/cjs/clipping/internalContexts/LineStringOffsetClipperContext.d.ts +1 -1
  42. package/lib/cjs/clipping/internalContexts/LineStringOffsetClipperContext.d.ts.map +1 -1
  43. package/lib/cjs/clipping/internalContexts/LineStringOffsetClipperContext.js +4 -5
  44. package/lib/cjs/clipping/internalContexts/LineStringOffsetClipperContext.js.map +1 -1
  45. package/lib/cjs/core-geometry.d.ts +0 -1
  46. package/lib/cjs/core-geometry.d.ts.map +1 -1
  47. package/lib/cjs/core-geometry.js +0 -1
  48. package/lib/cjs/core-geometry.js.map +1 -1
  49. package/lib/cjs/curve/Arc3d.js +2 -2
  50. package/lib/cjs/curve/Arc3d.js.map +1 -1
  51. package/lib/cjs/curve/CurveChainWithDistanceIndex.d.ts +12 -4
  52. package/lib/cjs/curve/CurveChainWithDistanceIndex.d.ts.map +1 -1
  53. package/lib/cjs/curve/CurveChainWithDistanceIndex.js +52 -33
  54. package/lib/cjs/curve/CurveChainWithDistanceIndex.js.map +1 -1
  55. package/lib/cjs/curve/CurveCollection.d.ts.map +1 -1
  56. package/lib/cjs/curve/CurveCollection.js +13 -6
  57. package/lib/cjs/curve/CurveCollection.js.map +1 -1
  58. package/lib/cjs/curve/CurveCurve.js +1 -1
  59. package/lib/cjs/curve/CurveCurve.js.map +1 -1
  60. package/lib/cjs/curve/CurveFactory.d.ts.map +1 -1
  61. package/lib/cjs/curve/CurveFactory.js +13 -1
  62. package/lib/cjs/curve/CurveFactory.js.map +1 -1
  63. package/lib/cjs/curve/CurveLocationDetail.d.ts +12 -4
  64. package/lib/cjs/curve/CurveLocationDetail.d.ts.map +1 -1
  65. package/lib/cjs/curve/CurveLocationDetail.js +14 -5
  66. package/lib/cjs/curve/CurveLocationDetail.js.map +1 -1
  67. package/lib/cjs/curve/CurvePrimitive.d.ts +5 -4
  68. package/lib/cjs/curve/CurvePrimitive.d.ts.map +1 -1
  69. package/lib/cjs/curve/CurvePrimitive.js +7 -4
  70. package/lib/cjs/curve/CurvePrimitive.js.map +1 -1
  71. package/lib/cjs/curve/LineString3d.d.ts +25 -16
  72. package/lib/cjs/curve/LineString3d.d.ts.map +1 -1
  73. package/lib/cjs/curve/LineString3d.js +90 -72
  74. package/lib/cjs/curve/LineString3d.js.map +1 -1
  75. package/lib/cjs/curve/Path.d.ts +0 -3
  76. package/lib/cjs/curve/Path.d.ts.map +1 -1
  77. package/lib/cjs/curve/Path.js +9 -2
  78. package/lib/cjs/curve/Path.js.map +1 -1
  79. package/lib/cjs/curve/Query/InOutTests.js.map +1 -1
  80. package/lib/cjs/curve/Query/PlanarSubdivision.d.ts.map +1 -1
  81. package/lib/cjs/curve/Query/PlanarSubdivision.js +25 -31
  82. package/lib/cjs/curve/Query/PlanarSubdivision.js.map +1 -1
  83. package/lib/cjs/curve/Query/StrokeCountChain.d.ts +7 -1
  84. package/lib/cjs/curve/Query/StrokeCountChain.d.ts.map +1 -1
  85. package/lib/cjs/curve/Query/StrokeCountChain.js +27 -36
  86. package/lib/cjs/curve/Query/StrokeCountChain.js.map +1 -1
  87. package/lib/cjs/curve/RegionMomentsXY.d.ts.map +1 -1
  88. package/lib/cjs/curve/RegionMomentsXY.js +7 -1
  89. package/lib/cjs/curve/RegionMomentsXY.js.map +1 -1
  90. package/lib/cjs/curve/RegionOps.d.ts.map +1 -1
  91. package/lib/cjs/curve/RegionOps.js +8 -5
  92. package/lib/cjs/curve/RegionOps.js.map +1 -1
  93. package/lib/cjs/curve/RegionOpsClassificationSweeps.d.ts.map +1 -1
  94. package/lib/cjs/curve/RegionOpsClassificationSweeps.js +6 -6
  95. package/lib/cjs/curve/RegionOpsClassificationSweeps.js.map +1 -1
  96. package/lib/cjs/curve/internalContexts/AnnounceTangentStrokeHandler.d.ts.map +1 -1
  97. package/lib/cjs/curve/internalContexts/AnnounceTangentStrokeHandler.js +4 -1
  98. package/lib/cjs/curve/internalContexts/AnnounceTangentStrokeHandler.js.map +1 -1
  99. package/lib/cjs/curve/internalContexts/ClosestPointStrokeHandler.d.ts.map +1 -1
  100. package/lib/cjs/curve/internalContexts/ClosestPointStrokeHandler.js +6 -1
  101. package/lib/cjs/curve/internalContexts/ClosestPointStrokeHandler.js.map +1 -1
  102. package/lib/cjs/curve/internalContexts/CurveCurveCloseApproachXY.d.ts +5 -21
  103. package/lib/cjs/curve/internalContexts/CurveCurveCloseApproachXY.d.ts.map +1 -1
  104. package/lib/cjs/curve/internalContexts/CurveCurveCloseApproachXY.js +29 -73
  105. package/lib/cjs/curve/internalContexts/CurveCurveCloseApproachXY.js.map +1 -1
  106. package/lib/cjs/curve/internalContexts/CurveCurveIntersectXY.d.ts +55 -13
  107. package/lib/cjs/curve/internalContexts/CurveCurveIntersectXY.d.ts.map +1 -1
  108. package/lib/cjs/curve/internalContexts/CurveCurveIntersectXY.js +238 -110
  109. package/lib/cjs/curve/internalContexts/CurveCurveIntersectXY.js.map +1 -1
  110. package/lib/cjs/curve/internalContexts/PolygonOffsetContext.js +1 -1
  111. package/lib/cjs/curve/internalContexts/PolygonOffsetContext.js.map +1 -1
  112. package/lib/cjs/curve/spiral/DirectSpiral3d.d.ts +1 -4
  113. package/lib/cjs/curve/spiral/DirectSpiral3d.d.ts.map +1 -1
  114. package/lib/cjs/curve/spiral/DirectSpiral3d.js +9 -9
  115. package/lib/cjs/curve/spiral/DirectSpiral3d.js.map +1 -1
  116. package/lib/cjs/curve/spiral/IntegratedSpiral3d.d.ts +11 -14
  117. package/lib/cjs/curve/spiral/IntegratedSpiral3d.d.ts.map +1 -1
  118. package/lib/cjs/curve/spiral/IntegratedSpiral3d.js +18 -18
  119. package/lib/cjs/curve/spiral/IntegratedSpiral3d.js.map +1 -1
  120. package/lib/cjs/curve/spiral/TransitionConditionalProperties.d.ts +7 -1
  121. package/lib/cjs/curve/spiral/TransitionConditionalProperties.d.ts.map +1 -1
  122. package/lib/cjs/curve/spiral/TransitionConditionalProperties.js.map +1 -1
  123. package/lib/cjs/geometry3d/Ellipsoid.d.ts +19 -7
  124. package/lib/cjs/geometry3d/Ellipsoid.d.ts.map +1 -1
  125. package/lib/cjs/geometry3d/Ellipsoid.js +26 -11
  126. package/lib/cjs/geometry3d/Ellipsoid.js.map +1 -1
  127. package/lib/cjs/geometry3d/FrustumAnimation.d.ts.map +1 -1
  128. package/lib/cjs/geometry3d/FrustumAnimation.js +11 -1
  129. package/lib/cjs/geometry3d/FrustumAnimation.js.map +1 -1
  130. package/lib/cjs/geometry3d/GrowableFloat64Array.d.ts +5 -1
  131. package/lib/cjs/geometry3d/GrowableFloat64Array.d.ts.map +1 -1
  132. package/lib/cjs/geometry3d/GrowableFloat64Array.js +11 -1
  133. package/lib/cjs/geometry3d/GrowableFloat64Array.js.map +1 -1
  134. package/lib/cjs/geometry3d/GrowableXYArray.d.ts +1 -1
  135. package/lib/cjs/geometry3d/GrowableXYArray.js +1 -1
  136. package/lib/cjs/geometry3d/GrowableXYArray.js.map +1 -1
  137. package/lib/cjs/geometry3d/GrowableXYZArray.d.ts +49 -8
  138. package/lib/cjs/geometry3d/GrowableXYZArray.d.ts.map +1 -1
  139. package/lib/cjs/geometry3d/GrowableXYZArray.js +90 -37
  140. package/lib/cjs/geometry3d/GrowableXYZArray.js.map +1 -1
  141. package/lib/cjs/geometry3d/IndexedXYZCollection.d.ts +100 -3
  142. package/lib/cjs/geometry3d/IndexedXYZCollection.d.ts.map +1 -1
  143. package/lib/cjs/geometry3d/IndexedXYZCollection.js +125 -0
  144. package/lib/cjs/geometry3d/IndexedXYZCollection.js.map +1 -1
  145. package/lib/cjs/geometry3d/Matrix3d.d.ts +10 -1
  146. package/lib/cjs/geometry3d/Matrix3d.d.ts.map +1 -1
  147. package/lib/cjs/geometry3d/Matrix3d.js +53 -34
  148. package/lib/cjs/geometry3d/Matrix3d.js.map +1 -1
  149. package/lib/cjs/geometry3d/Plane3dByOriginAndUnitNormal.js +1 -1
  150. package/lib/cjs/geometry3d/Plane3dByOriginAndUnitNormal.js.map +1 -1
  151. package/lib/cjs/geometry3d/Point3dArrayCarrier.d.ts +49 -2
  152. package/lib/cjs/geometry3d/Point3dArrayCarrier.d.ts.map +1 -1
  153. package/lib/cjs/geometry3d/Point3dArrayCarrier.js +67 -9
  154. package/lib/cjs/geometry3d/Point3dArrayCarrier.js.map +1 -1
  155. package/lib/cjs/geometry3d/Point3dVector3d.d.ts +1 -1
  156. package/lib/cjs/geometry3d/Point3dVector3d.js +1 -1
  157. package/lib/cjs/geometry3d/Point3dVector3d.js.map +1 -1
  158. package/lib/cjs/geometry3d/PointStreaming.js +1 -1
  159. package/lib/cjs/geometry3d/PointStreaming.js.map +1 -1
  160. package/lib/cjs/geometry3d/PolygonOps.d.ts +24 -32
  161. package/lib/cjs/geometry3d/PolygonOps.d.ts.map +1 -1
  162. package/lib/cjs/geometry3d/PolygonOps.js +147 -180
  163. package/lib/cjs/geometry3d/PolygonOps.js.map +1 -1
  164. package/lib/cjs/geometry3d/PolylineCompressionByEdgeOffset.js +5 -5
  165. package/lib/cjs/geometry3d/PolylineCompressionByEdgeOffset.js.map +1 -1
  166. package/lib/cjs/geometry3d/PolylineOps.d.ts.map +1 -1
  167. package/lib/cjs/geometry3d/PolylineOps.js +13 -3
  168. package/lib/cjs/geometry3d/PolylineOps.js.map +1 -1
  169. package/lib/cjs/geometry3d/Range.js.map +1 -1
  170. package/lib/cjs/geometry3d/Ray3d.d.ts +0 -3
  171. package/lib/cjs/geometry3d/Ray3d.d.ts.map +1 -1
  172. package/lib/cjs/geometry3d/Ray3d.js +5 -1
  173. package/lib/cjs/geometry3d/Ray3d.js.map +1 -1
  174. package/lib/cjs/geometry3d/SortablePolygon.d.ts +2 -2
  175. package/lib/cjs/geometry3d/SortablePolygon.d.ts.map +1 -1
  176. package/lib/cjs/geometry3d/SortablePolygon.js +14 -18
  177. package/lib/cjs/geometry3d/SortablePolygon.js.map +1 -1
  178. package/lib/cjs/geometry3d/Transform.d.ts +8 -0
  179. package/lib/cjs/geometry3d/Transform.d.ts.map +1 -1
  180. package/lib/cjs/geometry3d/Transform.js +15 -9
  181. package/lib/cjs/geometry3d/Transform.js.map +1 -1
  182. package/lib/cjs/numerics/ClusterableArray.d.ts +4 -2
  183. package/lib/cjs/numerics/ClusterableArray.d.ts.map +1 -1
  184. package/lib/cjs/numerics/ClusterableArray.js +6 -4
  185. package/lib/cjs/numerics/ClusterableArray.js.map +1 -1
  186. package/lib/cjs/numerics/Newton.d.ts +3 -1
  187. package/lib/cjs/numerics/Newton.d.ts.map +1 -1
  188. package/lib/cjs/numerics/Newton.js +5 -1
  189. package/lib/cjs/numerics/Newton.js.map +1 -1
  190. package/lib/cjs/polyface/AuxData.d.ts +1 -4
  191. package/lib/cjs/polyface/AuxData.d.ts.map +1 -1
  192. package/lib/cjs/polyface/AuxData.js +5 -1
  193. package/lib/cjs/polyface/AuxData.js.map +1 -1
  194. package/lib/cjs/polyface/GreedyTriangulationBetweenLineStrings.js +3 -3
  195. package/lib/cjs/polyface/GreedyTriangulationBetweenLineStrings.js.map +1 -1
  196. package/lib/cjs/polyface/Polyface.d.ts.map +1 -1
  197. package/lib/cjs/polyface/Polyface.js +14 -16
  198. package/lib/cjs/polyface/Polyface.js.map +1 -1
  199. package/lib/cjs/polyface/PolyfaceBuilder.d.ts +84 -28
  200. package/lib/cjs/polyface/PolyfaceBuilder.d.ts.map +1 -1
  201. package/lib/cjs/polyface/PolyfaceBuilder.js +277 -217
  202. package/lib/cjs/polyface/PolyfaceBuilder.js.map +1 -1
  203. package/lib/cjs/polyface/PolyfaceClip.d.ts +4 -3
  204. package/lib/cjs/polyface/PolyfaceClip.d.ts.map +1 -1
  205. package/lib/cjs/polyface/PolyfaceClip.js +11 -4
  206. package/lib/cjs/polyface/PolyfaceClip.js.map +1 -1
  207. package/lib/cjs/polyface/PolyfaceData.js.map +1 -1
  208. package/lib/cjs/polyface/PolyfaceQuery.d.ts.map +1 -1
  209. package/lib/cjs/polyface/PolyfaceQuery.js +9 -7
  210. package/lib/cjs/polyface/PolyfaceQuery.js.map +1 -1
  211. package/lib/cjs/polyface/RangeTree/LineString3dRangeTreeContext.d.ts.map +1 -1
  212. package/lib/cjs/polyface/RangeTree/LineString3dRangeTreeContext.js +3 -2
  213. package/lib/cjs/polyface/RangeTree/LineString3dRangeTreeContext.js.map +1 -1
  214. package/lib/cjs/polyface/RangeTree/RangeTreeNode.d.ts +1 -1
  215. package/lib/cjs/polyface/RangeTree/RangeTreeNode.js +2 -2
  216. package/lib/cjs/polyface/RangeTree/RangeTreeNode.js.map +1 -1
  217. package/lib/cjs/polyface/RangeTree/RangeTreeSearchHandlers.d.ts.map +1 -1
  218. package/lib/cjs/polyface/RangeTree/RangeTreeSearchHandlers.js +14 -12
  219. package/lib/cjs/polyface/RangeTree/RangeTreeSearchHandlers.js.map +1 -1
  220. package/lib/cjs/polyface/multiclip/BuildAverageNormalsContext.d.ts +1 -1
  221. package/lib/cjs/polyface/multiclip/BuildAverageNormalsContext.d.ts.map +1 -1
  222. package/lib/cjs/polyface/multiclip/BuildAverageNormalsContext.js +10 -6
  223. package/lib/cjs/polyface/multiclip/BuildAverageNormalsContext.js.map +1 -1
  224. package/lib/cjs/polyface/multiclip/OffsetMeshContext.js +4 -3
  225. package/lib/cjs/polyface/multiclip/OffsetMeshContext.js.map +1 -1
  226. package/lib/cjs/polyface/multiclip/SweepLineStringToFacetContext.d.ts.map +1 -1
  227. package/lib/cjs/polyface/multiclip/SweepLineStringToFacetContext.js +3 -5
  228. package/lib/cjs/polyface/multiclip/SweepLineStringToFacetContext.js.map +1 -1
  229. package/lib/cjs/polyface/multiclip/XYPointBuckets.d.ts +1 -1
  230. package/lib/cjs/polyface/multiclip/XYPointBuckets.d.ts.map +1 -1
  231. package/lib/cjs/polyface/multiclip/XYPointBuckets.js +4 -8
  232. package/lib/cjs/polyface/multiclip/XYPointBuckets.js.map +1 -1
  233. package/lib/cjs/serialization/BGFBAccessors.d.ts.map +1 -1
  234. package/lib/cjs/serialization/BGFBAccessors.js +1 -0
  235. package/lib/cjs/serialization/BGFBAccessors.js.map +1 -1
  236. package/lib/cjs/serialization/BGFBReader.d.ts.map +1 -1
  237. package/lib/cjs/serialization/BGFBReader.js +37 -7
  238. package/lib/cjs/serialization/BGFBReader.js.map +1 -1
  239. package/lib/cjs/serialization/BGFBWriter.d.ts +4 -4
  240. package/lib/cjs/serialization/BGFBWriter.d.ts.map +1 -1
  241. package/lib/cjs/serialization/BGFBWriter.js +24 -40
  242. package/lib/cjs/serialization/BGFBWriter.js.map +1 -1
  243. package/lib/cjs/serialization/IModelJsonSchema.d.ts.map +1 -1
  244. package/lib/cjs/serialization/IModelJsonSchema.js +9 -3
  245. package/lib/cjs/serialization/IModelJsonSchema.js.map +1 -1
  246. package/lib/cjs/serialization/SerializationHelpers.d.ts +0 -3
  247. package/lib/cjs/serialization/SerializationHelpers.d.ts.map +1 -1
  248. package/lib/cjs/serialization/SerializationHelpers.js +16 -7
  249. package/lib/cjs/serialization/SerializationHelpers.js.map +1 -1
  250. package/lib/cjs/solid/Box.d.ts +2 -2
  251. package/lib/cjs/solid/Box.d.ts.map +1 -1
  252. package/lib/cjs/solid/Box.js.map +1 -1
  253. package/lib/cjs/solid/Cone.d.ts +3 -2
  254. package/lib/cjs/solid/Cone.d.ts.map +1 -1
  255. package/lib/cjs/solid/Cone.js +4 -1
  256. package/lib/cjs/solid/Cone.js.map +1 -1
  257. package/lib/cjs/solid/LinearSweep.d.ts +1 -1
  258. package/lib/cjs/solid/LinearSweep.d.ts.map +1 -1
  259. package/lib/cjs/solid/LinearSweep.js +1 -1
  260. package/lib/cjs/solid/LinearSweep.js.map +1 -1
  261. package/lib/cjs/solid/RotationalSweep.d.ts.map +1 -1
  262. package/lib/cjs/solid/RotationalSweep.js +1 -3
  263. package/lib/cjs/solid/RotationalSweep.js.map +1 -1
  264. package/lib/cjs/solid/TorusPipe.d.ts +4 -3
  265. package/lib/cjs/solid/TorusPipe.d.ts.map +1 -1
  266. package/lib/cjs/solid/TorusPipe.js.map +1 -1
  267. package/lib/cjs/topology/ChainMerge.d.ts +4 -4
  268. package/lib/cjs/topology/ChainMerge.d.ts.map +1 -1
  269. package/lib/cjs/topology/ChainMerge.js +11 -1
  270. package/lib/cjs/topology/ChainMerge.js.map +1 -1
  271. package/lib/cjs/topology/Graph.d.ts +2 -0
  272. package/lib/cjs/topology/Graph.d.ts.map +1 -1
  273. package/lib/cjs/topology/Graph.js +5 -0
  274. package/lib/cjs/topology/Graph.js.map +1 -1
  275. package/lib/cjs/topology/HalfEdgeGraphSearch.d.ts.map +1 -1
  276. package/lib/cjs/topology/HalfEdgeGraphSearch.js +2 -0
  277. package/lib/cjs/topology/HalfEdgeGraphSearch.js.map +1 -1
  278. package/lib/cjs/topology/HalfEdgePointInGraphSearch.d.ts.map +1 -1
  279. package/lib/cjs/topology/HalfEdgePointInGraphSearch.js +23 -16
  280. package/lib/cjs/topology/HalfEdgePointInGraphSearch.js.map +1 -1
  281. package/lib/cjs/topology/HalfEdgePositionDetail.d.ts +20 -9
  282. package/lib/cjs/topology/HalfEdgePositionDetail.d.ts.map +1 -1
  283. package/lib/cjs/topology/HalfEdgePositionDetail.js +17 -13
  284. package/lib/cjs/topology/HalfEdgePositionDetail.js.map +1 -1
  285. package/lib/cjs/topology/HalfEdgePriorityQueue.d.ts.map +1 -1
  286. package/lib/cjs/topology/HalfEdgePriorityQueue.js +3 -1
  287. package/lib/cjs/topology/HalfEdgePriorityQueue.js.map +1 -1
  288. package/lib/cjs/topology/InsertAndRetriangulateContext.d.ts +6 -2
  289. package/lib/cjs/topology/InsertAndRetriangulateContext.d.ts.map +1 -1
  290. package/lib/cjs/topology/InsertAndRetriangulateContext.js +41 -35
  291. package/lib/cjs/topology/InsertAndRetriangulateContext.js.map +1 -1
  292. package/lib/cjs/topology/MaskManager.d.ts +7 -3
  293. package/lib/cjs/topology/MaskManager.d.ts.map +1 -1
  294. package/lib/cjs/topology/MaskManager.js +10 -4
  295. package/lib/cjs/topology/MaskManager.js.map +1 -1
  296. package/lib/cjs/topology/RegularizeFace.d.ts.map +1 -1
  297. package/lib/cjs/topology/RegularizeFace.js.map +1 -1
  298. package/lib/cjs/topology/Triangulation.d.ts +2 -1
  299. package/lib/cjs/topology/Triangulation.d.ts.map +1 -1
  300. package/lib/cjs/topology/Triangulation.js +12 -7
  301. package/lib/cjs/topology/Triangulation.js.map +1 -1
  302. package/lib/esm/Geometry.d.ts +7 -0
  303. package/lib/esm/Geometry.d.ts.map +1 -1
  304. package/lib/esm/Geometry.js +9 -0
  305. package/lib/esm/Geometry.js.map +1 -1
  306. package/lib/esm/bspline/BSplineCurve.d.ts.map +1 -1
  307. package/lib/esm/bspline/BSplineCurve.js +2 -1
  308. package/lib/esm/bspline/BSplineCurve.js.map +1 -1
  309. package/lib/esm/bspline/BSplineCurveOps.d.ts.map +1 -1
  310. package/lib/esm/bspline/BSplineCurveOps.js +4 -1
  311. package/lib/esm/bspline/BSplineCurveOps.js.map +1 -1
  312. package/lib/esm/bspline/BezierCurve3d.d.ts.map +1 -1
  313. package/lib/esm/bspline/BezierCurve3d.js +14 -4
  314. package/lib/esm/bspline/BezierCurve3d.js.map +1 -1
  315. package/lib/esm/bspline/BezierCurve3dH.d.ts +2 -0
  316. package/lib/esm/bspline/BezierCurve3dH.d.ts.map +1 -1
  317. package/lib/esm/bspline/BezierCurve3dH.js +19 -3
  318. package/lib/esm/bspline/BezierCurve3dH.js.map +1 -1
  319. package/lib/esm/bspline/BezierCurveBase.d.ts +8 -2
  320. package/lib/esm/bspline/BezierCurveBase.d.ts.map +1 -1
  321. package/lib/esm/bspline/BezierCurveBase.js +10 -4
  322. package/lib/esm/bspline/BezierCurveBase.js.map +1 -1
  323. package/lib/esm/clipping/AlternatingConvexClipTree.js +4 -4
  324. package/lib/esm/clipping/AlternatingConvexClipTree.js.map +1 -1
  325. package/lib/esm/clipping/ClipPlane.d.ts +0 -3
  326. package/lib/esm/clipping/ClipPlane.d.ts.map +1 -1
  327. package/lib/esm/clipping/ClipPlane.js +9 -2
  328. package/lib/esm/clipping/ClipPlane.js.map +1 -1
  329. package/lib/esm/clipping/ClipPrimitive.d.ts +59 -9
  330. package/lib/esm/clipping/ClipPrimitive.d.ts.map +1 -1
  331. package/lib/esm/clipping/ClipPrimitive.js +124 -55
  332. package/lib/esm/clipping/ClipPrimitive.js.map +1 -1
  333. package/lib/esm/clipping/ClipUtils.js +1 -1
  334. package/lib/esm/clipping/ClipUtils.js.map +1 -1
  335. package/lib/esm/clipping/ClipVector.d.ts.map +1 -1
  336. package/lib/esm/clipping/ClipVector.js +12 -8
  337. package/lib/esm/clipping/ClipVector.js.map +1 -1
  338. package/lib/esm/clipping/ConvexClipPlaneSet.d.ts +0 -2
  339. package/lib/esm/clipping/ConvexClipPlaneSet.d.ts.map +1 -1
  340. package/lib/esm/clipping/ConvexClipPlaneSet.js +20 -19
  341. package/lib/esm/clipping/ConvexClipPlaneSet.js.map +1 -1
  342. package/lib/esm/clipping/internalContexts/LineStringOffsetClipperContext.d.ts +1 -1
  343. package/lib/esm/clipping/internalContexts/LineStringOffsetClipperContext.d.ts.map +1 -1
  344. package/lib/esm/clipping/internalContexts/LineStringOffsetClipperContext.js +4 -5
  345. package/lib/esm/clipping/internalContexts/LineStringOffsetClipperContext.js.map +1 -1
  346. package/lib/esm/core-geometry.d.ts +0 -1
  347. package/lib/esm/core-geometry.d.ts.map +1 -1
  348. package/lib/esm/core-geometry.js +0 -1
  349. package/lib/esm/core-geometry.js.map +1 -1
  350. package/lib/esm/curve/Arc3d.js +2 -2
  351. package/lib/esm/curve/Arc3d.js.map +1 -1
  352. package/lib/esm/curve/CurveChainWithDistanceIndex.d.ts +12 -4
  353. package/lib/esm/curve/CurveChainWithDistanceIndex.d.ts.map +1 -1
  354. package/lib/esm/curve/CurveChainWithDistanceIndex.js +53 -34
  355. package/lib/esm/curve/CurveChainWithDistanceIndex.js.map +1 -1
  356. package/lib/esm/curve/CurveCollection.d.ts.map +1 -1
  357. package/lib/esm/curve/CurveCollection.js +13 -6
  358. package/lib/esm/curve/CurveCollection.js.map +1 -1
  359. package/lib/esm/curve/CurveCurve.js +1 -1
  360. package/lib/esm/curve/CurveCurve.js.map +1 -1
  361. package/lib/esm/curve/CurveFactory.d.ts.map +1 -1
  362. package/lib/esm/curve/CurveFactory.js +13 -1
  363. package/lib/esm/curve/CurveFactory.js.map +1 -1
  364. package/lib/esm/curve/CurveLocationDetail.d.ts +12 -4
  365. package/lib/esm/curve/CurveLocationDetail.d.ts.map +1 -1
  366. package/lib/esm/curve/CurveLocationDetail.js +14 -5
  367. package/lib/esm/curve/CurveLocationDetail.js.map +1 -1
  368. package/lib/esm/curve/CurvePrimitive.d.ts +5 -4
  369. package/lib/esm/curve/CurvePrimitive.d.ts.map +1 -1
  370. package/lib/esm/curve/CurvePrimitive.js +7 -4
  371. package/lib/esm/curve/CurvePrimitive.js.map +1 -1
  372. package/lib/esm/curve/LineString3d.d.ts +25 -16
  373. package/lib/esm/curve/LineString3d.d.ts.map +1 -1
  374. package/lib/esm/curve/LineString3d.js +90 -72
  375. package/lib/esm/curve/LineString3d.js.map +1 -1
  376. package/lib/esm/curve/Path.d.ts +0 -3
  377. package/lib/esm/curve/Path.d.ts.map +1 -1
  378. package/lib/esm/curve/Path.js +9 -2
  379. package/lib/esm/curve/Path.js.map +1 -1
  380. package/lib/esm/curve/Query/InOutTests.js.map +1 -1
  381. package/lib/esm/curve/Query/PlanarSubdivision.d.ts.map +1 -1
  382. package/lib/esm/curve/Query/PlanarSubdivision.js +25 -31
  383. package/lib/esm/curve/Query/PlanarSubdivision.js.map +1 -1
  384. package/lib/esm/curve/Query/StrokeCountChain.d.ts +7 -1
  385. package/lib/esm/curve/Query/StrokeCountChain.d.ts.map +1 -1
  386. package/lib/esm/curve/Query/StrokeCountChain.js +27 -36
  387. package/lib/esm/curve/Query/StrokeCountChain.js.map +1 -1
  388. package/lib/esm/curve/RegionMomentsXY.d.ts.map +1 -1
  389. package/lib/esm/curve/RegionMomentsXY.js +7 -1
  390. package/lib/esm/curve/RegionMomentsXY.js.map +1 -1
  391. package/lib/esm/curve/RegionOps.d.ts.map +1 -1
  392. package/lib/esm/curve/RegionOps.js +8 -5
  393. package/lib/esm/curve/RegionOps.js.map +1 -1
  394. package/lib/esm/curve/RegionOpsClassificationSweeps.d.ts.map +1 -1
  395. package/lib/esm/curve/RegionOpsClassificationSweeps.js +6 -6
  396. package/lib/esm/curve/RegionOpsClassificationSweeps.js.map +1 -1
  397. package/lib/esm/curve/internalContexts/AnnounceTangentStrokeHandler.d.ts.map +1 -1
  398. package/lib/esm/curve/internalContexts/AnnounceTangentStrokeHandler.js +4 -1
  399. package/lib/esm/curve/internalContexts/AnnounceTangentStrokeHandler.js.map +1 -1
  400. package/lib/esm/curve/internalContexts/ClosestPointStrokeHandler.d.ts.map +1 -1
  401. package/lib/esm/curve/internalContexts/ClosestPointStrokeHandler.js +6 -1
  402. package/lib/esm/curve/internalContexts/ClosestPointStrokeHandler.js.map +1 -1
  403. package/lib/esm/curve/internalContexts/CurveCurveCloseApproachXY.d.ts +5 -21
  404. package/lib/esm/curve/internalContexts/CurveCurveCloseApproachXY.d.ts.map +1 -1
  405. package/lib/esm/curve/internalContexts/CurveCurveCloseApproachXY.js +29 -73
  406. package/lib/esm/curve/internalContexts/CurveCurveCloseApproachXY.js.map +1 -1
  407. package/lib/esm/curve/internalContexts/CurveCurveIntersectXY.d.ts +55 -13
  408. package/lib/esm/curve/internalContexts/CurveCurveIntersectXY.d.ts.map +1 -1
  409. package/lib/esm/curve/internalContexts/CurveCurveIntersectXY.js +239 -111
  410. package/lib/esm/curve/internalContexts/CurveCurveIntersectXY.js.map +1 -1
  411. package/lib/esm/curve/internalContexts/PolygonOffsetContext.js +1 -1
  412. package/lib/esm/curve/internalContexts/PolygonOffsetContext.js.map +1 -1
  413. package/lib/esm/curve/spiral/DirectSpiral3d.d.ts +1 -4
  414. package/lib/esm/curve/spiral/DirectSpiral3d.d.ts.map +1 -1
  415. package/lib/esm/curve/spiral/DirectSpiral3d.js +9 -9
  416. package/lib/esm/curve/spiral/DirectSpiral3d.js.map +1 -1
  417. package/lib/esm/curve/spiral/IntegratedSpiral3d.d.ts +11 -14
  418. package/lib/esm/curve/spiral/IntegratedSpiral3d.d.ts.map +1 -1
  419. package/lib/esm/curve/spiral/IntegratedSpiral3d.js +18 -18
  420. package/lib/esm/curve/spiral/IntegratedSpiral3d.js.map +1 -1
  421. package/lib/esm/curve/spiral/TransitionConditionalProperties.d.ts +7 -1
  422. package/lib/esm/curve/spiral/TransitionConditionalProperties.d.ts.map +1 -1
  423. package/lib/esm/curve/spiral/TransitionConditionalProperties.js.map +1 -1
  424. package/lib/esm/geometry3d/Ellipsoid.d.ts +19 -7
  425. package/lib/esm/geometry3d/Ellipsoid.d.ts.map +1 -1
  426. package/lib/esm/geometry3d/Ellipsoid.js +26 -11
  427. package/lib/esm/geometry3d/Ellipsoid.js.map +1 -1
  428. package/lib/esm/geometry3d/FrustumAnimation.d.ts.map +1 -1
  429. package/lib/esm/geometry3d/FrustumAnimation.js +11 -1
  430. package/lib/esm/geometry3d/FrustumAnimation.js.map +1 -1
  431. package/lib/esm/geometry3d/GrowableFloat64Array.d.ts +5 -1
  432. package/lib/esm/geometry3d/GrowableFloat64Array.d.ts.map +1 -1
  433. package/lib/esm/geometry3d/GrowableFloat64Array.js +11 -1
  434. package/lib/esm/geometry3d/GrowableFloat64Array.js.map +1 -1
  435. package/lib/esm/geometry3d/GrowableXYArray.d.ts +1 -1
  436. package/lib/esm/geometry3d/GrowableXYArray.js +1 -1
  437. package/lib/esm/geometry3d/GrowableXYArray.js.map +1 -1
  438. package/lib/esm/geometry3d/GrowableXYZArray.d.ts +49 -8
  439. package/lib/esm/geometry3d/GrowableXYZArray.d.ts.map +1 -1
  440. package/lib/esm/geometry3d/GrowableXYZArray.js +90 -37
  441. package/lib/esm/geometry3d/GrowableXYZArray.js.map +1 -1
  442. package/lib/esm/geometry3d/IndexedXYZCollection.d.ts +100 -3
  443. package/lib/esm/geometry3d/IndexedXYZCollection.d.ts.map +1 -1
  444. package/lib/esm/geometry3d/IndexedXYZCollection.js +125 -0
  445. package/lib/esm/geometry3d/IndexedXYZCollection.js.map +1 -1
  446. package/lib/esm/geometry3d/Matrix3d.d.ts +10 -1
  447. package/lib/esm/geometry3d/Matrix3d.d.ts.map +1 -1
  448. package/lib/esm/geometry3d/Matrix3d.js +53 -34
  449. package/lib/esm/geometry3d/Matrix3d.js.map +1 -1
  450. package/lib/esm/geometry3d/Plane3dByOriginAndUnitNormal.js +1 -1
  451. package/lib/esm/geometry3d/Plane3dByOriginAndUnitNormal.js.map +1 -1
  452. package/lib/esm/geometry3d/Point3dArrayCarrier.d.ts +49 -2
  453. package/lib/esm/geometry3d/Point3dArrayCarrier.d.ts.map +1 -1
  454. package/lib/esm/geometry3d/Point3dArrayCarrier.js +67 -9
  455. package/lib/esm/geometry3d/Point3dArrayCarrier.js.map +1 -1
  456. package/lib/esm/geometry3d/Point3dVector3d.d.ts +1 -1
  457. package/lib/esm/geometry3d/Point3dVector3d.js +1 -1
  458. package/lib/esm/geometry3d/Point3dVector3d.js.map +1 -1
  459. package/lib/esm/geometry3d/PointStreaming.js +1 -1
  460. package/lib/esm/geometry3d/PointStreaming.js.map +1 -1
  461. package/lib/esm/geometry3d/PolygonOps.d.ts +24 -32
  462. package/lib/esm/geometry3d/PolygonOps.d.ts.map +1 -1
  463. package/lib/esm/geometry3d/PolygonOps.js +147 -180
  464. package/lib/esm/geometry3d/PolygonOps.js.map +1 -1
  465. package/lib/esm/geometry3d/PolylineCompressionByEdgeOffset.js +5 -5
  466. package/lib/esm/geometry3d/PolylineCompressionByEdgeOffset.js.map +1 -1
  467. package/lib/esm/geometry3d/PolylineOps.d.ts.map +1 -1
  468. package/lib/esm/geometry3d/PolylineOps.js +13 -3
  469. package/lib/esm/geometry3d/PolylineOps.js.map +1 -1
  470. package/lib/esm/geometry3d/Range.js.map +1 -1
  471. package/lib/esm/geometry3d/Ray3d.d.ts +0 -3
  472. package/lib/esm/geometry3d/Ray3d.d.ts.map +1 -1
  473. package/lib/esm/geometry3d/Ray3d.js +5 -1
  474. package/lib/esm/geometry3d/Ray3d.js.map +1 -1
  475. package/lib/esm/geometry3d/SortablePolygon.d.ts +2 -2
  476. package/lib/esm/geometry3d/SortablePolygon.d.ts.map +1 -1
  477. package/lib/esm/geometry3d/SortablePolygon.js +14 -18
  478. package/lib/esm/geometry3d/SortablePolygon.js.map +1 -1
  479. package/lib/esm/geometry3d/Transform.d.ts +8 -0
  480. package/lib/esm/geometry3d/Transform.d.ts.map +1 -1
  481. package/lib/esm/geometry3d/Transform.js +15 -9
  482. package/lib/esm/geometry3d/Transform.js.map +1 -1
  483. package/lib/esm/numerics/ClusterableArray.d.ts +4 -2
  484. package/lib/esm/numerics/ClusterableArray.d.ts.map +1 -1
  485. package/lib/esm/numerics/ClusterableArray.js +6 -4
  486. package/lib/esm/numerics/ClusterableArray.js.map +1 -1
  487. package/lib/esm/numerics/Newton.d.ts +3 -1
  488. package/lib/esm/numerics/Newton.d.ts.map +1 -1
  489. package/lib/esm/numerics/Newton.js +5 -1
  490. package/lib/esm/numerics/Newton.js.map +1 -1
  491. package/lib/esm/polyface/AuxData.d.ts +1 -4
  492. package/lib/esm/polyface/AuxData.d.ts.map +1 -1
  493. package/lib/esm/polyface/AuxData.js +5 -1
  494. package/lib/esm/polyface/AuxData.js.map +1 -1
  495. package/lib/esm/polyface/GreedyTriangulationBetweenLineStrings.js +3 -3
  496. package/lib/esm/polyface/GreedyTriangulationBetweenLineStrings.js.map +1 -1
  497. package/lib/esm/polyface/Polyface.d.ts.map +1 -1
  498. package/lib/esm/polyface/Polyface.js +14 -16
  499. package/lib/esm/polyface/Polyface.js.map +1 -1
  500. package/lib/esm/polyface/PolyfaceBuilder.d.ts +84 -28
  501. package/lib/esm/polyface/PolyfaceBuilder.d.ts.map +1 -1
  502. package/lib/esm/polyface/PolyfaceBuilder.js +277 -217
  503. package/lib/esm/polyface/PolyfaceBuilder.js.map +1 -1
  504. package/lib/esm/polyface/PolyfaceClip.d.ts +4 -3
  505. package/lib/esm/polyface/PolyfaceClip.d.ts.map +1 -1
  506. package/lib/esm/polyface/PolyfaceClip.js +11 -4
  507. package/lib/esm/polyface/PolyfaceClip.js.map +1 -1
  508. package/lib/esm/polyface/PolyfaceData.js.map +1 -1
  509. package/lib/esm/polyface/PolyfaceQuery.d.ts.map +1 -1
  510. package/lib/esm/polyface/PolyfaceQuery.js +9 -7
  511. package/lib/esm/polyface/PolyfaceQuery.js.map +1 -1
  512. package/lib/esm/polyface/RangeTree/LineString3dRangeTreeContext.d.ts.map +1 -1
  513. package/lib/esm/polyface/RangeTree/LineString3dRangeTreeContext.js +3 -2
  514. package/lib/esm/polyface/RangeTree/LineString3dRangeTreeContext.js.map +1 -1
  515. package/lib/esm/polyface/RangeTree/RangeTreeNode.d.ts +1 -1
  516. package/lib/esm/polyface/RangeTree/RangeTreeNode.js +2 -2
  517. package/lib/esm/polyface/RangeTree/RangeTreeNode.js.map +1 -1
  518. package/lib/esm/polyface/RangeTree/RangeTreeSearchHandlers.d.ts.map +1 -1
  519. package/lib/esm/polyface/RangeTree/RangeTreeSearchHandlers.js +14 -12
  520. package/lib/esm/polyface/RangeTree/RangeTreeSearchHandlers.js.map +1 -1
  521. package/lib/esm/polyface/multiclip/BuildAverageNormalsContext.d.ts +1 -1
  522. package/lib/esm/polyface/multiclip/BuildAverageNormalsContext.d.ts.map +1 -1
  523. package/lib/esm/polyface/multiclip/BuildAverageNormalsContext.js +10 -6
  524. package/lib/esm/polyface/multiclip/BuildAverageNormalsContext.js.map +1 -1
  525. package/lib/esm/polyface/multiclip/OffsetMeshContext.js +4 -3
  526. package/lib/esm/polyface/multiclip/OffsetMeshContext.js.map +1 -1
  527. package/lib/esm/polyface/multiclip/SweepLineStringToFacetContext.d.ts.map +1 -1
  528. package/lib/esm/polyface/multiclip/SweepLineStringToFacetContext.js +3 -5
  529. package/lib/esm/polyface/multiclip/SweepLineStringToFacetContext.js.map +1 -1
  530. package/lib/esm/polyface/multiclip/XYPointBuckets.d.ts +1 -1
  531. package/lib/esm/polyface/multiclip/XYPointBuckets.d.ts.map +1 -1
  532. package/lib/esm/polyface/multiclip/XYPointBuckets.js +4 -8
  533. package/lib/esm/polyface/multiclip/XYPointBuckets.js.map +1 -1
  534. package/lib/esm/serialization/BGFBAccessors.d.ts.map +1 -1
  535. package/lib/esm/serialization/BGFBAccessors.js +1 -0
  536. package/lib/esm/serialization/BGFBAccessors.js.map +1 -1
  537. package/lib/esm/serialization/BGFBReader.d.ts.map +1 -1
  538. package/lib/esm/serialization/BGFBReader.js +37 -7
  539. package/lib/esm/serialization/BGFBReader.js.map +1 -1
  540. package/lib/esm/serialization/BGFBWriter.d.ts +4 -4
  541. package/lib/esm/serialization/BGFBWriter.d.ts.map +1 -1
  542. package/lib/esm/serialization/BGFBWriter.js +24 -40
  543. package/lib/esm/serialization/BGFBWriter.js.map +1 -1
  544. package/lib/esm/serialization/IModelJsonSchema.d.ts.map +1 -1
  545. package/lib/esm/serialization/IModelJsonSchema.js +9 -3
  546. package/lib/esm/serialization/IModelJsonSchema.js.map +1 -1
  547. package/lib/esm/serialization/SerializationHelpers.d.ts +0 -3
  548. package/lib/esm/serialization/SerializationHelpers.d.ts.map +1 -1
  549. package/lib/esm/serialization/SerializationHelpers.js +16 -7
  550. package/lib/esm/serialization/SerializationHelpers.js.map +1 -1
  551. package/lib/esm/solid/Box.d.ts +2 -2
  552. package/lib/esm/solid/Box.d.ts.map +1 -1
  553. package/lib/esm/solid/Box.js.map +1 -1
  554. package/lib/esm/solid/Cone.d.ts +3 -2
  555. package/lib/esm/solid/Cone.d.ts.map +1 -1
  556. package/lib/esm/solid/Cone.js +4 -1
  557. package/lib/esm/solid/Cone.js.map +1 -1
  558. package/lib/esm/solid/LinearSweep.d.ts +1 -1
  559. package/lib/esm/solid/LinearSweep.d.ts.map +1 -1
  560. package/lib/esm/solid/LinearSweep.js +1 -1
  561. package/lib/esm/solid/LinearSweep.js.map +1 -1
  562. package/lib/esm/solid/RotationalSweep.d.ts.map +1 -1
  563. package/lib/esm/solid/RotationalSweep.js +1 -3
  564. package/lib/esm/solid/RotationalSweep.js.map +1 -1
  565. package/lib/esm/solid/TorusPipe.d.ts +4 -3
  566. package/lib/esm/solid/TorusPipe.d.ts.map +1 -1
  567. package/lib/esm/solid/TorusPipe.js.map +1 -1
  568. package/lib/esm/topology/ChainMerge.d.ts +4 -4
  569. package/lib/esm/topology/ChainMerge.d.ts.map +1 -1
  570. package/lib/esm/topology/ChainMerge.js +11 -1
  571. package/lib/esm/topology/ChainMerge.js.map +1 -1
  572. package/lib/esm/topology/Graph.d.ts +2 -0
  573. package/lib/esm/topology/Graph.d.ts.map +1 -1
  574. package/lib/esm/topology/Graph.js +5 -0
  575. package/lib/esm/topology/Graph.js.map +1 -1
  576. package/lib/esm/topology/HalfEdgeGraphSearch.d.ts.map +1 -1
  577. package/lib/esm/topology/HalfEdgeGraphSearch.js +2 -0
  578. package/lib/esm/topology/HalfEdgeGraphSearch.js.map +1 -1
  579. package/lib/esm/topology/HalfEdgePointInGraphSearch.d.ts.map +1 -1
  580. package/lib/esm/topology/HalfEdgePointInGraphSearch.js +23 -16
  581. package/lib/esm/topology/HalfEdgePointInGraphSearch.js.map +1 -1
  582. package/lib/esm/topology/HalfEdgePositionDetail.d.ts +20 -9
  583. package/lib/esm/topology/HalfEdgePositionDetail.d.ts.map +1 -1
  584. package/lib/esm/topology/HalfEdgePositionDetail.js +17 -13
  585. package/lib/esm/topology/HalfEdgePositionDetail.js.map +1 -1
  586. package/lib/esm/topology/HalfEdgePriorityQueue.d.ts.map +1 -1
  587. package/lib/esm/topology/HalfEdgePriorityQueue.js +4 -2
  588. package/lib/esm/topology/HalfEdgePriorityQueue.js.map +1 -1
  589. package/lib/esm/topology/InsertAndRetriangulateContext.d.ts +6 -2
  590. package/lib/esm/topology/InsertAndRetriangulateContext.d.ts.map +1 -1
  591. package/lib/esm/topology/InsertAndRetriangulateContext.js +41 -35
  592. package/lib/esm/topology/InsertAndRetriangulateContext.js.map +1 -1
  593. package/lib/esm/topology/MaskManager.d.ts +7 -3
  594. package/lib/esm/topology/MaskManager.d.ts.map +1 -1
  595. package/lib/esm/topology/MaskManager.js +10 -4
  596. package/lib/esm/topology/MaskManager.js.map +1 -1
  597. package/lib/esm/topology/RegularizeFace.d.ts.map +1 -1
  598. package/lib/esm/topology/RegularizeFace.js.map +1 -1
  599. package/lib/esm/topology/Triangulation.d.ts +2 -1
  600. package/lib/esm/topology/Triangulation.d.ts.map +1 -1
  601. package/lib/esm/topology/Triangulation.js +12 -7
  602. package/lib/esm/topology/Triangulation.js.map +1 -1
  603. package/package.json +3 -3
  604. package/lib/cjs/serialization/GeometrySamples.d.ts +0 -705
  605. package/lib/cjs/serialization/GeometrySamples.d.ts.map +0 -1
  606. package/lib/cjs/serialization/GeometrySamples.js +0 -2433
  607. package/lib/cjs/serialization/GeometrySamples.js.map +0 -1
  608. package/lib/esm/serialization/GeometrySamples.d.ts +0 -705
  609. package/lib/esm/serialization/GeometrySamples.d.ts.map +0 -1
  610. package/lib/esm/serialization/GeometrySamples.js +0 -2428
  611. package/lib/esm/serialization/GeometrySamples.js.map +0 -1
@@ -2,6 +2,10 @@
2
2
  * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
3
  * See LICENSE.md in the project root for license terms and full copyright notice.
4
4
  *--------------------------------------------------------------------------------------------*/
5
+ /** @packageDocumentation
6
+ * @module CartesianGeometry
7
+ */
8
+ import { assert } from "@itwin/core-bentley";
5
9
  import { AxisOrder, Geometry } from "../Geometry";
6
10
  import { GrowableFloat64Array } from "../geometry3d/GrowableFloat64Array";
7
11
  import { GrowableXYZArray } from "../geometry3d/GrowableXYZArray";
@@ -247,8 +251,11 @@ export class ClipPlane extends Plane3d {
247
251
  */
248
252
  getPlane3d() {
249
253
  const d = this._distanceFromOrigin;
250
- // normal should be normalized, will not return undefined
251
- return Plane3dByOriginAndUnitNormal.create(Point3d.create(this._inwardNormal.x * d, this._inwardNormal.y * d, this._inwardNormal.z * d), this._inwardNormal);
254
+ const origin = Point3d.create(this._inwardNormal.x * d, this._inwardNormal.y * d, this._inwardNormal.z * d);
255
+ const plane = Plane3dByOriginAndUnitNormal.createXYPlane();
256
+ const result = Plane3dByOriginAndUnitNormal.create(origin, this._inwardNormal, plane);
257
+ assert(result !== undefined, "this._inwardNormal should be normalized by constructors. Fix caller if this fails.");
258
+ return plane;
252
259
  }
253
260
  /**
254
261
  * Return the Point4d d form of the plane.
@@ -1 +1 @@
1
- {"version":3,"file":"ClipPlane.js","sourceRoot":"","sources":["../../../src/clipping/ClipPlane.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAQ/F,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAElD,OAAO,EAAE,oBAAoB,EAAE,MAAM,oCAAoC,CAAC;AAC1E,OAAO,EAAE,gBAAgB,EAAE,MAAM,gCAAgC,CAAC;AAElE,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAClD,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAChD,OAAO,EAAE,4BAA4B,EAAE,MAAM,4CAA4C,CAAC;AA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,CAAS,EAAE,MAAgB;QACjF,MAAM,KAAK,GAAG,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;QACzC,OAAO,OAAO,CAAC,MAAM,CAAC,CAAC,GAAG,KAAK,GAAG,IAAI,CAAC,aAAa,CAAC,CAAC,EAAE,CAAC,GAAG,KAAK,GAAG,IAAI,CAAC,aAAa,CAAC,CAAC,EAAE,CAAC,GAAG,KAAK,GAAG,IAAI,CAAC,aAAa,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC;IACtI,CAAC","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\r\n/** @packageDocumentation\r\n * @module CartesianGeometry\r\n */\r\n\r\nimport { Arc3d } from \"../curve/Arc3d\";\r\nimport { AnnounceNumberNumberCurvePrimitive } from \"../curve/CurvePrimitive\";\r\nimport { AxisOrder, Geometry } from \"../Geometry\";\r\nimport { Angle } from \"../geometry3d/Angle\";\r\nimport { GrowableFloat64Array } from \"../geometry3d/GrowableFloat64Array\";\r\nimport { GrowableXYZArray } from \"../geometry3d/GrowableXYZArray\";\r\nimport { IndexedXYZCollection } from \"../geometry3d/IndexedXYZCollection\";\r\nimport { Matrix3d } from \"../geometry3d/Matrix3d\";\r\nimport { Plane3d } from \"../geometry3d/Plane3d\";\r\nimport { Plane3dByOriginAndUnitNormal } from \"../geometry3d/Plane3dByOriginAndUnitNormal\";\r\nimport { Point3d, Vector3d } from \"../geometry3d/Point3dVector3d\";\r\nimport { IndexedXYZCollectionPolygonOps } from \"../geometry3d/PolygonOps\";\r\nimport { Range1d, Range3d } from \"../geometry3d/Range\";\r\nimport { GrowableXYZArrayCache } from \"../geometry3d/ReusableObjectCache\";\r\nimport { Transform } from \"../geometry3d/Transform\";\r\nimport { XYAndZ, XYZProps } from \"../geometry3d/XYZProps\";\r\nimport { Matrix4d } from \"../geometry4d/Matrix4d\";\r\nimport { Point4d } from \"../geometry4d/Point4d\";\r\nimport { AnalyticRoots } from \"../numerics/Polynomials\";\r\nimport { Clipper, ClipUtilities, PolygonClipper } from \"./ClipUtils\";\r\n\r\n/**\r\n * Wire format describing a [[ClipPlane]].\r\n * If either [[normal]] or [[dist]] are omitted, defaults to a normal of [[Vector3d.unitZ]] and a distance of zero.\r\n * @public\r\n */\r\nexport interface ClipPlaneProps {\r\n /** The plane's inward normal. */\r\n normal?: XYZProps;\r\n /** The plane's signed distance from the origin. */\r\n dist?: number;\r\n /** Defaults to `false`. Interpretation of this flag is algorithm-specific. */\r\n invisible?: boolean;\r\n /** Defaults to `false`. Interpretation of this flag is algorithm-specific. */\r\n interior?: boolean;\r\n}\r\n\r\n/**\r\n * A ClipPlane is a single plane represented as\r\n * * An inward unit normal (u,v,w)\r\n * * A signedDistance\r\n * More details can be found at docs/learning/geometry/Clipping.md\r\n *\r\n * Hence\r\n * * The halfspace function evaluation for \"point\" (x,y,z) is `(x,y,z) DOT (u,v,w) - signedDistance`.\r\n * * POSITIVE values of the halfspace function are \"inside\".\r\n * * ZERO value of the halfspace function is \"on\".\r\n * * NEGATIVE value of the halfspace function is \"outside\".\r\n * * A representative point on the plane is (signedDistance * u, signedDistance * v, signedDistance * w).\r\n * * Given a point on the plane and the inward normal of the plane, `signedDistance = point DOT normal`.\r\n * @public\r\n */\r\nexport class ClipPlane extends Plane3d implements Clipper, PolygonClipper {\r\n private _inwardNormal: Vector3d;\r\n /**\r\n * Construct a parallel plane through the origin.\r\n * * Move it to the actual position.\r\n * * _distanceFromOrigin is the distance it moved, with the (inward) normal direction as positive\r\n */\r\n private _distanceFromOrigin: number;\r\n private _invisible: boolean;\r\n private _interior: boolean;\r\n\r\n private constructor(normal: Vector3d, distance: number, invisible: boolean, interior: boolean) {\r\n super();\r\n this._invisible = invisible;\r\n this._interior = interior;\r\n this._inwardNormal = normal;\r\n this._distanceFromOrigin = distance;\r\n }\r\n /*\r\n private safeSetXYZDistance(nx: number, ny: number, nz: number, d: number) {\r\n this._inwardNormal.set(nx, ny, nz);\r\n this._distanceFromOrigin = d;\r\n }\r\n */\r\n /**\r\n * Return true if all members are almostEqual to corresponding members of other.\r\n * @param other clip plane to compare\r\n */\r\n public isAlmostEqual(other: ClipPlane): boolean {\r\n return Geometry.isSameCoordinate(this._distanceFromOrigin, other._distanceFromOrigin)\r\n && this._inwardNormal.isAlmostEqual(other._inwardNormal)\r\n && this._interior === other._interior\r\n && this._invisible === other._invisible;\r\n }\r\n /** Return a cloned plane */\r\n public clone(): ClipPlane {\r\n const result = new ClipPlane(this._inwardNormal.clone(), this._distanceFromOrigin, this._invisible, this._interior);\r\n return result;\r\n }\r\n /** Return a cloned plane with coordinate data negated. */\r\n public cloneNegated(): ClipPlane {\r\n const plane = new ClipPlane(this._inwardNormal.clone(), this._distanceFromOrigin, this._invisible, this._interior);\r\n plane.negateInPlace();\r\n return plane;\r\n }\r\n /** Create a ClipPlane from Plane3dByOriginAndUnitNormal. */\r\n public static createPlane(\r\n plane: Plane3dByOriginAndUnitNormal, invisible: boolean = false, interior: boolean = false, result?: ClipPlane,\r\n ): ClipPlane {\r\n const distance = plane.getNormalRef().dotProduct(plane.getOriginRef());\r\n if (result) {\r\n result._invisible = invisible;\r\n result._interior = interior;\r\n result._inwardNormal = plane.getNormalRef().clone();\r\n result._distanceFromOrigin = distance;\r\n return result;\r\n }\r\n return new ClipPlane(plane.getNormalRef().clone(), distance, invisible, interior);\r\n }\r\n /**\r\n * Create a ClipPlane with direct normal and signedDistance.\r\n * * The vector is normalized for storage.\r\n */\r\n public static createNormalAndDistance(\r\n normal: Vector3d, distance: number, invisible: boolean = false, interior: boolean = false, result?: ClipPlane,\r\n ): ClipPlane | undefined {\r\n const normalized = normal.normalize();\r\n if (normalized) {\r\n if (result) {\r\n result._invisible = invisible;\r\n result._interior = interior;\r\n result._inwardNormal = normalized;\r\n result._distanceFromOrigin = distance;\r\n }\r\n return new ClipPlane(normalized, distance, invisible, interior);\r\n }\r\n return undefined;\r\n }\r\n /**\r\n * Create a ClipPlane\r\n * * \"normal\" is the inward normal of the plane (it is internally normalized).\r\n * * \"point\" is any point of the plane.\r\n * * The stored distance for the plane is the dot product of the point with the normal (i.e. treat the point's xyz as\r\n * a vector from the origin.)\r\n */\r\n public static createNormalAndPoint(\r\n normal: Vector3d, point: XYAndZ, invisible: boolean = false, interior: boolean = false, result?: ClipPlane,\r\n ): ClipPlane | undefined {\r\n const normalized = normal.normalize();\r\n if (normalized) {\r\n const distance = normalized.dotProduct(point);\r\n if (result) {\r\n result._invisible = invisible;\r\n result._interior = interior;\r\n result._inwardNormal = normalized;\r\n result._distanceFromOrigin = distance;\r\n }\r\n return new ClipPlane(normalized, distance, invisible, interior);\r\n }\r\n return undefined;\r\n }\r\n /**\r\n * Create a clip plane\r\n * @param origin any point on the plane.\r\n * @param vectorA any vector in the plane\r\n * @param vectorB any vector in the plane\r\n * @return undefined if the vectors are not independent.\r\n * * The stored inward normal is vectorB.crossProduct(vectorA).\r\n * * That is, the vectors are considered as a right-handed pair when viewed from the outside.\r\n */\r\n public static createOriginAndVectors(\r\n origin: Point3d,\r\n vectorA: Vector3d,\r\n vectorB: Vector3d,\r\n invisible: boolean = false,\r\n interior: boolean = false,\r\n result?: ClipPlane,\r\n ): ClipPlane | undefined {\r\n const normalized = vectorB.crossProduct(vectorA);\r\n return this.createNormalAndPoint(normalized, origin, invisible, interior, result);\r\n }\r\n /**\r\n * Create a ClipPlane\r\n * * \"normal\" (normalX, normalY, normalZ) is the inward normal of the plane.\r\n * * \"point\" (originX,originY,originZ) is any point of the plane.\r\n * * The stored distance for the plane is the dot product of the point with the normal (i.e. treat the point's xyz\r\n * as a vector from the origin.)\r\n */\r\n public static createNormalAndPointXYZXYZ(\r\n normalX: number, normalY: number, normalZ: number,\r\n originX: number, originY: number, originZ: number,\r\n invisible: boolean = false, interior: boolean = false,\r\n result?: ClipPlane,\r\n ): ClipPlane | undefined {\r\n const q = Geometry.hypotenuseXYZ(normalX, normalY, normalZ);\r\n const r = Geometry.conditionalDivideFraction(1, q);\r\n if (r !== undefined) {\r\n if (result) {\r\n result._inwardNormal.set(normalX * r, normalY * r, normalZ * r);\r\n result._distanceFromOrigin = result._inwardNormal.dotProductXYZ(originX, originY, originZ);\r\n result._invisible = invisible;\r\n result._interior = interior;\r\n return result;\r\n }\r\n const normal = Vector3d.create(normalX * r, normalY * r, normalZ * r);\r\n return new ClipPlane(normal, normal.dotProductXYZ(originX, originY, originZ), invisible, interior);\r\n }\r\n return undefined;\r\n }\r\n /**\r\n * Return a json object of the form\r\n * `{\"normal\":[u,v,w],\"dist\":signedDistanceValue,\"interior\":true,\"invisible\":true}`\r\n */\r\n public toJSON(): ClipPlaneProps {\r\n const props: ClipPlaneProps = {\r\n normal: this.inwardNormalRef.toJSON(),\r\n dist: this.distance,\r\n };\r\n if (this.interior)\r\n props.interior = true;\r\n if (this.invisible)\r\n props.invisible = true;\r\n return props;\r\n }\r\n /** Parse json object to ClipPlane instance */\r\n public static fromJSON(json: ClipPlaneProps, result?: ClipPlane): ClipPlane | undefined {\r\n if (json && json.normal && undefined !== json.dist && Number.isFinite(json.dist))\r\n return ClipPlane.createNormalAndDistance(\r\n Vector3d.fromJSON(json.normal), json.dist, !!json.invisible, !!json.interior,\r\n );\r\n return ClipPlane.createNormalAndDistance(Vector3d.unitZ(), 0, false, false, result);\r\n }\r\n /** Set both the invisible and interior flags. */\r\n public setFlags(invisible: boolean, interior: boolean) {\r\n this._invisible = invisible;\r\n this._interior = interior;\r\n }\r\n /** Return the stored distanceFromOrigin property. */\r\n public get distance() {\r\n return this._distanceFromOrigin;\r\n }\r\n /** * Return the stored inward normal property. */\r\n public get inwardNormalRef(): Vector3d {\r\n return this._inwardNormal;\r\n }\r\n /** Return the \"interior\" property flag. Interpretation of this flag is algorithm-specific. */\r\n public get interior() {\r\n return this._interior;\r\n }\r\n /** Return the \"invisible\" property flag. Interpretation of this flag is algorithm-specific. */\r\n public get invisible() {\r\n return this._invisible;\r\n }\r\n /**\r\n * Create a plane defined by two points, an up vector, and a tilt angle relative to the up vector.\r\n * @param point0 start point of the edge\r\n * @param point1 end point of the edge\r\n * @param upVector vector perpendicular to the plane\r\n * @param tiltAngle angle to tilt the plane around the edge in the direction of the up vector.\r\n * @param result optional preallocated plane\r\n */\r\n public static createEdgeAndUpVector(\r\n point0: Point3d, point1: Point3d, upVector: Vector3d, tiltAngle?: Angle, result?: ClipPlane,\r\n ): ClipPlane | undefined {\r\n const edgeVector = Vector3d.createFrom(point1.minus(point0));\r\n let normal = (upVector.crossProduct(edgeVector)).normalize();\r\n\r\n if (normal) {\r\n if (tiltAngle !== undefined && !tiltAngle.isAlmostZero) {\r\n const tiltNormal = Vector3d.createRotateVectorAroundVector(normal, edgeVector, tiltAngle);\r\n if (tiltNormal) {\r\n normal = tiltNormal.clone();\r\n }\r\n }\r\n normal.negate(normal);\r\n return ClipPlane.createNormalAndPoint(normal, point0, false, false, result);\r\n }\r\n return undefined;\r\n }\r\n /** Create a plane perpendicular to the edge between the xy parts of point0 and point1. */\r\n public static createEdgeXY(point0: XYAndZ, point1: XYAndZ, result?: ClipPlane): ClipPlane | undefined {\r\n const normal = Vector3d.create(point0.y - point1.y, point1.x - point0.x);\r\n if (normal.normalizeInPlace())\r\n return ClipPlane.createNormalAndPoint(normal, point0, false, false, result);\r\n return undefined;\r\n }\r\n /**\r\n * Variant of [[createEdgeXY]] that computes the plane using the edge midpoint instead of its start point.\r\n * * This is more stable for creating a pair of clip planes from a long edge and its reversal, as is commonly found\r\n * in a [[UnionOfConvexClipPlaneSets]].\r\n */\r\n public static createMidPointEdgeXY(point0: XYAndZ, point1: XYAndZ, result?: ClipPlane): ClipPlane | undefined {\r\n return ClipPlane.createNormalAndPointXYZXYZ(\r\n point0.y - point1.y, point1.x - point0.x, 0,\r\n 0.5 * (point0.x + point1.x), 0.5 * (point0.y + point1.y), 0,\r\n false, false, result,\r\n );\r\n }\r\n /**\r\n * Return the Plane3d form of the plane.\r\n * * The plane origin is the point `distance * inwardNormal`\r\n * * The plane normal is the inward normal of the ClipPlane.\r\n */\r\n public getPlane3d(): Plane3dByOriginAndUnitNormal {\r\n const d = this._distanceFromOrigin;\r\n // normal should be normalized, will not return undefined\r\n return Plane3dByOriginAndUnitNormal.create(\r\n Point3d.create(this._inwardNormal.x * d, this._inwardNormal.y * d, this._inwardNormal.z * d),\r\n this._inwardNormal,\r\n )!;\r\n }\r\n /**\r\n * Return the Point4d d form of the plane.\r\n * * The homogeneous xyz are the inward normal xyz.\r\n * * The homogeneous weight is the negated ClipPlane distance.\r\n */\r\n public getPlane4d(): Point4d {\r\n return Point4d.create(\r\n this._inwardNormal.x, this._inwardNormal.y, this._inwardNormal.z, - this._distanceFromOrigin,\r\n );\r\n }\r\n /**\r\n * Set the plane from DPoint4d style plane.\r\n * * The saved plane has its direction normalized.\r\n * * This preserves the plane itself as a zero set but make plane evaluations act as true distances (even if the\r\n * plane coefficients are scaled otherwise).\r\n * @param plane the DPoint4d style plane.\r\n */\r\n public setPlane4d(plane: Point4d) {\r\n const a = Math.sqrt(plane.x * plane.x + plane.y * plane.y + plane.z * plane.z);\r\n const r = a === 0.0 ? 1.0 : 1.0 / a;\r\n this._inwardNormal.x = r * plane.x;\r\n this._inwardNormal.y = r * plane.y;\r\n this._inwardNormal.z = r * plane.z;\r\n this._distanceFromOrigin = -r * plane.w;\r\n }\r\n /**\r\n * Evaluate the altitude in weighted space, i.e. (dot product with inward normal) minus distance, with point.w\r\n * scale applied to distance.\r\n * @param point space point to test.\r\n */\r\n public weightedAltitude(point: Point4d): number {\r\n return point.x * this._inwardNormal.x\r\n + point.y * this._inwardNormal.y\r\n + point.z * this._inwardNormal.z\r\n - point.w * this._distanceFromOrigin;\r\n }\r\n /**\r\n * Evaluate the distance from the plane to a point in space, i.e. (dot product with inward normal) minus distance.\r\n * @param point space point to test.\r\n */\r\n public altitude(point: Point3d): number {\r\n return point.x * this._inwardNormal.x\r\n + point.y * this._inwardNormal.y\r\n + point.z * this._inwardNormal.z\r\n - this._distanceFromOrigin;\r\n }\r\n /**\r\n * Evaluate the distance from the plane to a point in space with point given as x,y,z, i.e. (dot product with\r\n * inward normal) minus distance.\r\n * @param point space point to test.\r\n */\r\n public altitudeXYZ(x: number, y: number, z: number): number {\r\n return x * this._inwardNormal.x\r\n + y * this._inwardNormal.y\r\n + z * this._inwardNormal.z\r\n - this._distanceFromOrigin;\r\n }\r\n /** Return the x component of the normal used to evaluate altitude. */\r\n public normalX(): number {\r\n return this._inwardNormal.x;\r\n }\r\n /** Return the x component of the normal used to evaluate altitude. */\r\n public normalY(): number {\r\n return this._inwardNormal.y;\r\n }\r\n /** Return the z component of the normal used to evaluate altitude. */\r\n public normalZ(): number {\r\n return this._inwardNormal.z;\r\n }\r\n /** Return the dot product of the plane normal with the vector (NOT using the plane's distanceFromOrigin). */\r\n public velocity(vector: Vector3d): number {\r\n return vector.x * this._inwardNormal.x + vector.y * this._inwardNormal.y + vector.z * this._inwardNormal.z;\r\n }\r\n /**\r\n * Return the dot product of the plane normal with the x,yz, vector components (NOT using the plane's\r\n * distanceFromOrigin).\r\n */\r\n public velocityXYZ(x: number, y: number, z: number): number {\r\n return x * this._inwardNormal.x + y * this._inwardNormal.y + z * this._inwardNormal.z;\r\n }\r\n /**\r\n * Return the dot product of the plane normal with the point (treating the point xyz as a vector, and NOT\r\n * using the plane's distanceFromOrigin).\r\n */\r\n public dotProductPlaneNormalPoint(point: Point3d): number {\r\n return point.x * this._inwardNormal.x + point.y * this._inwardNormal.y + point.z * this._inwardNormal.z;\r\n }\r\n /**\r\n * Return true if spacePoint is inside or on the plane, with tolerance applied to \"on\".\r\n * @param spacePoint point to test.\r\n * @param tolerance tolerance for considering \"near plane\" to be \"on plane\"\r\n */\r\n public isPointOnOrInside(spacePoint: Point3d, tolerance: number = Geometry.smallMetricDistance): boolean {\r\n let value = this.altitude(spacePoint);\r\n if (tolerance) { value += tolerance; }\r\n return value >= 0.0;\r\n }\r\n /**\r\n * Return true if spacePoint is strictly inside the halfspace, with tolerance applied to \"on\".\r\n * @param spacePoint point to test.\r\n * @param tolerance tolerance for considering \"near plane\" to be \"on plane\"\r\n */\r\n public isPointInside(point: Point3d, tolerance: number = Geometry.smallMetricDistance): boolean {\r\n let value = this.altitude(point);\r\n if (tolerance) { value -= tolerance; }\r\n return value > 0.0;\r\n }\r\n /**\r\n * Return true if spacePoint is strictly on the plane, within tolerance\r\n * @param spacePoint point to test.\r\n * @param tolerance tolerance for considering \"near plane\" to be \"on plane\"\r\n */\r\n public isPointOn(point: Point3d, tolerance: number = Geometry.smallMetricDistance): boolean {\r\n return Math.abs(this.altitude(point)) <= tolerance;\r\n }\r\n /**\r\n * Compute intersections of an (UNBOUNDED) arc with the plane. Append them (as radians) to a growing array.\r\n * @param arc arc to test. The angle limits of the arc are NOT considered.\r\n * @param intersectionRadians array to receive results\r\n */\r\n public appendIntersectionRadians(arc: Arc3d, intersectionRadians: GrowableFloat64Array) {\r\n const arcVectors = arc.toVectors();\r\n const alpha = this.altitude(arc.center);\r\n const beta = this.velocity(arcVectors.vector0);\r\n const gamma = this.velocity(arcVectors.vector90);\r\n AnalyticRoots.appendImplicitLineUnitCircleIntersections(\r\n alpha, beta, gamma, undefined, undefined, intersectionRadians,\r\n );\r\n }\r\n private static _clipArcFractionArray = new GrowableFloat64Array();\r\n /**\r\n * Announce fractional intervals of arc clip.\r\n * * Each call to `announce(fraction0, fraction1, arc)` announces one interval that is inside the clip plane.\r\n */\r\n public announceClippedArcIntervals(arc: Arc3d, announce?: AnnounceNumberNumberCurvePrimitive): boolean {\r\n const breaks = ClipPlane._clipArcFractionArray;\r\n breaks.clear();\r\n this.appendIntersectionRadians(arc, breaks);\r\n arc.sweep.radiansArrayToPositivePeriodicFractions(breaks);\r\n return ClipUtilities.selectIntervals01(arc, breaks, this, announce);\r\n }\r\n /**\r\n * Compute intersection of (unbounded) segment with the plane.\r\n * * If the ends are on the same side of the plane, return undefined.\r\n * * If the intersection is an endpoint or interior to the segment return the fraction.\r\n * * If both ends are on, return undefined.\r\n */\r\n public getBoundedSegmentSimpleIntersection(pointA: Point3d, pointB: Point3d): number | undefined {\r\n const h0 = this.altitude(pointA);\r\n const h1 = this.altitude(pointB);\r\n if (h0 * h1 > 0.0)\r\n return undefined;\r\n if (h0 === 0.0 && h1 === 0.0) {\r\n return undefined;\r\n }\r\n return - h0 / (h1 - h0);\r\n }\r\n /** Apply transform to the origin. Apply inverse transpose of the matrix part to th normal vector. */\r\n public transformInPlace(transform: Transform): boolean {\r\n const plane: Plane3dByOriginAndUnitNormal = this.getPlane3d();\r\n const matrix: Matrix3d = transform.matrix;\r\n const newPoint = transform.multiplyPoint3d(plane.getOriginRef());\r\n // Normal transforms as the inverse transpose of the matrix part\r\n // BTW: If the matrix is orthogonal, this is a long way to multiply by the matrix part (mumble grumble)\r\n const newNormal = matrix.multiplyInverseTranspose(plane.getNormalRef());\r\n if (!newNormal)\r\n return false;\r\n\r\n plane.set(newPoint, newNormal);\r\n const normalized = (plane.getNormalRef()).normalize();\r\n if (!normalized)\r\n return false;\r\n this._inwardNormal = normalized;\r\n this._distanceFromOrigin = this._inwardNormal.dotProduct(plane.getOriginRef());\r\n return true;\r\n }\r\n /** Set the invisible flag. Interpretation of this flag is algorithm-specific. */\r\n public setInvisible(invisible: boolean) {\r\n this._invisible = invisible;\r\n }\r\n /** Reverse the sign of all coefficients, so outside and inside reverse */\r\n public negateInPlace() {\r\n this._inwardNormal = this._inwardNormal.negate();\r\n this._distanceFromOrigin = - this._distanceFromOrigin;\r\n }\r\n /**\r\n * Move the plane INWARD by given distance\r\n * @param offset distance of shift inwards\r\n */\r\n public offsetDistance(offset: number) {\r\n this._distanceFromOrigin += offset;\r\n }\r\n /**\r\n * Clip a polygon to the inside or outside of the plane.\r\n * * Results with 2 or fewer points are ignored.\r\n * * Other than ensuring capacity in the arrays, there are no object allocations during execution of this function.\r\n * * For a convex input polygon, the output polygon is also convex.\r\n * * For non-convex input, the output polygon may have double-back edges along plane intersections. This is still a\r\n * valid clip in a parity sense (overlapping regions cancel).\r\n * @param xyz input points.\r\n * @param work optional work buffer\r\n * @param inside whether the positive side of the plane survives (true, default), or negative side (false).\r\n * @param tolerance distance tolerance for \"on plane\" decision. Default value is [[Geometry.smallMetricDistance]].\r\n * @return the number of crossings. If this is larger than 2, the input polygon was non-convex.\r\n * @see appendPolygonClip\r\n */\r\n public clipConvexPolygonInPlace(\r\n xyz: GrowableXYZArray,\r\n work?: GrowableXYZArray,\r\n inside: boolean = true,\r\n tolerance: number = Geometry.smallMetricDistance,\r\n ): number {\r\n return IndexedXYZCollectionPolygonOps.clipConvexPolygonInPlace(this, xyz, work, inside, tolerance);\r\n }\r\n /**\r\n * Multiply the ClipPlane's DPoint4d by matrix.\r\n * @param matrix matrix to apply.\r\n * @param invert if true, use in verse of the matrix.\r\n * @param transpose if true, use the transpose of the matrix (or inverse, per invert parameter)\r\n * @param matrix matrix to apply\r\n * @return false if unable to invert\r\n * * Note that if matrixA is applied to all of space, the matrix to send to this method to get a corresponding\r\n * effect on the plane is the inverse transpose of matrixA\r\n * * Callers that will apply the same matrix to many planes should pre-invert the matrix for efficiency.\r\n * * Both params default to true to get the full effect of transforming space.\r\n */\r\n public multiplyPlaneByMatrix4d(matrix: Matrix4d, invert: boolean = true, transpose: boolean = true): boolean {\r\n const plane: Point4d = this.getPlane4d();\r\n if (invert) {\r\n const inverse = matrix.createInverse();\r\n if (inverse)\r\n return this.multiplyPlaneByMatrix4d(inverse, false, transpose);\r\n return false;\r\n }\r\n if (transpose)\r\n matrix.multiplyTransposePoint4d(plane, plane);\r\n else\r\n matrix.multiplyPoint4d(plane, plane);\r\n this.setPlane4d(plane);\r\n return true;\r\n }\r\n /** Announce the interval (if any) where a line is within the clip plane half space. */\r\n public announceClippedSegmentIntervals(\r\n f0: number, f1: number, pointA: Point3d, pointB: Point3d, announce?: (fraction0: number, fraction1: number) => void,\r\n ): boolean {\r\n if (f1 < f0)\r\n return false;\r\n const h0 = - this.altitude(pointA);\r\n const h1 = - this.altitude(pointB);\r\n const delta = h1 - h0;\r\n const f = Geometry.conditionalDivideFraction(-h0, delta);\r\n if (f === undefined) { // The segment is parallel to the plane.\r\n if (h0 <= 0.0) { if (announce) announce(f0, f1); return true; }\r\n return false;\r\n }\r\n if (delta > 0) { // segment aims OUT\r\n if (f < f1) f1 = f;\r\n } else {\r\n // segment aims IN\r\n if (f > f0)\r\n f0 = f;\r\n }\r\n if (f1 < f0)\r\n return false;\r\n if (announce) announce(f0, f1);\r\n return true;\r\n }\r\n /**\r\n * Return a coordinate frame with\r\n * * origin at closest point to global origin\r\n * * z axis points in\r\n * * x and y are \"in plane\"\r\n */\r\n public getFrame(): Transform {\r\n const d = this._distanceFromOrigin;\r\n const origin = Point3d.create(this._inwardNormal.x * d, this._inwardNormal.y * d, this._inwardNormal.z * d);\r\n const matrix = Matrix3d.createRigidHeadsUp(this._inwardNormal, AxisOrder.ZXY);\r\n return Transform.createOriginAndMatrix(origin, matrix);\r\n }\r\n /**\r\n * Return the intersection of the plane with a range cube.\r\n * @param range\r\n * @param xyzOut intersection polygon. This is convex.\r\n */\r\n public intersectRange(range: Range3d, addClosurePoint: boolean = false): GrowableXYZArray | undefined {\r\n if (range.isNull)\r\n return undefined;\r\n const corners = range.corners();\r\n const frameOnPlane = this.getFrame();\r\n frameOnPlane.multiplyInversePoint3dArrayInPlace(corners);\r\n const localRange = Range3d.createArray(corners);\r\n if (localRange.low.z * localRange.high.z > 0.0)\r\n return undefined;\r\n // oversized polygon on local z= 0\r\n const xyzOut = new GrowableXYZArray();\r\n xyzOut.pushXYZ(localRange.low.x, localRange.low.y, 0);\r\n xyzOut.pushXYZ(localRange.high.x, localRange.low.y, 0);\r\n xyzOut.pushXYZ(localRange.high.x, localRange.high.y, 0);\r\n xyzOut.pushXYZ(localRange.low.x, localRange.high.y, 0);\r\n xyzOut.multiplyTransformInPlace(frameOnPlane);\r\n IndexedXYZCollectionPolygonOps.intersectRangeConvexPolygonInPlace(range, xyzOut);\r\n if (xyzOut.length === 0)\r\n return undefined;\r\n if (addClosurePoint)\r\n xyzOut.pushWrap(1);\r\n return xyzOut;\r\n }\r\n /**\r\n * Implement appendPolygonClip, as defined in interface PolygonClipper.\r\n * @param xyz convex polygon. This is not changed.\r\n * @param insideFragments Array to receive \"inside\" fragments. Each fragment is a GrowableXYZArray grabbed\r\n * from the cache. This is NOT cleared.\r\n * @param outsideFragments Array to receive \"outside\" fragments. Each fragment is a GrowableXYZArray grabbed\r\n * from the cache. This is NOT cleared.\r\n * @param arrayCache cache for reusable GrowableXYZArray.\r\n * @see clipConvexPolygonInPlace\r\n */\r\n public appendPolygonClip(\r\n xyz: IndexedXYZCollection,\r\n insideFragments: GrowableXYZArray[],\r\n outsideFragments: GrowableXYZArray[],\r\n arrayCache: GrowableXYZArrayCache,\r\n ): void {\r\n const perpendicularRange = Range1d.createNull();\r\n const newInside = arrayCache.grabFromCache();\r\n const newOutside = arrayCache.grabFromCache();\r\n IndexedXYZCollectionPolygonOps.splitConvexPolygonInsideOutsidePlane(\r\n this, xyz, newInside, newOutside, perpendicularRange,\r\n );\r\n ClipUtilities.captureOrDrop(newInside, 3, insideFragments, arrayCache);\r\n ClipUtilities.captureOrDrop(newOutside, 3, outsideFragments, arrayCache);\r\n }\r\n /** Project a point in space to the plane. */\r\n public projectPointToPlane(spacePoint: Point3d, result?: Point3d): Point3d {\r\n return this.projectXYZToPlane(spacePoint.x, spacePoint.y, spacePoint.z, result);\r\n }\r\n /** Return the projection of (x,y,z) onto the plane. */\r\n public override projectXYZToPlane(x: number, y: number, z: number, result?: Point3d): Point3d {\r\n const scale = -this.altitudeXYZ(x, y, z);\r\n return Point3d.create(x + scale * this._inwardNormal.x, y + scale * this._inwardNormal.y, z + scale * this._inwardNormal.z, result);\r\n }\r\n}\r\n"]}
1
+ {"version":3,"file":"ClipPlane.js","sourceRoot":"","sources":["../../../src/clipping/Clip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U,CAAC,aAAa,EAAE,CAAC;QAC7C,MAAM,UAAU,GAAG,UAAU,CAAC,aAAa,EAAE,CAAC;QAC9C,8BAA8B,CAAC,oCAAoC,CACjE,IAAI,EAAE,GAAG,EAAE,SAAS,EAAE,UAAU,EAAE,kBAAkB,CACrD,CAAC;QACF,aAAa,CAAC,aAAa,CAAC,SAAS,EAAE,CAAC,EAAE,eAAe,EAAE,UAAU,CAAC,CAAC;QACvE,aAAa,CAAC,aAAa,CAAC,UAAU,EAAE,CAAC,EAAE,gBAAgB,EAAE,UAAU,CAAC,CAAC;IAC3E,CAAC;IACD,6CAA6C;IACtC,mBAAmB,CAAC,UAAmB,EAAE,MAAgB;QAC9D,OAAO,IAAI,CAAC,iBAAiB,CAAC,UAAU,CAAC,CAAC,EAAE,UAAU,CAAC,CAAC,EAAE,UAAU,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC;IAClF,CAAC;IACD,uDAAuD;IACvC,iBAAiB,CAAC,CAAS,EAAE,CAAS,EAAE,CAAS,EAAE,MAAgB;QACjF,MAAM,KAAK,GAAG,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;QACzC,OAAO,OAAO,CAAC,MAAM,CAAC,CAAC,GAAG,KAAK,GAAG,IAAI,CAAC,aAAa,CAAC,CAAC,EAAE,CAAC,GAAG,KAAK,GAAG,IAAI,CAAC,aAAa,CAAC,CAAC,EAAE,CAAC,GAAG,KAAK,GAAG,IAAI,CAAC,aAAa,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC;IACtI,CAAC","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\r\n/** @packageDocumentation\r\n * @module CartesianGeometry\r\n */\r\n\r\nimport { assert } from \"@itwin/core-bentley\";\r\nimport { Arc3d } from \"../curve/Arc3d\";\r\nimport { AnnounceNumberNumberCurvePrimitive } from \"../curve/CurvePrimitive\";\r\nimport { AxisOrder, Geometry } from \"../Geometry\";\r\nimport { Angle } from \"../geometry3d/Angle\";\r\nimport { GrowableFloat64Array } from \"../geometry3d/GrowableFloat64Array\";\r\nimport { GrowableXYZArray } from \"../geometry3d/GrowableXYZArray\";\r\nimport { IndexedXYZCollection } from \"../geometry3d/IndexedXYZCollection\";\r\nimport { Matrix3d } from \"../geometry3d/Matrix3d\";\r\nimport { Plane3d } from \"../geometry3d/Plane3d\";\r\nimport { Plane3dByOriginAndUnitNormal } from \"../geometry3d/Plane3dByOriginAndUnitNormal\";\r\nimport { Point3d, Vector3d } from \"../geometry3d/Point3dVector3d\";\r\nimport { IndexedXYZCollectionPolygonOps } from \"../geometry3d/PolygonOps\";\r\nimport { Range1d, Range3d } from \"../geometry3d/Range\";\r\nimport { GrowableXYZArrayCache } from \"../geometry3d/ReusableObjectCache\";\r\nimport { Transform } from \"../geometry3d/Transform\";\r\nimport { XYAndZ, XYZProps } from \"../geometry3d/XYZProps\";\r\nimport { Matrix4d } from \"../geometry4d/Matrix4d\";\r\nimport { Point4d } from \"../geometry4d/Point4d\";\r\nimport { AnalyticRoots } from \"../numerics/Polynomials\";\r\nimport { Clipper, ClipUtilities, PolygonClipper } from \"./ClipUtils\";\r\n\r\n/**\r\n * Wire format describing a [[ClipPlane]].\r\n * If either [[normal]] or [[dist]] are omitted, defaults to a normal of [[Vector3d.unitZ]] and a distance of zero.\r\n * @public\r\n */\r\nexport interface ClipPlaneProps {\r\n /** The plane's inward normal. */\r\n normal?: XYZProps;\r\n /** The plane's signed distance from the origin. */\r\n dist?: number;\r\n /** Defaults to `false`. Interpretation of this flag is algorithm-specific. */\r\n invisible?: boolean;\r\n /** Defaults to `false`. Interpretation of this flag is algorithm-specific. */\r\n interior?: boolean;\r\n}\r\n\r\n/**\r\n * A ClipPlane is a single plane represented as\r\n * * An inward unit normal (u,v,w)\r\n * * A signedDistance\r\n * More details can be found at docs/learning/geometry/Clipping.md\r\n *\r\n * Hence\r\n * * The halfspace function evaluation for \"point\" (x,y,z) is `(x,y,z) DOT (u,v,w) - signedDistance`.\r\n * * POSITIVE values of the halfspace function are \"inside\".\r\n * * ZERO value of the halfspace function is \"on\".\r\n * * NEGATIVE value of the halfspace function is \"outside\".\r\n * * A representative point on the plane is (signedDistance * u, signedDistance * v, signedDistance * w).\r\n * * Given a point on the plane and the inward normal of the plane, `signedDistance = point DOT normal`.\r\n * @public\r\n */\r\nexport class ClipPlane extends Plane3d implements Clipper, PolygonClipper {\r\n private _inwardNormal: Vector3d;\r\n /**\r\n * Construct a parallel plane through the origin.\r\n * * Move it to the actual position.\r\n * * _distanceFromOrigin is the distance it moved, with the (inward) normal direction as positive\r\n */\r\n private _distanceFromOrigin: number;\r\n private _invisible: boolean;\r\n private _interior: boolean;\r\n\r\n private constructor(normal: Vector3d, distance: number, invisible: boolean, interior: boolean) {\r\n super();\r\n this._invisible = invisible;\r\n this._interior = interior;\r\n this._inwardNormal = normal;\r\n this._distanceFromOrigin = distance;\r\n }\r\n /*\r\n private safeSetXYZDistance(nx: number, ny: number, nz: number, d: number) {\r\n this._inwardNormal.set(nx, ny, nz);\r\n this._distanceFromOrigin = d;\r\n }\r\n */\r\n /**\r\n * Return true if all members are almostEqual to corresponding members of other.\r\n * @param other clip plane to compare\r\n */\r\n public isAlmostEqual(other: ClipPlane): boolean {\r\n return Geometry.isSameCoordinate(this._distanceFromOrigin, other._distanceFromOrigin)\r\n && this._inwardNormal.isAlmostEqual(other._inwardNormal)\r\n && this._interior === other._interior\r\n && this._invisible === other._invisible;\r\n }\r\n /** Return a cloned plane */\r\n public clone(): ClipPlane {\r\n const result = new ClipPlane(this._inwardNormal.clone(), this._distanceFromOrigin, this._invisible, this._interior);\r\n return result;\r\n }\r\n /** Return a cloned plane with coordinate data negated. */\r\n public cloneNegated(): ClipPlane {\r\n const plane = new ClipPlane(this._inwardNormal.clone(), this._distanceFromOrigin, this._invisible, this._interior);\r\n plane.negateInPlace();\r\n return plane;\r\n }\r\n /** Create a ClipPlane from Plane3dByOriginAndUnitNormal. */\r\n public static createPlane(\r\n plane: Plane3dByOriginAndUnitNormal, invisible: boolean = false, interior: boolean = false, result?: ClipPlane,\r\n ): ClipPlane {\r\n const distance = plane.getNormalRef().dotProduct(plane.getOriginRef());\r\n if (result) {\r\n result._invisible = invisible;\r\n result._interior = interior;\r\n result._inwardNormal = plane.getNormalRef().clone();\r\n result._distanceFromOrigin = distance;\r\n return result;\r\n }\r\n return new ClipPlane(plane.getNormalRef().clone(), distance, invisible, interior);\r\n }\r\n /**\r\n * Create a ClipPlane with direct normal and signedDistance.\r\n * * The vector is normalized for storage.\r\n */\r\n public static createNormalAndDistance(\r\n normal: Vector3d, distance: number, invisible: boolean = false, interior: boolean = false, result?: ClipPlane,\r\n ): ClipPlane | undefined {\r\n const normalized = normal.normalize();\r\n if (normalized) {\r\n if (result) {\r\n result._invisible = invisible;\r\n result._interior = interior;\r\n result._inwardNormal = normalized;\r\n result._distanceFromOrigin = distance;\r\n }\r\n return new ClipPlane(normalized, distance, invisible, interior);\r\n }\r\n return undefined;\r\n }\r\n /**\r\n * Create a ClipPlane\r\n * * \"normal\" is the inward normal of the plane (it is internally normalized).\r\n * * \"point\" is any point of the plane.\r\n * * The stored distance for the plane is the dot product of the point with the normal (i.e. treat the point's xyz as\r\n * a vector from the origin.)\r\n */\r\n public static createNormalAndPoint(\r\n normal: Vector3d, point: XYAndZ, invisible: boolean = false, interior: boolean = false, result?: ClipPlane,\r\n ): ClipPlane | undefined {\r\n const normalized = normal.normalize();\r\n if (normalized) {\r\n const distance = normalized.dotProduct(point);\r\n if (result) {\r\n result._invisible = invisible;\r\n result._interior = interior;\r\n result._inwardNormal = normalized;\r\n result._distanceFromOrigin = distance;\r\n }\r\n return new ClipPlane(normalized, distance, invisible, interior);\r\n }\r\n return undefined;\r\n }\r\n /**\r\n * Create a clip plane\r\n * @param origin any point on the plane.\r\n * @param vectorA any vector in the plane\r\n * @param vectorB any vector in the plane\r\n * @return undefined if the vectors are not independent.\r\n * * The stored inward normal is vectorB.crossProduct(vectorA).\r\n * * That is, the vectors are considered as a right-handed pair when viewed from the outside.\r\n */\r\n public static createOriginAndVectors(\r\n origin: Point3d,\r\n vectorA: Vector3d,\r\n vectorB: Vector3d,\r\n invisible: boolean = false,\r\n interior: boolean = false,\r\n result?: ClipPlane,\r\n ): ClipPlane | undefined {\r\n const normalized = vectorB.crossProduct(vectorA);\r\n return this.createNormalAndPoint(normalized, origin, invisible, interior, result);\r\n }\r\n /**\r\n * Create a ClipPlane\r\n * * \"normal\" (normalX, normalY, normalZ) is the inward normal of the plane.\r\n * * \"point\" (originX,originY,originZ) is any point of the plane.\r\n * * The stored distance for the plane is the dot product of the point with the normal (i.e. treat the point's xyz\r\n * as a vector from the origin.)\r\n */\r\n public static createNormalAndPointXYZXYZ(\r\n normalX: number, normalY: number, normalZ: number,\r\n originX: number, originY: number, originZ: number,\r\n invisible: boolean = false, interior: boolean = false,\r\n result?: ClipPlane,\r\n ): ClipPlane | undefined {\r\n const q = Geometry.hypotenuseXYZ(normalX, normalY, normalZ);\r\n const r = Geometry.conditionalDivideFraction(1, q);\r\n if (r !== undefined) {\r\n if (result) {\r\n result._inwardNormal.set(normalX * r, normalY * r, normalZ * r);\r\n result._distanceFromOrigin = result._inwardNormal.dotProductXYZ(originX, originY, originZ);\r\n result._invisible = invisible;\r\n result._interior = interior;\r\n return result;\r\n }\r\n const normal = Vector3d.create(normalX * r, normalY * r, normalZ * r);\r\n return new ClipPlane(normal, normal.dotProductXYZ(originX, originY, originZ), invisible, interior);\r\n }\r\n return undefined;\r\n }\r\n /**\r\n * Return a json object of the form\r\n * `{\"normal\":[u,v,w],\"dist\":signedDistanceValue,\"interior\":true,\"invisible\":true}`\r\n */\r\n public toJSON(): ClipPlaneProps {\r\n const props: ClipPlaneProps = {\r\n normal: this.inwardNormalRef.toJSON(),\r\n dist: this.distance,\r\n };\r\n if (this.interior)\r\n props.interior = true;\r\n if (this.invisible)\r\n props.invisible = true;\r\n return props;\r\n }\r\n /** Parse json object to ClipPlane instance */\r\n public static fromJSON(json: ClipPlaneProps, result?: ClipPlane): ClipPlane | undefined {\r\n if (json && json.normal && undefined !== json.dist && Number.isFinite(json.dist))\r\n return ClipPlane.createNormalAndDistance(\r\n Vector3d.fromJSON(json.normal), json.dist, !!json.invisible, !!json.interior,\r\n );\r\n return ClipPlane.createNormalAndDistance(Vector3d.unitZ(), 0, false, false, result);\r\n }\r\n /** Set both the invisible and interior flags. */\r\n public setFlags(invisible: boolean, interior: boolean) {\r\n this._invisible = invisible;\r\n this._interior = interior;\r\n }\r\n /** Return the stored distanceFromOrigin property. */\r\n public get distance() {\r\n return this._distanceFromOrigin;\r\n }\r\n /** * Return the stored inward normal property. */\r\n public get inwardNormalRef(): Vector3d {\r\n return this._inwardNormal;\r\n }\r\n /** Return the \"interior\" property flag. Interpretation of this flag is algorithm-specific. */\r\n public get interior() {\r\n return this._interior;\r\n }\r\n /** Return the \"invisible\" property flag. Interpretation of this flag is algorithm-specific. */\r\n public get invisible() {\r\n return this._invisible;\r\n }\r\n /**\r\n * Create a plane defined by two points, an up vector, and a tilt angle relative to the up vector.\r\n * @param point0 start point of the edge\r\n * @param point1 end point of the edge\r\n * @param upVector vector perpendicular to the plane\r\n * @param tiltAngle angle to tilt the plane around the edge in the direction of the up vector.\r\n * @param result optional preallocated plane\r\n */\r\n public static createEdgeAndUpVector(\r\n point0: Point3d, point1: Point3d, upVector: Vector3d, tiltAngle?: Angle, result?: ClipPlane,\r\n ): ClipPlane | undefined {\r\n const edgeVector = Vector3d.createFrom(point1.minus(point0));\r\n let normal = (upVector.crossProduct(edgeVector)).normalize();\r\n\r\n if (normal) {\r\n if (tiltAngle !== undefined && !tiltAngle.isAlmostZero) {\r\n const tiltNormal = Vector3d.createRotateVectorAroundVector(normal, edgeVector, tiltAngle);\r\n if (tiltNormal) {\r\n normal = tiltNormal.clone();\r\n }\r\n }\r\n normal.negate(normal);\r\n return ClipPlane.createNormalAndPoint(normal, point0, false, false, result);\r\n }\r\n return undefined;\r\n }\r\n /** Create a plane perpendicular to the edge between the xy parts of point0 and point1. */\r\n public static createEdgeXY(point0: XYAndZ, point1: XYAndZ, result?: ClipPlane): ClipPlane | undefined {\r\n const normal = Vector3d.create(point0.y - point1.y, point1.x - point0.x);\r\n if (normal.normalizeInPlace())\r\n return ClipPlane.createNormalAndPoint(normal, point0, false, false, result);\r\n return undefined;\r\n }\r\n /**\r\n * Variant of [[createEdgeXY]] that computes the plane using the edge midpoint instead of its start point.\r\n * * This is more stable for creating a pair of clip planes from a long edge and its reversal, as is commonly found\r\n * in a [[UnionOfConvexClipPlaneSets]].\r\n */\r\n public static createMidPointEdgeXY(point0: XYAndZ, point1: XYAndZ, result?: ClipPlane): ClipPlane | undefined {\r\n return ClipPlane.createNormalAndPointXYZXYZ(\r\n point0.y - point1.y, point1.x - point0.x, 0,\r\n 0.5 * (point0.x + point1.x), 0.5 * (point0.y + point1.y), 0,\r\n false, false, result,\r\n );\r\n }\r\n /**\r\n * Return the Plane3d form of the plane.\r\n * * The plane origin is the point `distance * inwardNormal`\r\n * * The plane normal is the inward normal of the ClipPlane.\r\n */\r\n public getPlane3d(): Plane3dByOriginAndUnitNormal {\r\n const d = this._distanceFromOrigin;\r\n const origin = Point3d.create(this._inwardNormal.x * d, this._inwardNormal.y * d, this._inwardNormal.z * d);\r\n const plane = Plane3dByOriginAndUnitNormal.createXYPlane();\r\n const result = Plane3dByOriginAndUnitNormal.create(origin, this._inwardNormal, plane);\r\n assert(result !== undefined, \"this._inwardNormal should be normalized by constructors. Fix caller if this fails.\");\r\n return plane;\r\n }\r\n /**\r\n * Return the Point4d d form of the plane.\r\n * * The homogeneous xyz are the inward normal xyz.\r\n * * The homogeneous weight is the negated ClipPlane distance.\r\n */\r\n public getPlane4d(): Point4d {\r\n return Point4d.create(\r\n this._inwardNormal.x, this._inwardNormal.y, this._inwardNormal.z, - this._distanceFromOrigin,\r\n );\r\n }\r\n /**\r\n * Set the plane from DPoint4d style plane.\r\n * * The saved plane has its direction normalized.\r\n * * This preserves the plane itself as a zero set but make plane evaluations act as true distances (even if the\r\n * plane coefficients are scaled otherwise).\r\n * @param plane the DPoint4d style plane.\r\n */\r\n public setPlane4d(plane: Point4d) {\r\n const a = Math.sqrt(plane.x * plane.x + plane.y * plane.y + plane.z * plane.z);\r\n const r = a === 0.0 ? 1.0 : 1.0 / a;\r\n this._inwardNormal.x = r * plane.x;\r\n this._inwardNormal.y = r * plane.y;\r\n this._inwardNormal.z = r * plane.z;\r\n this._distanceFromOrigin = -r * plane.w;\r\n }\r\n /**\r\n * Evaluate the altitude in weighted space, i.e. (dot product with inward normal) minus distance, with point.w\r\n * scale applied to distance.\r\n * @param point space point to test.\r\n */\r\n public weightedAltitude(point: Point4d): number {\r\n return point.x * this._inwardNormal.x\r\n + point.y * this._inwardNormal.y\r\n + point.z * this._inwardNormal.z\r\n - point.w * this._distanceFromOrigin;\r\n }\r\n /**\r\n * Evaluate the distance from the plane to a point in space, i.e. (dot product with inward normal) minus distance.\r\n * @param point space point to test.\r\n */\r\n public altitude(point: Point3d): number {\r\n return point.x * this._inwardNormal.x\r\n + point.y * this._inwardNormal.y\r\n + point.z * this._inwardNormal.z\r\n - this._distanceFromOrigin;\r\n }\r\n /**\r\n * Evaluate the distance from the plane to a point in space with point given as x,y,z, i.e. (dot product with\r\n * inward normal) minus distance.\r\n * @param point space point to test.\r\n */\r\n public altitudeXYZ(x: number, y: number, z: number): number {\r\n return x * this._inwardNormal.x\r\n + y * this._inwardNormal.y\r\n + z * this._inwardNormal.z\r\n - this._distanceFromOrigin;\r\n }\r\n /** Return the x component of the normal used to evaluate altitude. */\r\n public normalX(): number {\r\n return this._inwardNormal.x;\r\n }\r\n /** Return the x component of the normal used to evaluate altitude. */\r\n public normalY(): number {\r\n return this._inwardNormal.y;\r\n }\r\n /** Return the z component of the normal used to evaluate altitude. */\r\n public normalZ(): number {\r\n return this._inwardNormal.z;\r\n }\r\n /** Return the dot product of the plane normal with the vector (NOT using the plane's distanceFromOrigin). */\r\n public velocity(vector: Vector3d): number {\r\n return vector.x * this._inwardNormal.x + vector.y * this._inwardNormal.y + vector.z * this._inwardNormal.z;\r\n }\r\n /**\r\n * Return the dot product of the plane normal with the x,yz, vector components (NOT using the plane's\r\n * distanceFromOrigin).\r\n */\r\n public velocityXYZ(x: number, y: number, z: number): number {\r\n return x * this._inwardNormal.x + y * this._inwardNormal.y + z * this._inwardNormal.z;\r\n }\r\n /**\r\n * Return the dot product of the plane normal with the point (treating the point xyz as a vector, and NOT\r\n * using the plane's distanceFromOrigin).\r\n */\r\n public dotProductPlaneNormalPoint(point: Point3d): number {\r\n return point.x * this._inwardNormal.x + point.y * this._inwardNormal.y + point.z * this._inwardNormal.z;\r\n }\r\n /**\r\n * Return true if spacePoint is inside or on the plane, with tolerance applied to \"on\".\r\n * @param spacePoint point to test.\r\n * @param tolerance tolerance for considering \"near plane\" to be \"on plane\"\r\n */\r\n public isPointOnOrInside(spacePoint: Point3d, tolerance: number = Geometry.smallMetricDistance): boolean {\r\n let value = this.altitude(spacePoint);\r\n if (tolerance) { value += tolerance; }\r\n return value >= 0.0;\r\n }\r\n /**\r\n * Return true if spacePoint is strictly inside the halfspace, with tolerance applied to \"on\".\r\n * @param spacePoint point to test.\r\n * @param tolerance tolerance for considering \"near plane\" to be \"on plane\"\r\n */\r\n public isPointInside(point: Point3d, tolerance: number = Geometry.smallMetricDistance): boolean {\r\n let value = this.altitude(point);\r\n if (tolerance) { value -= tolerance; }\r\n return value > 0.0;\r\n }\r\n /**\r\n * Return true if spacePoint is strictly on the plane, within tolerance\r\n * @param spacePoint point to test.\r\n * @param tolerance tolerance for considering \"near plane\" to be \"on plane\"\r\n */\r\n public isPointOn(point: Point3d, tolerance: number = Geometry.smallMetricDistance): boolean {\r\n return Math.abs(this.altitude(point)) <= tolerance;\r\n }\r\n /**\r\n * Compute intersections of an (UNBOUNDED) arc with the plane. Append them (as radians) to a growing array.\r\n * @param arc arc to test. The angle limits of the arc are NOT considered.\r\n * @param intersectionRadians array to receive results\r\n */\r\n public appendIntersectionRadians(arc: Arc3d, intersectionRadians: GrowableFloat64Array) {\r\n const arcVectors = arc.toVectors();\r\n const alpha = this.altitude(arc.center);\r\n const beta = this.velocity(arcVectors.vector0);\r\n const gamma = this.velocity(arcVectors.vector90);\r\n AnalyticRoots.appendImplicitLineUnitCircleIntersections(\r\n alpha, beta, gamma, undefined, undefined, intersectionRadians,\r\n );\r\n }\r\n private static _clipArcFractionArray = new GrowableFloat64Array();\r\n /**\r\n * Announce fractional intervals of arc clip.\r\n * * Each call to `announce(fraction0, fraction1, arc)` announces one interval that is inside the clip plane.\r\n */\r\n public announceClippedArcIntervals(arc: Arc3d, announce?: AnnounceNumberNumberCurvePrimitive): boolean {\r\n const breaks = ClipPlane._clipArcFractionArray;\r\n breaks.clear();\r\n this.appendIntersectionRadians(arc, breaks);\r\n arc.sweep.radiansArrayToPositivePeriodicFractions(breaks);\r\n return ClipUtilities.selectIntervals01(arc, breaks, this, announce);\r\n }\r\n /**\r\n * Compute intersection of (unbounded) segment with the plane.\r\n * * If the ends are on the same side of the plane, return undefined.\r\n * * If the intersection is an endpoint or interior to the segment return the fraction.\r\n * * If both ends are on, return undefined.\r\n */\r\n public getBoundedSegmentSimpleIntersection(pointA: Point3d, pointB: Point3d): number | undefined {\r\n const h0 = this.altitude(pointA);\r\n const h1 = this.altitude(pointB);\r\n if (h0 * h1 > 0.0)\r\n return undefined;\r\n if (h0 === 0.0 && h1 === 0.0) {\r\n return undefined;\r\n }\r\n return - h0 / (h1 - h0);\r\n }\r\n /** Apply transform to the origin. Apply inverse transpose of the matrix part to th normal vector. */\r\n public transformInPlace(transform: Transform): boolean {\r\n const plane: Plane3dByOriginAndUnitNormal = this.getPlane3d();\r\n const matrix: Matrix3d = transform.matrix;\r\n const newPoint = transform.multiplyPoint3d(plane.getOriginRef());\r\n // Normal transforms as the inverse transpose of the matrix part\r\n // BTW: If the matrix is orthogonal, this is a long way to multiply by the matrix part (mumble grumble)\r\n const newNormal = matrix.multiplyInverseTranspose(plane.getNormalRef());\r\n if (!newNormal)\r\n return false;\r\n\r\n plane.set(newPoint, newNormal);\r\n const normalized = (plane.getNormalRef()).normalize();\r\n if (!normalized)\r\n return false;\r\n this._inwardNormal = normalized;\r\n this._distanceFromOrigin = this._inwardNormal.dotProduct(plane.getOriginRef());\r\n return true;\r\n }\r\n /** Set the invisible flag. Interpretation of this flag is algorithm-specific. */\r\n public setInvisible(invisible: boolean) {\r\n this._invisible = invisible;\r\n }\r\n /** Reverse the sign of all coefficients, so outside and inside reverse */\r\n public negateInPlace() {\r\n this._inwardNormal = this._inwardNormal.negate();\r\n this._distanceFromOrigin = - this._distanceFromOrigin;\r\n }\r\n /**\r\n * Move the plane INWARD by given distance\r\n * @param offset distance of shift inwards\r\n */\r\n public offsetDistance(offset: number) {\r\n this._distanceFromOrigin += offset;\r\n }\r\n /**\r\n * Clip a polygon to the inside or outside of the plane.\r\n * * Results with 2 or fewer points are ignored.\r\n * * Other than ensuring capacity in the arrays, there are no object allocations during execution of this function.\r\n * * For a convex input polygon, the output polygon is also convex.\r\n * * For non-convex input, the output polygon may have double-back edges along plane intersections. This is still a\r\n * valid clip in a parity sense (overlapping regions cancel).\r\n * @param xyz input points.\r\n * @param work optional work buffer\r\n * @param inside whether the positive side of the plane survives (true, default), or negative side (false).\r\n * @param tolerance distance tolerance for \"on plane\" decision. Default value is [[Geometry.smallMetricDistance]].\r\n * @return the number of crossings. If this is larger than 2, the input polygon was non-convex.\r\n * @see appendPolygonClip\r\n */\r\n public clipConvexPolygonInPlace(\r\n xyz: GrowableXYZArray,\r\n work?: GrowableXYZArray,\r\n inside: boolean = true,\r\n tolerance: number = Geometry.smallMetricDistance,\r\n ): number {\r\n return IndexedXYZCollectionPolygonOps.clipConvexPolygonInPlace(this, xyz, work, inside, tolerance);\r\n }\r\n /**\r\n * Multiply the ClipPlane's DPoint4d by matrix.\r\n * @param matrix matrix to apply.\r\n * @param invert if true, use in verse of the matrix.\r\n * @param transpose if true, use the transpose of the matrix (or inverse, per invert parameter)\r\n * @param matrix matrix to apply\r\n * @return false if unable to invert\r\n * * Note that if matrixA is applied to all of space, the matrix to send to this method to get a corresponding\r\n * effect on the plane is the inverse transpose of matrixA\r\n * * Callers that will apply the same matrix to many planes should pre-invert the matrix for efficiency.\r\n * * Both params default to true to get the full effect of transforming space.\r\n */\r\n public multiplyPlaneByMatrix4d(matrix: Matrix4d, invert: boolean = true, transpose: boolean = true): boolean {\r\n const plane: Point4d = this.getPlane4d();\r\n if (invert) {\r\n const inverse = matrix.createInverse();\r\n if (inverse)\r\n return this.multiplyPlaneByMatrix4d(inverse, false, transpose);\r\n return false;\r\n }\r\n if (transpose)\r\n matrix.multiplyTransposePoint4d(plane, plane);\r\n else\r\n matrix.multiplyPoint4d(plane, plane);\r\n this.setPlane4d(plane);\r\n return true;\r\n }\r\n /** Announce the interval (if any) where a line is within the clip plane half space. */\r\n public announceClippedSegmentIntervals(\r\n f0: number, f1: number, pointA: Point3d, pointB: Point3d, announce?: (fraction0: number, fraction1: number) => void,\r\n ): boolean {\r\n if (f1 < f0)\r\n return false;\r\n const h0 = - this.altitude(pointA);\r\n const h1 = - this.altitude(pointB);\r\n const delta = h1 - h0;\r\n const f = Geometry.conditionalDivideFraction(-h0, delta);\r\n if (f === undefined) { // The segment is parallel to the plane.\r\n if (h0 <= 0.0) { if (announce) announce(f0, f1); return true; }\r\n return false;\r\n }\r\n if (delta > 0) { // segment aims OUT\r\n if (f < f1) f1 = f;\r\n } else {\r\n // segment aims IN\r\n if (f > f0)\r\n f0 = f;\r\n }\r\n if (f1 < f0)\r\n return false;\r\n if (announce) announce(f0, f1);\r\n return true;\r\n }\r\n /**\r\n * Return a coordinate frame with\r\n * * origin at closest point to global origin\r\n * * z axis points in\r\n * * x and y are \"in plane\"\r\n */\r\n public getFrame(): Transform {\r\n const d = this._distanceFromOrigin;\r\n const origin = Point3d.create(this._inwardNormal.x * d, this._inwardNormal.y * d, this._inwardNormal.z * d);\r\n const matrix = Matrix3d.createRigidHeadsUp(this._inwardNormal, AxisOrder.ZXY);\r\n return Transform.createOriginAndMatrix(origin, matrix);\r\n }\r\n /**\r\n * Return the intersection of the plane with a range cube.\r\n * @param range\r\n * @param xyzOut intersection polygon. This is convex.\r\n */\r\n public intersectRange(range: Range3d, addClosurePoint: boolean = false): GrowableXYZArray | undefined {\r\n if (range.isNull)\r\n return undefined;\r\n const corners = range.corners();\r\n const frameOnPlane = this.getFrame();\r\n frameOnPlane.multiplyInversePoint3dArrayInPlace(corners);\r\n const localRange = Range3d.createArray(corners);\r\n if (localRange.low.z * localRange.high.z > 0.0)\r\n return undefined;\r\n // oversized polygon on local z= 0\r\n const xyzOut = new GrowableXYZArray();\r\n xyzOut.pushXYZ(localRange.low.x, localRange.low.y, 0);\r\n xyzOut.pushXYZ(localRange.high.x, localRange.low.y, 0);\r\n xyzOut.pushXYZ(localRange.high.x, localRange.high.y, 0);\r\n xyzOut.pushXYZ(localRange.low.x, localRange.high.y, 0);\r\n xyzOut.multiplyTransformInPlace(frameOnPlane);\r\n IndexedXYZCollectionPolygonOps.intersectRangeConvexPolygonInPlace(range, xyzOut);\r\n if (xyzOut.length === 0)\r\n return undefined;\r\n if (addClosurePoint)\r\n xyzOut.pushWrap(1);\r\n return xyzOut;\r\n }\r\n /**\r\n * Implement appendPolygonClip, as defined in interface PolygonClipper.\r\n * @param xyz convex polygon. This is not changed.\r\n * @param insideFragments Array to receive \"inside\" fragments. Each fragment is a GrowableXYZArray grabbed\r\n * from the cache. This is NOT cleared.\r\n * @param outsideFragments Array to receive \"outside\" fragments. Each fragment is a GrowableXYZArray grabbed\r\n * from the cache. This is NOT cleared.\r\n * @param arrayCache cache for reusable GrowableXYZArray.\r\n * @see clipConvexPolygonInPlace\r\n */\r\n public appendPolygonClip(\r\n xyz: IndexedXYZCollection,\r\n insideFragments: GrowableXYZArray[],\r\n outsideFragments: GrowableXYZArray[],\r\n arrayCache: GrowableXYZArrayCache,\r\n ): void {\r\n const perpendicularRange = Range1d.createNull();\r\n const newInside = arrayCache.grabFromCache();\r\n const newOutside = arrayCache.grabFromCache();\r\n IndexedXYZCollectionPolygonOps.splitConvexPolygonInsideOutsidePlane(\r\n this, xyz, newInside, newOutside, perpendicularRange,\r\n );\r\n ClipUtilities.captureOrDrop(newInside, 3, insideFragments, arrayCache);\r\n ClipUtilities.captureOrDrop(newOutside, 3, outsideFragments, arrayCache);\r\n }\r\n /** Project a point in space to the plane. */\r\n public projectPointToPlane(spacePoint: Point3d, result?: Point3d): Point3d {\r\n return this.projectXYZToPlane(spacePoint.x, spacePoint.y, spacePoint.z, result);\r\n }\r\n /** Return the projection of (x,y,z) onto the plane. */\r\n public override projectXYZToPlane(x: number, y: number, z: number, result?: Point3d): Point3d {\r\n const scale = -this.altitudeXYZ(x, y, z);\r\n return Point3d.create(x + scale * this._inwardNormal.x, y + scale * this._inwardNormal.y, z + scale * this._inwardNormal.z, result);\r\n }\r\n}\r\n"]}
@@ -1,13 +1,13 @@
1
+ import { Arc3d } from "../curve/Arc3d";
2
+ import { AnnounceNumberNumber, AnnounceNumberNumberCurvePrimitive } from "../curve/CurvePrimitive";
1
3
  import { Point3d } from "../geometry3d/Point3dVector3d";
2
- import { TransformProps, XYZProps } from "../geometry3d/XYZProps";
3
4
  import { Range3d } from "../geometry3d/Range";
4
5
  import { Transform } from "../geometry3d/Transform";
6
+ import { TransformProps, XYZProps } from "../geometry3d/XYZProps";
5
7
  import { Matrix4d } from "../geometry4d/Matrix4d";
6
8
  import { Clipper, ClipPlaneContainment } from "./ClipUtils";
7
9
  import { ConvexClipPlaneSet } from "./ConvexClipPlaneSet";
8
10
  import { UnionOfConvexClipPlaneSets, UnionOfConvexClipPlaneSetsProps } from "./UnionOfConvexClipPlaneSets";
9
- import { Arc3d } from "../curve/Arc3d";
10
- import { AnnounceNumberNumber, AnnounceNumberNumberCurvePrimitive } from "../curve/CurvePrimitive";
11
11
  /**
12
12
  * Bit mask type for referencing subsets of 6 planes of range box.
13
13
  * @public
@@ -208,18 +208,60 @@ export declare class ClipShape extends ClipPrimitive {
208
208
  protected constructor(polygon?: Point3d[], zLow?: number, zHigh?: number, transform?: Transform, isMask?: boolean, invisible?: boolean);
209
209
  /** Returns true if this ClipShape is marked as invisible. */
210
210
  get invisible(): boolean;
211
- /** Return this transformFromClip, which may be undefined. */
211
+ /** Return local to world transform, which may be undefined. */
212
212
  get transformFromClip(): Transform | undefined;
213
- /** Return this transformToClip, which may be undefined. */
213
+ /** Return world to local transform, which may be undefined. */
214
214
  get transformToClip(): Transform | undefined;
215
- /** Returns true if this ClipShape's transforms are currently set. */
215
+ /**
216
+ * Returns true if this ClipShape has a local to world transform.
217
+ * @see type guards [[hasTransformFromClip]], [[hasTransformToClip]], and [[hasTransforms]].
218
+ */
216
219
  get transformValid(): boolean;
217
- /** Returns true if this ClipShape's lower z boundary is set. */
220
+ /**
221
+ * Returns true if this ClipShape's lower z boundary is set.
222
+ * @see type guard [[hasZLow]].
223
+ */
218
224
  get zLowValid(): boolean;
219
- /** Returns true if this ClipShape's upper z boundary is set. */
225
+ /**
226
+ * Returns true if this ClipShape's upper z boundary is set.
227
+ * @see type guard [[hasZHigh]].
228
+ */
220
229
  get zHighValid(): boolean;
221
- /** Return true if this ClipShape has a local to world transform */
230
+ /**
231
+ * Return true if this ClipShape has a local to world transform
232
+ * @deprecated Use duplicate property [[transformValid]] or type guard [[hasTransformFromClip]] instead.
233
+ */
222
234
  get transformIsValid(): boolean;
235
+ /** Type guard for [[zLow]]. */
236
+ hasZLow(): this is {
237
+ zLow: number;
238
+ };
239
+ /** Type guard for [[zHigh]]. */
240
+ hasZHigh(): this is {
241
+ zHigh: number;
242
+ };
243
+ /**
244
+ * Type guard for [[transformFromClip]].
245
+ * @see related type guards [[hasTransformToClip]] and [[hasTransforms]].
246
+ */
247
+ hasTransformFromClip(): this is {
248
+ transformFromClip: Transform;
249
+ };
250
+ /**
251
+ * Type guard for [[transformToClip]].
252
+ * @see related type guards [[hasTransformFromClip]] and [[hasTransforms]].
253
+ */
254
+ hasTransformToClip(): this is {
255
+ transformToClip: Transform;
256
+ };
257
+ /**
258
+ * Type guard for both [[transformFromClip]] and [[transformToClip]].
259
+ * @see individual type guards [[hasTransformFromClip]] and [[hasTransformToClip]].
260
+ */
261
+ hasTransforms(): this is {
262
+ transformFromClip: Transform;
263
+ transformToClip: Transform;
264
+ };
223
265
  /** Return this zLow, which may be undefined. */
224
266
  get zLow(): number | undefined;
225
267
  /** Return this zHigh, which may be undefined. */
@@ -268,11 +310,19 @@ export declare class ClipShape extends ClipPrimitive {
268
310
  /**
269
311
  * Given a start and end point, populate the given UnionOfConvexClipPlaneSets with ConvexClipPlaneSets
270
312
  * defining the bounded region of linear planes. Returns true if successful.
313
+ * * This handles the degenerate 2-point polygon case, e.g., select by line. See [[parseConvexPolygonPlanes]].
271
314
  */
272
315
  private parseLinearPlanes;
273
316
  /**
274
317
  * Given a convex polygon defined as an array of points, populate the given UnionOfConvexClipPlaneSets with
275
318
  * ConvexClipPlaneSets defining the bounded region. Returns true if successful.
319
+ * @param polygon convex polygon with closure point. z-coordinates are ignored.
320
+ * @param direction whether the area described by the polygon is found on its directed edges' left (nonnegative) or
321
+ * right (negative). Typically this is positive for CCW xy-polygons.
322
+ * @param buildExteriorClipper whether the returned clippers represent the xy-region *outside* the polygon.
323
+ * When this is true, `direction` is typically set accordingly. For example, for a CCW polygon, to return clippers
324
+ * for the exterior region, pass `direction < 0` and `buildExteriorClipper = true`. Currently not implemented for
325
+ * camera view.
276
326
  */
277
327
  private parseConvexPolygonPlanes;
278
328
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"ClipPrimitive.d.ts","sourceRoot":"","sources":["../../../src/clipping/ClipPrimitive.ts"],"names":[],"mappings":"AAWA,OAAO,EAAE,OAAO,EAAY,MAAM,+BAA+B,CAAC;AAElE,OAAO,EAAE,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