Cleanup and complete keybindings

This commit is contained in:
karl 2021-06-22 11:23:50 +02:00
parent 5477388869
commit 34b7ddfbfb

View File

@ -80,17 +80,19 @@ class FullDemo : public Gedeng::Application {
if (Gedeng::Input::is_key_down(GLFW_KEY_4)) tessellation_factor += delta * 8.0;
if (Gedeng::Input::is_key_down(GLFW_KEY_3)) tessellation_factor -= delta * 8.0;
if (Gedeng::Input::is_key_down(GLFW_KEY_6)) number_of_steps += delta * 5.0;
if (Gedeng::Input::is_key_down(GLFW_KEY_5)) number_of_steps -= delta * 5.0;
if (Gedeng::Input::is_key_down(GLFW_KEY_8)) number_of_refinement_steps += delta * 5.0;
if (Gedeng::Input::is_key_down(GLFW_KEY_7)) number_of_refinement_steps -= delta * 5.0;
if (Gedeng::Input::is_key_down(GLFW_KEY_0)) bump_depth += delta * 0.1;
if (Gedeng::Input::is_key_down(GLFW_KEY_9)) bump_depth -= delta * 0.1;
particles.set_interval(particle_interval);
}
void dynamic_update(double delta) override {
// Wireframe?
if (Gedeng::Input::is_key_down(GLFW_KEY_B)) {
glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
} else {
glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
}
// Marching cubes
// Create the noise