window.signal_close.connect(sigc::bind(sigc::mem_fun(this, &DesertPillars::exit), 0));
keyboard.signal_button_press.connect(sigc::bind_return(sigc::mem_fun(this, &DesertPillars::key_press), false));
window.signal_close.connect(sigc::bind(sigc::mem_fun(this, &DesertPillars::exit), 0));
keyboard.signal_button_press.connect(sigc::bind_return(sigc::mem_fun(this, &DesertPillars::key_press), false));
- const GL::Light &sun = resources.get<GL::Light>("Sun.light");
- sky = make_unique<GL::Sky>(resources, content, sun);
+ GL::Light &sun = resources.get<GL::Light>("Sun.light");
+ sky = make_unique<GL::Sky>(content, sun);
unsigned shadow_size = 8192;
shadow_seq = make_unique<GL::Sequence>(shadow_size, shadow_size);
GL::Sequence::Step *step = &shadow_seq->add_step("shadow", content);
step->set_depth_test(&GL::DepthTest::lequal());
unsigned shadow_size = 8192;
shadow_seq = make_unique<GL::Sequence>(shadow_size, shadow_size);
GL::Sequence::Step *step = &shadow_seq->add_step("shadow", content);
step->set_depth_test(&GL::DepthTest::lequal());
- shadow_map = make_unique<GL::ShadowMap>(resources, shadow_size, *sky, sun, *shadow_seq);
- shadow_map->set_darkness(0.9f);
+ shadow_map = make_unique<GL::ShadowMap>(shadow_size, *sky, sun, *shadow_seq);
shadow_map->set_target(GL::Vector3(0.0f, 0.0f, 0.0f), 20.0f);
GL::SequenceBuilder seq_bld(resources.get<GL::SequenceTemplate>("Desert.seq"));
shadow_map->set_target(GL::Vector3(0.0f, 0.0f, 0.0f), 20.0f);
GL::SequenceBuilder seq_bld(resources.get<GL::SequenceTemplate>("Desert.seq"));
step->set_lighting(&resources.get<GL::Lighting>("Desert.lightn"));
step->set_depth_test(&GL::DepthTest::lequal());
step->set_lighting(&resources.get<GL::Lighting>("Desert.lightn"));
step->set_depth_test(&GL::DepthTest::lequal());
- env_map = make_unique<GL::EnvironmentMap>(resources, 256, GL::RGB16F, sphere, *env_seq);
+ env_map = make_unique<GL::EnvironmentMap>(256, GL::RGB16F, sphere, *env_seq);
sphere.set_matrix(GL::Matrix::translation(GL::Vector3(0.0f, 0.0f, 3.3f)));
content.add(resources.get<GL::Scene>("Background.scene"));
sphere.set_matrix(GL::Matrix::translation(GL::Vector3(0.0f, 0.0f, 3.3f)));
content.add(resources.get<GL::Scene>("Background.scene"));