diff options
Diffstat (limited to 'boltzgas/visualizer.py')
-rw-r--r-- | boltzgas/visualizer.py | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/boltzgas/visualizer.py b/boltzgas/visualizer.py index 373a181..22ebfe1 100644 --- a/boltzgas/visualizer.py +++ b/boltzgas/visualizer.py @@ -64,8 +64,10 @@ def make_keyboard_handler(controller, view): controller.pause() else: controller.run() - if key == b'h': - view.show_histogram = not view.show_histogram + if key == b'1': + view.show_decorations = not view.show_decorations + if key == b'2': + view.show_windows = not view.show_windows return on_keyboard @@ -75,7 +77,7 @@ def make_close_handler(controller): return on_close -def simulate(config, gas, instruments, decorations, windows, updates_per_frame = 5): +def simulate(config, gas, instruments, updates_per_frame = 5): glutInit() glutInitDisplayMode(GLUT_RGBA | GLUT_DOUBLE | GLUT_DEPTH) glutInitWindowPosition(0, 0) @@ -85,7 +87,7 @@ def simulate(config, gas, instruments, decorations, windows, updates_per_frame = for instrument in instruments: instrument.setup() - view = View(gas, decorations, windows) + view = View(gas, instruments) controller = SimulationController(gas, instruments, updates_per_frame) glutDisplayFunc(make_display_handler(controller, view)) |