Monday, July 28, 14
HTML COMMENT <!-- -->
CSS COMMENT // or /* */
PROCESSING COMMENT // or /* */
Monday, July 28, 14
void setup() {
/* size(400, 400);
noStroke();
background(100,0,255); */
}
void draw() {
//Draw a circle
 ellipse(mouseX, mouseY, 80, 80);
}
Monday, July 28, 14
Monday, July 28, 14
void draw() {
if (keyPressed) {
if (key == 'b' || key == 'B') {
fill(0);
}
} else {
fill(255);
}
rect(25, 25, 50, 50);
}
Monday, July 28, 14
float circleX = 0;
void setup() {
size(400,400);
noStroke();
fill(193, 155, 62);
}
void draw(){
background(27, 177, 245);
ellipse(circleX, 50, 50, 50);
circleX = circleX + 1;
if(circleX > 400) {
circleX=0;
}
}
Monday, July 28, 14
float circleX = 0;
float speed = 2;
void setup() {
size(400,400);
noStroke();
fill(193, 155, 62);
}
void draw(){
background(27, 177, 245);
ellipse(circleX, 50, 50, 50);
circleX = circleX + speed;
if(circleX < 0) {
speed *= -1;
}
if(circleX > 400) {
speed *= -1;
}
}
Monday, July 28, 14
float circleX = 0;
float speed = 2;
void setup() {
size(400,400);
noStroke();
fill(193, 155, 62);
}
void draw(){
background(27, 177, 245);
ellipse(circleX, 50, 50, 50);
circleX = circleX + speed;
if (keyPressed) {
if (key == 'b' || key == 'B') {
speed *= -1;
}
}
}
Monday, July 28, 14
FLAPPY BIRD CAN BE MADE WITH 25 IF STATEMENTS
http://www.openprocessing.org/sketch/133401
PONG CAN BE MADE WITH LESS THAN 20
https://github.com/nakul13/PONG/commit/
04680fd6041a1134852f6a425212c27d2965eef0
Monday, July 28, 14
THE FOR LOOP
void setup() {
size(400,400);
stroke(0);
fill(193, 155, 62);
}
void draw(){
for (int i = 0; i < 200; i = i+1)
{
line(30, i, 350, i);
}
}
Monday, July 28, 14
THE FOR LOOP
for (int i = 0; i < 200; i = i+5)
{
line(30, i, 350, i);
}
Monday, July 28, 14
THE FOR LOOP
for (int i = 0; i < 200; i = i+5)
{
ellipse (20*i, 20*i, 10, 10);
}
Monday, July 28, 14
Monday, July 28, 14
PImage webImg;
void setup() {
size(528, 720);
String url = "http://bit.ly/1ApLO5u";
}
void draw() {
background(0);
image(webImg, 0, 0);
}
Monday, July 28, 14

More Related Content

PDF
Processing ii
KEY
Kwp2 100114
KEY
Kwp2 100107
PPTX
[3] 프로세싱과 아두이노
KEY
Proga 090525
PDF
graphics Assidnment
KEY
Kwp2 100121
Processing ii
Kwp2 100114
Kwp2 100107
[3] 프로세싱과 아두이노
Proga 090525
graphics Assidnment
Kwp2 100121

Viewers also liked (6)

PPT
Simplesmente Python: Por que você não deve deixar de aprender essa linguagem
PDF
Python introduction
PDF
Python for text processing
PDF
Text Classification in Python – using Pandas, scikit-learn, IPython Notebook ...
PDF
Practical Natural Language Processing
PPTX
NLTK - Natural Language Processing in Python
Simplesmente Python: Por que você não deve deixar de aprender essa linguagem
Python introduction
Python for text processing
Text Classification in Python – using Pandas, scikit-learn, IPython Notebook ...
Practical Natural Language Processing
NLTK - Natural Language Processing in Python
Ad

More from citylore (7)

PDF
Processing i
PDF
Cssii
PDF
Lesson 2- Css1
PDF
Lesson 1
PPT
Live from the poemobile 2012
PPT
City Lore Outcomes Institute Powerpoint
PPTX
City Lore Interviewing guide
Processing i
Cssii
Lesson 2- Css1
Lesson 1
Live from the poemobile 2012
City Lore Outcomes Institute Powerpoint
City Lore Interviewing guide
Ad

Recently uploaded (20)

