Patches nodes#

PyLabCircle()

Create true circle at center xy.

PyLabEllipse()

Create ellipse patch.

PyLabPolygon()

Create Polygon patch.

PyLabRectangle()

Create Rectangle patch.

PyLabWedge()

Create Wedge patch.

PyLabPatchDictionary()

VisuAlea version of pylab.patch.

Api#

VisuAlea nodes related to pylab.patches functionalities

class openalea.pylab_patches_wralea.py_pylab.PyLabCircle[source]#

Create true circle at center xy. See matplotlib.patches.Circle for details

Parameters:
  • x – x coordinate of circle’s center

  • y – y coordinate of circle’s center

  • radius – radius of the circle

  • patch – a PyLabPatchDictionary object (optional)

Returns:

a circle patch

Example:

class openalea.pylab_patches_wralea.py_pylab.PyLabEllipse[source]#

Create ellipse patch. See matplotlib.patches.Ellipse for details

Parameters:
  • x – x coordinate of ellipse center

  • y – y coordinate of ellipse center

  • width – width of horizontal axis

  • height – length of vertical axis

  • angle – rotation in degrees (anti-clockwise)

  • patch – a PyLabPatchDictionary object (optional)

Returns:

an ellipse patch

Example:

class openalea.pylab_patches_wralea.py_pylab.PyLabPatchDictionary[source]#

VisuAlea version of pylab.patch.

This node allows you to customize a patch object such as pylab.patches.Circle() and therefore all nodes in VisuAlea that are in the patches directory including for instance PyLabCircle, PyLabPolygon and so on.

Parameters:
  • alpha (float) – The alpha blending value. (default is 1.0)

  • color

  • edgecolor

  • facecolor

  • figure

  • fill

  • label

  • linestyle

  • linewidth

Returns:

a dictionary that can be used by patches to provide optional arguments.

class openalea.pylab_patches_wralea.py_pylab.PyLabPolygon[source]#

Create Polygon patch. See matplotlib.patches.Ellipse for details

Parameters:
  • x – array with shape Nx1

  • y – array with shape Nx1.

  • closed – polygon will be closed so the starting and ending points are the same (default is True)

  • patch – a PyLabPatchDictionary object (optional)

Returns:

a polygon patch

Example:

class openalea.pylab_patches_wralea.py_pylab.PyLabRectangle[source]#

Create Rectangle patch. See matplotlib.patches.Rectangle for details

Parameters:
  • x – x coordinate of lower left rectangle

  • y – y coordinate of lower left rectangle

  • width – width of the rectangle

  • height – height of the rectangle

  • patch – a PyLabPatchDictionary object (optional)

Returns:

a rectangle patch

Example:

class openalea.pylab_patches_wralea.py_pylab.PyLabWedge[source]#

Create Wedge patch. See matplotlib.patches.Wedge for details

Parameters:
  • x – x-coordinate of wedge’s center

  • y – y-coordinate of wedge’s center

  • r – radius that sweeps theta1 and theta2

  • theta1

  • theta2

  • width – if provided, then a partial wedge is drawn from inner radius r - width to outer radius r.

  • patch – a PyLabPatchDictionary object (optional)

Returns:

a wedge patch

Example: