VolMeshArtist
- class compas.artists.VolMeshArtist(*args, **kwargs)[source]
Bases:
compas.artists.artist.ArtistArtist for drawing volmesh data structures.
- Parameters
volmesh (
compas.datastructures.VolMesh) – A COMPAS volmesh.- Class Attributes
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_cellcolor (tuple) – The default color for cells that do not have a specified color.
- Attributes
volmesh (
compas.datastructures.VolMesh) – The COMPAS volmesh associated with the artist.vertices (list) – The list of vertices to draw. Default is a list of all vertices of the volmesh.
edges (list) – The list of edges to draw. Default is a list of all edges of the volmesh.
faces (list) – The list of faces to draw. Default is a list of all faces of the volmesh.
cells (list) – The list of cells to draw. Default is a list of all cells of the volmesh.
vertex_xyz (dict[int, tuple(float, float, float)]) – Mapping between vertices and their view coordinates. The default view coordinates are the actual coordinates of the vertices of the volmesh.
vertex_color (dict[int, tuple(int, int, int)]) – Mapping between vertices and RGB color values. The colors have to be integer tuples with values in the range
0-255. Missing vertices get the default vertex color (~VolMeshArtist.default_vertexcolor).vertex_text (dict[int, str]) – Mapping between vertices and text labels. Missing vertices are labelled with the corresponding vertex identifiers.
edge_color (dict[tuple(int, int), tuple(int, int, int)]) – Mapping between edges and RGB color values. The colors have to be integer tuples with values in the range
0-255. Missing edges get the default edge color (~VolMeshArtist.default_edgecolor).edge_text (dict[tuple(int, int), str]) – Mapping between edges and text labels. Missing edges are labelled with the corresponding edge identifiers.
face_color (dict[tuple, tuple(int, int, int)]) – Mapping between faces and RGB color values. The colors have to be integer tuples with values in the range
0-255. Missing faces get the default face color (~VolMeshArtist.default_facecolor).face_text (dict[tuple, str]) – Mapping between faces and text labels. Missing faces are labelled with the corresponding face identifiers.
cell_color (dict[int, tuple(int, int, int)]) – Mapping between cells and RGB color values. The colors have to be integer tuples with values in the range
0-255. Missing cells get the default cell color (~VolMeshArtist.default_cellcolor).cell_text (dict[int, str]) – Mapping between cells and text labels. Missing cells are labelled with the corresponding cell identifiers.
Attributes
cell_colorcell_textcellsdefault_cellcolordefault_edgecolordefault_facecolordefault_vertexcoloredge_coloredge_textedgesface_colorface_textfacesvertex_colorvertex_textvertex_xyzverticesvolmeshInherited Attributes
AVAILABLE_CONTEXTSCONTEXTITEM_ARTISTMethods
Draw the cells of the mesh.
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.