Draft PointArray
Draft PointArray |
Menu location |
---|
Draft → PointArray |
Workbenches |
Draft, Arch |
Default shortcut |
None |
Introduced in version |
0.18 |
See also |
Draft Array, Draft PathArray |
Description
The PointArray tool places copies of a selected shape along various selected points.
The PointArray tool can be used on 2D shapes created with the Draft Workbench, but can also be used on many types of 3D objects such as those created with the Part, PartDesign, or Arch Workbenches.
To position copies in an orthogonal array use Draft Array; to position copies along a path use Draft PathArray; to create copies or clones, and manually place them use Draft Move, Draft Rotate, and Draft Clone.
How to use
- Select an object which you wish to distribute.
- Select a point compound.
- Press the Draft PointArray button.
To create a point compound select various Draft Points and then press the Draft Upgrade button.
Options
There are no options for this tool. Either it works with the selected object or not.
Properties
- DataBase: specifies the object to duplicate.
- DataCount: (read-only) specifies the number of copies of the base object. This number will depend on the number of Draft Points in the compound.
- DataPointList: specifies the compound object with the points needed to place the copies of the base object.
Scripting
See also: Draft API and FreeCAD Scripting Basics.
The PointArray tool can be used in macros and from the Python console by using the following function:
PointArray = makePointArray(base, ptlst)
- Creates a
PointArray
object from thebase
object, by placing the copies alongptlst
. ptlst
is an object withGeometry
,Links
, orComponents
attributes that define the position of the copies.
Example:
import FreeCAD, Draft
Polygon = Draft.makePolygon(3, radius=500.0)
p1 = Draft.makePoint(FreeCAD.Vector(1500, 0, 0))
p2 = Draft.makePoint(FreeCAD.Vector(2500, 0, 0))
p3 = Draft.makePoint(FreeCAD.Vector(2000, 1000, 0))
# Create a compound of points
addList, deleteList = Draft.upgrade([p1, p2, p3])
# Extract the compound from the list
compound = addList[0]
PointArray = Draft.makePointArray(Polygon, compound)
Usage Notes
- in progress