Arrow
- class Arrow[source]
Bases:
compas.geometry.shapes._shape.Shape
A Arrow is defined by its location and direction vector.
- Parameters
- positionlist of float or compas.geometry.Vector
The start position of arrow
- directionlist of float or compas.geometry.Vector
The height of the cone.
Examples
>>> from compas.geometry import Arrow >>> arrow = Arrow([0, 0, 0], [0, 0, 1])
- Attributes
- head_portionfloat
The portion of head of the arrow
- head_widthfloat
The head width relative to the length of arrow
- body_widthfloat
The body width relative to the length of arrow
Methods
Construct a Arrow from its data representation.
Returns a list of vertices and faces.
Transform the Arrow.
Inherited Methods
Converts the instance to a string.
Make an independent copy of the data object.
Construct an object from serialized data contained in a JSON file.
Construct an object from serialized data contained in a JSON string.
Compute a hash of the data for comparison during version control using the sha256 algorithm.
Convert an object to its native data representation.
Serialize the data representation of an object to a JSON file.
Serialize the data representation of an object to a JSON string.
Returns a transformed copy of this geometry.
Validate the object's data against its data schema.
Validate the object's data against its json schema.