VectorArtist

class compas_plotters.artists.VectorArtist(item, **kwargs)[source]

Bases: PlotterArtist, PrimitiveArtist

Artist for COMPAS vectors.

Parameters
  • vector (Vector) – A COMPAS vector.

  • point (Point, optional) – A COMPAS point as base point for the vector. Default is the origin of the world coordinate system.

  • draw_point (bool, optional) – If True, draw the point of application of the vector.

  • color (tuple[float, float, float], optional) – Color of the vector.

  • zorder (int, optional) – Stacking order of the vector on the canvas.

  • **kwargs (dict, optional) – Additional keyword arguments. See PlotterArtist and PrimitiveArtist for more info.

Attributes

vector (Vector) – The vector associated with the artist.

Methods

draw

Draw the vector.

redraw

Update the vector using the current geometry and visualization settings.

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_collection

Drawing method for drawing an entire collection of objects.

register

Register an artist type to a data type.

update_data

Update the data limits of the plotting axes using the visualization data.

viewbox

Compute the bounds of the current view.