2023. 4. 23. 15:40ㆍLess Code with ChatGPT/Processing
-Learn the Processing #Colors
https://hello.processing.org/editor/
Processing Hour of Code | Editor
hello.processing.org
Code>>
size(500,300)
background(216,133,224);
ellipse(250,150,100,100);//bigface
ellipse(180,125,50,50);//earl
ellipse(320,125,50,50);//earr
ellipse(230,140,30,30);//eyel
ellipse(270,140,30,30);//eyer
stroke(0);
fill(128);
ellipse(250,170,20,30);//mouth
ellipse(230,140,10,10);//earballl
ellipse(270,140,10,10);//eyeballr
stroke(0);
fill(0,0,255);
rect(225,200,50,60);//neck
stroke(255);
fill(255,0,0);
triangle(100,100, 130,70,125,125);
Run Code>>
Meaning>>
선 stroke(0);
그레이채우기 fill(128)
컬러채우기 값 Red, Green, Blue -->> fill( , , );
Black (0); -----> White (255);
White (0);-----> Red (255);
White (0);----->Green (255);
White (0);-----> Blue (255);
배경채우기 background( , , );
도형을 만들기 전에 선과 채우기의 색들을 먼저 설정한다.
설정을 바꾸기전까지는 이후 넘버링 코드에 모두 적용됨
'Less Code with ChatGPT > Processing' 카테고리의 다른 글
#5. Processing -Variations (0) | 2023.04.25 |
---|---|
ChatGPT + Processing 으로 3D 그림 만들기 Interactive Digital Art (0) | 2023.04.24 |
#4. Processing -Variations (0) | 2023.04.24 |
#3. Processing - Interact/Animate (0) | 2023.04.24 |
#1. Processing - Shapes (0) | 2023.04.22 |