diff options
author | Drew DeVault <sir@cmpwn.com> | 2017-08-19 08:45:44 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-08-19 08:45:44 -0400 |
commit | b876bea288bc4827a9de157eed481b823c081a4b (patch) | |
tree | 94fb650815691f98ab633c7731496f14ac751dc2 /examples/rotation.c | |
parent | 3674085faede2960581461cf8f40c33ffce85e7c (diff) | |
parent | 84c0c87a5ddca24cb039f33eea38252681bb4636 (diff) |
Merge pull request #114 from martinetd/cleanups
Cleanups
Diffstat (limited to 'examples/rotation.c')
-rw-r--r-- | examples/rotation.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/examples/rotation.c b/examples/rotation.c index b663f428..1dcbc80f 100644 --- a/examples/rotation.c +++ b/examples/rotation.c @@ -132,12 +132,12 @@ int main(int argc, char *argv[]) { compositor.keyboard_key_cb = handle_keyboard_key; compositor_init(&compositor); - state.renderer = wlr_gles2_renderer_init(compositor.backend); + state.renderer = wlr_gles2_renderer_create(compositor.backend); if (!state.renderer) { wlr_log(L_ERROR, "Could not start compositor, OOM"); exit(EXIT_FAILURE); } - state.cat_texture = wlr_render_texture_init(state.renderer); + state.cat_texture = wlr_render_texture_create(state.renderer); if (!state.cat_texture) { wlr_log(L_ERROR, "Could not start compositor, OOM"); exit(EXIT_FAILURE); @@ -145,10 +145,11 @@ int main(int argc, char *argv[]) { wlr_texture_upload_pixels(state.cat_texture, WL_SHM_FORMAT_ABGR8888, cat_tex.width, cat_tex.width, cat_tex.height, cat_tex.pixel_data); - compositor_run(&compositor); + wl_display_run(compositor.display); wlr_texture_destroy(state.cat_texture); wlr_renderer_destroy(state.renderer); + compositor_fini(&compositor); example_config_destroy(state.config); } |