@itwin/core-geometry 5.10.0-dev.1 → 5.10.0-dev.11

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 (174) hide show
  1. package/CHANGELOG.md +22 -1
  2. package/lib/cjs/clipping/BooleanClipNode.d.ts +28 -29
  3. package/lib/cjs/clipping/BooleanClipNode.d.ts.map +1 -1
  4. package/lib/cjs/clipping/BooleanClipNode.js +61 -29
  5. package/lib/cjs/clipping/BooleanClipNode.js.map +1 -1
  6. package/lib/cjs/clipping/ClipPlane.d.ts +12 -13
  7. package/lib/cjs/clipping/ClipPlane.d.ts.map +1 -1
  8. package/lib/cjs/clipping/ClipPlane.js +19 -12
  9. package/lib/cjs/clipping/ClipPlane.js.map +1 -1
  10. package/lib/cjs/clipping/ClipPrimitive.d.ts +13 -8
  11. package/lib/cjs/clipping/ClipPrimitive.d.ts.map +1 -1
  12. package/lib/cjs/clipping/ClipPrimitive.js +18 -7
  13. package/lib/cjs/clipping/ClipPrimitive.js.map +1 -1
  14. package/lib/cjs/clipping/ClipUtils.d.ts +13 -5
  15. package/lib/cjs/clipping/ClipUtils.d.ts.map +1 -1
  16. package/lib/cjs/clipping/ClipUtils.js.map +1 -1
  17. package/lib/cjs/clipping/ClipVector.d.ts +11 -5
  18. package/lib/cjs/clipping/ClipVector.d.ts.map +1 -1
  19. package/lib/cjs/clipping/ClipVector.js +22 -7
  20. package/lib/cjs/clipping/ClipVector.js.map +1 -1
  21. package/lib/cjs/clipping/ConvexClipPlaneSet.d.ts +7 -20
  22. package/lib/cjs/clipping/ConvexClipPlaneSet.d.ts.map +1 -1
  23. package/lib/cjs/clipping/ConvexClipPlaneSet.js +16 -20
  24. package/lib/cjs/clipping/ConvexClipPlaneSet.js.map +1 -1
  25. package/lib/cjs/clipping/UnionOfConvexClipPlaneSets.d.ts +8 -19
  26. package/lib/cjs/clipping/UnionOfConvexClipPlaneSets.d.ts.map +1 -1
  27. package/lib/cjs/clipping/UnionOfConvexClipPlaneSets.js +19 -22
  28. package/lib/cjs/clipping/UnionOfConvexClipPlaneSets.js.map +1 -1
  29. package/lib/cjs/curve/CurvePrimitive.d.ts +4 -4
  30. package/lib/cjs/curve/CurvePrimitive.d.ts.map +1 -1
  31. package/lib/cjs/curve/CurvePrimitive.js +5 -6
  32. package/lib/cjs/curve/CurvePrimitive.js.map +1 -1
  33. package/lib/cjs/curve/LineString3d.d.ts +4 -4
  34. package/lib/cjs/curve/LineString3d.d.ts.map +1 -1
  35. package/lib/cjs/curve/LineString3d.js +4 -6
  36. package/lib/cjs/curve/LineString3d.js.map +1 -1
  37. package/lib/cjs/curve/internalContexts/AppendPlaneIntersectionStrokeHandler.d.ts +2 -3
  38. package/lib/cjs/curve/internalContexts/AppendPlaneIntersectionStrokeHandler.d.ts.map +1 -1
  39. package/lib/cjs/curve/internalContexts/AppendPlaneIntersectionStrokeHandler.js +5 -6
  40. package/lib/cjs/curve/internalContexts/AppendPlaneIntersectionStrokeHandler.js.map +1 -1
  41. package/lib/cjs/curve/spiral/TransitionSpiral3d.d.ts.map +1 -1
  42. package/lib/cjs/curve/spiral/TransitionSpiral3d.js.map +1 -1
  43. package/lib/cjs/geometry3d/Ellipsoid.d.ts +4 -3
  44. package/lib/cjs/geometry3d/Ellipsoid.d.ts.map +1 -1
  45. package/lib/cjs/geometry3d/Ellipsoid.js +7 -4
  46. package/lib/cjs/geometry3d/Ellipsoid.js.map +1 -1
  47. package/lib/cjs/geometry3d/Matrix3d.d.ts +2 -0
  48. package/lib/cjs/geometry3d/Matrix3d.d.ts.map +1 -1
  49. package/lib/cjs/geometry3d/Matrix3d.js +4 -0
  50. package/lib/cjs/geometry3d/Matrix3d.js.map +1 -1
  51. package/lib/cjs/geometry3d/Plane3d.d.ts +16 -11
  52. package/lib/cjs/geometry3d/Plane3d.d.ts.map +1 -1
  53. package/lib/cjs/geometry3d/Plane3d.js +16 -11
  54. package/lib/cjs/geometry3d/Plane3d.js.map +1 -1
  55. package/lib/cjs/serialization/IModelJsonSchema.d.ts.map +1 -1
  56. package/lib/cjs/serialization/IModelJsonSchema.js +8 -13
  57. package/lib/cjs/serialization/IModelJsonSchema.js.map +1 -1
  58. package/lib/cjs/solid/Box.d.ts +2 -0
  59. package/lib/cjs/solid/Box.d.ts.map +1 -1
  60. package/lib/cjs/solid/Box.js +4 -0
  61. package/lib/cjs/solid/Box.js.map +1 -1
  62. package/lib/cjs/solid/Cone.d.ts +12 -0
  63. package/lib/cjs/solid/Cone.d.ts.map +1 -1
  64. package/lib/cjs/solid/Cone.js +23 -0
  65. package/lib/cjs/solid/Cone.js.map +1 -1
  66. package/lib/cjs/solid/LinearSweep.d.ts +2 -0
  67. package/lib/cjs/solid/LinearSweep.d.ts.map +1 -1
  68. package/lib/cjs/solid/LinearSweep.js +4 -0
  69. package/lib/cjs/solid/LinearSweep.js.map +1 -1
  70. package/lib/cjs/solid/RotationalSweep.d.ts +2 -0
  71. package/lib/cjs/solid/RotationalSweep.d.ts.map +1 -1
  72. package/lib/cjs/solid/RotationalSweep.js +4 -0
  73. package/lib/cjs/solid/RotationalSweep.js.map +1 -1
  74. package/lib/cjs/solid/RuledSweep.d.ts +1 -1
  75. package/lib/cjs/solid/RuledSweep.js.map +1 -1
  76. package/lib/cjs/solid/SolidPrimitive.d.ts +8 -1
  77. package/lib/cjs/solid/SolidPrimitive.d.ts.map +1 -1
  78. package/lib/cjs/solid/SolidPrimitive.js +8 -0
  79. package/lib/cjs/solid/SolidPrimitive.js.map +1 -1
  80. package/lib/cjs/solid/Sphere.d.ts +2 -0
  81. package/lib/cjs/solid/Sphere.d.ts.map +1 -1
  82. package/lib/cjs/solid/Sphere.js +4 -0
  83. package/lib/cjs/solid/Sphere.js.map +1 -1
  84. package/lib/cjs/solid/TorusPipe.d.ts +2 -0
  85. package/lib/cjs/solid/TorusPipe.d.ts.map +1 -1
  86. package/lib/cjs/solid/TorusPipe.js +4 -0
  87. package/lib/cjs/solid/TorusPipe.js.map +1 -1
  88. package/lib/esm/clipping/BooleanClipNode.d.ts +28 -29
  89. package/lib/esm/clipping/BooleanClipNode.d.ts.map +1 -1
  90. package/lib/esm/clipping/BooleanClipNode.js +61 -29
  91. package/lib/esm/clipping/BooleanClipNode.js.map +1 -1
  92. package/lib/esm/clipping/ClipPlane.d.ts +12 -13
  93. package/lib/esm/clipping/ClipPlane.d.ts.map +1 -1
  94. package/lib/esm/clipping/ClipPlane.js +19 -12
  95. package/lib/esm/clipping/ClipPlane.js.map +1 -1
  96. package/lib/esm/clipping/ClipPrimitive.d.ts +13 -8
  97. package/lib/esm/clipping/ClipPrimitive.d.ts.map +1 -1
  98. package/lib/esm/clipping/ClipPrimitive.js +18 -7
  99. package/lib/esm/clipping/ClipPrimitive.js.map +1 -1
  100. package/lib/esm/clipping/ClipUtils.d.ts +13 -5
  101. package/lib/esm/clipping/ClipUtils.d.ts.map +1 -1
  102. package/lib/esm/clipping/ClipUtils.js.map +1 -1
  103. package/lib/esm/clipping/ClipVector.d.ts +11 -5
  104. package/lib/esm/clipping/ClipVector.d.ts.map +1 -1
  105. package/lib/esm/clipping/ClipVector.js +22 -7
  106. package/lib/esm/clipping/ClipVector.js.map +1 -1
  107. package/lib/esm/clipping/ConvexClipPlaneSet.d.ts +7 -20
  108. package/lib/esm/clipping/ConvexClipPlaneSet.d.ts.map +1 -1
  109. package/lib/esm/clipping/ConvexClipPlaneSet.js +16 -20
  110. package/lib/esm/clipping/ConvexClipPlaneSet.js.map +1 -1
  111. package/lib/esm/clipping/UnionOfConvexClipPlaneSets.d.ts +8 -19
  112. package/lib/esm/clipping/UnionOfConvexClipPlaneSets.d.ts.map +1 -1
  113. package/lib/esm/clipping/UnionOfConvexClipPlaneSets.js +19 -22
  114. package/lib/esm/clipping/UnionOfConvexClipPlaneSets.js.map +1 -1
  115. package/lib/esm/curve/CurvePrimitive.d.ts +4 -4
  116. package/lib/esm/curve/CurvePrimitive.d.ts.map +1 -1
  117. package/lib/esm/curve/CurvePrimitive.js +5 -6
  118. package/lib/esm/curve/CurvePrimitive.js.map +1 -1
  119. package/lib/esm/curve/LineString3d.d.ts +4 -4
  120. package/lib/esm/curve/LineString3d.d.ts.map +1 -1
  121. package/lib/esm/curve/LineString3d.js +4 -6
  122. package/lib/esm/curve/LineString3d.js.map +1 -1
  123. package/lib/esm/curve/internalContexts/AppendPlaneIntersectionStrokeHandler.d.ts +2 -3
  124. package/lib/esm/curve/internalContexts/AppendPlaneIntersectionStrokeHandler.d.ts.map +1 -1
  125. package/lib/esm/curve/internalContexts/AppendPlaneIntersectionStrokeHandler.js +5 -6
  126. package/lib/esm/curve/internalContexts/AppendPlaneIntersectionStrokeHandler.js.map +1 -1
  127. package/lib/esm/curve/spiral/TransitionSpiral3d.d.ts.map +1 -1
  128. package/lib/esm/curve/spiral/TransitionSpiral3d.js.map +1 -1
  129. package/lib/esm/geometry3d/Ellipsoid.d.ts +4 -3
  130. package/lib/esm/geometry3d/Ellipsoid.d.ts.map +1 -1
  131. package/lib/esm/geometry3d/Ellipsoid.js +7 -4
  132. package/lib/esm/geometry3d/Ellipsoid.js.map +1 -1
  133. package/lib/esm/geometry3d/Matrix3d.d.ts +2 -0
  134. package/lib/esm/geometry3d/Matrix3d.d.ts.map +1 -1
  135. package/lib/esm/geometry3d/Matrix3d.js +4 -0
  136. package/lib/esm/geometry3d/Matrix3d.js.map +1 -1
  137. package/lib/esm/geometry3d/Plane3d.d.ts +16 -11
  138. package/lib/esm/geometry3d/Plane3d.d.ts.map +1 -1
  139. package/lib/esm/geometry3d/Plane3d.js +16 -11
  140. package/lib/esm/geometry3d/Plane3d.js.map +1 -1
  141. package/lib/esm/serialization/IModelJsonSchema.d.ts.map +1 -1
  142. package/lib/esm/serialization/IModelJsonSchema.js +8 -13
  143. package/lib/esm/serialization/IModelJsonSchema.js.map +1 -1
  144. package/lib/esm/solid/Box.d.ts +2 -0
  145. package/lib/esm/solid/Box.d.ts.map +1 -1
  146. package/lib/esm/solid/Box.js +4 -0
  147. package/lib/esm/solid/Box.js.map +1 -1
  148. package/lib/esm/solid/Cone.d.ts +12 -0
  149. package/lib/esm/solid/Cone.d.ts.map +1 -1
  150. package/lib/esm/solid/Cone.js +23 -0
  151. package/lib/esm/solid/Cone.js.map +1 -1
  152. package/lib/esm/solid/LinearSweep.d.ts +2 -0
  153. package/lib/esm/solid/LinearSweep.d.ts.map +1 -1
  154. package/lib/esm/solid/LinearSweep.js +4 -0
  155. package/lib/esm/solid/LinearSweep.js.map +1 -1
  156. package/lib/esm/solid/RotationalSweep.d.ts +2 -0
  157. package/lib/esm/solid/RotationalSweep.d.ts.map +1 -1
  158. package/lib/esm/solid/RotationalSweep.js +4 -0
  159. package/lib/esm/solid/RotationalSweep.js.map +1 -1
  160. package/lib/esm/solid/RuledSweep.d.ts +1 -1
  161. package/lib/esm/solid/RuledSweep.js.map +1 -1
  162. package/lib/esm/solid/SolidPrimitive.d.ts +8 -1
  163. package/lib/esm/solid/SolidPrimitive.d.ts.map +1 -1
  164. package/lib/esm/solid/SolidPrimitive.js +8 -0
  165. package/lib/esm/solid/SolidPrimitive.js.map +1 -1
  166. package/lib/esm/solid/Sphere.d.ts +2 -0
  167. package/lib/esm/solid/Sphere.d.ts.map +1 -1
  168. package/lib/esm/solid/Sphere.js +4 -0
  169. package/lib/esm/solid/Sphere.js.map +1 -1
  170. package/lib/esm/solid/TorusPipe.d.ts +2 -0
  171. package/lib/esm/solid/TorusPipe.d.ts.map +1 -1
  172. package/lib/esm/solid/TorusPipe.js +4 -0
  173. package/lib/esm/solid/TorusPipe.js.map +1 -1
  174. package/package.json +3 -3
