From aed523d457c60dd9cae9cf34f9e8bbccf5980a2d Mon Sep 17 00:00:00 2001 From: Eryn Wells Date: Wed, 11 Sep 2013 08:38:39 -0700 Subject: [PATCH] Add lights to the scene --- src/charles.cc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/charles.cc b/src/charles.cc index ca2c48c..f41a268 100644 --- a/src/charles.cc +++ b/src/charles.cc @@ -8,6 +8,7 @@ #include #include "basics.h" +#include "light.h" #include "object_sphere.h" #include "scene.h" #include "writer_png.h" @@ -29,6 +30,11 @@ main(int argc, scene.add_shape(s2); scene.add_shape(s3); + Light *l1 = new Light(Vector3(0.0, 240.0, -100.0), 1.0); + Light *l2 = new Light(Vector3(640.0, 240.0, -10000.0), 0.6); + scene.add_light(l1); + scene.add_light(l2); + // Render. scene.render();