-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathP53d.html
31 lines (31 loc) · 806 Bytes
/
P53d.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<script src="https://cdn.jsdelivr.net/npm/[email protected]/lib/p5.js"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/lib/p5.dom.js"></script>
<style>
body{background-color:black;margin:0;padding:0;}
</style>
</head>
<body>
<script>
function setup(){
createCanvas(window.innerWidth,window.innerHeight,WEBGL);
angleMode(DEGREES);
}
function draw(){
background(0);
//translate(width/2,height/2);
rotateX(-mouseY);
rotateY(mouseX);
stroke(255);
noFill();
sphere(100,10,10);
box(250);
fill(255,100);
noStroke();
plane(300);
}
</script>
</body>
<html>