@@ -33,9 +33,8 @@ export declare class AppendPlaneIntersectionStrokeHandler extends NewtonRtoRStro
33
33
  private announceSolutionFraction;
34
34
  evaluate(fraction: number): boolean;
35
35
  /**
36
- * * ASSUME both the "A" and "B" evaluations (fraction, function, and derivative) are known.
37
- * * If function value changed sign between, interpolate an approximate root and improve it with
38
- * the newton solver.
36
+ * * ASSUME both the "A" and "B" evaluations (fraction, function, and derivative) are known.
37
+ * * If function value changed sign between, interpolate an approximate root and improve it with the newton solver.
39
38
  */
40
39
  private searchInterval;
41
40
  /** Evaluate and save _functionB, _derivativeB, and _fractionB. */
@@ -1 +1 @@
1
- {"version":3,"file":"AppendPlaneIntersectionStrokeHandler.d.ts","sourceRoot":"","sources":["../../../../src/curve/internalContexts/AppendPlaneIntersectionStrokeHandler.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAY,sBAAsB,EAAE,MAAM,gBAAgB,CAAC;AAClE,OAAO,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAClE,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,kCAAkC,CAAC;AAGrE,OAAO,EAA0C,uBAAuB,EAAE,MAAM,uBAAuB,CAAC;AACxG,OAAO,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;AAC7D,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAEnD;;;GAGG;AACH,qBAAa,oCAAqC,SAAQ,uBAAwB,YAAW,cAAc;IACzG,OAAO,CAAC,MAAM,CAA6B;IAC3C,OAAO,CAAC,MAAM,CAAyB;IACvC,OAAO,CAAC,cAAc,CAAwB;IAC9C,OAAO,CAAC,UAAU,CAAa;IAC/B,OAAO,CAAC,UAAU,CAAa;IAE/B,OAAO,CAAC,UAAU,CAAa;IAC/B,OAAO,CAAC,UAAU,CAAa;IAC/B,OAAO,CAAC,YAAY,CAAa;IACjC,OAAO,CAAC,aAAa,CAAa;IAElC,OAAO,CAAC,IAAI,CAAQ;IACpB,OAAO,CAAC,aAAa,CAAyC;IAGvD,cAAc,IAAI,cAAc,GAAG,SAAS;IAMnD,IAAW,cAAc,WAExB;gBAEkB,KAAK,EAAE,sBAAsB,EAAE,aAAa,EAAE,mBAAmB,EAAE;IAS/E,mBAAmB,CAAC,KAAK,EAAE,cAAc,GAAG,SAAS;IAQrD,iBAAiB;IAGjB,qCAAqC,CAC1C,EAAE,EAAE,cAAc,EAClB,UAAU,EAAE,MAAM,EAClB,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,MAAM,GAAG,IAAI;IAWnB,uBAAuB,CAC5B,GAAG,EAAE,cAAc,EACnB,MAAM,EAAE,OAAO,EACf,MAAM,EAAE,OAAO,EACf,WAAW,EAAE,MAAM,EACnB,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,MAAM,GAAG,IAAI;IAkB1B,OAAO,CAAC,wBAAwB;IAQzB,QAAQ,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO;IAQ1C;;;;OAIG;IACH,OAAO,CAAC,cAAc;IActB,kEAAkE;IAClE,OAAO,CAAC,SAAS;IAMjB;;;;;;;;;OASG;IACI,oBAAoB,CAAC,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,QAAQ,GAAG,IAAI;CAMrF"}
1
+ {"version":3,"file":"AppendPlaneIntersectionStrokeHandler.d.ts","sourceRoot":"","sources":["../../../../src/curve/internalContexts/AppendPlaneIntersectionStrokeHandler.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAY,sBAAsB,EAAE,MAAM,gBAAgB,CAAC;AAClE,OAAO,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAClE,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,kCAAkC,CAAC;AAGrE,OAAO,EAA0C,uBAAuB,EAAE,MAAM,uBAAuB,CAAC;AACxG,OAAO,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;AAC7D,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAEnD;;;GAGG;AACH,qBAAa,oCAAqC,SAAQ,uBAAwB,YAAW,cAAc;IACzG,OAAO,CAAC,MAAM,CAA6B;IAC3C,OAAO,CAAC,MAAM,CAAyB;IACvC,OAAO,CAAC,cAAc,CAAwB;IAC9C,OAAO,CAAC,UAAU,CAAa;IAC/B,OAAO,CAAC,UAAU,CAAa;IAE/B,OAAO,CAAC,UAAU,CAAa;IAC/B,OAAO,CAAC,UAAU,CAAa;IAC/B,OAAO,CAAC,YAAY,CAAa;IACjC,OAAO,CAAC,aAAa,CAAa;IAElC,OAAO,CAAC,IAAI,CAAQ;IACpB,OAAO,CAAC,aAAa,CAAyC;IAEvD,cAAc,IAAI,cAAc,GAAG,SAAS;IAKnD,IAAW,cAAc,WAExB;gBACkB,KAAK,EAAE,sBAAsB,EAAE,aAAa,EAAE,mBAAmB,EAAE;IAQ/E,mBAAmB,CAAC,KAAK,EAAE,cAAc,GAAG,SAAS,GAAG,IAAI;IAO5D,iBAAiB;IACjB,qCAAqC,CAC1C,EAAE,EAAE,cAAc,EAClB,UAAU,EAAE,MAAM,EAClB,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,MAAM,GAChB,IAAI;IAWA,uBAAuB,CAC5B,GAAG,EAAE,cAAc,EACnB,MAAM,EAAE,OAAO,EACf,MAAM,EAAE,OAAO,EACf,WAAW,EAAE,MAAM,EACnB,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,MAAM,GAChB,IAAI;IAiBP,OAAO,CAAC,wBAAwB;IAOzB,QAAQ,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO;IAQ1C;;;OAGG;IACH,OAAO,CAAC,cAAc;IAgBtB,kEAAkE;IAClE,OAAO,CAAC,SAAS;IAKjB;;;;;;;;;OASG;IACI,oBAAoB,CAAC,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,QAAQ,GAAG,IAAI;CAOrF"}
@@ -23,7 +23,7 @@ class AppendPlaneIntersectionStrokeHandler extends Newton_1.NewtonRtoRStrokeHand
23
23
  _intersections;
24
24
  _fractionA = 0;
25
25
  _functionA = 0;
26
- // private derivativeA: number; <---- Not currently used
26
+ // private derivativeA: number; <---- Not currently used
27
27
  _functionB = 0;
28
28
  _fractionB = 0;
29
29
  _derivativeB = 0;
@@ -55,8 +55,7 @@ class AppendPlaneIntersectionStrokeHandler extends Newton_1.NewtonRtoRStrokeHand
55
55
  this._functionA = 0.0;
56
56
  // this.derivativeA = 0.0;
57
57
  }
58
- endCurvePrimitive() {
59
- }
58
+ endCurvePrimitive() { }
60
59
  announceIntervalForUniformStepStrokes(cp, numStrokes, fraction0, fraction1) {
61
60
  this.startCurvePrimitive(cp);
62
61
  if (numStrokes < 1)
@@ -96,13 +95,13 @@ class AppendPlaneIntersectionStrokeHandler extends Newton_1.NewtonRtoRStrokeHand
96
95
  const curve = this.effectiveCurve();
97
96
  if (!curve)
98
97
  return false;
98
+ // the Newton function is just plane altitude: curve points that lie on the plane are altitude roots (i.e., altitude = 0).
99
99
  this.currentF = this._plane.altitude(curve.fractionToPoint(fraction));
100
100
  return true;
101
101
  }
102
102
  /**
103
- * * ASSUME both the "A" and "B" evaluations (fraction, function, and derivative) are known.
104
- * * If function value changed sign between, interpolate an approximate root and improve it with
105
- * the newton solver.
103
+ * * ASSUME both the "A" and "B" evaluations (fraction, function, and derivative) are known.
104
+ * * If function value changed sign between, interpolate an approximate root and improve it with the newton solver.
106
105
  */
107
106
  searchInterval() {
108
107
  if (this._functionA * this._functionB > 0)
@@ -1 +1 @@
1
- {"version":3,"file":"AppendPlaneIntersectionStrokeHandler.js","sourceRoot":"","sources":["../../../../src/curve/internalContexts/AppendPlaneIntersectionStrokeHandler.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,6CAAkE;AAGlE,kDAA+C;AAC/C,wEAAgE;AAChE,kDAAwG;AACxG,gEAA6D;AAG7D;;;GAGG;AACH,MAAa,oCAAqC,SAAQ,gCAAuB;IACvE,MAAM,CAA6B;IACnC,MAAM,CAAyB;IAC/B,cAAc,CAAwB;IACtC,UAAU,GAAW,CAAC,CAAC;IACvB,UAAU,GAAW,CAAC,CAAC;IAC/B,0DAA0D;IAClD,UAAU,GAAW,CAAC,CAAC;IACvB,UAAU,GAAW,CAAC,CAAC;IACvB,YAAY,GAAW,CAA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aAAa,EAAE;oBACpC,IAAI,CAAC,wBAAwB,CAAC,IAAI,CAAC,aAAa,CAAC,IAAI,EAAE,CAAC,CAAC;YAC7D,CAAC;QACH,CAAC;IACH,CAAC;IAED,kEAAkE;IAC1D,SAAS,CAAC,GAAY,EAAE,QAAgB,EAAE,OAAiB;QACjE,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC;QAC5C,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC;QAClD,IAAI,CAAC,UAAU,GAAG,QAAQ,CAAC;IAC7B,CAAC;IAED;;;;;;;;;OASG;IACI,oBAAoB,CAAC,GAAY,EAAE,QAAgB,EAAE,OAAiB;QAC3E,IAAI,CAAC,SAAS,CAAC,GAAG,EAAE,QAAQ,EAAE,OAAO,CAAC,CAAC;QACvC,IAAI,IAAI,CAAC,aAAa,EAAE,GAAG,CAAC;YAAE,IAAI,CAAC,cAAc,EAAE,CAAC;QACpD,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,UAAU,CAAC;QAClC,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,UAAU,CAAC;IACpC,CAAC;CACF;AA/ID,oFA+IC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Curve\r\n */\r\n\r\nimport { Geometry, PlaneAltitudeEvaluator } from \"../../Geometry\";\r\nimport { IStrokeHandler } from \"../../geometry3d/GeometryHandler\";\r\nimport { Point3d, Vector3d } from \"../../geometry3d/Point3dVector3d\";\r\nimport { Ray3d } from \"../../geometry3d/Ray3d\";\r\nimport { Order2Bezier } from \"../../numerics/BezierPolynomials\";\r\nimport { Newton1dUnboundedApproximateDerivative, NewtonRtoRStrokeHandler } from \"../../numerics/Newton\";\r\nimport { CurveLocationDetail } from \"../CurveLocationDetail\";\r\nimport { CurvePrimitive } from \"../CurvePrimitive\";\r\n\r\n/**\r\n * Context for computing intersections of a CurvePrimitive with a plane.\r\n * @internal\r\n */\r\nexport class AppendPlaneIntersectionStrokeHandler extends NewtonRtoRStrokeHandler implements IStrokeHandler {\r\n private _curve: CurvePrimitive | undefined;\r\n private _plane: PlaneAltitudeEvaluator;\r\n private _intersections: CurveLocationDetail[];\r\n private _fractionA: number = 0;\r\n private _functionA: number = 0;\r\n // private derivativeA: number; <---- Not currently used\r\n private _functionB: number = 0;\r\n private _fractionB: number = 0;\r\n private _derivativeB: number = 0;\r\n private _numThisCurve: number = 0;\r\n // scratch vars for use within methods.\r\n private _ray: Ray3d;\r\n private _newtonSolver: Newton1dUnboundedApproximateDerivative;\r\n\r\n // Return the first defined curve among: this.parentCurvePrimitive, this.curve;\r\n public effectiveCurve(): CurvePrimitive | undefined {\r\n if (this._parentCurvePrimitive)\r\n return this._parentCurvePrimitive;\r\n return this._curve;\r\n }\r\n\r\n public get getDerivativeB() {\r\n return this._derivativeB; // <--- _derivativeB is not currently used anywhere. Provided getter to suppress lint error\r\n }\r\n\r\n public constructor(plane: PlaneAltitudeEvaluator, intersections: CurveLocationDetail[]) {\r\n super();\r\n this._plane = plane;\r\n this._intersections = intersections;\r\n this.startCurvePrimitive(undefined);\r\n this._ray = Ray3d.createZero();\r\n this._newtonSolver = new Newton1dUnboundedApproximateDerivative(this);\r\n }\r\n\r\n public startCurvePrimitive(curve: CurvePrimitive | undefined) {\r\n this._curve = curve;\r\n this._fractionA = 0.0;\r\n this._numThisCurve = 0;\r\n this._functionA = 0.0;\r\n // this.derivativeA = 0.0;\r\n }\r\n\r\n public endCurvePrimitive() {\r\n }\r\n\r\n public announceIntervalForUniformStepStrokes(\r\n cp: CurvePrimitive,\r\n numStrokes: number,\r\n fraction0: number,\r\n fraction1: number): void {\r\n this.startCurvePrimitive(cp);\r\n if (numStrokes < 1) numStrokes = 1;\r\n const df = 1.0 / numStrokes;\r\n for (let i = 0; i <= numStrokes; i++) {\r\n const fraction = Geometry.interpolate(fraction0, i * df, fraction1);\r\n cp.fractionToPointAndDerivative(fraction, this._ray);\r\n this.announcePointTangent(this._ray.origin, fraction, this._ray.direction);\r\n }\r\n }\r\n\r\n public announceSegmentInterval(\r\n _cp: CurvePrimitive,\r\n point0: Point3d,\r\n point1: Point3d,\r\n _numStrokes: number,\r\n fraction0: number,\r\n fraction1: number): void {\r\n const h0 = this._plane.altitude(point0);\r\n const h1 = this._plane.altitude(point1);\r\n if (h0 * h1 > 0.0)\r\n return;\r\n const fraction01 = Order2Bezier.solveCoffs(h0, h1);\r\n // let numIntersection = 0;\r\n if (fraction01 !== undefined) {\r\n // numIntersection++;\r\n const fraction = Geometry.interpolate(fraction0, fraction01, fraction1);\r\n this._newtonSolver.setX(fraction);\r\n if (this._newtonSolver.runIterations()) {\r\n this.announceSolutionFraction(this._newtonSolver.getX());\r\n }\r\n // this.intersections.push(CurveLocationDetail.createCurveFractionPoint(cp, fraction, cp.fractionToPoint(fraction)));\r\n }\r\n }\r\n\r\n private announceSolutionFraction(fraction: number) {\r\n const curve = this.effectiveCurve();\r\n if (curve) {\r\n this._ray = curve.fractionToPointAndDerivative(fraction, this._ray);\r\n this._intersections.push(CurveLocationDetail.createCurveFractionPoint(curve, fraction, this._ray.origin));\r\n }\r\n }\r\n\r\n public evaluate(fraction: number): boolean {\r\n const curve = this.effectiveCurve();\r\n if (!curve)\r\n return false;\r\n this.currentF = this._plane.altitude(curve.fractionToPoint(fraction));\r\n return true;\r\n }\r\n\r\n /**\r\n * * ASSUME both the \"A\" and \"B\" evaluations (fraction, function, and derivative) are known.\r\n * * If function value changed sign between, interpolate an approximate root and improve it with\r\n * the newton solver.\r\n */\r\n private searchInterval() {\r\n if (this._functionA * this._functionB > 0) return;\r\n if (this._functionA === 0) this.announceSolutionFraction(this._fractionA);\r\n if (this._functionB === 0) this.announceSolutionFraction(this._fractionB);\r\n if (this._functionA * this._functionB < 0) {\r\n const fraction = Geometry.inverseInterpolate(this._fractionA, this._functionA, this._fractionB, this._functionB);\r\n if (fraction) {\r\n this._newtonSolver.setX(fraction);\r\n if (this._newtonSolver.runIterations())\r\n this.announceSolutionFraction(this._newtonSolver.getX());\r\n }\r\n }\r\n }\r\n\r\n /** Evaluate and save _functionB, _derivativeB, and _fractionB. */\r\n private evaluateB(xyz: Point3d, fraction: number, tangent: Vector3d) {\r\n this._functionB = this._plane.altitude(xyz);\r\n this._derivativeB = this._plane.velocity(tangent);\r\n this._fractionB = fraction;\r\n }\r\n\r\n /**\r\n * Announce point and tangent for evaluations.\r\n * * The function evaluation is saved as the \"B\" function point.\r\n * * The function point count is incremented\r\n * * If function point count is greater than 1, the current interval is searched.\r\n * * The just-evaluated point (\"B\") is saved as the \"old\" (\"A\") evaluation point.\r\n * @param xyz\r\n * @param fraction\r\n * @param tangent\r\n */\r\n public announcePointTangent(xyz: Point3d, fraction: number, tangent: Vector3d): void {\r\n this.evaluateB(xyz, fraction, tangent);\r\n if (this._numThisCurve++ > 0) this.searchInterval();\r\n this._functionA = this._functionB;\r\n this._fractionA = this._fractionB;\r\n }\r\n}\r\n"]}
1
+ {"version":3,"file":"AppendPlaneIntersectionStrokeHandler.js","sourceRoot":"","sources":["../../../../src/curve/internalContexts/AppendPlaneIntersectionStrokeHandler.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,6CAAkE;AAGlE,kDAA+C;AAC/C,wEAAgE;AAChE,kDAAwG;AACxG,gEAA6D;AAG7D;;;GAGG;AACH,MAAa,oCAAqC,SAAQ,gCAAuB;IACvE,MAAM,CAA6B;IACnC,MAAM,CAAyB;IAC/B,cAAc,CAAwB;IACtC,UAAU,GAAW,CAAC,CAAC;IACvB,UAAU,GAAW,CAAC,CAAC;IAC/B,yDAAyD;IACjD,UAAU,GAAW,CAAC,CAAC;IACvB,UAAU,GAAW,CAAC,CAAC;IAC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,IAAI,CAAC,aAAa,CAAC,aAAa,EAAE;oBACpC,IAAI,CAAC,wBAAwB,CAAC,IAAI,CAAC,aAAa,CAAC,IAAI,EAAE,CAAC,CAAC;YAC7D,CAAC;QACH,CAAC;IACH,CAAC;IACD,kEAAkE;IAC1D,SAAS,CAAC,GAAY,EAAE,QAAgB,EAAE,OAAiB;QACjE,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC;QAC5C,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC;QAClD,IAAI,CAAC,UAAU,GAAG,QAAQ,CAAC;IAC7B,CAAC;IACD;;;;;;;;;OASG;IACI,oBAAoB,CAAC,GAAY,EAAE,QAAgB,EAAE,OAAiB;QAC3E,IAAI,CAAC,SAAS,CAAC,GAAG,EAAE,QAAQ,EAAE,OAAO,CAAC,CAAC;QACvC,IAAI,IAAI,CAAC,aAAa,EAAE,GAAG,CAAC;YAC1B,IAAI,CAAC,cAAc,EAAE,CAAC;QACxB,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,UAAU,CAAC;QAClC,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,UAAU,CAAC;IACpC,CAAC;CACF;AAzID,oFAyIC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Curve\r\n */\r\n\r\nimport { Geometry, PlaneAltitudeEvaluator } from \"../../Geometry\";\r\nimport { IStrokeHandler } from \"../../geometry3d/GeometryHandler\";\r\nimport { Point3d, Vector3d } from \"../../geometry3d/Point3dVector3d\";\r\nimport { Ray3d } from \"../../geometry3d/Ray3d\";\r\nimport { Order2Bezier } from \"../../numerics/BezierPolynomials\";\r\nimport { Newton1dUnboundedApproximateDerivative, NewtonRtoRStrokeHandler } from \"../../numerics/Newton\";\r\nimport { CurveLocationDetail } from \"../CurveLocationDetail\";\r\nimport { CurvePrimitive } from \"../CurvePrimitive\";\r\n\r\n/**\r\n * Context for computing intersections of a CurvePrimitive with a plane.\r\n * @internal\r\n */\r\nexport class AppendPlaneIntersectionStrokeHandler extends NewtonRtoRStrokeHandler implements IStrokeHandler {\r\n private _curve: CurvePrimitive | undefined;\r\n private _plane: PlaneAltitudeEvaluator;\r\n private _intersections: CurveLocationDetail[];\r\n private _fractionA: number = 0;\r\n private _functionA: number = 0;\r\n // private derivativeA: number; <---- Not currently used\r\n private _functionB: number = 0;\r\n private _fractionB: number = 0;\r\n private _derivativeB: number = 0;\r\n private _numThisCurve: number = 0;\r\n // scratch vars for use within methods.\r\n private _ray: Ray3d;\r\n private _newtonSolver: Newton1dUnboundedApproximateDerivative;\r\n // Return the first defined curve among: this.parentCurvePrimitive, this.curve;\r\n public effectiveCurve(): CurvePrimitive | undefined {\r\n if (this._parentCurvePrimitive)\r\n return this._parentCurvePrimitive;\r\n return this._curve;\r\n }\r\n public get getDerivativeB() {\r\n return this._derivativeB; // <--- _derivativeB is not currently used anywhere. Provided getter to suppress lint error\r\n }\r\n public constructor(plane: PlaneAltitudeEvaluator, intersections: CurveLocationDetail[]) {\r\n super();\r\n this._plane = plane;\r\n this._intersections = intersections;\r\n this.startCurvePrimitive(undefined);\r\n this._ray = Ray3d.createZero();\r\n this._newtonSolver = new Newton1dUnboundedApproximateDerivative(this);\r\n }\r\n public startCurvePrimitive(curve: CurvePrimitive | undefined): void {\r\n this._curve = curve;\r\n this._fractionA = 0.0;\r\n this._numThisCurve = 0;\r\n this._functionA = 0.0;\r\n // this.derivativeA = 0.0;\r\n }\r\n public endCurvePrimitive() { }\r\n public announceIntervalForUniformStepStrokes(\r\n cp: CurvePrimitive,\r\n numStrokes: number,\r\n fraction0: number,\r\n fraction1: number,\r\n ): void {\r\n this.startCurvePrimitive(cp);\r\n if (numStrokes < 1)\r\n numStrokes = 1;\r\n const df = 1.0 / numStrokes;\r\n for (let i = 0; i <= numStrokes; i++) {\r\n const fraction = Geometry.interpolate(fraction0, i * df, fraction1);\r\n cp.fractionToPointAndDerivative(fraction, this._ray);\r\n this.announcePointTangent(this._ray.origin, fraction, this._ray.direction);\r\n }\r\n }\r\n public announceSegmentInterval(\r\n _cp: CurvePrimitive,\r\n point0: Point3d,\r\n point1: Point3d,\r\n _numStrokes: number,\r\n fraction0: number,\r\n fraction1: number,\r\n ): void {\r\n const h0 = this._plane.altitude(point0);\r\n const h1 = this._plane.altitude(point1);\r\n if (h0 * h1 > 0.0)\r\n return;\r\n const fraction01 = Order2Bezier.solveCoffs(h0, h1);\r\n // let numIntersection = 0;\r\n if (fraction01 !== undefined) {\r\n // numIntersection++;\r\n const fraction = Geometry.interpolate(fraction0, fraction01, fraction1);\r\n this._newtonSolver.setX(fraction);\r\n if (this._newtonSolver.runIterations()) {\r\n this.announceSolutionFraction(this._newtonSolver.getX());\r\n }\r\n // this.intersections.push(CurveLocationDetail.createCurveFractionPoint(cp, fraction, cp.fractionToPoint(fraction)));\r\n }\r\n }\r\n private announceSolutionFraction(fraction: number): void {\r\n const curve = this.effectiveCurve();\r\n if (curve) {\r\n this._ray = curve.fractionToPointAndDerivative(fraction, this._ray);\r\n this._intersections.push(CurveLocationDetail.createCurveFractionPoint(curve, fraction, this._ray.origin));\r\n }\r\n }\r\n public evaluate(fraction: number): boolean {\r\n const curve = this.effectiveCurve();\r\n if (!curve)\r\n return false;\r\n // the Newton function is just plane altitude: curve points that lie on the plane are altitude roots (i.e., altitude = 0).\r\n this.currentF = this._plane.altitude(curve.fractionToPoint(fraction));\r\n return true;\r\n }\r\n /**\r\n * * ASSUME both the \"A\" and \"B\" evaluations (fraction, function, and derivative) are known.\r\n * * If function value changed sign between, interpolate an approximate root and improve it with the newton solver.\r\n */\r\n private searchInterval(): void {\r\n if (this._functionA * this._functionB > 0)\r\n return;\r\n if (this._functionA === 0)\r\n this.announceSolutionFraction(this._fractionA);\r\n if (this._functionB === 0)\r\n this.announceSolutionFraction(this._fractionB);\r\n if (this._functionA * this._functionB < 0) {\r\n const fraction = Geometry.inverseInterpolate(this._fractionA, this._functionA, this._fractionB, this._functionB);\r\n if (fraction) {\r\n this._newtonSolver.setX(fraction);\r\n if (this._newtonSolver.runIterations())\r\n this.announceSolutionFraction(this._newtonSolver.getX());\r\n }\r\n }\r\n }\r\n /** Evaluate and save _functionB, _derivativeB, and _fractionB. */\r\n private evaluateB(xyz: Point3d, fraction: number, tangent: Vector3d): void {\r\n this._functionB = this._plane.altitude(xyz);\r\n this._derivativeB = this._plane.velocity(tangent);\r\n this._fractionB = fraction;\r\n }\r\n /**\r\n * Announce point and tangent for evaluations.\r\n * * The function evaluation is saved as the \"B\" function point.\r\n * * The function point count is incremented\r\n * * If function point count is greater than 1, the current interval is searched.\r\n * * The just-evaluated point (\"B\") is saved as the \"old\" (\"A\") evaluation point.\r\n * @param xyz\r\n * @param fraction\r\n * @param tangent\r\n */\r\n public announcePointTangent(xyz: Point3d, fraction: number, tangent: Vector3d): void {\r\n this.evaluateB(xyz, fraction, tangent);\r\n if (this._numThisCurve++ > 0)\r\n this.searchInterval();\r\n this._functionA = this._functionB;\r\n this._fractionA = this._fractionB;\r\n }\r\n}\r\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"TransitionSpiral3d.d.ts","sourceRoot":"","sources":["../../../../src/curve/spiral/TransitionSpiral3d.ts"],"names":[],"mappings":"AAKA;;GAEG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAE5D,OAAO,EAAE,QAAQ,EAAE,MAAM,2BAA2B,CAAC;AACrD,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AAC1D,OAAO,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAC;AACvD,OAAO,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAC;AACvD,OAAO,EAAE,cAAc,E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,CAAC,WAAW,EAAE,CAAC;IAC/B,CAAC;IACD,qDAAqD;IACrC,WAAW,CAAC,aAAsB,EAAE,SAAqB;QACvE,aAAa,CAAC,WAAW,CAAC,IAAI,CAAC,qBAAqB,CAAC,GAAG,EAAE,GAAG,EAAE,SAAS,CAAC,CAAC,CAAC;IAC7E,CAAC;IACD;;;OAGG;IACa,qBAAqB,CAAC,SAAiB,EAAE,SAAiB,EAAE,SAAqB;QAC/F,MAAM,OAAO,GAAG,IAAI,CAAC,aAAa,CAAC;QACnC,IAAI,SAAS,KAAK,OAAO;YACvB,OAAO,eAAO,CAAC,UAAU,EAAE,CAAC;QAC9B,IAAI,KAAK,GAAG,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,SAAS,EAAE,GAAG,IAAI,CAAC,GAAG,CAAC,SAAS,GAAG,SAAS,CAAC,CAAC,CAAC;QAC7E,KAAK,GAAG,mBAAQ,CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,CAAC,CAAC;QACrC,OAAO,IAAI,CAAC,4BAA4B,CAAC,SAAS,EAAE,SAAS,EAAE,KAAK,EAAE,SAAS,EAAE,GAAG,CAAC,CAAC;IACxF,CAAC;IACD;;;;;;;OAOG;IACa,uBAAuB,CAAC,GAAqB,EAAE,OAAiB;QAC9E,OAAO,qDAAyB,CAAC,kCAAkC,CAAC,IAAI,EAAE,GAAG,EAAE,OAAO,CAAC,CAAC;IAC1F,CAAC;CACF;AA5KD,gDA4KC","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 Curve\r\n */\r\n\r\nimport { BSplineCurve3d } from \"../../bspline/BSplineCurve\";\r\nimport { Geometry } from \"../../Geometry\";\r\nimport { Matrix3d } from \"../../geometry3d/Matrix3d\";\r\nimport { Range1d, Range3d } from \"../../geometry3d/Range\";\r\nimport { Segment1d } from \"../../geometry3d/Segment1d\";\r\nimport { Transform } from \"../../geometry3d/Transform\";\r\nimport { CurvePrimitive } from \"../CurvePrimitive\";\r\nimport { CurveOffsetXYHandler } from \"../internalContexts/CurveOffsetXYHandler\";\r\nimport { PlaneAltitudeRangeContext } from \"../internalContexts/PlaneAltitudeRangeContext\";\r\nimport { LineString3d } from \"../LineString3d\";\r\nimport { OffsetOptions } from \"../OffsetOptions\";\r\nimport { TransitionConditionalProperties } from \"./TransitionConditionalProperties\";\r\n\r\nimport type { Vector3d } from \"../../geometry3d/Point3dVector3d\";\r\nimport type { Ray3d } from \"../../geometry3d/Ray3d\";\r\n\r\n/**\r\n * This is the set of valid type names for \"integrated\" spirals.\r\n * * Behavior is expressed by a `NormalizedTransition` snap function.\r\n * * The snap function varies smoothly from f(0) = 0 to f(1) = 1.\r\n * * The various snap functions are:\r\n * * clothoid: linear\r\n * * biquadratic: 2 quadratics pieced together, joining with 1st derivative continuity at f(0.5) = 0.5, with zero\r\n * slope f'(0) = 0 and f'(1) = 0\r\n * * bloss: A single cubic with zero slope at 0 and 1\r\n * * cosine: half of a cosine wave, centered around 0.5\r\n * * sine: full period of a sine wave added to the line f(u)=u\r\n * *\r\n * @public\r\n */\r\nexport type IntegratedSpiralTypeName = \"clothoid\" | \"bloss\" | \"biquadratic\" | \"cosine\" | \"sine\";\r\n\r\n/**\r\n * This is the set of valid type names for \"direct\" spirals.\r\n * \"Direct\" spirals can evaluate fractionToPoint by direct equations, i.e. not requiring the numeric integrations in\r\n * \"Integrated\" spiral types.\r\n * @public\r\n */\r\nexport type DirectSpiralTypeName =\r\n \"Arema\" // 2 terms from each of the X,Y clothoid series expansions; identical to ChineseCubic\r\n | \"JapaneseCubic\" // 1 term from each of the X,Y clothoid series expansions; y = x^3 / (6RL)\r\n | \"ChineseCubic\" // identical to Arema\r\n | \"WesternAustralian\" // simple cubic; 2 terms of x series, 1 term of y series\r\n | \"HalfCosine\" // high continuity cosine variation from quadratic\r\n | \"AustralianRailCorp\" // cubic with high accuracy distance series\r\n | \"Czech\" // simple cubic with two term distance approximation\r\n | \"Italian\" // similar to Czech\r\n | \"MXCubicAlongArc\" // x obtained from fractional distance via 2-terms from series, y = x^3 / (6RL)\r\n | \"Polish\" // similar to MXCubicAlongArc\r\n ;\r\n\r\n/**\r\n * TransitionSpiral3d is a base class for multiple variants of spirals.\r\n * * The menagerie of spiral types have 2 broad categories:\r\n * * IntegratedSpiral3d -- a spiral whose direct function for curvature versus distance must be integrated to\r\n * determine x,y.\r\n * * The IntegratedSpiral3d types are enumerated in `IntegratedSpiralTypes`.\r\n * * DirectSpiral3d -- a spiral implemented with direct calculation of x,y from fractional position along the spiral.\r\n * * The direct spiral types are enumerated in the `DirectSpiralType`.\r\n * * The method set for CurvePrimitive support includes a `handleTransitionSpiral(g: TransitionSpiral3d)` which receives\r\n * all the spiral types.\r\n * * The spiral class may impose expectations that its inflection is at the origin, with tangent along the x axis.\r\n * * This is generally necessary for direct spirals.\r\n * * This is not necessary for integrated spirals.\r\n * @public\r\n */\r\n// see internaldocs/Spiral.md for more info\r\nexport abstract class TransitionSpiral3d extends CurvePrimitive {\r\n /** String name of spiral type. */\r\n protected _spiralType: string;\r\n /** Original defining properties. */\r\n protected _designProperties: TransitionConditionalProperties | undefined;\r\n /** Placement transform. */\r\n protected _localToWorld: Transform;\r\n /**\r\n * Fractional interval for the \"active\" part of a containing spiral.\r\n * (the radius, angle, and length conditions define a complete spiral, and some portion of it is \"active\")\r\n */\r\n protected _activeFractionInterval: Segment1d;\r\n /** Return (reference to) the active portion of the reference spiral. */\r\n public get activeFractionInterval(): Segment1d {\r\n return this._activeFractionInterval;\r\n }\r\n /** Strokes in the active portion. */\r\n public abstract get activeStrokes(): LineString3d;\r\n /** (Reference to) placement transform. */\r\n public get localToWorld(): Transform {\r\n return this._localToWorld;\r\n }\r\n protected constructor(\r\n spiralType: string | undefined,\r\n localToWorld: Transform,\r\n activeFractionInterval: Segment1d | undefined,\r\n designProperties: TransitionConditionalProperties | undefined,\r\n ) {\r\n super();\r\n this._spiralType = spiralType ? spiralType : \"unknownSpiralType\";\r\n this._designProperties = designProperties;\r\n this._localToWorld = localToWorld;\r\n this._activeFractionInterval = activeFractionInterval ? activeFractionInterval : Segment1d.create(0, 1);\r\n }\r\n public get spiralType(): string {\r\n return this._spiralType;\r\n }\r\n /** Return 1/r with convention that exact zero input returns 0 (straight line, zero curvature, infinite radius). */\r\n public static radiusToCurvature(radius: number): number {\r\n return (radius === 0.0) ? 0.0 : 1.0 / radius;\r\n }\r\n /** Return 1/k with convention that near-zero input returns 0 (straight line, zero curvature, infinite radius). */\r\n public static curvatureToRadius(curvature: number): number {\r\n if (Math.abs(curvature) < Geometry.smallAngleRadians)\r\n return 0.0;\r\n return 1.0 / curvature;\r\n }\r\n /** Return a deep clone. */\r\n public abstract override clone(): TransitionSpiral3d;\r\n /** Recompute strokes. */\r\n public abstract refreshComputedProperties(): void;\r\n /** Return (if possible) a spiral which is a portion of this curve. */\r\n public override clonePartialCurve(fractionA: number, fractionB: number): TransitionSpiral3d {\r\n const spiralB = this.clone();\r\n const globalFractionA = this._activeFractionInterval.fractionToPoint(fractionA);\r\n const globalFractionB = this._activeFractionInterval.fractionToPoint(fractionB);\r\n spiralB._activeFractionInterval.set(globalFractionA, globalFractionB);\r\n spiralB.refreshComputedProperties();\r\n return spiralB;\r\n }\r\n /** Clone with a transform applied. */\r\n public override cloneTransformed(transform: Transform): TransitionSpiral3d {\r\n const result = this.clone();\r\n result.tryTransformInPlace(transform); // we're confident it will always work\r\n return result;\r\n }\r\n /** Return the average of the start and end curvatures. */\r\n public static averageCurvature(radiusLimits: Segment1d): number {\r\n return 0.5 * (TransitionSpiral3d.radiusToCurvature(radiusLimits.x0) + TransitionSpiral3d.radiusToCurvature(radiusLimits.x1));\r\n }\r\n /**\r\n * Given two radii (or zeros for 0 curvature) return the average curvature.\r\n * @param r0 start radius, or 0 for line.\r\n * @param r1 end radius, or 0 for line.\r\n */\r\n public static averageCurvatureR0R1(r0: number, r1: number): number {\r\n return 0.5 * (TransitionSpiral3d.radiusToCurvature(r0) + TransitionSpiral3d.radiusToCurvature(r1));\r\n }\r\n /**\r\n * Given two radii (or zeros for 0 curvature) return the curvature at the given fraction.\r\n * @param r0 start radius, or 0 for line.\r\n * @param fraction fractional position between the curvatures defined by r0 and r1.\r\n * @param r1 end radius, or 0 for line.\r\n */\r\n public static interpolateCurvatureR0R1(r0: number, fraction: number, r1: number): number {\r\n return Geometry.interpolate(TransitionSpiral3d.radiusToCurvature(r0), fraction, TransitionSpiral3d.radiusToCurvature(r1));\r\n }\r\n /** Return the arc length of a transition spiral with given sweep and radius pair. */\r\n public static radiusRadiusSweepRadiansToArcLength(radius0: number, radius1: number, sweepRadians: number): number {\r\n return Math.abs(sweepRadians / TransitionSpiral3d.averageCurvatureR0R1(radius0, radius1));\r\n }\r\n /** Return the turn angle for spiral of given length between two radii */\r\n public static radiusRadiusLengthToSweepRadians(radius0: number, radius1: number, arcLength: number): number {\r\n return TransitionSpiral3d.averageCurvatureR0R1(radius0, radius1) * arcLength;\r\n }\r\n /** Return the end radius for spiral of given start radius, length, and turn angle. */\r\n public static radius0LengthSweepRadiansToRadius1(radius0: number, arcLength: number, sweepRadians: number) {\r\n return TransitionSpiral3d.curvatureToRadius(\r\n (2.0 * sweepRadians / arcLength) - TransitionSpiral3d.radiusToCurvature(radius0),\r\n );\r\n }\r\n /** Return the start radius for spiral of given end radius, length, and turn angle. */\r\n public static radius1LengthSweepRadiansToRadius0(radius1: number, arcLength: number, sweepRadians: number) {\r\n return TransitionSpiral3d.curvatureToRadius(\r\n (2.0 * sweepRadians / arcLength) - TransitionSpiral3d.radiusToCurvature(radius1),\r\n );\r\n }\r\n /** Return the original defining properties (if any) saved by the constructor. */\r\n public get designProperties(): TransitionConditionalProperties | undefined {\r\n return this._designProperties;\r\n }\r\n /**\r\n * * If transformA is rigid with uniform scale, apply the rigid part of transformA to the localToWorld transform and\r\n * return the scale and rigid separation.\r\n * * If not rigid, do nothing and return undefined.\r\n * * Also apply the scale factor to the designProperties.\r\n * @param transformA\r\n */\r\n protected applyRigidPartOfTransform(transformA: Transform): { rigidAxes: Matrix3d, scale: number } | undefined {\r\n const rigidData = transformA.matrix.factorRigidWithSignedScale();\r\n if (rigidData !== undefined) {\r\n // [sQ a][R b] = [sQ*R sQb+a]\r\n // but we save it as [Q*R sQb+a] with spiral data scaled by s\r\n const transformC0 = transformA.multiplyTransformTransform(this.localToWorld);\r\n // but pull the scale part out of the matrix\r\n const matrixC = rigidData.rigidAxes.multiplyMatrixMatrix(this.localToWorld.matrix);\r\n this._localToWorld = Transform.createOriginAndMatrix(transformC0.origin, matrixC);\r\n if (this.designProperties)\r\n this.designProperties.applyScaleFactor(rigidData.scale);\r\n return rigidData;\r\n }\r\n return undefined;\r\n }\r\n /**\r\n * Construct an offset of the instance curve as viewed in the xy-plane (ignoring z).\r\n * * No attempt is made to join the offsets of smaller constituent primitives. To construct a fully joined offset for an\r\n * aggregate instance (e.g., LineString3d, CurveChainWithDistanceIndex), use RegionOps.constructCurveXYOffset() instead.\r\n * @param offsetDistanceOrOptions offset distance (positive to left of the instance curve), or options object.\r\n */\r\n public override constructOffsetXY(offsetDistanceOrOptions: number | OffsetOptions): BSplineCurve3d | undefined {\r\n const options = OffsetOptions.create(offsetDistanceOrOptions);\r\n const handler = new CurveOffsetXYHandler(this, options.leftOffsetDistance);\r\n this.emitStrokableParts(handler, options.strokeOptions);\r\n return handler.claimResult();\r\n }\r\n /** Extend the range by the strokes of the spiral. */\r\n public override extendRange(rangeToExtend: Range3d, transform?: Transform): void {\r\n rangeToExtend.extendRange(this.rangeBetweenFractions(0.0, 1.0, transform));\r\n }\r\n /**\r\n * Return the range of spiral between fractions of the activeStrokes.\r\n * * Use activeStrokes point count times interval factor for initial evaluation count, but do at least 5.\r\n */\r\n public override rangeBetweenFractions(fractionA: number, fractionB: number, transform?: Transform): Range3d {\r\n const strokes = this.activeStrokes;\r\n if (undefined === strokes)\r\n return Range3d.createNull();\r\n let count = Math.ceil(strokes.numPoints() * Math.abs(fractionB - fractionA));\r\n count = Geometry.clamp(5, count, 30);\r\n return this.rangeBetweenFractionsByCount(fractionA, fractionB, count, transform, 0.5);\r\n }\r\n /**\r\n * Project instance geometry (via dispatch) onto the given ray, and return the extreme fractional parameters of\r\n * projection.\r\n * @param ray ray onto which the instance is projected. A `Vector3d` is treated as a `Ray3d` with zero origin.\r\n * @param lowHigh optional receiver for output\r\n * @returns range of fractional projection parameters onto the ray, where 0.0 is start of the ray and 1.0 is the\r\n * end of the ray.\r\n */\r\n public override projectedParameterRange(ray: Vector3d | Ray3d, lowHigh?: Range1d): Range1d | undefined {\r\n return PlaneAltitudeRangeContext.findExtremeFractionsAlongDirection(this, ray, lowHigh);\r\n }\r\n}\r\n"]}
1
+ {"version":3,"file":"TransitionSpiral3d.js","sourceRoot":"","sources":["../../../../src/curve/spiral/TransitionSpiral3d.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;;;AAO/F,6CAA0C;AAE1C,kDAA0D;AAC1D,0DAAuD;AACvD,0DAAuD;AACvD,sDAAmD;AACnD,mFAAgF;AAChF,6FAA0F;AAE1F,oDAAiD;AAwCjD;;;;;;;;;;;;;;GAcG;AACH,2CAA2C;AAC3C,MAAsB,kBAAmB,SAAQ,+BAAc;IAC7D,kCAAkC;IACxB,WAAW,CAAS;IAC9B,oCAAoC;IAC1B,iBAAiB,CAA8C;IACzE,2BAA2B;IACjB,aAAa,CAAY;IACnC;;;OAGG;IACO,uBAAuB,CAAY;IAC7C,wEAAwE;IACxE,IAAW,sBAAsB;QAC/B,OAAO,IAAI,CAAC,uBAAuB,CAAC;IACtC,CAAC;IAGD,0CAA0C;IAC1C,IAAW,YAAY;QACrB,OAAO,IAAI,CAAC,aAAa,CAAC;IAC5B,CAAC;IACD,YACE,UAA8B,EAC9B,YAAuB,EACvB,sBAA6C,EAC7C,gBAA6D;QAE7D,KAAK,EAAE,CAAC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AiB,CAAC,uBAA+C;QAC/E,MAAM,OAAO,GAAG,6BAAa,CAAC,MAAM,CAAC,uBAAuB,CAAC,CAAC;QAC9D,MAAM,OAAO,GAAG,IAAI,2CAAoB,CAAC,IAAI,EAAE,OAAO,CAAC,kBAAkB,CAAC,CAAC;QAC3E,IAAI,CAAC,kBAAkB,CAAC,OAAO,EAAE,OAAO,CAAC,aAAa,CAAC,CAAC;QACxD,OAAO,OAAO,CAAC,WAAW,EAAE,CAAC;IAC/B,CAAC;IACD,qDAAqD;IACrC,WAAW,CAAC,aAAsB,EAAE,SAAqB;QACvE,aAAa,CAAC,WAAW,CAAC,IAAI,CAAC,qBAAqB,CAAC,GAAG,EAAE,GAAG,EAAE,SAAS,CAAC,CAAC,CAAC;IAC7E,CAAC;IACD;;;OAGG;IACa,qBAAqB,CAAC,SAAiB,EAAE,SAAiB,EAAE,SAAqB;QAC/F,MAAM,OAAO,GAAG,IAAI,CAAC,aAAa,CAAC;QACnC,IAAI,SAAS,KAAK,OAAO;YACvB,OAAO,eAAO,CAAC,UAAU,EAAE,CAAC;QAC9B,IAAI,KAAK,GAAG,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,SAAS,EAAE,GAAG,IAAI,CAAC,GAAG,CAAC,SAAS,GAAG,SAAS,CAAC,CAAC,CAAC;QAC7E,KAAK,GAAG,mBAAQ,CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,CAAC,CAAC;QACrC,OAAO,IAAI,CAAC,4BAA4B,CAAC,SAAS,EAAE,SAAS,EAAE,KAAK,EAAE,SAAS,EAAE,GAAG,CAAC,CAAC;IACxF,CAAC;IACD;;;;;;;OAOG;IACa,uBAAuB,CAAC,GAAqB,EAAE,OAAiB;QAC9E,OAAO,qDAAyB,CAAC,kCAAkC,CAAC,IAAI,EAAE,GAAG,EAAE,OAAO,CAAC,CAAC;IAC1F,CAAC;CACF;AA5KD,gDA4KC","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 Curve\r\n */\r\n\r\nimport { BSplineCurve3d } from \"../../bspline/BSplineCurve\";\r\nimport { Geometry } from \"../../Geometry\";\r\nimport { Matrix3d } from \"../../geometry3d/Matrix3d\";\r\nimport { Range1d, Range3d } from \"../../geometry3d/Range\";\r\nimport { Segment1d } from \"../../geometry3d/Segment1d\";\r\nimport { Transform } from \"../../geometry3d/Transform\";\r\nimport { CurvePrimitive } from \"../CurvePrimitive\";\r\nimport { CurveOffsetXYHandler } from \"../internalContexts/CurveOffsetXYHandler\";\r\nimport { PlaneAltitudeRangeContext } from \"../internalContexts/PlaneAltitudeRangeContext\";\r\nimport { LineString3d } from \"../LineString3d\";\r\nimport { OffsetOptions } from \"../OffsetOptions\";\r\nimport { TransitionConditionalProperties } from \"./TransitionConditionalProperties\";\r\n\r\nimport type { Vector3d } from \"../../geometry3d/Point3dVector3d\";\r\nimport type { Ray3d } from \"../../geometry3d/Ray3d\";\r\n/**\r\n * This is the set of valid type names for \"integrated\" spirals.\r\n * * Behavior is expressed by a `NormalizedTransition` snap function.\r\n * * The snap function varies smoothly from f(0) = 0 to f(1) = 1.\r\n * * The various snap functions are:\r\n * * clothoid: linear\r\n * * biquadratic: 2 quadratics pieced together, joining with 1st derivative continuity at f(0.5) = 0.5, with zero\r\n * slope f'(0) = 0 and f'(1) = 0\r\n * * bloss: A single cubic with zero slope at 0 and 1\r\n * * cosine: half of a cosine wave, centered around 0.5\r\n * * sine: full period of a sine wave added to the line f(u)=u\r\n * *\r\n * @public\r\n */\r\nexport type IntegratedSpiralTypeName = \"clothoid\" | \"bloss\" | \"biquadratic\" | \"cosine\" | \"sine\";\r\n\r\n/**\r\n * This is the set of valid type names for \"direct\" spirals.\r\n * \"Direct\" spirals can evaluate fractionToPoint by direct equations, i.e. not requiring the numeric integrations in\r\n * \"Integrated\" spiral types.\r\n * @public\r\n */\r\nexport type DirectSpiralTypeName =\r\n \"Arema\" // 2 terms from each of the X,Y clothoid series expansions; identical to ChineseCubic\r\n | \"JapaneseCubic\" // 1 term from each of the X,Y clothoid series expansions; y = x^3 / (6RL)\r\n | \"ChineseCubic\" // identical to Arema\r\n | \"WesternAustralian\" // simple cubic; 2 terms of x series, 1 term of y series\r\n | \"HalfCosine\" // high continuity cosine variation from quadratic\r\n | \"AustralianRailCorp\" // cubic with high accuracy distance series\r\n | \"Czech\" // simple cubic with two term distance approximation\r\n | \"Italian\" // similar to Czech\r\n | \"MXCubicAlongArc\" // x obtained from fractional distance via 2-terms from series, y = x^3 / (6RL)\r\n | \"Polish\" // similar to MXCubicAlongArc\r\n ;\r\n\r\n/**\r\n * TransitionSpiral3d is a base class for multiple variants of spirals.\r\n * * The menagerie of spiral types have 2 broad categories:\r\n * * IntegratedSpiral3d -- a spiral whose direct function for curvature versus distance must be integrated to\r\n * determine x,y.\r\n * * The IntegratedSpiral3d types are enumerated in `IntegratedSpiralTypes`.\r\n * * DirectSpiral3d -- a spiral implemented with direct calculation of x,y from fractional position along the spiral.\r\n * * The direct spiral types are enumerated in the `DirectSpiralType`.\r\n * * The method set for CurvePrimitive support includes a `handleTransitionSpiral(g: TransitionSpiral3d)` which receives\r\n * all the spiral types.\r\n * * The spiral class may impose expectations that its inflection is at the origin, with tangent along the x axis.\r\n * * This is generally necessary for direct spirals.\r\n * * This is not necessary for integrated spirals.\r\n * @public\r\n */\r\n// see internaldocs/Spiral.md for more info\r\nexport abstract class TransitionSpiral3d extends CurvePrimitive {\r\n /** String name of spiral type. */\r\n protected _spiralType: string;\r\n /** Original defining properties. */\r\n protected _designProperties: TransitionConditionalProperties | undefined;\r\n /** Placement transform. */\r\n protected _localToWorld: Transform;\r\n /**\r\n * Fractional interval for the \"active\" part of a containing spiral.\r\n * (the radius, angle, and length conditions define a complete spiral, and some portion of it is \"active\")\r\n */\r\n protected _activeFractionInterval: Segment1d;\r\n /** Return (reference to) the active portion of the reference spiral. */\r\n public get activeFractionInterval(): Segment1d {\r\n return this._activeFractionInterval;\r\n }\r\n /** Strokes in the active portion. */\r\n public abstract get activeStrokes(): LineString3d;\r\n /** (Reference to) placement transform. */\r\n public get localToWorld(): Transform {\r\n return this._localToWorld;\r\n }\r\n protected constructor(\r\n spiralType: string | undefined,\r\n localToWorld: Transform,\r\n activeFractionInterval: Segment1d | undefined,\r\n designProperties: TransitionConditionalProperties | undefined,\r\n ) {\r\n super();\r\n this._spiralType = spiralType ? spiralType : \"unknownSpiralType\";\r\n this._designProperties = designProperties;\r\n this._localToWorld = localToWorld;\r\n this._activeFractionInterval = activeFractionInterval ? activeFractionInterval : Segment1d.create(0, 1);\r\n }\r\n public get spiralType(): string {\r\n return this._spiralType;\r\n }\r\n /** Return 1/r with convention that exact zero input returns 0 (straight line, zero curvature, infinite radius). */\r\n public static radiusToCurvature(radius: number): number {\r\n return (radius === 0.0) ? 0.0 : 1.0 / radius;\r\n }\r\n /** Return 1/k with convention that near-zero input returns 0 (straight line, zero curvature, infinite radius). */\r\n public static curvatureToRadius(curvature: number): number {\r\n if (Math.abs(curvature) < Geometry.smallAngleRadians)\r\n return 0.0;\r\n return 1.0 / curvature;\r\n }\r\n /** Return a deep clone. */\r\n public abstract override clone(): TransitionSpiral3d;\r\n /** Recompute strokes. */\r\n public abstract refreshComputedProperties(): void;\r\n /** Return (if possible) a spiral which is a portion of this curve. */\r\n public override clonePartialCurve(fractionA: number, fractionB: number): TransitionSpiral3d {\r\n const spiralB = this.clone();\r\n const globalFractionA = this._activeFractionInterval.fractionToPoint(fractionA);\r\n const globalFractionB = this._activeFractionInterval.fractionToPoint(fractionB);\r\n spiralB._activeFractionInterval.set(globalFractionA, globalFractionB);\r\n spiralB.refreshComputedProperties();\r\n return spiralB;\r\n }\r\n /** Clone with a transform applied. */\r\n public override cloneTransformed(transform: Transform): TransitionSpiral3d {\r\n const result = this.clone();\r\n result.tryTransformInPlace(transform); // we're confident it will always work\r\n return result;\r\n }\r\n /** Return the average of the start and end curvatures. */\r\n public static averageCurvature(radiusLimits: Segment1d): number {\r\n return 0.5 * (TransitionSpiral3d.radiusToCurvature(radiusLimits.x0) + TransitionSpiral3d.radiusToCurvature(radiusLimits.x1));\r\n }\r\n /**\r\n * Given two radii (or zeros for 0 curvature) return the average curvature.\r\n * @param r0 start radius, or 0 for line.\r\n * @param r1 end radius, or 0 for line.\r\n */\r\n public static averageCurvatureR0R1(r0: number, r1: number): number {\r\n return 0.5 * (TransitionSpiral3d.radiusToCurvature(r0) + TransitionSpiral3d.radiusToCurvature(r1));\r\n }\r\n /**\r\n * Given two radii (or zeros for 0 curvature) return the curvature at the given fraction.\r\n * @param r0 start radius, or 0 for line.\r\n * @param fraction fractional position between the curvatures defined by r0 and r1.\r\n * @param r1 end radius, or 0 for line.\r\n */\r\n public static interpolateCurvatureR0R1(r0: number, fraction: number, r1: number): number {\r\n return Geometry.interpolate(TransitionSpiral3d.radiusToCurvature(r0), fraction, TransitionSpiral3d.radiusToCurvature(r1));\r\n }\r\n /** Return the arc length of a transition spiral with given sweep and radius pair. */\r\n public static radiusRadiusSweepRadiansToArcLength(radius0: number, radius1: number, sweepRadians: number): number {\r\n return Math.abs(sweepRadians / TransitionSpiral3d.averageCurvatureR0R1(radius0, radius1));\r\n }\r\n /** Return the turn angle for spiral of given length between two radii */\r\n public static radiusRadiusLengthToSweepRadians(radius0: number, radius1: number, arcLength: number): number {\r\n return TransitionSpiral3d.averageCurvatureR0R1(radius0, radius1) * arcLength;\r\n }\r\n /** Return the end radius for spiral of given start radius, length, and turn angle. */\r\n public static radius0LengthSweepRadiansToRadius1(radius0: number, arcLength: number, sweepRadians: number) {\r\n return TransitionSpiral3d.curvatureToRadius(\r\n (2.0 * sweepRadians / arcLength) - TransitionSpiral3d.radiusToCurvature(radius0),\r\n );\r\n }\r\n /** Return the start radius for spiral of given end radius, length, and turn angle. */\r\n public static radius1LengthSweepRadiansToRadius0(radius1: number, arcLength: number, sweepRadians: number) {\r\n return TransitionSpiral3d.curvatureToRadius(\r\n (2.0 * sweepRadians / arcLength) - TransitionSpiral3d.radiusToCurvature(radius1),\r\n );\r\n }\r\n /** Return the original defining properties (if any) saved by the constructor. */\r\n public get designProperties(): TransitionConditionalProperties | undefined {\r\n return this._designProperties;\r\n }\r\n /**\r\n * * If transformA is rigid with uniform scale, apply the rigid part of transformA to the localToWorld transform and\r\n * return the scale and rigid separation.\r\n * * If not rigid, do nothing and return undefined.\r\n * * Also apply the scale factor to the designProperties.\r\n * @param transformA\r\n */\r\n protected applyRigidPartOfTransform(transformA: Transform): { rigidAxes: Matrix3d, scale: number } | undefined {\r\n const rigidData = transformA.matrix.factorRigidWithSignedScale();\r\n if (rigidData !== undefined) {\r\n // [sQ a][R b] = [sQ*R sQb+a]\r\n // but we save it as [Q*R sQb+a] with spiral data scaled by s\r\n const transformC0 = transformA.multiplyTransformTransform(this.localToWorld);\r\n // but pull the scale part out of the matrix\r\n const matrixC = rigidData.rigidAxes.multiplyMatrixMatrix(this.localToWorld.matrix);\r\n this._localToWorld = Transform.createOriginAndMatrix(transformC0.origin, matrixC);\r\n if (this.designProperties)\r\n this.designProperties.applyScaleFactor(rigidData.scale);\r\n return rigidData;\r\n }\r\n return undefined;\r\n }\r\n /**\r\n * Construct an offset of the instance curve as viewed in the xy-plane (ignoring z).\r\n * * No attempt is made to join the offsets of smaller constituent primitives. To construct a fully joined offset for an\r\n * aggregate instance (e.g., LineString3d, CurveChainWithDistanceIndex), use RegionOps.constructCurveXYOffset() instead.\r\n * @param offsetDistanceOrOptions offset distance (positive to left of the instance curve), or options object.\r\n */\r\n public override constructOffsetXY(offsetDistanceOrOptions: number | OffsetOptions): BSplineCurve3d | undefined {\r\n const options = OffsetOptions.create(offsetDistanceOrOptions);\r\n const handler = new CurveOffsetXYHandler(this, options.leftOffsetDistance);\r\n this.emitStrokableParts(handler, options.strokeOptions);\r\n return handler.claimResult();\r\n }\r\n /** Extend the range by the strokes of the spiral. */\r\n public override extendRange(rangeToExtend: Range3d, transform?: Transform): void {\r\n rangeToExtend.extendRange(this.rangeBetweenFractions(0.0, 1.0, transform));\r\n }\r\n /**\r\n * Return the range of spiral between fractions of the activeStrokes.\r\n * * Use activeStrokes point count times interval factor for initial evaluation count, but do at least 5.\r\n */\r\n public override rangeBetweenFractions(fractionA: number, fractionB: number, transform?: Transform): Range3d {\r\n const strokes = this.activeStrokes;\r\n if (undefined === strokes)\r\n return Range3d.createNull();\r\n let count = Math.ceil(strokes.numPoints() * Math.abs(fractionB - fractionA));\r\n count = Geometry.clamp(5, count, 30);\r\n return this.rangeBetweenFractionsByCount(fractionA, fractionB, count, transform, 0.5);\r\n }\r\n /**\r\n * Project instance geometry (via dispatch) onto the given ray, and return the extreme fractional parameters of\r\n * projection.\r\n * @param ray ray onto which the instance is projected. A `Vector3d` is treated as a `Ray3d` with zero origin.\r\n * @param lowHigh optional receiver for output\r\n * @returns range of fractional projection parameters onto the ray, where 0.0 is start of the ray and 1.0 is the\r\n * end of the ray.\r\n */\r\n public override projectedParameterRange(ray: Vector3d | Ray3d, lowHigh?: Range1d): Range1d | undefined {\r\n return PlaneAltitudeRangeContext.findExtremeFractionsAlongDirection(this, ray, lowHigh);\r\n }\r\n}\r\n"]}
@@ -35,7 +35,8 @@ export declare class Ellipsoid implements Clipper {
35
35
  private _workPointA;
36
36
  private _workPointB;
37
37
  private constructor();
38
- /** Create with a clone (not capture) with given transform.
38
+ /**
39
+ * Create with a clone (not capture) with given transform.
39
40
  * * If transform is undefined, create a unit sphere.
40
41
  */
41
42
  static create(matrixOrTransform?: Transform | Matrix3d): Ellipsoid;
@@ -247,9 +248,9 @@ export declare class Ellipsoid implements Clipper {
247
248
  static radiansToUnitNormalRay(ellipsoid: Ellipsoid | undefined, thetaRadians: number, phiRadians: number, result?: Ray3d): Ray3d | undefined;
248
249
  /** Implementation of [[Clipper.isPointOnOrInside]]. */
249
250
  isPointOnOrInside(point: Point3d): boolean;
250
- /** Announce "in" portions of a line segment. Implementation of [[Clipper.announceClippedSegmentIntervals]]. */
251
+ /** Method from [[Clipper]] interface. */
251
252
  announceClippedSegmentIntervals(f0: number, f1: number, pointA: Point3d, pointB: Point3d, announce?: AnnounceNumberNumber): boolean;
252
- /** Announce "in" portions of a line segment. Implementation of [[Clipper.announceClippedArcIntervals]] */
253
+ /** Method from [[Clipper]] interface. */
253
254
  announceClippedArcIntervals(arc: Arc3d, announce?: AnnounceNumberNumberCurvePrimitive): boolean;
254
255
  }
255
256
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"Ellipsoid.d.ts","sourceRoot":"","sources":["../../../src/geometry3d/Ellipsoid.ts"],"names":[],"mappings":"AAKA;;GAEG;AAEH,OAAO,EAAE,6BAA6B,EAA2B,MAAM,kCAAkC,CAAC;AAC1G,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAChD,OAAO,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAEvC,OAAO,EAAE,oBAAoB,EAAE,kCAAkC,EAAE,MAAM,yBAAyB,CAAC;AAEnG,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAKhD,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,EAAE,uBAAuB,EAAE,MAAM,6BAA6B,CAAC;AACtE,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,4BAA4B,EAAE,MAAM,gCAAgC,CAAC;AAC9E,OAAO,EAAE,yBAAyB,EAAE,MAAM,6BAA6B,CAAC;AACxE,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AACtD,OAAO,EAAW,OAAO,EAAE,MAAM,SAAS,CAAC;AAC3C,OAAO,EAAE,KAAK,EAAE,MAAM,SAA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AE,GAAG,SAAS;IAsDrI,OAAO,CAAC,uCAAuC;IAc/C,OAAO,CAAC,WAAW;IAUnB;;;;OAIG;IACH,OAAO,CAAC,SAAS;IAqBjB,OAAO,CAAC,KAAK;IAGb;;;;;;;;;;OAUG;WACW,kCAAkC,CAAC,SAAS,EAAE,SAAS,EACnE,MAAM,EAAE,uBAAuB,EAC/B,MAAM,EAAE,uBAAuB,EAAE,SAAS,EAAE,MAAM,EAClD,4BAA4B,EAAE,MAAM,EACpC,4BAA4B,EAAE,MAAM,GAAG;QAAE,YAAY,EAAE,KAAK,CAAC;QAAC,oCAAoC,EAAE,MAAM,CAAA;KAAE,GAAG,SAAS;CA6B3H"}
@@ -153,7 +153,8 @@ class Ellipsoid {
153
153
  this._workPointA = Point3dVector3d_1.Point3d.create();
154
154
  this._workPointB = Point3dVector3d_1.Point3d.create();
155
155
  }
156
- /** Create with a clone (not capture) with given transform.
156
+ /**
157
+ * Create with a clone (not capture) with given transform.
157
158
  * * If transform is undefined, create a unit sphere.
158
159
  */
159
160
  static create(matrixOrTransform) {
@@ -187,7 +188,9 @@ class Ellipsoid {
187
188
  * * In the sphere space, an xyz (vector from origin) with magnitude less than 1 is INSIDE the sphere (hence its world image is INSIDE the ellipsoid)
188
189
  * * In the sphere space, an xyz (vector from origin) with magnitude greater than 1 is OUTSIDE the sphere (hence its world image is OUTSIDE the ellipsoid)
189
190
  */
190
- get transformRef() { return this._transform; }
191
+ get transformRef() {
192
+ return this._transform;
193
+ }
191
194
  /**
192
195
  * * Convert a world point to point within the underlying mapped sphere space.
193
196
  * * In the sphere space, an xyz (vector from origin) with magnitude equal to 1 is ON the sphere (hence its world image is ON the ellipsoid)
@@ -652,7 +655,7 @@ class Ellipsoid {
652
655
  return localPoint.magnitude() <= 1.0;
653
656
  return false;
654
657
  }
655
- /** Announce "in" portions of a line segment. Implementation of [[Clipper.announceClippedSegmentIntervals]]. */
658
+ /** Method from [[Clipper]] interface. */
656
659
  announceClippedSegmentIntervals(f0, f1, pointA, pointB, announce) {
657
660
  const localA = this._transform.multiplyInversePoint3d(pointA, this._workPointA);
658
661
  const localB = this._transform.multiplyInversePoint3d(pointB, this._workPointB);
@@ -691,7 +694,7 @@ class Ellipsoid {
691
694
  }
692
695
  return false;
693
696
  }
694
- /** Announce "in" portions of a line segment. Implementation of [[Clipper.announceClippedArcIntervals]] */
697
+ /** Method from [[Clipper]] interface. */
695
698
  announceClippedArcIntervals(arc, announce) {
696
699
  const arcData = arc.toVectors();
697
700
  let numAnnounce = 0;