add_vertex
- Mesh.add_vertex(point, *args, **kwargs)[source]
Create and add new vertex.
The first point added to a mesh determines the dimensionality of all mesh vertices.
- Parameters:
point (array_like or float) – Vertex coordinates.
*args – Variable number of scalars.
**kwargs – Attribute name and value pairs.
- Raises:
ValueError – If point has the wrong shape.
- Returns:
The newly created
Vertex
instance.- Return type:
Note
When adding a new vertex all vertex data blocks are extended by a correponding value:
either by using the default value specified when the data block was added,
or by using a value provided as keyword argument.
Values specified as keyword arguments that don’t fit this pattern are added as
Vertex
instance attributes and only availabe as attributes of this particular instance.