This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int value; | |
void setup() { | |
size(640, 360); | |
} | |
void draw() { | |
background(102); | |
pushMatrix(); | |
translate(width*0.2, height*0.5); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int x = 1; | |
int y = 2; | |
int value; | |
void setup () | |
{ | |
size(1200, 1200); | |
pixelDensity (2); | |
} | |
void draw () |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//variables | |
int a = 40; | |
int b = 255; | |
float ok = 255; | |
float ya = 500; | |
float yo = 0; | |
//boolean stroke() = true; | |
//boolean noStroke() = false; | |
void setup() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//create variables for pins | |
const int blueLed = 11; | |
const int whiteLed = 12; | |
const int potPin = A0; | |
// Time code | |
unsigned long previousMillis = 0; | |
const long interval = 10; | |
// LED fading variables |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// images are in zip file link in Assignment submission !! | |
float x = 0; | |
float y = 10; | |
float z = 0; | |
PImage a; | |
PImage b; | |
PImage c; | |
void setup() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// six pins instead of three. | |
int ledPin1 = 8; | |
int ledPin2 = 9; | |
int ledPin3 = 10; | |
int ledPin4 = 11; | |
int ledPin5 = 12; | |
int ledPin6 = 13; | |
int ledPins[6] = (8, 9, 10, 11, 12, 13); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int ledPins[] = { 3, 5, 6, 9, 10, 11, 10, 9, 6, 5, }; | |
int pinCount = 10; | |
int ledFade[10]; | |
int i; | |
int prevTime; | |
int interval = 500; | |
int fadeSpeed = 5; | |
int prevFadeTime; | |
void setup() { | |
/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Use oscillation (sin() and cos()) and loops (for or while) | |
PImage a; | |
float posX = 2; | |
float posY = 2; | |
float sizeX = 0; | |
float sizeY = 0; | |
float time = 0; | |
//float previousMillis = 0; | |
//int interval = 100; | |
color[] colors = new color[2]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// as you click each slide, the plant stem grows! | |
// you can toggle back and forth using the left and right arrow keys. | |
float posX = 2; | |
float posY = 2; | |
float sizeX = 0; | |
float sizeY = 0; | |
int lineX = 0; | |
int lineY = 0; |
OlderNewer