ElementGeometry.Builder Class
Builder is a helper class for populating a ElementGeometryDataEntry array needed to create a GeometricElement or GeometryPart.
Methods
Name | Description | |
---|---|---|
constructor(): ElementGeometry.Builder | ||
appendBRepData(brep: BRepEntity.DataProps): boolean | Append a DataProps supplied in either local or world coordinates to the ElementGeometryDataEntry array. | |
appendGeometryParamsChange(geomParams: GeometryParams): boolean | Change GeometryParams for subsequent geometry. | |
appendGeometryPart(partId: string, partTransform?: Transform): boolean | Append a GeometryPart instance with relative transform to the ElementGeometryDataEntry array for creating a GeometricElement. | |
appendGeometryPart2d(partId: string, instanceOrigin?: Point2d, instanceRotation?: Angle, instanceScale?: number): boolean | Append a GeometryPart instance with relative position, orientation, and scale to the ElementGeometryDataEntry array for creating a GeometricElement2d. | |
appendGeometryPart3d(partId: string, instanceOrigin?: Point3d, instanceRotation?: YawPitchRollAngles, instanceScale?: number): boolean | Append a GeometryPart instance with relative position, orientation, and scale to the ElementGeometryDataEntry array for creating a GeometricElement3d. | |
appendGeometryQuery(geometry: GeometryQuery): boolean | Append a GeometryQuery supplied in either local or world coordinates to the ElementGeometryDataEntry array | |
appendGeometryRanges(): boolean | Store local ranges for all subsequent geometry appended. | |
appendImageGraphic(image: ImageGraphic): boolean | Append a ImageGraphic supplied in either local or world coordinates to the ElementGeometryDataEntry array | |
appendTextBlock(block: TextBlockGeometryProps): boolean | Append a series of entries representing a TextBlock to the ElementGeometryDataEntry array. | |
appendTextString(text: TextString): boolean | Append a TextString supplied in either local or world coordinates to the ElementGeometryDataEntry array | |
setLocalToWorld(localToWorld?: Transform): void | Supply optional local to world transform. | |
setLocalToWorld2d(origin: Point2d, angle: Angle...): void | Supply local to world transform from a Point2d and optional Angle. | |
setLocalToWorld3d(origin: Point3d, angles: YawPitchRollAngles...): void | Supply local to world transform from a Point3d and optional YawPitchRollAngles. | |
setLocalToWorldFromPlacement(props: PlacementProps): void | Supply local to world transform from a PlacementProps2d or PlacementProps3d. | |
placementAngleFromPoints(pts: Point3d[], result?: Angle): Angle Static | Compute angle suitable for passing to ElementGeometry.Builder.setLocalToWorld2d from an array of xy plane points. | |
placementAnglesFromPoints(pts: Point3d[], defaultUp?: Vector3d, result?: YawPitchRollAngles): YawPitchRollAngles Static | Compute angles suitable for passing to ElementGeometry.Builder.setLocalToWorld3d from an array of 3d points. |
Properties
Name | Type | Description | |
---|---|---|---|
entries Readonly | ElementGeometryDataEntry[] | GeometryStream entries | |
localToWorld Accessor ReadOnly | undefined | Transform | Current placement transform, converts local coordinate (placement relative) input to world | |
worldToLocal Accessor ReadOnly | undefined | Transform | Current inverse placement transform, converts world coordinate input to local (placement relative) |
Defined in
Last Updated: 14 November, 2024
Found something wrong, missing, or unclear on this page?Raise an issue in our repo.