SurfaceArtist

class compas.artists.SurfaceArtist(*args, **kwargs)[source]

Bases: Artist

Base class for artists for surfaces.

Parameters
  • surface (Surface) – The surface geometry.

  • color (tuple[float, float, float] | Color, optional) – The RGB color.

Attributes
  • surface (Surface) – The geometry of the surface.

  • color (Color) – The color of the surface.

Class Attributes

default_color (Color) – The default color of the surface.

Inherited Methods

build

Build an artist corresponding to the item type.

build_as

Build an artist with the given type.

clear

Clear all objects from the view.

draw

The main drawing method.

draw_collection

Drawing method for drawing an entire collection of objects.

redraw

Redraw the view.

register

Register an artist type to a data type.