PPTX
Computer Architecture Input Output Memory.pptx
PDF
HVAC Specification 2024 according to central public works department
PPTX
ELIAS-SEZIURE AND EPilepsy semmioan session.pptx
PPTX
A powerpoint presentation on the Revised K-10 Science Shaping Paper
PPTX
Virtual and Augmented Reality in Current Scenario
PPTX
TNA_Presentation-1-Final(SAVE)) (1).pptx
PPTX
CHAPTER IV. MAN AND BIOSPHERE AND ITS TOTALITY.pptx
PDF
BP 704 T. NOVEL DRUG DELIVERY SYSTEMS (UNIT 2).pdf
PPTX
Unit 4 Computer Architecture Multicore Processor.pptx
DOCX
Cambridge-Practice-Tests-for-IELTS-12.docx
PDF
advance database management system book.pdf
PPTX
History, Philosophy and sociology of education (1).pptx
PDF
Hazard Identification & Risk Assessment .pdf
PDF
LDMMIA Reiki Yoga Finals Review Spring Summer
PDF
IGGE1 Understanding the Self1234567891011
PDF
Empowerment Technology for Senior High School Guide
PDF
A GUIDE TO GENETICS FOR UNDERGRADUATE MEDICAL STUDENTS
PDF
AI-driven educational solutions for real-life interventions in the Philippine...
PPTX
Chinmaya Tiranga Azadi Quiz (Class 7-8 )
PDF
Environmental Education MCQ BD2EE - Share Source.pdf
Computer Architecture Input Output Memory.pptx
HVAC Specification 2024 according to central public works department
ELIAS-SEZIURE AND EPilepsy semmioan session.pptx
A powerpoint presentation on the Revised K-10 Science Shaping Paper
Virtual and Augmented Reality in Current Scenario
TNA_Presentation-1-Final(SAVE)) (1).pptx
CHAPTER IV. MAN AND BIOSPHERE AND ITS TOTALITY.pptx
BP 704 T. NOVEL DRUG DELIVERY SYSTEMS (UNIT 2).pdf
Unit 4 Computer Architecture Multicore Processor.pptx
Cambridge-Practice-Tests-for-IELTS-12.docx
advance database management system book.pdf
History, Philosophy and sociology of education (1).pptx
Hazard Identification & Risk Assessment .pdf
LDMMIA Reiki Yoga Finals Review Spring Summer
IGGE1 Understanding the Self1234567891011
Empowerment Technology for Senior High School Guide
A GUIDE TO GENETICS FOR UNDERGRADUATE MEDICAL STUDENTS
AI-driven educational solutions for real-life interventions in the Philippine...
Chinmaya Tiranga Azadi Quiz (Class 7-8 )
Environmental Education MCQ BD2EE - Share Source.pdf

Processing iii

  • 2. HTML COMMENT <!-- --> CSS COMMENT // or /* */ PROCESSING COMMENT // or /* */ Monday, July 28, 14
  • 3. void setup() { /* size(400, 400); noStroke(); background(100,0,255); */ } void draw() { //Draw a circle  ellipse(mouseX, mouseY, 80, 80); } Monday, July 28, 14
  • 5. void draw() { if (keyPressed) { if (key == 'b' || key == 'B') { fill(0); } } else { fill(255); } rect(25, 25, 50, 50); } Monday, July 28, 14
  • 6. float circleX = 0; void setup() { size(400,400); noStroke(); fill(193, 155, 62); } void draw(){ background(27, 177, 245); ellipse(circleX, 50, 50, 50); circleX = circleX + 1; if(circleX > 400) { circleX=0; } } Monday, July 28, 14
  • 7. float circleX = 0; float speed = 2; void setup() { size(400,400); noStroke(); fill(193, 155, 62); } void draw(){ background(27, 177, 245); ellipse(circleX, 50, 50, 50); circleX = circleX + speed; if(circleX < 0) { speed *= -1; } if(circleX > 400) { speed *= -1; } } Monday, July 28, 14
  • 8. float circleX = 0; float speed = 2; void setup() { size(400,400); noStroke(); fill(193, 155, 62); } void draw(){ background(27, 177, 245); ellipse(circleX, 50, 50, 50); circleX = circleX + speed; if (keyPressed) { if (key == 'b' || key == 'B') { speed *= -1; } } } Monday, July 28, 14
  • 9. FLAPPY BIRD CAN BE MADE WITH 25 IF STATEMENTS http://www.openprocessing.org/sketch/133401 PONG CAN BE MADE WITH LESS THAN 20 https://github.com/nakul13/PONG/commit/ 04680fd6041a1134852f6a425212c27d2965eef0 Monday, July 28, 14
  • 10. THE FOR LOOP void setup() { size(400,400); stroke(0); fill(193, 155, 62); } void draw(){ for (int i = 0; i < 200; i = i+1) { line(30, i, 350, i); } } Monday, July 28, 14
  • 11. THE FOR LOOP for (int i = 0; i < 200; i = i+5) { line(30, i, 350, i); } Monday, July 28, 14
  • 12. THE FOR LOOP for (int i = 0; i < 200; i = i+5) { ellipse (20*i, 20*i, 10, 10); } Monday, July 28, 14
  • 14. PImage webImg; void setup() { size(528, 720); String url = "http://bit.ly/1ApLO5u"; } void draw() { background(0); image(webImg, 0, 0); } Monday, July 28, 14