ShapeArtist
- class compas.artists.ShapeArtist(*args, **kwargs)[source]
Bases:
compas.artists.artist.Artist
Base class for artists for geometric shapes.
- Parameters
shape (
compas.geometry.Shape
) – The geometry of the shape.color (tuple, optional) – The RGB color.
- Class Attributes
default_color (tuple) – The default rgb color value of the shape (
(255, 255, 255)
).- Attributes
shape (
compas.geometry.Shape
) – The geometry of the shape.color (tuple) – The RGB color.
u (int) – The resolution in the u direction. The default is
16
and the minimum3
.v (int) – The resolution in the v direction. The default is
16
and the minimum3
.
Methods
build
(item, **kwargs)Build an artist corresponding to the item type.
build_as
(item, artist_type, **kwargs)clear
()draw
()draw_collection
(collection)get_artist_cls
(data, **kwargs)redraw
()register
(item_type, artist_type)