Fixed camera

This commit is contained in:
STP
2023-11-25 00:04:41 -05:00
parent ccac1f414d
commit ab284e8e98
4 changed files with 50 additions and 65 deletions

View File

@@ -5,18 +5,21 @@ let target = P(0.0, 0.0, 0.0);
let up = V(0.0, 1.0, 3.0);
let cam = Camera(eye, target, up, 70.0, 1.0);
let material = Material(V(0.5,0.5,0.5), V(0.8, 0.8, 0.8), 0.5);
let material = Material(V(0.5,0.5,0.5), V(0.8, 0.8, 0.8), 25.0);
let light2 = Light(P(0.0,0.0,-10.0), V(0.8, 0.8, 0.8), V(0.2, 0.0, 0.0));
let ambient = Light(P(10.0,0.0,0.0), V(1.0,1.0,1.0), V(0.0, 0.0, 0.0));
let light2 = Light(P(0.0,0.0,10.0), V(0.0,1.0,1.0), V(0.1, 0.01, 0.001));
scene.addLight(light2);
scene.addLight(ambient);
// let sphere = Sphere(P(0.0,0.0,0.0), 4.0, material);
// let node = Node(sphere);
// scene.addNode(node);
let stein = Torus(1.0,2.0, material);
let stein = Stein(5.0,10.0, material);
let node = Node(stein);
scene.addNode(node);