Add more point lights to the example scene
This commit is contained in:
parent
78078e92cd
commit
6b10ae96f8
1 changed files with 8 additions and 2 deletions
|
@ -26,13 +26,19 @@ void ExampleApp::initialize_render() {
|
|||
auto& sun = scene->add<Light>(sun_obj);
|
||||
sun.type = Light::Type::Point;
|
||||
auto& sun_trans = scene->get<Transform>(sun_obj);
|
||||
sun_trans.position = {0, 5, -3};
|
||||
sun_trans.position = {-2, 5, 1};
|
||||
|
||||
auto second_sun_obj = scene->add_object();
|
||||
auto& second_sun = scene->add<Light>(second_sun_obj);
|
||||
second_sun.type = Light::Type::Point;
|
||||
second_sun.color = {1, 0, 0};
|
||||
scene->get<Transform>(second_sun_obj).position = {2, 3, 3};
|
||||
scene->get<Transform>(second_sun_obj).position = {-14, 1, -1};
|
||||
|
||||
auto third_sun_obj = scene->add_object();
|
||||
auto& third_sun = scene->add<Light>(third_sun_obj);
|
||||
third_sun.type = Light::Type::Point;
|
||||
third_sun.color = {0, 0, 1};
|
||||
scene->get<Transform>(third_sun_obj).position = {3, 1, -1};
|
||||
|
||||
auto sphere_obj = scene->add_object();
|
||||
auto& sphere_render = scene->add<Renderable>(sphere_obj);
|
||||
|
|
Reference in a new issue