quad(x1, y1, x2, y2, x3, y3, x3, y3)

Draws a quad to the page. A quad is a quadrilateral, a four sided polygon. It is similar to a rectangle, but the angles between its edges are not constrained to ninety degrees. The first pair of parameters (x1, y1) sets the first vertex, the subsequent pairs proceed around the defined shape.

Type: function

Parameter(s):

  • x1 {Number}:

    X-coordinate of Point 1.

  • y1 {Number}:

    Y-coordinate of Point 1.

  • x2 {Number}:

    X-coordinate of Point 2.

  • y2 {Number}:

    Y-coordinate of Point 2.

  • x3 {Number}:

    X-coordinate of Point 3.

  • y3 {Number}:

    Y-coordinate of Point 3.

  • x3 {Number}:

    X-coordinate of Point 4.

  • y3 {Number}:

    Y-coordinate of Point 4.

Returns:

  • {Polygon}:

    The new quad as a Polygon object.