From 34296feeb20da082d7d0c9eef02ba20e60719cea Mon Sep 17 00:00:00 2001 From: Eryn Wells Date: Sun, 22 Sep 2013 10:16:32 -0700 Subject: [PATCH] Add a plane to the scene --- src/charles.cc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/charles.cc b/src/charles.cc index f042ccd..02501e7 100644 --- a/src/charles.cc +++ b/src/charles.cc @@ -11,6 +11,7 @@ #include "light.h" #include "material.h" #include "object_sphere.h" +#include "object_plane.h" #include "scene.h" #include "writer_png.h" @@ -46,6 +47,11 @@ main(int argc, scene.add_shape(s2); scene.add_shape(s3); + // Make a plane + Plane *p1 = new Plane(Vector3(0, 200, 0), Vector3::Y); + p1->set_material(m1); + scene.add_shape(p1); + PointLight *l1 = new PointLight(Vector3(0.0, 240.0, 100.0), Color(1.0, 1.0, 1.0), 1.0); //Light *l2 = new Light(Vector3(640.0, 240.0, 10000.0), 0.2); scene.add_light(l1);