square()

Shape / 2D Primitives

Description

Draws a square to the screen.

Syntax

void square(float x, float y, float s)

Parameters

NameTypeDescription
xfloatx-coordinate of the upper-left corner
yfloaty-coordinate of the upper-left corner
sfloatside length

Returns

void

Related

Under the Hood

Implementation in Processing.h / Processing.cpp:

Loading...