Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
NCC-JavaScript-Week#5
Search
Irene Chang
November 19, 2015
Education
75
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
NCC-JavaScript-Week#5
NTUST Coding Club JavaScript Course Week#5 (2015.11.20)
By Chiun Hau
For self-study only.
Irene Chang
November 19, 2015
More Decks by Irene Chang
See All by Irene Chang
前端初心者談,合作過程與學習經驗
irene84111
0
200
一手打造你的專屬網誌-Hexo 簡介及教學
irene84111
0
550
NCC-JavaScript-Week#7
irene84111
0
150
NCC-JavaScript-Week#6
irene84111
0
150
NCC-SublimeText-InstallationTutorial
irene84111
0
47
NCC-JavaScript-Week#4
irene84111
0
46
NCC-JavaScript-Week#3
irene84111
0
130
NCC-JavaScript-Week#2
irene84111
0
240
NCC-JavaScript-Week#1
irene84111
0
190
Other Decks in Education
See All in Education
Science Tokyo University for International Research Excellence scheme_April 2026
sciencetokyo
PRO
0
420
Geografía y fútbol. Atlanta. la megalópolis del fútbol
juanmartin2026
1
12k
HCI and Interaction Design - Lecture 2 - Human-Computer Interaction (1023841ANR)
signer
PRO
0
2k
TISSUE
pawan_pharm
0
260
学習者データを「見る」:外国語教師のためのデータの入力、分析、解釈方法
uranoken
0
410
Introduction - Lecture 1 - Human-Computer Interaction (1023841ANR)
signer
PRO
0
3.5k
20260908_ターゲットとスコープを決める発表法
masakiokuda
1
130
セキュリティ担当がいない中小医療機関を院外のRISSはどう支えるべきか / How External RISS Can Help Small Medical Institutions
eller86
1
220
組合せ最適化特論
tasusu
0
130
Sanapilvet opetuksessa
matleenalaakso
1
36k
Introduction - Lecture 1 - Web Technologies (1019888BNR)
signer
PRO
0
6.5k
Sekolah Sabat - Triwulan 4 2026 - Pelajaran 1
hiola
0
12k
Featured
See All Featured
[SF Ruby Conf 2025] Rails X
palkan
3
1.4k
The Limits of Empathy - UXLibs8
cassininazir
2
710
Context Engineering - Making Every Token Count
addyosmani
9
1.2k
VelocityConf: Rendering Performance Case Studies
addyosmani
331
25k
Practical Orchestrator
shlominoach
192
12k
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
Ten Tips & Tricks for a 🌱 transition
stuffmc
1
250
Getting science done with accelerated Python computing platforms
jacobtomlinson
2
520
The Illustrated Children's Guide to Kubernetes
chrisshort
51
53k
The AI Search Optimization Roadmap by Aleyda Solis
aleyda
2
6.3k
GraphQLとの向き合い方2022年版
quramy
50
15k
We Are The Robots
honzajavorek
0
390
Transcript
Build Cool Things with p5.js 康 㹦 ꔤ ⚺
⥜ ㉂ 噠 鏤 鎙 鰊 ⥜ 蒀 䕙 撑 僈 〵 猰 㣐 ✽ ⹛ 鏤 鎙 灇 瑖 爢 鴍 㣗
Why p5.js is COOL? 1 S P D F T
T J O H 涸 ㆹ 㷸 + B W B T D S J Q U 涸 㻜 ⡲ 㛇 劥 ♳ 㽠 僽 剤 鞮 㺢 ✽ ⹛ 䚍 涸 㼭 殥 㹻 罜 ⚂ 佅 䴂 % 粭 㕬 莅 ⹛ 殥
NYU ITP Q ⚺ 銴 歋 * 5 1
涸 㷸 欰 笞 隌 罜 ⚂ 䖎 㢵 僽 㥏 欰 * 5 1 㥶 ず . * 5 . F E J B - B C 僽 ✽ ⹛ 猰 䪮 谁 遯 涸 ⯓ 뀝
Example Code <3 劥 傈 䨾 剤 玑 䒭 焺
鿪 㖈 鸏 酆 I U U Q T H J U I V C D P N D I J V O I B V Q O D D
function setup() 〫 剚 㖈 玑 䒭 ⴲ 㨥 ⻋
㻜 㛂 遤 ♧ 妄 欽 倴 ♧ 妄 䚍 鏤 㹁
function draw() 剚 ♧ 湬 㛂 遤 湬 ⵌ ꡠ
ꟗ 笪 갤 欽 ⢵ 殥 㕬 㘗 騈 ⹛ 殥
function setup(){ createCanvas(500, 500); } function draw(){ ellipse(100, 100, 50,
50); } 殥 ♧ ⦐ ꬆ 姺 涸 㕩
ellipse(x, y, width, height) F M M J Q T
F
function setup(){ createCanvas(500, 500); } function draw(){ ellipse(100, 100, 50,
50); ellipse(200, 100, 70, 70); } 殥 Ⰽ ⦐ ꬆ 姺 涸 㕩
fill(color(100, 200, 100)); stroke(color(“red”)); // or no color noFill(); noStroke();
겝 蒀
var xPos = 0; function draw(){ ellipse(xPos, 100, 50, 50);
xPos ++; } 殥 ♧ ⦐ 剚 ⹛ 涸 㕩
function mouseClicked() 殹 徿 롗 럊 乹 ♧ ♴ ⛓
䖕 㽠 剚 㛂 遤
function mouseClicked(){ ellipse(mouseX, mouseY, 50, 50); } N P V
T F $ M J D L F E 徿 롗 ✲ ⟝
Cool? / P 0 C K F D U
T / P . F U I P E T 0 O M Z F B T Z U P V T F ' 6 / $ 5 * 0 / 4
rect() triangle() quad() bezier() vertex() ….
Advanced V T J O H G P S
J G B O E B S S B Z
Build a matrix 欽 G P S ⨞ ♧ ⦐
瀄 ꤏ
for(var i = 0; i < 9; i ++){ for(var
j = 0; j < 9; j ++) { ellipse(i*50 , j*50, 30, 30) } } 殥 ♧ ⦐ Y 涸 瀄 ꤏ
for(var i = 0; i < 10; i ++){ for(var
j = 0; j < 10; j ++) { if(i % 2 == 0) { fill(color(“blue”)); } else { fill(color(“red”)); } ellipse(i*50 ,j*50, 30, 30); } } 殥 ♧ ⦐ Y 涸 瀄 ꤏ ⸈ Ⰵ ⴼ 倬 齅 鱀
#PrayForParis ⨞ ♧ ⦐ Y 涸 㕩 䕎
岁 㕜 㕜 偫 瀄 ꤏ 鍑 瘸 捀 Q S B Z ' P S 1 B S J T K T ⴕ ꗻ 箻 绢
Using sin() 殹 ⦐ 侸 㷸 㹻 ゅ
T J O 宕 黇 〫 㔐 ⫄
荛 涸 侸 㶶 ⵄ 欽 Ⱖ 暶 婌 涸 岚 䕎 醢 鸤 礶 䕙 涸 ⹛ 殥 佪 卓
frameCount 剚 㔐 ⫄ ♧ ⦐ 侮 侸 ➿
邍 植 㖈 殥 鹎 遤 ⵌ 痧 䎙 䌴 ✫ 䨾 ⟃ ➮ Ⱖ 㻜 剚 ♧ 湬 ⸈ ♧ ⸈ ♧ ♴
function draw(){ ellipse(400, 400, sin(frameCount), sin(frameCount)); } G S B
N F $ P V O U 莅 T J O 涸 刈 僳 禾 袇
function draw(){ var sinSeed = sin(frameCount * 0.01); ellipse(400, 400,
sinSeed * 100, sinSeed * 100); } G S B N F $ P V O U 莅 T J O 涸 刈 僳 禾 袇 葻 㥪 晝 劥
sin() = Magic 箻 绢 ⡲ ⦐ ♳ ♴ ⨞
矦 镜 麌 ⹛ 涸 椕 椕 ゅ 鍑 瘸 捀 T J O # B M M K T
Final Project 雊 1 S B Z ' P
S 1 B S J T 涸 敚 岙 䙐 㣐 䙐 㼭 ゅ 䧮 涸 晝 劥 㖈 鸏 酭 I U U Q H P P H M Y - [ P 5 玑 䒭 焺 僽 Q S B Z ' P S 1 B S J T K T
Terima Kasih! 䧮 僽 㹦 ꔤ 㹦 ꔤ 僽
䧮