Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- float ellipseXPosition;
- color red = color(255,0,0);
- color randomColor = randomColor();
- void setup() {
- size(500,500);
- noStroke();
- ellipseXPosition = 250;
- }
- void draw() {
- background(255,255,255);
- fill(randomColor);
- circle(250,250,300);
- //ellipseXPosition = ellipseXPosition + 0.2;
- }
- void circle(float xPos, float yPos, float diameter) {
- // x y width hight
- // float float float float
- ellipse(xPos, yPos, diameter, diameter);
- }
- color randomColor() {
- float r = random(0,255);
- float g = random(0,255);
- float b = random(0,255);
- color resultColor = color(r,g,b);
- return resultColor;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement