MeshArtist
- class compas.artists.MeshArtist(*args, **kwargs)[source]
Bases:
compas.artists.artist.ArtistBase class for all mesh artists.
- Parameters
mesh (
compas.datastructures.Mesh) – A COMPAS mesh.- Class Attributes
default_color (tuple) – The default color of the mesh.
default_vertexcolor (tuple) – The default color for vertices that do not have a specified color.
default_edgecolor (tuple) – The default color for edges that do not have a specified color.
default_facecolor (tuple) – The default color for faces that do not have a specified color.
default_vertexsize (int)
default_edgewidth (float)
- Attributes
mesh (
compas.datastructures.Mesh) – The mesh associated with the artist.vertices (list) – The vertices to include in the drawing. Default is all vertices.
edges (list) – The edges to include in the drawing. Default is all edges.
faces (list) – The faces to include in the drawing. Default is all faces.
vertex_xyz (dict) – The view coordinates of the vertices. Default is to use the actual vertex coordinates.
vertex_color (dict) – Mapping between vertices and colors. Default is to use the default color for vertices.
edge_color (dict) – Mapping between edges and colors. Default is to use the default color for edges.
face_color (dict) – Mapping between faces and colors. Default is to use the default color for faces.
vertex_text (dict) – Mapping between vertices and text labels.
edge_text (dict) – Mapping between edges and text labels.
face_text (dict) – Mapping between faces and text labels.
Attributes
colordefault_colordefault_edgecolordefault_edgewidthdefault_facecolordefault_vertexcolordefault_vertexsizeedge_coloredge_textedge_widthedgesface_colorface_textfacesmeshvertex_colorvertex_sizevertex_textvertex_xyzverticesInherited Attributes
AVAILABLE_CONTEXTSCONTEXTITEM_ARTISTMethods
Draw the edges of the mesh.
Draw the faces of the mesh.
Draw the vertices of the mesh.
Inherited Methods
Build an artist corresponding to the item type.