aboutsummaryrefslogtreecommitdiff
path: root/examples/scene-graph.c
diff options
context:
space:
mode:
authorSimon Ser <contact@emersion.fr>2023-06-26 20:07:36 +0200
committerAlexander Orzechowski <alex@ozal.ski>2023-06-27 16:26:30 +0000
commit2aabaf88096864f4a9c534f94c909968d0b62b19 (patch)
treecf42282606d2ac4a2595cde359936147fd1a3df8 /examples/scene-graph.c
parent9e6431dc3bd121b1994961c68374b4e17db29444 (diff)
examples: enable new outputs
Diffstat (limited to 'examples/scene-graph.c')
-rw-r--r--examples/scene-graph.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/examples/scene-graph.c b/examples/scene-graph.c
index 0ea61c28..3cf150d0 100644
--- a/examples/scene-graph.c
+++ b/examples/scene-graph.c
@@ -81,14 +81,15 @@ static void server_handle_new_output(struct wl_listener *listener, void *data) {
output->scene_output = wlr_scene_output_create(server->scene, wlr_output);
+ struct wlr_output_state state;
+ wlr_output_state_init(&state);
+ wlr_output_state_set_enabled(&state, true);
struct wlr_output_mode *mode = wlr_output_preferred_mode(wlr_output);
if (mode != NULL) {
- struct wlr_output_state state;
- wlr_output_state_init(&state);
wlr_output_state_set_mode(&state, mode);
- wlr_output_commit_state(wlr_output, &state);
- wlr_output_state_finish(&state);
}
+ wlr_output_commit_state(wlr_output, &state);
+ wlr_output_state_finish(&state);
wlr_output_create_global(wlr_output);
}