opencad2d 1.0.0__py3-none-win_amd64.whl
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.
- GeometryHelper-stubs/Arranging/__init__.pyi +202 -0
- GeometryHelper-stubs/Clash/__init__.pyi +289 -0
- GeometryHelper-stubs/Core/__init__.pyi +12848 -0
- GeometryHelper-stubs/Dwg/__init__.pyi +57 -0
- GeometryHelper-stubs/Dxf/__init__.pyi +18468 -0
- GeometryHelper-stubs/Enums/__init__.pyi +259 -0
- GeometryHelper-stubs/Export/__init__.pyi +390 -0
- GeometryHelper-stubs/Extension/__init__.pyi +210 -0
- GeometryHelper-stubs/Geometry/__init__.pyi +25141 -0
- GeometryHelper-stubs/Meshing/__init__.pyi +754 -0
- GeometryHelper-stubs/Packing/__init__.pyi +343 -0
- GeometryHelper-stubs/Spatial/__init__.pyi +315 -0
- GeometryHelper-stubs/Takeoff/__init__.pyi +107 -0
- GeometryHelper-stubs/__init__.pyi +587 -0
- OpenCAD2D-stubs/Lisp/__init__.pyi +227 -0
- OpenCAD2D-stubs/Plugins/__init__.pyi +921 -0
- OpenCAD2D-stubs/Remote/__init__.pyi +346 -0
- OpenCAD2D-stubs/__init__.pyi +16299 -0
- System-stubs/Collections/Generic/__init__.pyi +85 -0
- System-stubs/Collections/__init__.pyi +13 -0
- System-stubs/IO/__init__.pyi +22 -0
- System-stubs/Reflection/__init__.pyi +8 -0
- System-stubs/Runtime/Serialization/__init__.pyi +4 -0
- System-stubs/Runtime/__init__.pyi +0 -0
- System-stubs/Threading/__init__.pyi +8 -0
- System-stubs/__init__.pyi +156 -0
- opencad2d/__init__.py +134 -0
- opencad2d/_app.py +326 -0
- opencad2d/arrays.py +127 -0
- opencad2d/cad/__init__.py +484 -0
- opencad2d/cad/_drawing.py +947 -0
- opencad2d/cad/_local.py +607 -0
- opencad2d/cad/_remote.py +297 -0
- opencad2d/cad/_ui.py +482 -0
- opencad2d/lib/Fonts/README.txt +36 -0
- opencad2d/lib/Fonts/ghsimplex.shx +0 -0
- opencad2d/lib/GeometryHelper.dll +0 -0
- opencad2d/lib/Hatches/GeometryHelper.pat +180 -0
- opencad2d/lib/Hatches/README.txt +25 -0
- opencad2d/lib/Linetypes/GeometryHelper.lin +81 -0
- opencad2d/lib/Linetypes/README.txt +32 -0
- opencad2d/lib/OpenCAD2D.Core.dll +0 -0
- opencad2d/lib/OpenCAD2D.Remote.dll +0 -0
- opencad2d/opencad2d.runtimeconfig.json +10 -0
- opencad2d/py.typed +0 -0
- opencad2d-1.0.0.dist-info/METADATA +61 -0
- opencad2d-1.0.0.dist-info/RECORD +49 -0
- opencad2d-1.0.0.dist-info/WHEEL +4 -0
- opencad2d-1.0.0.dist-info/licenses/LICENSE +21 -0
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
# Generated by tools/OpenCAD2D.PyStubs from GeometryHelper 13.12.1. Do not edit.
|
|
2
|
+
# pyright: reportOverlappingOverload=false, reportInconsistentOverload=false, reportIncompatibleMethodOverride=false, reportIncompatibleVariableOverride=false
|
|
3
|
+
import System
|
|
4
|
+
import System.Collections.Generic
|
|
5
|
+
from typing import ClassVar, overload
|
|
6
|
+
from GeometryHelper import Tolerance
|
|
7
|
+
from GeometryHelper.Geometry import GeoLine2
|
|
8
|
+
from GeometryHelper.Geometry import GeoPoint2
|
|
9
|
+
from GeometryHelper.Geometry import GeoPolygon2
|
|
10
|
+
from GeometryHelper.Geometry import GeoRectangle2
|
|
11
|
+
from GeometryHelper.Geometry import GeoVector2
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class ArrangeItem(System.Object):
|
|
15
|
+
"""A label to place: the box it takes up, the leader it belongs to, and what it has to keep clear of."""
|
|
16
|
+
def __init__(self) -> None: ...
|
|
17
|
+
@property
|
|
18
|
+
def BlockLines(self) -> System.Collections.Generic.IReadOnlyList[GeoLine2]:
|
|
19
|
+
"""Gets or sets the segments the label must not overlap; empty unless set, and null reads as empty."""
|
|
20
|
+
@BlockLines.setter
|
|
21
|
+
def BlockLines(self, value: System.Collections.Generic.IReadOnlyList[GeoLine2] | None) -> None: ...
|
|
22
|
+
@property
|
|
23
|
+
def BlockPolygons(self) -> System.Collections.Generic.IReadOnlyList[GeoPolygon2]:
|
|
24
|
+
"""Gets or sets the regions the label must not overlap; empty unless set, and null reads as empty."""
|
|
25
|
+
@BlockPolygons.setter
|
|
26
|
+
def BlockPolygons(self, value: System.Collections.Generic.IReadOnlyList[GeoPolygon2] | None) -> None: ...
|
|
27
|
+
@property
|
|
28
|
+
def Box(self) -> GeoRectangle2:
|
|
29
|
+
"""Gets or sets the box of the label: the rectangle that is moved."""
|
|
30
|
+
@Box.setter
|
|
31
|
+
def Box(self, value: GeoRectangle2) -> None: ...
|
|
32
|
+
@property
|
|
33
|
+
def Leader(self) -> GeoLine2:
|
|
34
|
+
"""Gets or sets the leader: the segment of the object the label belongs to. The candidate positions spread
|
|
35
|
+
out from its midpoint, in rows on either side of it, each sliding along it."""
|
|
36
|
+
@Leader.setter
|
|
37
|
+
def Leader(self, value: GeoLine2) -> None: ...
|
|
38
|
+
Offset: float
|
|
39
|
+
"""Sets the least gap between the edge of the label and the leader on both sides of it at once:
|
|
40
|
+
ArrangeItem.OffsetTop and ArrangeItem.OffsetBottom both take the value. It only sets, and holds nothing of
|
|
41
|
+
its own, so it cannot be read; the sides are what placement reads.
|
|
42
|
+
|
|
43
|
+
The gaps belong to the label rather than to ArrangeOptions because labels differ: a large text may have to
|
|
44
|
+
stand further off than a small one."""
|
|
45
|
+
@property
|
|
46
|
+
def OffsetBottom(self) -> float:
|
|
47
|
+
"""Gets or sets the least gap between the edge of the label and the leader on the side of the leader that
|
|
48
|
+
faces down in the drawing, towards smaller Y, and for a vertical leader the right; 50 unless set, here or
|
|
49
|
+
through ArrangeItem.Offset."""
|
|
50
|
+
@OffsetBottom.setter
|
|
51
|
+
def OffsetBottom(self, value: float) -> None: ...
|
|
52
|
+
@property
|
|
53
|
+
def OffsetTop(self) -> float:
|
|
54
|
+
"""Gets or sets the least gap between the edge of the label and the leader on the side of the leader that
|
|
55
|
+
faces up in the drawing, towards greater Y; 50 unless set, here or through ArrangeItem.Offset. The first
|
|
56
|
+
row of candidates on that side lies half the height of the label plus this from the leader."""
|
|
57
|
+
@OffsetTop.setter
|
|
58
|
+
def OffsetTop(self, value: float) -> None: ...
|
|
59
|
+
@property
|
|
60
|
+
def Rectangle(self) -> GeoRectangle2 | None:
|
|
61
|
+
"""Gets or sets the rectangle of the object the label belongs to, to stand along its long side; null, and so
|
|
62
|
+
the ArrangeItem.Leader is used, unless set."""
|
|
63
|
+
@Rectangle.setter
|
|
64
|
+
def Rectangle(self, value: GeoRectangle2 | None) -> None: ...
|
|
65
|
+
@property
|
|
66
|
+
def Side(self) -> ArrangeSide:
|
|
67
|
+
"""Gets or sets which side of the leader the label may stand on; ArrangeSide.Both unless set."""
|
|
68
|
+
@Side.setter
|
|
69
|
+
def Side(self, value: ArrangeSide) -> None: ...
|
|
70
|
+
@overload
|
|
71
|
+
def GetPlacePoints(self) -> System.Collections.Generic.List[GeoPoint2]:
|
|
72
|
+
"""Gets the positions the centre of the label is tried at, with the default options."""
|
|
73
|
+
@overload
|
|
74
|
+
def GetPlacePoints(self, options: ArrangeOptions) -> System.Collections.Generic.List[GeoPoint2]:
|
|
75
|
+
"""Gets the positions the centre of the label is tried at: rows on either side of the leader, or on the one
|
|
76
|
+
side ArrangeItem.Side keeps the label to, each sliding along it. A run chooses among these."""
|
|
77
|
+
|
|
78
|
+
class ArrangeOptions(System.Object):
|
|
79
|
+
"""Parameters controlling candidate position generation and collision checking for label arrangement. Values are
|
|
80
|
+
typically in millimeters, suitable for standard structural drawings."""
|
|
81
|
+
def __init__(self) -> None: ...
|
|
82
|
+
Default: ClassVar[ArrangeOptions]
|
|
83
|
+
"""Gets the default options, a new instance each time it is read, as Arranger.Run runs with them."""
|
|
84
|
+
@property
|
|
85
|
+
def FreedomSampleSize(self) -> int:
|
|
86
|
+
"""Number of candidates evaluated when measuring label freedom degree, serving the
|
|
87
|
+
ArrangeOptions.PlaceMostConstrainedFirst option."""
|
|
88
|
+
@FreedomSampleSize.setter
|
|
89
|
+
def FreedomSampleSize(self, value: int) -> None: ...
|
|
90
|
+
@property
|
|
91
|
+
def LongitudinalOvershootRatio(self) -> float:
|
|
92
|
+
"""Ratio of label width added to half of the path segment length to determine longitudinal sliding limits.
|
|
93
|
+
Allows the label to overshoot the segment ends slightly."""
|
|
94
|
+
@LongitudinalOvershootRatio.setter
|
|
95
|
+
def LongitudinalOvershootRatio(self, value: float) -> None: ...
|
|
96
|
+
@property
|
|
97
|
+
def LookAheadCandidates(self) -> int:
|
|
98
|
+
"""Number of empty positions evaluated before selection. Among these candidates, the position with the
|
|
99
|
+
maximum clearance wins. Set to 1 to select the first found empty position immediately."""
|
|
100
|
+
@LookAheadCandidates.setter
|
|
101
|
+
def LookAheadCandidates(self, value: int) -> None: ...
|
|
102
|
+
@property
|
|
103
|
+
def MaximumCandidates(self) -> int:
|
|
104
|
+
"""Maximum number of candidate positions generated for a label to prevent infinite loops."""
|
|
105
|
+
@MaximumCandidates.setter
|
|
106
|
+
def MaximumCandidates(self, value: int) -> None: ...
|
|
107
|
+
@property
|
|
108
|
+
def MinimumBoxSize(self) -> float:
|
|
109
|
+
"""Labels smaller than this size will be considered invalid/erroneous and ignored."""
|
|
110
|
+
@MinimumBoxSize.setter
|
|
111
|
+
def MinimumBoxSize(self, value: float) -> None: ...
|
|
112
|
+
@property
|
|
113
|
+
def MinimumMoveDistance(self) -> float:
|
|
114
|
+
"""Shifts smaller than this distance will be ignored. Avoids minor adjustments for labels that are already
|
|
115
|
+
in the correct position."""
|
|
116
|
+
@MinimumMoveDistance.setter
|
|
117
|
+
def MinimumMoveDistance(self, value: float) -> None: ...
|
|
118
|
+
@property
|
|
119
|
+
def NeighbourMargin(self) -> float:
|
|
120
|
+
"""Margin to expand the neighbor bounding box when selecting obstacles for collision checks. Added to the
|
|
121
|
+
maximum dimension of the label."""
|
|
122
|
+
@NeighbourMargin.setter
|
|
123
|
+
def NeighbourMargin(self, value: float) -> None: ...
|
|
124
|
+
@property
|
|
125
|
+
def PerpendicularLevels(self) -> int:
|
|
126
|
+
"""Number of perpendicular fallback levels to test on each side of the path."""
|
|
127
|
+
@PerpendicularLevels.setter
|
|
128
|
+
def PerpendicularLevels(self, value: int) -> None: ...
|
|
129
|
+
@property
|
|
130
|
+
def PlaceFromInsideOut(self) -> bool:
|
|
131
|
+
"""Sorts labels from the inside out (from area centroid to boundary). Helps labels in crowded center regions
|
|
132
|
+
get priority placement."""
|
|
133
|
+
@PlaceFromInsideOut.setter
|
|
134
|
+
def PlaceFromInsideOut(self, value: bool) -> None: ...
|
|
135
|
+
@property
|
|
136
|
+
def PlaceMostConstrainedFirst(self) -> bool:
|
|
137
|
+
"""Sorts placement order so that the most constrained label (fewest options) is placed first. Recommended as
|
|
138
|
+
the greedy algorithm has no backtracking mechanism. Set to false to sort purely by default geometric
|
|
139
|
+
order."""
|
|
140
|
+
@PlaceMostConstrainedFirst.setter
|
|
141
|
+
def PlaceMostConstrainedFirst(self, value: bool) -> None: ...
|
|
142
|
+
@property
|
|
143
|
+
def RowGap(self) -> float:
|
|
144
|
+
"""The gap between two consecutive label rows, added to the label height when shifting to the next
|
|
145
|
+
perpendicular level. Helps prevent rows from overlapping."""
|
|
146
|
+
@RowGap.setter
|
|
147
|
+
def RowGap(self, value: float) -> None: ...
|
|
148
|
+
@property
|
|
149
|
+
def Tolerance(self) -> Tolerance:
|
|
150
|
+
"""Tolerance used for geometric calculations and intersection checks: Tolerance.Global as it stands when the
|
|
151
|
+
options are made, unless set."""
|
|
152
|
+
@Tolerance.setter
|
|
153
|
+
def Tolerance(self, value: Tolerance) -> None: ...
|
|
154
|
+
|
|
155
|
+
class ArrangeResult(System.ValueType):
|
|
156
|
+
"""What became of one label: how far it moves, and whether where it ends up is clear."""
|
|
157
|
+
def __init__(self, translation: GeoVector2, placed: bool) -> None:
|
|
158
|
+
"""Initializes a new instance of the ArrangeResult struct."""
|
|
159
|
+
@property
|
|
160
|
+
def Placed(self) -> bool:
|
|
161
|
+
"""Gets whether the label, moved, overlaps nothing: no other label, and nothing any label keeps clear of."""
|
|
162
|
+
@property
|
|
163
|
+
def Translation(self) -> GeoVector2:
|
|
164
|
+
"""Gets how far the label moves: translate its box by this. Zero when it stays where it is."""
|
|
165
|
+
@overload
|
|
166
|
+
def Equals(self, other: ArrangeResult) -> bool:
|
|
167
|
+
"""Indicates whether this result is the same as another: the same translation, exactly, and the same
|
|
168
|
+
verdict."""
|
|
169
|
+
@overload
|
|
170
|
+
def Equals(self, obj: object) -> bool: ...
|
|
171
|
+
def GetHashCode(self) -> int: ...
|
|
172
|
+
def ToString(self) -> str: ...
|
|
173
|
+
def __eq__(self, other: object) -> bool:
|
|
174
|
+
"""Compares two results for equality."""
|
|
175
|
+
def __hash__(self) -> int: ...
|
|
176
|
+
def __ne__(self, other: object) -> bool:
|
|
177
|
+
"""Compares two results for inequality."""
|
|
178
|
+
|
|
179
|
+
class ArrangeSide(System.Enum):
|
|
180
|
+
"""Which side of its leader a label may stand on."""
|
|
181
|
+
Both: ClassVar[ArrangeSide]
|
|
182
|
+
"""Either side: the rows of both are tried, the nearest first. The default."""
|
|
183
|
+
Bottom: ClassVar[ArrangeSide]
|
|
184
|
+
"""The side of the leader that faces down in the drawing, towards smaller Y; the right of a vertical leader."""
|
|
185
|
+
Top: ClassVar[ArrangeSide]
|
|
186
|
+
"""The side of the leader that faces up in the drawing, towards greater Y; the left of a vertical leader."""
|
|
187
|
+
def __init__(self, value: int) -> None: ...
|
|
188
|
+
def __int__(self) -> int: ...
|
|
189
|
+
|
|
190
|
+
class Arranger(System.Object):
|
|
191
|
+
"""Places labels so that they overlap neither one another nor what they have to keep clear of."""
|
|
192
|
+
@overload
|
|
193
|
+
@staticmethod
|
|
194
|
+
def Run(items: System.Collections.Generic.IReadOnlyList[ArrangeItem]) -> System.Array[ArrangeResult]:
|
|
195
|
+
"""Places the labels with the default options."""
|
|
196
|
+
@overload
|
|
197
|
+
@staticmethod
|
|
198
|
+
def Run(
|
|
199
|
+
items: System.Collections.Generic.IReadOnlyList[ArrangeItem],
|
|
200
|
+
options: ArrangeOptions,
|
|
201
|
+
) -> System.Array[ArrangeResult]:
|
|
202
|
+
"""Places the labels."""
|
|
@@ -0,0 +1,289 @@
|
|
|
1
|
+
# Generated by tools/OpenCAD2D.PyStubs from GeometryHelper 13.12.1. Do not edit.
|
|
2
|
+
# pyright: reportOverlappingOverload=false, reportInconsistentOverload=false, reportIncompatibleMethodOverride=false, reportIncompatibleVariableOverride=false
|
|
3
|
+
import System
|
|
4
|
+
import System.Collections.Generic
|
|
5
|
+
from typing import ClassVar, overload
|
|
6
|
+
from GeometryHelper import Tolerance
|
|
7
|
+
from GeometryHelper.Geometry import GeoFace3
|
|
8
|
+
from GeometryHelper.Geometry import GeoLine3
|
|
9
|
+
from GeometryHelper.Geometry import GeoPoint3
|
|
10
|
+
from GeometryHelper.Geometry import GeoPolyline3
|
|
11
|
+
from GeometryHelper.Geometry import GeoPolylineArc3
|
|
12
|
+
from GeometryHelper.Geometry import GeoSolid3
|
|
13
|
+
from GeometryHelper.Spatial import GeoPreparedSolid3
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
class Clash3(System.Object):
|
|
17
|
+
"""Checking many parts against each other at once: which run into each other, which touch, and which come nearer
|
|
18
|
+
than a clearance."""
|
|
19
|
+
@overload
|
|
20
|
+
@staticmethod
|
|
21
|
+
def Find(parts: System.Collections.Generic.IReadOnlyList[GeoSolid3]) -> System.Array[ClashResult]:
|
|
22
|
+
"""Checks every part of a set against every other, using the default options and tolerance."""
|
|
23
|
+
@overload
|
|
24
|
+
@staticmethod
|
|
25
|
+
def Find(parts: System.Collections.Generic.IReadOnlyList[GeoPreparedSolid3]) -> System.Array[ClashResult]:
|
|
26
|
+
"""Checks every prepared part of a set against every other, using the default options and tolerance."""
|
|
27
|
+
@overload
|
|
28
|
+
@staticmethod
|
|
29
|
+
def Find(
|
|
30
|
+
bars: System.Collections.Generic.IReadOnlyList[ClashBar],
|
|
31
|
+
parts: System.Collections.Generic.IReadOnlyList[GeoSolid3],
|
|
32
|
+
) -> System.Array[ClashResult]:
|
|
33
|
+
"""Checks every bar against every part, reading the bars by their centre lines, using the default options
|
|
34
|
+
and tolerance."""
|
|
35
|
+
@overload
|
|
36
|
+
@staticmethod
|
|
37
|
+
def Find(
|
|
38
|
+
bars: System.Collections.Generic.IReadOnlyList[ClashBar],
|
|
39
|
+
parts: System.Collections.Generic.IReadOnlyList[GeoPreparedSolid3],
|
|
40
|
+
) -> System.Array[ClashResult]:
|
|
41
|
+
"""Checks every bar against every prepared part, reading the bars by their centre lines, using the default
|
|
42
|
+
options and tolerance."""
|
|
43
|
+
@overload
|
|
44
|
+
@staticmethod
|
|
45
|
+
def Find(
|
|
46
|
+
parts: System.Collections.Generic.IReadOnlyList[GeoSolid3],
|
|
47
|
+
options: ClashOptions,
|
|
48
|
+
) -> System.Array[ClashResult]:
|
|
49
|
+
"""Checks every part of a set against every other, using the default tolerance."""
|
|
50
|
+
@overload
|
|
51
|
+
@staticmethod
|
|
52
|
+
def Find(
|
|
53
|
+
first: System.Collections.Generic.IReadOnlyList[GeoSolid3],
|
|
54
|
+
second: System.Collections.Generic.IReadOnlyList[GeoSolid3],
|
|
55
|
+
) -> System.Array[ClashResult]:
|
|
56
|
+
"""Checks every part of one set against every part of another, using the default options and tolerance."""
|
|
57
|
+
@overload
|
|
58
|
+
@staticmethod
|
|
59
|
+
def Find(
|
|
60
|
+
parts: System.Collections.Generic.IReadOnlyList[GeoPreparedSolid3],
|
|
61
|
+
options: ClashOptions,
|
|
62
|
+
) -> System.Array[ClashResult]:
|
|
63
|
+
"""Checks every prepared part of a set against every other, using the default tolerance."""
|
|
64
|
+
@overload
|
|
65
|
+
@staticmethod
|
|
66
|
+
def Find(
|
|
67
|
+
first: System.Collections.Generic.IReadOnlyList[GeoPreparedSolid3],
|
|
68
|
+
second: System.Collections.Generic.IReadOnlyList[GeoPreparedSolid3],
|
|
69
|
+
) -> System.Array[ClashResult]:
|
|
70
|
+
"""Checks every prepared part of one set against every prepared part of another, using the default options
|
|
71
|
+
and tolerance."""
|
|
72
|
+
@overload
|
|
73
|
+
@staticmethod
|
|
74
|
+
def Find(
|
|
75
|
+
bars: System.Collections.Generic.IReadOnlyList[ClashBar],
|
|
76
|
+
parts: System.Collections.Generic.IReadOnlyList[GeoSolid3],
|
|
77
|
+
options: ClashOptions,
|
|
78
|
+
) -> System.Array[ClashResult]:
|
|
79
|
+
"""Checks every bar against every part, reading the bars by their centre lines, using the default
|
|
80
|
+
tolerance."""
|
|
81
|
+
@overload
|
|
82
|
+
@staticmethod
|
|
83
|
+
def Find(
|
|
84
|
+
bars: System.Collections.Generic.IReadOnlyList[ClashBar],
|
|
85
|
+
parts: System.Collections.Generic.IReadOnlyList[GeoPreparedSolid3],
|
|
86
|
+
options: ClashOptions,
|
|
87
|
+
) -> System.Array[ClashResult]:
|
|
88
|
+
"""Checks every bar against every prepared part, reading the bars by their centre lines, using the default
|
|
89
|
+
tolerance."""
|
|
90
|
+
@overload
|
|
91
|
+
@staticmethod
|
|
92
|
+
def Find(
|
|
93
|
+
parts: System.Collections.Generic.IReadOnlyList[GeoSolid3],
|
|
94
|
+
options: ClashOptions,
|
|
95
|
+
tolerance: Tolerance,
|
|
96
|
+
) -> System.Array[ClashResult]:
|
|
97
|
+
"""Checks every part of a set against every other, within a tolerance."""
|
|
98
|
+
@overload
|
|
99
|
+
@staticmethod
|
|
100
|
+
def Find(
|
|
101
|
+
first: System.Collections.Generic.IReadOnlyList[GeoSolid3],
|
|
102
|
+
second: System.Collections.Generic.IReadOnlyList[GeoSolid3],
|
|
103
|
+
options: ClashOptions,
|
|
104
|
+
) -> System.Array[ClashResult]:
|
|
105
|
+
"""Checks every part of one set against every part of another, using the default tolerance."""
|
|
106
|
+
@overload
|
|
107
|
+
@staticmethod
|
|
108
|
+
def Find(
|
|
109
|
+
parts: System.Collections.Generic.IReadOnlyList[GeoPreparedSolid3],
|
|
110
|
+
options: ClashOptions,
|
|
111
|
+
tolerance: Tolerance,
|
|
112
|
+
) -> System.Array[ClashResult]:
|
|
113
|
+
"""Checks every prepared part of a set against every other, within a tolerance."""
|
|
114
|
+
@overload
|
|
115
|
+
@staticmethod
|
|
116
|
+
def Find(
|
|
117
|
+
first: System.Collections.Generic.IReadOnlyList[GeoPreparedSolid3],
|
|
118
|
+
second: System.Collections.Generic.IReadOnlyList[GeoPreparedSolid3],
|
|
119
|
+
options: ClashOptions,
|
|
120
|
+
) -> System.Array[ClashResult]:
|
|
121
|
+
"""Checks every prepared part of one set against every prepared part of another, using the default
|
|
122
|
+
tolerance."""
|
|
123
|
+
@overload
|
|
124
|
+
@staticmethod
|
|
125
|
+
def Find(
|
|
126
|
+
bars: System.Collections.Generic.IReadOnlyList[ClashBar],
|
|
127
|
+
parts: System.Collections.Generic.IReadOnlyList[GeoSolid3],
|
|
128
|
+
options: ClashOptions,
|
|
129
|
+
tolerance: Tolerance,
|
|
130
|
+
) -> System.Array[ClashResult]:
|
|
131
|
+
"""Checks every bar against every part, reading the bars by their centre lines, within a tolerance."""
|
|
132
|
+
@overload
|
|
133
|
+
@staticmethod
|
|
134
|
+
def Find(
|
|
135
|
+
bars: System.Collections.Generic.IReadOnlyList[ClashBar],
|
|
136
|
+
parts: System.Collections.Generic.IReadOnlyList[GeoPreparedSolid3],
|
|
137
|
+
options: ClashOptions,
|
|
138
|
+
tolerance: Tolerance,
|
|
139
|
+
) -> System.Array[ClashResult]:
|
|
140
|
+
"""Checks every bar against every prepared part, reading the bars by their centre lines, within a
|
|
141
|
+
tolerance."""
|
|
142
|
+
@overload
|
|
143
|
+
@staticmethod
|
|
144
|
+
def Find(
|
|
145
|
+
first: System.Collections.Generic.IReadOnlyList[GeoSolid3],
|
|
146
|
+
second: System.Collections.Generic.IReadOnlyList[GeoSolid3],
|
|
147
|
+
options: ClashOptions,
|
|
148
|
+
tolerance: Tolerance,
|
|
149
|
+
) -> System.Array[ClashResult]:
|
|
150
|
+
"""Checks every part of one set against every part of another, within a tolerance."""
|
|
151
|
+
@overload
|
|
152
|
+
@staticmethod
|
|
153
|
+
def Find(
|
|
154
|
+
first: System.Collections.Generic.IReadOnlyList[GeoPreparedSolid3],
|
|
155
|
+
second: System.Collections.Generic.IReadOnlyList[GeoPreparedSolid3],
|
|
156
|
+
options: ClashOptions,
|
|
157
|
+
tolerance: Tolerance,
|
|
158
|
+
) -> System.Array[ClashResult]:
|
|
159
|
+
"""Checks every prepared part of one set against every prepared part of another, within a tolerance."""
|
|
160
|
+
|
|
161
|
+
class ClashBar(System.Object):
|
|
162
|
+
"""A round bar to check for clashes by its centre line and its radius, without building its body."""
|
|
163
|
+
@overload
|
|
164
|
+
def __init__(self, centreLine: GeoPolyline3, radius: float) -> None:
|
|
165
|
+
"""Initializes a straight-run bar from its centre line and its radius."""
|
|
166
|
+
@overload
|
|
167
|
+
def __init__(self, centreLine: GeoPolylineArc3, radius: float) -> None:
|
|
168
|
+
"""Initializes a bar from its centre line and its radius, its bends followed to a thousandth of the
|
|
169
|
+
radius."""
|
|
170
|
+
@overload
|
|
171
|
+
def __init__(self, centreLine: GeoPolylineArc3, radius: float, chordTolerance: float) -> None:
|
|
172
|
+
"""Initializes a bar from its centre line and its radius, its bends followed to a chord tolerance."""
|
|
173
|
+
@property
|
|
174
|
+
def CentreLine(self) -> GeoPolylineArc3:
|
|
175
|
+
"""Gets the centre line, with its bends as arcs."""
|
|
176
|
+
@property
|
|
177
|
+
def ChordTolerance(self) -> float:
|
|
178
|
+
"""Gets how far the straight pieces the bends are followed by may stray from them."""
|
|
179
|
+
@property
|
|
180
|
+
def Radius(self) -> float:
|
|
181
|
+
"""Gets the radius of the bar itself."""
|
|
182
|
+
|
|
183
|
+
class ClashKind(System.Enum):
|
|
184
|
+
"""What two parts found by a clash check do to each other."""
|
|
185
|
+
Clearance: ClassVar[ClashKind]
|
|
186
|
+
"""The two stay apart, but by less than the clearance asked for."""
|
|
187
|
+
Hard: ClassVar[ClashKind]
|
|
188
|
+
"""The two share volume: one runs into the other."""
|
|
189
|
+
Touch: ClassVar[ClashKind]
|
|
190
|
+
"""The two touch without sharing volume: face to face, along an edge or at a corner."""
|
|
191
|
+
Unresolved: ClassVar[ClashKind]
|
|
192
|
+
"""Checking the pair failed, so nothing is known of it; the result carries the error."""
|
|
193
|
+
def __init__(self, value: int) -> None: ...
|
|
194
|
+
def __int__(self) -> int: ...
|
|
195
|
+
|
|
196
|
+
class ClashOptions(System.Object):
|
|
197
|
+
"""What a clash check between many parts looks for, and how many threads it may use."""
|
|
198
|
+
@overload
|
|
199
|
+
def __init__(self, clearance: float, includeTouching: bool, maxDegreeOfParallelism: int) -> None:
|
|
200
|
+
"""Initializes the options with no minimum depth or volume: every overlap is a ClashKind.Hard clash."""
|
|
201
|
+
@overload
|
|
202
|
+
def __init__(
|
|
203
|
+
self,
|
|
204
|
+
clearance: float = ...,
|
|
205
|
+
includeTouching: bool = ...,
|
|
206
|
+
maxDegreeOfParallelism: int = ...,
|
|
207
|
+
minimumDepth: float = ...,
|
|
208
|
+
minimumVolume: float = ...,
|
|
209
|
+
) -> None:
|
|
210
|
+
"""Initializes the options."""
|
|
211
|
+
@property
|
|
212
|
+
def Clearance(self) -> float:
|
|
213
|
+
"""Gets how far apart two parts have to stay; nought when no clearance is checked."""
|
|
214
|
+
Default: ClassVar[ClashOptions]
|
|
215
|
+
"""Gets the options that report parts running into each other and parts touching, with no clearance, on every
|
|
216
|
+
processor."""
|
|
217
|
+
@property
|
|
218
|
+
def IncludeTouching(self) -> bool:
|
|
219
|
+
"""Gets whether parts that touch without sharing volume are reported."""
|
|
220
|
+
@property
|
|
221
|
+
def MaxDegreeOfParallelism(self) -> int:
|
|
222
|
+
"""Gets how many threads may check pairs at once; -1 for every processor."""
|
|
223
|
+
@property
|
|
224
|
+
def MinimumDepth(self) -> float:
|
|
225
|
+
"""Gets how deep two parts have to run into each other for a ClashKind.Hard clash; nought reports every
|
|
226
|
+
overlap."""
|
|
227
|
+
@property
|
|
228
|
+
def MinimumVolume(self) -> float:
|
|
229
|
+
"""Gets how much volume two bodies have to share for a ClashKind.Hard clash; nought reports every
|
|
230
|
+
overlap."""
|
|
231
|
+
@overload
|
|
232
|
+
def Equals(self, other: ClashOptions) -> bool: ...
|
|
233
|
+
@overload
|
|
234
|
+
def Equals(self, obj: object) -> bool: ...
|
|
235
|
+
def GetHashCode(self) -> int: ...
|
|
236
|
+
def ToString(self) -> str: ...
|
|
237
|
+
|
|
238
|
+
class ClashResult(System.Object):
|
|
239
|
+
"""One pair of parts a clash check found, and what they do to each other."""
|
|
240
|
+
@property
|
|
241
|
+
def Contact(self) -> System.Collections.Generic.IReadOnlyList[GeoFace3]:
|
|
242
|
+
"""Gets where the two lie against each other, face to face, for a ClashKind.Touch; empty where they meet
|
|
243
|
+
only along an edge or at a corner, and for every other kind. Each patch faces out of the part listed
|
|
244
|
+
first (ClashResult.First)."""
|
|
245
|
+
@property
|
|
246
|
+
def ContactArea(self) -> float:
|
|
247
|
+
"""Gets the area of ClashResult.Contact."""
|
|
248
|
+
@property
|
|
249
|
+
def Depth(self) -> float:
|
|
250
|
+
"""Gets how deep the two run into each other, for a ClashKind.Hard clash; nought otherwise."""
|
|
251
|
+
@property
|
|
252
|
+
def Distance(self) -> float:
|
|
253
|
+
"""Gets how far apart the two are: the gap for ClashKind.Clearance, nought otherwise."""
|
|
254
|
+
@property
|
|
255
|
+
def Error(self) -> System.Exception:
|
|
256
|
+
"""Gets what went wrong checking the pair, for ClashKind.Unresolved; null otherwise."""
|
|
257
|
+
@property
|
|
258
|
+
def First(self) -> int:
|
|
259
|
+
"""Gets the index of the first part of the pair: in the one list checked, the lower index; with two lists,
|
|
260
|
+
the index in the first."""
|
|
261
|
+
@property
|
|
262
|
+
def Gap(self) -> GeoLine3 | None:
|
|
263
|
+
"""Gets the shortest segment across the gap for ClashKind.Clearance, from the part listed first
|
|
264
|
+
(ClashResult.First) to the other; null otherwise."""
|
|
265
|
+
@property
|
|
266
|
+
def Kind(self) -> ClashKind:
|
|
267
|
+
"""Gets what the two do to each other."""
|
|
268
|
+
@property
|
|
269
|
+
def LengthInside(self) -> float:
|
|
270
|
+
"""Gets how much of a bar's centre line runs inside the part, for a bar checked by its centre line
|
|
271
|
+
(ClashBar); nought where the centre line stays outside, and for two bodies."""
|
|
272
|
+
@property
|
|
273
|
+
def Location(self) -> GeoPoint3:
|
|
274
|
+
"""Gets where the clash is: the centre of the volume shared, the centre of the contact, the middle of the
|
|
275
|
+
gap left, or for a pair that could not be checked, the middle of the space the two boxes share."""
|
|
276
|
+
@property
|
|
277
|
+
def Overlaps(self) -> System.Collections.Generic.IReadOnlyList[GeoSolid3]:
|
|
278
|
+
"""Gets the regions the two share, one body per region, for a ClashKind.Hard clash; empty otherwise, and for
|
|
279
|
+
a bar checked by its centre line, whose clashes are measured and not built. A clash reported as touching
|
|
280
|
+
for being shallower than ClashOptions.MinimumDepth or smaller than ClashOptions.MinimumVolume keeps them."""
|
|
281
|
+
@property
|
|
282
|
+
def Second(self) -> int:
|
|
283
|
+
"""Gets the index of the second part of the pair: in the one list checked, the higher index; with two lists,
|
|
284
|
+
the index in the second."""
|
|
285
|
+
@property
|
|
286
|
+
def Volume(self) -> float:
|
|
287
|
+
"""Gets how much volume the two share; nought unless the clash is ClashKind.Hard, and for a bar checked by
|
|
288
|
+
its centre line. A clash reported as touching for being too shallow or too small keeps it."""
|
|
289
|
+
def ToString(self) -> str: ...
|