Drawing polygons


show more Drawing polygons provides you with in-depth training on Developer. Taught by Barton Poulson as part of the Interactive Data Visualization with Processing show less
please wait ...

Drawing polygons

The next step in Processing is to learn how to draw polygons or irregular shapes, this is still with flat sides, but you can have however many corners you want. And you can have whatever relationship between them that you want. This one is also a little bit different, because it has several different lines of code. And let me show you how this works by creating a new sketch right here. What I'm going to do is begin by putting in the name of the sketch. Now I will put in the size of the window, turn on anti-aliasing make things smoother, I'll give it a background color.

I'm going to use a hex code and that's going to be D9C6B0 kind of a tan color, there we go right there. Then I am going to put in a strokeWeight for the borders of these of 5 pixels, Save all that. Now to be able to draw an irregular polygon, you need several lines. The first thing it need to do is you have to have a command that says beginShape and that's all there is to that one.

Then what you do is yo...

Drawing polygons
Video duration: 3m 37s 7h 43m Beginner

Viewers:

Drawing polygons provides you with in-depth training on Developer. Taught by Barton Poulson as part of the Interactive Data Visualization with Processing

Subjects:
Developer IT
Software:
Processing
Author:
please wait ...