Upcoming SlideShare
×

# ronpro2011s#11

730 views

Published on

0 Likes
Statistics
Notes
• Full Name
Comment goes here.

Are you sure you want to Yes No
• Be the first to comment

• Be the first to like this

Views
Total views
730
On SlideShare
0
From Embeds
0
Number of Embeds
115
Actions
Shares
0
0
0
Likes
0
Embeds 0
No embeds

No notes for slide

### ronpro2011s#11

1. 1. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14 #11N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski)
2. 2. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/10 5•  "•  "•
3. 3. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14(x, y) (mouseX, mouseY)
4. 4. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14 (x, y) (mouseY - y) (mouseX, mouseY) (mouseX - x)
5. 5. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14 1•  800 × 600 100 "•  200 "•  200 "•  200 "•  100
6. 6. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14•  "•  "•
7. 7. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14ﬂoat r;" void draw(){"int x, y;" background(0, 0, 0);"" if(dist(x, y, mouseX, mouseY) < 200){"void setup(){" if(r < 200){" size(800, 600);" r = r + 1;" }" smooth();" }else if(r > 100){" noStroke();" r = r - 1;" r = 100;" }" x = 400;" ellipse(x, y, r, r);" y = 300;" }}""
8. 8. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14booleanboolean inArea(){" boolean result = " dist(x, y, mouseX, mouseY) < 200;" return result;"}
9. 9. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14if(dist(x, y, mouseX, mouseY) < 200){"if(inArea()){
10. 10. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14boolean inArea(){" boolean result = " dist(x, y, mouseX, mouseY) < 200;" return result;"}
11. 11. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14boolean inArea(ﬂoat d){" boolean result = " dist(x, y, mouseX, mouseY) < d;" return result;"}
12. 12. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14void draw(){" background(0, 0, 0);" if(inArea(150)){"
13. 13. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14void increaseSize(){"}
14. 14. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14 2•  1 increaseSize 1 "•  "
15. 15. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14 3•  2 increaseSize "•
16. 16. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14 4• increaseSize decreaseSize "•  "•  decreaseSize
17. 17. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14 6• increaseSize "•  - * 0.05"•  "
18. 18. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14 7•  6 decreaseSize
19. 19. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14 8•  blackout "   "   rect "• background blackout
20. 20. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14 9•  "•  "•
21. 21. N. Shimizu (chiko@sfc.keio.ac.jp / @chikoski) 2011/07/14 10•  9 "•