Function:
Draw a straight line free image:
Beginshape (), vertex (), and endshape () are the nodes that connect to the graph, and endshape (close) indicates the closed graph.
Draw a curve border free image:
Beginshape () start to draw
Vertex () graph start endpoint
Beziervertex (cx1, cy1, CX2, cy2, x, y) curves cx1, cy1, CX2, cy2 are the first and second control point coordinates X, Y is the end point coordinates
Endshape ()
Color: the key is that there are several values behind the brackets.
Grayscale: color (grayscale)
Gray Level transparency: color (gray level, transparency)
Color: color (R, G, B)
Color transparency: color (R, G, B, transparency)
Colormode (): defines the color mode.
Colormode (RGB, 255) adopts the RGB mode
Colormode (HSB, 360,100,100) uses the HSB mode followed by a number in the value range
Painting attributes:
Background (color) sets the canvas color
Fill (color) specifies the fill color
Nofill () is not color filled
Stroke (color) specifies the line color
Nostroke () does not draw lines
Strokeweight (thickness) specifies the Border Width
Strokecap (mode) specifies the line endpoint form including square (square endpoint) project (square extension endpoint) round (Circular endpoint)
Strokejoin (mode) specifies the line angle in the form of miter (sharp angle) bevel (diagonal angle) round (rounded corner)
Smooth () enables smooth drawing mode
Nosmooth () Disable smooth drawing mode
[Processing] Small Code 2